bank-sampah/Controllers/Master/PendampingController.cs

92 lines
3.9 KiB
C#

using Microsoft.AspNetCore.Mvc;
namespace BankSampahApp.Controllers.Master
{
[Route("Master/[controller]/[action]")]
public class PendampingController : Controller
{
public IActionResult Index()
{
return View("~/Views/Master/Pendamping/Index.cshtml");
}
public IActionResult Table(){
var data = new[]
{
new {
nama = "Andi Prabowo",
alamat = "Jl. Melati No. 12",
kelurahan = "Cipayung",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Siti Nurhaliza",
alamat = "Jl. Kenanga No. 5",
kelurahan = "Matraman",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Budi Santoso",
alamat = "Jl. Dahlia No. 8",
kelurahan = "Kramat Jati",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Nina Sari",
alamat = "Jl. Anggrek No. 7",
kelurahan = "Pulogadung",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Dewi Lestari",
alamat = "Jl. Flamboyan No. 22",
kelurahan = "Cakung",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Rudi Hartono",
alamat = "Jl. Mawar No. 33",
kelurahan = "Jatinegara",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Ratna Wijaya",
alamat = "Jl. Cempaka No. 10",
kelurahan = "Durensawit",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Fahri Setyawan",
alamat = "Jl. Teratai No. 15",
kelurahan = "Pasar Rebo",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Laras Putri",
alamat = "Jl. Padi Raya No. 9",
kelurahan = "Ciracas",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Agus Setiawan",
alamat = "Jl. Karet No. 20",
kelurahan = "Makassar",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
},
new {
nama = "Yuni Kartika",
alamat = "Jl. Cemara No. 3",
kelurahan = "Matraman",
aksi = "<a href=\"#\" class=\"btn btn-circle btn-warning text-white btn-sm\"><i class=\"ph ph-note-pencil\"></i></a>"
}
};
var response = new
{
data = data
};
return Json(response);
}
}
}