Commit 5414fbd7a0d6188ede23534038bf3806392398e1

Authored by Administrator
1 parent 2de47257

change ds

Showing 1 changed file with 12 additions and 4 deletions   Show diff stats
src/Maps/Controllers/BusStopController.cs
... ... @@ -36,26 +36,34 @@ namespace Maps.Controllers
36 36 public async Task<IActionResult> Index()
37 37 {
38 38 var busStops = await _busStopDs.GetIndexListAsync();
  39 +
  40 + ListBusStopVm vm = new ListBusStopVm
  41 + {
  42 + BusStopEditDsM = busStops.ToList()
  43 + };
  44 +
  45 + return Json(vm);
  46 + }
  47 +
  48 + [HttpGet]
  49 + public async Task<IActionResult> Directory(){
39 50 var SurfaceType = await _surfaceTypeDs.GetSelectListAsync();
40 51 var StateCommon = await _stateCommonDs.GetSelectListAsync();
41 52 var Settlement = await _settlementDs.GetSelectListAsync();
42 53 var Road = await _roadDs.GetSelectListAsync();
43 54 var Region = await _regionDs.GetSelectListAsync();
44 55  
45   - ListBusStopVm vm = new ListBusStopVm
  56 + CreateBusStopVm vm = new CreateBusStopVm
46 57 {
47   - BusStopEditDsM = busStops.ToList(),
48 58 SurfaceTypeSelectListDsM = SurfaceType.ToList(),
49 59 StateCommonSelectListDsM = StateCommon.ToList(),
50 60 SettlementSelectListDsM = Settlement.ToList(),
51 61 RoadSelectListDsM = Road.ToList(),
52 62 RegionSelectListDsM = Region.ToList()
53 63 };
54   -
55 64 return Json(vm);
56 65 }
57 66  
58   -
59 67 // GET: BusStop/Details/5
60 68 public async Task<IActionResult> Details(int id)
61 69 {
... ...