From 98d2b3d20fc974ef675429104180a89357316d9b Mon Sep 17 00:00:00 2001 From: caoqianming Date: Mon, 27 Nov 2023 13:52:27 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20wpm=E6=B7=BB=E5=8A=A0=E4=BA=86=E5=85=B6?= =?UTF-8?q?=E4=BB=96=E6=97=A5=E5=BF=97=E7=94=A8=E4=BA=8E=E5=BD=95=E5=85=A5?= =?UTF-8?q?avg?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/model/wpm.js | 48 ++++++++------ src/config/route.js | 10 +++ src/views/wpm/otherlog.vue | 96 +++++++++++++++++++++++++++ src/views/wpm/otherlog_form.vue | 111 ++++++++++++++++++++++++++++++++ 4 files changed, 244 insertions(+), 21 deletions(-) create mode 100644 src/views/wpm/otherlog.vue create mode 100644 src/views/wpm/otherlog_form.vue diff --git a/src/api/model/wpm.js b/src/api/model/wpm.js index 6fca56e7..20bbb242 100644 --- a/src/api/model/wpm.js +++ b/src/api/model/wpm.js @@ -281,26 +281,32 @@ export default { `${config.API_URL}/wpm/wmaterial/batchs/`, data); } - }, + } }, - // //值班停机关系 - // stsflog: { - // list: { - // name: "值班停机关系", - // req: async function(data){ - // return await http.get( - // `${config.API_URL}/wpm/stsflog/`, - // data - // ); - // } - // }, - // update: { - // name: "值班停机关系更新", - // req: async function(id, data){ - // return await http.put( - // `${config.API_URL}/wpm/stsflog/${id}/`, - // data); - // } - // }, - // }, + otherlog:{ + list: { + name: "其他生产日志", + req: async function(data){ + return await http.get( + `${config.API_URL}/wpm/otherlog/`, + data + ); + } + }, + create: { + name: "创建", + req: async function(data){ + return await http.post( + `${config.API_URL}/wpm/otherlog/`, + data); + } + }, + delete: { + name: "删除", + req: async function(id){ + return await http.delete( + `${config.API_URL}/wpm/otherlog/${id}/`); + } + }, + } } \ No newline at end of file diff --git a/src/config/route.js b/src/config/route.js index 94bb261b..9bdd3ffb 100644 --- a/src/config/route.js +++ b/src/config/route.js @@ -808,6 +808,16 @@ const routes = [ "perms": ["wpm"] }, "component": "wpm/worktask2" + }, + { + "name": "otherlog", + "path": "/wpm/otherlog", + "meta": { + "title": "其他日志", + "icon": "el-icon-grid", + "perms": ["wpm"] + }, + "component": "wpm/otherlog" } ] }, diff --git a/src/views/wpm/otherlog.vue b/src/views/wpm/otherlog.vue new file mode 100644 index 00000000..a50e44d2 --- /dev/null +++ b/src/views/wpm/otherlog.vue @@ -0,0 +1,96 @@ + + \ No newline at end of file diff --git a/src/views/wpm/otherlog_form.vue b/src/views/wpm/otherlog_form.vue new file mode 100644 index 00000000..1474aa9e --- /dev/null +++ b/src/views/wpm/otherlog_form.vue @@ -0,0 +1,111 @@ + + + + \ No newline at end of file