Ejemplo n.º 1
0
        public async Task <IActionResult> UpdateIdeaWeight([FromBody] UpdateWeightInput input)
        {
            if (input.id == null || input.weight == null || input.weight < 20)
            {
                return(BadRequest("参数有误!"));
            }
            var entity = await _patVisitApp.GetForm(input.id);

            if (entity == null || string.IsNullOrEmpty(entity.F_Pid))
            {
                return(BadRequest("主键ID有误!"));
            }
            //修改干体重记录
            await _patientApp.UpdateWeight(entity.F_Pid, _usersService.GetCurrentUserId(), input.weight.ToFloat(2));

            return(Ok("操作成功"));
        }