MobileGrid.xaml 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <ContentView xmlns="http://xamarin.com/schemas/2014/forms"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
  4. xmlns:grid="clr-namespace:Syncfusion.SfDataGrid.XForms;assembly=Syncfusion.SfDataGrid.XForms"
  5. xmlns:ui="clr-namespace:XF.Material.Forms.UI;assembly=XF.Material"
  6. xmlns:mobile="clr-namespace:InABox.Mobile;assembly=InABox.Mobile.Shared"
  7. xmlns:pull="clr-namespace:Syncfusion.SfPullToRefresh.XForms;assembly=Syncfusion.SfPullToRefresh.XForms"
  8. x:Class="InABox.Mobile.MobileGrid"
  9. x:DataType="mobile:MobileGrid"
  10. >
  11. <ContentView.Content>
  12. <Grid RowSpacing="0">
  13. <Grid.RowDefinitions>
  14. <RowDefinition Height="Auto"/>
  15. <RowDefinition Height="*"/>
  16. <RowDefinition Height="Auto"/>
  17. </Grid.RowDefinitions>
  18. <mobile:MobileSearchBar
  19. x:Name="Search"
  20. Grid.Row="0"
  21. IsVisible="true"
  22. PlaceHolder="Search"
  23. TextChanged="Search_OnTextChanged"
  24. BackgroundColor="Transparent"
  25. Margin="0,0,0,5"
  26. />
  27. <mobile:MobileCard
  28. Grid.Row="1"
  29. BackgroundColor="WhiteSmoke">
  30. <!-- <pull:SfPullToRefresh -->
  31. <!-- Refreshing="SfPullToRefresh_OnRefreshing" -->
  32. <!-- x:Name="pullToRefresh" -->
  33. <!-- IsRefreshing="False" -->
  34. <!-- PullingThreshold="100" -->
  35. <!-- RefreshContentHeight="0" -->
  36. <!-- RefreshContentThreshold="0" -->
  37. <!-- RefreshContentWidth="0" -->
  38. <!-- TransitionMode="Push"> -->
  39. <!-- -->
  40. <!-- <pull:SfPullToRefresh.PullableContent> -->
  41. <grid:SfDataGrid
  42. x:Name="Grid"
  43. AutoGenerateColumns="False"
  44. SelectionMode="Single"
  45. GridViewCreated="Grid_OnGridViewCreated"
  46. SelectionChanged="Grid_OnSelectionChanged"
  47. GridTapped="Grid_OnGridTapped"
  48. AllowPullToRefresh="True"
  49. >
  50. <grid:SfDataGrid.GridStyle>
  51. <grid:DefaultStyle
  52. GridCellBorderWidth="0"
  53. RowBackgroundColor="White"
  54. RowForegroundColor="Black"
  55. AlternatingRowColor="WhiteSmoke"
  56. SelectionBackgroundColor="Purple"
  57. SelectionForegroundColor="White"
  58. HeaderForegroundColor="DimGray"
  59. HeaderBackgroundColor="Transparent"
  60. HeaderCellBorderWidth="0"/>
  61. </grid:SfDataGrid.GridStyle>
  62. </grid:SfDataGrid>
  63. <!-- </pull:SfPullToRefresh.PullableContent> -->
  64. <!-- </pull:SfPullToRefresh> -->
  65. </mobile:MobileCard>
  66. <mobile:MobileCard
  67. Grid.Row="2"
  68. Margin="0,5,0,0"
  69. x:Name="_refreshgrid"
  70. Padding="5">
  71. <Grid>
  72. <Grid.ColumnDefinitions>
  73. <ColumnDefinition Width="*"/>
  74. <ColumnDefinition Width="Auto"/>
  75. <ColumnDefinition Width="*"/>
  76. </Grid.ColumnDefinitions>
  77. <Label
  78. x:Name="_lastupdate"
  79. Grid.Column="0"
  80. HorizontalTextAlignment="Start"
  81. FontSize="Micro"
  82. TextColor="Black"/>
  83. <Label
  84. x:Name="_numrecords"
  85. Grid.Column="1"
  86. HorizontalTextAlignment="Center"
  87. FontSize="Micro"
  88. TextColor="Black"/>
  89. <Label
  90. x:Name="_pulltorefresh"
  91. Grid.Column="2"
  92. HorizontalTextAlignment="End"
  93. FontSize="Micro"
  94. Text="Pull To Refresh"
  95. TextColor="Black"/>
  96. </Grid>
  97. </mobile:MobileCard>
  98. </Grid>
  99. </ContentView.Content>
  100. </ContentView>