RecTrans.xaml 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213
  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <timesheets:BasePage xmlns="http://xamarin.com/schemas/2014/forms"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
  4. x:Class="comal.timesheets.RecTrans"
  5. xmlns:material="clr-namespace:XF.Material.Forms.UI;assembly=XF.Material" xmlns:extensions="http://xamarin.com/schemas/2020/toolkit"
  6. xmlns:timesheets="clr-namespace:comal.timesheets"
  7. material:MaterialNavigationPage.AppBarColor="#a2006d"
  8. Title="Transfer Stock"
  9. >
  10. <timesheets:BasePage.ToolbarItems>
  11. <ToolbarItem x:Name="Save" Order="Primary" Priority="0" Clicked="SaveBatch_Clicked" IconImageSource="floppydisk.png"/>
  12. </timesheets:BasePage.ToolbarItems>
  13. <timesheets:BasePage.Content>
  14. <Grid Padding="2">
  15. <Grid.ColumnDefinitions>
  16. <ColumnDefinition Width="*"/>
  17. <ColumnDefinition Width="*"/>
  18. </Grid.ColumnDefinitions>
  19. <!--Left Column-->
  20. <Grid Grid.Column="0">
  21. <Grid.RowDefinitions>
  22. <RowDefinition Height="auto"/>
  23. <RowDefinition Height="auto"/>
  24. </Grid.RowDefinitions>
  25. <!--Top Left Issuing-->
  26. <Frame x:Name="issuingFrame"
  27. Grid.Row="0" Padding="0" BackgroundColor="WhiteSmoke" BorderColor="Black" CornerRadius="10">
  28. <Grid Padding="0">
  29. <Grid.RowDefinitions>
  30. <RowDefinition Height="40"/>
  31. <RowDefinition Height="60"/>
  32. <RowDefinition Height="40"/>
  33. </Grid.RowDefinitions>
  34. <!--Top row of frame-->
  35. <Label x:Name="issuingLocationLbl" Text="Issuing Location" VerticalOptions="Center" FontSize="Medium" TextColor="#008b8b"
  36. Grid.Row="0" Margin="2" FontAttributes="Bold" HorizontalOptions="Center"/>
  37. <!--Bottom row of frame-->
  38. <Label Grid.Row="2" Margin="2"
  39. x:Name="issuingLocationCountLbl" Text="Items: " HorizontalOptions="Center" VerticalOptions="Start"/>
  40. </Grid>
  41. </Frame>
  42. <extensions:Expander Grid.Row="0" x:Name="issuingExpander" VerticalOptions="Center" HorizontalOptions="FillAndExpand"
  43. extensions:CornerRadiusEffect.CornerRadius="10" Tapped="IssuingExpander_Tapped"
  44. BackgroundColor="#FFF5F5F5" Margin="3">
  45. <extensions:Expander.Header>
  46. <Frame CornerRadius="10" BackgroundColor="#15C7C1" BorderColor="Transparent" HorizontalOptions="Center">
  47. <Label Text="Choose" TextColor="White" BackgroundColor="Transparent">
  48. </Label>
  49. </Frame>
  50. </extensions:Expander.Header>
  51. <StackLayout>
  52. <Button Margin="2, 6, 2, 2" TextColor="White" BackgroundColor="#15C7C1" CornerRadius="10"
  53. Text="Search" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3"
  54. Clicked="ChooseIssuingLocationBtn_Clicked" x:Name="chooseIssuingLocationBtn"/>
  55. <Button Margin="2" TextColor="White" BackgroundColor="#15C7C1" CornerRadius="10" Clicked="IssuingFavourite_Clicked"
  56. Text="Favourite 1" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3"
  57. x:Name="issuingFavouriteBtn1"
  58. />
  59. <Button Margin="2" TextColor="White" BackgroundColor="#15C7C1" CornerRadius="10" Clicked="IssuingFavourite_Clicked"
  60. Text="Favourite 2" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3"
  61. x:Name="issuingFavouriteBtn2"
  62. />
  63. <Button Margin="2" TextColor="White" BackgroundColor="#15C7C1" CornerRadius="10" Clicked="IssuingFavourite_Clicked"
  64. Text="Favourite 3" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3"
  65. x:Name="issuingFavouriteBtn3"
  66. />
  67. </StackLayout>
  68. </extensions:Expander>
  69. <!--Left List-->
  70. <Frame Grid.Row="1" Padding="0" BackgroundColor="WhiteSmoke">
  71. <StackLayout>
  72. <Entry x:Name="searchEnt" Placeholder="Search" HorizontalTextAlignment="Center" TextChanged="SearchEnt_Changed"/>
  73. <ListView x:Name="issuingListView" HasUnevenRows="True">
  74. <ListView.ItemTemplate>
  75. <DataTemplate>
  76. <ViewCell Tapped="IssuingListView_Tapped">
  77. <Frame BorderColor="#15C7C1" Margin="2" CornerRadius="15" Padding="5" HasShadow="False">
  78. <Grid>
  79. <Grid.RowDefinitions>
  80. <RowDefinition Height="auto"/>
  81. <RowDefinition Height="auto"/>
  82. <RowDefinition Height="auto"/>
  83. <RowDefinition Height="auto"/>
  84. <RowDefinition Height="auto"/>
  85. <RowDefinition Height="auto"/>
  86. <RowDefinition Height="{Binding LastRowHeight}"/>
  87. </Grid.RowDefinitions>
  88. <Label Grid.Row="0" Text="{Binding Code}" FontAttributes="Bold" HorizontalOptions="Center"/>
  89. <Label Grid.Row="1" Text="{Binding Name}"/>
  90. <Label Grid.Row="2" Text="{Binding DisplayJob}"/>
  91. <Label Grid.Row="3" Text="{Binding DisplayFinish}"/>
  92. <Label Grid.Row="4" Text="{Binding DisplaySize}"/>
  93. <Label Grid.Row="5" Text="{Binding DisplayUnits}"/>
  94. <Image Grid.Row="6" IsVisible="{Binding ImageVisible}" Source="{Binding ImageSource}"/>
  95. </Grid>
  96. </Frame>
  97. </ViewCell>
  98. </DataTemplate>
  99. </ListView.ItemTemplate>
  100. </ListView>
  101. </StackLayout>
  102. </Frame>
  103. </Grid>
  104. <!--Right Column-->
  105. <Grid Grid.Column="1">
  106. <Grid.RowDefinitions>
  107. <RowDefinition Height="auto"/>
  108. <RowDefinition Height="auto"/>
  109. </Grid.RowDefinitions>
  110. <!--Top Right Receiving-->
  111. <Frame Grid.Row="0" x:Name="receivingFrame"
  112. Padding="0" BackgroundColor="WhiteSmoke" BorderColor="Black" CornerRadius="10">
  113. <Grid Padding="0">
  114. <Grid.RowDefinitions>
  115. <RowDefinition Height="40"/>
  116. <RowDefinition Height="60"/>
  117. <RowDefinition Height="40"/>
  118. </Grid.RowDefinitions>
  119. <!--Top row of frame-->
  120. <Label x:Name="receivingLocationLbl" Text="Receiving Location" VerticalOptions="Center" FontSize="Medium" TextColor="PaleVioletRed"
  121. Grid.Row="0" Margin="2" FontAttributes="Bold" HorizontalOptions="Center"/>
  122. <!--Bottom row of frame-->
  123. <Label Grid.Row="2" Margin="2"
  124. x:Name="receivingCountLbl" Text="Items in batch: " HorizontalOptions="Center" VerticalOptions="Start"/>
  125. </Grid>
  126. </Frame>
  127. <extensions:Expander Grid.Row="0" x:Name="receivingExpander" VerticalOptions="Center" HorizontalOptions="FillAndExpand"
  128. extensions:CornerRadiusEffect.CornerRadius="10" Tapped="ReceivingExpander_Tapped"
  129. BackgroundColor="#FFF5F5F5" Margin="3">
  130. <extensions:Expander.Header>
  131. <Frame CornerRadius="10" BackgroundColor="#9f4576" BorderColor="Transparent" HorizontalOptions="Center">
  132. <Label Text="Choose" TextColor="White" BackgroundColor="Transparent">
  133. </Label>
  134. </Frame>
  135. </extensions:Expander.Header>
  136. <StackLayout>
  137. <Button Margin="2, 6, 2, 2" TextColor="White" BackgroundColor="#9f4576" CornerRadius="10"
  138. Text="New / Search" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3"
  139. x:Name="chooseReceivingLocationBtn" Clicked="ChooseReceivingLocationBtn_Clicked"/>
  140. <Button Margin="2" TextColor="White" BackgroundColor="#9f4576" CornerRadius="10" x:Name="chooseJobBtn"
  141. Text="Job" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3" Clicked="JobBtn_Clicked"
  142. />
  143. <Button Margin="2" TextColor="White" BackgroundColor="#9f4576" CornerRadius="10" x:Name="receivingFavouriteBtn1"
  144. Text="Favourite 1" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3" Clicked="ReceivingFavourite_Clicked"
  145. />
  146. <Button Margin="2" TextColor="White" BackgroundColor="#9f4576" CornerRadius="10" x:Name="receivingFavouriteBtn2"
  147. Text="Favourite 2" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3" Clicked="ReceivingFavourite_Clicked"
  148. />
  149. <Button Margin="2" TextColor="White" BackgroundColor="#9f4576" CornerRadius="10" x:Name="receivingFavouriteBtn3"
  150. Text="Favourite 3" FontAttributes="Bold" HorizontalOptions="Center" VerticalOptions="Center" Padding="6,3,6,3" Clicked="ReceivingFavourite_Clicked"
  151. />
  152. </StackLayout>
  153. </extensions:Expander>
  154. <!--Right List-->
  155. <Frame Grid.Row="1" Padding="0" BackgroundColor="WhiteSmoke">
  156. <ListView x:Name="receivingListView" HasUnevenRows="True">
  157. <ListView.ItemTemplate>
  158. <DataTemplate>
  159. <ViewCell Tapped="ReceivingListView_Tapped">
  160. <Frame BorderColor="#c71585" Margin="2" CornerRadius="15" Padding="5" HasShadow="False">
  161. <Grid>
  162. <Grid.RowDefinitions>
  163. <RowDefinition Height="auto"/>
  164. <RowDefinition Height="auto"/>
  165. <RowDefinition Height="auto"/>
  166. <RowDefinition Height="auto"/>
  167. <RowDefinition Height="auto"/>
  168. <RowDefinition Height="auto"/>
  169. <RowDefinition Height="{Binding LastRowHeight}"/>
  170. </Grid.RowDefinitions>
  171. <Label Grid.Row="0" Text="{Binding Code}" FontAttributes="Bold" HorizontalOptions="Center"/>
  172. <Label Grid.Row="1" Text="{Binding Name}"/>
  173. <Label Grid.Row="2" Text="{Binding DisplayJob}"/>
  174. <Label Grid.Row="3" Text="{Binding DisplayFinish}"/>
  175. <Label Grid.Row="4" Text="{Binding DisplaySize}"/>
  176. <Label Grid.Row="5" Text="{Binding DisplayUnits}"/>
  177. <Image Grid.Row="6" IsVisible="{Binding ImageVisible}" Source="{Binding ImageSource}"/>
  178. </Grid>
  179. </Frame>
  180. </ViewCell>
  181. </DataTemplate>
  182. </ListView.ItemTemplate>
  183. </ListView>
  184. </Frame>
  185. </Grid>
  186. </Grid>
  187. </timesheets:BasePage.Content>
  188. </timesheets:BasePage>