From fd15d0a29907750be0ebd2c1e99349579134fcde Mon Sep 17 00:00:00 2001 From: shilixia <2309368887@qq.com> Date: Tue, 23 Nov 2021 15:20:49 +0800 Subject: [PATCH] caozuo --- hb_client/.env.development | 4 +- hb_client/src/api/pm.js | 11 +- hb_client/src/api/wpm.js | 184 ++++ hb_client/src/router/index.js | 16 +- hb_client/src/views/wpm/operation.vue | 138 +++ hb_client/src/views/wpm/operationdo.vue | 792 ++++++++++++++++ hb_client/src/views/wpm/worktask.vue | 212 ++++- hb_client/src/views/wpm/worktaskcopy.vue | 1069 ++++++++++++++++++++++ 8 files changed, 2383 insertions(+), 43 deletions(-) create mode 100644 hb_client/src/views/wpm/operation.vue create mode 100644 hb_client/src/views/wpm/operationdo.vue create mode 100644 hb_client/src/views/wpm/worktaskcopy.vue diff --git a/hb_client/.env.development b/hb_client/.env.development index ef83e12..003a43c 100644 --- a/hb_client/.env.development +++ b/hb_client/.env.development @@ -2,8 +2,8 @@ ENV = 'development' # base api -VUE_APP_BASE_API = 'http://127.0.0.1:8000/api' -#VUE_APP_BASE_API = 'http://47.95.0.242:2222/api' +#VUE_APP_BASE_API = 'http://127.0.0.1:8000/api' +VUE_APP_BASE_API = 'http://47.95.0.242:2222/api' # vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable, diff --git a/hb_client/src/api/pm.js b/hb_client/src/api/pm.js index ec7fe91..2bc359d 100644 --- a/hb_client/src/api/pm.js +++ b/hb_client/src/api/pm.js @@ -80,4 +80,13 @@ export function createPick_need(id, data) { method: 'post', data }) -} \ No newline at end of file +} + +//生产进度表 +export function getprogressList(query) { + return request({ + url: '/pm/subproduction_progress/', + method: 'get', + params: query + }) +} diff --git a/hb_client/src/api/wpm.js b/hb_client/src/api/wpm.js index a36437f..a6f998a 100644 --- a/hb_client/src/api/wpm.js +++ b/hb_client/src/api/wpm.js @@ -68,4 +68,188 @@ export function wproductPutin(id, data) { data }) } +//车间领半成品 + + +export function getpickhalfList(id) { + return request({ + url: `/wpm/subplan/${id}/pick_half/`, + method: 'get' + }) +} + +//子计划半成品领料 +export function createpickhalf(id, data) { + return request({ + url: `/wpm/subplan/${id}/pick_half/`, + method: 'post', + data + }) +} + +//车间点击对应工序的子工序,创建操作记录 + + +export function createOperation(data) { + return request({ + url: '/wpm/operation/', + method: 'post', + data + }) +} + +//生产记录操作记录列表 + + +export function getoperationList(query) { + return request({ + url: '/wpm/operation/', + method: 'get', + params: query + }) +} + +//生产操作,提交边角料 +export function createoperation(id, data) { + return request({ + url: `/wpm/operation/${id}/`, + method: 'put', + data + }) +} + +//调取一条操作记录 +export function getoperation(id) { + return request({ + url: `/wpm/operation/${id}/`, + method: 'get' + }) +} + +//操作使用的半成品列表 +export function getoperationwproductList(query) { + return request({ + url: '/wpm/operation_wproduct/', + method: 'get', + params: query + }) +} +//操作半成品删除 +export function deleteOperationwproduct(id) { + return request({ + url: `/wpm/operation_wproduct/${id}/`, + method: 'delete', + }) +} + + +//删除操作记录 +export function deleteOperation(id) { + return request({ + url: `/wpm/operation/${id}/`, + method: 'delete', + }) +} + +//操作设备 +export function getequList(query) { + return request({ + url: '/wpm/operation_equip/', + method: 'get', + params: query + }) +} +//操作设备删除 +export function deleteOperationequip(id) { + return request({ + url: `/wpm/operation_equip​/${id}/`, + method: 'delete', + }) +} + + + +//操作自定义表 +export function getrecordList(query) { + return request({ + url: '/wpm/operation_record/', + method: 'get', + params: query + }) +} +//操作提交自定义表 +export function createRecord(id, data) { + return request({ + url: `/wpm/operation_record/${id}/submit/`, + method: 'post', + data + }) +} + +//操作消耗物料 + +export function getinputList(query) { + return request({ + url: '/wpm/operation_input/', + method: 'get', + params: query + }) +} + +//车间物料消耗 + + +export function createInput(data) { + return request({ + url: '/wpm/operation_input/', + method: 'post', + data + }) +} +//操作,产出物料 +export function getoutputList(query) { + return request({ + url: '/wpm/operation_output/', + method: 'get', + params: query + }) +} +//产出物料 + +export function createOutput(data) { + return request({ + url: '/wpm/operation_output/', + method: 'post', + data + }) +} + +//提交本次操作 + +export function submitOperation(id, data) { + return request({ + url: `/wpm/operation/${id}/submit/`, + method: 'post', + data + }) +} + +//操作,工序工装 +export function gettoolList(query) { + return request({ + url: '/wpm/operation_tool/', + method: 'get', + params: query + }) +} +//操作工序工装 + +export function createTool(data) { + return request({ + url: '/wpm/operation_tool/', + method: 'post', + data + }) +} + diff --git a/hb_client/src/router/index.js b/hb_client/src/router/index.js index 235fbd4..b4d5e84 100644 --- a/hb_client/src/router/index.js +++ b/hb_client/src/router/index.js @@ -179,12 +179,26 @@ export const asyncRoutes = [ name: 'pm', meta: { title: '生产执行', icon: 'example', perms: ['equipment_set'] }, children: [ - { + { path: 'worktask', name: 'worktask', component: () => import('@/views/wpm/worktask'), meta: { title: '车间任务', icon: 'example', perms: ['index_manage'] } }, + { + path: 'operation', + name: 'operation', + component: () => import('@/views/wpm/operation'), + meta: { title: '车间操作', icon: 'example', perms: ['index_manage'] } + } + , + { + path: 'operationdo', + name: 'operationdo', + component: () => import('@/views/wpm/operationdo'), + meta: { title: '车间操作跳转界面', icon: 'example', perms: ['index_manage'] }, + hidden: true + }, { path: 'need/:id', name: 'need', diff --git a/hb_client/src/views/wpm/operation.vue b/hb_client/src/views/wpm/operation.vue new file mode 100644 index 0000000..edb2cfe --- /dev/null +++ b/hb_client/src/views/wpm/operation.vue @@ -0,0 +1,138 @@ + + \ No newline at end of file diff --git a/hb_client/src/views/wpm/operationdo.vue b/hb_client/src/views/wpm/operationdo.vue new file mode 100644 index 0000000..e79aeff --- /dev/null +++ b/hb_client/src/views/wpm/operationdo.vue @@ -0,0 +1,792 @@ + + + + \ No newline at end of file diff --git a/hb_client/src/views/wpm/worktask.vue b/hb_client/src/views/wpm/worktask.vue index 3dcfa56..c78513e 100644 --- a/hb_client/src/views/wpm/worktask.vue +++ b/hb_client/src/views/wpm/worktask.vue @@ -60,7 +60,7 @@ -