Browse Source

Merge branch 'dev' of ssh://gitea.anxinyun.cn:2022/gao.zhiyuan/OperationalService into dev

dev
deartibers 2 years ago
parent
commit
59c020a25e
  1. 4
      api/app/lib/controllers/organization/index.js
  2. 2
      api/app/lib/controllers/project/index.js

4
api/app/lib/controllers/organization/index.js

@ -80,7 +80,7 @@ async function editUser (ctx) {
ctx.fs.logger.error(`path: ${ctx.path}, error: ${error}`);
ctx.status = 400;
ctx.body = {
message: typeof error == 'string' ? error : undefined
}
}
}
@ -96,7 +96,7 @@ async function putUser (ctx) {
}
})
if (existUserRes && existUserRes.role.includes('admin') && !disabled) {
if (existUserRes && existUserRes.role.includes('admin') && disabled == false) {
throw '成员不能既是管理员又是普通成员'
}

2
api/app/lib/controllers/project/index.js

@ -43,7 +43,7 @@ async function projectPManage (ctx) {
const models = ctx.fs.dc.models;
const { clickHouse } = ctx.app.fs
const projectRes = await clickHouse.projectManage.query(`SELECT * FROM t_project WHERE project_state = 4 ORDER BY id DESC`).toPromise()
const projectRes = await clickHouse.projectManage.query(`SELECT id, project_name FROM t_pim_project WHERE isdelete=0 ORDER BY id DESC`).toPromise()
ctx.status = 200;
ctx.body = projectRes

Loading…
Cancel
Save