@@ -24,6 +24,7 @@
diff --git a/src/views/quality/base/qualityScrapDet/index.vue b/src/views/quality/base/qualityScrapDet/index.vue
new file mode 100644
index 00000000..82467b0e
--- /dev/null
+++ b/src/views/quality/base/qualityScrapDet/index.vue
@@ -0,0 +1,169 @@
+
+
+
+
+
diff --git a/src/views/quality/base/qualityScrapLog/add-or-updata.vue b/src/views/quality/base/qualityScrapLog/add-or-updata.vue
new file mode 100644
index 00000000..a46f3101
--- /dev/null
+++ b/src/views/quality/base/qualityScrapLog/add-or-updata.vue
@@ -0,0 +1,209 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/base/qualityScrapLog/index.vue b/src/views/quality/base/qualityScrapLog/index.vue
new file mode 100644
index 00000000..220a78b1
--- /dev/null
+++ b/src/views/quality/base/qualityScrapLog/index.vue
@@ -0,0 +1,220 @@
+
+
+
+
+
diff --git a/src/views/quality/base/qualityScrapType/add-or-updata.vue b/src/views/quality/base/qualityScrapType/add-or-updata.vue
new file mode 100644
index 00000000..9979724b
--- /dev/null
+++ b/src/views/quality/base/qualityScrapType/add-or-updata.vue
@@ -0,0 +1,86 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/base/qualityScrapType/index.vue b/src/views/quality/base/qualityScrapType/index.vue
new file mode 100644
index 00000000..156ab946
--- /dev/null
+++ b/src/views/quality/base/qualityScrapType/index.vue
@@ -0,0 +1,169 @@
+
+
+
+
+
diff --git a/src/views/quality/monitoring/currentData/dialogForm.vue b/src/views/quality/monitoring/currentData/dialogForm.vue
new file mode 100644
index 00000000..9ef8b17c
--- /dev/null
+++ b/src/views/quality/monitoring/currentData/dialogForm.vue
@@ -0,0 +1,270 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/currentData/index.vue b/src/views/quality/monitoring/currentData/index.vue
new file mode 100644
index 00000000..81e49adc
--- /dev/null
+++ b/src/views/quality/monitoring/currentData/index.vue
@@ -0,0 +1,436 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/deviceParameters/components/pieChart.vue b/src/views/quality/monitoring/deviceParameters/components/pieChart.vue
new file mode 100644
index 00000000..249e5b3b
--- /dev/null
+++ b/src/views/quality/monitoring/deviceParameters/components/pieChart.vue
@@ -0,0 +1,279 @@
+
+
+
+
+
+
+
+
+
{{ textData.workTime }}
+
工作时长
+
+
+
+
{{ textData.stopTime }}
+
停机时长
+
+
+
+
{{ textData.downTime }}
+
故障时长
+
+
+
+
{{ textData.peEfficiency }}
+
速度开动率
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/deviceParameters/index.vue b/src/views/quality/monitoring/deviceParameters/index.vue
new file mode 100644
index 00000000..0c30de48
--- /dev/null
+++ b/src/views/quality/monitoring/deviceParameters/index.vue
@@ -0,0 +1,714 @@
+
+
+
+
+
+
+ {{ currentFactory?.label || '点我选择工厂' }}
+
+
+ -
+
+ {{ fc.label }}
+
+
+
+
+
+ - 无 -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
handleEmitFun(table, val)">
+
+ getListFor(table, { page, limit, current })
+ " />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/deviceParameters/utils/local-data-manager.js b/src/views/quality/monitoring/deviceParameters/utils/local-data-manager.js
new file mode 100644
index 00000000..5d8c76fd
--- /dev/null
+++ b/src/views/quality/monitoring/deviceParameters/utils/local-data-manager.js
@@ -0,0 +1,36 @@
+export default class LocalDataManager {
+ constructor(dataList, pageNo, pageSize) {
+ this._dataListStore = dataList;
+ this._pageNo = pageNo;
+ this._pageSize = pageSize;
+ }
+
+ set pageNo(pageNo) {
+ console.log('set pageNo', pageNo);
+ this._pageNo = pageNo;
+ }
+
+ set pageSize(pageSize) {
+ console.log('set pageSize', pageSize);
+ this._pageSize = pageSize;
+ }
+
+ get dataList() {
+ const firstLine = this._dataListStore[0];
+ const realDataList = this._dataListStore.slice(1);
+ return [
+ firstLine,
+ ...realDataList.slice((this._pageNo - 1) * this._pageSize, this._pageNo * this._pageSize)
+ ]
+ }
+
+ get total() {
+ return this._dataListStore.length;
+ }
+
+ deleteData(id) {
+ const idx = this._dataListStore.findIndex(item => item.id == id);
+ this._dataListStore.splice(idx, 1);
+ // send http request
+ }
+}
\ No newline at end of file
diff --git a/src/views/quality/monitoring/equipmentTraceability/components/pieChart.vue b/src/views/quality/monitoring/equipmentTraceability/components/pieChart.vue
new file mode 100644
index 00000000..249e5b3b
--- /dev/null
+++ b/src/views/quality/monitoring/equipmentTraceability/components/pieChart.vue
@@ -0,0 +1,279 @@
+
+
+
+
+
+
+
+
+
{{ textData.workTime }}
+
工作时长
+
+
+
+
{{ textData.stopTime }}
+
停机时长
+
+
+
+
{{ textData.downTime }}
+
故障时长
+
+
+
+
{{ textData.peEfficiency }}
+
速度开动率
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/equipmentTraceability/index.vue b/src/views/quality/monitoring/equipmentTraceability/index.vue
new file mode 100644
index 00000000..c88a7f60
--- /dev/null
+++ b/src/views/quality/monitoring/equipmentTraceability/index.vue
@@ -0,0 +1,576 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
各设备加工数量
+
+
+
+ 工作时长
+
+
+
+ 停机时长
+
+
+
+ 故障时长
+
+
+
+ 速度开动率
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/materielDateFrom/index.vue b/src/views/quality/monitoring/materielDateFrom/index.vue
new file mode 100644
index 00000000..95791604
--- /dev/null
+++ b/src/views/quality/monitoring/materielDateFrom/index.vue
@@ -0,0 +1,247 @@
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/mixins/basic-add.js b/src/views/quality/monitoring/mixins/basic-add.js
new file mode 100644
index 00000000..0b9acd23
--- /dev/null
+++ b/src/views/quality/monitoring/mixins/basic-add.js
@@ -0,0 +1,100 @@
+/*
+ * @Author: zwq
+ * @Date: 2022-08-24 11:19:43
+ * @LastEditors: zwq
+ * @LastEditTime: 2023-08-03 14:21:04
+ * @Description:
+ */
+export default {
+ data() {
+ /* eslint-disable */
+ return {
+ urlOptions: {
+ createURL: '',
+ updateURL: '',
+ infoURL: '',
+ codeURL: '',
+ getOption: false,
+ isGetCode: false,
+ optionArrUrl: [],
+ optionArr: {}
+ },
+ visible: false,
+ setData: false
+ }
+ },
+ created() {
+ },
+ activated() {
+ },
+ methods: {
+ init(id) {
+ this.dataForm.id = id || "";
+ this.visible = true;
+ if (this.urlOptions.getOption) {
+ this.getArr()
+ }
+ this.$nextTick(() => {
+ this.$refs["dataForm"].resetFields();
+ if (this.dataForm.id) {
+ this.urlOptions.infoURL(id).then(response => {
+ this.dataForm = response.data;
+ if (this.setData) {
+ this.setDataForm()
+ }
+ });
+ } else {
+ if (this.urlOptions.isGetCode) {
+ this.getCode()
+ }
+ }
+ });
+ },
+ getCode() {
+ this.urlOptions.codeURL()
+ .then(({ data: res }) => {
+ this.dataForm.code = res;
+ })
+ .catch(() => {});
+ },
+ getArr() {
+ const params = {
+ pageSize: 100,
+ pageNo: 1,
+ }
+ this.urlOptions.optionArrUrl.forEach((item, index) => {
+ item(params).then(({ data: res }) => {
+ this.$set(this.urlOptions.optionArr, `arr${index}`, res.list)
+ })
+ .catch(() => {
+ });
+ });
+ },
+ // 表单提交
+ dataFormSubmit() {
+ this.$refs["dataForm"].validate((valid) => {
+ if (!valid) {
+ return false;
+ }
+ // 修改的提交
+ if (this.dataForm.id) {
+ this.urlOptions.updateURL(this.dataForm).then(response => {
+ this.$modal.msgSuccess("修改成功");
+ this.visible = false;
+ this.$emit("refreshDataList");
+ });
+ return;
+ }
+ // 添加的提交
+ this.urlOptions.createURL(this.dataForm).then(response => {
+ this.$modal.msgSuccess("新增成功");
+ this.visible = false;
+ this.$emit("refreshDataList");
+ });
+ });
+ },
+ formClear() {
+ this.$refs.dataForm.resetFields()
+ }
+ }
+}
diff --git a/src/views/quality/monitoring/mixins/basic-page.js b/src/views/quality/monitoring/mixins/basic-page.js
new file mode 100644
index 00000000..8723be82
--- /dev/null
+++ b/src/views/quality/monitoring/mixins/basic-page.js
@@ -0,0 +1,168 @@
+/*
+ * @Author: zwq
+ * @Date: 2022-08-24 11:19:43
+ * @LastEditors: DY
+ * @LastEditTime: 2023-09-21 16:02:07
+ * @Description:
+ */
+export default {
+ data() {
+ /* eslint-disable */
+ return {
+ urlOptions: {
+ getDataListURL: '',
+ deleteURL: '',
+ statusUrl: '',
+ exportURL: ''
+ },
+ tableData: [],
+ listQuery: {
+ pageSize: 10,
+ pageNo: 1,
+ total: 1,
+ },
+ exportLoading: false,
+ dataListLoading: false,
+ addOrEditTitle: '',
+ addOrUpdateVisible: false,
+ }
+ },
+ created() {
+ },
+ mounted() {
+ this.getDataList()
+ },
+ methods: {
+ // 获取数据列表
+ getDataList() {
+ this.dataListLoading = true;
+ this.urlOptions.getDataListURL(this.listQuery).then(response => {
+ this.tableData = response.data.list;
+ this.listQuery.total = response.data.total;
+ this.dataListLoading = false;
+ });
+ },
+ // 每页数
+ sizeChangeHandle(val) {
+ this.listQuery.pageSize = val;
+ this.listQuery.pageNo = 1;
+ this.getDataList();
+ },
+ // 当前页
+ currentChangeHandle(val) {
+ this.listQuery.pageNo = val;
+ this.getDataList();
+ },
+ // 新增 / 修改
+ addOrUpdateHandle(id) {
+ this.addOrUpdateVisible = true;
+ this.$nextTick(() => {
+ this.$refs.addOrUpdate.init(id);
+ });
+ },
+ cancel(id) {
+ this.$refs["popover-" + id].showPopper = false;
+ },
+ //改变状态
+ changeStatus(id) {
+ this.$http
+ .post(this.urlOptions.statusUrl, { id })
+ .then(({ data: res }) => {
+ if (res.code !== 0) {
+ return this.$message.error(res.msg);
+ }
+ this.$refs["popover-" + id].showPopper = false;
+ this.$message({
+ message: this.$t("prompt.success"),
+ type: "success",
+ duration: 500,
+ onClose: () => {
+ this.getDataList();
+ },
+ });
+ })
+ .catch(() => { });
+ },
+ //tableBtn点击
+ handleClick(val) {
+ if (val.type === "edit") {
+ this.addOrUpdateVisible = true;
+ this.addOrEditTitle = "编辑";
+ this.$nextTick(() => {
+ this.$refs.addOrUpdate.init(val.data.id);
+ });
+ } else if (val.type === "delete") {
+ this.deleteHandle(val.data.id, val.data.name, val.data._pageIndex)
+ } else if (val.type === "change") {
+ this.changeStatus(val.data.id)
+ } else {
+ this.otherMethods(val)
+ }
+ },
+ // 删除
+ deleteHandle(id, name, index) {
+ this.$confirm(`确定对${name ? '[名称=' + name + ']' : '[序号=' + index + ']'}进行删除操作?`, "提示", {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ type: "warning",
+ })
+ .then(() => {
+ this.urlOptions.deleteURL(id).then(({ data }) => {
+ this.$message({
+ message: "操作成功",
+ type: "success",
+ duration: 1500,
+ onClose: () => {
+ this.getDataList();
+ },
+ });
+ });
+ })
+ .catch(() => { });
+ },
+ //search-bar点击
+ buttonClick(val) {
+ switch (val.btnName) {
+ case "search":
+ this.listQuery.xm1 = val.xm1;
+ this.listQuery.xm2 = val.xm2;
+ this.listQuery.pageNo = 1;
+ this.getDataList();
+ break;
+ case "add":
+ this.addOrEditTitle = '新增'
+ this.addOrUpdateVisible = true;
+ this.addOrUpdateHandle()
+ break;
+ default:
+ console.log(val)
+ }
+ },
+ handleCancel() {
+ this.$refs.addOrUpdate.formClear()
+ this.addOrUpdateVisible = false
+ this.addOrEditTitle = ''
+ },
+ handleConfirm() {
+ this.$refs.addOrUpdate.dataFormSubmit()
+ },
+ successSubmit() {
+ this.handleCancel()
+ this.getDataList()
+ },
+ /** 导出按钮操作 */
+ handleExport() {
+ // 处理查询参数
+ let params = { ...this.queryParams };
+ params.pageNo = undefined;
+ params.pageSize = undefined;
+ this.$modal.confirm('是否确认导出所有数据项?').then(() => {
+ this.exportLoading = true;
+ return this.urlOptions.exportURL(params);
+ }).then(response => {
+ this.$download.excel(response, '工厂.xls');
+ this.exportLoading = false;
+ }).catch(() => { });
+ }
+ }
+}
diff --git a/src/views/quality/monitoring/mixins/code-filter.js b/src/views/quality/monitoring/mixins/code-filter.js
new file mode 100644
index 00000000..30c5f12e
--- /dev/null
+++ b/src/views/quality/monitoring/mixins/code-filter.js
@@ -0,0 +1,69 @@
+
+/*
+ * @Date: 2020-12-29 16:49:28
+ * @LastEditors: DY
+ * @LastEditTime: 2023-09-12 11:13:34
+ * @FilePath: \basic-admin\src\filters\basicData\index.js
+ * @Description:
+ */
+
+const table = {
+ lineStatus: {
+ 1: '生产中',
+ 2: '停止',
+ 3: '未知',
+ },
+ reportType: {
+ 1: '日',
+ 2: '周',
+ 3: '月'
+ }
+}
+
+// 日期格式化
+export function parseTime(time, pattern) {
+ if (arguments.length === 0 || !time) {
+ return null
+ }
+ const format = pattern || '{y}-{m}-{d} {h}:{i}:{s}'
+ let date
+ if (typeof time === 'object') {
+ date = time
+ } else {
+ if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {
+ time = parseInt(time)
+ } else if (typeof time === 'string') {
+ time = time.replace(new RegExp(/-/gm), '/').replace('T', ' ').replace(new RegExp(/\.\d{3}/gm),'');
+ }
+ if ((typeof time === 'number') && (time.toString().length === 10)) {
+ time = time * 1000
+ }
+ date = new Date(time)
+ }
+ const formatObj = {
+ y: date.getFullYear(),
+ m: date.getMonth() + 1,
+ d: date.getDate(),
+ h: date.getHours(),
+ i: date.getMinutes(),
+ s: date.getSeconds(),
+ a: date.getDay()
+ }
+ const time_str = format.replace(/{([ymdhisa])+}/g, (result, key) => {
+ let value = formatObj[key]
+ // Note: getDay() returns 0 on Sunday
+ if (key === 'a') {
+ return ['日', '一', '二', '三', '四', '五', '六'][value]
+ }
+ if (result.length > 0 && value < 10) {
+ value = '0' + value
+ }
+ return value || 0
+ })
+ return time_str
+}
+export default function (dictTable) {
+ return function (val) {
+ return table?.[dictTable]?.[val]
+ }
+}
diff --git a/src/views/quality/monitoring/processTraceability/index.vue b/src/views/quality/monitoring/processTraceability/index.vue
new file mode 100644
index 00000000..23bcc1e9
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceability/index.vue
@@ -0,0 +1,267 @@
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessBomList.vue b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessBomList.vue
new file mode 100644
index 00000000..133c1816
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessBomList.vue
@@ -0,0 +1,180 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessDetail.vue b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessDetail.vue
new file mode 100644
index 00000000..00ef7f0c
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessDetail.vue
@@ -0,0 +1,486 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessInfo.vue b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessInfo.vue
new file mode 100644
index 00000000..e2c7240c
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessInfo.vue
@@ -0,0 +1,126 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessNode.js b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessNode.js
new file mode 100644
index 00000000..948aaf24
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceabilityDetail/components/ProcessNode.js
@@ -0,0 +1,170 @@
+import { Node, ObjectExt, Shape } from '@antv/x6';
+import { IdToName } from '@/utils'
+import cache from '@/utils/cache'
+import axios from '@/utils/request'
+import { v4 } from 'uuid'
+
+Shape.Edge.config({
+ attrs: {
+ line: {
+ stroke: '#ccc',
+ strokeWidth: 1,
+ targetMarker: {
+ name: 'block',
+ width: 1,
+ height: 1
+ },
+ },
+ }
+})
+
+
+export default class ProcessNode extends Node { }
+ProcessNode.config({
+ width: 200,
+ height: 100,
+ markup: [
+ {
+ tagName: 'rect',
+ selector: 'container',
+ attrs: {
+ x: 0,
+ y: 0,
+ width: 200,
+ height: 100,
+ fill: 'transparent',
+ stroke: '#ccc'
+ },
+ },
+ {
+ tagName: 'rect',
+ attrs: {
+ x: 0,
+ y: 0,
+ width: 200,
+ height: 50,
+ fill: '#ffffff',
+ },
+ },
+ {
+ tagName: 'rect',
+ attrs: {
+ x: 0,
+ y: 50,
+ width: 200,
+ height: 50,
+ fill: '#f8f8f8',
+ },
+ },
+ {
+ tagName: 'text',
+ selector: 'detName',
+ attrs: {
+ x: 20,
+ y: 30,
+ },
+ },
+ {
+ tagName: 'text',
+ selector: 'sectionName',
+ attrs: {
+ x: 115,
+ y: 30,
+ },
+ },
+ {
+ tagName: 'text',
+ selector: 'detDesc',
+ attrs: {
+ x: 26,
+ y: 80,
+ fill: '#777',
+ fontSize: 14,
+ fill: '#1a90fc',
+ },
+ },
+ ],
+ attrs: {
+ line: {
+ fill: 'red'
+ }
+ },
+ ports: {
+ groups: {
+ in: {
+ position: 'left',
+ attrs: {
+ circle: {
+ r: 2,
+ magnet: true,
+ stroke: '#0b58ff',
+ strokeWidth: 1,
+ fill: '#0b58ff'
+ }
+ }
+ },
+ out: {
+ position: 'right',
+ attrs: {
+ circle: {
+ r: 2,
+ magnet: true,
+ stroke: '#0b58ff',
+ strokeWidth: 1,
+ fill: '#0b58ff'
+ }
+ }
+ }
+ }
+ },
+ propHooks(metadata) {
+ const { detId, detName, detDesc, sectionName, processId, sectionId, ...others } = metadata;
+ // debugger;
+ if (detName) ObjectExt.setByPath(others, 'attrs/detName/text', detName);
+ if (detDesc) ObjectExt.setByPath(others, 'attrs/detDesc/text', detDesc);
+ if (sectionName) ObjectExt.setByPath(others, 'attrs/sectionName/text', sectionName);
+ if (detId) ObjectExt.setByPath(others, 'attrs/detId/text', detId);
+ if (processId) ObjectExt.setByPath(others, 'attrs/processId/text', processId);
+ if (sectionId) ObjectExt.setByPath(others, 'attrs/sectionId/text', sectionId);
+ return others;
+ }
+});
+
+export const CACHE_NAME = 'ProcessDetail::section';
+
+export async function getSectionFrom(sectionId) {
+ const sectionList = await cache.getList(
+ CACHE_NAME,
+ async () => {
+ const { code, data } = await axios(
+ '/base/core-production-line/listAll'
+ );
+ if (code == 0) {
+ return data;
+ }
+ }
+ );
+ return IdToName(sectionId, sectionList);
+}
+
+export async function createProcessNode({ flowId, id, name, sectionId, remark }) {
+ const sectionName = await getSectionFrom(sectionId);
+ return {
+ shape: 'process-node',
+ x: 0,
+ y: 0,
+ detName: name, // 工序名称
+ sectionName, // 工段
+ sectionId,
+ detDesc: remark, // 工序说明
+ processId: flowId, // 工艺ID
+ detId: id, // 工序ID
+ tools: [],
+ ports: [
+ { id: v4(), group: 'in' },
+ { id: v4(), group: 'out' },
+ ]
+ };
+}
+
+export async function createEdge(src, dest) { }
\ No newline at end of file
diff --git a/src/views/quality/monitoring/processTraceabilityDetail/index.vue b/src/views/quality/monitoring/processTraceabilityDetail/index.vue
new file mode 100644
index 00000000..34fb96a4
--- /dev/null
+++ b/src/views/quality/monitoring/processTraceabilityDetail/index.vue
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue b/src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue
index 1d660f8a..9ef8b17c 100644
--- a/src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue
+++ b/src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue
@@ -1,4 +1,4 @@
-
@@ -68,7 +68,7 @@ export default {
methods: {
async getList() {
const response = await this.$axios({
- url: '/monitoring/record-in-one-day/get',
+ url: '/analysis/record-in-one-day/get',
method: 'get',
});
const {
diff --git a/src/views/quality/monitoring/qualityStatistics/index.vue b/src/views/quality/monitoring/qualityStatistics/index.vue
index ec436dbb..40e96b6c 100644
--- a/src/views/quality/monitoring/qualityStatistics/index.vue
+++ b/src/views/quality/monitoring/qualityStatistics/index.vue
@@ -1,4 +1,4 @@
-
+
+
+
+
+
diff --git a/src/views/quality/monitoring/statisticalData/dialogForm.vue b/src/views/quality/monitoring/statisticalData/dialogForm.vue
new file mode 100644
index 00000000..9ef8b17c
--- /dev/null
+++ b/src/views/quality/monitoring/statisticalData/dialogForm.vue
@@ -0,0 +1,270 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/quality/monitoring/statisticalData/index.vue b/src/views/quality/monitoring/statisticalData/index.vue
new file mode 100644
index 00000000..a17c8621
--- /dev/null
+++ b/src/views/quality/monitoring/statisticalData/index.vue
@@ -0,0 +1,436 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/report/jmreport/index.vue b/src/views/report/jmreport/index.vue
index 3b968108..9039ebf0 100644
--- a/src/views/report/jmreport/index.vue
+++ b/src/views/report/jmreport/index.vue
@@ -1,3 +1,10 @@
+
From 3812eb38a9b77af4c789f54f38af13feecd1b727 Mon Sep 17 00:00:00 2001
From: juzi <819872918@qq.com>
Date: Thu, 9 Nov 2023 15:01:50 +0800
Subject: [PATCH 10/11] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AE=A2=E5=8D=95bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/base/delivery.js | 18 +++
src/api/base/orderManage.js | 9 ++
.../components/deliveryLogDetail.vue | 127 ++++++++++++------
.../deliveryLog/components/editDetail.vue | 124 +++++++++++++++++
src/views/delivery/deliveryLog/index.vue | 2 +-
.../components/deliveryLogDetDetail.vue | 11 +-
src/views/delivery/deliveryLogDet/index.vue | 2 +-
.../orderManage/components/addWorkOrder.vue | 57 +++-----
.../base/orderManage/components/orderAdd.vue | 100 ++++++--------
src/views/order/base/orderManage/index.vue | 95 +++++++++++--
.../base/orderManage/orderDetailData.vue | 77 +++++++----
11 files changed, 450 insertions(+), 172 deletions(-)
create mode 100644 src/views/delivery/deliveryLog/components/editDetail.vue
diff --git a/src/api/base/delivery.js b/src/api/base/delivery.js
index 4c095c6a..82c371c3 100644
--- a/src/api/base/delivery.js
+++ b/src/api/base/delivery.js
@@ -71,3 +71,21 @@ export function deliveryLogDetCreate(data) {
data: data
})
}
+
+// 获得一条发货详细
+export function deliveryLogDetGet(query) {
+ return request({
+ url: '/extend/delivery-log-det/get',
+ method: 'get',
+ params: query
+ })
+}
+
+// 编辑发货详情
+export function deliveryLogDetUpdate(data) {
+ return request({
+ url: '/extend/delivery-log-det/update',
+ method: 'put',
+ data: data
+ })
+}
diff --git a/src/api/base/orderManage.js b/src/api/base/orderManage.js
index 37cace76..38085d6a 100644
--- a/src/api/base/orderManage.js
+++ b/src/api/base/orderManage.js
@@ -137,4 +137,13 @@ export function bomUseNum(query) {
method: 'get',
params: query
})
+}
+
+// 完成订单
+export function orderFinish(query) {
+ return request({
+ url: '/base/order/finish',
+ method: 'post',
+ params: query
+ })
}
\ No newline at end of file
diff --git a/src/views/delivery/deliveryLog/components/deliveryLogDetail.vue b/src/views/delivery/deliveryLog/components/deliveryLogDetail.vue
index caa9aef9..9f1b0827 100644
--- a/src/views/delivery/deliveryLog/components/deliveryLogDetail.vue
+++ b/src/views/delivery/deliveryLog/components/deliveryLogDetail.vue
@@ -1,46 +1,69 @@
-
-
-
-
- 订单名:
- {{orderName ? orderName : '-'}}
-
-
- 发货单号:
- {{code ? code : '-'}}
-
-
-
-
-
-
-
详情
+
+
+
+
+
+ 订单名:
+ {{orderName ? orderName : '-'}}
+
+
+ 发货单号:
+ {{code ? code : '-'}}
+
+
-
-
-
-
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/delivery/deliveryLog/index.vue b/src/views/delivery/deliveryLog/index.vue
index 844f5030..c1eea8d0 100644
--- a/src/views/delivery/deliveryLog/index.vue
+++ b/src/views/delivery/deliveryLog/index.vue
@@ -302,7 +302,7 @@ export default {
successSubmit2() {
this.handleCancel2()
this.getList()
- },
+ }
}
}
\ No newline at end of file
diff --git a/src/views/delivery/deliveryLogDet/components/deliveryLogDetDetail.vue b/src/views/delivery/deliveryLogDet/components/deliveryLogDetDetail.vue
index f26889a9..9d5ff8c4 100644
--- a/src/views/delivery/deliveryLogDet/components/deliveryLogDetDetail.vue
+++ b/src/views/delivery/deliveryLogDet/components/deliveryLogDetDetail.vue
@@ -19,11 +19,11 @@
{{orderMsg.num ? orderMsg.num : '-'}}
-
累积占比(%)
+
累计占比(%)
{{orderMsg.rate ? orderMsg.rate : '-'}}
-
累积运输费用
+
累计运输费用
{{orderMsg.cost ? orderMsg.cost : '-'}}
@@ -305,8 +305,11 @@ export default {
}
},
legend: {
- bottom: '5%',
- left: 'center',
+ type: 'scroll',
+ orient: 'vertical',
+ right: '10%',
+ top: 20,
+ bottom: 20,
icon: 'rect',
itemHeight: 8,
itemWidth: 8
diff --git a/src/views/delivery/deliveryLogDet/index.vue b/src/views/delivery/deliveryLogDet/index.vue
index 7a21fa78..dc02ec0c 100644
--- a/src/views/delivery/deliveryLogDet/index.vue
+++ b/src/views/delivery/deliveryLogDet/index.vue
@@ -61,7 +61,7 @@ const tableProps = [
},
{
prop: 'rate',
- label: '累积发货比例(%)'
+ label: '累计发货比例(%)'
}
]
export default {
diff --git a/src/views/order/base/orderManage/components/addWorkOrder.vue b/src/views/order/base/orderManage/components/addWorkOrder.vue
index b4d3e899..69d9904c 100644
--- a/src/views/order/base/orderManage/components/addWorkOrder.vue
+++ b/src/views/order/base/orderManage/components/addWorkOrder.vue
@@ -25,23 +25,18 @@
-
+
+ {{ item.name }}
+ {{ item.specifications }}
-
-
-
-
-
-
-
+
+
-
-
+
+
-
-
-
+
+
+
-
+
产品基础
工艺扩展
-
-
@@ -114,6 +109,8 @@
+
+
@@ -126,8 +123,6 @@
-
-
@@ -140,6 +135,8 @@
+
+
@@ -170,7 +167,6 @@ export default {
name: '',
code: '',
planProductId: '',
- productSpec: '',
planStartTime: '',
planFinishTime: '',
planAssignQuantity: 0,
@@ -205,14 +201,17 @@ export default {
}
},
methods: {
- init(id, param) {
- this.form.orderId = id
+ init(data, param) {
+ this.form.orderId = data.id
this.getList()
if (param === 'add') {
this.isBind = false
getWorkOrderCode().then(res => {
this.form.code = res.data || ''
})
+ this.form.planProductId = data.planProductId
+ this.form.processFlowId = data.processFlowId
+ this.form.materialMethod = data.materialMethod
}else{//绑定
this.isBind = true
}
@@ -237,18 +236,6 @@ export default {
this.workOrderList = res.data || []
})
},
- // 选产品带出规格
- selectProduct(val) {
- if (val) {
- this.productList.map(item => {
- if (val === item.id) {
- this.form.productSpec = item.specifications
- }
- })
- } else {
- this.form.productSpec = ''
- }
- },
addWorkOrderSubmit() {
this.$refs['addWorkOrder'].validate((valid) => {
if (valid) {
@@ -298,8 +285,6 @@ export default {
if (res.code === 0) {
this.form.code = res.data.code
this.form.planProductId = res.data.planProductId
- this.selectProduct(this.form.planProductId)
- this.form.productSpec = res.data.productSpec
this.planStartTime = res.data.planStartTime ? moment.unix(res.data.planStartTime).format('YYYY-MM-DD HH:mm:ss') : null
this.planFinishTime = res.data.planFinishTime ? moment.unix(res.data.planFinishTime).format('YYYY-MM-DD HH:mm:ss') : null
this.form.planAssignQuantity = res.data.planAssignQuantity
diff --git a/src/views/order/base/orderManage/components/orderAdd.vue b/src/views/order/base/orderManage/components/orderAdd.vue
index 4a5317b5..daf4c18b 100644
--- a/src/views/order/base/orderManage/components/orderAdd.vue
+++ b/src/views/order/base/orderManage/components/orderAdd.vue
@@ -8,7 +8,7 @@
-
+
@@ -20,12 +20,14 @@
-
+
+ {{ item.name }}
+ {{ item.specifications }}
@@ -37,13 +39,6 @@
-
-
-
-
-
-
-
@@ -56,6 +51,8 @@
+
+
@@ -68,8 +65,6 @@
-
-
@@ -82,13 +77,13 @@
+
+
-
-
@@ -101,6 +96,8 @@
+
+
@@ -109,35 +106,33 @@
-
-
-
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
@@ -168,7 +163,6 @@ export default {
planQuantity: '',
planProductId: '',
price: '',
- productSpec: '',
customerId: '',
priority: '',
packSpec: '',
@@ -180,8 +174,6 @@ export default {
planStartTime: '',
planFinishTime: ''
},
- planStartTime: '',
- planFinishTime: '',
rules: {
name: [{ required: true, message: "订单名称不能为空", trigger: "blur" }],
planQuantity: [{ required: true, message: "计划加工数量不能为空", trigger: "blur" }],
@@ -205,16 +197,15 @@ export default {
this.form.code = res.data.code
this.form.planQuantity = res.data.planQuantity
this.form.planProductId = res.data.planProductId
- this.selectProduct(this.form.planProductId)
this.form.price = res.data.price
this.form.customerId = res.data.customerId
this.form.priority = res.data.priority ? res.data.priority + '' : ''
- this.planStartTime = res.data.planStartTime ? moment(res.data.planStartTime).format('YYYY-MM-DD') : null
+ this.form.planStartTime = res.data.planStartTime ? res.data.planStartTime : null
this.form.packSpec = res.data.packSpec ? res.data.packSpec+'' : ''
this.form.workers = res.data.workers
this.form.processFlowId = res.data.processFlowId
this.form.materialMethod = res.data.materialMethod
- this.planFinishTime = res.data.planFinishTime ? moment(res.data.planFinishTime).format('YYYY-MM-DD') : null
+ this.form.planFinishTime = res.data.planFinishTime ? res.data.planFinishTime : null
this.form.remark = res.data.remark
this.form.description = res.data.description
}
@@ -242,24 +233,23 @@ export default {
this.processFlowList = res.data || []
})
},
- // 选产品带出规格
- selectProduct(val) {
- if (val) {
- this.productList.map(item => {
- if (val === item.id) {
- this.form.productSpec = item.specifications
- }
- })
- } else {
- this.form.productSpec = ''
+ timeChange() {
+ if (this.form.planStartTime && this.form.planFinishTime) {
+ if (this.form.planStartTime > this.form.planFinishTime) {
+ this.$modal.msgError('计划开始时间不能大于结束时间')
+ }
}
},
submitForm() {
this.$refs['orderAddForm'].validate((valid) => {
if (valid) {
- this.form.planStartTime = this.planStartTime ? new Date(this.planStartTime).valueOf() : ''
- this.form.planFinishTime = this.planFinishTime ? new Date(this.planFinishTime).valueOf() : ''
- console.log(this.form)
+ if (this.form.planStartTime && this.form.planFinishTime) {
+ if (this.form.planStartTime > this.form.planFinishTime) {
+ this.$modal.msgError('计划开始时间不能大于结束时间')
+ return false
+ }
+ }
+ // console.log(this.form)
if (this.isEdit) {
//编辑
orderUpdate({ ...this.form }).then((res) => {
@@ -288,10 +278,6 @@ export default {
this.form.materialMethod = 1
this.form.price = 0.00
this.form.planQuantity = 0
- this.planFinishTime = ''
- this.planStartTime = ''
- this.form.planFinishTime = ''
- this.form.planStartTime = ''
this.isEdit = false
}
}
diff --git a/src/views/order/base/orderManage/index.vue b/src/views/order/base/orderManage/index.vue
index d8181ad5..ec44b927 100644
--- a/src/views/order/base/orderManage/index.vue
+++ b/src/views/order/base/orderManage/index.vue
@@ -17,7 +17,7 @@
diff --git a/src/views/equipment/analysis/Visualization/SmallTitle.vue b/src/views/equipment/analysis/Visualization/SmallTitle.vue
new file mode 100644
index 00000000..93b4a18f
--- /dev/null
+++ b/src/views/equipment/analysis/Visualization/SmallTitle.vue
@@ -0,0 +1,65 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/equipment/analysis/Visualization/index.vue b/src/views/equipment/analysis/Visualization/index.vue
new file mode 100644
index 00000000..9cf0205c
--- /dev/null
+++ b/src/views/equipment/analysis/Visualization/index.vue
@@ -0,0 +1,514 @@
+
+
+
+
+
+
+ 设备运行状态
+
+
+
+
各设备加工数量
+
+
+
+ 工作时长
+
+
+
+ 停机时长
+
+
+
+ 故障时长
+
+
+
+ 速度开动率
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/equipment/analysis/efficiency/index.vue b/src/views/equipment/analysis/efficiency/index.vue
index 66a1e009..5951a847 100644
--- a/src/views/equipment/analysis/efficiency/index.vue
+++ b/src/views/equipment/analysis/efficiency/index.vue
@@ -13,14 +13,21 @@
ref="search-bar"
@headBtnClick="handleSearchBarBtnClick" />
-
+
+
+
-