public async Task <IActionResult> EditDiagnose(Diagnose diagnose) { if (!ModelState.IsValid) { return(View(diagnose)); } var diagnoseModel = await _diagnoseService.Get(diagnose.UserId); if (diagnoseModel == null) { _diagnoseService.Add(diagnose); } else { await _diagnoseService.Update(diagnose); } return(Content("")); }
public async Task <OutputBase> Update([FromBody] Diagnose diagnose) { return(await _diagnoseService.Update(diagnose)); }