From 9566025669b6b81a081a1a9f311f7b3615de5583 Mon Sep 17 00:00:00 2001 From: "gao.zhiyuan" Date: Tue, 13 Sep 2022 15:56:18 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=92=E8=89=B2=E7=AD=9B=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/app/lib/controllers/organization/index.js | 3 +++ api/app/lib/controllers/push/config.js | 21 +++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 api/app/lib/controllers/push/config.js diff --git a/api/app/lib/controllers/organization/index.js b/api/app/lib/controllers/organization/index.js index 36e2e70..7a158bf 100644 --- a/api/app/lib/controllers/organization/index.js +++ b/api/app/lib/controllers/organization/index.js @@ -110,6 +110,9 @@ async function user (ctx) { }, where: { deleted: false, + $not: { + role: { $contained: ['SuperAdmin', 'admin'] } + } }, order: [['updateTime', 'DESC']] } diff --git a/api/app/lib/controllers/push/config.js b/api/app/lib/controllers/push/config.js new file mode 100644 index 0000000..e38565f --- /dev/null +++ b/api/app/lib/controllers/push/config.js @@ -0,0 +1,21 @@ +'use strict'; + +async function edit (ctx) { + try { + const models = ctx.fs.dc.models; + + + + ctx.status = 204; + } catch (error) { + ctx.fs.logger.error(`path: ${ctx.path}, error: error`); + ctx.status = 400; + ctx.body = { + message: typeof error == 'string' ? error : undefined + } + } +} + +module.exports = { + edit +}; \ No newline at end of file