You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

102 lines
4.6 KiB

1 year ago
  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
  4. x:Class="GMCabsDriverAssistantSolution.Views.CouponsV2Page"
  5. Title="{Binding Title}"
  6. Shell.FlyoutBehavior="Disabled">
  7. <ContentPage.Resources>
  8. <ResourceDictionary>
  9. <Color x:Key="Accent">#96d1ff</Color>
  10. </ResourceDictionary>
  11. </ContentPage.Resources>
  12. <ContentPage.Content>
  13. <StackLayout Orientation="Vertical"
  14. BackgroundColor="#DCDCDC">
  15. <Grid Margin="40,40,40,20">
  16. <Grid.ColumnDefinitions>
  17. <ColumnDefinition Width="4*"/>
  18. <ColumnDefinition Width="*"/>
  19. <ColumnDefinition Width="4*"/>
  20. </Grid.ColumnDefinitions>
  21. <Button
  22. x:Name="BackButton"
  23. Text="Back"
  24. ImageSource="back_arrow.png"
  25. Command="{Binding BackCouponCommand}"
  26. IsVisible="{Binding IsBackButton}"
  27. Grid.Row="0" Grid.Column="0"
  28. TextColor="Black"
  29. BackgroundColor="Transparent"
  30. BorderColor="Transparent"
  31. Visual="Default"/>
  32. <ImageButton
  33. Source="sync.png"
  34. HeightRequest="30"
  35. BackgroundColor="Transparent"
  36. HorizontalOptions="CenterAndExpand"
  37. Command="{Binding SyncCouponCommand}"
  38. Grid.Row="0" Grid.Column="1"/>
  39. <Button
  40. x:Name="NextButton"
  41. Text="Next"
  42. ImageSource="next_arrow.png"
  43. Command="{Binding NextCouponCommand}"
  44. IsVisible="{Binding IsNextButton}"
  45. Grid.Row="0" Grid.Column="2"
  46. TextColor="Black"
  47. BackgroundColor="Transparent"
  48. BorderColor="Transparent"
  49. Visual="Default"/>
  50. </Grid>
  51. <StackLayout IsVisible="{Binding HasCoupons}">
  52. <Frame
  53. HasShadow="True"
  54. BorderColor="DarkGray"
  55. CornerRadius="12"
  56. Margin="8"
  57. HorizontalOptions="Center"
  58. VerticalOptions="StartAndExpand"
  59. BackgroundColor="White">
  60. <StackLayout>
  61. <Grid HeightRequest="240"
  62. WidthRequest="240">
  63. <ActivityIndicator IsRunning="True"
  64. IsVisible="true"
  65. Scale="0.5"/>
  66. <Image
  67. Source="{Binding Image}"
  68. Aspect="AspectFit"
  69. HorizontalOptions="Center"
  70. Margin="8,0" />
  71. </Grid>
  72. <Label
  73. HorizontalOptions="Center">
  74. <Label.FormattedText>
  75. <FormattedString>
  76. <Span Text="Redemption Details"
  77. TextColor="Blue"
  78. TextDecorations="Underline"
  79. FontSize="20">
  80. <Span.GestureRecognizers>
  81. <TapGestureRecognizer Command="{Binding RedemptionDetails}"/>
  82. </Span.GestureRecognizers>
  83. </Span>
  84. </FormattedString>
  85. </Label.FormattedText>
  86. </Label>
  87. </StackLayout>
  88. </Frame>
  89. </StackLayout>
  90. <StackLayout IsVisible="{Binding HasEmptyMessage}">
  91. <Label Text="{Binding EmptyViewMessage}"
  92. FontSize="25"
  93. TextColor="Black"
  94. HorizontalOptions="Center"/>
  95. </StackLayout>
  96. <Button VerticalOptions="EndAndExpand"
  97. Margin="40,0,40,15"
  98. Text="View History"
  99. FontSize="20"
  100. Clicked="OnCouponHistoryViewClicked"/>
  101. </StackLayout>
  102. </ContentPage.Content>
  103. </ContentPage>