Compare commits
	
		
			58 Commits
		
	
	
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
|  | 037071350a | ||
|  | 56f59f533d | ||
|  | d9559db959 | ||
| 8966dec79a | |||
| 9513fb484b | |||
| 68193ecfb3 | |||
| 5a42c80256 | |||
| 0cd8970053 | |||
| 597934be2e | |||
| fcb01aaa4b | |||
| 93be36708d | |||
| 80439e7e01 | |||
| 6a338438bf | |||
| e74632e5fa | |||
| 21d7a8f7eb | |||
|  | 6d2311be44 | ||
|  | 3eac46beeb | ||
|  | 64c27487c5 | ||
| 14bf2dc2f6 | |||
| de1a7835e1 | |||
| e023b9c23e | |||
| 6e18a42c03 | |||
| 7e6881ff74 | |||
| 7c6d7b63e3 | |||
| bb4f3e2c0e | |||
| c4e7af8fba | |||
| 0338bf1a15 | |||
| aa15b551fb | |||
| 5fadd533de | |||
| f2c038d543 | |||
| 30cfedec07 | |||
| 898803c514 | |||
| 4af403b22b | |||
|  | 2628c14e99 | ||
|  | fe1c64845e | ||
|  | d47343af69 | ||
|  | b800893ea5 | ||
| f3f1c972b4 | |||
| fb496d8a97 | |||
|  | aa94abd681 | ||
| 2455f83b74 | |||
| 9006efdb67 | |||
|  | ce4bf752f0 | ||
|  | 16610e1390 | ||
| 8f01c92374 | |||
| d07e209936 | |||
| 975d14c886 | |||
| b0f0582e51 | |||
| 602af58f2d | |||
| 7bc184c9c7 | |||
| 9673c1ba30 | |||
| 66fce549e1 | |||
| 1b6ffddcf9 | |||
| 14bf2bd17e | |||
| bb6925f3a2 | |||
|  | 433c86a379 | ||
| 31c9929245 | |||
| dcc267ab9c | 
| @@ -12,7 +12,7 @@ steps: | ||||
|   - name: dockerconfig | ||||
|     path: /root/.docker | ||||
|   commands: | ||||
|   - docker build -t harbor.picaiba.com/mes/mes-cigs-ui ./ && docker push harbor.picaiba.com/mes/mes-cigs-ui | ||||
|   - docker build -t harbor.picaiba.com/kszny/wms-ui:00a-1.0.0 ./ && docker push harbor.picaiba.com/kszny/wms-ui:00a-1.0.0 | ||||
|  | ||||
| - name: deploy | ||||
|   image: harbor.picaiba.com/tools/kubectl:1.19.8 | ||||
| @@ -20,9 +20,9 @@ steps: | ||||
|   - echo "172.27.0.20 lb.kubesphere.local" >> /etc/hosts | ||||
|   #- echo "52.74.223.119 github.com" >> /etc/hosts | ||||
|   - sleep 1 | ||||
|   - kubectl scale --replicas=0 deployment/mes-ui -n mes-cigs | ||||
|   - kubectl scale --replicas=0 deployment/a-wms-ui -n wms | ||||
|   - sleep 3 | ||||
|   - kubectl scale --replicas=1 deployment/mes-ui -n mes-cigs | ||||
|   - kubectl scale --replicas=1 deployment/a-wms-ui -n wms | ||||
|   depends_on: | ||||
|   - build | ||||
|  | ||||
|   | ||||
| @@ -2,6 +2,6 @@ | ||||
| ENV = 'production' | ||||
|  | ||||
| # base api | ||||
| VUE_APP_BASE_API = '/api' | ||||
| VUE_APP_BASE_API = '' | ||||
| VUE_APP_REPORT_DESIGN_URL = '/ureport/designer' | ||||
| VUE_APP_REPORT_VIEW_URL = '/ureport/preview' | ||||
| VUE_APP_REPORT_VIEW_URL = '/ureport/preview' | ||||
|   | ||||
| @@ -1,9 +1,7 @@ | ||||
| FROM node:12 AS builder | ||||
| WORKDIR /app | ||||
| ADD package.json /app/ | ||||
| RUN npm install \ | ||||
|     --registry=https://registry.npm.taobao.org \ | ||||
|     --disturl=https://npm.taobao.org/dist | ||||
| RUN npm config set registry https://registry.npmmirror.com && npm install git+https://gitee.com/shihairong/raphael && npm install  | ||||
| ADD . /app | ||||
| RUN npm run build:prod | ||||
|  | ||||
|   | ||||
| @@ -66,6 +66,7 @@ | ||||
|     "nprogress": "0.2.0", | ||||
|     "outlayer": "^2.1.1", | ||||
|     "path-to-regexp": "2.4.0", | ||||
|     "raphael": "git+https://gitee.com/shihairong/raphael", | ||||
|     "screenfull": "4.2.0", | ||||
|     "script-loader": "0.7.2", | ||||
|     "showdown": "1.9.0", | ||||
|   | ||||
| @@ -2,42 +2,42 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function list(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/page', | ||||
|     url: '/api/process/process-flow/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function getInfo(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/get', | ||||
|     url: '/api/process/process-flow/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function enabled(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/enabled', | ||||
|     url: '/api/process/process-flow/enabled', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function del(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/delete', | ||||
|     url: '/api/process/process-flow/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function update(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/update', | ||||
|     url: '/api/process/process-flow/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function add(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/add', | ||||
|     url: '/api/process/process-flow/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -45,7 +45,7 @@ export function add(data) { | ||||
| // 获取基板列表 | ||||
| export function listSubstrate(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/substrateList', | ||||
|     url: '/api/process/process-flow/substrateList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -53,7 +53,7 @@ export function listSubstrate(data) { | ||||
| // 获取BOM列表 | ||||
| export function listBom(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/bomList', | ||||
|     url: '/api/process/process-flow/bomList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -70,7 +70,7 @@ export function listEquipmentBom(data) { | ||||
| // 获取所有设备的bom | ||||
| export function listAllEquipmentBom(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow-equipment/allEquipmentBomList', | ||||
|     url: '/api/process/process-flow-equipment/allEquipmentBomList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -86,7 +86,7 @@ export function listEquipmentRecipe(data) { | ||||
| // 获取所有设备下的配方 | ||||
| export function listAllEquipmentRecipe(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow-equipment/allEquipmentRecipeList', | ||||
|     url: '/api/process/process-flow-equipment/allEquipmentRecipeList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -94,7 +94,7 @@ export function listAllEquipmentRecipe(data) { | ||||
| // 保存某个工艺下的所有节点 | ||||
| export function addProcessFlows(data) { | ||||
|   return request({ | ||||
|     url: 'process/process-flow-equipment/add', | ||||
|     url: '/api/process/process-flow-equipment/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -102,7 +102,7 @@ export function addProcessFlows(data) { | ||||
| // 获取工艺流程下所有节点 | ||||
| export function listProcessFlowNode(data) { | ||||
|   return request({ | ||||
|     url: '/process/process-flow-equipment/list', | ||||
|     url: '/api/process/process-flow-equipment/list', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -111,7 +111,7 @@ export function listProcessFlowNode(data) { | ||||
| // 获取工序列表 | ||||
| export function listProcess(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/list', | ||||
|     url: '/api/process/work-sequence/list', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -120,7 +120,7 @@ export function listProcess(data) { | ||||
| // 获取工艺自动code | ||||
| export function getCode() { | ||||
|   return request({ | ||||
|     url: '/process/process-flow/getCode', | ||||
|     url: '/api/process/process-flow/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|   | ||||
| @@ -1,8 +1,8 @@ | ||||
| /* | ||||
|  * @Author: gtz | ||||
|  * @Date: 2021-04-06 20:20:10 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-07 16:14:47 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-25 09:04:24 | ||||
|  * @Description: file content | ||||
|  */ | ||||
|  | ||||
| @@ -10,7 +10,7 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function list(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/page', | ||||
|     url: '/api/process/work-sequence/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -18,7 +18,7 @@ export function list(data) { | ||||
|  | ||||
| export function getInfo(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/get', | ||||
|     url: '/api/process/work-sequence/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -26,7 +26,7 @@ export function getInfo(data) { | ||||
|  | ||||
| export function del(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/delete', | ||||
|     url: '/api/process/work-sequence/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -34,7 +34,7 @@ export function del(data) { | ||||
|  | ||||
| export function update(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/update', | ||||
|     url: '/api/process/work-sequence/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -42,7 +42,7 @@ export function update(data) { | ||||
|  | ||||
| export function add(data) { | ||||
|   return request({ | ||||
|     url: '/process/work-sequence/add', | ||||
|     url: '/api/process/work-sequence/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-27 16:42:27 | ||||
|  * @LastEditTime: 2022-01-11 16:16:07 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function areaList(data) { // 获取缓存区区域信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/area/page', | ||||
|     url: '/api/wms/area/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function areaList(data) { // 获取缓存区区域信息列表 | ||||
|  | ||||
| export function areaDetail(id) { // 获取缓存区区域信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/area/get', | ||||
|     url: '/api/wms/area/getById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function areaDetail(id) { // 获取缓存区区域信息单条数据 | ||||
|  | ||||
| export function areaUpdate(data) { // 更新缓存区区域信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/area/update', | ||||
|     url: '/api/wms/area/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function areaUpdate(data) { // 更新缓存区区域信息单条数据 | ||||
|  | ||||
| export function areaAdd(data) { // 新增缓存区区域信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/area/add', | ||||
|     url: '/api/wms/area/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function areaAdd(data) { // 新增缓存区区域信息单条数据 | ||||
|  | ||||
| export function areaCode() { // 获取缓存区区域信息code | ||||
|   return request({ | ||||
|     url: '/basic/area/get-code', | ||||
|     url: '/api/wms/area/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function areaDelete(id) { // 删除缓存区区域信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/area/delete', | ||||
|     url: '/api/wms/area/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-20 15:31:32 | ||||
|  * @LastEditTime: 2022-01-11 15:50:42 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function cacheList(data) { // 获取缓存区信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/cache/page', | ||||
|     url: '/api/wms/area/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function cacheList(data) { // 获取缓存区信息列表 | ||||
|  | ||||
| export function cacheDetail(id) { // 获取缓存区信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/cache/get', | ||||
|     url: '/api/wms/area/getById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function cacheDetail(id) { // 获取缓存区信息单条数据 | ||||
|  | ||||
| export function cacheUpdate(data) { // 更新缓存区信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/cache/update', | ||||
|     url: '/api/wms/area/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function cacheUpdate(data) { // 更新缓存区信息单条数据 | ||||
|  | ||||
| export function cacheAdd(data) { // 新增缓存区信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/cache/add', | ||||
|     url: '/api/wms/area/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function cacheAdd(data) { // 新增缓存区信息单条数据 | ||||
|  | ||||
| export function cacheCode() { // 获取缓存区信息code | ||||
|   return request({ | ||||
|     url: '/basic/cache/get-code', | ||||
|     url: '/api/wms/area/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function cacheDelete(id) { // 删除缓存区信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/cache/delete', | ||||
|     url: '/api/wms/area/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -9,7 +9,7 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function shelfList(data) { // 获取货架信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/shelf/page', | ||||
|     url: '/api/wms/area/shelf', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function shelfList(data) { // 获取货架信息列表 | ||||
|  | ||||
| export function shelfDetail(id) { // 获取货架信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/shelf/get', | ||||
|     url: '/api/wms/area/shelfById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,8 @@ export function shelfDetail(id) { // 获取货架信息单条数据 | ||||
|  | ||||
| export function shelfUpdate(data) { // 更新货架信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/shelf/update', | ||||
|     // url: '/basic/shelf/update', | ||||
|     url: '/api/wms/area/updateshelf', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +34,7 @@ export function shelfUpdate(data) { // 更新货架信息单条数据 | ||||
|  | ||||
| export function shelfAdd(data) { // 新增货架信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/shelf/add', | ||||
|     url: '/api/wms/area/addshelf', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +42,14 @@ export function shelfAdd(data) { // 新增货架信息单条数据 | ||||
|  | ||||
| export function shelfCode() { // 获取货架信息code | ||||
|   return request({ | ||||
|     url: '/basic/shelf/get-code', | ||||
|     url: '/api/wms/area/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function shelfDelete(id) { // 删除货架信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/shelf/delete', | ||||
|     url: '/api/wms/area/deleteshelf', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 14:29:10 | ||||
|  * @LastEditTime: 2022-01-11 16:43:22 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function storageBoxList(data) { // 获取存储箱列表 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/page', | ||||
|     url: '/api/wms/storagebox/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function storageBoxList(data) { // 获取存储箱列表 | ||||
|  | ||||
| export function storageBoxDetail(id) { // 获取存储箱单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/get', | ||||
|     url: '/api/wms/storagebox/getById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function storageBoxDetail(id) { // 获取存储箱单条数据 | ||||
|  | ||||
| export function storageBoxUpdate(data) { // 更新存储箱单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/update', | ||||
|     url: '/api/wms/storagebox/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function storageBoxUpdate(data) { // 更新存储箱单条数据 | ||||
|  | ||||
| export function storageBoxAdd(data) { // 新增存储箱单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/add', | ||||
|     url: '/api/wms/storagebox/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function storageBoxAdd(data) { // 新增存储箱单条数据 | ||||
|  | ||||
| export function storageBoxCode() { // 获取存储箱code | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/get-code', | ||||
|     url: '/api/wms/storagebox/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function storageBoxDelete(id) { // 删除存储箱单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank/delete', | ||||
|     url: '/api/wms/storagebox/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -56,14 +56,14 @@ export function storageBoxDelete(id) { // 删除存储箱单条数据 | ||||
|  | ||||
| export function PositionDetailInfoAdd(data) { // 新增存储箱地址单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank-site/add', | ||||
|     url: '/api/wms/storagebox/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function PositionDetailInfoList(data) { // 获取存储箱地址列表 | ||||
|   return request({ | ||||
|     url: '/basic/storage-tank-site/page', | ||||
|     url: '/api/wms/storagebox-site/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -10,7 +10,8 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function equipmentGroupList(data) { // 获取设备分组列表 | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-group/findAll', | ||||
|     // url: '/equipment/equipment-group/findAll', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-03-12 09:40:01 | ||||
|  * @LastEditTime: 2022-01-10 17:00:16 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function equipmentInfoList(data) { // 获取设备信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/equipment/page', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function equipmentInfoList(data) { // 获取设备信息列表 | ||||
|  | ||||
| export function equipmentInfoDetail(id) { // 获取设备信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment/get', | ||||
|     url: '/api/wms/equipment/get', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function equipmentInfoDetail(id) { // 获取设备信息单条数据 | ||||
|  | ||||
| export function equipmentInfoUpdate(data) { // 更新设备信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment/update', | ||||
|     url: '/api/wms/equipment/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function equipmentInfoUpdate(data) { // 更新设备信息单条数据 | ||||
|  | ||||
| export function equipmentInfoAdd(data) { // 新增设备信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment/add', | ||||
|     url: '/api/wms/equipment/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function equipmentInfoAdd(data) { // 新增设备信息单条数据 | ||||
|  | ||||
| export function equipmentInfoCode() { // 获取设备信息code | ||||
|   return request({ | ||||
|     url: '/basic/equipment/get-code', | ||||
|     url: '/api/wms/equipment/getCode', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function equipmentInfoDelete(id) { // 删除设备信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment/delete', | ||||
|     url: '/api/wms/equipment/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -56,7 +56,7 @@ export function equipmentInfoDelete(id) { // 删除设备信息单条数据 | ||||
|  | ||||
| export function equipmentInfoFileAdd(data) { // 设备信息上传 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-file/update-file', | ||||
|     url: '/api/wms/equipment-file/update-file', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -64,8 +64,10 @@ export function equipmentInfoFileAdd(data) { // 设备信息上传 | ||||
|  | ||||
| export function getEquipmentInfoFile(data) { // 设备信息下载 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-file/get-by-param', | ||||
|     method: 'post', | ||||
|     // url: '/api/wms/equipment-file/get-by-param', | ||||
|     url: '/api/common/attachment/downloadFile', | ||||
|     // method: 'post', | ||||
|     method: 'get', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|   | ||||
| @@ -9,7 +9,8 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function equipmentInfoAttrList(data) { // 获取设备属性列表 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-attr/page', | ||||
|     // url: '/basic/equipment-attr/page', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +18,8 @@ export function equipmentInfoAttrList(data) { // 获取设备属性列表 | ||||
|  | ||||
| export function equipmentInfoAttrDetail(id) { // 获取设备属性单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-attr/get', | ||||
|     // url: '/basic/equipment-attr/get', | ||||
|     url: '/api/wms/equipment/attrById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -9,7 +9,8 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function equipmentTypeList(data) { // 获取设备类型列表 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-type/page', | ||||
|     // url: '/basic/equipment-type/page', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-06 11:10:22 | ||||
|  * @LastEditTime: 2022-03-03 13:46:55 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function EquipmentScrapGradeList(data) { // 获取废片等级列表 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/pageForEquipmentGrade', | ||||
|     url: '/api/wms/equipment-scraps-grade/pageForEquipmentGrade', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function EquipmentScrapGradeList(data) { // 获取废片等级列表 | ||||
|  | ||||
| export function EquipmentScrapGradeDetail(id) { // 获取废片等级单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/get', | ||||
|     url: '/api/wms/equipment-scraps-grade/get', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function EquipmentScrapGradeDetail(id) { // 获取废片等级单条数 | ||||
|  | ||||
| export function EquipmentScrapGradeUpdate(data) { // 更新废片等级单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/update', | ||||
|     url: '/api/wms/equipment-scraps-grade/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function EquipmentScrapGradeUpdate(data) { // 更新废片等级单条数 | ||||
|  | ||||
| export function EquipmentScrapGradeAdd(data) { // 新增废片等级单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/add', | ||||
|     url: '/api/wms/equipment-scraps-grade/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,7 +41,7 @@ export function EquipmentScrapGradeAdd(data) { // 新增废片等级单条数据 | ||||
|  | ||||
| export function EquipmentScrapGradeDelete(id) { // 删除废片等级单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/delete', | ||||
|     url: '/api/wms/equipment-scraps-grade/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -1,8 +1,8 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-17 16:04:51 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 15:10:05 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
| @@ -56,7 +56,7 @@ export function staffDelete(id) { // 删除员工单条数据 | ||||
|  | ||||
| export function workerList(data) { // 添加组员列表 | ||||
|   return request({ | ||||
|     url: '/basic/team-det/workerList', | ||||
|     url: '/api/wms/team-det/workerList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -64,7 +64,7 @@ export function workerList(data) { // 添加组员列表 | ||||
|  | ||||
| export function getRoleList() { | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataListByPage', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       dictTypeId: '1383318968677273601', | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-15 16:03:31 | ||||
|  * @LastEditTime: 2022-02-24 08:57:40 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function materialList(data) { // 获取物料信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/material/page', | ||||
|     url: '/api/wms/material/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function materialList(data) { // 获取物料信息列表 | ||||
|  | ||||
| export function materialDetail(id) { // 获取物料信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material/get', | ||||
|     url: '/api/wms/material/get', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function materialDetail(id) { // 获取物料信息单条数据 | ||||
|  | ||||
| export function materialUpdate(data) { // 更新物料信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material/update', | ||||
|     url: '/api/wms/material/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function materialUpdate(data) { // 更新物料信息单条数据 | ||||
|  | ||||
| export function materialAdd(data) { // 新增物料信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material/add', | ||||
|     url: '/api/wms/material/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function materialAdd(data) { // 新增物料信息单条数据 | ||||
|  | ||||
| export function materialCode() { // 获取物料信息code | ||||
|   return request({ | ||||
|     url: '/basic/material/get-code', | ||||
|     url: '/api/wms/material/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function materialDelete(id) { // 删除物料信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material/delete', | ||||
|     url: '/api/wms/material/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-16 12:09:29 | ||||
|  * @LastEditTime: 2022-02-24 14:46:16 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function materialAttrList(data) { // 获取物料属性列表 | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/page', | ||||
|     url: '/api/wms/material-attr/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function materialAttrList(data) { // 获取物料属性列表 | ||||
|  | ||||
| export function materialAttrDetail(id) { // 获取物料属性单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/get', | ||||
|     url: '/api/wms/material-attr/get', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function materialAttrDetail(id) { // 获取物料属性单条数据 | ||||
|  | ||||
| export function materialAttrUpdate(data) { // 更新物料属性单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/update', | ||||
|     url: '/api/wms/material-attr/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function materialAttrUpdate(data) { // 更新物料属性单条数据 | ||||
|  | ||||
| export function materialAttrAdd(data) { // 新增物料属性单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/add', | ||||
|     url: '/api/wms/material-attr/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function materialAttrAdd(data) { // 新增物料属性单条数据 | ||||
|  | ||||
| export function materialAttrCode() { // 获取物料属性code | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/get-code', | ||||
|     url: '/api/wms/material-attr/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function materialAttrDelete(id) { // 删除物料属性单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-attr/delete', | ||||
|     url: '/api/wms/material-attr/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-16 11:52:14 | ||||
|  * @LastEditTime: 2022-02-24 14:46:20 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function materialsTypeList(data) { // 获取物料类型列表 | ||||
|   return request({ | ||||
|     url: '/basic/material-type/page', | ||||
|     url: '/api/wms/material-type/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function materialsTypeList(data) { // 获取物料类型列表 | ||||
|  | ||||
| export function materialsTypeDetail(id) { // 获取物料类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-type/get', | ||||
|     url: '/api/wms/material-type/get', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function materialsTypeDetail(id) { // 获取物料类型单条数据 | ||||
|  | ||||
| export function materialsTypeUpdate(data) { // 更新物料类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-type/update', | ||||
|     url: '/api/wms/material-type/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function materialsTypeUpdate(data) { // 更新物料类型单条数据 | ||||
|  | ||||
| export function materialsTypeAdd(data) { // 新增物料类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-type/add', | ||||
|     url: '/api/wms/material-type/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,14 +41,14 @@ export function materialsTypeAdd(data) { // 新增物料类型单条数据 | ||||
|  | ||||
| export function materialsTypeCode() { // 获取物料类型code | ||||
|   return request({ | ||||
|     url: '/basic/material-type/get-code', | ||||
|     url: '/api/wms/material-type/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function materialsTypeDelete(id) { // 删除物料类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/material-type/delete', | ||||
|     url: '/api/wms/material-type/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-03-10 14:25:18 | ||||
|  * @LastEditTime: 2022-03-03 13:46:40 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function scrapInfoList(data) { // 获取报废信息列表 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/page', | ||||
|     url: '/api/wms/scrap-information/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -20,7 +20,7 @@ export function scrapInfoDetail(id) { // 获取报废信息单条数据 | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/get', | ||||
|     url: '/api/wms/scrap-information/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -28,7 +28,7 @@ export function scrapInfoDetail(id) { // 获取报废信息单条数据 | ||||
|  | ||||
| export function scrapInfoUpdate(data) { // 更新报废信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/update', | ||||
|     url: '/api/wms/scrap-information/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -36,7 +36,7 @@ export function scrapInfoUpdate(data) { // 更新报废信息单条数据 | ||||
|  | ||||
| export function scrapInfoAdd(data) { // 新增报废信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/add', | ||||
|     url: '/api/wms/scrap-information/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -44,14 +44,14 @@ export function scrapInfoAdd(data) { // 新增报废信息单条数据 | ||||
|  | ||||
| export function scrapInfoCode() { // 获取报废信息code | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/get-code', | ||||
|     url: '/api/wms/scrap-information/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function scrapInfoDelete(id) { // 删除报废信息单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/delete', | ||||
|     url: '/api/wms/scrap-information/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-03-10 14:25:59 | ||||
|  * @LastEditTime: 2022-03-03 13:46:46 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function scrapTypeList(data) { // 获取报废类型列表 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/page', | ||||
|     url: '/api/wms/scrap-type-information/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -20,7 +20,7 @@ export function scrapTypeDetail(id) { // 获取报废类型单条数据 | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/get', | ||||
|     url: '/api/wms/scrap-type-information/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -28,7 +28,7 @@ export function scrapTypeDetail(id) { // 获取报废类型单条数据 | ||||
|  | ||||
| export function scrapTypeUpdate(data) { // 更新报废类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/update', | ||||
|     url: '/api/wms/scrap-type-information/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -36,7 +36,7 @@ export function scrapTypeUpdate(data) { // 更新报废类型单条数据 | ||||
|  | ||||
| export function scrapTypeAdd(data) { // 新增报废类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/add', | ||||
|     url: '/api/wms/scrap-type-information/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -44,14 +44,14 @@ export function scrapTypeAdd(data) { // 新增报废类型单条数据 | ||||
|  | ||||
| export function scrapTypeCode() { // 获取报废类型code | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/get-code', | ||||
|     url: '/api/wms/scrap-type-information/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function scrapTypeDelete(id) { // 删除报废类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/scrap-type-information/delete', | ||||
|     url: '/api/wms/scrap-type-information/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-01-13 16:11:45 | ||||
|  * @LastEditTime: 2022-03-03 16:10:54 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function StateConfigList(data) { // 获取状态列表 | ||||
|   return request({ | ||||
|     url: '/basic/configure-display/page', | ||||
|     url: '/api/wms/configure-display/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
							
								
								
									
										46
									
								
								src/api/basicData/Warehouse/HistoricalTask.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										46
									
								
								src/api/basicData/Warehouse/HistoricalTask.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,46 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-14 15:29:26 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function HistoricalTaskList(data) { // 获取任务列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/car/task/execution/info/his/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function HistoricalTaskDetail(id) { // 获取任务单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/car/task/execution/info/his/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function CurrentTaskList(data) { // 获取任务列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/car/task/execution/info/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function CurrentTaskDetail(id) { // 获取任务单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/car/task/execution/info/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
							
								
								
									
										86
									
								
								src/api/basicData/Warehouse/StorageBoxInfo.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										86
									
								
								src/api/basicData/Warehouse/StorageBoxInfo.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,86 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 13:59:54 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function StorageBoxInfoList(data) { // 获取存储箱使用情况 | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/his/page/by/code', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxInfoDetail(id) { // 获取存储箱单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackList(data) { // 获取存储箱上架列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/page/for/bind', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function locationList(data) { // 获取库位列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/location/list', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackDetail(id) { // 获取存储箱上架单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackUpdate(data) { // 更新存储箱上架单条数据 | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackAdd(data) { // 新增存储箱上架单条数据 | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackCode(data) { // 获取存储箱上架code | ||||
|   return request({ | ||||
|     url: '/api/wms/storagebox/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function StorageBoxRackDelete(id) { // 删除存储箱上架单条数据 | ||||
|   return request({ | ||||
|     url: '/api/wms/storage/box/circ/info/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| } | ||||
| @@ -1,15 +1,15 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-05-19 15:57:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 15:10:16 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function dataDictionaryDataList(data) { // 获取字典类型列表 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataListByPage', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function dataDictionaryDataList(data) { // 获取字典类型列表 | ||||
|  | ||||
| export function dataDictionaryDataDetail(id) { // 获取字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataById', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function dataDictionaryDataDetail(id) { // 获取字典类型单条数据 | ||||
|  | ||||
| export function dataDictionaryDataUpdate(data) { // 更新字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/updatePlatformDictData', | ||||
|     url: '/api/wms/platform-dict/updatePlatformDictData', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function dataDictionaryDataUpdate(data) { // 更新字典类型单条数 | ||||
|  | ||||
| export function dataDictionaryDataAdd(data) { // 新增字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/savePlatformDictData', | ||||
|     url: '/api/wms/platform-dict/savePlatformDictData', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,7 +41,7 @@ export function dataDictionaryDataAdd(data) { // 新增字典类型单条数据 | ||||
|  | ||||
| export function dataDictionaryDataDelete(id) { // 删除字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/deletePlatformDictData', | ||||
|     url: '/api/wms/platform-dict/deletePlatformDictData', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -2,14 +2,14 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-04-16 12:51:29 | ||||
|  * @LastEditTime: 2022-03-03 15:29:30 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function dataDictionaryTypeList(data) { // 获取字典类型列表 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictTypeListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictTypeListByPage', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function dataDictionaryTypeList(data) { // 获取字典类型列表 | ||||
|  | ||||
| export function dataDictionaryTypeDetail(id) { // 获取字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/selectDictTypeById', | ||||
|     url: '/api/wms/platform-dict/selectDictTypeById', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function dataDictionaryTypeDetail(id) { // 获取字典类型单条数据 | ||||
|  | ||||
| export function dataDictionaryTypeUpdate(data) { // 更新字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/updatePlatformDictType', | ||||
|     url: '/api/wms/platform-dict/updatePlatformDictType', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function dataDictionaryTypeUpdate(data) { // 更新字典类型单条数 | ||||
|  | ||||
| export function dataDictionaryTypeAdd(data) { // 新增字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/savePlatformDictType', | ||||
|     url: '/api/wms/platform-dict/savePlatformDictType', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,7 +41,7 @@ export function dataDictionaryTypeAdd(data) { // 新增字典类型单条数据 | ||||
|  | ||||
| export function dataDictionaryTypeDelete(id) { // 删除字典类型单条数据 | ||||
|   return request({ | ||||
|     url: '/basic/platform-dict/deletePlatformDictType', | ||||
|     url: '/api/wms/platform-dict/deletePlatformDictType', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-01-21 18:08:29 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-12 10:11:14 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-24 14:55:06 | ||||
|  * @FilePath: \basic-admin\src\api\dict\index.js | ||||
|  * @Description: 数据字典定义 | ||||
|  */ | ||||
| @@ -11,7 +11,7 @@ import { requestWithCache } from '@/utils/request' | ||||
| // 获取设备列表列表 | ||||
| export function getDictDevice(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/equipment/page', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }).then(res => { | ||||
| @@ -41,7 +41,7 @@ export function getDictDeviceType(data) { | ||||
| // 获取物料列表 | ||||
| export function getDictBom(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/material/page', | ||||
|     url: '/api/wms/material/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }).then(res => { | ||||
| @@ -71,7 +71,7 @@ export function getDictSupplier(data) { | ||||
| // 获取单位列表 | ||||
| export function getDictUnit(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataListByPage', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -105,7 +105,7 @@ export function getDictMaterial(data) { | ||||
| // 获取维修类型 | ||||
| export function getDictRepairType(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/maintenance-type/page', | ||||
|     url: '/api/wms/maintenance-type/page', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -129,7 +129,7 @@ export function getDictRepairType(data) { | ||||
| // 获取员工列表 | ||||
| export function getDictWorker() { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/worker/page', | ||||
|     url: '/api/wms/worker/page', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -153,7 +153,7 @@ export function getDictWorker() { | ||||
| // 获取基础备品备件列表 | ||||
| export function getDictSparepart(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/tool-spare-part/page', | ||||
|     url: '/api/wms/tool-spare-part/page', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -176,7 +176,7 @@ export function getDictSparepart(data) { | ||||
| // 获取备件型号 | ||||
| export function getDictModel(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/tool-spare-part/list', | ||||
|     url: '/api/wms/tool-spare-part/list', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -200,7 +200,7 @@ export function getDictModel(data) { | ||||
| // 质量---报废: 报废原因 | ||||
| export function scrapReasonList(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/scrap-information/page', | ||||
|     url: '/api/wms/scrap-information/page', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -250,7 +250,7 @@ export function faultLevelList(data) { | ||||
| // 获取保养周期 | ||||
| export function maintainPeriod(data) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataListByPage', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -327,7 +327,7 @@ export function equipmentTypeParam(id) { | ||||
|  | ||||
| export function statusList(id) { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/configure-display/page', | ||||
|     url: '/api/wms/configure-display/page', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       current: 1, | ||||
| @@ -350,7 +350,7 @@ export function statusList(id) { | ||||
| // 获取角色列表 | ||||
| export function workerRoleList() { | ||||
|   return requestWithCache({ | ||||
|     url: '/basic/platform-dict/selectPlatformDictDataListByPage', | ||||
|     url: '/api/wms/platform-dict/selectPlatformDictDataListByPage', | ||||
|     method: 'post', | ||||
|     data: { | ||||
|       dictTypeId: '1383318968677273601', | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-01-05 15:25:38 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-21 13:26:36 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-24 14:48:53 | ||||
|  * @FilePath: \basic-admin\src\api\equipment\bom.js | ||||
|  * @Description: 设备管理——设备物料bom管理 接口定义 | ||||
|  */ | ||||
| @@ -10,7 +10,7 @@ import request from '@/utils/request' | ||||
| // 获取物料bom列表 | ||||
| export function getBOMList(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom/findAllByEQNameOrEQCodeOrMaterialNameWithPage', | ||||
|     url: '/api/wms/equipment-bom/findAllByEQNameOrEQCodeOrMaterialNameWithPage', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -19,7 +19,7 @@ export function getBOMList(data) { | ||||
| // 新增物料bom | ||||
| export function addBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom/create', | ||||
|     url: '/api/wms/equipment-bom/create', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -28,7 +28,7 @@ export function addBOM(data) { | ||||
| // 修改物料bom | ||||
| export function editBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom/update', | ||||
|     url: '/api/wms/equipment-bom/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -37,7 +37,7 @@ export function editBOM(data) { | ||||
| // 删除物料bom | ||||
| export function delBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom/delete', | ||||
|     url: '/api/wms/equipment-bom/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -46,7 +46,7 @@ export function delBOM(data) { | ||||
| // 根据id获取物料bom | ||||
| export function getBOMInfo(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom/findById', | ||||
|     url: '/api/wms/equipment-bom/findById', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -55,7 +55,7 @@ export function getBOMInfo(data) { | ||||
| // 获取设备物料bom列表 | ||||
| export function getDeviceBOMList(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom-detail/findAllByEQBomIdWithPage', | ||||
|     url: '/api/wms/equipment-bom-detail/findAllByEQBomIdWithPage', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -64,7 +64,7 @@ export function getDeviceBOMList(data) { | ||||
| // 新增设备物料bom | ||||
| export function addDeviceBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom-detail/create', | ||||
|     url: '/api/wms/equipment-bom-detail/create', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -73,7 +73,7 @@ export function addDeviceBOM(data) { | ||||
| // 修改设备物料bom | ||||
| export function editDeviceBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom-detail/update', | ||||
|     url: '/api/wms/equipment-bom-detail/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -82,7 +82,7 @@ export function editDeviceBOM(data) { | ||||
| // 删除设备物料bom | ||||
| export function delDeviceBOM(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom-detail/delete', | ||||
|     url: '/api/wms/equipment-bom-detail/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -91,7 +91,7 @@ export function delDeviceBOM(data) { | ||||
| // 根据id获取设备物料bom详细 | ||||
| export function getDeviceBOMInfo(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-bom-detail/findById', | ||||
|     url: '/api/wms/equipment-bom-detail/findById', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -101,7 +101,7 @@ export function getDeviceBOMInfo(data) { | ||||
|  | ||||
| export function getMaterialList(data) { | ||||
|   return request({ | ||||
|     url: '/basic/material/page', | ||||
|     url: '/api/wms/material/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-01-15 17:42:07 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-12 10:31:01 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 13:52:50 | ||||
|  * @FilePath: \basic-admin\src\api\equipment\maintain.js | ||||
|  * @Description: 保养计划 & 保养记录 接口定义 | ||||
|  */ | ||||
| @@ -109,7 +109,7 @@ export function getMaintainLog(data) { | ||||
| // 获取设备列表 | ||||
| export function getEqList(data) { | ||||
|   return request({ | ||||
|     url: '/basic/equipment/page', | ||||
|     url: '/api/wms/equipment/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-01-28 15:01:57 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-20 10:50:48 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-24 14:49:42 | ||||
|  * @FilePath: \basic-admin\src\api\equipment\recipe.js | ||||
|  * @Description: 设备配方设置 | ||||
|  */ | ||||
| @@ -11,7 +11,7 @@ import request from '@/utils/request' | ||||
| // 获取设备配方CODE | ||||
| export function getDeviceRecipeCode(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/getEquipmentRecipeCode', | ||||
|     url: '/api/wms/equipment-recipe/getEquipmentRecipeCode', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -20,7 +20,7 @@ export function getDeviceRecipeCode(data) { | ||||
| // 获取设备配方列表 | ||||
| export function getDeviceRecipeList(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/findAllByEquipmentTypeAndRecipeName', | ||||
|     url: '/api/wms/equipment-recipe/findAllByEquipmentTypeAndRecipeName', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -29,7 +29,7 @@ export function getDeviceRecipeList(data) { | ||||
| // 新建设备配方 | ||||
| export function addDeviceRecipe(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/create', | ||||
|     url: '/api/wms/equipment-recipe/create', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -38,7 +38,7 @@ export function addDeviceRecipe(data) { | ||||
| // 编辑设备配方 | ||||
| export function editDeviceRecipe(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/update', | ||||
|     url: '/api/wms/equipment-recipe/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -47,7 +47,7 @@ export function editDeviceRecipe(data) { | ||||
| // 删除设备配方 | ||||
| export function delDeviceRecipe(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/delete', | ||||
|     url: '/api/wms/equipment-recipe/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -56,7 +56,7 @@ export function delDeviceRecipe(data) { | ||||
| // 获取设备配方 | ||||
| export function getDeviceRecipe(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe/findById', | ||||
|     url: '/api/wms/equipment-recipe/findById', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -65,7 +65,7 @@ export function getDeviceRecipe(data) { | ||||
| // 根据id获取设备配方参数列表 | ||||
| export function getDeviceRecipeParamList(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe-parameter/findAllByRecipeIdWithPage', | ||||
|     url: '/api/wms/equipment-recipe-parameter/findAllByRecipeIdWithPage', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -74,7 +74,7 @@ export function getDeviceRecipeParamList(data) { | ||||
| // 新增设备配方参数 | ||||
| export function addDeviceRecipeParam(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe-parameter/create', | ||||
|     url: '/api/wms/equipment-recipe-parameter/create', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -83,7 +83,7 @@ export function addDeviceRecipeParam(data) { | ||||
| // 修改设备配方参数 | ||||
| export function editDeviceRecipeParam(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe-parameter/update', | ||||
|     url: '/api/wms/equipment-recipe-parameter/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -92,7 +92,7 @@ export function editDeviceRecipeParam(data) { | ||||
| // 删除设备配方参数 | ||||
| export function delDeviceRecipeParam(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe-parameter/delete', | ||||
|     url: '/api/wms/equipment-recipe-parameter/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -101,7 +101,7 @@ export function delDeviceRecipeParam(data) { | ||||
| // 获取设备配方参数详细 (等待接口补全) | ||||
| export function getDeviceRecipeParam(data) { | ||||
|   return request({ | ||||
|     url: '/equipment/equipment-recipe-parameter/findById', | ||||
|     url: '/api/wms/equipment-recipe-parameter/findById', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,15 +1,22 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2021-09-18 16:09:07 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 09:52:41 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function list(data) { | ||||
|   return request({ | ||||
|     url: 'material/material-date/materialList', | ||||
|     url: 'api/process/process-flow-equipment/equipmentList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function listEquipment(data) { | ||||
|   return request({ | ||||
|     url: 'material/equipment-material-replace/equipmentList', | ||||
|     url: 'api/process/process-flow-equipment/equipmentList', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
							
								
								
									
										47
									
								
								src/api/orderManage/00A.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										47
									
								
								src/api/orderManage/00A.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,47 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2022-01-17 14:55:09 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 14:59:07 | ||||
|  * @Description: | ||||
|  */ | ||||
|  | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function ProcessInfoList(data) { // 获取工单工艺列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/work/order/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function ProcessInfoDetail(id) { // 获取工单工艺单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/work/order/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function ExecutionInfoList(data) { // 获取工单执行列表 | ||||
|   return request({ | ||||
|     url: '/api/wms/work/order/execute/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function ExecutionInfoDetail(id) { // 获取工单执行单条数据 | ||||
|   const data = { | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/api/wms/work/order/execute/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| @@ -1,15 +1,15 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:00:14 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-20 10:30:39 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 13:57:00 | ||||
|  * @Description: | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function workOrderList(data) { // 获取工单列表 | ||||
|   return request({ | ||||
|     url: '/order/work-order/page', | ||||
|     url: '/api/order/work-order/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -20,7 +20,7 @@ export function workOrderDetail(id) { // 获取工单单条数据 | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/order/work-order/get', | ||||
|     url: '/api/order/work-order/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -28,7 +28,7 @@ export function workOrderDetail(id) { // 获取工单单条数据 | ||||
|  | ||||
| export function workOrderUpdate(data) { // 更新工单单条数据 | ||||
|   return request({ | ||||
|     url: '/order/work-order/update', | ||||
|     url: '/api/order/work-order/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -36,7 +36,7 @@ export function workOrderUpdate(data) { // 更新工单单条数据 | ||||
|  | ||||
| export function workOrderAdd(data) { // 新增工单单条数据 | ||||
|   return request({ | ||||
|     url: '/order/work-order/add', | ||||
|     url: '/api/order/work-order/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -44,14 +44,14 @@ export function workOrderAdd(data) { // 新增工单单条数据 | ||||
|  | ||||
| export function workOrderCode() { // 获取工单code | ||||
|   return request({ | ||||
|     url: '/order/work-order/get-code', | ||||
|     url: '/api/order/work-order/get-code', | ||||
|     method: 'post' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| export function workOrderDelete(id) { // 删除工单单条数据 | ||||
|   return request({ | ||||
|     url: '/order/work-order/delete', | ||||
|     url: '/api/order/work-order/delete', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
| @@ -59,7 +59,7 @@ export function workOrderDelete(id) { // 删除工单单条数据 | ||||
|  | ||||
| export function workOrderIssueList(data) { // 获取工单下发列表 | ||||
|   return request({ | ||||
|     url: '/order/wo-sync/page', | ||||
|     url: '/api/order/wo-sync/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -67,7 +67,7 @@ export function workOrderIssueList(data) { // 获取工单下发列表 | ||||
|  | ||||
| export function packagingBoxList(data) { // 获取包装基板列表 | ||||
|   return request({ | ||||
|     url: '/order/wo-packaging-box-substrate/page', | ||||
|     url: '/api/order/wo-packaging-box-substrate/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -75,7 +75,7 @@ export function packagingBoxList(data) { // 获取包装基板列表 | ||||
|  | ||||
| export function packagingList(data) { // 获取包装标签列表 | ||||
|   return request({ | ||||
|     url: '/order/wo-packaging-box/page', | ||||
|     url: '/api/order/wo-packaging-box/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -86,7 +86,7 @@ export function packagingDetail(id) { // 获取包装标签详情 | ||||
|     'id': id | ||||
|   } | ||||
|   return request({ | ||||
|     url: '/order/wo-packaging-box/get', | ||||
|     url: '/api/order/wo-packaging-box/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -94,7 +94,7 @@ export function packagingDetail(id) { // 获取包装标签详情 | ||||
|  | ||||
| export function syncAdd(data) { // 新增下发工单单条数据 | ||||
|   return request({ | ||||
|     url: '/order/wo-sync/add', | ||||
|     url: '/api/order/wo-sync/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -102,7 +102,7 @@ export function syncAdd(data) { // 新增下发工单单条数据 | ||||
|  | ||||
| export function packagingInventoryList(data) { // 获取包装清单列表 | ||||
|   return request({ | ||||
|     url: '/order/wo-packaging-box/page-for-inventory', | ||||
|     url: '/api/order/wo-packaging-box/page-for-inventory', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -110,7 +110,7 @@ export function packagingInventoryList(data) { // 获取包装清单列表 | ||||
|  | ||||
| export function updateForStatus(data) { // 激活 | ||||
|   return request({ | ||||
|     url: '/order/work-order/updateForStatus', | ||||
|     url: '/api/order/work-order/updateForStatus', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-03-15 10:27:40 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-09 14:35:26 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 15:40:29 | ||||
|  * @FilePath: \basic-admin\src\api\quality-manage\scrap.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -9,7 +9,7 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function getScrapList(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/page', | ||||
|     url: '/api/wms/scrap/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function getScrapList(data) { | ||||
|  | ||||
| export function delScrapInfo(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/delete', | ||||
|     url: '/api/wms/scrap/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function delScrapInfo(data) { | ||||
|  | ||||
| export function editScrapInfo(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/update', | ||||
|     url: '/api/wms/scrap/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,14 +33,14 @@ export function editScrapInfo(data) { | ||||
|  | ||||
| export function addScrapInfo(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/create', | ||||
|     url: '/api/wms/scrap/create', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| } | ||||
| export function getScrapInfo(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/findById', | ||||
|     url: '/api/wms/scrap/findById', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -49,7 +49,7 @@ export function getScrapInfo(data) { | ||||
| // 废品报废 原因 | ||||
| export function getscrapReason(data) { | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/get', | ||||
|     url: '/api/wms/scrap-information/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -58,7 +58,7 @@ export function getscrapReason(data) { | ||||
| // 根据设备id查询肺片等级 | ||||
| export function getScrap(id) { | ||||
|   return request({ | ||||
|     url: '/basic/equipment-scraps-grade/getScrapsGradeByEquipmentId', | ||||
|     url: '/api/wms/equipment-scraps-grade/getScrapsGradeByEquipmentId', | ||||
|     method: 'post', | ||||
|     data: { id } | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-03-15 10:27:40 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-09 14:35:26 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 15:40:35 | ||||
|  * @FilePath: \basic-admin\src\api\quality-manage\scrap.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -9,7 +9,7 @@ import request from '@/utils/request' | ||||
|  | ||||
| export function getList(data) { | ||||
|   return request({ | ||||
|     url: '/quality/scrap/findReportByEquipmentId', | ||||
|     url: '/api/wms/scrap/findReportByEquipmentId', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -18,7 +18,7 @@ export function getList(data) { | ||||
| // 废品报废 原因 | ||||
| export function getscrapReason(data) { | ||||
|   return request({ | ||||
|     url: '/basic/scrap-information/get', | ||||
|     url: '/api/wms/scrap-information/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,15 +1,15 @@ | ||||
| /* | ||||
|  * @Author: gtz | ||||
|  * @Date: 2021-04-01 09:24:20 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-16 13:24:51 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-25 09:06:19 | ||||
|  * @Description: file content | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function page(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/page', | ||||
|     url: '/api/report/report-sheet-category/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function page(data) { | ||||
|  | ||||
| export function list(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/list', | ||||
|     url: '/api/report/report-sheet-category/list', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function list(data) { | ||||
|  | ||||
| export function del(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/delete', | ||||
|     url: '/api/report/report-sheet-category/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function del(data) { | ||||
|  | ||||
| export function update(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/update', | ||||
|     url: '/api/report/report-sheet-category/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -41,7 +41,7 @@ export function update(data) { | ||||
|  | ||||
| export function add(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/add', | ||||
|     url: '/api/report/report-sheet-category/add', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -49,7 +49,7 @@ export function add(data) { | ||||
|  | ||||
| export function getData(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/get', | ||||
|     url: '/api/report/report-sheet-category/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,15 +1,15 @@ | ||||
| /* | ||||
|  * @Author: gtz | ||||
|  * @Date: 2021-03-07 18:39:03 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-22 20:03:49 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-02-25 09:05:53 | ||||
|  * @Description: file content | ||||
|  */ | ||||
| import request from '@/utils/request' | ||||
|  | ||||
| export function page(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet/page', | ||||
|     url: '/api/report/report-sheet/page', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -17,7 +17,7 @@ export function page(data) { | ||||
|  | ||||
| export function del(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet/delete', | ||||
|     url: '/api/report/report-sheet/delete', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -25,7 +25,7 @@ export function del(data) { | ||||
|  | ||||
| export function getInfo(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet/get', | ||||
|     url: '/api/report/report-sheet/get', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -33,7 +33,7 @@ export function getInfo(data) { | ||||
|  | ||||
| export function update(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet/update', | ||||
|     url: '/api/report/report-sheet/update', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
| @@ -42,7 +42,7 @@ export function update(data) { | ||||
| // 报表分类列表 | ||||
| export function listCategory(data) { | ||||
|   return request({ | ||||
|     url: '/report/report-sheet-category/list', | ||||
|     url: '/api/report/report-sheet-category/list', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2020-12-14 09:07:03 | ||||
|  * @LastEditors: guo | ||||
|  * @LastEditTime: 2021-01-11 09:40:09 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-11 15:45:54 | ||||
|  * @FilePath: \basic-admin\src\api\user.js | ||||
|  * @Description: 用户管理 & 登录用户的相关api接口定义 | ||||
|  */ | ||||
| @@ -13,7 +13,8 @@ export function login(data) { | ||||
|     userType: 1 | ||||
|   }) | ||||
|   return request({ | ||||
|     url: '/passport/login', | ||||
|     url: '/api/passport/login', | ||||
|     // url: '/passport/login', | ||||
|     method: 'post', | ||||
|     data: dto | ||||
|   }) | ||||
| @@ -28,7 +29,7 @@ export function logout() { | ||||
| // 获取当前登录的用户信息 | ||||
| export function getUserInfo(data) { | ||||
|   return request({ | ||||
|     url: '/passport/getLoginUser', | ||||
|     url: '/api/passport/getLoginUser', | ||||
|     method: 'post', | ||||
|     data | ||||
|   }) | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2020-12-29 16:49:28 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 15:56:54 | ||||
|  * @LastEditTime: 2022-01-17 15:31:40 | ||||
|  * @FilePath: \basic-admin\src\filters\basicData\index.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -63,9 +63,9 @@ const table = { | ||||
|     '1': i18n.t('basicDataFilter.enableState.enable') | ||||
|   }, | ||||
|   storage: { | ||||
|     '0': i18n.t('basicDataFilter.enableState.normal'), | ||||
|     '1': i18n.t('basicDataFilter.enableState.repairing'), | ||||
|     '2': i18n.t('basicDataFilter.enableState.scrap') | ||||
|     '0': i18n.t('basicDataFilter.storage.normal'), | ||||
|     '1': i18n.t('basicDataFilter.storage.repairing'), | ||||
|     '2': i18n.t('basicDataFilter.storage.scrap') | ||||
|   } | ||||
| } | ||||
|  | ||||
|   | ||||
							
								
								
									
										33
									
								
								src/filters/basicData/warehouse.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								src/filters/basicData/warehouse.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,33 @@ | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2022-01-17 11:30:41 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 11:33:29 | ||||
|  * @Description: | ||||
|  */ | ||||
| /* | ||||
|  * @Date: 2020-12-29 16:49:28 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-04-13 13:49:51 | ||||
|  * @FilePath: \basic-admin\src\filters\DataDict\index.js | ||||
|  * @Description: 部分常量的数据字典定义 | ||||
|  */ | ||||
|  | ||||
| import i18n from '@/lang' | ||||
|  | ||||
| const table = { | ||||
|   yesOrNo: { | ||||
|     '0': i18n.t('baseDict.yesOrNo.no'), | ||||
|     '1': i18n.t('baseDict.yesOrNo.yes') | ||||
|   }, | ||||
|   enableState: { | ||||
|     '0': i18n.t('basicDataFilter.enableState.disable'), | ||||
|     '1': i18n.t('basicDataFilter.enableState.enable') | ||||
|   } | ||||
| } | ||||
|  | ||||
| export default function(dictTable) { | ||||
|   return function(val) { | ||||
|     return table?.[dictTable]?.[val] | ||||
|   } | ||||
| } | ||||
| @@ -1,7 +1,7 @@ | ||||
| export default { | ||||
|   title: { | ||||
|     en: 'ARI MES', | ||||
|     zh: '中建材自动化智能制造执行系统' | ||||
|     en: 'ARI WMS', | ||||
|     zh: '中建材自动化智能仓库管理系统' | ||||
|   }, | ||||
|   btn: { | ||||
|     start: { | ||||
| @@ -254,12 +254,8 @@ export default { | ||||
|   }, | ||||
|   routerTitle: { | ||||
|     dashboard: { | ||||
|       zh: '', | ||||
|       en: '', | ||||
|       dashboard: { | ||||
|         zh: '仪表盘', | ||||
|         en: 'Dashboard' | ||||
|       } | ||||
|       zh: '仪表盘', | ||||
|       en: 'Dashboard' | ||||
|     }, | ||||
|     basic: { | ||||
|       zh: '系统管理', | ||||
| @@ -284,6 +280,10 @@ export default { | ||||
|     equipment: { | ||||
|       zh: '设备管理', | ||||
|       en: 'Equipment Manager', | ||||
|       EquipmentUtilizationRate: { | ||||
|         zh: '设备稼动率', | ||||
|         en: 'EQ OEE' | ||||
|       }, | ||||
|       EquipmentVisualization: { | ||||
|         zh: '设备可视化', | ||||
|         en: 'Equipment Visualization', | ||||
| @@ -552,8 +552,8 @@ export default { | ||||
|         zh: '缓存区信息', | ||||
|         en: 'Ports Info', | ||||
|         ports: { | ||||
|           zh: '仓库', | ||||
|           en: 'Warehouse' | ||||
|           zh: '缓存区信息', | ||||
|           en: 'Ports Info' | ||||
|         }, | ||||
|         area: { | ||||
|           zh: '区域', | ||||
| @@ -709,6 +709,26 @@ export default { | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     Warehouse: { | ||||
|       zh: '仓库管理', | ||||
|       en: 'Warehouse Manager', | ||||
|       StorageBoxInfo: { | ||||
|         zh: '存储箱信息', | ||||
|         en: 'Storage Box Info' | ||||
|       }, | ||||
|       StorageBoxRack: { | ||||
|         zh: '存储箱上架', | ||||
|         en: 'Storage Box Rack' | ||||
|       }, | ||||
|       CurrentTask: { | ||||
|         zh: '当前任务', | ||||
|         en: 'Current Task' | ||||
|       }, | ||||
|       HistoricalTask: { | ||||
|         zh: '历史任务', | ||||
|         en: 'Historical Task' | ||||
|       } | ||||
|     }, | ||||
|     order: { | ||||
|       zh: '工单管理', | ||||
|       en: 'Order Manager', | ||||
| @@ -716,6 +736,14 @@ export default { | ||||
|         zh: 'Power Classification', | ||||
|         en: 'Power Classification' | ||||
|       }, | ||||
|       ProcessInfo: { | ||||
|         zh: '工艺信息', | ||||
|         en: 'Process Info' | ||||
|       }, | ||||
|       ExecutionInfo: { | ||||
|         zh: '执行信息', | ||||
|         en: 'Execution Info' | ||||
|       }, | ||||
|       consumption: { | ||||
|         zh: '工单能耗', | ||||
|         en: 'Energy consumption of the repair order' | ||||
| @@ -928,6 +956,18 @@ export default { | ||||
|         zh: '质量检测计划', | ||||
|         en: 'Quality Detect Plan' | ||||
|       }, | ||||
|       scrapManagement: { | ||||
|         zh: '废片管理', | ||||
|         en: 'Scrap management', | ||||
|         gradeInfo: { | ||||
|           zh: '等级信息', | ||||
|           en: 'Grade Info' | ||||
|         }, | ||||
|         scrapInfo: { | ||||
|           zh: '废片信息', | ||||
|           en: 'Scrap Info' | ||||
|         } | ||||
|       }, | ||||
|       knowledge: { | ||||
|         zh: '维护保养知识库', | ||||
|         en: 'Maintain the knowledge base' | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: gtz | ||||
|  * @Date: 2021-03-04 16:13:51 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 09:59:34 | ||||
|  * @LastEditTime: 2022-01-17 15:12:18 | ||||
|  * @Description: file content | ||||
|  */ | ||||
| export default { | ||||
| @@ -130,9 +130,11 @@ export default { | ||||
|     CacheCode: 'Ports Code', | ||||
|     CacheName: 'Ports Name', | ||||
|     StockNumber: 'Stock Number', | ||||
|     AreaNumber: 'Area Number', | ||||
|     AreaCode: 'Area Code', | ||||
|     AreaName: 'Area Name', | ||||
|     AreaNumber: 'Shelf Number', | ||||
|     AreaCode: 'Shelf Code', | ||||
|     AreaName: 'Shelf Name', | ||||
|     rowNum: 'Row Num', | ||||
|     columnNum: 'Column Num', | ||||
|     Shelf: 'Shelf', | ||||
|     ManageShelves: 'Manage Shelves', | ||||
|     ShelfCode: 'Shelf Code', | ||||
| @@ -145,7 +147,7 @@ export default { | ||||
|     LocationName: 'Location Name', | ||||
|     anotherName: 'Another Name', | ||||
|     place: 'Place', | ||||
|     addCacheArea: 'add Ports Area' | ||||
|     addCacheArea: 'add Ports Shelf' | ||||
|   }, | ||||
|   storageBox: { | ||||
|     name: 'Name', | ||||
| @@ -272,5 +274,46 @@ export default { | ||||
|   EquipmentScrapGrade: { | ||||
|     keyword: 'name', | ||||
|     ScrapGrade: 'Scrap Grade' | ||||
|   }, | ||||
|   Warehouse: { | ||||
|     Code: 'Code', | ||||
|     TaskType: 'Task Type', | ||||
|     TaskStatus: 'Task Status', | ||||
|     TaskSource: 'Task Source', | ||||
|     VehicleName: 'Vehicle Name', | ||||
|     TimeSlot: 'Time Slot', | ||||
|     ExecutionTime: 'Execution Time', | ||||
|     BoxStatus: 'Box Status', | ||||
|     BoxNumber: 'Box Number', | ||||
|     PreviousOperation: 'Previous Operation', | ||||
|     NextOperation: 'Next Operation', | ||||
|     CompletionTime: 'Completion Time', | ||||
|     StartLocation: 'Start Location', | ||||
|     FullBoxStartLocation: 'FullBox Start Location', | ||||
|     TaskLocation: 'Task Location', | ||||
|     TargetLocation: 'Target Location', | ||||
|     OrderName: 'Order Name', | ||||
|     OrderCode: 'Order Code', | ||||
|     IssueOrderTime: 'Issue Order Time', | ||||
|     TotalProcessName: 'Total Process Name', | ||||
|     Priority: 'Priority', | ||||
|     OrderStatus: 'Order Status', | ||||
|     ProcessOrNot: 'Process Or Not', | ||||
|     Unit: 'Unit', | ||||
|     RelateProcess: 'Relate Process', | ||||
|     PlanProcessQuantity: 'Plan Process Quantity', | ||||
|     SubProcessName: 'Sub Process Name', | ||||
|     TaskBoxNumber: 'Task Box Number', | ||||
|     FullBoxNumber: 'Full Box Number', | ||||
|     EmptyFork: 'Empty Fork', | ||||
|     TaskBoxFork: 'Task Box Fork', | ||||
|     EmptyHandlingTime: 'Empty Handling Time', | ||||
|     TaskBoxHandlingTime: 'TaskBox Handling Time', | ||||
|     StorageBoxNumber: 'Storage Box Number', | ||||
|     CurrentLocation: 'Current Location', | ||||
|     IsEmpty: 'Is Empty', | ||||
|     IsEmptyBox: 'Is Empty Box', | ||||
|     LocationName: 'Location Name', | ||||
|     LocationCode: 'Location Code' | ||||
|   } | ||||
| } | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-03-05 10:04:30 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-23 09:13:56 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:31:23 | ||||
|  * @FilePath: \basic-admin\src\lang\i18n\en\module\equipmentManager.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -19,6 +19,68 @@ export default { | ||||
|     Water: 'Water', | ||||
|     Gas: 'Gas' | ||||
|   }, | ||||
|   monitoringInfo: { | ||||
|     allCycles: 'Total cycle Times', | ||||
|     badTimes: 'Failure Times', | ||||
|     time: 'Time', | ||||
|     MCBF: 'MCBF', | ||||
|     previousStatus: 'State Before', | ||||
|     runTime: 'UpTime (hours)', | ||||
|     produceTime: 'Production time (hours)', | ||||
|     productiveCount: 'Actual Capacity', | ||||
|     timeRate: 'Time Start Rate', | ||||
|     performanceRate: 'Performance Start Rate', | ||||
|     oee: 'OEE', | ||||
|     E10StartTime: 'E10 StartTime', | ||||
|     E10endTime: 'E10 EndTime', | ||||
|     laterE10Status: 'Changed E10 State', | ||||
|     duration: 'Duration', | ||||
|     goodsNumbers: 'OK Quantity', | ||||
|     noOkNumbers: 'NOK Quantity', | ||||
|     onceOkCount: 'OK Quantity Of Fist Process ', | ||||
|     reworkOkCount: 'OK Quantity Of Rework ', | ||||
|     GetTimePeriod: 'Time Period', | ||||
|     ProductionTimePeriod: 'Production Time Period', | ||||
|     MaintenanceTimes: 'Maintenance Times', | ||||
|     RunningTime: 'Running Time', | ||||
|     E10status: 'E10 State', | ||||
|     number: 'Quantity Produced Of Current day', | ||||
|     yieId: 'Daily yield', | ||||
|     bom: 'Daily Consumption Of Materials,', | ||||
|     controlState: 'Control State', | ||||
|     equipmentName: 'EQ Name', | ||||
|     e10Code: 'E10 State', | ||||
|     materialName: 'MaterialName', | ||||
|     port: 'Loading Port', | ||||
|     productCount: 'Product Quantity', | ||||
|     spec: 'Spec', | ||||
|     materialNo: 'MaterialNo', | ||||
|     upTime: 'Loading Time', | ||||
|     upCount: 'Loading Amount', | ||||
|     useCount: 'Used Amount', | ||||
|     unit: 'Unit', | ||||
|     eventName: 'EventName', | ||||
|     paramName: 'ParamName', | ||||
|     paramValue: 'ParamValue', | ||||
|     standardFormat: 'StandardFormat', | ||||
|     paramFormat: 'ParamFormat', | ||||
|     receiveTime: 'ReceivedTime', | ||||
|     recipe: 'EQ Recipe', | ||||
|     controlStatus: 'Control State', | ||||
|     traceDataState: 'Trace Data OpenState', | ||||
|     controlStateUpdateTime: 'Control State UpdateTime', | ||||
|     e10UpdateTime: 'E10 Update Time', | ||||
|     StateFlg: 'StateFlag', | ||||
|     EnableSpooling: 'EnableSpooling', | ||||
|     maxspooltransmit: 'MaxSpoolTransmit', | ||||
|     spoolingstate: 'SpoolingState', | ||||
|     spoolingcountactual: 'SpoolingCountActual', | ||||
|     SpoolingCountTotal: 'SpoolingCountTotal', | ||||
|     F1F3Succ: 'F1F3 Request Success', | ||||
|     F2F13Succ: 'F2F13 Request Success', | ||||
|     baseChart: 'Processed Substrates Quantity', | ||||
|     monitorChart: 'EQ Running Time' | ||||
|   }, | ||||
|   sparepart: { | ||||
|     'sparepart': 'Sparepart', | ||||
|     'code': 'Sparepart number', | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: gtz | ||||
|  * @Date: 2021-03-04 16:13:51 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 09:58:59 | ||||
|  * @LastEditTime: 2022-01-17 15:12:12 | ||||
|  * @Description: file content | ||||
|  */ | ||||
| export default { | ||||
| @@ -130,22 +130,24 @@ export default { | ||||
|     CacheCode: '缓存区编码', | ||||
|     CacheName: '缓存区名称', | ||||
|     StockNumber: '库位数量', | ||||
|     AreaNumber: '区域数量', | ||||
|     AreaCode: '区域编码', | ||||
|     AreaName: '区域名称', | ||||
|     AreaNumber: '货架数量', | ||||
|     AreaCode: '货架编码', | ||||
|     AreaName: '货架名称', | ||||
|     rowNum: '行数', | ||||
|     columnNum: '列数', | ||||
|     Shelf: '货架', | ||||
|     ManageShelves: '管理货架', | ||||
|     ShelfCode: '货架编码', | ||||
|     ShelfName: '货架名称', | ||||
|     ShelfNumber: '货架数量', | ||||
|     StorageQuantity: '存储数量', | ||||
|     Location: '货位', | ||||
|     Location: '库位', | ||||
|     ManageLocation: '管理货位', | ||||
|     LocationCode: '库位编码', | ||||
|     LocationName: '库位名称', | ||||
|     anotherName: '别名', | ||||
|     place: '位置', | ||||
|     addCacheArea: '添加区域' | ||||
|     addCacheArea: '添加货架' | ||||
|   }, | ||||
|   storageBox: { | ||||
|     name: '名称', | ||||
| @@ -272,5 +274,47 @@ export default { | ||||
|   EquipmentScrapGrade: { | ||||
|     keyword: '名称', | ||||
|     ScrapGrade: '废片等级' | ||||
|   }, | ||||
|   Warehouse: { | ||||
|     Code: '编码', | ||||
|     TaskType: '任务类型', | ||||
|     TaskStatus: '任务状态', | ||||
|     TaskSource: '任务来源', | ||||
|     VehicleName: '车辆名', | ||||
|     TimeSlot: '时间段', | ||||
|     ExecutionTime: '执行时间', | ||||
|     BoxStatus: '箱状态', | ||||
|     BoxNumber: '箱号', | ||||
|     PreviousOperation: '上一个工序', | ||||
|     NextOperation: '下一个工序', | ||||
|     CompletionTime: '完成时间', | ||||
|     StartLocation: '开始库位', | ||||
|     FullBoxStartLocation: '空箱开始库位', | ||||
|     TaskLocation: '任务库位', | ||||
|     TargetLocation: '目标库位', | ||||
|     OrderName: '工单名', | ||||
|     OrderCode: '工单编码', | ||||
|     IssueOrderTime: '下发工单时间', | ||||
|     TotalProcessName: '总工艺名称', | ||||
|     Priority: '优先级', | ||||
|     OrderStatus: '工单状态', | ||||
|     ProcessOrNot: '是否关联工艺', | ||||
|     Unit: '单位', | ||||
|     RelateProcess: '关联工艺', | ||||
|     PlanProcessQuantity: '计划加工数量', | ||||
|     SubProcessName: '分工艺', | ||||
|     TaskBoxNumber: '任务箱号', | ||||
|     FullBoxNumber: '空箱号', | ||||
|     EmptyFork: '空箱货叉', | ||||
|     TaskBoxFork: '任务箱货叉', | ||||
|     EmptyHandlingTime: '搬运空箱时间', | ||||
|     TaskBoxHandlingTime: '搬运任务箱时间', | ||||
|     StorageBoxNumber: '存储箱号', | ||||
|     CurrentLocation: '当前库位', | ||||
|     IsEmpty: '是否有基板', | ||||
|     IsEmptyBox: '是否空箱', | ||||
|     LocationName: '库位名', | ||||
|     LocationCode: '库位编码' | ||||
|  | ||||
|   } | ||||
| } | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2021-03-05 10:04:37 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-07-23 09:13:20 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:31:16 | ||||
|  * @FilePath: \basic-admin\src\lang\i18n\zh\module\equipmentManager.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -19,6 +19,68 @@ export default { | ||||
|     'Water': '水', | ||||
|     'Gas': '气' | ||||
|   }, | ||||
|   monitoringInfo: { | ||||
|     allCycles: '总循环次数', | ||||
|     badTimes: '故障次数', | ||||
|     time: '时间', | ||||
|     MCBF: 'MCBF', | ||||
|     previousStatus: '转换前状态', | ||||
|     runTime: '开机时长(时)', | ||||
|     produceTime: '生产时长(时)', | ||||
|     productiveCount: '实际产能', | ||||
|     timeRate: '时间开动率', | ||||
|     performanceRate: '性能开动率', | ||||
|     oee: '综合效率OEE', | ||||
|     E10StartTime: 'E10开始时间', | ||||
|     E10endTime: 'E10结束时间', | ||||
|     laterE10Status: '变化后E10状态', | ||||
|     duration: '持续时间', | ||||
|     goodsNumbers: '良品数量', | ||||
|     noOkNumbers: '不良品数量', | ||||
|     onceOkCount: '一次加工良品数量', | ||||
|     reworkOkCount: '重工良品数量', | ||||
|     GetTimePeriod: '获取时间段', | ||||
|     ProductionTimePeriod: '生产时间段', | ||||
|     MaintenanceTimes: '维护次数', | ||||
|     RunningTime: '运行时长', | ||||
|     E10status: 'E10状态', | ||||
|     number: '当日生产的数量', | ||||
|     yieId: '当日良率', | ||||
|     bom: '当日消耗物料', | ||||
|     controlState: '控制状态', | ||||
|     equipmentName: '设备名称', | ||||
|     e10Code: 'E10状态名称', | ||||
|     port: '上料位置', | ||||
|     recipe: '设备配方', | ||||
|     materialName: '物料名称', | ||||
|     productCount: '加工数量', | ||||
|     spec:	'物料规格', | ||||
|     materialNo:	'物料批次号', | ||||
|     upTime:	'上料时间', | ||||
|     upCount: '上料数量', | ||||
|     useCount:	'使用数量', | ||||
|     unit:	'单位', | ||||
|     eventName: '事件名称', | ||||
|     paramName: '参数名称', | ||||
|     receiveTime: '获取参数时间', | ||||
|     paramValue: '获取参数值', | ||||
|     standardFormat: '标准参数模式', | ||||
|     paramFormat: '获取参数格式', | ||||
|     controlStatus: '设备控制状态', | ||||
|     traceDataState: 'Trace Data 开启状态', | ||||
|     controlStateUpdateTime: '控制状态更新时间', | ||||
|     e10UpdateTime: 'E10更新时间', | ||||
|     StateFlg: 'StateFlg', | ||||
|     EnableSpooling: 'EnableSpooling', | ||||
|     maxspooltransmit: 'maxspooltransmit', | ||||
|     spoolingstate: 'spoolingstate', | ||||
|     spoolingcountactual: 'spoolingcountactual', | ||||
|     SpoolingCountTotal: 'SpoolingCountTotal', | ||||
|     F1F3Succ: 'F1F3请求成功', | ||||
|     F2F13Succ: 'F2F13请求成功', | ||||
|     baseChart: '设备加工基板数量', | ||||
|     monitorChart: '设备运行时长' | ||||
|   }, | ||||
|   sparepart: { | ||||
|     'sparepart': '备品备件', | ||||
|     'code': '备件编号', | ||||
|   | ||||
| @@ -15,11 +15,6 @@ | ||||
|         <svg-icon class="item-icon" icon-class="home" /> | ||||
|         {{ 'navbar.homepage' | i18nFilter }} | ||||
|       </div> | ||||
|       <div class="right-menu-back"> | ||||
|         <el-badge :value="alarmList.length" class="item" style="line-height: 0; margin: 0 10px;" @click.native="toAlarm"> | ||||
|           <svg-icon style="width: 24px; height: 24px" class="item-icon" icon-class="alarm" /> | ||||
|         </el-badge> | ||||
|       </div> | ||||
|  | ||||
|       <template> | ||||
|         <lang-select class="right-menu-item hover-effect" /> | ||||
| @@ -27,15 +22,15 @@ | ||||
|       <div v-if="showhome" class="right-menu-back"> | ||||
|         <a href="Lodap.zip"><i class="el-icon-download" /></a> | ||||
|       </div> | ||||
|       <div class="right-menu-back"> | ||||
|       <!-- <div class="right-menu-back"> | ||||
|         <i class="el-icon-alarm-clock" /> | ||||
|         {{ formatTime }} | ||||
|       </div> | ||||
|       </div> --> | ||||
|  | ||||
|       <el-dropdown class="avatar-container right-menu-item hover-effect" trigger="click"> | ||||
|         <div class="avatar-wrapper"> | ||||
|           <img :src="require('@/assets/img/head.png')" class="user-avatar"> | ||||
|           <div class="avatar-username">{{ username }}</div> | ||||
|           <!-- <div class="avatar-username">{{ username }}</div> --> | ||||
|           <!-- <i class="el-icon-caret-bottom" /> --> | ||||
|         </div> | ||||
|         <el-dropdown-menu slot="dropdown"> | ||||
| @@ -71,7 +66,6 @@ | ||||
| <script> | ||||
| import axios from 'axios' | ||||
| import { mapGetters } from 'vuex' | ||||
| import { alarmInfoList } from '@/api/basicData/AlarmManagement/alarmInfo' | ||||
| import Breadcrumb from '@/components/Breadcrumb' | ||||
| import Hamburger from '@/components/Hamburger' | ||||
| import LangSelect from '@/components/LangSelect' | ||||
| @@ -122,16 +116,9 @@ export default { | ||||
|       if (val <= 0) { | ||||
|         this.logout() | ||||
|       } | ||||
|     }, | ||||
|     $route: function() { | ||||
|       this.getAlarm() | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     this.getAlarm() | ||||
|     logoutInterval = setInterval(() => { | ||||
|       this.logoutTime -= 1000 | ||||
|     }, 1000) | ||||
|     addEventListener('click', this.logoutTimeReset) | ||||
|     addEventListener('keydown', this.logoutTimeReset) | ||||
|     addEventListener('visibilitychange', this.visibilitychangeListener) | ||||
| @@ -192,24 +179,6 @@ export default { | ||||
|     async toHome() { | ||||
|       this.$store.dispatch('app/setChoicepart') | ||||
|       this.$router.push('/') | ||||
|     }, | ||||
|     getAlarm() { | ||||
|       alarmInfoList({ | ||||
|         current: 1, | ||||
|         size: 1000, | ||||
|         alarmType: '', | ||||
|         code: '', | ||||
|         alarmGrade: '' | ||||
|       }).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.alarmList = response.data.records | ||||
|         } else { | ||||
|           this.alarmList = [] | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     toAlarm() { | ||||
|       this.$router.push('/AlarmManagement/AlarmInfo') | ||||
|     } | ||||
|   } | ||||
| } | ||||
|   | ||||
| @@ -1,8 +1,8 @@ | ||||
| <!-- | ||||
|  * @Author: your name | ||||
|  * @Date: 2021-01-27 10:07:42 | ||||
|  * @LastEditTime: 2021-03-08 11:59:59 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-12-22 16:06:25 | ||||
|  * @LastEditors: zwq | ||||
|  * @Description: In User Settings Edit | ||||
|  * @FilePath: \mt-bus-fe\src\layout\components\Sidebar\index.vue | ||||
| --> | ||||
| @@ -31,31 +31,17 @@ import { mapGetters } from 'vuex' | ||||
| import Logo from './Logo' | ||||
| import SidebarItem from './SidebarItem' | ||||
| import variables from '@/styles/variables.scss' | ||||
| // import { constantRoutes } from '@/router' | ||||
| import store from '@/store' | ||||
| import { constantRoutes } from '@/router' | ||||
| export default { | ||||
|   components: { SidebarItem, Logo }, | ||||
|   computed: { | ||||
|     ...mapGetters([ | ||||
|       'sidebar', | ||||
|       'choicepart', | ||||
|       'permission_routes', | ||||
|       'language' | ||||
|     ]), | ||||
|     partList() { | ||||
|       const cangoList = [] | ||||
|       const constantRoutes = store.getters.permission_routes | ||||
|       constantRoutes.map(item => { | ||||
|         if (!item.hidden && item.meta) { | ||||
|           cangoList.push(item) | ||||
|         } | ||||
|       }) | ||||
|       const formatList = cangoList.map((item, index) => { | ||||
|         return this.setIndex(item, index) | ||||
|       }) | ||||
|       return formatList | ||||
|     }, | ||||
|     routeList() { | ||||
|       return [this.partList[this.choicepart]] | ||||
|       return constantRoutes | ||||
|     }, | ||||
|     activeMenu() { | ||||
|       const route = this.$route | ||||
| @@ -67,6 +53,7 @@ export default { | ||||
|       return path | ||||
|     }, | ||||
|     showLogo() { | ||||
|       console.log(this.$route) | ||||
|       return this.$store.state.settings.sidebarLogo | ||||
|     }, | ||||
|     variables() { | ||||
| @@ -75,24 +62,6 @@ export default { | ||||
|     isCollapse() { | ||||
|       return !this.sidebar.opened | ||||
|     } | ||||
|   }, | ||||
|   watch: { | ||||
|     $route: function(val) { | ||||
|       if (val.meta.routeIndex >= 0) { | ||||
|         this.$store.dispatch('app/setChoicepart', val.meta.routeIndex) | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     setIndex(list, index) { | ||||
|       list.meta.routeIndex = index | ||||
|       if (list.children) { | ||||
|         list.children.map(item => { | ||||
|           this.setIndex(item, index) | ||||
|         }) | ||||
|       } | ||||
|       return list | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|   | ||||
| @@ -45,8 +45,8 @@ export default { | ||||
|       return this.$store.state.tagsView.visitedViews | ||||
|     }, | ||||
|     routes() { | ||||
|       // return this.$store.state.permission.routes | ||||
|       return [] | ||||
|       return this.$store.state.permission.routes | ||||
|       // return [] | ||||
|     } | ||||
|   }, | ||||
|   watch: { | ||||
|   | ||||
| @@ -1,12 +1,11 @@ | ||||
| /* | ||||
|  * @Date: 2020-12-14 09:07:03 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-02-25 09:42:36 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-12-22 16:13:30 | ||||
|  * @FilePath: \basic-admin\src\permission.js | ||||
|  * @Description: 路由权限检查 | ||||
|  */ | ||||
| import router from './router' | ||||
| // import { resetRouter } from '@/router' | ||||
| import { Message } from 'element-ui' | ||||
| import NProgress from 'nprogress' // progress bar | ||||
| import 'nprogress/nprogress.css' // progress bar style | ||||
| @@ -35,38 +34,28 @@ router.beforeEach(async(to, from, next) => { | ||||
|       next({ path: '/' }) | ||||
|       NProgress.done() // hack: https://github.com/PanJiaChen/vue-element-admin/pull/2939 | ||||
|     } else { | ||||
|       const hasRoles = store.getters.menus && store.getters.menus.length > 0 | ||||
|       console.log('store.getters.menus', store.getters.menus) | ||||
|       console.log('store.getters', store.getters) | ||||
|       console.log('hasRoles=', hasRoles) | ||||
|       if (hasRoles) { | ||||
|         console.log('hasRoles=', store.getters.menus) | ||||
|       // next() | ||||
|       NProgress.done() | ||||
|       try { | ||||
|       //   // generate accessible routes map based on roles | ||||
|         // const accessRoutes = await store.dispatch('permission/generateRoutes') | ||||
|         // console.log(accessRoutes) | ||||
|         // router.addRoutes(accessRoutes) | ||||
|         next() | ||||
|         NProgress.done() | ||||
|       } else { | ||||
|         try { | ||||
|           //   // generate accessible routes map based on roles | ||||
|           const { menus } = await store.dispatch('user/getInfo') | ||||
|           console.log(menus) | ||||
|           const accessRoutes = await store.dispatch('permission/generateRoutes', menus) | ||||
|           console.log('accessRoutes', accessRoutes) | ||||
|           router.addRoutes(accessRoutes) | ||||
|           next({ ...to, replace: true }) | ||||
|         // hack method to ensure that addRoutes is complete | ||||
|         // set the replace: true, so the navigation will not leave a history record | ||||
|         // next({ ...to, replace: true }) | ||||
|         } catch (error) { | ||||
|       } catch (error) { | ||||
|         // remove token and go to login page to re-login | ||||
|           next(`/login?redirect=${to.path}`) | ||||
|           await store.dispatch('user/resetToken') | ||||
|           Message.error(error || 'Has Error') | ||||
|           NProgress.done() | ||||
|         } | ||||
|         next(`/login?redirect=${to.path}`) | ||||
|         await store.dispatch('user/resetToken') | ||||
|         Message.error(error || 'Has Error') | ||||
|         NProgress.done() | ||||
|       } | ||||
|     } | ||||
|   } else { | ||||
|     /* has no token*/ | ||||
|     console.log('has no token to.path=' + to.path) | ||||
|     console.log('to.path=' + to.path) | ||||
|     console.log('whiteList.indexOf(to.path)=' + whiteList.indexOf(to.path)) | ||||
|     if (whiteList.indexOf(to.path) !== -1) { | ||||
|       // in the free login whitelist, go directly | ||||
|   | ||||
							
								
								
									
										1247
									
								
								src/router/index.js
									
									
									
									
									
								
							
							
						
						
									
										1247
									
								
								src/router/index.js
									
									
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -1,13 +1,13 @@ | ||||
| /* | ||||
|  * @Date: 2020-12-14 09:07:03 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-03-08 11:52:17 | ||||
|  * @LastEditors: Please set LastEditors | ||||
|  * @LastEditTime: 2021-12-06 14:24:30 | ||||
|  * @FilePath: \basic-admin\src\settings.js | ||||
|  * @Description: | ||||
|  */ | ||||
|  | ||||
| module.exports = { | ||||
|   title: 'ARI MES', | ||||
|   title: 'ARI WMS', | ||||
|  | ||||
|   /** | ||||
|    * @type {boolean} true | false | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| /* | ||||
|  * @Date: 2020-12-14 09:07:03 | ||||
|  * @LastEditors: gtz | ||||
|  * @LastEditTime: 2021-01-29 14:24:20 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-12-22 11:38:46 | ||||
|  * @FilePath: \basic-admin\src\store\getters.js | ||||
|  * @Description: | ||||
|  */ | ||||
| @@ -19,7 +19,6 @@ const getters = { | ||||
|   introduction: state => state.user.introduction, | ||||
|   username: state => state.user.username, | ||||
|   roles: state => state.user.roles, | ||||
|   menus: state => state.user.menus, | ||||
|   permission_routes: state => state.permission.routes | ||||
| } | ||||
| export default getters | ||||
|   | ||||
| @@ -1,36 +1,38 @@ | ||||
| import { dynamicRoutes, constantRoutes } from '@/router' | ||||
| import { getListItems } from '@/utils/tree' | ||||
| /* | ||||
|  * @Author: zwq | ||||
|  * @Date: 2021-09-18 16:09:08 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-12-22 15:43:46 | ||||
|  * @Description: | ||||
|  */ | ||||
| import { asyncRoutes, constantRoutes } from '@/router' | ||||
|  | ||||
| /** | ||||
|  * Use meta.role to determine if the current user has permission | ||||
|  * @param roles | ||||
|  * @param route | ||||
|  */ | ||||
| function hasPermission(menuList, route) { | ||||
|   // if (route.meta && route.meta.roles) { | ||||
|   //   return roles.some(role => route.meta.roles.includes(role)) | ||||
|   // } else { | ||||
|   //   return true | ||||
|   // } | ||||
|   if (route.hidden) { | ||||
| function hasPermission(roles, route) { | ||||
|   if (route.meta && route.meta.roles) { | ||||
|     return roles.some(role => route.meta.roles.includes(role)) | ||||
|   } else { | ||||
|     return true | ||||
|   } | ||||
|   return menuList.some(m => route.path === m.h) | ||||
| } | ||||
|  | ||||
| /** | ||||
|  * Filter asynchronous routing tables by recursion | ||||
|  * @param routes asyncRoutes | ||||
|  * @param menuList | ||||
|  * @param roles | ||||
|  */ | ||||
| export function filterAsyncRoutes(routes, menuList) { | ||||
| export function filterAsyncRoutes(routes, roles) { | ||||
|   const res = [] | ||||
|  | ||||
|   routes.forEach(route => { | ||||
|     const tmp = { ...route } | ||||
|     if (hasPermission(menuList, tmp)) { | ||||
|     if (hasPermission(roles, tmp)) { | ||||
|       if (tmp.children) { | ||||
|         tmp.children = filterAsyncRoutes(tmp.children, menuList) | ||||
|         tmp.children = filterAsyncRoutes(tmp.children, roles) | ||||
|       } | ||||
|       res.push(tmp) | ||||
|     } | ||||
| @@ -52,19 +54,13 @@ const mutations = { | ||||
| } | ||||
|  | ||||
| const actions = { | ||||
|   generateRoutes({ commit }, menus) { | ||||
|   generateRoutes({ commit }, roles) { | ||||
|     return new Promise(resolve => { | ||||
|       let accessedRoutes | ||||
|       console.log(menus) | ||||
|       if (!menus) { | ||||
|         accessedRoutes = [] | ||||
|       if (roles.includes('admin')) { | ||||
|         accessedRoutes = asyncRoutes || [] | ||||
|       } else { | ||||
|         const menuList = [] | ||||
|         getListItems(menus, node => menuList.push(node)) | ||||
|         console.log(menuList) | ||||
|         console.log(dynamicRoutes) | ||||
|         accessedRoutes = filterAsyncRoutes(dynamicRoutes, menuList) | ||||
|         console.log(accessedRoutes) | ||||
|         accessedRoutes = filterAsyncRoutes(asyncRoutes, roles) | ||||
|       } | ||||
|       commit('SET_ROUTES', accessedRoutes) | ||||
|       resolve(accessedRoutes) | ||||
|   | ||||
| @@ -9,7 +9,6 @@ const state = { | ||||
|   avatar: '', | ||||
|   introduction: '', | ||||
|   roles: [], | ||||
|   menus: [], | ||||
|   username: Cookies.get('username') || '' | ||||
| } | ||||
|  | ||||
| @@ -26,9 +25,6 @@ const mutations = { | ||||
|   SET_AVATAR: (state, avatar) => { | ||||
|     state.avatar = avatar | ||||
|   }, | ||||
|   SET_MENUS: (state, menus) => { | ||||
|     state.menus = menus | ||||
|   }, | ||||
|   SET_ROLES: (state, roles) => { | ||||
|     state.roles = roles | ||||
|   }, | ||||
| @@ -42,7 +38,7 @@ const actions = { | ||||
|   login({ commit }, userInfo) { | ||||
|     const { username, password } = userInfo | ||||
|     return new Promise((resolve, reject) => { | ||||
|       login({ mobile: username.trim(), password: password }).then(res => { | ||||
|       login({ mobile: String(username).trim(), password }).then(res => { | ||||
|         console.log(res) | ||||
|         if (res.code === 0) { | ||||
|           const { token, name } = res.data | ||||
| @@ -70,17 +66,16 @@ const actions = { | ||||
|           reject('Verification failed, please Login again.') | ||||
|         } | ||||
|  | ||||
|         const { roles, name, avatar, introduction, menus } = data | ||||
|         const { roles, name, avatar, introduction } = data | ||||
|  | ||||
|         // roles must be a non-empty array | ||||
|         if (!menus || menus.length <= 0) { | ||||
|           reject('getInfo: menus must be a non-null array!') | ||||
|         if (!roles || roles.length <= 0) { | ||||
|           reject('getInfo: roles must be a non-null array!') | ||||
|         } | ||||
|  | ||||
|         commit('SET_ROLES', roles || []) | ||||
|         commit('SET_ROLES', roles) | ||||
|         commit('SET_NAME', name) | ||||
|         commit('SET_AVATAR', avatar) | ||||
|         commit('SET_MENUS', menus) | ||||
|         commit('SET_INTRODUCTION', introduction) | ||||
|         resolve(data) | ||||
|       }).catch(error => { | ||||
| @@ -97,7 +92,6 @@ const actions = { | ||||
|       dispatch('tagsView/delAllViews', null, { root: true }) | ||||
|       commit('SET_TOKEN', '') | ||||
|       commit('SET_ROLES', []) | ||||
|       commit('SET_MENUS', []) | ||||
|       commit('SET_USERNAME') | ||||
|       Cookies.set('username', '') | ||||
|       localStorage.clear() | ||||
|   | ||||
							
								
								
									
										152
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/E10.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										152
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/E10.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,152 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-16 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 15:26:05 | ||||
|  * @Description: E10 | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="80px" | ||||
|     > | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="toE10()">E10</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toOEE()">OEE</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMTTR()">MTTR</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMCBF()">MCBF</el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item :label="$t('module.equipmentManager.recipe.equipmentId')" prop="equipmentName"> | ||||
|         <el-select v-model="formData.equipmentName" :placeholder="$t('module.equipmentManager.recipe.EQselect')" filterable clearable> | ||||
|           <el-option | ||||
|             v-for="(item, index) in eqList" | ||||
|             :key="index" | ||||
|             :label="item.name" | ||||
|             :value="item.name" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> --> | ||||
|       <el-form-item :label="$t('module.equipmentManager.equipmentVisualization.timeSlot')" label-width="100px" prop="time"> | ||||
|         <el-date-picker | ||||
|           v-model="formData.timeSlot" | ||||
|           type="datetimerange" | ||||
|           :start-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :end-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :range-separator="$t('module.orderManage.order.To')" | ||||
|           clearable | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.exportBtn' | i18nFilter }} </el-button> | ||||
|       </el-form-item> --> | ||||
|     </el-form> | ||||
|     <e10Chart v-if="e10Visible" ref="e10Chart" :time1="startTime" :time2="endTime" :name="formData.equipmentName" @equipmentName="seeDetail" /> | ||||
|     <e10-detail-chart v-if="e10Detail" ref="e10DetailChart" :time1="startTime" :time2="endTime" :equipment-name="equipmentName" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import e10Chart from './components/e10-chart' | ||||
| import e10DetailChart from './components/e10Detail-chart' | ||||
| // import { equipmentList } from '@/api/basicData/Equipment/equipmentInfo' | ||||
|  | ||||
| export default { | ||||
|   name: 'E10', | ||||
|   components: { e10Chart, e10DetailChart }, | ||||
|   data() { | ||||
|     return { | ||||
|       list: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       formData: { | ||||
|         timeSlot: [], | ||||
|         equipmentName: undefined, | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       e10Visible: false, | ||||
|       e10Detail: false, | ||||
|       equipmentName: '', | ||||
|       eqList: [] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     // this.getEqList() | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     async getEqList() { | ||||
|       const res = await equipmentList({ | ||||
|         current: 1, | ||||
|         size: 999 | ||||
|       }) | ||||
|       if (res.code === 0) { | ||||
|         this.eqList = res.data | ||||
|       } | ||||
|     }, | ||||
|     toE10() { | ||||
|       this.$router.push({ | ||||
|         name: 'E10' | ||||
|       }) | ||||
|     }, | ||||
|     toOEE() { | ||||
|       this.$router.push({ | ||||
|         name: 'OEE' | ||||
|       }) | ||||
|     }, | ||||
|     toMTTR() { | ||||
|       this.$router.push({ | ||||
|         name: 'MTTR' | ||||
|       }) | ||||
|     }, | ||||
|     toMCBF() { | ||||
|       this.$router.push({ | ||||
|         name: 'MCBF' | ||||
|       }) | ||||
|     }, | ||||
|     seeDetail(name) { | ||||
|       this.equipmentName = name | ||||
|       this.e10Visible = false | ||||
|       this.e10Detail = true | ||||
|       setTimeout(() => { | ||||
|         this.$refs.e10DetailChart.getList() | ||||
|       }, 60) | ||||
|     }, | ||||
|     getList() { | ||||
|       if (this.formData.timeSlot.length !== 0) { | ||||
|         this.startTime = this.formData.timeSlot[0] | ||||
|         this.endTime = this.formData.timeSlot[1] | ||||
|         this.$nextTick(() => { | ||||
|           this.e10Visible = true | ||||
|           setTimeout(() => { | ||||
|             this.$refs.e10Chart.getList() | ||||
|           }, 60) | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/MCBF.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/MCBF.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,151 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-16 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 15:26:28 | ||||
|  * @Description: MCBF | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="80px" | ||||
|     > | ||||
|       <el-form-item> | ||||
|         <el-button @click="toE10()">E10</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toOEE()">OEE</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMTTR()">MTTR</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="toMCBF()">MCBF</el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item :label="$t('module.equipmentManager.recipe.equipmentId')" prop="equipmentName"> | ||||
|         <el-select v-model="formData.equipmentName" :placeholder="$t('module.equipmentManager.recipe.EQselect')" filterable clearable> | ||||
|           <el-option | ||||
|             v-for="(item, index) in eqList" | ||||
|             :key="index" | ||||
|             :label="item.name" | ||||
|             :value="item.name" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> --> | ||||
|       <el-form-item :label="$t('module.equipmentManager.equipmentVisualization.timeSlot')" label-width="100px" prop="time"> | ||||
|         <el-date-picker | ||||
|           v-model="formData.timeSlot" | ||||
|           type="datetimerange" | ||||
|           :start-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :end-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :range-separator="$t('module.orderManage.order.To')" | ||||
|           clearable | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.exportBtn' | i18nFilter }} </el-button> | ||||
|       </el-form-item> --> | ||||
|     </el-form> | ||||
|     <mcbfChart v-if="mcbfVisible" ref="mcbfChart" :time1="startTime" :time2="endTime" @equipmentName="seeDetail" /> | ||||
|     <mcbf-detail-chart v-if="mcbfDetail" ref="mcbfDetailChart" :time1="startTime" :time2="endTime" :equipment-name="equipmentName" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import mcbfChart from './components/mcbf-chart' | ||||
| import mcbfDetailChart from './components/mcbfDetail-chart' | ||||
| // import { equipmentList } from '@/api/basicData/Equipment/equipmentInfo' | ||||
|  | ||||
| export default { | ||||
|   name: 'MCBF', | ||||
|   components: { mcbfChart, mcbfDetailChart }, | ||||
|   data() { | ||||
|     return { | ||||
|       list: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       formData: { | ||||
|         timeSlot: [], | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       mcbfVisible: false, | ||||
|       mcbfDetail: false, | ||||
|       equipmentName: '', | ||||
|       eqList: [] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     // this.getEqList() | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     async getEqList() { | ||||
|       const res = await equipmentList({ | ||||
|         current: 1, | ||||
|         size: 999 | ||||
|       }) | ||||
|       if (res.code === 0) { | ||||
|         this.eqList = res.data | ||||
|       } | ||||
|     }, | ||||
|     toE10() { | ||||
|       this.$router.push({ | ||||
|         name: 'E10' | ||||
|       }) | ||||
|     }, | ||||
|     toOEE() { | ||||
|       this.$router.push({ | ||||
|         name: 'OEE' | ||||
|       }) | ||||
|     }, | ||||
|     toMTTR() { | ||||
|       this.$router.push({ | ||||
|         name: 'MTTR' | ||||
|       }) | ||||
|     }, | ||||
|     toMCBF() { | ||||
|       this.$router.push({ | ||||
|         name: 'MCBF' | ||||
|       }) | ||||
|     }, | ||||
|     seeDetail(name) { | ||||
|       this.equipmentName = name | ||||
|       this.mcbfVisible = false | ||||
|       this.mcbfDetail = true | ||||
|       setTimeout(() => { | ||||
|         this.$refs.mcbfDetailChart.getList() | ||||
|       }, 60) | ||||
|     }, | ||||
|     getList() { | ||||
|       if (this.formData.timeSlot.length !== 0) { | ||||
|         this.startTime = this.formData.timeSlot[0] | ||||
|         this.endTime = this.formData.timeSlot[1] | ||||
|         this.$nextTick(() => { | ||||
|           this.mcbfVisible = true | ||||
|           setTimeout(() => { | ||||
|             this.$refs.mcbfChart.getList() | ||||
|           }, 60) | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/MTTR.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/MTTR.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,151 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-16 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 15:26:44 | ||||
|  * @Description: MTTR | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="80px" | ||||
|     > | ||||
|       <el-form-item> | ||||
|         <el-button @click="toE10()">E10</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toOEE()">OEE</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="toMTTR()">MTTR</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMCBF()">MCBF</el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item :label="$t('module.equipmentManager.recipe.equipmentId')" prop="equipmentName"> | ||||
|         <el-select v-model="formData.equipmentName" :placeholder="$t('module.equipmentManager.recipe.EQselect')" filterable clearable> | ||||
|           <el-option | ||||
|             v-for="(item, index) in eqList" | ||||
|             :key="index" | ||||
|             :label="item.name" | ||||
|             :value="item.name" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> --> | ||||
|       <el-form-item :label="$t('module.equipmentManager.equipmentVisualization.timeSlot')" label-width="100px" prop="time"> | ||||
|         <el-date-picker | ||||
|           v-model="formData.timeSlot" | ||||
|           type="datetimerange" | ||||
|           :start-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :end-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :range-separator="$t('module.orderManage.order.To')" | ||||
|           clearable | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.exportBtn' | i18nFilter }} </el-button> | ||||
|       </el-form-item> --> | ||||
|     </el-form> | ||||
|     <mttrChart v-if="mttrVisible" ref="mttrChart" :time1="startTime" :time2="endTime" @equipmentName="seeDetail" /> | ||||
|     <mttr-detail-chart v-if="mttrDetail" ref="mttrDetailChart" :time1="startTime" :time2="endTime" :equipment-name="equipmentName" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import mttrChart from './components/mttr-chart' | ||||
| import mttrDetailChart from './components/mttrDetail-chart' | ||||
| // import { equipmentList } from '@/api/basicData/Equipment/equipmentInfo' | ||||
|  | ||||
| export default { | ||||
|   name: 'MTTR', | ||||
|   components: { mttrChart, mttrDetailChart }, | ||||
|   data() { | ||||
|     return { | ||||
|       list: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       formData: { | ||||
|         timeSlot: [], | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       mttrVisible: false, | ||||
|       mttrDetail: false, | ||||
|       equipmentName: '', | ||||
|       eqList: [] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     // this.getEqList() | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     async getEqList() { | ||||
|       const res = await equipmentList({ | ||||
|         current: 1, | ||||
|         size: 999 | ||||
|       }) | ||||
|       if (res.code === 0) { | ||||
|         this.eqList = res.data | ||||
|       } | ||||
|     }, | ||||
|     toE10() { | ||||
|       this.$router.push({ | ||||
|         name: 'E10' | ||||
|       }) | ||||
|     }, | ||||
|     toOEE() { | ||||
|       this.$router.push({ | ||||
|         name: 'OEE' | ||||
|       }) | ||||
|     }, | ||||
|     toMTTR() { | ||||
|       this.$router.push({ | ||||
|         name: 'MTTR' | ||||
|       }) | ||||
|     }, | ||||
|     toMCBF() { | ||||
|       this.$router.push({ | ||||
|         name: 'MCBF' | ||||
|       }) | ||||
|     }, | ||||
|     seeDetail(name) { | ||||
|       this.equipmentName = name | ||||
|       this.mttrVisible = false | ||||
|       this.mttrDetail = true | ||||
|       setTimeout(() => { | ||||
|         this.$refs.mttrDetailChart.getList() | ||||
|       }, 60) | ||||
|     }, | ||||
|     getList() { | ||||
|       if (this.formData.timeSlot.length !== 0) { | ||||
|         this.startTime = this.formData.timeSlot[0] | ||||
|         this.endTime = this.formData.timeSlot[1] | ||||
|         this.$nextTick(() => { | ||||
|           this.mttrVisible = true | ||||
|           setTimeout(() => { | ||||
|             this.$refs.mttrChart.getList() | ||||
|           }, 60) | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/OEE.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										151
									
								
								src/views/EquipmentManager/equipmentUtilizationRate/OEE.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,151 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-16 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 15:26:56 | ||||
|  * @Description: OEE | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="80px" | ||||
|     > | ||||
|       <el-form-item> | ||||
|         <el-button @click="toE10()">E10</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="toOEE()">OEE</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMTTR()">MTTR</el-button> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button @click="toMCBF()">MCBF</el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item :label="$t('module.equipmentManager.recipe.equipmentId')" prop="equipmentName"> | ||||
|         <el-select v-model="formData.equipmentName" :placeholder="$t('module.equipmentManager.recipe.EQselect')" filterable clearable> | ||||
|           <el-option | ||||
|             v-for="(item, index) in eqList" | ||||
|             :key="index" | ||||
|             :label="item.name" | ||||
|             :value="item.name" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> --> | ||||
|       <el-form-item :label="$t('module.equipmentManager.equipmentVisualization.timeSlot')" label-width="100px" prop="time"> | ||||
|         <el-date-picker | ||||
|           v-model="formData.timeSlot" | ||||
|           type="datetimerange" | ||||
|           :start-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :end-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :range-separator="$t('module.orderManage.order.To')" | ||||
|           clearable | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|       <!-- <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.exportBtn' | i18nFilter }} </el-button> | ||||
|       </el-form-item> --> | ||||
|     </el-form> | ||||
|     <oeeChart v-if="oeeVisible" ref="oeeChart" :time1="startTime" :time2="endTime" @equipmentName="seeDetail" /> | ||||
|     <oee-detail-chart v-if="oeeDetail" ref="oeeDetailChart" :time1="startTime" :time2="endTime" :equipment-name="equipmentName" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import oeeChart from './components/oee-chart' | ||||
| import oeeDetailChart from './components/oeeDetail-chart' | ||||
| // import { equipmentList } from '@/api/basicData/Equipment/equipmentInfo' | ||||
|  | ||||
| export default { | ||||
|   name: 'OEE', | ||||
|   components: { oeeChart, oeeDetailChart }, | ||||
|   data() { | ||||
|     return { | ||||
|       list: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       formData: { | ||||
|         timeSlot: [], | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       oeeVisible: false, | ||||
|       oeeDetail: false, | ||||
|       equipmentName: '', | ||||
|       eqList: [] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     // this.getEqList() | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     async getEqList() { | ||||
|       const res = await equipmentList({ | ||||
|         current: 1, | ||||
|         size: 999 | ||||
|       }) | ||||
|       if (res.code === 0) { | ||||
|         this.eqList = res.data | ||||
|       } | ||||
|     }, | ||||
|     toE10() { | ||||
|       this.$router.push({ | ||||
|         name: 'E10' | ||||
|       }) | ||||
|     }, | ||||
|     toOEE() { | ||||
|       this.$router.push({ | ||||
|         name: 'OEE' | ||||
|       }) | ||||
|     }, | ||||
|     toMTTR() { | ||||
|       this.$router.push({ | ||||
|         name: 'MTTR' | ||||
|       }) | ||||
|     }, | ||||
|     toMCBF() { | ||||
|       this.$router.push({ | ||||
|         name: 'MCBF' | ||||
|       }) | ||||
|     }, | ||||
|     seeDetail(name) { | ||||
|       this.equipmentName = name | ||||
|       this.oeeVisible = false | ||||
|       this.oeeDetail = true | ||||
|       setTimeout(() => { | ||||
|         this.$refs.oeeDetailChart.getList() | ||||
|       }, 60) | ||||
|     }, | ||||
|     getList() { | ||||
|       if (this.formData.timeSlot.length !== 0) { | ||||
|         this.startTime = this.formData.timeSlot[0] | ||||
|         this.endTime = this.formData.timeSlot[1] | ||||
|         this.$nextTick(() => { | ||||
|           this.oeeVisible = true | ||||
|           setTimeout(() => { | ||||
|             this.$refs.oeeChart.getList() | ||||
|           }, 60) | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -0,0 +1,134 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:22:24 | ||||
|  * @Description: E10详情表格 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     /> | ||||
|     <pagination :total="total" :page.sync="listQuery.current" :limit.sync="listQuery.size" @pagination="init" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' | ||||
| import { timeFormatter } from '@/filters' | ||||
| // import { getE10StackDetail } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'equipmentName', | ||||
|     label: i18n.t('module.equipmentManager.maintainplan.equipmentId'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.E10status'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'previousStatus', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.laterE10Status'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'endTime', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.E10endTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'durationTime', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.duration'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: '', | ||||
|   components: { BaseTable, Pagination }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       total: 0, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       listLoading: false, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     // this.init() | ||||
|   }, | ||||
|   methods: { | ||||
|     init() { | ||||
|       this.listQuery.startTime = this.time1 | ||||
|       this.listQuery.endTime = this.time2 | ||||
|       this.listQuery.equipmentName = this.equipmentName | ||||
|       getE10StackDetail(this.listQuery).then(res => { | ||||
|         if (res.data !== []) { | ||||
|           this.list = res.data.detail.records | ||||
|           this.total = res.data.detail.total | ||||
|           this.list.forEach(item => { | ||||
|             item.equipmentName = this.equipmentName | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -0,0 +1,94 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:47:23 | ||||
|  * @Description: MCBF详情表格 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <base-table | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
|  | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'tmc', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.allCycles'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'emc', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.badTimes'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'time', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.time'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'mtbf', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.MCBF'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: '', | ||||
|   components: { BaseTable }, | ||||
|   props: { | ||||
|     tableData: { | ||||
|       type: Array, | ||||
|       default: () => { [] } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       total: 0, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       listLoading: false | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     // this.init() | ||||
|   }, | ||||
|   methods: { | ||||
|     init() { | ||||
|       this.list = this.tableData | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -0,0 +1,132 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:46:06 | ||||
|  * @Description: Mttr详情表格 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     /> | ||||
|     <pagination :total="total" :page.sync="listQuery.current" :limit.sync="listQuery.size" @pagination="init" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' | ||||
| import { timeFormatter } from '@/filters' | ||||
| // import { getMttrDetail } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'previousStatus', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.previousStatus'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.art.status'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'startTime', | ||||
|     label: i18n.t('module.equipmentManager.equipmentParams.startTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'endTime', | ||||
|     label: i18n.t('module.equipmentManager.equipmentParams.endTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'durationTime', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.duration'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: '', | ||||
|   components: { BaseTable, Pagination }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       total: 0, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       listLoading: false, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     // this.init() | ||||
|   }, | ||||
|   methods: { | ||||
|     init() { | ||||
|       this.listQuery.startTime = this.time1 | ||||
|       this.listQuery.endTime = this.time2 | ||||
|       this.listQuery.equipmentName = this.equipmentName | ||||
|       getMttrDetail(this.listQuery).then(res => { | ||||
|         if (res.data !== []) { | ||||
|           this.list = res.data.detail.records | ||||
|           this.total = res.data.detail.total | ||||
|         } | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -0,0 +1,100 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:38:52 | ||||
|  * @Description: OEE详情表格 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <base-table | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
|  | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'equipmentName', | ||||
|     label: i18n.t('module.equipmentManager.maintainplan.equipmentId'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'runTime', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.runTime'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'productiveTime', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.produceTime'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'productiveCount', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.productiveCount'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'timeRate', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.timeRate'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'performanceRate', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.performanceRate'), | ||||
|     align: 'center' | ||||
|   }, { | ||||
|     prop: 'oee', | ||||
|     label: i18n.t('module.equipmentManager.monitoringInfo.oee'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: '', | ||||
|   components: { BaseTable }, | ||||
|   props: { | ||||
|     tableData: { | ||||
|       type: Array, | ||||
|       default: () => { [] } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { '' } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       total: 0, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       listLoading: false | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     // this.init() | ||||
|   }, | ||||
|   methods: { | ||||
|     init() { | ||||
|       this.list = this.tableData | ||||
|       if (this.list !== []) { | ||||
|         this.list.forEach(item => { | ||||
|           item.equipmentName = this.equipmentName | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -0,0 +1,212 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 15:43:32 | ||||
|  * @Description: E10折线柱状图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div id="monitorChart" :style="{width: '1000px', height: '800px'}" style="margin-left:10%" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getE10Stack } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| export default { | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     name: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       engineeringList: [], | ||||
|       nonscheduledDownList: [], | ||||
|       productiveList: [], | ||||
|       rampUpDownList: [], | ||||
|       scheduledDownList: [], | ||||
|       standByList: [], | ||||
|       unscheduledDownList: [] | ||||
|     } | ||||
|   }, | ||||
|   mounted() {}, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     removeData() { | ||||
|       this.xDataList = ['ACOT1', 'ACOT2'] | ||||
|       this.engineeringList = [20, 30] | ||||
|       this.nonscheduledDownList = [20, 20] | ||||
|       this.productiveList = [10, 2] | ||||
|       this.rampUpDownList = [30, 3] | ||||
|       this.scheduledDownList = [8, 15] | ||||
|       this.standByList = [2, 12] | ||||
|       this.unscheduledDownList = [10, 18] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.removeData() | ||||
|       this.init() | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|       const that = this | ||||
|       that.chart.on('click', function(params) { | ||||
|         that.$emit('equipmentName', params.name) | ||||
|       }) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           max: 10, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: { | ||||
|           type: 'value', | ||||
|           min: 0, | ||||
|           max: 100, | ||||
|           axisLabel: { | ||||
|             formatter: '{value}%' | ||||
|           } | ||||
|         }, | ||||
|         series: [ | ||||
|           { | ||||
|             name: 'engineering', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             barWidth: 40, | ||||
|             data: this.engineeringList | ||||
|           }, | ||||
|           { | ||||
|             name: 'nonscheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.nonscheduledDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'productive', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.productiveList | ||||
|           }, | ||||
|           { | ||||
|             name: 'rampUpDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.rampUpDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'scheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.scheduledDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'standBy', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.standByList | ||||
|           }, | ||||
|           { | ||||
|             name: 'unscheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.unscheduledDownList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,253 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:26:34 | ||||
|  * @Description: E10详情堆积图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div> | ||||
|       <el-button-group> | ||||
|         <el-button @click="byYear">年</el-button> | ||||
|         <el-button @click="byQuarterly">季度</el-button> | ||||
|         <el-button @click="byMonth">月</el-button> | ||||
|         <el-button @click="byWeek">周</el-button> | ||||
|         <el-button @click="byDay">天</el-button> | ||||
|       </el-button-group> | ||||
|     </div> | ||||
|     <div id="monitorChart" :style="{width: '700px', height: '550px'}" style="margin-left:10%" /> | ||||
|     <e10-table v-if="tableVisible" :time1="startTime" :time2="endTime" :equipment-name="name" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getE10StackDetail } from '@/api/equipment/infoPandect' | ||||
| import E10Table from './E10Table' | ||||
|  | ||||
| export default { | ||||
|   components: { E10Table }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       tableVisible: false, | ||||
|       equipmentDetail: [], | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       engineeringList: [], | ||||
|       nonscheduledDownList: [], | ||||
|       productiveList: [], | ||||
|       rampUpDownList: [], | ||||
|       scheduledDownList: [], | ||||
|       standByList: [], | ||||
|       unscheduledDownList: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       name: '' | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     this.startTime = this.time1 | ||||
|     this.endTime = this.time2 | ||||
|     this.name = this.equipmentName | ||||
|   }, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     getDataList(params) { | ||||
|       console.log(params) | ||||
|     }, | ||||
|     byYear() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.年) | ||||
|     }, | ||||
|     byQuarterly() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.季度) | ||||
|     }, | ||||
|     byMonth() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.月) | ||||
|     }, | ||||
|     byWeek() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.周) | ||||
|     }, | ||||
|     byDay() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.天) | ||||
|     }, | ||||
|     setChart(list) { | ||||
|       this.init() | ||||
|     }, | ||||
|     removeData() { | ||||
|       // this.xDataList = [this.name] | ||||
|       this.engineeringList = [20] | ||||
|       this.nonscheduledDownList = [20] | ||||
|       this.productiveList = [10] | ||||
|       this.rampUpDownList = [30] | ||||
|       this.scheduledDownList = [8] | ||||
|       this.standByList = [2] | ||||
|       this.unscheduledDownList = [10] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.xDataList = [this.name] | ||||
|       this.tableVisible = true | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|  | ||||
|       this.chart.on('click', function(params) { | ||||
|         console.log('113d', params.name) | ||||
|       }) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           max: 10, | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: { | ||||
|           type: 'value' | ||||
|         }, | ||||
|         series: [ | ||||
|           { | ||||
|             name: 'engineering', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.engineeringList | ||||
|           }, | ||||
|           { | ||||
|             name: 'nonscheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.nonscheduledDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'productive', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.productiveList | ||||
|           }, | ||||
|           { | ||||
|             name: 'rampUpDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.rampUpDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'scheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.scheduledDownList | ||||
|           }, | ||||
|           { | ||||
|             name: 'standBy', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.standByList | ||||
|           }, | ||||
|           { | ||||
|             name: 'unscheduledDown', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.unscheduledDownList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,137 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:48:01 | ||||
|  * @Description: Mcbf折线柱状图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div id="monitorChart" :style="{width: '1000px', height: '800px'}" style="margin-left:10%" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getAllMtbf } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| export default { | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       yDataList: [] | ||||
|     } | ||||
|   }, | ||||
|   mounted() {}, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     removeData() { | ||||
|       this.xDataList = ['ACOT1', 'ACOT2', 'ACOT-a', 'ACOT-b'] | ||||
|       this.yDataList = [22, 40, 66, 44] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.removeData() | ||||
|       this.init() | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|       const that = this | ||||
|       that.chart.on('click', function(params) { | ||||
|         that.$emit('equipmentName', params.name) | ||||
|       }) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           max: 10, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: [{ | ||||
|           type: 'value', | ||||
|           min: 0, | ||||
|           max: 100, | ||||
|           axisLabel: { | ||||
|             formatter: '{value}次' | ||||
|           } | ||||
|         }, | ||||
|         { | ||||
|           type: 'value', | ||||
|           min: 0, | ||||
|           max: 100, | ||||
|           axisLabel: { | ||||
|             formatter: '{value}次' | ||||
|           } | ||||
|         } | ||||
|         ], | ||||
|         series: [ | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             barWidth: 40, | ||||
|             data: this.yDataList | ||||
|           }, | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'line', | ||||
|             yAxisIndex: 1, | ||||
|             data: this.yDataList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,185 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:48:53 | ||||
|  * @Description: MCBF详情堆积图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div> | ||||
|       <el-button-group> | ||||
|         <el-button @click="byYear">年</el-button> | ||||
|         <el-button @click="byQuarterly">季度</el-button> | ||||
|         <el-button @click="byMonth">月</el-button> | ||||
|         <el-button @click="byWeek">周</el-button> | ||||
|         <el-button @click="byDay">天</el-button> | ||||
|       </el-button-group> | ||||
|     </div> | ||||
|     <div id="monitorChart" :style="{width: '700px', height: '550px'}" style="margin-left:10%" /> | ||||
|     <mcbf-table v-if="tableVisible" ref="tableRef" :table-data="tableData" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getMcbfDetail } from '@/api/equipment/infoPandect' | ||||
| import McbfTable from './McbfTable' | ||||
|  | ||||
| export default { | ||||
|   components: { McbfTable }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       tableVisible: false, | ||||
|       tableData: [], | ||||
|       equipmentDetail: [], | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       yDataList: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       name: '' | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     this.startTime = this.time1 | ||||
|     this.endTime = this.time2 | ||||
|     this.name = this.equipmentName | ||||
|   }, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     getDataList(params) { | ||||
|       console.log(params) | ||||
|     }, | ||||
|     byYear() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.年) | ||||
|       this.tableData = this.list.年 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byQuarterly() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.季度) | ||||
|       this.tableData = this.list.季度 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byMonth() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.月) | ||||
|       this.tableData = this.list.月 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byWeek() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.周) | ||||
|       this.tableData = this.list.周 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byDay() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.天) | ||||
|       this.tableData = this.list.天 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     setChart(list) { | ||||
|       this.init() | ||||
|     }, | ||||
|     removeData() { | ||||
|       this.xDataList = [this.name] | ||||
|       this.yDataList = [11, 33, 20, 53, 24] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.tableVisible = true | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           max: 10, | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: { | ||||
|           type: 'value' | ||||
|         }, | ||||
|         series: [ | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'line', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.yDataList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,133 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:41:38 | ||||
|  * @Description: MTTR折线柱状图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div id="monitorChart" :style="{width: '1000px', height: '800px'}" style="margin-left:10%" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getMttr } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| export default { | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       yDataList: [] | ||||
|     } | ||||
|   }, | ||||
|   mounted() {}, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     removeData() { | ||||
|       this.xDataList = ['ACOT1', 'ACOT2', 'ACOT-a', 'ACOT-b'] | ||||
|       this.yDataList = [22, 40, 66, 44] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.removeData() | ||||
|       this.init() | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|       const that = this | ||||
|       that.chart.on('click', function(params) { | ||||
|         that.$emit('equipmentName', params.name) | ||||
|       }) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           max: 10, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: [{ | ||||
|           type: 'value', | ||||
|           axisLabel: { | ||||
|             formatter: '{value}小时' | ||||
|           } | ||||
|         }, | ||||
|         { | ||||
|           type: 'value', | ||||
|           axisLabel: { | ||||
|             formatter: '{value}小时' | ||||
|           } | ||||
|         } | ||||
|         ], | ||||
|         series: [ | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             barWidth: 40, | ||||
|             data: this.yDataList | ||||
|           }, | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'line', | ||||
|             yAxisIndex: 1, | ||||
|             data: this.yDataList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,165 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:43:34 | ||||
|  * @Description: MTTR详情堆积图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div> | ||||
|       <el-button-group> | ||||
|         <el-button @click="byYear">年</el-button> | ||||
|         <el-button @click="byQuarterly">季度</el-button> | ||||
|         <el-button @click="byMonth">月</el-button> | ||||
|         <el-button @click="byWeek">周</el-button> | ||||
|         <el-button @click="byDay">天</el-button> | ||||
|       </el-button-group> | ||||
|     </div> | ||||
|     <div id="monitorChart" :style="{width: '700px', height: '550px'}" style="margin-left:10%" /> | ||||
|     <mttr-table v-if="tableVisible" :time1="startTime" :time2="endTime" :equipment-name="name" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getMttrDetail } from '@/api/equipment/infoPandect' | ||||
| import MttrTable from './MttrTable' | ||||
|  | ||||
| export default { | ||||
|   components: { MttrTable }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       tableVisible: false, | ||||
|       equipmentDetail: [], | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       yDataList: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       name: '' | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     this.startTime = this.time1 | ||||
|     this.endTime = this.time2 | ||||
|     this.name = this.equipmentName | ||||
|     this.removeData() | ||||
|   }, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     getDataList(params) { | ||||
|       console.log(params) | ||||
|     }, | ||||
|     byYear() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.年) | ||||
|     }, | ||||
|     byQuarterly() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.季度) | ||||
|     }, | ||||
|     byMonth() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.月) | ||||
|     }, | ||||
|     byWeek() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.周) | ||||
|     }, | ||||
|     byDay() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.天) | ||||
|     }, | ||||
|     setChart(list) { | ||||
|       this.init() | ||||
|     }, | ||||
|     removeData() { | ||||
|       this.xDataList = [this.name] | ||||
|       this.yDataList = [30, 40, 30, 33, 44] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.tableVisible = true | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           max: 10, | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: { | ||||
|           type: 'value' | ||||
|         }, | ||||
|         series: [ | ||||
|           { | ||||
|             name: '稼动率值', | ||||
|             type: 'line', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.yDataList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,137 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:34:30 | ||||
|  * @Description: OEE折线柱状图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div id="monitorChart" :style="{width: '1000px', height: '800px'}" style="margin-left:10%" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getOEE } from '@/api/equipment/infoPandect' | ||||
|  | ||||
| export default { | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       oeeList: [] | ||||
|     } | ||||
|   }, | ||||
|   mounted() {}, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     removeData() { | ||||
|       this.xDataList = ['ACOT1', 'ACOT2', 'ACOT-a', 'ACOT-b'] | ||||
|       this.oeeList = [20, 30, 80, 44] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.removeData() | ||||
|       this.init() | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|       const that = this | ||||
|       that.chart.on('click', function(params) { | ||||
|         that.$emit('equipmentName', params.name) | ||||
|       }) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           max: 10, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: [{ | ||||
|           type: 'value', | ||||
|           min: 0, | ||||
|           max: 100, | ||||
|           axisLabel: { | ||||
|             formatter: '{value}%' | ||||
|           } | ||||
|         }, | ||||
|         { | ||||
|           type: 'value', | ||||
|           min: 0, | ||||
|           max: 100, | ||||
|           axisLabel: { | ||||
|             formatter: '{value}%' | ||||
|           } | ||||
|         } | ||||
|         ], | ||||
|         series: [ | ||||
|           { | ||||
|             name: 'oee', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             barWidth: 40, | ||||
|             data: this.oeeList | ||||
|           }, | ||||
|           { | ||||
|             name: 'oee', | ||||
|             type: 'line', | ||||
|             yAxisIndex: 1, | ||||
|             data: this.oeeList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,258 @@ | ||||
| <!-- | ||||
|  * @Author: DY | ||||
|  * @Date: 2021-12-13 16:39:34 | ||||
|  * @LastEditors: DY | ||||
|  * @LastEditTime: 2022-03-03 16:37:49 | ||||
|  * @Description:OEE详情堆积图 | ||||
| --> | ||||
| <template> | ||||
|   <div> | ||||
|     <div> | ||||
|       <el-button-group> | ||||
|         <el-button @click="byYear">年</el-button> | ||||
|         <el-button @click="byQuarterly">季度</el-button> | ||||
|         <el-button @click="byMonth">月</el-button> | ||||
|         <el-button @click="byWeek">周</el-button> | ||||
|         <el-button @click="byDay">天</el-button> | ||||
|       </el-button-group> | ||||
|     </div> | ||||
|     <div id="monitorChart" :style="{width: '700px', height: '550px'}" style="margin-left:10%" /> | ||||
|     <oee-table v-if="tableVisible" ref="tableRef" :table-data="tableData" :equipment-name="name" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import echarts from 'echarts' | ||||
| // import { getOEEDetail } from '@/api/equipment/infoPandect' | ||||
| import OeeTable from './OeeTable' | ||||
|  | ||||
| export default { | ||||
|   components: { OeeTable }, | ||||
|   props: { | ||||
|     time1: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     time2: { | ||||
|       type: Date, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     }, | ||||
|     equipmentName: { | ||||
|       type: String, | ||||
|       default: () => { | ||||
|         return '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       chart: null, | ||||
|       tableVisible: false, | ||||
|       equipmentDetail: [], | ||||
|       tableData: [], | ||||
|       list: [], | ||||
|       xDataList: [], | ||||
|       oeeList: [], | ||||
|       startTime: '', | ||||
|       endTime: '', | ||||
|       name: '' | ||||
|     } | ||||
|   }, | ||||
|   mounted() { | ||||
|     this.startTime = this.time1 | ||||
|     this.endTime = this.time2 | ||||
|     this.name = this.equipmentName | ||||
|     this.removeData() | ||||
|   }, | ||||
|   beforeDestroy() { | ||||
|     if (!this.chart) { | ||||
|       return | ||||
|     } | ||||
|     this.chart.dispose() | ||||
|     this.chart = null | ||||
|   }, | ||||
|   methods: { | ||||
|     getDataList(params) { | ||||
|       console.log(params) | ||||
|     }, | ||||
|     async byYear() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.年) | ||||
|       this.tableData = this.list.年 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byQuarterly() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.季度) | ||||
|       this.tableData = this.list.季度 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byMonth() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.月) | ||||
|       this.tableData = this.list.月 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byWeek() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.周) | ||||
|       this.tableData = this.list.周 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     byDay() { | ||||
|       this.removeData() | ||||
|       this.setChart(this.list.天) | ||||
|       this.tableData = this.list.天 | ||||
|       setTimeout(() => { | ||||
|         this.$refs.tableRef.init() | ||||
|       }, 60) | ||||
|     }, | ||||
|     setChart(list) { | ||||
|       this.init() | ||||
|     }, | ||||
|     removeData() { | ||||
|       this.xDataList = [this.name] | ||||
|       this.oeeList = [30, 40, 30, 33, 44] | ||||
|     }, | ||||
|     getList() { | ||||
|       this.tableVisible = true | ||||
|     }, | ||||
|     init() { | ||||
|       this.chart = echarts.init(document.getElementById('monitorChart')) | ||||
|  | ||||
|       this.chart.setOption({ | ||||
|         tooltip: { | ||||
|           trigger: 'axis', | ||||
|           axisPointer: { | ||||
|             type: 'cross', | ||||
|             crossStyle: { | ||||
|               color: '#999' | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         toolbox: { | ||||
|           feature: { | ||||
|             saveAsImage: { show: true } | ||||
|           } | ||||
|         }, | ||||
|         grid: { | ||||
|           left: '3%', | ||||
|           right: '4%', | ||||
|           bottom: '3%', | ||||
|           containLabel: true | ||||
|         }, | ||||
|         xAxis: { | ||||
|           type: 'category', | ||||
|           max: 10, | ||||
|           axisLabel: { | ||||
|             interval: 0, | ||||
|             rotate: -30 | ||||
|           }, | ||||
|           data: this.xDataList | ||||
|         }, | ||||
|         yAxis: { | ||||
|           type: 'value' | ||||
|         }, | ||||
|         series: [ | ||||
|           { | ||||
|             name: 'oee', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.oeeList | ||||
|           }, | ||||
|           { | ||||
|             name: 'performanceRate', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.performanceRateList | ||||
|           }, | ||||
|           { | ||||
|             name: 'productiveCount', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.productiveCountList | ||||
|           }, | ||||
|           { | ||||
|             name: 'productiveTime', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.productiveTimeList | ||||
|           }, | ||||
|           { | ||||
|             name: 'runTime', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.runTimeList | ||||
|           }, | ||||
|           { | ||||
|             name: 'time', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.timeList | ||||
|           }, | ||||
|           { | ||||
|             name: 'timeRate', | ||||
|             type: 'bar', | ||||
|             stack: 'total', | ||||
|             label: { | ||||
|               show: true | ||||
|             }, | ||||
|             emphasis: { | ||||
|               focus: 'series' | ||||
|             }, | ||||
|             data: this.timeRateList | ||||
|           } | ||||
|         ] | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										178
									
								
								src/views/QualityManager/QCPplan.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										178
									
								
								src/views/QualityManager/QCPplan.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,178 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-03-03 14:28:58 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <head-form | ||||
|       :placeholder-name="placeholderName" | ||||
|       :key-name="keyName" | ||||
|       :show-add="showAdd" | ||||
|       @getDataList="getList" | ||||
|       @add="addNew" | ||||
|     /> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="listQuery.current" | ||||
|       :limit.sync="listQuery.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import i18n from '@/lang' | ||||
| import { StateConfigList, StateConfigDelete } from '@/api/basicData/StateConfig' | ||||
| import HeadForm from '@/components/basicData/HeadForm' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import { timeFormatter } from '@/filters' | ||||
| import basicData from '@/filters/basicData' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'edit', | ||||
|     btnName: 'btn.edit' | ||||
|   } | ||||
|   // { | ||||
|   //   type: 'delete', | ||||
|   //   btnName: 'btn.delete' | ||||
|   // } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.factory.createTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.StateConfig.status'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'twinkle', | ||||
|     label: i18n.t('module.basicData.StateConfig.Twinkle'), | ||||
|     filter: basicData('onDuty'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'colour', | ||||
|     label: i18n.t('module.basicData.StateConfig.DisplayColor'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'description', | ||||
|     label: i18n.t('module.basicData.visual.Remarks'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'QCPplan', | ||||
|   components: { Pagination, BaseTable, MethodBtn, HeadForm }, | ||||
|   data() { | ||||
|     return { | ||||
|       keyName: i18n.t('module.basicData.visual.keyword'), | ||||
|       placeholderName: this.$t('module.basicData.StateConfig.status'), | ||||
|       addOrUpdateVisible: false, | ||||
|       tableBtn, | ||||
|       trueWidth: 150, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       showAdd: false, | ||||
|       listLoading: true, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     handleClick(raw) { | ||||
|       console.log(raw) | ||||
|       if (raw.type === 'delete') { | ||||
|         this.$confirm(`${this.$t('module.basicData.visual.TipsBefore')}[${raw.data.status}]?`, this.$t('module.basicData.visual.Tips'), { | ||||
|           confirmButtonText: this.$t('module.basicData.visual.confirmButtonText'), | ||||
|           cancelButtonText: this.$t('module.basicData.visual.cancelButtonText'), | ||||
|           type: 'warning' | ||||
|         }).then(() => { | ||||
|           StateConfigDelete(raw.data.id).then(response => { | ||||
|             this.$message({ | ||||
|               message: this.$t('module.basicData.visual.success'), | ||||
|               type: 'success', | ||||
|               duration: 1500, | ||||
|               onClose: () => { | ||||
|                 this.getList() | ||||
|               } | ||||
|             }) | ||||
|           }) | ||||
|         }).catch(() => {}) | ||||
|       } | ||||
|     }, | ||||
|     getList(key) { | ||||
|       this.listLoading = true | ||||
|       this.listQuery.status = key | ||||
|       StateConfigList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
| @@ -13,11 +13,11 @@ | ||||
|               {{ i.equipmentId ? equipmentObj[i.equipmentId] : $t('module.art.eqName') }} | ||||
|             </el-button> | ||||
|           </el-col> | ||||
|           <el-col :span="4" class="process-table-main-item-item"> | ||||
|           <!-- <el-col :span="4" class="process-table-main-item-item"> | ||||
|             <el-button v-if="!processPortObj[item.workSequenceId]" disabled> | ||||
|               {{ i.equipmentRecipeId ? equipmentRecipeObj[i.equipmentRecipeId] : $t('module.art.recipeName') }} | ||||
|             </el-button> | ||||
|           </el-col> | ||||
|           </el-col> --> | ||||
|           <!-- <el-col :span="4" class="process-table-main-item-item"> | ||||
|             <el-button v-if="!processPortObj[item.workSequenceId]" disabled> | ||||
|               {{ i.nodeType ? nodeTypesObj[i.nodeType] : $t('module.art.artType') }} | ||||
| @@ -36,7 +36,7 @@ | ||||
| </template> | ||||
| <script> | ||||
| import { | ||||
|   listAllEquipmentRecipe, | ||||
|   // listAllEquipmentRecipe, | ||||
|   listProcessFlowNode, | ||||
|   listProcess | ||||
| } from '@/api/art-manage/art.js' | ||||
| @@ -57,7 +57,7 @@ export default { | ||||
|       processObj: {}, | ||||
|       processPortObj: {}, | ||||
|       equipmentRecipeList: [], | ||||
|       equipmentRecipeObj: [], | ||||
|       // equipmentRecipeObj: [], | ||||
|       equipmentList: [], | ||||
|       equipmentObj: {}, | ||||
|       showAddList: [], | ||||
| @@ -102,12 +102,12 @@ export default { | ||||
|       console.log(this.processList) | ||||
|       console.log(this.processObj) | ||||
|       // 获取配方列表 | ||||
|       const allRecipeRes = await listAllEquipmentRecipe() | ||||
|       this.equipmentRecipeList = allRecipeRes.data | ||||
|       allRecipeRes.data.map(item => { | ||||
|         this.equipmentRecipeObj[item.id] = item.name | ||||
|       }) | ||||
|       console.log(this.equipmentRecipeList) | ||||
|       // const allRecipeRes = await listAllEquipmentRecipe() | ||||
|       // this.equipmentRecipeList = allRecipeRes.data | ||||
|       // allRecipeRes.data.map(item => { | ||||
|       //   this.equipmentRecipeObj[item.id] = item.name | ||||
|       // }) | ||||
|       // console.log(this.equipmentRecipeList) | ||||
|       // 获取设备列表 | ||||
|       const allEquipmentRes = await listEquipment() | ||||
|       this.equipmentList = allEquipmentRes.data | ||||
|   | ||||
| @@ -19,11 +19,11 @@ | ||||
|                 {{ i.equipmentId ? equipmentObj[i.equipmentId] : $t('module.art.eqName') }} | ||||
|               </el-button> | ||||
|             </el-col> | ||||
|             <el-col :span="4" class="process-table-main-item-item"> | ||||
|             <!-- <el-col :span="4" class="process-table-main-item-item"> | ||||
|               <el-button v-if="!processPortObj[item.workSequenceId]" icon="el-icon-edit" @click="choiceRecipe(index, idx, i.equipmentRecipeId)"> | ||||
|                 {{ i.equipmentRecipeId ? equipmentRecipeObj[i.equipmentRecipeId] : $t('module.art.recipeName') }} | ||||
|               </el-button> | ||||
|             </el-col> | ||||
|             </el-col> --> | ||||
|             <!-- <el-col :span="4" class="process-table-main-item-item"> | ||||
|               <el-button v-if="!processPortObj[item.workSequenceId]" icon="el-icon-edit" @click="choiceArtType(index, idx, i.nodeType)"> | ||||
|                 {{ i.nodeType ? nodeTypesObj[i.nodeType] : $t('module.art.artType') }} | ||||
| @@ -55,7 +55,7 @@ import processTableSelect from './process-table-select.vue' | ||||
| import processTableAdd from './process-table-add.vue' | ||||
| import vuedraggable from 'vuedraggable' | ||||
| import { | ||||
|   listAllEquipmentRecipe, | ||||
|   // listAllEquipmentRecipe, | ||||
|   addProcessFlows, | ||||
|   listProcessFlowNode, | ||||
|   listProcess | ||||
| @@ -82,7 +82,7 @@ export default { | ||||
|       processObj: {}, | ||||
|       processPortObj: {}, | ||||
|       equipmentRecipeList: [], | ||||
|       equipmentRecipeObj: [], | ||||
|       // equipmentRecipeObj: [], | ||||
|       equipmentList: [], | ||||
|       equipmentObj: {}, | ||||
|       showAddList: [], | ||||
| @@ -131,12 +131,12 @@ export default { | ||||
|       console.log(this.processList) | ||||
|       console.log(this.processObj) | ||||
|       // 获取配方列表 | ||||
|       const allRecipeRes = await listAllEquipmentRecipe() | ||||
|       this.equipmentRecipeList = allRecipeRes.data | ||||
|       allRecipeRes.data.map(item => { | ||||
|         this.equipmentRecipeObj[item.id] = item.name | ||||
|       }) | ||||
|       console.log(this.equipmentRecipeList) | ||||
|       // const allRecipeRes = await listAllEquipmentRecipe() | ||||
|       // this.equipmentRecipeList = allRecipeRes.data | ||||
|       // allRecipeRes.data.map(item => { | ||||
|       //   this.equipmentRecipeObj[item.id] = item.name | ||||
|       // }) | ||||
|       // console.log(this.equipmentRecipeList) | ||||
|       // 获取设备列表 | ||||
|       const allEquipmentRes = await listEquipment() | ||||
|       this.equipmentList = allEquipmentRes.data | ||||
| @@ -197,8 +197,8 @@ export default { | ||||
|         nodeType: '', | ||||
|         processFlowId: this.processFlowId, | ||||
|         workSequenceId: this.dataList[index].workSequenceId, | ||||
|         description: this.dataList[index].processFlowEquipmentParams[0]?.description ? this.dataList[index].processFlowEquipmentParams[0].description : '', | ||||
|         remark: this.dataList[index].processFlowEquipmentParams[0]?.remark ? this.dataList[index].processFlowEquipmentParams[0].remark : '' | ||||
|         description: this.dataList[index].processFlowEquipmentParams[0].description ? this.dataList[index].processFlowEquipmentParams[0].description : '', | ||||
|         remark: this.dataList[index].processFlowEquipmentParams[0].remark ? this.dataList[index].processFlowEquipmentParams[0].remark : '' | ||||
|       }) | ||||
|       e.stopPropagation() | ||||
|     }, | ||||
| @@ -232,16 +232,16 @@ export default { | ||||
|       this.$refs.processtableselect.init('equipmentId', first, sec, id, this.processObj[processId].equipments) | ||||
|     }, | ||||
|     // 选择配方 | ||||
|     choiceRecipe(first, sec, id) { | ||||
|       if (this.dataList[first].processFlowEquipmentParams[sec]?.equipmentId) { | ||||
|         this.$refs.processtableselect.init('equipmentRecipeId', first, sec, id, this.equipmentRecipeList.filter(f => f.equipmentId === this.dataList[first].processFlowEquipmentParams[sec].equipmentId)) | ||||
|       } else { | ||||
|         this.$message.error(this.$t('module.art.choiceEqError')) | ||||
|       } | ||||
|     }, | ||||
|     // choiceRecipe(first, sec, id) { | ||||
|     //   if (this.dataList[first].processFlowEquipmentParams[sec]?.equipmentId) { | ||||
|     //     this.$refs.processtableselect.init('equipmentRecipeId', first, sec, id, this.equipmentRecipeList.filter(f => f.equipmentId === this.dataList[first].processFlowEquipmentParams[sec].equipmentId)) | ||||
|     //   } else { | ||||
|     //     this.$message.error(this.$t('module.art.choiceEqError')) | ||||
|     //   } | ||||
|     // }, | ||||
|     // 选择工艺类型 | ||||
|     choiceArtType(first, sec, id) { | ||||
|       if (this.dataList[first].processFlowEquipmentParams[sec]?.equipmentId) { | ||||
|       if (this.dataList[first].processFlowEquipmentParams[sec].equipmentId) { | ||||
|         this.$refs.processtableselect.init('nodeType', first, sec, id, this.nodeTypes) | ||||
|       } else { | ||||
|         this.$message.error(this.$t('module.art.choiceEqError')) | ||||
| @@ -307,13 +307,14 @@ export default { | ||||
|               hasNull = true | ||||
|             } | ||||
|           }) | ||||
|         } else { | ||||
|           item.processFlowEquipmentParams.map(i => { | ||||
|             if (!i.equipmentId || !i.equipmentRecipeId) { | ||||
|               hasNull = true | ||||
|             } | ||||
|           }) | ||||
|         } | ||||
|         // else { | ||||
|         //   item.processFlowEquipmentParams.map(i => { | ||||
|         //     if (!i.equipmentId || !i.equipmentRecipeId) { | ||||
|         //       hasNull = true | ||||
|         //     } | ||||
|         //   }) | ||||
|         // } | ||||
|       }) | ||||
|       // console.log(JSON.stringify(vm.dataList)) | ||||
|       // if (vm.dataList.length === 0) { | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-03-25 16:09:59 | ||||
|  * @LastEditTime: 2022-01-11 15:48:58 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
| @@ -44,6 +44,7 @@ import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import { timeFormatter } from '@/filters' | ||||
|  | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
| @@ -82,7 +83,7 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     prop: 'tareaName', | ||||
|     label: i18n.t('module.basicData.cache.CacheName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-04-28 10:07:44 | ||||
|  * @LastEditTime: 2022-01-11 16:26:29 | ||||
|  * @enName: | ||||
| --> | ||||
| <template> | ||||
| @@ -16,8 +16,8 @@ | ||||
|         label-width="140px" | ||||
|       > | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.cache.CacheName')" prop="name"> | ||||
|             <el-input v-model="dataForm.name" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.CacheName')])" clearable :style="{width: '100%'}" /> | ||||
|           <el-form-item :label="$t('module.basicData.cache.CacheName')" prop="tareaName"> | ||||
|             <el-input v-model="dataForm.tareaName" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.CacheName')])" clearable :style="{width: '100%'}" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
| @@ -36,64 +36,14 @@ | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.Manufacturer')" prop="manufacturer"> | ||||
|             <el-input | ||||
|               v-model="dataForm.manufacturer" | ||||
|               :disabled="isdetail" | ||||
|               :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Manufacturer')])" | ||||
|               clearable | ||||
|               :style="{width: '100%'}" | ||||
|             /> | ||||
|           <el-form-item :label="$t('module.basicData.visual.Specs')" prop="spec"> | ||||
|             <el-input v-model="dataForm.spec" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Specs')])" clearable :style="{width: '100%'}" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.Specs')" prop="description"> | ||||
|             <el-input v-model="dataForm.description" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Specs')])" clearable :style="{width: '100%'}" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.productionTime')" prop="productionTime"> | ||||
|             <el-date-picker | ||||
|               v-model="dataForm.productionTime" | ||||
|               :disabled="isdetail" | ||||
|               format="yyyy-MM-dd" | ||||
|               value-format="yyyy-MM-dd" | ||||
|               :style="{width: '100%'}" | ||||
|               :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.productionTime')])" | ||||
|               clearable | ||||
|             /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.enterTime')" prop="enterTime"> | ||||
|             <el-date-picker | ||||
|               v-model="dataForm.enterTime" | ||||
|               :disabled="isdetail" | ||||
|               format="yyyy-MM-dd" | ||||
|               value-format="yyyy-MM-dd" | ||||
|               :style="{width: '100%'}" | ||||
|               :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.enterTime')])" | ||||
|               clearable | ||||
|             /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.debugTime')" prop="debugTime"> | ||||
|             <el-date-picker | ||||
|               v-model="dataForm.debugTime" | ||||
|               :disabled="isdetail" | ||||
|               format="yyyy-MM-dd" | ||||
|               value-format="yyyy-MM-dd" | ||||
|               :style="{width: '100%'}" | ||||
|               :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.debugTime')])" | ||||
|               clearable | ||||
|             /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.CurrentState')" prop="currentStatus"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.CurrentState')" prop="status"> | ||||
|             <el-select | ||||
|               v-model="dataForm.currentStatus" | ||||
|               v-model="dataForm.status" | ||||
|               :disabled="isdetail" | ||||
|               :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.CurrentState')])" | ||||
|               clearable | ||||
| @@ -110,18 +60,18 @@ | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.cache.StockNumber')" prop="stockNumber"> | ||||
|             <el-input-number v-model="dataForm.stockNumber" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.StockNumber')])" :step="1" /> | ||||
|           <el-form-item :label="$t('module.basicData.cache.StockNumber')" prop="locationNum"> | ||||
|             <el-input-number v-model="dataForm.locationNum" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.StockNumber')])" :step="1" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.cache.AreaNumber')" prop="areaNumber"> | ||||
|             <el-input-number v-model="dataForm.areaNumber" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.AreaNumber')])" :step="1" /> | ||||
|           <el-form-item :label="$t('module.basicData.cache.AreaNumber')" prop="shelfNum"> | ||||
|             <el-input-number v-model="dataForm.shelfNum" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.AreaNumber')])" :step="1" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item :label="$t('module.basicData.visual.Remarks')" prop="remark"> | ||||
|             <el-input v-model="dataForm.remark" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Remarks')])" clearable :style="{width: '100%'}" /> | ||||
|           <el-form-item :label="$t('module.basicData.visual.Remarks')" prop="note"> | ||||
|             <el-input v-model="dataForm.note" :disabled="isdetail" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Remarks')])" clearable :style="{width: '100%'}" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|       </el-form> | ||||
| @@ -130,7 +80,7 @@ | ||||
|       <el-button type="success" @click="goback()">{{ 'btn.back' | i18nFilter }}</el-button> | ||||
|       <span v-if="!isdetail"> | ||||
|         <el-button type="primary" @click="dataFormSubmit()">{{ 'btn.save' | i18nFilter }}</el-button> | ||||
|         <el-button v-if="listQuery.cacheId" type="primary" @click="addNew()">{{ $t('module.basicData.cache.addCacheArea') }}</el-button> | ||||
|         <el-button v-if="listQuery.id" type="primary" @click="addNew()">{{ $t('module.basicData.cache.addCacheArea') }}</el-button> | ||||
|       </span> | ||||
|     </div> | ||||
|     <div style="height:380px;overflow:auto"> | ||||
| @@ -148,7 +98,7 @@ | ||||
|         /> | ||||
|       </base-table> | ||||
|     </div> | ||||
|     <cacheArea-add v-if="addOrUpdateVisible" ref="addOrUpdate" :cache-id="listQuery.cacheId" @refreshDataList="getList" /> | ||||
|     <shelfAttr-add v-if="addOrUpdateVisible" ref="addOrUpdate" :cache-id="listQuery.id" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| @@ -157,9 +107,8 @@ import { cacheDetail, cacheUpdate, cacheAdd, cacheCode } from '@/api/basicData/C | ||||
| import { areaList, areaDelete } from '@/api/basicData/Cache/area' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import cacheAreaAdd from './cacheArea-add.vue' | ||||
| import shelfAttrAdd from './shelfAttr-add.vue' | ||||
| import shelfBtn from './shelfBtn.vue' | ||||
| import { timeFormatter } from '@/filters' | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'edit', | ||||
| @@ -171,12 +120,6 @@ const tableBtn = [ | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.factory.createTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     label: i18n.t('module.basicData.cache.AreaName'), | ||||
| @@ -188,20 +131,30 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'areaNumber', | ||||
|     prop: 'shelfNum', | ||||
|     label: i18n.t('module.basicData.cache.StorageQuantity'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'rowNum', | ||||
|     label: i18n.t('module.basicData.cache.rowNum'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'columnNum', | ||||
|     label: i18n.t('module.basicData.cache.columnNum'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'shelf', | ||||
|     label: i18n.t('module.basicData.cache.Shelf'), | ||||
|     label: i18n.t('module.basicData.cache.Location'), | ||||
|     subcomponent: shelfBtn, | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   components: { BaseTable, MethodBtn, cacheAreaAdd }, | ||||
|   components: { BaseTable, MethodBtn, shelfAttrAdd }, | ||||
|   data() { | ||||
|     return { | ||||
|       addOrUpdateVisible: false, | ||||
| @@ -210,27 +163,23 @@ export default { | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       dataForm: { | ||||
|         name: '', | ||||
|         tareaName: '', | ||||
|         code: '', | ||||
|         enName: '', | ||||
|         abbr: '', | ||||
|         manufacturer: '', | ||||
|         description: '', | ||||
|         productionTime: '', | ||||
|         enterTime: '', | ||||
|         debugTime: '', | ||||
|         currentStatus: '', | ||||
|         stockNumber: '', | ||||
|         areaNumber: '', | ||||
|         remark: '' | ||||
|         spec: '', | ||||
|         status: '', | ||||
|         locationNum: '', | ||||
|         shelfNum: '', | ||||
|         note: '' | ||||
|       }, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 990, | ||||
|         cacheId: '' | ||||
|         id: '' | ||||
|       }, | ||||
|       rules: { | ||||
|         name: [{ | ||||
|         tareaName: [{ | ||||
|           required: true, | ||||
|           message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.cache.CacheName')]), | ||||
|           trigger: 'blur' | ||||
| @@ -243,35 +192,35 @@ export default { | ||||
|       }, | ||||
|       currentStatusOptions: [{ | ||||
|         'label': '正常', | ||||
|         'value': '0' | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '暂停', | ||||
|         'value': '1' | ||||
|         'value': 1 | ||||
|       }, { | ||||
|         'label': '维修', | ||||
|         'value': '2' | ||||
|         'value': 2 | ||||
|       }], | ||||
|       cacheId: '', | ||||
|       id: '', // 缓存区id | ||||
|       isdetail: false | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.cacheId = this.$route.query.id | ||||
|     this.id = this.$route.query.id | ||||
|     this.init() | ||||
|   }, | ||||
|   methods: { | ||||
|     init() { | ||||
|       this.isdetail = false | ||||
|       this.isdetail = Boolean(this.$route.query.isdetail) | ||||
|       this.listQuery.cacheId = '' | ||||
|       this.listQuery.id = '' | ||||
|       this.list.splice(0, this.list.length) | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         if (this.cacheId) { | ||||
|           cacheDetail(this.cacheId).then(res => { | ||||
|         if (this.id) { | ||||
|           cacheDetail(this.id).then(res => { | ||||
|             this.dataForm = res.data | ||||
|           }) | ||||
|           this.listQuery.cacheId = this.cacheId | ||||
|           this.listQuery.id = this.id | ||||
|           areaList(this.listQuery).then(response => { | ||||
|             if (response.data.records) { | ||||
|               this.list = response.data.records | ||||
| @@ -322,20 +271,16 @@ export default { | ||||
|           const data = { | ||||
|             'abbr': this.dataForm.abbr, | ||||
|             'code': this.dataForm.code, | ||||
|             'currentStatus': this.dataForm.currentStatus, | ||||
|             'debugTime': this.dataForm.debugTime, | ||||
|             'status': this.dataForm.status, | ||||
|             'enName': this.dataForm.enName, | ||||
|             'enterTime': this.dataForm.enterTime, | ||||
|             'manufacturer': this.dataForm.manufacturer, | ||||
|             'name': this.dataForm.name, | ||||
|             'productionTime': this.dataForm.productionTime, | ||||
|             'remark': this.dataForm.remark, | ||||
|             'description': this.dataForm.description, | ||||
|             'stockNumber': this.dataForm.stockNumber, | ||||
|             'areaNumber': this.dataForm.areaNumber, | ||||
|             'id': this.cacheId | ||||
|             'tareaName': this.dataForm.tareaName, | ||||
|             'note': this.dataForm.note, | ||||
|             'spec': this.dataForm.spec, | ||||
|             'locationNum': this.dataForm.locationNum, | ||||
|             'shelfNum': this.dataForm.shelfNum, | ||||
|             'id': this.id | ||||
|           } | ||||
|           if (this.cacheId) { | ||||
|           if (this.id) { | ||||
|             cacheUpdate(data).then(res => { | ||||
|               this.$message({ | ||||
|                 message: this.$t('module.basicData.visual.success'), | ||||
| @@ -350,7 +295,7 @@ export default { | ||||
|                 type: 'success', | ||||
|                 duration: 1500 | ||||
|               }) | ||||
|               this.listQuery.cacheId = res.data.id | ||||
|               this.listQuery.id = res.data.id | ||||
|             }) | ||||
|           } | ||||
|         } | ||||
|   | ||||
| @@ -75,7 +75,7 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     prop: 'shelfName', | ||||
|     label: i18n.t('module.basicData.cache.ShelfName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   | ||||
| @@ -12,7 +12,7 @@ | ||||
|   > | ||||
|     <el-form ref="dataForm" :model="dataForm" :rules="dataRule" label-width="130px" @keyup.enter.native="dataFormSubmit()"> | ||||
|       <el-form-item :label="$t('module.basicData.cache.ShelfName')" prop="name"> | ||||
|         <el-input v-model="dataForm.name" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfName')])" clearable /> | ||||
|         <el-input v-model="dataForm.shelfName" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfName')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.cache.ShelfCode')" prop="code"> | ||||
|         <el-input v-model="dataForm.code" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfCode')])" clearable /> | ||||
| @@ -56,15 +56,17 @@ export default { | ||||
|       visible: false, | ||||
|       isPage: false, | ||||
|       dataForm: { | ||||
|         abbr: 'n', | ||||
|         id: 0, | ||||
|         areaId: '', | ||||
|         name: '', | ||||
|         shelfName: '', | ||||
|         code: '', | ||||
|         shelfNumber: '' | ||||
|         shelfNumber: '', | ||||
|         total: '' | ||||
|       }, | ||||
|       areaArr: [], | ||||
|       dataRule: { | ||||
|         name: [ | ||||
|         shelfName: [ | ||||
|           { required: true, message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.cache.ShelfName')]), trigger: 'blur' } | ||||
|         ], | ||||
|         code: [ | ||||
| @@ -112,6 +114,7 @@ export default { | ||||
|       this.$refs['dataForm'].validate((valid) => { | ||||
|         if (valid) { | ||||
|           const data = this.dataForm | ||||
|           console.log(data) | ||||
|           if (this.dataForm.id) { | ||||
|             shelfUpdate(data).then(res => { | ||||
|               this.$message({ | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 13:59:43 | ||||
|  * @LastEditTime: 2022-01-11 16:45:30 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
| @@ -11,17 +11,14 @@ | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-form ref="dataForm" :model="dataForm" :rules="dataRule" label-width="130px" @keyup.enter.native="dataFormSubmit()"> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.name')" prop="name"> | ||||
|         <el-input v-model="dataForm.name" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.name')])" clearable /> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.name')" prop="storageBoxName"> | ||||
|         <el-input v-model="dataForm.storageBoxName" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.name')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.code')" prop="code"> | ||||
|         <el-input v-model="dataForm.code" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.code')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.StorageQuantity')" prop="quantity"> | ||||
|         <el-input-number v-model="dataForm.quantity" :min="0" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.StorageQuantity')])" /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.alias')" prop="aliasName"> | ||||
|         <el-input v-model="dataForm.aliasName" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.alias')])" clearable /> | ||||
|       <el-form-item :label="$t('module.basicData.visual.EnglishName')" prop="enName"> | ||||
|         <el-input v-model="dataForm.enName" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.EnglishName')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.storageBox.status')" prop="status"> | ||||
|         <el-select v-model="dataForm.status" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.storageBox.status')])" clearable> | ||||
| @@ -33,8 +30,8 @@ | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.visual.Remarks')" prop="remark"> | ||||
|         <el-input v-model="dataForm.remark" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Remarks')])" clearable /> | ||||
|       <el-form-item :label="$t('module.basicData.visual.Remarks')" prop="note"> | ||||
|         <el-input v-model="dataForm.note" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Remarks')])" clearable /> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
| @@ -53,12 +50,11 @@ export default { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: 0, | ||||
|         name: '', | ||||
|         storageBoxName: '', | ||||
|         code: '', | ||||
|         status: 0, | ||||
|         aliasName: '', | ||||
|         quantity: 0, | ||||
|         remark: '' | ||||
|         enName: '', | ||||
|         note: '' | ||||
|       }, | ||||
|       options: [ | ||||
|         { | ||||
| @@ -75,7 +71,7 @@ export default { | ||||
|         } | ||||
|       ], | ||||
|       dataRule: { | ||||
|         name: [ | ||||
|         storageBoxName: [ | ||||
|           { | ||||
|             required: true, | ||||
|             message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.storageBox.name')]), | ||||
|   | ||||
| @@ -181,6 +181,7 @@ export default { | ||||
|       this.listLoading = true | ||||
|       this.listQuery.name = key | ||||
|       shelfList(this.listQuery).then(response => { | ||||
|         console.log(response) | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|           this.list.forEach(item => { | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2021-07-21 14:00:56 | ||||
|  * @LastEditTime: 2022-01-11 16:46:48 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
| @@ -41,7 +41,6 @@ | ||||
| <script>import i18n from '@/lang' | ||||
| import HeadForm from '@/components/basicData/HeadForm' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import PositionDetail from './components/PositionDetail' | ||||
| import storageBoxAdd from './components/storageBox-add' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| @@ -82,7 +81,7 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     prop: 'storageBoxName', | ||||
|     label: i18n.t('module.basicData.storageBox.name'), | ||||
|     align: 'center' | ||||
|   }, | ||||
| @@ -92,13 +91,8 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'aliasName', | ||||
|     label: i18n.t('module.basicData.storageBox.alias'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'quantity', | ||||
|     label: i18n.t('module.basicData.storageBox.StorageQuantity'), | ||||
|     prop: 'enName', | ||||
|     label: i18n.t('module.basicData.visual.EnglishName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
| @@ -108,15 +102,9 @@ const tableProps = [ | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'remark', | ||||
|     prop: 'note', | ||||
|     label: i18n.t('module.basicData.storageBox.remark'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'location', | ||||
|     label: i18n.t('module.basicData.cache.Location'), | ||||
|     subcomponent: PositionDetail, | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| @@ -157,7 +145,7 @@ export default { | ||||
|   methods: { | ||||
|     handleClick(raw) { | ||||
|       if (raw.type === 'delete') { | ||||
|         this.$confirm(`${this.$t('module.basicData.visual.TipsBefore')}[${raw.data.name}]?`, this.$t('module.basicData.visual.Tips'), { | ||||
|         this.$confirm(`${this.$t('module.basicData.visual.TipsBefore')}[${raw.data.storageBoxName}]?`, this.$t('module.basicData.visual.Tips'), { | ||||
|           confirmButtonText: this.$t('module.basicData.visual.confirmButtonText'), | ||||
|           cancelButtonText: this.$t('module.basicData.visual.cancelButtonText'), | ||||
|           type: 'warning' | ||||
| @@ -181,8 +169,7 @@ export default { | ||||
|     }, | ||||
|     getList(key) { | ||||
|       this.listLoading = true | ||||
|       this.listQuery.name = key | ||||
|       this.listQuery.code = key | ||||
|       this.listQuery.storageBoxName = key | ||||
|       storageBoxList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|   | ||||
							
								
								
									
										254
									
								
								src/views/basicData/Warehouse/CurrentTask.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										254
									
								
								src/views/basicData/Warehouse/CurrentTask.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,254 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-14 15:54:12 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       ref="formData" | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="100px" | ||||
|     > | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.TaskType')" prop="taskType"> | ||||
|         <el-select v-model="formData.taskType" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.TaskType')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in taskTypeList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.TaskStatus')" prop="status"> | ||||
|         <el-select v-model="formData.status" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.TaskStatus')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in TaskStatusList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.VehicleName')" prop="equipmentId"> | ||||
|         <el-select v-model="formData.equipmentId" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.VehicleName')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in VehicleNameList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <base-table | ||||
|       :page="formData.current" | ||||
|       :limit="formData.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="formData.current" | ||||
|       :limit.sync="formData.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|     <current-task-info v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { CurrentTaskList } from '@/api/basicData/Warehouse/HistoricalTask' | ||||
| import CurrentTaskInfo from './components/CurrentTaskInfo.vue' | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| // import { timeFormatter } from '@/filters' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'view', | ||||
|     btnName: 'btn.see' | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'taskCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.Code'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.Warehouse.ExecutionTime'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'taskSource', | ||||
|     label: i18n.t('module.basicData.Warehouse.TaskSource'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'taskType', | ||||
|     label: i18n.t('module.basicData.Warehouse.TaskType'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'fullCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.TaskBoxNumber'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'emptyCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.FullBoxNumber'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'wcurrProcessCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.PreviousOperation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'wnextProcessCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.NextOperation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'anotherCurrLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.StartLocation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'anotherTargetLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.TargetLocation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'currLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.FullBoxStartLocation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     label: i18n.t('module.basicData.Warehouse.VehicleName'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'ScrapInfo', | ||||
|   components: { Pagination, BaseTable, MethodBtn, CurrentTaskInfo }, | ||||
|   data() { | ||||
|     return { | ||||
|       trueWidth: 100, | ||||
|       addOrUpdateVisible: false, | ||||
|       tableProps, | ||||
|       tableBtn, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       listLoading: false, | ||||
|       formData: { | ||||
|         taskType: '', | ||||
|         status: '', | ||||
|         equipmentId: '', | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       taskTypeList: [{ | ||||
|         'label': '出库', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '入库', | ||||
|         'value': 1 | ||||
|       }, { | ||||
|         'label': '流转', | ||||
|         'value': 2 | ||||
|       }], | ||||
|       TaskStatusList: [{ | ||||
|         'label': '初始化', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '损坏', | ||||
|         'value': 1 | ||||
|       }], | ||||
|       VehicleNameList: [{ | ||||
|         'label': '小车1', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '小车2', | ||||
|         'value': 1 | ||||
|       }] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     getList() { | ||||
|       this.listLoading = true | ||||
|       CurrentTaskList(this.formData).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     }, | ||||
|     handleClick(raw) { | ||||
|       console.log(raw) | ||||
|       this.addNew(raw.data.id) | ||||
|     }, | ||||
|     // 新增 / 修改 | ||||
|     addNew(id) { | ||||
|       this.addOrUpdateVisible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.addOrUpdate.init(id) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										276
									
								
								src/views/basicData/Warehouse/HistoricalTask.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										276
									
								
								src/views/basicData/Warehouse/HistoricalTask.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,276 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-13 15:49:01 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form | ||||
|       ref="formData" | ||||
|       :model="formData" | ||||
|       :inline="true" | ||||
|       size="medium" | ||||
|       label-width="100px" | ||||
|     > | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.TaskType')" prop="taskType"> | ||||
|         <el-select v-model="formData.taskType" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.TaskType')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in taskTypeList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.TaskStatus')" prop="status"> | ||||
|         <el-select v-model="formData.status" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.TaskStatus')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in TaskStatusList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.VehicleName')" prop="equipmentId"> | ||||
|         <el-select v-model="formData.equipmentId" filterable :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.VehicleName')])" clearable> | ||||
|           <el-option | ||||
|             v-for="item in VehicleNameList" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.TimeSlot')" prop="time"> | ||||
|         <el-date-picker | ||||
|           v-model="formData.timeSlot" | ||||
|           type="daterange" | ||||
|           format="yyyy-MM-dd" | ||||
|           value-format="yyyy-MM-dd" | ||||
|           :start-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :end-placeholder="$t('module.orderManage.order.StartTime')" | ||||
|           :range-separator="$t('module.orderManage.order.To')" | ||||
|           clearable | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()"> {{ 'btn.search' | i18nFilter }} </el-button> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <base-table | ||||
|       :page="formData.current" | ||||
|       :limit="formData.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="formData.current" | ||||
|       :limit.sync="formData.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|     <historical-task-info v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { HistoricalTaskList } from '@/api/basicData/Warehouse/HistoricalTask' | ||||
| import HistoricalTaskInfo from './components/HistoricalTaskInfo.vue' | ||||
| import i18n from '@/lang' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| // import { timeFormatter } from '@/filters' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'view', | ||||
|     btnName: 'btn.see' | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'taskCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.Code'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.Warehouse.ExecutionTime'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.Warehouse.TaskStatus'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   // { | ||||
|   //   prop: 'taskType', | ||||
|   //   label: i18n.t('module.basicData.Warehouse.TaskType'), | ||||
|   //   align: 'center' | ||||
|   // }, | ||||
|   { | ||||
|     prop: 'name', | ||||
|     label: i18n.t('module.basicData.Warehouse.VehicleName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   // { | ||||
|   //   prop: 'substrateNo', | ||||
|   //   label: i18n.t('module.basicData.Warehouse.BoxStatus'), | ||||
|   //   align: 'center' | ||||
|   // }, | ||||
|   { | ||||
|     prop: 'wcode', | ||||
|     label: i18n.t('module.basicData.Warehouse.BoxNumber'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'wcurrProcessCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.PreviousOperation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'wnextProcessCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.NextOperation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'updateTime', | ||||
|     label: i18n.t('module.basicData.Warehouse.CompletionTime'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'currLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.StartLocation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'targetLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.TargetLocation'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'ScrapInfo', | ||||
|   components: { Pagination, BaseTable, MethodBtn, HistoricalTaskInfo }, | ||||
|   data() { | ||||
|     return { | ||||
|       trueWidth: 100, | ||||
|       addOrUpdateVisible: false, | ||||
|       tableProps, | ||||
|       tableBtn, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       listLoading: false, | ||||
|       formData: { | ||||
|         taskType: '', | ||||
|         status: '', | ||||
|         equipmentId: '', | ||||
|         timeSlot: [], | ||||
|         endTime: '', | ||||
|         startTime: '', | ||||
|         current: 1, | ||||
|         size: 10 | ||||
|       }, | ||||
|       taskTypeList: [{ | ||||
|         'label': '出库', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '入库', | ||||
|         'value': 1 | ||||
|       }, { | ||||
|         'label': '流转', | ||||
|         'value': 2 | ||||
|       }], | ||||
|       TaskStatusList: [{ | ||||
|         'label': '初始化', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '损坏', | ||||
|         'value': 1 | ||||
|       }], | ||||
|       VehicleNameList: [{ | ||||
|         'label': '小车1', | ||||
|         'value': 0 | ||||
|       }, { | ||||
|         'label': '小车2', | ||||
|         'value': 1 | ||||
|       }] | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     getList() { | ||||
|       if (this.formData.timeSlot) { | ||||
|         this.formData.startTime = this.formData.timeSlot[0] | ||||
|         this.formData.endTime = this.formData.timeSlot[1] | ||||
|       } else { | ||||
|         this.formData.startTime = '' | ||||
|         this.formData.endTime = '' | ||||
|       } | ||||
|       this.listLoading = true | ||||
|       HistoricalTaskList(this.formData).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     }, | ||||
|     handleClick(raw) { | ||||
|       console.log(raw) | ||||
|       this.addNew(raw.data.id) | ||||
|     }, | ||||
|     // 新增 / 修改 | ||||
|     addNew(id) { | ||||
|       this.addOrUpdateVisible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.addOrUpdate.init(id) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										160
									
								
								src/views/basicData/Warehouse/StorageBoxInfo.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										160
									
								
								src/views/basicData/Warehouse/StorageBoxInfo.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,160 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-18 14:30:25 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form ref="listQuery" :model="listQuery" :inline="true" label-width="120px" @keyup.enter.native="getList()"> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.StorageBoxNumber')" prop="code"> | ||||
|         <el-select | ||||
|           v-model="listQuery.code" | ||||
|           :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.StorageBoxNumber')])" | ||||
|           clearable | ||||
|           filterable | ||||
|           :style="{width: '100%'}" | ||||
|         > | ||||
|           <el-option | ||||
|             v-for="(item, index) in storageBoxList" | ||||
|             :key="index" | ||||
|             :label="item.code" | ||||
|             :value="item.code" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()">{{ 'btn.search' | i18nFilter }}</el-button> | ||||
|       </el-form-item> | ||||
|       <base-table | ||||
|         :page="listQuery.current" | ||||
|         :limit="listQuery.size" | ||||
|         :table-config="tableProps" | ||||
|         :table-data="list" | ||||
|         :is-loading="listLoading" | ||||
|       /> | ||||
|       <pagination | ||||
|         v-show="total > 0" | ||||
|         :total="total" | ||||
|         :page.sync="listQuery.current" | ||||
|         :limit.sync="listQuery.size" | ||||
|         @pagination="getList()" | ||||
|       /> | ||||
|     </el-form></div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { StorageBoxInfoList, StorageBoxRackCode } from '@/api/basicData/Warehouse/StorageBoxInfo' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import warehouse from '@/filters/basicData/warehouse' | ||||
| import i18n from '@/lang' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'storageCode', | ||||
|     label: i18n.t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.Warehouse.BoxStatus'), | ||||
|     filter: warehouse('enableState'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'currLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.CurrentLocation'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'isEmpty', | ||||
|     label: i18n.t('module.basicData.Warehouse.IsEmpty'), | ||||
|     filter: warehouse('yesOrNo'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'StorageBoxInfo', | ||||
|   components: { Pagination, BaseTable }, | ||||
|   filters: { | ||||
|     statusFilter(status) { | ||||
|       const statusMap = { | ||||
|         published: 'success', | ||||
|         draft: 'info', | ||||
|         deleted: 'danger' | ||||
|       } | ||||
|       return statusMap[status] | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       keyName: i18n.t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|       placeholderName: this.$t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|       trueWidth: 200, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       storageBoxList: [], | ||||
|       total: 0, | ||||
|       listLoading: true, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10, | ||||
|         code: '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|     const listQuery1 = { | ||||
|       current: 1, | ||||
|       size: 100 | ||||
|     } | ||||
|     StorageBoxRackCode(listQuery1).then(res => { | ||||
|       this.storageBoxList = res.data.records | ||||
|     }) | ||||
|   }, | ||||
|   methods: { | ||||
|     getList() { | ||||
|       this.listLoading = true | ||||
|       StorageBoxInfoList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										247
									
								
								src/views/basicData/Warehouse/StorageBoxRack.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										247
									
								
								src/views/basicData/Warehouse/StorageBoxRack.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,247 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 14:06:53 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <el-form ref="listQuery" :model="listQuery" :inline="true" label-width="120px" @keyup.enter.native="getList()"> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.LocationName')" prop="currLocationId"> | ||||
|         <el-select | ||||
|           v-model="listQuery.currLocationId" | ||||
|           :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.LocationName')])" | ||||
|           clearable | ||||
|           filterable | ||||
|           :style="{width: '100%'}" | ||||
|         > | ||||
|           <el-option | ||||
|             v-for="(item, index) in LocationList" | ||||
|             :key="index" | ||||
|             :label="item.locationName" | ||||
|             :value="item.id" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.StorageBoxNumber')" prop="storageBoxId"> | ||||
|         <el-select | ||||
|           v-model="listQuery.storageBoxId" | ||||
|           :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.StorageBoxNumber')])" | ||||
|           clearable | ||||
|           filterable | ||||
|           :style="{width: '100%'}" | ||||
|         > | ||||
|           <el-option | ||||
|             v-for="(item, index) in storageBoxList" | ||||
|             :key="index" | ||||
|             :label="item.code" | ||||
|             :value="item.id" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item> | ||||
|         <el-button type="primary" @click="getList()">{{ 'btn.search' | i18nFilter }}</el-button> | ||||
|         <el-button type="primary" @click="addNew()">{{ 'btn.add' | i18nFilter }}</el-button> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="listQuery.current" | ||||
|       :limit.sync="listQuery.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|     <Factory-add v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { StorageBoxRackList, StorageBoxRackDelete, StorageBoxRackCode, locationList } from '@/api/basicData/Warehouse/StorageBoxInfo' | ||||
| import FactoryAdd from './components/StorageBoxRack-add.vue' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import { timeFormatter } from '@/filters' | ||||
| import warehouse from '@/filters/basicData/warehouse' | ||||
| import i18n from '@/lang' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'edit', | ||||
|     btnName: 'btn.edit' | ||||
|   }, | ||||
|   { | ||||
|     type: 'delete', | ||||
|     btnName: 'btn.delete' | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.factory.createTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'code', | ||||
|     label: i18n.t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.Warehouse.BoxStatus'), | ||||
|     filter: warehouse('enableState'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'currLocation', | ||||
|     label: i18n.t('module.basicData.Warehouse.LocationName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'currLocationName', | ||||
|     label: i18n.t('module.basicData.Warehouse.LocationCode'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'isEmpty', | ||||
|     label: i18n.t('module.basicData.Warehouse.IsEmptyBox'), | ||||
|     filter: warehouse('yesOrNo'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'StorageBoxInfo', | ||||
|   components: { Pagination, BaseTable, MethodBtn, FactoryAdd }, | ||||
|   filters: { | ||||
|     statusFilter(status) { | ||||
|       const statusMap = { | ||||
|         published: 'success', | ||||
|         draft: 'info', | ||||
|         deleted: 'danger' | ||||
|       } | ||||
|       return statusMap[status] | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       keyName: i18n.t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|       placeholderName: this.$t('module.basicData.Warehouse.StorageBoxNumber'), | ||||
|       addOrUpdateVisible: false, | ||||
|       tableBtn, | ||||
|       trueWidth: 200, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       LocationList: [], | ||||
|       storageBoxList: [], | ||||
|       listLoading: true, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10, | ||||
|         storageBoxId: '', | ||||
|         currLocationId: '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|     const listQuery1 = { | ||||
|       current: 1, | ||||
|       size: 100 | ||||
|     } | ||||
|     locationList(listQuery1).then(response => { | ||||
|       this.LocationList = response.data | ||||
|     }) | ||||
|     StorageBoxRackCode(listQuery1).then(res => { | ||||
|       this.storageBoxList = res.data.records | ||||
|     }) | ||||
|   }, | ||||
|   methods: { | ||||
|     handleClick(raw) { | ||||
|       console.log(raw) | ||||
|       if (raw.type === 'delete') { | ||||
|         this.$confirm(`${this.$t('module.basicData.visual.TipsBefore')}[${raw.data.code}]?`, this.$t('module.basicData.visual.Tips'), { | ||||
|           confirmButtonText: this.$t('module.basicData.visual.confirmButtonText'), | ||||
|           cancelButtonText: this.$t('module.basicData.visual.cancelButtonText'), | ||||
|           type: 'warning' | ||||
|         }).then(() => { | ||||
|           StorageBoxRackDelete(raw.data.id).then(response => { | ||||
|             this.$message({ | ||||
|               message: this.$t('module.basicData.visual.success'), | ||||
|               type: 'success', | ||||
|               duration: 1500, | ||||
|               onClose: () => { | ||||
|                 this.getList() | ||||
|               } | ||||
|             }) | ||||
|           }) | ||||
|         }).catch(() => {}) | ||||
|       } else { | ||||
|         this.addNew(raw.data.id) | ||||
|       } | ||||
|     }, | ||||
|     getList() { | ||||
|       this.listLoading = true | ||||
|       StorageBoxRackList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     }, | ||||
|     // 新增 / 修改 | ||||
|     addNew(id) { | ||||
|       this.addOrUpdateVisible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.addOrUpdate.init(id) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										178
									
								
								src/views/basicData/Warehouse/components/CurrentTaskInfo.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										178
									
								
								src/views/basicData/Warehouse/components/CurrentTaskInfo.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,178 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-14 15:55:39 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="'btn.see' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-row :gutter="10"> | ||||
|       <el-form | ||||
|         ref="dataForm" | ||||
|         :model="dataForm" | ||||
|         size="medium" | ||||
|         label-width="110px" | ||||
|         label-position="left" | ||||
|       > | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.Code')" prop="taskCode"> | ||||
|                 <el-input v-model="dataForm.taskCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderName')" prop="orderName"> | ||||
|                 <el-input v-model="dataForm.orderName" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxNumber')" prop="fullCode"> | ||||
|                 <el-input v-model="dataForm.fullCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.VehicleName')" prop="name"> | ||||
|                 <el-input v-model="dataForm.name" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.EmptyFork')" prop="field124"> | ||||
|                 <el-input v-model="dataForm.field124" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.EmptyHandlingTime')" prop="field119"> | ||||
|                 <el-input v-model="dataForm.field119" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.ExecutionTime')" prop="createTime"> | ||||
|                 <el-input v-model="dataForm.createTime" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskType')" prop="taskType"> | ||||
|                 <el-input v-model="dataForm.taskType" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.FullBoxNumber')" prop="emptyCode"> | ||||
|                 <el-input v-model="dataForm.emptyCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskLocation')" prop="anotherCurrLocation"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherCurrLocation" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxFork')" prop="field121"> | ||||
|                 <el-input v-model="dataForm.field121" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskSource')" prop="taskSource"> | ||||
|                 <el-input v-model="dataForm.taskSource" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.PreviousOperation')" prop="anotherCurrProcessCode"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherCurrProcessCode" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.NextOperation')" prop="anotherNextProcessCode"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherNextProcessCode" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TargetLocation')" prop="anotherTargetLocation"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherTargetLocation" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.BoxStatus')" prop="field126"> | ||||
|                 <el-input v-model="dataForm.field126" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|       </el-form> | ||||
|     </el-row> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { CurrentTaskDetail } from '@/api/basicData/Warehouse/HistoricalTask' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: '', | ||||
|         taskCode: undefined, | ||||
|         orderName: undefined, | ||||
|         fullCode: undefined, | ||||
|         name: undefined, | ||||
|         field124: undefined, | ||||
|         field119: undefined, | ||||
|         createTime: undefined, | ||||
|         taskType: undefined, | ||||
|         emptyCode: undefined, | ||||
|         anotherCurrLocation: undefined, | ||||
|         field121: undefined, | ||||
|         taskSource: undefined, | ||||
|         anotherCurrProcessCode: undefined, | ||||
|         anotherNextProcessCode: undefined, | ||||
|         anotherTargetLocation: undefined, | ||||
|         field126: undefined | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id | ||||
|       this.visible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         CurrentTaskDetail(this.dataForm.id).then(res => { | ||||
|           this.dataForm = res.data | ||||
|         }) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										194
									
								
								src/views/basicData/Warehouse/components/HistoricalTaskInfo.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										194
									
								
								src/views/basicData/Warehouse/components/HistoricalTaskInfo.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,194 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-13 16:22:39 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="'btn.see' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-row :gutter="10"> | ||||
|       <el-form | ||||
|         ref="dataForm" | ||||
|         :model="dataForm" | ||||
|         size="medium" | ||||
|         label-width="110px" | ||||
|         label-position="left" | ||||
|       > | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.Code')" prop="taskCode"> | ||||
|                 <el-input v-model="dataForm.taskCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderName')" prop="orderName"> | ||||
|                 <el-input v-model="dataForm.orderName" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxNumber')" prop="fullCode"> | ||||
|                 <el-input v-model="dataForm.fullCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.VehicleName')" prop="name"> | ||||
|                 <el-input v-model="dataForm.name" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.EmptyFork')" prop="field124"> | ||||
|                 <el-input v-model="dataForm.field124" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.EmptyHandlingTime')" prop="field119"> | ||||
|                 <el-input v-model="dataForm.field119" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.ExecutionTime')" prop="createTime"> | ||||
|                 <el-input v-model="dataForm.createTime" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskType')" prop="taskType"> | ||||
|                 <el-input v-model="dataForm.taskType" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.FullBoxNumber')" prop="emptyCode"> | ||||
|                 <el-input v-model="dataForm.emptyCode" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskLocation')" prop="anotherCurrLocation"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherCurrLocation" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxFork')" prop="field121"> | ||||
|                 <el-input v-model="dataForm.field121" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxHandlingTime')" prop="field122"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.field122" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TaskSource')" prop="taskSource"> | ||||
|                 <el-input v-model="dataForm.taskSource" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.PreviousOperation')" prop="anotherCurrProcessCode"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherCurrProcessCode" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.NextOperation')" prop="anotherNextProcessCode"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherNextProcessCode" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TargetLocation')" prop="anotherTargetLocation"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.anotherTargetLocation" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.CompletionTime')" prop="field125"> | ||||
|                 <el-input v-model="dataForm.field125" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.BoxStatus')" prop="field126"> | ||||
|                 <el-input v-model="dataForm.field126" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|       </el-form> | ||||
|     </el-row> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { HistoricalTaskDetail } from '@/api/basicData/Warehouse/HistoricalTask' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: '', | ||||
|         taskCode: undefined, | ||||
|         orderName: undefined, | ||||
|         fullCode: undefined, | ||||
|         name: undefined, | ||||
|         field124: undefined, | ||||
|         field119: undefined, | ||||
|         createTime: undefined, | ||||
|         taskType: undefined, | ||||
|         emptyCode: undefined, | ||||
|         anotherCurrLocation: undefined, | ||||
|         field121: undefined, | ||||
|         field122: undefined, | ||||
|         taskSource: undefined, | ||||
|         anotherCurrProcessCode: undefined, | ||||
|         anotherNextProcessCode: undefined, | ||||
|         anotherTargetLocation: undefined, | ||||
|         field125: undefined, | ||||
|         field126: undefined | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id | ||||
|       this.visible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         HistoricalTaskDetail(this.dataForm.id).then(res => { | ||||
|           this.dataForm = res.data | ||||
|         }) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -0,0 +1,65 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 10:19:45 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="!dataForm.id ? 'btn.add' : 'btn.edit' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-form ref="dataForm" :model="dataForm" label-width="120px"> | ||||
|       <el-form-item :label="$t('module.basicData.factory.FactoryName')" prop="name"> | ||||
|         <el-input v-model="dataForm.name" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.factory.FactoryName')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.factory.FactoryCode')" prop="code"> | ||||
|         <el-input v-model="dataForm.code" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.factory.FactoryCode')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.factory.Address')" prop="address"> | ||||
|         <el-input v-model="dataForm.address" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.factory.Address')])" clearable /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.visual.Remarks')" prop="description"> | ||||
|         <el-input v-model="dataForm.description" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.visual.Remarks')])" clearable /> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { StorageBoxInfoDetail } from '@/api/basicData/Warehouse/StorageBoxInfo' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: 0, | ||||
|         name: '', | ||||
|         code: '', | ||||
|         address: '', | ||||
|         description: '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id || '' | ||||
|       this.visible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         StorageBoxInfoDetail(this.dataForm.id).then(res => { | ||||
|           this.dataForm.name = res.data.name | ||||
|           this.dataForm.code = res.data.code | ||||
|           this.dataForm.address = res.data.address | ||||
|           this.dataForm.description = res.data.description | ||||
|         }) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										180
									
								
								src/views/basicData/Warehouse/components/StorageBoxRack-add.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										180
									
								
								src/views/basicData/Warehouse/components/StorageBoxRack-add.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,180 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 11:21:26 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="!dataForm.id ? 'btn.add' : 'btn.edit' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-form ref="dataForm" :model="dataForm" :rules="dataRule" label-width="120px" @keyup.enter.native="dataFormSubmit()"> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.LocationName')" prop="currLocationId"> | ||||
|         <el-select | ||||
|           v-model="dataForm.currLocationId" | ||||
|           :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.LocationName')])" | ||||
|           clearable | ||||
|           filterable | ||||
|           :style="{width: '100%'}" | ||||
|           @change="selectGetLabel1" | ||||
|         > | ||||
|           <el-option | ||||
|             v-for="(item, index) in LocationList" | ||||
|             :key="index" | ||||
|             :label="item.locationName" | ||||
|             :value="item.id" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.StorageBoxNumber')" prop="storageBoxId"> | ||||
|         <el-select | ||||
|           v-model="dataForm.storageBoxId" | ||||
|           :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.Warehouse.StorageBoxNumber')])" | ||||
|           clearable | ||||
|           filterable | ||||
|           :style="{width: '100%'}" | ||||
|           @change="selectGetLabel2" | ||||
|         > | ||||
|           <el-option | ||||
|             v-for="(item, index) in storageBoxList" | ||||
|             :key="index" | ||||
|             :label="item.code" | ||||
|             :value="item.id" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.BoxStatus')" prop="status"> | ||||
|         <el-switch | ||||
|           v-model="dataForm.status" | ||||
|           :active-value="1" | ||||
|           :inactive-value="0" | ||||
|           active-color="#13ce66" | ||||
|           inactive-color="#AAAAAA" | ||||
|         /> | ||||
|       </el-form-item> | ||||
|       <el-form-item :label="$t('module.basicData.Warehouse.IsEmptyBox')" prop="isEmpty"> | ||||
|         <el-switch | ||||
|           v-model="dataForm.isEmpty" | ||||
|           :active-value="1" | ||||
|           :inactive-value="0" | ||||
|           active-color="#13ce66" | ||||
|           inactive-color="#AAAAAA" | ||||
|         /> | ||||
|       </el-form-item> | ||||
|     </el-form> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|       <el-button type="primary" @click="dataFormSubmit()">{{ 'btn.confirm' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { StorageBoxRackDetail, StorageBoxRackUpdate, StorageBoxRackAdd, StorageBoxRackCode, locationList } from '@/api/basicData/Warehouse/StorageBoxInfo' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: 0, | ||||
|         code: '', | ||||
|         locationName: '', | ||||
|         currLocationId: '', | ||||
|         storageBoxId: '', | ||||
|         status: '', | ||||
|         isEmpty: '' | ||||
|       }, | ||||
|       LocationList: [], | ||||
|       storageBoxList: [], | ||||
|       dataRule: { | ||||
|         currLocationId: [ | ||||
|           { | ||||
|             required: true, | ||||
|             message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.Warehouse.LocationName')]), | ||||
|             trigger: 'blur' } | ||||
|         ], | ||||
|         storageBoxId: [ | ||||
|           { | ||||
|             required: true, | ||||
|             message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.Warehouse.StorageBoxNumber')]), | ||||
|             trigger: 'blur' } | ||||
|         ] | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id || '' | ||||
|       this.visible = true | ||||
|       const listQuery = { | ||||
|         current: 1, | ||||
|         size: 100 | ||||
|       } | ||||
|       locationList(listQuery).then(response => { | ||||
|         this.LocationList = response.data | ||||
|       }) | ||||
|       StorageBoxRackCode(listQuery).then(res => { | ||||
|         this.storageBoxList = res.data.records | ||||
|       }) | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         if (this.dataForm.id) { | ||||
|           StorageBoxRackDetail(this.dataForm.id).then(res => { | ||||
|             this.dataForm = res.data | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     selectGetLabel1(vId) { | ||||
|       let obj = {} | ||||
|       obj = this.LocationList.find((item) => { | ||||
|         return item.id === vId | ||||
|       }) | ||||
|       this.dataForm.locationName = obj.locationName | ||||
|     }, | ||||
|     selectGetLabel2(vId) { | ||||
|       let obj = {} | ||||
|       obj = this.storageBoxList.find((item) => { | ||||
|         return item.id === vId | ||||
|       }) | ||||
|       this.dataForm.code = obj.code | ||||
|     }, | ||||
|     // 表单提交 | ||||
|     dataFormSubmit() { | ||||
|       this.$refs['dataForm'].validate((valid) => { | ||||
|         if (valid) { | ||||
|           const data = this.dataForm | ||||
|           if (this.dataForm.id) { | ||||
|             StorageBoxRackUpdate(data).then(res => { | ||||
|               this.$message({ | ||||
|                 message: this.$t('module.basicData.visual.success'), | ||||
|                 type: 'success', | ||||
|                 duration: 1500, | ||||
|                 onClose: () => { | ||||
|                   this.visible = false | ||||
|                   this.$emit('refreshDataList') | ||||
|                 } | ||||
|               }) | ||||
|             }) | ||||
|           } else { | ||||
|             StorageBoxRackAdd(data).then(res => { | ||||
|               this.$message({ | ||||
|                 message: this.$t('module.basicData.visual.success'), | ||||
|                 type: 'success', | ||||
|                 duration: 1500, | ||||
|                 onClose: () => { | ||||
|                   this.visible = false | ||||
|                   this.$emit('refreshDataList') | ||||
|                 } | ||||
|               }) | ||||
|             }) | ||||
|           } | ||||
|         } | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
| @@ -102,8 +102,13 @@ export default { | ||||
|     } | ||||
|     return { | ||||
|       loginForm: { | ||||
|         username: '13588441519', | ||||
|         password: '123abc.' | ||||
|         username: 13588441519, | ||||
|         // password: 123456, | ||||
|         password: '123abc.', | ||||
|         mobile: 13588441519, | ||||
|         oauthCode: 13588441519, | ||||
|         openId: 13588441519, | ||||
|         wechatAppId: 13588441519 | ||||
|       }, | ||||
|       loginRules: { | ||||
|         username: [{ required: true, trigger: 'blur', validator: validateUsername }], | ||||
| @@ -133,6 +138,7 @@ export default { | ||||
|     // window.addEventListener('storage', this.afterQRScan) | ||||
|   }, | ||||
|   mounted() { | ||||
|     // 自动获取焦点 | ||||
|     if (this.loginForm.username === '') { | ||||
|       this.$refs.username.focus() | ||||
|     } else if (this.loginForm.password === '') { | ||||
| @@ -146,6 +152,7 @@ export default { | ||||
|     // window.removeEventListener('storage', this.afterQRScan) | ||||
|   }, | ||||
|   methods: { | ||||
|     // 监听用户键盘输入 | ||||
|     checkCapslock(e) { | ||||
|       const { key } = e | ||||
|       this.capsTooltip = key && key.length === 1 && (key >= 'A' && key <= 'Z') | ||||
| @@ -162,12 +169,24 @@ export default { | ||||
|     }, | ||||
|     handleLogin() { | ||||
|       this.$refs.loginForm.validate(valid => { | ||||
|         // 自定义登陆验证,如符合验证console.log输出true | ||||
|         console.log(valid) | ||||
|         console.log(this.redirect, this.$route) | ||||
|         if (valid) { | ||||
|           this.loading = true | ||||
|           // this.$store.dispatch('user/login', this.loginForm) | ||||
|           //   .then(() => { | ||||
|           //     console.log(this.redirect, this.otherQuery) | ||||
|           //     this.$router.push({ path: this.redirect || '/', query: this.otherQuery }) | ||||
|           //     this.loading = false | ||||
|           //   }) | ||||
|           //   .catch(() => { | ||||
|           //     this.loading = false | ||||
|           //   }) | ||||
|  | ||||
|           this.$store.dispatch('user/login', this.loginForm) | ||||
|             .then(() => { | ||||
|             .then(res => { | ||||
|               console.log(res) | ||||
|               console.log(this.redirect, this.otherQuery) | ||||
|               this.$router.push({ path: this.redirect || '/', query: this.otherQuery }) | ||||
|               this.loading = false | ||||
|   | ||||
							
								
								
									
										177
									
								
								src/views/orderManage/ExecutionInfo.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										177
									
								
								src/views/orderManage/ExecutionInfo.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,177 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 15:26:35 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <head-form | ||||
|       :placeholder-name="placeholderName" | ||||
|       :key-name="keyName" | ||||
|       :show-add="false" | ||||
|       @getDataList="getList" | ||||
|       @add="addNew" | ||||
|     /> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="listQuery.current" | ||||
|       :limit.sync="listQuery.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|     <Factory-add v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { ExecutionInfoList } from '@/api/orderManage/00A' | ||||
| import FactoryAdd from './components/ExecutionInfoDetail.vue' | ||||
| import HeadForm from '@/components/basicData/HeadForm' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import { timeFormatter } from '@/filters' | ||||
| import basicData from '@/filters/basicData' | ||||
| import i18n from '@/lang' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'see', | ||||
|     btnName: 'btn.see' | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'name', | ||||
|     label: i18n.t('module.basicData.Warehouse.OrderName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.Warehouse.IssueOrderTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'craftName', | ||||
|     label: i18n.t('module.basicData.Warehouse.TotalProcessName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'priority', | ||||
|     label: i18n.t('module.basicData.Warehouse.Priority'), | ||||
|     filter: basicData('priority'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.Warehouse.OrderStatus'), | ||||
|     filter: basicData('workOrderStatus'), | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'ExecutionInfo', | ||||
|   components: { Pagination, BaseTable, MethodBtn, HeadForm, FactoryAdd }, | ||||
|   filters: { | ||||
|     statusFilter(status) { | ||||
|       const statusMap = { | ||||
|         published: 'success', | ||||
|         draft: 'info', | ||||
|         deleted: 'danger' | ||||
|       } | ||||
|       return statusMap[status] | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       keyName: i18n.t('module.basicData.Warehouse.OrderName'), | ||||
|       placeholderName: this.$t('module.basicData.Warehouse.OrderName'), | ||||
|       addOrUpdateVisible: false, | ||||
|       tableBtn, | ||||
|       trueWidth: 200, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       listLoading: true, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10, | ||||
|         name: '', | ||||
|         code: '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     handleClick(raw) { | ||||
|       this.addNew(raw.data.id) | ||||
|     }, | ||||
|     getList(key) { | ||||
|       this.listLoading = true | ||||
|       this.listQuery.code = key | ||||
|       ExecutionInfoList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     }, | ||||
|     // 新增 / 修改 | ||||
|     addNew(id) { | ||||
|       this.addOrUpdateVisible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.addOrUpdate.init(id) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										184
									
								
								src/views/orderManage/ProcessInfo.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										184
									
								
								src/views/orderManage/ProcessInfo.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,184 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 15:41:11 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 15:32:00 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <div class="app-container"> | ||||
|     <head-form | ||||
|       :placeholder-name="placeholderName" | ||||
|       :key-name="keyName" | ||||
|       :show-add="false" | ||||
|       @getDataList="getList" | ||||
|       @add="addNew" | ||||
|     /> | ||||
|     <base-table | ||||
|       :page="listQuery.current" | ||||
|       :limit="listQuery.size" | ||||
|       :table-config="tableProps" | ||||
|       :table-data="list" | ||||
|       :is-loading="listLoading" | ||||
|     > | ||||
|       <method-btn | ||||
|         slot="handleBtn" | ||||
|         :width="trueWidth" | ||||
|         :method-list="tableBtn" | ||||
|         @clickBtn="handleClick" | ||||
|       /> | ||||
|     </base-table> | ||||
|     <pagination | ||||
|       v-show="total > 0" | ||||
|       :total="total" | ||||
|       :page.sync="listQuery.current" | ||||
|       :limit.sync="listQuery.size" | ||||
|       @pagination="getList()" | ||||
|     /> | ||||
|     <Factory-add v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { ProcessInfoList } from '@/api/orderManage/00A' | ||||
| import FactoryAdd from './components/ProcessInfoDetail.vue' | ||||
| import HeadForm from '@/components/basicData/HeadForm' | ||||
| import BaseTable from '@/components/BaseTable' | ||||
| import Pagination from '@/components/Pagination' // Secondary package based on el-pagination | ||||
| import MethodBtn from '@/components/BaseTable/subcomponents/MethodBtn' | ||||
| import { timeFormatter } from '@/filters' | ||||
| import basicData from '@/filters/basicData' | ||||
| import processLinkBtn from './components/processLinkBtn' | ||||
| import i18n from '@/lang' | ||||
| /** | ||||
|  * 表格表头配置项 TypeScript接口注释 | ||||
|  * tableConfig<ConfigItem> = [] | ||||
|  * | ||||
|  * Interface ConfigItem = { | ||||
|  *  prop: string, | ||||
|  *  label: string, | ||||
|  *  width: string, | ||||
|  *  align: string, | ||||
|  *  subcomponent: function, | ||||
|  *  filter: function | ||||
|  * } | ||||
|  * | ||||
|  * | ||||
|  */ | ||||
|  | ||||
| const tableBtn = [ | ||||
|   { | ||||
|     type: 'see', | ||||
|     btnName: 'btn.see' | ||||
|   } | ||||
| ] | ||||
| const tableProps = [ | ||||
|   { | ||||
|     prop: 'name', | ||||
|     label: i18n.t('module.basicData.Warehouse.OrderName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'createTime', | ||||
|     label: i18n.t('module.basicData.Warehouse.IssueOrderTime'), | ||||
|     filter: timeFormatter, | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'craftName', | ||||
|     label: i18n.t('module.basicData.Warehouse.TotalProcessName'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'priority', | ||||
|     label: i18n.t('module.basicData.Warehouse.Priority'), | ||||
|     filter: basicData('priority'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'status', | ||||
|     label: i18n.t('module.basicData.Warehouse.OrderStatus'), | ||||
|     filter: basicData('workOrderStatus'), | ||||
|     align: 'center' | ||||
|   }, | ||||
|   { | ||||
|     prop: 'attribute', | ||||
|     label: i18n.t('module.basicData.Warehouse.RelateProcess'), | ||||
|     subcomponent: processLinkBtn, | ||||
|     align: 'center' | ||||
|   } | ||||
| ] | ||||
|  | ||||
| export default { | ||||
|   name: 'ProcessInfo', | ||||
|   components: { Pagination, BaseTable, MethodBtn, HeadForm, FactoryAdd }, | ||||
|   filters: { | ||||
|     statusFilter(status) { | ||||
|       const statusMap = { | ||||
|         published: 'success', | ||||
|         draft: 'info', | ||||
|         deleted: 'danger' | ||||
|       } | ||||
|       return statusMap[status] | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       keyName: i18n.t('module.basicData.Warehouse.OrderName'), | ||||
|       placeholderName: this.$t('module.basicData.Warehouse.OrderName'), | ||||
|       addOrUpdateVisible: false, | ||||
|       tableBtn, | ||||
|       trueWidth: 200, | ||||
|       tableProps, | ||||
|       list: [], | ||||
|       total: 0, | ||||
|       listLoading: true, | ||||
|       listQuery: { | ||||
|         current: 1, | ||||
|         size: 10, | ||||
|         name: '', | ||||
|         code: '' | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getList() | ||||
|   }, | ||||
|   methods: { | ||||
|     handleClick(raw) { | ||||
|       this.addNew(raw.data.id) | ||||
|     }, | ||||
|     getList(key) { | ||||
|       this.listLoading = true | ||||
|       this.listQuery.code = key | ||||
|       ProcessInfoList(this.listQuery).then(response => { | ||||
|         if (response.data.records) { | ||||
|           this.list = response.data.records | ||||
|         } else { | ||||
|           this.list.splice(0, this.list.length) | ||||
|         } | ||||
|         this.total = response.data.total | ||||
|         this.listLoading = false | ||||
|       }) | ||||
|     }, | ||||
|     // 新增 / 修改 | ||||
|     addNew(id) { | ||||
|       this.addOrUpdateVisible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.addOrUpdate.init(id) | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style scoped> | ||||
| .edit-input { | ||||
|   padding-right: 100px; | ||||
| } | ||||
| .cancel-btn { | ||||
|   position: absolute; | ||||
|   right: 15px; | ||||
|   top: 10px; | ||||
| } | ||||
| </style> | ||||
							
								
								
									
										115
									
								
								src/views/orderManage/components/ExecutionInfoDetail.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										115
									
								
								src/views/orderManage/components/ExecutionInfoDetail.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,115 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 15:21:50 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="'btn.see' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-row :gutter="10"> | ||||
|       <el-form | ||||
|         ref="dataForm" | ||||
|         :model="dataForm" | ||||
|         size="medium" | ||||
|         label-width="110px" | ||||
|         label-position="left" | ||||
|       > | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderName')" prop="name"> | ||||
|                 <el-input v-model="dataForm.name" :placeholder="$t('module.basicData.Warehouse.OrderName')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.IssueOrderTime')" prop="createTime"> | ||||
|                 <el-input v-model="dataForm.createTime" :placeholder="$t('module.basicData.Warehouse.IssueOrderTime')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.PlanProcessQuantity')" prop="planQuantity"> | ||||
|                 <el-input v-model="dataForm.planQuantity" :placeholder="$t('module.basicData.Warehouse.PlanProcessQuantity')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderCode')" prop="taskCode"> | ||||
|                 <el-input v-model="dataForm.taskCode" :placeholder="$t('module.basicData.Warehouse.OrderCode')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderStatus')" prop="taskType"> | ||||
|                 <el-input v-model="dataForm.taskType" :placeholder="$t('module.basicData.Warehouse.OrderStatus')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TotalProcessName')" prop="craftName"> | ||||
|                 <el-input v-model="dataForm.craftName" :placeholder="$t('module.basicData.Warehouse.TotalProcessName')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.SubProcessName')" prop="subProccessName"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.subProccessName" | ||||
|                   :placeholder="$t('module.basicData.Warehouse.SubProcessName')" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|       </el-form> | ||||
|     </el-row> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { ExecutionInfoDetail } from '@/api/orderManage/00A' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: 0, | ||||
|         name: undefined, | ||||
|         createTime: undefined, | ||||
|         taskCode: undefined, | ||||
|         taskType: undefined, | ||||
|         craftName: undefined, | ||||
|         planQuantity: undefined, | ||||
|         subProccessName: undefined | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id || '' | ||||
|       this.visible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         if (this.dataForm.id) { | ||||
|           ExecutionInfoDetail(this.dataForm.id).then(res => { | ||||
|             this.dataForm = res.data | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										115
									
								
								src/views/orderManage/components/ProcessInfoDetail.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										115
									
								
								src/views/orderManage/components/ProcessInfoDetail.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,115 @@ | ||||
| <!-- | ||||
|  * @Author: zwq | ||||
|  * @Date: 2020-12-29 16:37:56 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 15:22:08 | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <el-dialog | ||||
|     :title="'btn.see' | i18nFilter" | ||||
|     :visible.sync="visible" | ||||
|   > | ||||
|     <el-row :gutter="10"> | ||||
|       <el-form | ||||
|         ref="dataForm" | ||||
|         :model="dataForm" | ||||
|         size="medium" | ||||
|         label-width="110px" | ||||
|         label-position="left" | ||||
|       > | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderName')" prop="name"> | ||||
|                 <el-input v-model="dataForm.name" :placeholder="$t('module.basicData.Warehouse.OrderName')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.IssueOrderTime')" prop="createTime"> | ||||
|                 <el-input v-model="dataForm.createTime" :placeholder="$t('module.basicData.Warehouse.IssueOrderTime')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.PlanProcessQuantity')" prop="planQuantity"> | ||||
|                 <el-input v-model="dataForm.planQuantity" :placeholder="$t('module.basicData.Warehouse.PlanProcessQuantity')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderCode')" prop="taskCode"> | ||||
|                 <el-input v-model="dataForm.taskCode" :placeholder="$t('module.basicData.Warehouse.OrderCode')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.OrderStatus')" prop="taskType"> | ||||
|                 <el-input v-model="dataForm.taskType" :placeholder="$t('module.basicData.Warehouse.OrderStatus')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-row> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.TotalProcessName')" prop="craftName"> | ||||
|                 <el-input v-model="dataForm.craftName" :placeholder="$t('module.basicData.Warehouse.TotalProcessName')" readonly :style="{width: '100%'}" /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|             <el-col :span="24"> | ||||
|               <el-form-item :label="$t('module.basicData.Warehouse.SubProcessName')" prop="subProccessName"> | ||||
|                 <el-input | ||||
|                   v-model="dataForm.subProccessName" | ||||
|                   :placeholder="$t('module.basicData.Warehouse.SubProcessName')" | ||||
|                   readonly | ||||
|                   :style="{width: '100%'}" | ||||
|                 /> | ||||
|               </el-form-item> | ||||
|             </el-col> | ||||
|           </el-row> | ||||
|         </el-col> | ||||
|       </el-form> | ||||
|     </el-row> | ||||
|     <span slot="footer" class="dialog-footer"> | ||||
|       <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button> | ||||
|     </span> | ||||
|   </el-dialog> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { ProcessInfoDetail } from '@/api/orderManage/00A' | ||||
|  | ||||
| export default { | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       dataForm: { | ||||
|         id: 0, | ||||
|         name: undefined, | ||||
|         createTime: undefined, | ||||
|         taskCode: undefined, | ||||
|         taskType: undefined, | ||||
|         craftName: undefined, | ||||
|         planQuantity: undefined, | ||||
|         subProccessName: undefined | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     init(id) { | ||||
|       this.dataForm.id = id || '' | ||||
|       this.visible = true | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs['dataForm'].resetFields() | ||||
|         if (this.dataForm.id) { | ||||
|           ProcessInfoDetail(this.dataForm.id).then(res => { | ||||
|             this.dataForm = res.data | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										64
									
								
								src/views/orderManage/components/processLinkBtn.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										64
									
								
								src/views/orderManage/components/processLinkBtn.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,64 @@ | ||||
| <!-- | ||||
|  * @Date: 2021-01-07 20:09:37 | ||||
|  * @LastEditors: zwq | ||||
|  * @LastEditTime: 2022-01-17 15:16:29 | ||||
|  * @FilePath: \basic-admin\src\components\BaseTable\subcomponents\CheckDetail.vue | ||||
|  * @Description: | ||||
| --> | ||||
| <template> | ||||
|   <span> | ||||
|     <el-popover | ||||
|       v-model="visible" | ||||
|       placement="top" | ||||
|       width="160" | ||||
|     > | ||||
|       <div> | ||||
|         <el-select v-model="value" placeholder="请选择"> | ||||
|           <el-option | ||||
|             v-for="item in options" | ||||
|             :key="item.value" | ||||
|             :label="item.label" | ||||
|             :value="item.value" | ||||
|           /> | ||||
|         </el-select> | ||||
|       </div> | ||||
|       <div style="text-align: right; margin: 0"> | ||||
|         <el-button size="mini" type="text" @click="visible = false">取消</el-button> | ||||
|         <el-button type="primary" size="mini" @click="emitClick">确定</el-button> | ||||
|       </div> | ||||
|       <el-button slot="reference" type="text">{{ $t('module.basicData.Warehouse.RelateProcess') }}</el-button> | ||||
|     </el-popover> | ||||
|   </span> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| export default { | ||||
|   props: { | ||||
|     injectData: { | ||||
|       type: Object, | ||||
|       default: () => ({}) | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       visible: false, | ||||
|       options: [{ | ||||
|         value: '选项1', | ||||
|         label: '黄金糕' | ||||
|       }, { | ||||
|         value: '选项2', | ||||
|         label: '双皮奶' | ||||
|       } | ||||
|       ], | ||||
|       value: '' | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     emitClick() { | ||||
|       console.log(this.injectData) | ||||
|       console.log(this.value) | ||||
|       this.visible = false | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
							
								
								
									
										191
									
								
								vue.config.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										191
									
								
								vue.config.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,191 @@ | ||||
| 'use strict' | ||||
| const path = require('path') | ||||
| const defaultSettings = require('./src/settings.js') | ||||
|  | ||||
| function resolve(dir) { | ||||
|   return path.join(__dirname, dir) | ||||
| } | ||||
|  | ||||
| const name = defaultSettings.title || 'vue Element Admin' // page title | ||||
|  | ||||
| // If your port is set to 80, | ||||
| // use administrator privileges to execute the command line. | ||||
| // For example, Mac: sudo npm run | ||||
| // You can change the port by the following method: | ||||
| // port = 9527 npm run dev OR npm run dev --port = 9527 | ||||
| const port = process.env.port || process.env.npm_config_port || 9527 // dev port | ||||
| // All configuration item explanations can be find in https://cli.vuejs.org/config/ | ||||
| module.exports = { | ||||
|   /** | ||||
|    * You will need to set publicPath if you plan to deploy your site under a sub path, | ||||
|    * for example GitHub Pages. If you plan to deploy your site to https://foo.github.io/bar/, | ||||
|    * then publicPath should be set to "/bar/". | ||||
|    * In most cases please use '/' !!! | ||||
|    * Detail: https://cli.vuejs.org/config/#publicpath | ||||
|    */ | ||||
|   publicPath: '', | ||||
|   outputDir: 'dist', | ||||
|   assetsDir: 'static', | ||||
|   lintOnSave: process.env.NODE_ENV === 'development', | ||||
|   productionSourceMap: false, | ||||
|   devServer: { | ||||
|     port: port, | ||||
|     open: false, | ||||
|     overlay: { | ||||
|       warnings: false, | ||||
|       errors: true | ||||
|     }, | ||||
|     // allowedHosts: ['192.168.0.104:8080', '192.168.0.104:8081'], | ||||
|     // headers: { | ||||
|     //   'Access-Control-Allow-Origin': '192.168.0.104:8080, 192.168.0.104:8081', | ||||
|     //   'Access-Control-Allow-Headers': '*', | ||||
|     //   'Access-Control-Allow-Methods': '*', | ||||
|     //   'Access-Control-Allow-Credentials': 'true' | ||||
|     // }, | ||||
|     // before: require('./mock/mock-server.js'), | ||||
|     // 这里写入需要代理的api和对应的目标地址 | ||||
|     proxy: { | ||||
|       '/api': { | ||||
|         // target: 'http://localhost:8080', | ||||
|         // target: 'http://192.168.0.148:8080', | ||||
|         target: 'http://a.wms.picaiba.com/api', | ||||
|         // target: 'http://192.168.0.127:8080', | ||||
|         // target: 'http://192.168.0.165:8080', | ||||
|         // target: 'http://192.168.43.105:8080', | ||||
|         // target: 'http://127.0.0.1:8080', | ||||
|         // target: 'http://192.168.0.70:8080', | ||||
|         // target: 'http://192.168.0.199:8080', | ||||
|  | ||||
|         ws: true, | ||||
|         changeOrigin: true, | ||||
|         pathRewrite: { | ||||
|           '^/api': '' | ||||
|         } | ||||
|         // 使用了proxy 就需要开启下面的选项 (http-proxy-middleware会将post请求给parse了 所以需要再次进行string化) | ||||
|         // onProxyReq: (proxyReq, req, res, options) => { | ||||
|         //   if (req.body) { | ||||
|         //     const bodyData = JSON.stringify(req.body) | ||||
|         //     // incase if content-type is application/x-www-form-urlencoded -> we need to change to application/json | ||||
|         //     proxyReq.setHeader('Content-Type', 'application/json') | ||||
|         //     proxyReq.setHeader('Content-Length', Buffer.byteLength(bodyData)) | ||||
|         //     // stream the content | ||||
|         //     proxyReq.write(bodyData) | ||||
|         //   } | ||||
|         // } | ||||
|       }, | ||||
|       '/spc': { | ||||
|         // target: 'http://192.168.0.180:8080', | ||||
|         target: 'http://58.210.206.230:8000', | ||||
|         // target: 'http://192.168.0.187:8080', | ||||
|         // target: 'http://192.168.43.105:8080', | ||||
|         // target: 'http://127.0.0.1:8080', | ||||
|         ws: true, | ||||
|         changeOrigin: true, | ||||
|         pathRewrite: { | ||||
|           '^/spc': '' | ||||
|         } | ||||
|         // 使用了proxy 就需要开启下面的选项 (http-proxy-middleware会将post请求给parse了 所以需要再次进行string化) | ||||
|         // onProxyReq: (proxyReq, req, res, options) => { | ||||
|         //   if (req.body) { | ||||
|         //     const bodyData = JSON.stringify(req.body) | ||||
|         //     // incase if content-type is application/x-www-form-urlencoded -> we need to change to application/json | ||||
|         //     proxyReq.setHeader('Content-Type', 'application/json') | ||||
|         //     proxyReq.setHeader('Content-Length', Buffer.byteLength(bodyData)) | ||||
|         //     // stream the content | ||||
|         //     proxyReq.write(bodyData) | ||||
|         //   } | ||||
|         // } | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   configureWebpack: { | ||||
|     // provide the app's title in webpack's name field, so that | ||||
|     // it can be accessed in index.html to inject the correct title. | ||||
|     name: name, | ||||
|     resolve: { | ||||
|       alias: { | ||||
|         '@': resolve('src') | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   css: { | ||||
|     loaderOptions: { | ||||
|       // vue cli默认使用node-sass作为sass预处理器,使用下面的选项可以使用sass包作为预处理器 | ||||
|       // 用于解决node-sass需要从外网下载依赖的卡顿问题 | ||||
|       sass: { | ||||
|         implementation: require('sass') | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   chainWebpack(config) { | ||||
|     config.plugins.delete('preload') // TODO: need test | ||||
|     config.plugins.delete('prefetch') // TODO: need test | ||||
|  | ||||
|     // set svg-sprite-loader | ||||
|     config.module | ||||
|       .rule('svg') | ||||
|       .exclude.add(resolve('src/icons')) | ||||
|       .end() | ||||
|     config.module | ||||
|       .rule('icons') | ||||
|       .test(/\.svg$/) | ||||
|       .include.add(resolve('src/icons')) | ||||
|       .end() | ||||
|       .use('svg-sprite-loader') | ||||
|       .loader('svg-sprite-loader') | ||||
|       .options({ | ||||
|         symbolId: 'icon-[name]' | ||||
|       }) | ||||
|       .end() | ||||
|  | ||||
|     // set preserveWhitespace | ||||
|     config.module | ||||
|       .rule('vue') | ||||
|       .use('vue-loader') | ||||
|       .loader('vue-loader') | ||||
|       .tap(options => { | ||||
|         options.compilerOptions.preserveWhitespace = true | ||||
|         return options | ||||
|       }) | ||||
|       .end() | ||||
|  | ||||
|     config | ||||
|       .when(process.env.NODE_ENV !== 'development', | ||||
|         config => { | ||||
|           config | ||||
|             .plugin('ScriptExtHtmlWebpackPlugin') | ||||
|             .after('html') | ||||
|             .use('script-ext-html-webpack-plugin', [{ | ||||
|               // `runtime` must same as runtimeChunk name. default is `runtime` | ||||
|               inline: /runtime\..*\.js$/ | ||||
|             }]) | ||||
|             .end() | ||||
|           config | ||||
|             .optimization.splitChunks({ | ||||
|               chunks: 'all', | ||||
|               cacheGroups: { | ||||
|                 libs: { | ||||
|                   name: 'chunk-libs', | ||||
|                   test: /[\\/]node_modules[\\/]/, | ||||
|                   priority: 10, | ||||
|                   chunks: 'initial' // only package third parties that are initially dependent | ||||
|                 }, | ||||
|                 elementUI: { | ||||
|                   name: 'chunk-elementUI', // split elementUI into a single package | ||||
|                   priority: 20, // the weight needs to be larger than libs and app or it will be packaged into libs or app | ||||
|                   test: /[\\/]node_modules[\\/]_?element-ui(.*)/ // in order to adapt to cnpm | ||||
|                 }, | ||||
|                 commons: { | ||||
|                   name: 'chunk-commons', | ||||
|                   test: resolve('src/components'), // can customize your rules | ||||
|                   minChunks: 3, //  minimum common number | ||||
|                   priority: 5, | ||||
|                   reuseExistingChunk: true | ||||
|                 } | ||||
|               } | ||||
|             }) | ||||
|           config.optimization.runtimeChunk('single') | ||||
|         } | ||||
|       ) | ||||
|   } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user