public async Task <AppResponse <bool> > EditSurgeryProcedureAsync(long id, EditSurgeryProcedureInput input) { bool isSurgeryExist = await _systemtLookupsManager.IsSurgeryProcedureExistAsync(input.Name); if (isSurgeryExist) { return new AppResponse <bool> { IsSuccessful = false, StatusCode = StatusCodes.ENTITY_ALREADY_EXIST, StatusDescription = string.Format(L("NameExist"), L("SurgeryProcedure")) } } ; return(new AppResponse <bool> { Data = await _systemtLookupsManager.EditSurgeryProcedureAsync(id, input), IsSuccessful = true, StatusCode = StatusCodes.SUCCESS, StatusDescription = L("Updated") }); }
public async Task <IActionResult> EditSurgeryProcedureAsync(long id, [FromBody] EditSurgeryProcedureInput input) { AppResponse <bool> response = await _systemLookupsService.EditSurgeryProcedureAsync(id, input); return(Ok(response)); }