public async Task <IResponseEntity> UpdateAsync(ApiEditRequest req) { if (req == null || req?.Id == "") { return(ResponseEntity.Error("更新的实体主键丢失")); } var entity = _mapper.Map <SysApiEntity>(req); await _sysApiRepository.UpdateAsync(entity); return(ResponseEntity.Ok("更新成功")); }
public async Task <IResponseEntity> Update(ApiEditRequest req) { return(await _sysApiService.UpdateAsync(req)); }