From 6e91320c0703a627f7ba5813b3fefacb39175dac Mon Sep 17 00:00:00 2001 From: wxc <191104855@qq.com> Date: Thu, 17 Oct 2024 18:55:12 +0800 Subject: [PATCH] =?UTF-8?q?fit:=20=E9=A2=84=E8=AD=A6=E7=BA=BF=E7=B4=A2?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E3=80=82fit:=20=E4=BB=BB=E5=8A=A1=E5=88=86?= =?UTF-8?q?=E5=8F=91=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/sensitivePerception/model.ts | 23 +- src/api/sensitivePerception/modelClue.ts | 14 + src/api/system/dict.ts | 6 + src/api/system/police.ts | 6 + src/components/depart-tree-select.vue | 23 +- src/components/model-icon-picker.vue | 4 +- src/components/model-tree.vue | 92 ++++++ src/enums/appEnums.ts | 7 +- src/enums/dictEnums.ts | 13 +- src/layout/components/Header.vue | 4 +- src/permission.ts | 1 - src/router/routes.ts | 4 + src/views/Login.vue | 4 +- src/views/sensitivePerception/Model.vue | 275 ++++++++++++------ .../{ClueData.vue => ModelClue.vue} | 104 +++---- .../sensitivePerception/ModelClueTask.vue | 109 +++++++ src/views/system/Dict.vue | 15 + src/views/system/Holiday.vue | 3 +- src/views/system/Menu.vue | 4 +- src/views/system/Police.vue | 95 +++--- src/views/system/Role.vue | 139 +++++---- src/views/system/User.vue | 92 ++++-- vite.config.ts | 10 +- 23 files changed, 753 insertions(+), 294 deletions(-) create mode 100644 src/api/sensitivePerception/modelClue.ts create mode 100644 src/components/model-tree.vue rename src/views/sensitivePerception/{ClueData.vue => ModelClue.vue} (58%) create mode 100644 src/views/sensitivePerception/ModelClueTask.vue diff --git a/src/api/sensitivePerception/model.ts b/src/api/sensitivePerception/model.ts index e47cd84..d081f1a 100644 --- a/src/api/sensitivePerception/model.ts +++ b/src/api/sensitivePerception/model.ts @@ -2,14 +2,33 @@ import request from "@/api/request"; export function listModel(query) { return request.get({ - url: '/model', + url: '/models', query }); } +export function treeModel() { + return request.get({ + url: '/models/tree' + }); +} + export function addModel(body) { return request.post({ - url: '/model', + url: '/models', body }); +} + +export function updateModel(body) { + return request.put({ + url: '/models', + body + }); +} + +export function delModel(id) { + return request.del({ + url: `/models/${id}` + }); } \ No newline at end of file diff --git a/src/api/sensitivePerception/modelClue.ts b/src/api/sensitivePerception/modelClue.ts new file mode 100644 index 0000000..f8ad4fd --- /dev/null +++ b/src/api/sensitivePerception/modelClue.ts @@ -0,0 +1,14 @@ +import request from "@/api/request"; + +export function listModelClue(query) { + return request.get({ + url: `/model/clues`, + query + }); +} + +export function listTopModelClueRecords(modelId) { + return request.get({ + url: `/model/clue/records/${modelId}/top` + }); +} \ No newline at end of file diff --git a/src/api/system/dict.ts b/src/api/system/dict.ts index b66a796..8823149 100644 --- a/src/api/system/dict.ts +++ b/src/api/system/dict.ts @@ -21,6 +21,12 @@ export function updateDictType(body) { }); } +export function delDictType(id) { + return request.del({ + url: '/dict/' + id + }); +} + export function listDictDatas(query, dictType) { return request.get({ url: `/dict/${dictType}/dictData`, diff --git a/src/api/system/police.ts b/src/api/system/police.ts index 8cc64a5..bdbd0e4 100644 --- a/src/api/system/police.ts +++ b/src/api/system/police.ts @@ -21,6 +21,12 @@ export function updatePolice(body) { }); } +export function delPolice(id) { + return request.del({ + url: `/police/${id}` + }); +} + export function listPoliceAll(departId) { return request.get({ url: `/police/${departId}/all` diff --git a/src/components/depart-tree-select.vue b/src/components/depart-tree-select.vue index 14e14cc..1f34f26 100644 --- a/src/components/depart-tree-select.vue +++ b/src/components/depart-tree-select.vue @@ -1,11 +1,32 @@ \ No newline at end of file diff --git a/src/enums/appEnums.ts b/src/enums/appEnums.ts index 37e57a6..21b007d 100644 --- a/src/enums/appEnums.ts +++ b/src/enums/appEnums.ts @@ -9,8 +9,13 @@ export const MENU_ROOT_ID = 0; export const DICT_CONTENT_ROOT_ID = -1; +// 部门跟节点 +export const ROOT_DEPART_ID = '12630'; + // 状态 export enum Status { ENABLE = '1', DISABLE = '0' -} \ No newline at end of file +} + +export const WEEKS = ["一", "二", "三", "四", "五", "六", "日"]; \ No newline at end of file diff --git a/src/enums/dictEnums.ts b/src/enums/dictEnums.ts index 47f33e8..c6cf0d8 100644 --- a/src/enums/dictEnums.ts +++ b/src/enums/dictEnums.ts @@ -108,8 +108,15 @@ export enum SubjectiveAspect { OTHER = '3' } -// 分发周期 +// 分发方式 export enum DistributionMethod { - AUTO = '1', - MANUAL = '2' + NEGATIVE_DISTRIBUTE = '1', + DATA_SAVE = '2', + WARNING_NOTIFICATION = '3' +} + +// 分发周期 +export enum DistributionCycle { + DAY = 'day', + WEEKLY = 'weekly' } \ No newline at end of file diff --git a/src/layout/components/Header.vue b/src/layout/components/Header.vue index 3c01377..aab0254 100644 --- a/src/layout/components/Header.vue +++ b/src/layout/components/Header.vue @@ -16,10 +16,10 @@