From 8634b6b46ed73a9f275150077939e57c56476cce Mon Sep 17 00:00:00 2001 From: Yuri Dimas Date: Wed, 5 Nov 2025 23:49:05 +0700 Subject: [PATCH] style: add page kategori sampah for dinas --- .../Controllers/KategoriSampahController.cs | 61 ++++++++++++++ Areas/Dinas/Views/KategoriSampah/Index.cshtml | 81 +++++++++++++++++++ Areas/Shared/Layouts/App/_Sidebar.cshtml | 4 +- 3 files changed, 144 insertions(+), 2 deletions(-) create mode 100644 Areas/Dinas/Controllers/KategoriSampahController.cs create mode 100644 Areas/Dinas/Views/KategoriSampah/Index.cshtml diff --git a/Areas/Dinas/Controllers/KategoriSampahController.cs b/Areas/Dinas/Controllers/KategoriSampahController.cs new file mode 100644 index 0000000..1b59888 --- /dev/null +++ b/Areas/Dinas/Controllers/KategoriSampahController.cs @@ -0,0 +1,61 @@ +using Microsoft.AspNetCore.Mvc; + +namespace BankSampahApp.Areas.Dinas.Controllers +{ + [Area("Dinas")] + [Route("Dinas/[controller]/[action]")] + public class KategoriSampahController : Controller + { + public IActionResult Index() + { + return View(); + } + + [HttpGet] + public IActionResult Table() + { + var data = new[] + { + new { + nama = "Kertas", + jenis_sampah = "Anorganik", + aksi = "
" + + "" + + "" + + "
", + }, + new { + nama = "Kardus", + jenis_sampah = "Anorganik", + aksi = "
" + + "" + + "" + + "
", + }, + new { + nama = "Plastik", + jenis_sampah = "Anorganik", + aksi = "
" + + "" + + "" + + "
", + }, + new { + nama = "Lain-lain", + jenis_sampah = "Anorganik", + aksi = "
" + + "" + + "" + + "
", + }, + }; + + var response = new + { + data = data + }; + + return Json(response); + } + } +} diff --git a/Areas/Dinas/Views/KategoriSampah/Index.cshtml b/Areas/Dinas/Views/KategoriSampah/Index.cshtml new file mode 100644 index 0000000..ccf2da7 --- /dev/null +++ b/Areas/Dinas/Views/KategoriSampah/Index.cshtml @@ -0,0 +1,81 @@ +@{ + ViewData["Title"] = "Kategori Sampah"; +} + +
+
+ + Kategori Sampah + +
+ +
+ +
+
+ +
+ +
+
+ + + + + + + + + + + +
NoKategori SampahJenis SampahAksi
+
+
+ + + + + + \ No newline at end of file diff --git a/Areas/Shared/Layouts/App/_Sidebar.cshtml b/Areas/Shared/Layouts/App/_Sidebar.cshtml index 1a98527..c3edabf 100644 --- a/Areas/Shared/Layouts/App/_Sidebar.cshtml +++ b/Areas/Shared/Layouts/App/_Sidebar.cshtml @@ -202,7 +202,7 @@
  • -
    +
    Master Data @@ -220,7 +220,7 @@
  • Mitra
  • Status Lahan
  • Jenis Sampah
  • -
  • Kategori Sampah
  • +
  • Kategori Sampah
  • Sub Kategori Sampah