专家项目/专家BUG修改

master
王家东 4 weeks ago
parent eaa4753d75
commit d798e2d809
  1. 34
      jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/expert/controller/ExpertController.java
  2. 2
      jeecgboot-vue3/src/views/expert/self/Expert.api.ts
  3. 4
      jeecgboot-vue3/src/views/expert/self/ExpertList.vue

@ -400,6 +400,40 @@ public class ExpertController extends JeecgController<Expert, IExpertService> {
return Result.OK("编辑成功!");
}
/**
* 编辑
*
* @param expert
* @return
*/
@AutoLog(value = "专家管理(专家自己)-编辑")
@ApiOperation(value="专家管理(专家自己)-编辑", notes="专家管理(专家自己)-编辑")
@RequestMapping(value = "/editself", method = {RequestMethod.PUT,RequestMethod.POST})
public Result<String> editself(@RequestBody Expert expert) {
expert.setAdminopen("1");
expert.setIsdone("Y");
expert.setCompopen("1");
expertService.updateById(expert);
//开始添加到用户表
SysUser user = new SysUser();
user.setAvatar(expert.getTopPic());
user.setSex(expert.getSex());
user.setRealname(expert.getRealname());
user.setUsername(expert.getSeusername());
user.setWorkNo(expert.getWorkon());
user.setEmail(expert.getEmails());
user.setPhone(expert.getPhone());
user.setCreateTime(new Date());//设置创建时间
String salt = oConvertUtils.randomGen(8);
user.setSalt(salt);
String passwordEncode = PasswordUtil.encrypt(expert.getSeusername(), expert.getPsd(), salt);
user.setPassword(passwordEncode);
user.setStatus(1);
user.setDelFlag(CommonConstant.DEL_FLAG_0);
sysUserService.editUser(user,"1843478958968647681", expert.getSsdep(), "", "");
return Result.OK("编辑成功!");
}
/**
* 通过id删除
*

@ -6,7 +6,7 @@ const { createConfirm } = useMessage();
enum Api {
list = '/expert/expert/listself',
save='/expert/expert/add',
edit='/expert/expert/edit',
edit='/expert/expert/editself',
deleteOne = '/expert/expert/delete',
deleteBatch = '/expert/expert/deleteBatch',
importExcel = '/expert/expert/importExcel',

@ -215,14 +215,14 @@
{
label: '详情',
onClick: handleDetail.bind(null, record),
}, {
}/*, {
label: '删除',
popConfirm: {
title: '是否确认删除',
confirm: handleDelete.bind(null, record),
placement: 'topLeft',
},
}, {
}*/, {
label: '上报审核',
popConfirm: {
title: '请确定信息已完善',

Loading…
Cancel
Save