sweet home
This commit is contained in:
parent
22ae5f7a61
commit
438e2f8631
28 changed files with 569 additions and 168 deletions
|
|
@ -3,6 +3,7 @@
|
|||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
x:Class="ZicMoove.Pages.ClientPages.ActivityPage"
|
||||
xmlns:local="clr-namespace:ZicMoove;assembly=ZicMoove"
|
||||
xmlns:views="clr-namespace:ZicMoove.Views;assembly=ZicMoove"
|
||||
>
|
||||
<CarouselPage.ItemTemplate>
|
||||
<DataTemplate>
|
||||
|
|
@ -13,22 +14,32 @@
|
|||
<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>
|
||||
<Frame HasShadow="True">
|
||||
<StackLayout>
|
||||
<StackLayout Orientation="Horizontal">
|
||||
<views:SvgImage Svg="{Binding LocalPhoto}" HorizontalOptions="Start" HeightRequest="100" WidthRequest="100"/>
|
||||
|
||||
<Label Text="{Binding Name}" FontSize="Medium" HorizontalOptions="Center" />
|
||||
</StackLayout>
|
||||
<Label Text="{Binding Description}" 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>
|
||||
</Frame>
|
||||
|
||||
</StackLayout>
|
||||
</ScrollView>
|
||||
</ContentPage>
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@
|
|||
Grid.Row="0" Grid.Column="3"
|
||||
FontFamily="Monospace"></Label>
|
||||
<Image Grid.Row="0" Grid.Column="4" Style="{Binding
|
||||
Path=ViewModelState.IsValid,
|
||||
Path=ModelState.IsValid,
|
||||
Converter={StaticResource boolToStyleImage}}" ></Image>
|
||||
</Grid>
|
||||
</ViewCell.View>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
</ContentPage.Resources>
|
||||
<ContentPage.Content>
|
||||
<StackLayout Padding="10,10,10,10" x:Name="mainLayout">
|
||||
<ScrollView>
|
||||
<ScrollView VerticalOptions="Start">
|
||||
<StackLayout>
|
||||
<Grid MinimumHeightRequest="12">
|
||||
<Grid.RowDefinitions>
|
||||
|
|
@ -82,11 +82,11 @@
|
|||
VerticalOptions="FillAndExpand"
|
||||
HorizontalOptions="FillAndExpand"
|
||||
BackgroundColor="White"
|
||||
CaptionText="{Binding Data.Owner?.UserName}" CaptionTextColor="Black"
|
||||
CaptionText="{Binding CaptionText}" CaptionTextColor="Black"
|
||||
ClearText="Effacer!" ClearTextColor="Red"
|
||||
PromptText="Prompt Here" PromptTextColor="Red"
|
||||
SignatureLineColor="Aqua" StrokeColor="Black" StrokeWidth="2" />
|
||||
<Button Clicked="OnValidate" Text="Valider cette signature" x:Name="btnValidate" />
|
||||
PromptText="{Binding PromptText}" PromptTextColor="Red"
|
||||
SignatureLineColor="Green" StrokeColor="Black" StrokeWidth="3" />
|
||||
<Button Clicked="OnValidate" Text="Valider cette signature" x:Name="btnValidate" VerticalOptions="End" />
|
||||
|
||||
</StackLayout>
|
||||
</ContentPage.Content>
|
||||
|
|
|
|||
|
|
@ -32,21 +32,8 @@ namespace ZicMoove.Pages.EstimatePages
|
|||
var evm = (EditEstimateViewModel)BindingContext;
|
||||
var estimate = evm.Data;
|
||||
|
||||
|
||||
|
||||
using (var stream = await padView.GetImageStreamAsync(SignatureImageFormat.Png))
|
||||
{
|
||||
/*
|
||||
var signatureMemoryStream = pngStream as MemoryStream;
|
||||
if (signatureMemoryStream == null)
|
||||
{
|
||||
signatureMemoryStream = new MemoryStream();
|
||||
pngStream.CopyTo(signatureMemoryStream);
|
||||
}
|
||||
var byteArray = signatureMemoryStream.ToArray();
|
||||
var base64String = Convert.ToBase64String(byteArray)
|
||||
*/
|
||||
|
||||
stream.Seek(0, SeekOrigin.Begin);
|
||||
await DataManager.Instance.Estimates.SignAsProvider(estimate, stream);
|
||||
DataManager.Instance.Estimates.SaveEntity();
|
||||
|
|
@ -60,33 +47,6 @@ namespace ZicMoove.Pages.EstimatePages
|
|||
}
|
||||
|
||||
|
||||
private async void OnChangeTheme(object sender, EventArgs e)
|
||||
{
|
||||
var action = await DisplayActionSheet("Change Theme", "Cancel", null, "White", "Black", "Aqua");
|
||||
switch (action)
|
||||
{
|
||||
case "White":
|
||||
padView.BackgroundColor = Color.White;
|
||||
padView.StrokeColor = Color.Black;
|
||||
padView.ClearTextColor = Color.Black;
|
||||
padView.ClearText = "Clear Markers";
|
||||
break;
|
||||
|
||||
case "Black":
|
||||
padView.BackgroundColor = Color.Black;
|
||||
padView.StrokeColor = Color.White;
|
||||
padView.ClearTextColor = Color.White;
|
||||
padView.ClearText = "Clear Chalk";
|
||||
break;
|
||||
|
||||
case "Aqua":
|
||||
padView.BackgroundColor = Color.Aqua;
|
||||
padView.StrokeColor = Color.Red;
|
||||
padView.ClearTextColor = Color.Black;
|
||||
padView.ClearText = "Clear The Aqua";
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue