123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180 |
- <?xml version="1.0" encoding="UTF-8"?>
- <timesheets:BasePage
- xmlns="http://xamarin.com/schemas/2014/forms"
- xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
- xmlns:material="clr-namespace:XF.Material.Forms.UI;assembly=XF.Material"
- xmlns:timesheets="clr-namespace:comal.timesheets"
- material:MaterialNavigationPage.AppBarTitleTextFontSize="16.0"
- x:Class="comal.timesheets.DeliveryDetails"
- >
- <timesheets:BasePage.PageContent>
-
- <StackLayout VerticalOptions="StartAndExpand">
- <ScrollView x:Name="pageScroller" Padding="10">
- <StackLayout Orientation="Vertical" VerticalOptions="StartAndExpand">
- <!--Row 0 Delivery Type-->
- <material:MaterialLabel Text="Type" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
-
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" >
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="auto"/>
- </Grid.ColumnDefinitions>
- <Label Grid.Column="0" x:Name="TypeLbl" LineBreakMode="WordWrap" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold"/>
- <Button Grid.Column="1" x:Name="SelectTypeBtn" Clicked="SelectType_Clicked" Text="Select" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Grid>
- </Frame>
-
- <!--Row 1 Job number-->
- <material:MaterialLabel Text="Job Number" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" >
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="auto"/>
- </Grid.ColumnDefinitions>
- <Label Grid.Column="0" x:Name="JobName" LineBreakMode="WordWrap" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold"/>
- <Button Grid.Column="1" x:Name="SelectJob" Clicked="SelectJob_Clicked" Text="Select" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Grid>
- </Frame>
- <!--Row 2 Delivered Address - doesn't show up unless is present-->
- <material:MaterialLabel x:Name="DeliveredLbl" Text="Delivered" IsVisible="false" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
-
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" x:Name="DeliveredFlagFrame" IsVisible="false">
- <StackLayout>
- <Label x:Name="DeliveredDetails" FontAttributes="Bold" FontSize="Medium" TextColor="PaleVioletRed" HorizontalTextAlignment="Center" Margin="5"/>
- <Button x:Name="openMapBtn" IsEnabled="False" Clicked="OpenMapBtn_Clicked" Text="Show in Maps" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </StackLayout>
- </Frame>
- <!--Row 3 Address + contact selection-->
- <material:MaterialLabel Text="Address / Contact" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" >
- <StackLayout>
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="auto"/>
- </Grid.ColumnDefinitions>
- <Label Grid.Column="0" x:Name="ContactNameLbl" LineBreakMode="WordWrap" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray"/>
- <Button Grid.Column="1" x:Name="SelectContactBtn" Clicked="SelectContact_Clicked" Text="Select" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Grid>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="auto"/>
- <RowDefinition Height="auto"/>
- <RowDefinition Height="auto"/>
- <RowDefinition Height="auto"/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="auto"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <material:MaterialLabel Grid.Row="0" Grid.Column="0" Text="Street" TypeScale="H6" HorizontalTextAlignment="Start" VerticalOptions="Center" />
- <material:MaterialLabel Grid.Row="1" Grid.Column="0" Text="City" TypeScale="H6" HorizontalTextAlignment="Start" VerticalOptions="Center" />
- <material:MaterialLabel Grid.Row="2" Grid.Column="0" Text="State" TypeScale="H6" HorizontalTextAlignment="Start" VerticalOptions="Center"/>
- <material:MaterialLabel Grid.Row="3" Grid.Column="0" Text="Post Code" TypeScale="H6" HorizontalTextAlignment="Start" VerticalOptions="Center" />
- <Editor Grid.Row="0" Grid.Column="1" x:Name="streetEdt" Placeholder="Edit" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray" TextChanged="StreetEdt_Changed" AutoSize="TextChanges"/>
- <Editor Grid.Row="1" Grid.Column="1" x:Name="cityEdt" Placeholder="Edit" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray" TextChanged="CityEdt_Changed" AutoSize="TextChanges"/>
- <Picker Grid.Row="2" Grid.Column="1" x:Name="statePicker" VerticalOptions="Center" SelectedIndex="0" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray" SelectedIndexChanged="StatePicker_Changed">
- <Picker.Items>
- <x:String>Western Australia</x:String>
- <x:String>Victoria</x:String>
- <x:String>South Australia</x:String>
- <x:String>New South Wales</x:String>
- <x:String>Queensland</x:String>
- <x:String>Tasmania</x:String>
- </Picker.Items>
- </Picker>
- <Editor Grid.Row="3" Grid.Column="1" x:Name="postCodeEdt" Placeholder="Edit" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray" Keyboard="Numeric" MaxLength="4" TextChanged="PostCode_Changed"/>
- </Grid>
- </StackLayout>
- </Frame>
- <!--Row 4 Delivery Notes-->
- <material:MaterialLabel Text="Delivery Notes" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" BorderColor="Gray" Padding="10" >
- <Editor x:Name="deliveryNotesEdt" AutoSize="TextChanges" Placeholder="Edit" TextChanged="DeliveryNotes_Completed"/>
- </Frame>
- <!--Row 5 Items -->
- <material:MaterialLabel x:Name="ItemsToBeDelivered" IsVisible="false" Grid.Column="0" Text="Delivery Items" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
-
- <Frame x:Name="ItemsFrame" MinimumHeightRequest="50" HasShadow="False" Padding="10" BorderColor="Gray" VerticalOptions="StartAndExpand">
- <Button x:Name="loadDeliveryItems" IsEnabled="False" Clicked="Docket_Clicked" Text="View" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Frame>
- <!--Row 6 Photos-->
- <material:MaterialLabel x:Name="photosLbl" Text="Photos" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" Padding="10" BorderColor="Gray">
- <StackLayout Orientation="Vertical">
- <CollectionView x:Name="Images">
- <CollectionView.ItemsLayout>
- <GridItemsLayout Orientation="Horizontal" Span="1" />
- </CollectionView.ItemsLayout>
- <CollectionView.ItemTemplate>
- <DataTemplate>
- <Image HeightRequest="150" Aspect="AspectFill" Source="{Binding .}">
- <Image.GestureRecognizers>
- <TapGestureRecognizer Tapped="ImageTapped" CommandParameter="{Binding .}" NumberOfTapsRequired="1" />
- </Image.GestureRecognizers>
- </Image>
- </DataTemplate>
- </CollectionView.ItemTemplate>
- </CollectionView>
- <!-- <ScrollView Orientation="Horizontal" x:Name="ImageScroller" IsVisible="false"> -->
- <!-- <StackLayout x:Name="images" Orientation="Horizontal" HeightRequest="150" HorizontalOptions="StartAndExpand" VerticalOptions="Fill"/> -->
- <!-- </ScrollView> -->
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <Button x:Name="TakePhoto" Grid.Column="0" Text="Camera" Clicked="TakePhoto_Clicked" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- <Button x:Name="ChooseImage" Grid.Column="1" Text="Library" Clicked="ChooseImage_Clicked" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Grid>
- </StackLayout>
- </Frame>
- <!--Row 7 Employee-->
- <material:MaterialLabel Text="Requested By" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" >
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="auto"/>
- </Grid.ColumnDefinitions>
- <Label Grid.Column="0" x:Name="EmployeeName" LineBreakMode="WordWrap" HorizontalOptions="Start" VerticalOptions="Center" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray"/>
- <Button Grid.Column="1" x:Name="SelectEmployee" Clicked="SelectEmployee_Clicked" Text="Select" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Grid>
- </Frame>
- <!--Row 8 Due-->
- <material:MaterialLabel Text="Due (Tap to edit)" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
- <Frame HasShadow="False" Padding="10" BorderColor="Gray" >
- <DatePicker x:Name="dueDate" FontSize="Medium" FontAttributes="Bold" TextColor="DimGray"/>
- </Frame>
- <!--Row 9 Create a task-->
- <material:MaterialLabel x:Name="createATaskLbl" IsVisible="true" Grid.Column="0" Text="Create A Task" TypeScale="H6" HorizontalTextAlignment="Start" Margin="5"/>
-
- <Frame x:Name="TaskFrame" MinimumHeightRequest="50" HasShadow="False" Padding="10" BorderColor="Gray" VerticalOptions="StartAndExpand">
- <Button x:Name="convertToTaskBtn" IsEnabled="True" Clicked="ConvertToTaskBtn_Clicked" Text="Create" Padding="3" FontSize="Medium" TextColor="White" BackgroundColor="#15C7C1" FontAttributes="Bold"/>
- </Frame>
- </StackLayout>
- </ScrollView>
- <!--for future use when pdf exporter for Delivery Docket is ready-->
- <!--<Button x:Name="docketViewBtn" Text="View Docket" Clicked="Docket_Clicked" FontSize="Large" Padding="3" FontAttributes="Bold" CornerRadius="5" Margin="3" BorderColor="Black" BorderWidth="1" BackgroundColor="#15C7C1"/>-->
- </StackLayout>
- </timesheets:BasePage.PageContent>
- </timesheets:BasePage>
|