From f2f3a9e850136eebf1b1613bd7451ba03a0692ef Mon Sep 17 00:00:00 2001 From: lb Date: Mon, 11 Sep 2023 15:24:11 +0800 Subject: [PATCH 1/8] =?UTF-8?q?update=20=E8=AE=BE=E5=A4=87=E5=85=A8?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../monitoring/equipmentFullParams/index.vue | 105 +++++++----------- yarn.lock | 58 ++++++++++ 2 files changed, 98 insertions(+), 65 deletions(-) diff --git a/src/views/monitoring/equipmentFullParams/index.vue b/src/views/monitoring/equipmentFullParams/index.vue index ef2c84b8..5c2e99a3 100644 --- a/src/views/monitoring/equipmentFullParams/index.vue +++ b/src/views/monitoring/equipmentFullParams/index.vue @@ -12,31 +12,7 @@ ref="search-bar" @headBtnClick="handleSearchBarBtnClick" /> - - -
+
- -
+
暂无数据
+ + diff --git a/src/views/base/equipmentBindSection/index.vue b/src/views/base/equipmentBindSection/index.vue index cd653693..a18dd588 100644 --- a/src/views/base/equipmentBindSection/index.vue +++ b/src/views/base/equipmentBindSection/index.vue @@ -53,10 +53,10 @@ import { } from '@/api/base/equipmentBindSection'; import moment from 'moment'; import basicPageMixin from '@/mixins/lb/basicPageMixin'; - +import DialogForm from './dialogForm.vue'; export default { name: 'EquipmentBindSection', - components: {}, + components: { DialogForm }, mixins: [basicPageMixin], data() { return { @@ -181,8 +181,8 @@ export default { select: true, label: '工段', url: '/base/workshop-section/listByParentId', // 根据产线获取 - // depends: '__product_line', // 依赖产线获取数据 - depends: 'productionLineId', + // depends: '__product_line', // 依赖产线获取数据 + depends: 'productionLineId', prop: 'workshopSectionId', rules: [{ required: true, message: '不能为空', trigger: 'blur' }], }, From 529889fd074a72751afd354796826c2a306ebe72 Mon Sep 17 00:00:00 2001 From: lb Date: Tue, 12 Sep 2023 11:09:51 +0800 Subject: [PATCH 3/8] =?UTF-8?q?update=20=E5=B7=A5=E6=AE=B5=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E7=BB=91=E5=AE=9A=20dialogForm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../base/equipmentBindSection/dialogForm.vue | 58 +++++++++---------- src/views/base/equipmentBindSection/index.vue | 2 +- 2 files changed, 28 insertions(+), 32 deletions(-) diff --git a/src/views/base/equipmentBindSection/dialogForm.vue b/src/views/base/equipmentBindSection/dialogForm.vue index 089fea6c..91645365 100644 --- a/src/views/base/equipmentBindSection/dialogForm.vue +++ b/src/views/base/equipmentBindSection/dialogForm.vue @@ -6,7 +6,11 @@ --> From b17bc0e1629541ff733ca2c1392e7a6a47ab7d18 Mon Sep 17 00:00:00 2001 From: lb Date: Tue, 12 Sep 2023 11:12:05 +0800 Subject: [PATCH 4/8] update build:prod PUBLIC_PATH --- .env.prod | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.env.prod b/.env.prod index a1415ed3..4c6133c8 100644 --- a/.env.prod +++ b/.env.prod @@ -8,7 +8,9 @@ VUE_APP_TITLE = 芋道管理系统 VUE_APP_BASE_API = '/prod-api' # 根据服务器或域名修改 -PUBLIC_PATH = 'http://my-pi.com:8888/yudao-admin/' +# PUBLIC_PATH = 'http://my-pi.com:8888/yudao-admin/' +PUBLIC_PATH = 'http://192.168.0.33:8888/' + # 二级部署路径 VUE_APP_APP_NAME ='yudao-admin' From f341ec7b3012939da2af368a0a7e647e3ddb8911 Mon Sep 17 00:00:00 2001 From: lb Date: Wed, 13 Sep 2023 12:24:52 +0800 Subject: [PATCH 5/8] update router mode --- src/router/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/router/index.js b/src/router/index.js index 1d64f59b..ca26742b 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -247,7 +247,7 @@ Router.prototype.push = function push(location) { export default new Router({ base: process.env.VUE_APP_APP_NAME ? process.env.VUE_APP_APP_NAME : "/", - mode: 'history', // 去掉url中的# + mode: 'hash', // 去掉url中的# scrollBehavior: () => ({y: 0}), routes: constantRoutes }) From e8cc1fc50b32559fd6e1c07a9c2635805dde76d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=98937886381=E2=80=99?= <‘937886381@qq.com’> Date: Wed, 13 Sep 2023 16:00:43 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=E7=94=9F=E4=BA=A7=E5=88=86=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.dev | 10 +- src/api/core/analysis/index.js | 24 ++ src/api/core/monitoring/index.js | 16 + src/assets/images/pay/icon/alipay_app.svg | 2 +- src/views/base/equipmentPlcConnect/http.js | 9 +- src/views/core/analysis/LineChart.vue | 93 +++++ .../core/analysis/balanceAnalysis/index.vue | 331 ++++++++++-------- .../core/analysis/yieldAnalysis/index.vue | 233 +++++++----- .../sectionStatisticsSearch/index.vue | 79 +++-- 9 files changed, 534 insertions(+), 263 deletions(-) create mode 100644 src/api/core/analysis/index.js create mode 100644 src/api/core/monitoring/index.js create mode 100644 src/views/core/analysis/LineChart.vue diff --git a/.env.dev b/.env.dev index e5856184..ab61468a 100644 --- a/.env.dev +++ b/.env.dev @@ -1,10 +1,10 @@ ### # @Author: Do not edit # @Date: 2023-08-29 09:40:39 - # @LastEditTime: 2023-09-11 15:55:29 - # @LastEditors: DY - # @Description: -### + # @LastEditTime: 2023-09-12 14:01:15 + # @LastEditors: zhp + # @Description: +### # 开发环境配置 ENV = 'development' @@ -12,7 +12,7 @@ ENV = 'development' VUE_APP_TITLE = 芋道管理系统 # 芋道管理系统/开发环境 -VUE_APP_BASE_API = 'http://192.168.1.49:48080' +VUE_APP_BASE_API = 'http://192.168.1.188:48080' # VUE_APP_BASE_API = 'http://192.168.1.8:48080' # VUE_APP_BASE_API = 'http://192.168.0.33:48080' # VUE_APP_BASE_API = 'http://192.168.1.188:48080' diff --git a/src/api/core/analysis/index.js b/src/api/core/analysis/index.js new file mode 100644 index 00000000..af791ff5 --- /dev/null +++ b/src/api/core/analysis/index.js @@ -0,0 +1,24 @@ +/* + * @Author: zhp + * @Date: 2023-09-12 14:07:04 + * @LastEditTime: 2023-09-13 09:53:45 + * @LastEditors: zhp + * @Description: + */ +import request from '@/utils/request' + +export function getYieldAnalysisPageData(data) { + return request({ + url: '/analysis/production-analysis/getOutput', + method: 'post', + data: data + }) +} + +export function getCT(data) { + return request({ + url: '/analysis/production-analysis/getCT', + method: 'post', + data: data + }) +} diff --git a/src/api/core/monitoring/index.js b/src/api/core/monitoring/index.js new file mode 100644 index 00000000..13eb6963 --- /dev/null +++ b/src/api/core/monitoring/index.js @@ -0,0 +1,16 @@ +/* + * @Author: zhp + * @Date: 2023-09-12 14:07:04 + * @LastEditTime: 2023-09-13 09:46:44 + * @LastEditors: zhp + * @Description: + */ +import request from '@/utils/request' + +export function getSectionDataSearch(data) { + return request({ + url: '/monitoring/production-monitor/getSectionDataSearch', + method: 'post', + data: data + }) +} diff --git a/src/assets/images/pay/icon/alipay_app.svg b/src/assets/images/pay/icon/alipay_app.svg index ebf11883..c77a3d9f 100644 --- a/src/assets/images/pay/icon/alipay_app.svg +++ b/src/assets/images/pay/icon/alipay_app.svg @@ -1 +1 @@ - \ No newline at end of file + diff --git a/src/views/base/equipmentPlcConnect/http.js b/src/views/base/equipmentPlcConnect/http.js index 16544450..b87d0ed7 100644 --- a/src/views/base/equipmentPlcConnect/http.js +++ b/src/views/base/equipmentPlcConnect/http.js @@ -1,6 +1,13 @@ +/* + * @Author: zhp + * @Date: 2023-09-11 16:18:44 + * @LastEditTime: 2023-09-12 14:25:01 + * @LastEditors: zhp + * @Description: + */ import Mock from 'mockjs'; -const baseURL = 'http://192.168.1.49:48080/admin-api'; +const baseURL = 'http://192.168.1.188:48080/admin-api'; Mock.setup({ timeout: 200, diff --git a/src/views/core/analysis/LineChart.vue b/src/views/core/analysis/LineChart.vue new file mode 100644 index 00000000..49c1565f --- /dev/null +++ b/src/views/core/analysis/LineChart.vue @@ -0,0 +1,93 @@ + + + + diff --git a/src/views/core/analysis/balanceAnalysis/index.vue b/src/views/core/analysis/balanceAnalysis/index.vue index e0de210b..a3a2ca3f 100644 --- a/src/views/core/analysis/balanceAnalysis/index.vue +++ b/src/views/core/analysis/balanceAnalysis/index.vue @@ -1,159 +1,200 @@ - diff --git a/src/views/core/analysis/yieldAnalysis/index.vue b/src/views/core/analysis/yieldAnalysis/index.vue index ee6a5ce5..ed38a9fb 100644 --- a/src/views/core/analysis/yieldAnalysis/index.vue +++ b/src/views/core/analysis/yieldAnalysis/index.vue @@ -1,114 +1,95 @@ + + diff --git a/src/views/core/monitoring/sectionStatistics/index.vue b/src/views/core/monitoring/sectionStatistics/index.vue index 0aeaf6ad..152f4acd 100644 --- a/src/views/core/monitoring/sectionStatistics/index.vue +++ b/src/views/core/monitoring/sectionStatistics/index.vue @@ -1,7 +1,7 @@ @@ -9,6 +9,7 @@
import { parseTime } from '../../mixins/code-filter'; -import { - getFactoryPage, - exportFactoryExcel, -} from '@/api/core/base/factory'; +import { getWorkshopSectionList, getPdList, getSectionAutoReport } from '@/api/core/monitoring/sectionStatistics' const tableProps = [ { - prop: 'code', - label: '产线类型', - align: 'center', + prop: 'reportType', + label: '产线类型' }, { - prop: 'createTime', + prop: 'reportStartTime', label: '统计开始时间', - align: 'center', filter: parseTime, }, { - prop: 'createTime3', + prop: 'reportEndTime', label: '统计结束时间', - align: 'center', filter: parseTime, }, { - prop: 'name', - label: '产线名称', - align: 'center', + prop: 'lineName', + label: '产线名称' }, { - prop: 'name1', - label: '工段名称', - align: 'center', + prop: 'sectionName', + label: '工段名称' }, { - prop: 'address', - label: '投入数量/片', - align: 'center', + prop: 'inputNum', + label: '投入数量/片' }, { - prop: 'remark44', - label: '产出数量/片', - align: 'center', + prop: 'outputNum', + label: '产出数量/片' }, { - prop: 'remark23', - label: '产出面积/㎡', - align: 'center', + prop: 'outputArea', + label: '产出面积/㎡' }, { - prop: 'remark145', - label: '损耗数量/片', - align: 'center', + prop: 'lossNum', + label: '损耗数量/片' }, { - prop: 'remark22', - label: '损耗面积/㎡', - align: 'center', + prop: 'lossArea', + label: '损耗面积/㎡' }, { - prop: 'remark1', - label: '损耗比例%', - align: 'center', + prop: 'lossRatio', + label: '损耗比例%' } ]; @@ -107,15 +94,8 @@ export default { data() { return { urlOptions: { - getDataListURL: getFactoryPage, - exportURL: exportFactoryExcel, + getDataListURL: getSectionAutoReport }, - urlOptions: { - getDataListURL: '', - deleteURL: '', - statusUrl: '', - exportURL: '' - }, tableData: [], listQuery: { pageSize: 10, @@ -145,8 +125,21 @@ export default { { type: 'select', label: '报表类型', - selectOptions: [], - param: 'name', + selectOptions: [ + { + id: 1, + name: '日' + }, + { + id: 2, + name: '周' + }, + { + id: 3, + name: '月' + } + ], + param: 'reportType', }, { type: 'datePicker', @@ -158,8 +151,7 @@ export default { startPlaceholder: '开始时间', endPlaceholder: '结束时间', param: 'timeVal', - defaultSelect: [], - width: 350 + defaultSelect: [] }, { type: 'button', @@ -180,8 +172,20 @@ export default { ], }; }, - created() {}, + created() { + this.getDataList() + this.getPdLineList() + }, methods: { + getPdLineList() { + getPdList().then((res) => { + this.formConfig[0].selectOptions = res.data || [] + }) + // 获取工段list + getWorkshopSectionList().then((res) => { + this.formConfig[1].selectOptions = res.data || [] + }) + }, selectChange(val) { console.log(val) this.selectedList = val @@ -191,8 +195,11 @@ export default { case 'search': this.listQuery.pageNo = 1; this.listQuery.pageSize = 10; - this.listQuery.name = val.name; - this.listQuery.code = val.code; + this.listQuery.lineId = val.line ? val.line : undefined; + this.listQuery.sectionId = val.section ? val.section : undefined; + this.listQuery.reportType = val.reportType ? val.reportType : undefined; + this.listQuery.reportStartTime = [new Date(val.timeVal[0]).getTime()]; + this.listQuery.reportEndTime = [new Date(val.timeVal[1]).getTime()]; this.getDataList(); break; case 'export': @@ -206,7 +213,10 @@ export default { getDataList() { this.dataListLoading = true; this.urlOptions.getDataListURL(this.listQuery).then(response => { - this.tableData = response.data.list; + this.tableData = response.data.list.map(item => { + item.reportType = item.reportType === 1 ? '日' : item.reportType === 2 ? '周' : '月' + return item + }); this.total = response.data.total; this.dataListLoading = false; }); From bc5d3d44d5ca65527d97d1539aa8702d36949d73 Mon Sep 17 00:00:00 2001 From: helloDy <1615073571@qq.com> Date: Sat, 16 Sep 2023 17:51:09 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.dev | 2 +- .../core/analysis/balanceAnalysis/index.vue | 115 +++++++++---- src/views/core/monitoring/auto/index.vue | 32 ++-- src/views/core/monitoring/data/index.vue | 74 ++++++++- src/views/core/monitoring/data24/index.vue | 156 ++++++++++-------- .../monitoring/sectionStatistics/index.vue | 98 +++++++++-- 6 files changed, 344 insertions(+), 133 deletions(-) diff --git a/.env.dev b/.env.dev index 2dc89b0f..d9a29fce 100644 --- a/.env.dev +++ b/.env.dev @@ -1,7 +1,7 @@ ### # @Author: Do not edit # @Date: 2023-08-29 09:40:39 - # @LastEditTime: 2023-09-15 14:38:26 + # @LastEditTime: 2023-09-16 09:41:07 # @LastEditors: DY # @Description: ### diff --git a/src/views/core/analysis/balanceAnalysis/index.vue b/src/views/core/analysis/balanceAnalysis/index.vue index a3a2ca3f..ffa09229 100644 --- a/src/views/core/analysis/balanceAnalysis/index.vue +++ b/src/views/core/analysis/balanceAnalysis/index.vue @@ -1,7 +1,7 @@