From e7e2af2a65a6fb0c26bdde169967f321d633ab84 Mon Sep 17 00:00:00 2001 From: "kwan.nguyen" Date: Wed, 8 Jan 2025 20:14:50 +0700 Subject: [PATCH] add banner page --- .../{ => ApiResponse}/Pagination.cs | 4 +- PCUT/PCUT.Entities/Banner.cs | 13 ++ PCUT/PCUT/PCUT.csproj | 8 + .../BannerManagement/BannerViewPage.xaml | 149 ++++++++++++++++++ .../BannerManagement/BannerViewPage.xaml.cs | 83 ++++++++++ PCUT/PCUT/ViewModels/BannerViewModel.cs | 21 +++ 6 files changed, 276 insertions(+), 2 deletions(-) rename PCUT/PCUT.Entities/{ => ApiResponse}/Pagination.cs (86%) create mode 100644 PCUT/PCUT.Entities/Banner.cs create mode 100644 PCUT/PCUT/Pages/BannerManagement/BannerViewPage.xaml create mode 100644 PCUT/PCUT/Pages/BannerManagement/BannerViewPage.xaml.cs create mode 100644 PCUT/PCUT/ViewModels/BannerViewModel.cs diff --git a/PCUT/PCUT.Entities/Pagination.cs b/PCUT/PCUT.Entities/ApiResponse/Pagination.cs similarity index 86% rename from PCUT/PCUT.Entities/Pagination.cs rename to PCUT/PCUT.Entities/ApiResponse/Pagination.cs index b4b3cf3..0c07693 100644 --- a/PCUT/PCUT.Entities/Pagination.cs +++ b/PCUT/PCUT.Entities/ApiResponse/Pagination.cs @@ -3,9 +3,9 @@ using System; using System.Collections.Generic; using System.Text; -namespace PCUT.Entities +namespace PCUT.Entities.ApiResponse { - public class Pagination + public class Pagination { [JsonProperty("page")] public int Page { get; set; } diff --git a/PCUT/PCUT.Entities/Banner.cs b/PCUT/PCUT.Entities/Banner.cs new file mode 100644 index 0000000..1a8afb1 --- /dev/null +++ b/PCUT/PCUT.Entities/Banner.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace PCUT.Entities +{ + public class Banner + { + public string Id { get; set; } + public string Name { get; set; } + public string Content { get; set; } + } +} diff --git a/PCUT/PCUT/PCUT.csproj b/PCUT/PCUT/PCUT.csproj index 65efcbb..b42d793 100644 --- a/PCUT/PCUT/PCUT.csproj +++ b/PCUT/PCUT/PCUT.csproj @@ -186,6 +186,9 @@ AppOutdatedDialog.xaml + + BannerViewPage.xaml + CategoryUpsertDialog.xaml @@ -253,6 +256,7 @@ UserListPage.xaml + @@ -363,6 +367,10 @@ Designer MSBuild:Compile + + Designer + MSBuild:Compile + Designer MSBuild:Compile diff --git a/PCUT/PCUT/Pages/BannerManagement/BannerViewPage.xaml b/PCUT/PCUT/Pages/BannerManagement/BannerViewPage.xaml new file mode 100644 index 0000000..f2c139f --- /dev/null +++ b/PCUT/PCUT/Pages/BannerManagement/BannerViewPage.xaml @@ -0,0 +1,149 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +