packaging
This commit is contained in:
parent
caa9e1a6fa
commit
f0c9fb441d
49 changed files with 2855 additions and 1724 deletions
38
ZicMoove/ZicMoove/Pages/ClientPages/ActivityPage.xaml
Normal file
38
ZicMoove/ZicMoove/Pages/ClientPages/ActivityPage.xaml
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<CarouselPage xmlns="http://xamarin.com/schemas/2014/forms"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
x:Class="ZicMoove.Pages.ClientPages.ActivityPage"
|
||||
xmlns:local="clr-namespace:ZicMoove;assembly=ZicMoove"
|
||||
>
|
||||
<CarouselPage.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<ContentPage>
|
||||
<ContentPage.Padding>
|
||||
<OnPlatform x:TypeArguments="Thickness" iOS="0,40,0,0" Android="0,40,0,0" />
|
||||
</ContentPage.Padding>
|
||||
<ScrollView>
|
||||
|
||||
<StackLayout>
|
||||
<Label Text="{Binding Name}" FontSize="Medium" HorizontalOptions="Center" />
|
||||
<Image Source="{Binding PhotoUri}" Margin="10,10,10,10" HorizontalOptions="Center" VerticalOptions="CenterAndExpand" />
|
||||
<Label Text="{Binding Descrition}" HorizontalOptions="Center" />
|
||||
<ListView ItemsSource="{Binding Forms}">
|
||||
<ListView.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<ViewCell>
|
||||
<ViewCell.View>
|
||||
<StackLayout>
|
||||
<Button Text="{Binding Title}" CommandParameter="{Binding Action}"/>
|
||||
</StackLayout>
|
||||
</ViewCell.View>
|
||||
</ViewCell>
|
||||
</DataTemplate>
|
||||
</ListView.ItemTemplate>
|
||||
</ListView>
|
||||
</StackLayout>
|
||||
</ScrollView>
|
||||
</ContentPage>
|
||||
</DataTemplate>
|
||||
</CarouselPage.ItemTemplate>
|
||||
|
||||
</CarouselPage>
|
||||
25
ZicMoove/ZicMoove/Pages/ClientPages/ActivityPage.xaml.cs
Normal file
25
ZicMoove/ZicMoove/Pages/ClientPages/ActivityPage.xaml.cs
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
using Xamarin.Forms;
|
||||
using ZicMoove.Data;
|
||||
|
||||
namespace ZicMoove.Pages.ClientPages
|
||||
{
|
||||
public partial class ActivityPage
|
||||
{
|
||||
public ActivityPage()
|
||||
{
|
||||
InitializeComponent();
|
||||
ItemsSource = DataManager.Instance.Activities;
|
||||
|
||||
}
|
||||
public ActivityPage(object context)
|
||||
{
|
||||
BindingContext = context;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -8,7 +8,6 @@
|
|||
xmlns:converters="clr-namespace:ZicMoove.Converters;assembly=ZicMoove"
|
||||
xmlns:local="clr-namespace:ZicMoove;Assembly:ZicMoove"
|
||||
xmlns:extensions="clr-namespace:ZicMoove.Extensions;assembly=ZicMoove"
|
||||
|
||||
Style="{StaticResource PageStyle}" >
|
||||
|
||||
<TabbedPage.Children>
|
||||
|
|
|
|||
20
ZicMoove/ZicMoove/Pages/ClientPages/Workflow/WFBookPage.cs
Normal file
20
ZicMoove/ZicMoove/Pages/ClientPages/Workflow/WFBookPage.cs
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
using ZicMoove.Model.Social;
|
||||
using System;
|
||||
using Xamarin.Forms;
|
||||
using Xamarin.Forms.Maps;
|
||||
using Yavsc;
|
||||
using ZicMoove.Data;
|
||||
using System.Threading.Tasks;
|
||||
using XLabs.Platform.Services.Geolocation;
|
||||
using Plugin.Geolocator;
|
||||
|
||||
namespace ZicMoove.Pages.ClientPages
|
||||
{
|
||||
public class WorkflowBookPage : PinPage
|
||||
{
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -7,6 +7,7 @@ namespace ZicMoove.Pages
|
|||
{
|
||||
using Data;
|
||||
using EstimatePages;
|
||||
using Model.Musical;
|
||||
using Model.Social;
|
||||
using Model.Workflow;
|
||||
using Settings;
|
||||
|
|
|
|||
|
|
@ -6,8 +6,7 @@
|
|||
xmlns:views="clr-namespace:ZicMoove.Views;assembly=ZicMoove"
|
||||
xmlns:extensions="clr-namespace:ZicMoove.Extensions;assembly=ZicMoove"
|
||||
xmlns:controls="clr-namespace:XLabs.Forms.Controls;assembly=XLabs.Forms"
|
||||
Style="{StaticResource PageStyle}">
|
||||
|
||||
Style="{StaticResource PageStyle}">
|
||||
|
||||
<ScrollView>
|
||||
<ScrollView.Padding>
|
||||
|
|
@ -50,6 +49,8 @@
|
|||
|
||||
<Button Text="{Binding PerformerStatus}" Clicked="OnViewPerformerStatus" />
|
||||
</StackLayout>
|
||||
|
||||
<Button Text="Payer" x:Name="btnPay"/>
|
||||
</StackLayout>
|
||||
</StackLayout>
|
||||
</ScrollView>
|
||||
|
|
|
|||
|
|
@ -5,15 +5,20 @@ using Plugin.Media.Abstractions;
|
|||
using System;
|
||||
|
||||
using Xamarin.Forms;
|
||||
using ZicMoove.Settings;
|
||||
using ZicMoove.Helpers;
|
||||
using System.Net.Http;
|
||||
|
||||
namespace ZicMoove.Pages.UserProfile
|
||||
{
|
||||
public partial class UserProfilePage : ContentPage
|
||||
public partial class UserProfilePage
|
||||
{
|
||||
public UserProfilePage()
|
||||
{
|
||||
InitializeComponent();
|
||||
AvatarButton.Clicked += AvatarButton_Clicked;
|
||||
btnPay.Clicked += BtnPay_Clicked;
|
||||
|
||||
}
|
||||
public UserProfilePage(UserProfileViewModel model)
|
||||
{
|
||||
|
|
@ -21,14 +26,23 @@ namespace ZicMoove.Pages.UserProfile
|
|||
AvatarButton.Clicked += AvatarButton_Clicked;
|
||||
BindingContext = model;
|
||||
}
|
||||
private async void AvatarButton_Clicked (object sender, EventArgs e)
|
||||
|
||||
|
||||
private async void BtnPay_Clicked(object sender, EventArgs e)
|
||||
{
|
||||
App.PlatformSpecificInstance.Pay(0.1, Interfaces.PayMethod.Immediate, "test payment");
|
||||
|
||||
}
|
||||
|
||||
|
||||
private async void AvatarButton_Clicked(object sender, EventArgs e)
|
||||
{
|
||||
if (!CrossMedia.Current.IsCameraAvailable || !CrossMedia.Current.IsTakePhotoSupported)
|
||||
{
|
||||
await DisplayAlert("No Camera", ":( No camera avaialble.", "OK");
|
||||
return;
|
||||
}
|
||||
|
||||
IsBusy = true;
|
||||
var file = await CrossMedia.Current.TakePhotoAsync(new StoreCameraMediaOptions
|
||||
{
|
||||
Directory = "Avatars",
|
||||
|
|
@ -37,13 +51,31 @@ namespace ZicMoove.Pages.UserProfile
|
|||
|
||||
if (file == null)
|
||||
return;
|
||||
// ImageSource.FromFile(file.Path);
|
||||
/* ImageSource.FromStream(() =>
|
||||
using (var client = UserHelpers.CreateJsonClient())
|
||||
{
|
||||
var stream = file.GetStream();
|
||||
file.Dispose();
|
||||
return stream;
|
||||
}); */
|
||||
// Get the whole data
|
||||
try
|
||||
{
|
||||
using (var stream = file.GetStream())
|
||||
{
|
||||
var content = new StreamContent(stream);
|
||||
|
||||
using (var response = await client.PostAsync(Constants.YavscApiUrl + "/setavatar", content))
|
||||
{
|
||||
if (response.IsSuccessStatusCode)
|
||||
{
|
||||
// TODO image update
|
||||
var recnt = await response.Content.ReadAsStringAsync();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
// TODO error report
|
||||
}
|
||||
}
|
||||
IsBusy = false;
|
||||
}
|
||||
|
||||
public void OnManageFiles(object sender, EventArgs e)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<CarouselPage xmlns="http://xamarin.com/schemas/2014/forms"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
xmlns:local="clr-namespace:ZicMoove;assembly=ZicMoove"
|
||||
x:Class="ZicMoove.Pages.HomePage"
|
||||
x:Class="ZicMoove.Pages.WorkflowPage"
|
||||
Style="{StaticResource PageStyle}"
|
||||
Title="Accueil">
|
||||
<CarouselPage.Resources>
|
||||
|
|
@ -5,21 +5,21 @@ namespace ZicMoove.Pages
|
|||
using Data;
|
||||
using ViewModels;
|
||||
using ViewModels.EstimateAndBilling;
|
||||
public partial class HomePage
|
||||
public partial class WorkflowPage
|
||||
{
|
||||
public HomePage()
|
||||
public WorkflowPage()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public HomePage(HomeViewModel model)
|
||||
public WorkflowPage(WorkflowViewModel model)
|
||||
{
|
||||
BindingContext = model;
|
||||
}
|
||||
|
||||
public HomeViewModel Model {
|
||||
public WorkflowViewModel Model {
|
||||
get {
|
||||
return (HomeViewModel) BindingContext;
|
||||
return (WorkflowViewModel) BindingContext;
|
||||
}
|
||||
set
|
||||
{
|
||||
Loading…
Add table
Add a link
Reference in a new issue