fix:更新用户修改

上级 afcfada0
......@@ -110,7 +110,10 @@ public class CsdnUserController {
@PostMapping("/update")
public Result update(@RequestBody CsdnUserInfoQuery query) {
CsdnUserInfo csdnUserInfo = new CsdnUserInfo();
BeanUtils.copyProperties(query, csdnUserInfo);
csdnUserInfo.setId(query.getId());
csdnUserInfo.setUserName(query.getUserName());
csdnUserInfo.setNickName(query.getNickName());
csdnUserInfo.setUserWeight(query.getUserWeight());
return Result.ok(this.csdnUserInfoService.updateById(csdnUserInfo));
}
......
......@@ -4,6 +4,10 @@ import lombok.Data;
@Data
public class CsdnUserInfoQuery {
/**
* 主键id
*/
private Integer id;
/**
* 用户code
*/
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册