public async Task <ApiResponse> GetSupplier(int id) { try { var vm = await _supplierServices.GetById(id); return(new ApiResponse() { code = 0, data = vm }); } catch (Exception ex) { return(new ApiResponse() { code = -1, message = ex.Message }); } }
public async Task <IActionResult> Edit(int?id) { var vm = await _supplierServices.GetById((int)id); return(View(vm)); }