From 6d213775d14a63d18d9eb17b44ba14bd3bb220da Mon Sep 17 00:00:00 2001 From: Crunchy <3114200645@qq.com> Date: 星期四, 07 十二月 2023 10:35:53 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- vue.config.js | 6 src/views/technology/routing/routing-form.vue | 20 src/api/product/handymantype.js | 15 src/views/warehouse/pallettransports/ifslocation-form.vue | 82 src/views/plan/manufacturingorder/teststandardtable.vue | 16 src/views/quality/rawMaterial/rawMaterial-print.vue | 748 ++-- src/views/common/ztt-table.vue | 15 src/views/quality/teststandard/standard-form.vue | 332 +- src/views/plan/manufacturingorder/index.vue | 97 src/views/product/workbench/batchproductout-form-new.vue | 79 src/views/technology/operation/index.vue | 28 src/views/quality/package/index.vue | 172 + src/views/quality/teststandard/index.vue | 30 src/views/product/workbench/feed-form.vue | 63 src/views/product/workbench/operation-task-pane.vue | 264 + src/views/plan/customerorder/index.vue | 1 src/views/technology/completeproductstructure/completeproductstructure-form.vue | 22 src/views/warehouse/pallettransports/ifsstock-form.vue | 144 src/views/plan/manufacturingorder/productorder-form.vue | 113 src/views/product/workbench/workReportCard.vue | 24 src/api/quality/Packaging_ledger.js | 74 src/api/quality/rawMaterial.js | 9 src/views/plan/customerorder/customerorder-form.vue | 41 src/views/quality/finishedProductInspection/finishedProduct-form.vue | 28 src/views/technology/operation/operation-form.vue | 8 src/views/product/workbench/index.vue | 44 src/views/product/workbench/productInDialog.vue | 14 src/views/plan/masterproductionschedule/index.vue | 2 src/views/quality/Packaging_ledger/pack-from.vue | 174 + src/views/quality/rawMaterial/QrcodeReader.vue | 77 src/views/warehouse/pallettransports/index.vue | 574 +-- src/api/warehouse/pallettransports.js | 48 src/views/quality/finishedProductInspection/finishedProducter-print.vue | 454 +- src/views/quality/exception/exception.vue | 26 .gitignore | 4 src/views/plan/productionschedul/template-form.vue | 173 + src/views/quality/processconfiguration/index.vue | 2 src/router/views/index.js | 17 src/views/product/workbench/productoutput-table.vue | 13 src/views/quality/finishedProductInspection/index.vue | 35 src/views/technology/routing/edit-routing-operation.vue | 12 src/views/quality/Packaging_ledger/index.vue | 441 +++ src/api/quality/packageInspect.js | 39 src/views/plan/productionschedul/index.vue | 531 +++ src/views/technology/structure/single-structure-form.vue | 8 src/util/fileTransform.js | 20 src/api/plan/productionschedul.js | 24 src/views/common/operation.vue | 6 src/views/technology/routing/index.vue | 12 src/views/quality/processInspect/index.vue | 12 src/views/technology/structure/index.vue | 4 src/views/quality/Packaging_ledger/pack-fromadd.vue | 171 + src/views/admin/productType/index.vue | 9 src/views/quality/packageinspect/packageInspect-form.vue | 602 ++++ src/views/warehouse/pallettransports/detail-ifslocation-form.vue | 42 src/api/product/personboard.js | 61 src/views/quality/processInspect/processInspect-form.vue | 15 src/views/quality/packageinspect/index.vue | 231 + src/views/quality/rawMaterial/rawMaterial-form.vue | 270 + src/views/product/workbench/feed-pane.vue | 118 src/views/basic/workstation/workstation-form.vue | 8 public/title.css | 1256 +++++++++ package.json | 1 src/views/quality/rawMaterial/index.vue | 149 src/views/product/workbench/productoutput-list.vue | 8 src/views/technology/completeproductstructure/index.vue | 177 66 files changed, 6,402 insertions(+), 1,913 deletions(-) diff --git a/.gitignore b/.gitignore index 8142978..d6143ae 100644 --- a/.gitignore +++ b/.gitignore @@ -19,6 +19,7 @@ # Editor directories and files .idea .vscode +.nvmdrc *.suo *.ntvs* *.njsproj @@ -29,6 +30,3 @@ # Lock File package-lock.json yarn.lock - -# config.js -vue.config.js diff --git a/package.json b/package.json index fb282aa..1bd2008 100644 --- a/package.json +++ b/package.json @@ -45,6 +45,7 @@ "vue-json-editor": "^1.2.3", "vue-json-tree-view": "^2.1.4", "vue-qr": "^4.0.9", + "vue-qrcode-reader": "^5.4.1", "vue-quill-editor": "3.0.6", "vue-router": "^3.0.2", "vuedraggable": "^2.24.3", diff --git a/public/title.css b/public/title.css new file mode 100644 index 0000000..98a52ae --- /dev/null +++ b/public/title.css @@ -0,0 +1,1256 @@ +@page { + margin: 10mm 5mm; + margin-bottom: 0; + margin-top:0; +} +.xl6524921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 10.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} +.xl6624921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl6724921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl6824921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl6924921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7024921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl7124921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: top; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl7224921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: top; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl7324921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7424921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 14.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl7524921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 14.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7624921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7724921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7824921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl7924921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl8024921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl8124921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl8224921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl8324921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8424921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8524921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8624921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8724921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8824921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl8924921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl9024921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: none; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9124921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: none; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9224921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: none; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9324921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl9424921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9524921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9624921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9724921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: top; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9824921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: top; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl9924921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: top; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl10024921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl10124921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl10224921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10324921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 700; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: left; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10424921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: none; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10524921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: none; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10624921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10724921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} + +.xl10824921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: none; + border-bottom: none; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl10924921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: .5pt solid windowtext; + border-right: .5pt solid windowtext; + border-bottom: none; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl11024921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: none; + border-bottom: none; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl11124921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: .5pt solid windowtext; + border-bottom: none; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl11224921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: none; + border-bottom: .5pt solid windowtext; + border-left: .5pt solid windowtext; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +.xl11324921 { + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 12.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: center; + vertical-align: middle; + border-top: none; + border-right: .5pt solid windowtext; + border-bottom: .5pt solid windowtext; + border-left: none; + mso-background-source: auto; + mso-pattern: auto; + white-space: normal; +} + +ruby { + ruby-align: left; +} + +rt { + color: windowtext; + font-size: 9.0pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-char-type: none; +} + +.head{ + display: flex; + width: 900pt; + .head-1{ + padding: 40px; + } + .head-2{ + margin-left: auto; + margin-right: 0; + margin-top: 13px; + text-align: right; + } +} +.bodycss{ + margin-left: 85px; +} +.bodycs{ + margin-top: -30px; +} +.bodycs-1{ + display: flex; + text-align: left; + height: 60px; + width: auto; + margin-top: -80px; + + } +.bodycs-2{ + display: flex; + margin-left: 130px; + margin-top: 30px; +} +.bodycs-3{ + display: flex; + margin-left: 140px; +} +.ziti{ + display: flex; + margin-left: 140px; + + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 20pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 瀹嬩綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} +.time{ + display: flex; + margin-left: 80px; + margin-top: 20px; + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 20pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 榛戜綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; + +} +.chilen{ + display: flex; + margin-left: 250px; +} +.cldata{ + display: flex; + margin-left: 130px; +} +.pagefooting{ + font-size:8pt; + font-family:瀹嬩綋; + margin-right: 15pt; + color: deepskyblue; +} +.x1111111{ + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 50pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 榛戜綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} +.x1111112{ + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 20pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 榛戜綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} +.x1111113{ + padding: 0px; + mso-ignore: padding; + color: black; + font-size: 20pt; + font-weight: 400; + font-style: normal; + text-decoration: none; + font-family: 榛戜綋; + mso-generic-font-family: auto; + mso-font-charset: 134; + mso-number-format: General; + text-align: general; + vertical-align: middle; + mso-background-source: auto; + mso-pattern: auto; + white-space: nowrap; +} \ No newline at end of file diff --git a/src/api/plan/productionschedul.js b/src/api/plan/productionschedul.js new file mode 100644 index 0000000..5c56f9a --- /dev/null +++ b/src/api/plan/productionschedul.js @@ -0,0 +1,24 @@ +import request from '@/router/axios' + +export function fetchScheduleList(query) { + return request({ + url: '/mes/productionSchedul/page', + method: 'get', + params: query + }) +} + +export function fetchScheduleById(id) { + return request({ + url: '/mes/productionSchedul/'+id, + method: 'get', + }) +} + +export function fillTime(data) { + return request({ + url: '/mes/productionSchedul/fillTime', + method: 'put', + data: data + }) +} \ No newline at end of file diff --git a/src/api/product/handymantype.js b/src/api/product/handymantype.js index 6f71d44..09b43ea 100644 --- a/src/api/product/handymantype.js +++ b/src/api/product/handymantype.js @@ -119,3 +119,18 @@ params: query }) } + +export function isProductionCounting(query) { + return request({ + url: '/mes/product/isProductionCounting', + method: 'get', + params: query + }) +} + +export function qualifiedLocation(id) { + return request({ + url: '/mes/product/qualifiedLocation/' + id, + method: 'get' + }) +} diff --git a/src/api/product/personboard.js b/src/api/product/personboard.js index d8c1f37..d3b39bd 100644 --- a/src/api/product/personboard.js +++ b/src/api/product/personboard.js @@ -94,6 +94,14 @@ }) } +export function getFeed2(query, workstationId) { + return request({ + url: '/mes/stock/getFeedingStock2/' + workstationId, + method: 'get', + params: query + }) +} + export function getTodoStock(query) { return request({ url: '/mes/stock/getToDealStockByWorkstationId', @@ -129,6 +137,14 @@ export function getOperationTask(query) { return request({ url: '/mes/operationTask/getOperationTask', + method: 'get', + params: query + }) +} + +export function getOperationTaskCopy(query) { + return request({ + url: '/mes/operationTask/getOperationTaskCopy', method: 'get', params: query }) @@ -335,6 +351,15 @@ } // 鎵归噺鎻愪氦 +export function batchChangeCopy(qury, event) { + return request({ + url: '/mes/product/state/batchChangeCopy/' + event, + method: 'post', + data: qury + }) +} + +// 鎵归噺鎻愪氦 export function batchChange2(ids, event) { return request({ url: '/mes/product/state/batchChange/' + event, @@ -510,9 +535,41 @@ }) } -export function getOperationTaskCopy(query) { +export function submitInsPart(obj) { return request({ - url: '/mes/operationTask/getOperationTaskCopy', + url: '/mes/applyPart/submitIns', + method: 'post', + data: obj + }) +} + +export function submitProductMain(obj) { + return request({ + url: '/mes/product/submitProductMain', + method: 'post', + data: obj + }) +} + +export function inputHandle(obj) { + return request({ + url: '/mes/feeding/inputHandle', + method: 'post', + data: obj + }) +} + +export function cancellationOfWorkApplication(query) { + return request({ + url: '/mes/product/cancellationOfWorkApplication', + method: 'get', + params: query + }) +} + +export function generateBackflush(query) { + return request({ + url: '/mes/product/generateBackFlush', method: 'get', params: query }) diff --git a/src/api/quality/Packaging_ledger.js b/src/api/quality/Packaging_ledger.js new file mode 100644 index 0000000..edac84f --- /dev/null +++ b/src/api/quality/Packaging_ledger.js @@ -0,0 +1,74 @@ +import request from '@/router/axios' + +export function pagedata(query) { + return request({ + url: '/mes/qualityPackageBox/page', + method: 'get', + params: query + }) +} + +export function dataadd(query) { + return request({ + url: '/mes/qualityPackageBoxDetail/selProduct', + method: 'get', + params: query + }) +} + +export function list(query) { + return request({ + url: '/mes//qualityPackageBoxDetail/list', + method: 'get', + params: query + }) +} + +export function customerpage(query) { + return request({ + url: '/mes/customer/page', + method: 'get', + params: query + }) +} + +export function pagedataadd(obj) { + return request({ + url: '/mes/qualityPackageBox/add', + method: 'post', + data: obj + }) +} + + +export function saveList(obj) { + return request({ + url: '/mes/qualityPackageBoxDetail/saveList', + method: 'post', + data: obj + }) +} +export function dropById(query) { + return request({ + url: '/mes/qualityPackageBox/dropById', + method: 'get', + params: query + }) +} + + +export function deledata(query) { + return request({ + url: '/mes/qualityPackageBoxDetail/dropById', + method: 'get', + params: query + }) +} + +export function sAuditstatus(obj) { + return request({ + url: '/mes/packageInspect/add', + method: 'post', + data: obj + }) +} \ No newline at end of file diff --git a/src/api/quality/packageInspect.js b/src/api/quality/packageInspect.js new file mode 100644 index 0000000..f9881e6 --- /dev/null +++ b/src/api/quality/packageInspect.js @@ -0,0 +1,39 @@ +import request from '@/router/axios' + +export function fetchList(query) { + return request({ + url: '/mes/packageInspect/page', + method: 'get', + params: query + }) +} + +export function fetchListById(id) { + return request({ + url: '/mes/packageInspect/'+id, + method: 'get', + }) +} + +export function deleteById(id) { + return request({ + url: '/mes/packageInspect/'+id, + method: 'delete', + }) +} + +export function updatePackageInsProduct(data) { + return request({ + url: '/mes/packageInsProduct/updatePackageInsProduct', + method: 'post', + data: data + }) +} +export function updatePackageInspectById(data) { + return request({ + url: '/mes/packageInspect/updatePackageInspectById', + method: 'post', + params: data + }) +} + diff --git a/src/api/quality/rawMaterial.js b/src/api/quality/rawMaterial.js index 27f46f1..abf8b52 100644 --- a/src/api/quality/rawMaterial.js +++ b/src/api/quality/rawMaterial.js @@ -30,6 +30,15 @@ }) } +export function downloadReport(data) { + return request({ + url: '/mes/rawInspect/downloadReport', + method: 'post', + data: data, + responseType: 'blob', + }) +} + export function delObj(data) { return request({ url: '/mes/rawInspect/'+data, diff --git a/src/api/warehouse/pallettransports.js b/src/api/warehouse/pallettransports.js index 79dc4b4..54c4c69 100644 --- a/src/api/warehouse/pallettransports.js +++ b/src/api/warehouse/pallettransports.js @@ -23,6 +23,14 @@ }) } +export function selectAll(data) { + return request({ + url: '/mes/palletTransportsDetail/selectAll', + method: 'get', + params: data + }) +} + export function putPalletTransports(obj) { return request({ url: '/mes/palletTransports', @@ -46,6 +54,30 @@ }) } +export function getPalletTransportsAllDetailDataApi(query) { + return request({ + url: '/mes/palletTransportsMaterial/detail/click', + method: 'get', + params: query + }) +} + +export function palletTransportsMaterialFetchListCopy(query) { + return request({ + url: '/mes/palletTransportsMaterial/page/copy', + method: 'get', + params: query + }) +} + +export function palletTransportsMaterialListClick(query) { + return request({ + url: '/mes/palletTransportsMaterial/page/click', + method: 'get', + params: query + }) +} + export function addPalletTransportsMaterial(obj) { return request({ url: '/mes/palletTransportsMaterial', @@ -56,6 +88,14 @@ export function putPalletTransportsMaterial(obj) { return request({ url: '/mes/palletTransportsMaterial', + method: 'put', + data: obj + }) +} + +export function putPalletTransportsMaterialCopy(obj) { + return request({ + url: '/mes/palletTransportsMaterial/update', method: 'put', data: obj }) @@ -115,6 +155,14 @@ }) } +export function updateBatchPalletTransportsCopy(obj) { + return request({ + url: '/mes/palletTransportsMaterial/updateBatchPalletTransportsCopy', + method: 'put', + data: obj + }) +} + export function updateBatchPalletTransportsDetail(obj) { return request({ url: '/mes/palletTransportsDetail/updateBatch', diff --git a/src/router/views/index.js b/src/router/views/index.js index 7269a62..20e8be7 100644 --- a/src/router/views/index.js +++ b/src/router/views/index.js @@ -145,6 +145,23 @@ ] }, { + path: '/quality/packageinspect', + component: Layout, + children: [ + { + path: 'packageInspect-form', + name: 'packageInspectForm', + component: () => + import(/* webpackChunkName: "views" */ '@/views/quality/packageinspect/packageInspect-form'), + meta: { + keepAlive: false, + isTab: false, + isAuth: false + } + } + ] + }, + { path: '/quality/rawMaterial', component: Layout, children: [ diff --git a/src/util/fileTransform.js b/src/util/fileTransform.js index 832fa2a..6471e85 100644 --- a/src/util/fileTransform.js +++ b/src/util/fileTransform.js @@ -17,3 +17,23 @@ document.body.removeChild(elink) } } + +export function transformZip(response) { + const relType = ['application/zip'] + let type = response.data.type + if (relType.includes(type)) { + const blob = new Blob([response.data], {type: 'application/zip'}) + const disposition = response.headers["content-disposition"] + let temp = disposition.substring(disposition.lastIndexOf('=') + 1) + let filename = decodeURI(temp) + // 鍒涘缓涓�涓秴閾炬帴锛屽皢鏂囦欢娴佽祴杩涘幓锛岀劧鍚庡疄鐜拌繖涓秴閾炬帴鐨勫崟鍑讳簨浠� + const elink = document.createElement('a') + elink.download = filename + elink.style.display = 'none' + elink.href = URL.createObjectURL(blob) + document.body.appendChild(elink) + elink.click() + URL.revokeObjectURL(elink.href) // 閲婃斁URL 瀵硅薄 + document.body.removeChild(elink) + } +} \ No newline at end of file diff --git a/src/views/admin/productType/index.vue b/src/views/admin/productType/index.vue index b23cc54..12120e7 100644 --- a/src/views/admin/productType/index.vue +++ b/src/views/admin/productType/index.vue @@ -54,7 +54,7 @@ <el-dialog :visible.sync="dialogAddVisible" :close-on-click-modal="false" title="鏂板閰嶇疆"> <el-form :model="prodForm" :rules="rules" ref="addDialog"> <el-form-item prop="staffName" label="鐢ㄦ埛鍚嶇О:" label-width="90px"> - <el-select style="width:100%" v-model="prodForm.staffName"> + <el-select style="width:100%" v-model="prodForm.staffName" filterable placeholder="璇烽�夋嫨"> <el-option v-for="(item,index) in staffNamesOptions" :key="index" :value="item.id" :label="item.staffName"/> </el-select> </el-form-item> @@ -70,12 +70,12 @@ </el-dialog> </div> </template> - + <script> import { tableOption } from '@/const/crud/admin/productType' import { getList,addObj,delObj,chooseStaff } from '@/api/admin/productType' import { mapGetters } from 'vuex' - + export default { name: 'TableProduct', data() { @@ -184,7 +184,7 @@ } } </script> - + <style lang="scss" scoped> .el-dialog__wrapper { .el-dialog { @@ -203,4 +203,3 @@ } } </style> - \ No newline at end of file diff --git a/src/views/basic/workstation/workstation-form.vue b/src/views/basic/workstation/workstation-form.vue index 9947e12..2449eea 100644 --- a/src/views/basic/workstation/workstation-form.vue +++ b/src/views/basic/workstation/workstation-form.vue @@ -127,7 +127,7 @@ > </el-transfer> </el-tab-pane> - <el-tab-pane label="浜у嚭寰呮搴撲綅" name="inspection"> + <!-- <el-tab-pane label="浜у嚭寰呮搴撲綅" name="inspection"> <el-transfer filterable v-model="inspectionLocationIds" @@ -137,7 +137,7 @@ @change="handleChangeInspectionLocation" > </el-transfer> - </el-tab-pane> + </el-tab-pane> --> <!-- <el-tab-pane label="浜у嚭涓嶅悎鏍煎簱浣�" name="disqualified"> <el-transfer filterable @@ -160,7 +160,7 @@ > </el-transfer> </el-tab-pane> --> - <el-tab-pane label="妫�楠屽緟澶勭悊搴撲綅" name="pending"> + <!-- <el-tab-pane label="妫�楠屽緟澶勭悊搴撲綅" name="pending"> <el-transfer filterable v-model="pendingLocationIds" @@ -170,7 +170,7 @@ @change="handleChangePendingLocation" > </el-transfer> - </el-tab-pane> + </el-tab-pane> --> <el-tab-pane label="鎴愬搧寰呮搴撲綅" name="product"> <el-transfer filterable diff --git a/src/views/common/operation.vue b/src/views/common/operation.vue index cef559f..6c75fdd 100644 --- a/src/views/common/operation.vue +++ b/src/views/common/operation.vue @@ -94,8 +94,8 @@ isTrue: true, isSearch: true, searchInfoType: 'text' - }, - { + }/*, + { minWidth: '100', prop: 'productionCounting', label: '鏄惁鎶ュ伐', @@ -159,7 +159,7 @@ optList: () => { return this.getChangeList() } - } + } */ ] }, addOrUpdateVisible: false, diff --git a/src/views/common/ztt-table.vue b/src/views/common/ztt-table.vue index 2f5a551..e9cb8d8 100644 --- a/src/views/common/ztt-table.vue +++ b/src/views/common/ztt-table.vue @@ -149,11 +149,7 @@ v-bind="$attrs" v-on="$listeners" :highlight-current-row="true" - :row-key=" - (row) => { - return row.id - } - " + :row-key="rowKey" @row-dblclick="dbClickRow" @row-contextmenu="contextMenu" @header-click="headClick" @@ -563,6 +559,12 @@ name: 'TTable', components: { exSlot, advancedSearchDialog, zttdraggable }, props: { + rowKey: { + type: String, + default: ()=>{ + return 'id' + } + }, // 琛ㄦ牸鍨嬪彿锛歮ini,medium,small tableSize: { type: String, default: 'small' }, // 鏁版嵁璇锋眰鏂规硶 @@ -937,7 +939,8 @@ } }, getDataList(selectedId) { - this.dataListLoading = true + // this.dataListLoading = true + this.dataListLoading = false var criteria = {} criteria.dateTimeFilters = this.dateTimeFilters criteria.multiSearchFilter = this.multiSearchFilter diff --git a/src/views/plan/customerorder/customerorder-form.vue b/src/views/plan/customerorder/customerorder-form.vue index ec8dfc5..f131c55 100644 --- a/src/views/plan/customerorder/customerorder-form.vue +++ b/src/views/plan/customerorder/customerorder-form.vue @@ -209,13 +209,12 @@ <el-input v-model="dataForm.partNo" placeholder="" - disabled > <el-button slot="append" icon="el-icon-search" - @click="openSalesPartDialog()" - v-show="dataForm.id==null" + @click="openPartDialog()" + ></el-button> </el-input> </el-form-item> @@ -1052,7 +1051,7 @@ // } else { // console.log('2') this.dataForm = response.data.data - + // } // this.fileList = response.data.data.customerOrderAttachmentList const sourceId = response.data.data.sourceId @@ -1194,25 +1193,35 @@ } }) }, - // 闆朵欢閫夋嫨 + // 闆朵欢閫夋嫨 openPartDialog() { - if ( - this.dataForm.coState === '01partUnCheck' || - this.dataForm.coState === '02technologyUnCheck' - ) { - this.showPart = true - } else { - this.$message.warning( - '璁㈠崟鍙湁鍦ㄣ�愰浂浠跺緟閫夈�戙�併�愬伐鑹烘枃浠跺緟閫夈�戠姸鎬佷笅锛屾墠鑳借繘琛岄浂浠朵慨鏀�' - ) - } + this.showPart = true }, selectPart(part) { + console.log(part); if (part) { this.dataForm.partNo = part.partNo - this.$refs.dataForm.validateField('partNo', (valid) => {}) } }, + // 闆朵欢閫夋嫨 + // openPartDialog() { + // if ( + // this.dataForm.coState === '01partUnCheck' || + // this.dataForm.coState === '02technologyUnCheck' + // ) { + // this.showPart = true + // } else { + // this.$message.warning( + // '璁㈠崟鍙湁鍦ㄣ�愰浂浠跺緟閫夈�戙�併�愬伐鑹烘枃浠跺緟閫夈�戠姸鎬佷笅锛屾墠鑳借繘琛岄浂浠朵慨鏀�' + // ) + // } + // }, + // selectPart(part) { + // if (part) { + // this.dataForm.partNo = part.partNo + // this.$refs.dataForm.validateField('partNo', (valid) => {}) + // } + // }, // 鍏ㄥ睆 fullscreen() { this.isFullScreen = !this.isFullScreen diff --git a/src/views/plan/customerorder/index.vue b/src/views/plan/customerorder/index.vue index 973dd86..47981a3 100644 --- a/src/views/plan/customerorder/index.vue +++ b/src/views/plan/customerorder/index.vue @@ -93,7 +93,6 @@ > --> </template> </ttable> - <!-- 寮圭獥, 鏃ユ湡閫夋嫨 --> <ConfirmPullCustomerorder v-if="showPullCustomerOrderVisible" diff --git a/src/views/plan/manufacturingorder/index.vue b/src/views/plan/manufacturingorder/index.vue index d1e2b8b..b1bc910 100644 --- a/src/views/plan/manufacturingorder/index.vue +++ b/src/views/plan/manufacturingorder/index.vue @@ -105,12 +105,18 @@ :loading="loadingExcel" >瀵煎嚭 </el-button> + <el-button + @click="labelPrint" + type="primary" + style="margin-left:10px;" + >鏍囩鎵撳嵃 + </el-button> <!-- <el-button v-if="permissions.manufacturingorder_update_orderno" @click="updateOrderNo" type="primary" style="margin-left:10px;" - >鏇存柊璁㈠崟鍙� + >鏇存柊璁㈠崟鍙� </el-button>--> </template> </ttable> @@ -190,6 +196,31 @@ </span> </el-dialog> </basic-container> + <!-- 鏍囩鎵撳嵃 --> + <el-dialog title="鏍囩鍒楄〃" :visible.sync="diaPrintTab" width="500px"> + <div class="dia_body" style="height: 400px;overflow-y: auto;padding: 0 10px;"> + <el-card class="box-card" v-for="(item, i) in qrData" :key="i" style="margin-bottom: 15px;width:100%"> + <el-row> + <el-col :span="10" :offset="3">搴忓彿锛�</el-col> + <el-col :span="10" style="font-weight: bold;">{{ i + 1 }}</el-col> + </el-row> + <el-row> + <el-col :span="10" :offset="3">杞﹂棿璁㈠崟鍙凤細</el-col> + <el-col :span="10" style="font-weight: bold;">{{ item.moNo2 }}</el-col> + </el-row> + <el-row> + <el-col :span="10" :offset="3">璁㈠崟浜岀淮鐮侊細</el-col> + <el-col :span="10"> + <vueQr :text="JSON.stringify(item)" :size="80" :margin="2"></vueQr> + </el-col> + </el-row> + </el-card> + </div> + <span slot="footer" class="dialog-footer"> + <el-button @click="diaPrintTab = false">鍙� 娑�</el-button> + <el-button type="primary" @click="diaPrintTab = false">鎵� 鍗�</el-button> + </span> + </el-dialog> </div> </template> @@ -218,9 +249,14 @@ import DelMatUnIssueVue from './DelMatUnIssue.vue' import { getStore } from '@/util/store.js' import { getObj as getSysParam } from '@/api/admin/sys-public-param' +import vueQr from 'vue-qr' export default { data() { return { + checkList: [], + qrData: [], + orderDatalist:[], + diaPrintTab:false, showCustomerorder: false, paramObj: { customerList: null }, customerOrder: null, @@ -421,6 +457,15 @@ minWidth: '120', prop: 'lengthRequirement', label: '鐩橀暱瑕佹眰', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '120', + prop: 'scrapQty', + label: '鎶ュ簾鏁伴噺', sort: true, isTrue: true, isSearch: true, @@ -823,14 +868,7 @@ } ], toolbar: [], - operator: [ - // { - // text: '鏌ョ湅搴撳瓨', - // type: 'text', - // size: 'small', - // fun: this.searchStock - // } - ], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -902,7 +940,8 @@ AutoOperationtask, IssueMaterialForm, OrderMergeForm, - DelMatUnIssueVue + DelMatUnIssueVue, + vueQr }, created() { this.getManufactureAttrs() @@ -1003,7 +1042,6 @@ } }) }, - computed: { ...mapGetters(['permissions']) }, @@ -1130,6 +1168,7 @@ getByMoIds([this.orderPlan.id]).then((repsonse) => { const resData = repsonse.data.data const resCode = repsonse.data.code + console.log("resData-----",repsonse); if (resCode === 0) { const _that = this for (const key in resData) { @@ -1361,8 +1400,35 @@ } } }, + //鍒濆鍖栦簩缁寸爜鏍囩鏁版嵁 + initQrData(data){ + if(data){ + let index = Number(data.qtyRequired) + Number(data.scrapQty) + if(index>0){ + for(var i=1;i<= index;i++){ + let obj = { + moNo: data.moNo, + moNo2: null, + } + let no = (i+"").padStart(3,'0') + obj.moNo2 = data.moNo + no + this.qrData.push(obj) + } + } + } + }, // table鑷甫浜嬩欢 handleSelectionChange(val) { + let orderData = [] + orderData =val.map( el =>{ + return{ + moNo:el.moNo, + qtyRequired: el.qtyRequired, + scrapQty: el.scrapQty + } + }) + this.orderDatalist = orderData + this.initQrData(orderData[0]) // 鏍规嵁鐘舵�侊紝绂佺敤琛ㄥご鎸夐挳 // 绛涢�夊嚭閫変腑璁板綍鐨勭姸鎬� var stateArr = val.map(function(value, index) { @@ -1654,6 +1720,13 @@ } else { this.$message.error('涓婁紶澶辫触') } + }, + labelPrint(){ + if(this.multipleSelection.length==0){ + this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') + return + } + this.diaPrintTab = true } } } @@ -1662,4 +1735,4 @@ .gantt-info { display: none !important; } -</style> \ No newline at end of file +</style> diff --git a/src/views/plan/manufacturingorder/productorder-form.vue b/src/views/plan/manufacturingorder/productorder-form.vue index ba11120..d4fcf52 100644 --- a/src/views/plan/manufacturingorder/productorder-form.vue +++ b/src/views/plan/manufacturingorder/productorder-form.vue @@ -8,7 +8,7 @@ </div> <div class="btn-group header-right" v-if="editable"> <el-button :disabled="isSubmit" v-thinclick="`dataFormSubmit`" - >淇濆瓨</el-button + type="primary">淇濆瓨</el-button > </div> </div> @@ -126,7 +126,6 @@ </el-form-item> </el-col> </el-row> - <el-row :gutter="10"> <el-col :span="6"> <el-form-item label="澶囨敞" prop="remark"> @@ -151,39 +150,37 @@ </el-select> </el-form-item> </el-col> - <el-col :span="8"> - <el-col - :span="8" - v-if="permissions.plan_manufacturingorder_bom_sure" - > - <el-form-item label="BOM纭"> - <el-switch v-model="dataForm.bomConfirmStatus"> </el-switch> - </el-form-item> - </el-col> - <el-col - :span="8" - v-if="permissions.plan_manufacturingorder_process_sure" - > - <el-form-item label="宸ヨ壓纭"> - <el-switch v-model="dataForm.processConfirmStatus"> - </el-switch> - </el-form-item> - </el-col> - <el-col - :span="8" - v-if="permissions.plan_manufacturingorder_test_sure" - > - <el-form-item label="妫�娴嬫爣鍑嗙‘璁�"> - <el-switch v-model="dataForm.standardConfirmStatus"> - </el-switch> - </el-form-item> - </el-col> + <el-col + :span="2" + v-if="permissions.plan_manufacturingorder_bom_sure" + > + <el-form-item label="BOM纭" label-width="110px"> + <el-switch v-model="dataForm.bomConfirmStatus"> </el-switch> + </el-form-item> </el-col> - <el-col :span="4"> + <el-col + :span="2" + v-if="permissions.plan_manufacturingorder_process_sure" + > + <el-form-item label="宸ヨ壓纭" label-width="110px"> + <el-switch v-model="dataForm.processConfirmStatus"> + </el-switch> + </el-form-item> + </el-col> + <el-col + :span="2" + v-if="permissions.plan_manufacturingorder_test_sure" + > + <el-form-item label="妫�娴嬫爣鍑嗙‘璁�" label-width="140px"> + <el-switch v-model="dataForm.standardConfirmStatus"> + </el-switch> + </el-form-item> + </el-col> + <el-col :span="2"> <el-form-item label="IFS杞﹂棿璁㈠崟鎺ユ敹鏃舵姤鍛婂伐搴�" prop="isReportOperation" - label-width="200px" + label-width="250px" > <el-switch v-model="dataForm.isReportOperation" disabled> </el-switch> @@ -595,8 +592,19 @@ <el-tab-pane label="浜у搧缁撴瀯" id="ta1" key="ta1" name="ta1"> <el-row> - <el-col :span="11"> - <el-form-item label="瀹屾暣BOM"> + <el-col :span="2" style="text-align: center"> + <el-button + type="text" + size="small" + icon="el-icon-circle-plus-outline" + style="color:#f56c6c;" + :disabled="!dataForm.id" + @click="addStruct()" + >娣诲姞鍏冪礌 + </el-button> + </el-col> + <el-col :offset="11" :span="11"> + <!-- <el-form-item label="瀹屾暣BOM"> <el-select @change="bomSelectChanged" disabled @@ -622,18 +630,7 @@ > </el-option> </el-select> - </el-form-item> - </el-col> - <el-col :offset="11" :span="2" style="text-align: center"> - <el-button - type="text" - size="small" - icon="el-icon-circle-plus-outline" - style="color:#f56c6c;" - :disabled="!dataForm.id" - @click="addStruct()" - >娣诲姞鍏冪礌 - </el-button> + </el-form-item> --> </el-col> </el-row> <el-row> @@ -644,7 +641,7 @@ style="width: 100%" height="400px" > - <el-table-column type="selection" width="40" fixed="left" /> + <!-- <el-table-column type="selection" width="40" fixed="left" /> --> <el-table-column type="index" width="50" @@ -662,7 +659,7 @@ /> <el-table-column prop="partName" - width="" + width="200" header-align="center" align="left" label="闆朵欢" @@ -2107,17 +2104,17 @@ }, // 鎵撳紑bom鑺傜偣 addStruct() { - if (this.structSelection.length <= 0) { - this.$message.error('璇烽�夋嫨闇�瑕佹坊鍔犲厓绱犵殑鑺傜偣') - } else { - if (this.structSelection.length === 1) { - this.selectedStruct = this.structSelection[0] - this.moId = this.dataForm.id - this.showStructForm = true - } else { - this.$message.error('鍙兘涓哄崟涓妭鐐规坊鍔犲厓绱�') - } - } + this.selectedStruct = this.structSelection[0] + this.moId = this.dataForm.id + this.showStructForm = true + // if (this.structSelection.length <= 0) { + // this.$message.error('璇烽�夋嫨闇�瑕佹坊鍔犲厓绱犵殑鑺傜偣') + // } else { + // if (this.structSelection.length === 1) { + // } else { + // this.$message.error('鍙兘涓哄崟涓妭鐐规坊鍔犲厓绱�') + // } + // } }, refreshBom(node) { if (this.selectedStruct.children != null) { diff --git a/src/views/plan/manufacturingorder/teststandardtable.vue b/src/views/plan/manufacturingorder/teststandardtable.vue index 0c30093..6e4ad6b 100644 --- a/src/views/plan/manufacturingorder/teststandardtable.vue +++ b/src/views/plan/manufacturingorder/teststandardtable.vue @@ -111,14 +111,14 @@ height="100%" style="width: 100%" > - <el-table-column prop="index" label="搴忓彿" align="center" width="50" /> + <!-- <el-table-column prop="index" label="搴忓彿" align="center" width="50" /> <el-table-column label="绾胯姱" prop="wireCore" align="center" /> <el-table-column prop="isCheck" label="鎶芥" align="center" :formatter="isCheckFormatter" - /> + /> --> <el-table-column label="鍙傛暟缂栧彿" prop="code" align="center" /> <el-table-column label="鍙傛暟椤�" prop="parameterItem" align="center" /> <el-table-column label="妫�娴嬭寖鍥�" prop="referenceValue" align="center"> @@ -162,10 +162,10 @@ ></el-input> </template> </el-table-column> - <el-table-column label="閫氶亾" prop="aisle" align="center" /> - <el-table-column label="閮ㄤ綅" prop="position" align="center" /> + <!-- <el-table-column label="閫氶亾" prop="aisle" align="center" /> + <el-table-column label="閮ㄤ綅" prop="position" align="center" /> --> <el-table-column label="鍗曚綅" prop="unit" align="center" /> - <el-table-column + <!-- <el-table-column prop="extendsRoutingNo" label="缁ф壙宸ヨ壓璺嚎" align="center" @@ -184,7 +184,7 @@ prop="extendsTestStandardParamNo" label="缁ф壙鏍囧噯鍙傛暟" align="center" - /> + /> --> <el-table-column label="鎿嶄綔" align="center" width="118"> <template slot-scope="scope"> <el-button @@ -193,12 +193,12 @@ @click.stop="insertOperationParam(scope.row)" >鎻掑叆 </el-button> - <el-button + <!-- <el-button type="text" size="mini" @click.stop="editTestStandardParam(scope.row)" >鍏紡 - </el-button> + </el-button> --> <el-button type="text" size="mini" diff --git a/src/views/plan/masterproductionschedule/index.vue b/src/views/plan/masterproductionschedule/index.vue index 927b1ff..97410ce 100644 --- a/src/views/plan/masterproductionschedule/index.vue +++ b/src/views/plan/masterproductionschedule/index.vue @@ -626,7 +626,7 @@ operatorConfig: { fixed: 'right', label: '鎿嶄綔', - width: 240, + width: 140, minWidth: 100 } }, diff --git a/src/views/plan/productionschedul/index.vue b/src/views/plan/productionschedul/index.vue new file mode 100644 index 0000000..3a03c19 --- /dev/null +++ b/src/views/plan/productionschedul/index.vue @@ -0,0 +1,531 @@ +<template> + <div class="mod-config"> + <basic-container> + <el-row> + <el-col :span="12"> + <div style="height:80vh;padding: 0px 10px;"> + <avue-crud :data="tableData" ref="crud" :option="option" :span-method="spanMethod" + @refresh-change="getData" + :page="page" + @selection-change="selectionRow" + :table-loading="loading"> + <template #menu="{ row, index }"> + <el-button type="text" icon="el-icon-delete" size="small" @click="deleteHandle(row, index)">鍒犻櫎</el-button> + </template> + </avue-crud> + </div> + </el-col> + <el-col :span="12" style="padding-left: 10px"> + <div style=""> + <el-card> + <div slot="header" class="clearfix"> + <span>璋冨害鏃堕棿绾�</span> + <el-button v-if="scheduleList.length>0" @click="openEditDialog" style="float: right; padding: 3px 0" type="text">缂栬緫</el-button> + </div> + <div style="height:70vh;overflow-y: scroll;"> + <el-timeline> + <el-timeline-item + placement="top" + v-for="(item, index) in scheduleList" + :key="index" + :timestamp="item.title"> + <el-card shadow="hover" :body-style="{margin: '0',padding:'0px 20px 0px 20px'}" style="width:90%;"> + <p> + <span style="font-weight: bold;">璁″垝鏃堕棿: </span> + {{item.planTime}} + </p> + <p> + <span style="font-weight: bold;">瀹為檯鏃堕棿: </span> + {{ item.actualTime }}</p> + </el-card> + </el-timeline-item> + </el-timeline> + </div> + </el-card> + </div> + </el-col> + </el-row> + </basic-container> + <el-dialog + title="缂栬緫鏃堕棿绾�" + :visible.sync="dialogVisible" + top="5vh" + width="50%" + :before-close="handleClose"> + <div style="height:60vh;overflow-y: scroll;"> + <el-timeline> + <el-timeline-item + placement="top" + v-for="(item, index) in scheduleEditList" + :key="index" + :timestamp="item.title"> + <el-card shadow="hover" style="width:90%" :body-style="{padding:'20px 20px 5px 20px'}"> + <el-row> + <el-col :span="3"> + <p style="font-weight: bold;line-height: 50%;">璁″垝鏃堕棿: </p> + </el-col> + <el-col :span="21"> + <el-date-picker + style="width:100%" + v-model="item.planTime" + value-format="yyyy-MM-dd HH:mm:ss" + type="datetime" + placeholder="閫夋嫨鏃ユ湡鏃堕棿"> + </el-date-picker> + </el-col> + </el-row> + <el-row> + <el-col :span="3"> + <p style="font-weight: bold;line-height: 50%;">瀹為檯鏃堕棿: </p> + </el-col> + <el-col :span="21"> + <el-date-picker + style="width:100%" + v-model="item.actualTime" + value-format="yyyy-MM-dd HH:mm:ss" + type="datetime" + placeholder="閫夋嫨鏃ユ湡鏃堕棿"> + </el-date-picker> + </el-col> + </el-row> + </el-card> + </el-timeline-item> + </el-timeline> + </div> + <span slot="footer" class="dialog-footer"> + <el-button @click="dialogVisible = false">鍙� 娑�</el-button> + <el-button type="primary" @click="confirmEditSchedul">纭� 瀹�</el-button> + </span> + </el-dialog> + </div> +</template> + +<script> +import { + fetchScheduleList, + fetchScheduleById, + fillTime +} from '@/api//plan/productionschedul' +import TableForm from './template-form' +import ttable from '@/views/common/ztt-table.vue' +import { mapGetters } from 'vuex' +export default { + data() { + return { + dialogVisible: false, + scheduleList: [], + scheduleEditList: [], + typeOptions: [], + multipleSelection: [], + loading: true, + tableData: [], + page: { + total: 10, + currentPage: 1, + pageSize: 10 + }, + option: { + height: 400, + selection: true, + columnBtn: false, + index: true, + rowKey: 'product', + indexLabel: '搴忓彿', + menuAlign: 'center', + menuWidth: 100, + editBtn: false, + delBtn: false, + addBtn: false, + border: true, + align: 'center', + column: [ + { + minWidth: 120, + prop: 'projectName', + label: '椤圭洰鍚嶇О', + overHidden: true, + }, + { + minWidth: 100, + prop: 'contractNo', + label: '鍚堝悓鍙�', + overHidden: true, + }, + { + minWidth: 120, + prop: 'orderTime', + label: '鎺ュ崟鏃ユ湡', + overHidden: true, + formatter: (row,columnValue)=> this.formatDate(row,columnValue) + }, + { + minWidth: 120, + prop: 'customerName', + label: '瀹㈡埛鍚嶇О', + overHidden: true, + }, + { + minWidth: 120, + prop: 'deliveryDate', + label: '浜よ揣鏃ユ湡', + overHidden: true, + formatter: (row,columnValue)=> this.formatDate(row,columnValue) + }, + { + minWidth: 120, + prop: 'productType', + label: '浜у搧绫诲瀷', + overHidden: true, + }, + { + minWidth: 120, + prop: 'product', + label: '浜у搧鍚�', + overHidden: true, + }, + { + minWidth: 120, + prop: 'specs', + label: '瑙勬牸鍨嬪彿', + overHidden: true, + }, + { + minWidth: 120, + prop: 'unit', + label: '鍗曚綅', + overHidden: true, + }, + { + minWidth: 120, + prop: 'number', + label: '鏁伴噺', + overHidden: true, + }, + { + minWidth: 120, + prop: 'productionStatus', + label: '鐢熶骇鎯呭喌', + overHidden: true, + }, + { + minWidth: 120, + prop: 'productionRoutine', + label: '鐢熶骇绋嬪害', + overHidden: true, + }, + { + minWidth: 120, + prop: 'projectLeader', + label: '椤圭洰璐熻矗浜�', + overHidden: true, + }, + { + minWidth: 150, + prop: 'remark', + label: '澶囨敞', + overHidden: true, + } + ], + }, + spanArr: [{ + prop: 'projectName', + span: [] + }, { + prop: 'contractNo', + span: [] + }, + { + prop: 'orderTime', + span: [] + }, + { + prop: 'customerName', + span: [] + }, + { + prop: 'deliveryDate', + span: [] + }, + { + prop: 'productType', + span: [] + }, + ], + } + }, + components: { + ttable, + TableForm, + }, + computed: { + ...mapGetters(['permissions']), + }, + created(){ + this.loading = true + this.getData() + this.getParamType() + this.rowSort() + this.rowCalc() + }, + beforeUpdate() { + this.rowSort() + this.rowCalc() + }, + watch:{ + + }, + mounted() { + + }, + beforeDestroy() { + }, + methods: { + openEditDialog(){ + this.scheduleEditList = JSON.parse(JSON.stringify(this.scheduleList)) + this.dialogVisible = true + }, + confirmEditSchedul(){ + let data = this.scheduleEditList + let orderObj = this.multipleSelection[0] + console.log("data---",data) + console.log("orderObj-----",orderObj) + let obj = { + "documentActualTime": data[0].actualTime, + "documentPlanTime": data[0].planTime, + "bomActualTime": data[1].actualTime, + "bomPlanTime": data[1].planTime, + "contractActualTime": data[2].actualTime, + "contractPlanTime": data[2].planTime, + "arrivalActualTime": data[3].actualTime, + "arrivalPlanTime": data[3].planTime, + "checkActualTime": data[4].actualTime, + "checkPlanTime": data[4].planTime, + "productActualTime": data[5].actualTime, + "productPlanTime": data[5].planTime, + "id": orderObj.id, + "contractNo": orderObj.contractNo, + "customerName": orderObj.customerName, + "deliveryDate": orderObj.deliveryDate, + "orderTime": orderObj.orderTime, + "productType": orderObj.productType, + "projectName": orderObj.projectName + } + console.log("obj----->>>",obj); + fillTime(obj).then(res=>{ + if(res.status===200){ + this.$message.success("鏇存柊鎴愬姛") + }else{ + this.$message.error("鏇存柊澶辫触") + } + this.getScheduleById(orderObj.id) + this.dialogVisible = false + }).catch(error=>{ + console.log(error); + }) + + }, + handleClose(done){ + done() + }, + initTimeLine(data){ + this.scheduleList = [] + if(data){ + let arr = [ + { + title: '鏂囦欢绛惧彂', + actualTime: data.documentActualTime, + planTime: data.documentPlanTime, + }, + { + title: '涓嬭揪鐗╂枡闇�姹�', + actualTime: data.bomActualTime, + planTime: data.bomPlanTime, + }, + { + title: '閲囪喘璇环+鍚堝悓绛捐', + actualTime: data.contractActualTime, + planTime: data.contractPlanTime, + }, + { + title: '鐗╂枡閲囪喘鍒拌揣', + actualTime: data.arrivalActualTime, + planTime: data.arrivalPlanTime, + }, + { + title: '鐗╂枡鍒拌揣妫�楠�', + actualTime: data.checkActualTime, + planTime: data.checkPlanTime, + }, + { + title: '棰嗘枡銆佽绠卞叆搴�', + actualTime: data.productActualTime, + planTime: data.productPlanTime, + }, + ] + this.scheduleList = arr + } + }, + getScheduleById(id){ + if(id){ + fetchScheduleById(id).then(res=>{ + this.initTimeLine(res.data.data) + }).catch(error=>{ + console.log(error); + }) + } + }, + selectionRow(val){ + if (val.length > 1) { + const preVal = val.shift(); + this.$refs.crud.toggleRowSelection(preVal, false); + } + else{ + this.scheduleList=[] + } + this.multipleSelection = val + this.getScheduleById(val[0].id) + }, + formatDate(row, cellValue){ + if (cellValue) { + const dutyDateList = /\d{4}-\d{1,2}-\d{1,2}/g.exec(cellValue) + if (dutyDateList && dutyDateList.length > 0) { + return dutyDateList[0] + } + } + return '' + }, + // 鑾峰彇鏁版嵁鍒楄〃 + getData() { + this.loading = true + let param = { + size: 20, + current: 1, + } + fetchScheduleList(param).then((res) => { + this.tableData = res.data.data.records + this.page.total = res.data.data.total + this.page.currentPage = res.data.data.records.pages + this.scheduleList = [] + }) + this.loading = false + }, + handleCurrentChange(val) { + this.multipleSelection = val + }, + // 鍒犻櫎 + deleteHandle(row,index) { + this.$confirm('鏄惁纭鍒犻櫎', '鎻愮ず', { + confirmButtonText: '纭畾', + cancelButtonText: '鍙栨秷', + type: 'warning' + }).then(function() { + + }) + }, + //鍔ㄦ�佸悎骞舵柟娉� + rowCalc() { + this.spanArr.forEach((ele, index) => { + let parent + if (index !== 0) parent = this.spanArr[ele.parent || index - 1].span + ele.span = this.rowSpan(ele.prop, parent) + }) + }, + rowSort(list) { + let propList = this.spanArr.map(ele => ele.prop) + this.spanArr.forEach((ele, index) => { + let key = ele.prop + this.tableData = this.tableData.sort((a, b) => { + let flag = true; + for (let i = 0; i < index; i++) { + let prop = this.spanArr[i].prop + flag = flag && a[prop] == b[prop] + } + if (flag) { + if (a[key] < b[key]) { return 1; } + else if (a[key] > b[key]) { return -1; } + return 0; + } + return 0; + }) + }) + }, + rowSpan(key, parent) { + let list = []; + let position = 0; + this.tableData.forEach((item, index) => { + if (index === 0) { + list.push(1) + let position = 0; + } else { + if (this.tableData[index][key] === this.tableData[index - 1][key]) { + if (parent && parent[index] !== 0) { + list.push(1) + position = index + } else { + list[position] += 1; + list.push(0) + } + } else { + list.push(1) + position = index + } + } + }) + return list + }, + spanMethod({ row, column, rowIndex, columnIndex }) { + for (let i = 0; i < this.spanArr.length; i++) { + const ele = this.spanArr[i] + if (column.property == ele.prop) { + const _row = ele.span[rowIndex]; + const _col = _row > 0 ? 1 : 0; + return { + rowspan: _row, + colspan: _col + } + } + } + } + } +} +</script> +<style> +.basic-template-table .el-table__body .el-table__row td:first-child .cell { + padding-left: 0px; + padding-right: 0px; +} + +.basic-template-table .el-table__body .el-table__row:hover { + cursor: move; +} + +.basic-template-table .el-table__body .el-table__row:hover .icon { + display: inline-block; +} + +.basic-template-table .el-table__body .el-table__row .icon { + color: rgba(0, 0, 0, 0.45); + font-size: 12px; + line-height: 18px; + display: none; +} + +.aufontAll { + font-family: aufontAll !important; + font-size: 14px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.h-icon-all-drag { + background: url('/img/tz.png') center center no-repeat; + background-size: cover; + font-size: 14px; +} +.h-icon-all-drag:before { + content: '\E63E'; + font-size: 14px; + visibility: hidden; +} +</style> diff --git a/src/views/plan/productionschedul/template-form.vue b/src/views/plan/productionschedul/template-form.vue new file mode 100644 index 0000000..6d47932 --- /dev/null +++ b/src/views/plan/productionschedul/template-form.vue @@ -0,0 +1,173 @@ +<template> + <el-dialog + v-diadrag + :title="!dataForm.id ? '鏂板' : '淇敼'" + :close-on-click-modal="false" + :visible.sync="visible" + > + <el-form + :model="dataForm" + :rules="dataRule" + ref="dataForm" + label-width="100px" + class="l-mes" + > + <el-form-item label="妯℃澘缂栧彿" prop="templateNo"> + <el-input + v-model="dataForm.templateNo" + placeholder="妯℃澘缂栧彿" + ></el-input> + </el-form-item> + <el-form-item label="妯℃澘鍚嶇О" prop="templateName"> + <el-input + v-model="dataForm.templateName" + placeholder="妯℃澘鍚嶇О" + ></el-input> + </el-form-item> + <el-form-item label="妯℃澘绫诲瀷" prop="templateType"> + <el-select + v-model="dataForm.templateType" + placeholder="妯℃澘绫诲瀷" + filterable + style="width: 100%" + clearable + @change="templateTypeChange" + > + <el-option + v-for="item in templateTypeList" + :key="item.id" + :label="item.templateTypeName" + :value="item.templateTypeName" + /> + </el-select> + </el-form-item> + <el-form-item label="澶囨敞" prop="remark"> + <el-input v-model="dataForm.remark" placeholder="澶囨敞"></el-input> + </el-form-item> + </el-form> + <span slot="footer" class="dialog-footer"> + <el-button @click="visible = false">鍙栨秷</el-button> + <el-button + type="primary" + :disabled="isSubmit" + v-thinclick="`dataFormSubmit`" + >纭畾</el-button + > + </span> + </el-dialog> +</template> + +<script> +import { getObj, addObj, putObj, getTemplateTypes } from '@/api/basic/template' + +export default { + data() { + return { + templateTypeList: [], + visible: false, + dataForm: { + id: 0, + templateName: '', + templateNo: '', + templateType: '', + dataType: '', + remark: '' + }, + dataRule: { + templateName: [ + { required: true, message: '妯℃澘鍚嶇О涓嶈兘涓虹┖', trigger: 'blur' } + ], + templateType: [ + { required: true, message: '妯℃澘绫诲瀷涓嶈兘涓虹┖', trigger: 'blur' } + ] + }, + isSubmit: false + } + }, + methods: { + init(id) { + this.dataForm.id = id || 0 + this.visible = true + this.$nextTick(() => { + this.$refs.dataForm.resetFields() + Promise.all([this.getDict(), this.getDataForm(this.dataForm.id)]).then( + (res) => {} + ) + }) + }, + getDataForm(id) { + return new Promise((resolve, reject) => { + if (id) { + getObj(id) + .then((response) => { + if (response.data.code === 0) { + this.dataForm = response.data.data + resolve() + } else { + this.dataForm = {} + reject() + } + }) + .catch((error) => { + reject(error) + }) + } + }) + }, + getDict() { + return new Promise((resolve, reject) => { + getTemplateTypes() + .then((response) => { + if (response.data.code === 0) { + this.templateTypeList = response.data.data + resolve() + } else { + this.templateTypeList = [] + reject() + } + }) + .catch((error) => { + reject(error) + }) + }) + }, + templateTypeChange() { + const currOperationTemplateType = this.dataForm.templateType + const templateType = this.templateTypeList.find( + (item) => item.templateTypeName === currOperationTemplateType + ) + console.log(templateType) + if (templateType != undefined) { + this.dataForm.dataType = templateType.dataType + } else { + this.dataForm.dataType = '' + } + }, + // 琛ㄥ崟鎻愪氦 + dataFormSubmit() { + this.isSubmit = true + this.$refs.dataForm.validate((valid) => { + if (valid) { + if (this.dataForm.id) { + putObj(this.dataForm).then((data) => { + this.$message.success('淇敼鎴愬姛') + this.visible = false + this.isSubmit = false + this.$emit('refreshDataList') + }) + } else { + addObj(this.dataForm).then((data) => { + this.$message.success('娣诲姞鎴愬姛') + this.visible = false + this.isSubmit = false + this.$emit('refreshDataList') + }) + } + } else { + this.isSubmit = false + } + }) + } + } +} +</script> diff --git a/src/views/product/workbench/batchproductout-form-new.vue b/src/views/product/workbench/batchproductout-form-new.vue index 66bd976..11f7e1a 100644 --- a/src/views/product/workbench/batchproductout-form-new.vue +++ b/src/views/product/workbench/batchproductout-form-new.vue @@ -12,7 +12,7 @@ title="姹囨姤浜у嚭" :visible.sync="innerVisible" append-to-body - @close="$emit('update:currshowlist', false)" + @close="handleClose" :show="currshowlist" :close-on-click-modal="false" class="batch-product-out-form" @@ -57,9 +57,9 @@ ><el-col :span="2" class="batch-product-out-form-header-col" ><span>闆朵欢鍚嶇О</span></el-col > - <el-col :span="4" class="batch-product-out-form-header-col" + <!-- <el-col :span="4" class="batch-product-out-form-header-col" ><span>搴忓垪鍙�</span></el-col - > + > --> <!-- <el-col :span="2" class="batch-product-out-form-header-col" ><span>杞藉叿缂栧彿</span></el-col > @@ -78,9 +78,9 @@ <el-col :span="1" class="batch-product-out-form-header-col" ><span>鍗曚綅</span></el-col > - <el-col :span="2" class="batch-product-out-form-header-col" + <!-- <el-col :span="2" class="batch-product-out-form-header-col" ><span>WDR鍙�</span></el-col - > + > --> <!-- <el-col :span="1" class="batch-product-out-form-header-col" ><span>鍒嗘鎻忚堪</span></el-col > --> @@ -133,11 +133,11 @@ <span class="inline-el-hidden">{{ item.partName }}</span> </el-tooltip> </el-col> - <el-col :span="4" class="batch-product-out-form-body-col l-mes"> + <!-- <el-col :span="4" class="batch-product-out-form-body-col l-mes"> --> <!-- <span>{{ item.outBatchNo }}</span> --> - <el-input v-model="item.outBatchNo"> + <!-- <el-input v-model="item.outBatchNo"> </el-input> - </el-col> + </el-col> --> <!-- <el-col :span="2" class="batch-product-out-form-body-col l-mes"> <el-input v-model="item.reelNumber"></el-input> </el-col> @@ -156,17 +156,22 @@ <el-col :span="1" class="batch-product-out-form-body-col"> <span>{{ item.unit }}</span> </el-col> - <el-col :span="2" class="batch-product-out-form-body-col l-mes"> + <!-- <el-col :span="2" class="batch-product-out-form-body-col l-mes"> <el-input v-model="item.wdr"></el-input> - </el-col> + </el-col> --> <!-- <el-col :span="1" class="batch-product-out-form-body-col l-mes"> <el-input v-model="item.segmentDesc"></el-input> </el-col> --> <el-col :span="2" class="batch-product-out-form-body-col l-mes"> - <el-input v-model="item.outNum"></el-input> + <span v-text="item.outNum"></span> </el-col> <el-col :span="2" class="batch-product-out-form-body-col l-mes"> - <el-input v-model="item.scrapQty"></el-input> + <el-select v-model="item.scrapQty"> + <el-option label="0" value="0"> + </el-option> + <el-option label="1" value="1"> + </el-option> + </el-select> </el-col> <!-- <el-col :span="1" class="batch-product-out-form-body-col l-mes"> <el-input v-model="item.reelWeight"></el-input> @@ -191,7 +196,7 @@ <el-input v-model="item.remark"></el-input> </el-col>--> <el-col :span="2" class="batch-product-out-form-body-col l-mes"> - <el-input v-model="item.mainRemark"></el-input> + <el-input v-model="item.remark"></el-input> </el-col> <el-col :span="1" class="batch-product-out-form-body-col"> <span @@ -359,6 +364,7 @@ data() { return { innerVisible: false, + staffNameList: [], personSelection: [], saveDisabled: false, currDutyInitproducts: [], // 鐢ㄤ簬缂撳瓨椤甸潰涓師鏈夌殑staff浜у嚭璁板綍锛屽苟涓旀槸灞炰簬褰撳墠鐝涓嬬殑锛岀敤浜庡嬀閫変汉鍛樻椂浣滀负鍘熸暟鎹弬鐓� @@ -374,6 +380,36 @@ } }, methods: { + initProductList(){ + let val = this.personSelection + //鎸変汉鍛樻姤宸� + if(this.groupStatus){ + this.products = [] + this.addProductOutForPerson() + }else{ + //鎸夌粍鎶ュ伐 + let nameList = [] + val.forEach(obj=>{ + nameList.push(obj.staffName) + }) + let staffName = Array.from(new Set(nameList)).join(",") + if(staffName!=''){ + this.products = this.productList + this.products.forEach(item=>{ + item.staffName = staffName + item.outNum=1 + }) + }else{ + this.products = [] + } + } + }, + handleClose(){ + this.$emit('update:currshowlist', false) + this.$nextTick(()=>{ + this.$refs.productOutPersonList.clearSelection() + }) + }, isNumber(value) { var reg = /^[0-9]+(.[0-9]{1,4})?$/ if ( @@ -419,6 +455,9 @@ // 鍐嶅幓涓巔roducts(姝や负椤甸潰鐨勫疄鏃舵暟鎹紝鐢ㄦ埛鏈夋敼鍔ㄥ嵆鏇存柊)瀵规瘮锛屽皢鍏朵腑瀛樺湪鐨勭浉鍚屼汉鍛樼殑鐢熶骇鏁伴噺鍜岀敓浜ф壒娆″悓姝ヨ繃鏉ワ紝鑻roducts涓敓浜ф暟閲忔垨鐢熶骇鎵规涓嶅瓨鍦ㄥ�硷紝鍒欎笉杩涜鍚屾锛屾部鐢ㄥ師鏉ョ殑銆� // 鏈�鍚庯紝灏嗙粍瑁呭ソ鐨勯�変腑浜哄憳淇℃伅锛屾洿鏂板埌products(鎸夌収鐝杩涜)锛屾敞鎰忔洿鏂颁箣鍚庨�変腑浜哄憳淇℃伅鍦╬roducts浣嶇疆椤哄簭 this.personSelection = val + if(this.currshowlist){ + this.initProductList() + } }, // 鏍规嵁閫変腑鐨勪汉鍛橈紝鐢熸垚浜哄憳浜у嚭淇℃伅锛屽苟涓旀斁鍦ㄥ彸杈瑰垪琛ㄧ殑鏈�鍓嶉潰 addProductOutForPerson() { @@ -445,7 +484,8 @@ newProduct.partNo = this.parentInfo.partNo newProduct.partName = this.parentInfo.partName newProduct.outBatchNo = oriOutBatchNo - newProduct.productQty = 0 + newProduct.productQty = 1 + newProduct.outNum = 1 newProduct.unit = this.parentInfo.unit newProduct.productStaffs = productStaffs newProduct.productStaffIds = productStaffIds @@ -502,20 +542,21 @@ saveProductOuts2() { this.clickDateArr.push(new Date().getTime()) var productOutputList = [] - this.productList.forEach(a=>{ + this.products.forEach(a=>{ productOutputList.push({ partId: a.partId, productQty: a.outNum, outBatchNo: a.outBatchNo, scrapQty: a.scrapQty, remark: a.remark, - wdr: a.wdr, + wdr: a.wdr, staffNo: a.staffNo, staffName: a.staffName, status: a.status, dutyRecordId: a.dutyRecordId, productStaffIds: a.productStaffIds, - productStaffs: a.productStaffs + productStaffs: a.productStaffs, + sortNo: a.sortNo }) }) var productMains = { @@ -1055,14 +1096,14 @@ this.products.push(this.productList[i]) } this.$nextTick(() => { - this.$refs.productOutPersonList.clearSelection() + this.$refs.productOutPersonList.toggleAllSelection() }) } else { for (let i = 0; i < this.productList.length; i++) { this.products.push(this.productList[i]) } this.$nextTick(() => { - this.$refs.productOutPersonList.clearSelection() + this.$refs.productOutPersonList.toggleAllSelection() }) } } diff --git a/src/views/product/workbench/feed-form.vue b/src/views/product/workbench/feed-form.vue index e895b0a..e2c0374 100644 --- a/src/views/product/workbench/feed-form.vue +++ b/src/views/product/workbench/feed-form.vue @@ -1,6 +1,7 @@ <template> <el-dialog - width="40%" + width="60%" + top="5vh" title="鎶曟枡" :visible.sync="innerVisible" append-to-body @@ -15,24 +16,28 @@ :key="tableKey" :data="dataList" border - style="width: 100%;" + height="400" + style="width: 100%;overflow-y: scroll;" @cell-dblclick="dblhandleCurrentChange" show-summary :span-method="objectSpanMethod" :summary-method="getSummaries" > + <el-table-column header-align="center" align="center" type="index" label="搴忓彿"></el-table-column> <el-table-column prop="partNo" header-align="center" align="center" label="闆朵欢缂栧彿" + show-overflow-tooltip > </el-table-column> <el-table-column - prop="partDescription" + prop="partName" header-align="center" align="center" - label="闆朵欢鎻忚堪" + label="闆朵欢" + show-overflow-tooltip > </el-table-column> <el-table-column @@ -40,6 +45,7 @@ header-align="center" align="center" label="鎵瑰彿" + show-overflow-tooltip > </el-table-column> <!-- <el-table-column @@ -72,7 +78,13 @@ header-align="center" align="center" label="鍗曚綅" + show-overflow-tooltip > + </el-table-column> + <el-table-column prop="menu" label="鎿嶄綔" header-align="center" align="center"> + <template scope="scope"> + <el-button type="text" icon="el-icon-circle-close" @click="cancelFeed(scope.$index,scope.row)">鍙栨秷</el-button> + </template> </el-table-column> </el-table> </div> @@ -142,6 +154,12 @@ password: null } }, + beforeUpdate(){ + this.$nextTick(()=>{ + this.objectSpanMethod() + this.$refs.table.doLayout() + }) + }, directives: { focus: { inserted: function(el, option) { @@ -162,6 +180,10 @@ } }, methods: { + //鎶曞叆鍙栨秷鎸夐挳 + cancelFeed(index,row){ + this.dataList.splice(index,1) + }, confirmData() { if (this.password != null) { checkSubmitPassword({ password: this.password }).then((response) => { @@ -205,13 +227,13 @@ getCheckRawPart(partNoList).then((response) => { if (response.data.code === 0) { // 闇�瑕佸瘑鐮佺‘璁ゆ儏鍐� - if (response.data.data.success === false) { - this.messages = response.data.data.message - this.onnerVisible = true - } else { + //if (response.data.data.success === false) { + // this.messages = response.data.data.message + // this.onnerVisible = true + //} else { // 涓嶉渶瑕佸瘑鐮� 鐩存帴鎶曟枡 this.saveFeed() - } + //} } }) }, @@ -286,16 +308,16 @@ return reg.test(value) }, objectSpanMethod() { - setTimeout(() => { + this.$nextTick(()=>{ if (this.$refs.table.$el) { const current = this.$refs.table.$el .querySelector('.el-table__footer-wrapper') .querySelector('.el-table__footer') const cell = current.rows[0].cells // cell[1].style.display = 'none' - cell[0].colSpan = '4' + cell[0].colSpan = '6' } - }, 50) + }) }, getSummaries(param) { const { columns, data } = param @@ -325,12 +347,19 @@ }, watch: { currshowlist() { - this.innerVisible = this.currshowlist - this.password = null - if (this.currshowlist) { - this.$nextTick(() => {}) + const _than = this + _than.innerVisible = _than.currshowlist + _than.password = null + if (!_than.currshowlist) { + _than.$nextTick(() => { + }) } - } + }, + }, + created(){ + this.$nextTick(()=>{ + this.objectSpanMethod() + }) }, mounted() {} } diff --git a/src/views/product/workbench/feed-pane.vue b/src/views/product/workbench/feed-pane.vue index 7b41bbb..78fb19e 100644 --- a/src/views/product/workbench/feed-pane.vue +++ b/src/views/product/workbench/feed-pane.vue @@ -137,7 +137,7 @@ </el-table-column> </el-table> <el-tabs v-model="activeName"> - <el-tab-pane name="first" label="绾胯竟浠撳悎鏍肩墿鏂�"> + <!-- <el-tab-pane name="first" label="绾胯竟浠撳悎鏍肩墿鏂�"> --> <div class="line-side-warehouse-header"> <div> <el-divider class="pane-divider" direction="vertical"></el-divider @@ -229,16 +229,16 @@ </template> </el-table-column> --> <el-table-column - label="闆朵欢鎻忚堪" - prop="partDescription" + label="闆朵欢" + prop="partName" align="center" show-overflow-tooltip > <template slot="header"> - <div style="line-height: 14px;">闆朵欢鎻忚堪</div> + <div style="line-height: 14px;">闆朵欢</div> <div class="th" @click.stop> <el-input type="text" - v-model="queryParamTwo.partDescription" + v-model="queryParamTwo.partName" @keyup.enter.native="handleStockList" clearable @clear="handleStockList" @@ -247,12 +247,12 @@ </div> </template> <template slot-scope="scope"> - <span>{{ scope.row.partDescription }}</span> + <span>{{ scope.row.partName }}</span> </template> </el-table-column> - <el-table-column label="IFS鎵规鍙�" prop="ifsBatchNo" align="center"> + <el-table-column label="鎵规鍙�" prop="ifsBatchNo" align="center"> <template slot="header"> - <div style="line-height: 14px;">IFS鎵规鍙�</div> + <div style="line-height: 14px;">鎵规鍙�</div> <div class="th" @click.stop> <el-input type="text" @@ -268,7 +268,7 @@ <span>{{ scope.row.ifsBatchNo }}</span> </template> </el-table-column> - <el-table-column label="WDR鍙�" prop="ifsWdr" align="center"> + <!-- <el-table-column label="WDR鍙�" prop="ifsWdr" align="center"> <template slot="header"> <div style="line-height: 14px;">WDR鍙�</div> <div class="th" @click.stop> @@ -285,7 +285,7 @@ <template slot-scope="scope"> <span>{{ scope.row.ifsWdr }}</span> </template> - </el-table-column> + </el-table-column> --> <!-- <el-table-column label="SN鍙�" prop="partBatchNo" align="center"> <template slot="header"> <div style="line-height: 14px;">SN鍙�</div> @@ -375,7 +375,7 @@ > <template slot="header"> <div style="line-height: 14px;">鍙敤鏁伴噺</div> - <!-- <div class="th" @click.stop> + <div class="th" @click.stop> <el-input type="text" v-model="queryParamTwo.availableStockQuantity" @@ -384,7 +384,7 @@ @clear="handleStockList" size="mini" ></el-input> - </div> --> + </div> </template> <template slot-scope="scope"> <span>{{ scope.row.availableStockQuantity }}</span> @@ -393,7 +393,7 @@ <el-table-column label="搴撳瓨鏁伴噺" prop="stockQuantity" align="center"> <template slot="header"> <div style="line-height: 14px;">搴撳瓨鏁伴噺</div> - <!-- <div class="th" @click.stop> + <div class="th" @click.stop> <el-input type="text" v-model="queryParamTwo.stockQuantity" @@ -402,19 +402,19 @@ @clear="handleStockList" size="mini" ></el-input> - </div> --> + </div> </template> <template slot-scope="scope"> <span>{{ scope.row.stockQuantity }}</span> </template> </el-table-column> - <el-table-column + <!-- <el-table-column label="棰勭暀鏁伴噺" prop="reserveQuantity" align="center" > <template slot="header"> - <div style="line-height: 14px;">棰勭暀鏁伴噺</div> + <div style="line-height: 14px;">棰勭暀鏁伴噺</div> --> <!-- <div class="th" @click.stop> <el-input type="text" @@ -425,9 +425,33 @@ size="mini" ></el-input> </div> --> - </template> + <!-- </template> <template slot-scope="scope"> <span>{{ scope.row.reserveQuantity }}</span> + </template> + </el-table-column> --> + <el-table-column label="鏄惁宸ュ簭搴撳瓨" prop="operationStockStatus" align="center"> + <template slot-scope="scope"> + <span v-if="scope.row.operationStockStatus">鏄�</span> + <span v-else>鍚�</span> + </template> + </el-table-column> + <el-table-column label="鎵�灞炲伐搴�" prop="name" align="center"> + <template slot="header"> + <div style="line-height: 14px;">鎵�灞炲伐搴�</div> + <div class="th" @click.stop> + <el-input + type="text" + v-model="queryParamTwo.name" + @keyup.enter.native="handleStockList" + clearable + @clear="handleStockList" + size="mini" + ></el-input> + </div> + </template> + <template slot-scope="scope"> + <span>{{ scope.row.name }}</span> </template> </el-table-column> <el-table-column label="搴撲綅鍙�" prop="locationNo" align="center"> @@ -461,7 +485,7 @@ > </el-pagination> </div> --> - </el-tab-pane> + <!-- </el-tab-pane> --> <!-- <el-tab-pane name="second" label="绾胯竟浠撳緟澶勭悊鐗╂枡"> <div class="line-side-warehouse-header"> <div> @@ -480,7 +504,7 @@ >鎵爜鎶曟枡</el-button > <el-button - class="feeding-btn" + class="feeding-btn"locationNo type="primary" icon="feed-btn-feeding" @click="addFeed()" @@ -1202,7 +1226,7 @@ :show-overflow-tooltip="true" > <template slot="header" slot-scope="scope"> - <div style="line-height: 14px;">闆朵欢鎻忚堪</div> + <div style="line-height: 14px;">闆朵欢</div> <div class="th" @click.stop> <el-input type="text" @@ -1218,9 +1242,9 @@ <span>{{ scope.row.partName }}</span> </template> </el-table-column> - <el-table-column label="IFS鎵规鍙�" prop="ifsBatchNo" align="center"> + <el-table-column label="鎵规鍙�" prop="ifsBatchNo" align="center"> <template slot="header" slot-scope="scope"> - <div style="line-height: 14px;">IFS鎵规鍙�</div> + <div style="line-height: 14px;">鎵规鍙�</div> <div class="th" @click.stop> <el-input type="text" @@ -1236,7 +1260,7 @@ <span>{{ scope.row.ifsBatchNo }}</span> </template> </el-table-column> - <el-table-column label="WDR鍙�" prop="ifsWdr" align="center"> + <!-- <el-table-column label="WDR鍙�" prop="ifsWdr" align="center"> <template slot="header" slot-scope="scope"> <div style="line-height: 14px;">WDR鍙�</div> <div class="th" @click.stop> @@ -1253,7 +1277,7 @@ <template slot-scope="scope"> <span>{{ scope.row.ifsWdr }}</span> </template> - </el-table-column> + </el-table-column> --> <!-- <el-table-column label="SN鍙�" prop="partBatchNo" align="center"> <template slot="header" slot-scope="scope"> <div style="line-height: 14px;">SN鍙�</div> @@ -1358,6 +1382,30 @@ <span>{{ scope.row.stockQuantity }}</span> </template> </el-table-column> + <el-table-column label="鏄惁宸ュ簭搴撳瓨" prop="operationStockStatus" align="center"> + <template slot-scope="scope"> + <span v-if="scope.row.operationStockStatus">鏄�</span> + <span v-else>鍚�</span> + </template> + </el-table-column> + <el-table-column label="鎵�灞炲伐搴�" prop="name" align="center"> + <template slot="header"> + <div style="line-height: 14px;">鎵�灞炲伐搴�</div> + <div class="th" @click.stop> + <el-input + type="text" + v-model="queryParamTwo.name" + @keyup.enter.native="handleStockList" + clearable + @clear="handleStockList" + size="mini" + ></el-input> + </div> + </template> + <template slot-scope="scope"> + <span>{{ scope.row.name }}</span> + </template> + </el-table-column> <el-table-column label="搴撲綅鍙�" prop="ifsLocation" align="center"> <template slot="header" slot-scope="scope"> <div style="line-height: 14px;">搴撲綅鍙�</div> @@ -1373,7 +1421,7 @@ </div> </template> <template slot-scope="scope"> - <span>{{ scope.row.ifsLocation }}</span> + <span>{{ scope.row.locNo }}</span> </template> </el-table-column> <el-table-column label="鍗曚綅" prop="unit" align="center"> @@ -1487,11 +1535,11 @@ </template> <script> -import { getStock, getFeed, getTodoStock, submitInsPart, inputHandle } from '@/api/product/personboard' +import { getStock, getFeed,getFeed2, getTodoStock, submitInsPart, inputHandle } from '@/api/product/personboard' import { getMaterial } from '@/api/plan/operationtask' import { getERPStockListByPart, - fetchList + fetchList, } from '@/api/warehouse/joinstockorder' import feedFormDialog from './feed-form' import returnMaterialFormDialog from './returnmaterial-form' @@ -1814,7 +1862,7 @@ this.paramObject, this.queryParamThree ) - getFeed(query, stationId) + getFeed2(query, stationId) .then((response) => { var data = response.data if (data.code === 0) { @@ -2035,8 +2083,7 @@ getERPStockListByPart({ partNo: part.partNo, partBatchNo: part.partBatchNo - }) - .then((resp) => { + }).then((resp) => { const respCode = resp.data.code const respData = resp.data.data if (respCode === 0) { @@ -2045,8 +2092,7 @@ this.isSubmit = false this.$message.error('搴撳瓨鍒楄〃鏌ヨ澶辫触') } - }) - .catch(() => { + }).catch(() => { this.isSubmit = false console.log('鏌ヨ闆朵欢瀵瑰簲鐨勫簱瀛樺垪琛ㄦ椂锛屽彂鐢熼敊璇�') }) @@ -2178,6 +2224,14 @@ } }, watch: { + showFeedForm:{ + handler(newVal,oldVal){ + if(!newVal){ + this.$refs.stockTable.toggleAllSelection(false) + } + }, + deep: true + }, workstationId() { this.$nextTick(() => { if (this.currItem != null && this.currItem === 'feed') { diff --git a/src/views/product/workbench/index.vue b/src/views/product/workbench/index.vue index fd3b46e..cbb0fa3 100644 --- a/src/views/product/workbench/index.vue +++ b/src/views/product/workbench/index.vue @@ -528,10 +528,11 @@ </el-form-item> </el-form> </div> + <!-- :style="{ backgroundColor: taskStatusColor() }" --> <div class="task-div-content" > <div v-if="!isShowNormalTracking" class="task-list-div" > - <operationTaskPane - ref="operateTaskDiv" :style="{ backgroundColor: taskStatusColor() }" + <operationTaskPane + ref="operateTaskDiv" :workstationId="dutyForm.workstationId" :productSn="operateTaskForm.SN" :orderNumber="operateTaskForm.orderNumber" @@ -544,7 +545,7 @@ </div> <div v-if="isShowNormalTracking" class="task-list-div" > <operationTaskTable - ref="operateTaskTableDiv" :style="{ backgroundColor: taskStatusColor() }" + ref="operateTaskTableDiv" :workstationId="dutyForm.workstationId" :productSn="operateTaskForm.SN" :orderNumber="operateTaskForm.orderNumber" @@ -1438,7 +1439,6 @@ box-sizing: border-box; overflow-y: auto; margin-bottom: 10px; - } .task-list-div { @@ -1673,8 +1673,8 @@ } }, methods: { - changeCurrOperateTask() {}, - refreshWorkReportPageData() {}, + // changeCurrOperateTask() {}, + // refreshWorkReportPageData() {}, refreshOperateTasksByConditions() { this.$nextTick(() => { this.refreshOperateTasks() @@ -2519,23 +2519,25 @@ }, computed: { ...mapGetters(['userInfo', 'tagWel', 'permissions']), +// 鍗婁釜鏈堜箣鍓嶆槸榛勮壊 褰撳ぉ鍜屼笁澶╀箣鍐呭氨鏄孩鑹� 涓夊ぉ涔嬪悗灏辨槸钃濊壊 +// taskStatusColor() { +// return function(date) { +// const now = new Date(); +// const halfMonthAgo = new Date(now - 15 * 24 * 60 * 60 * 1000); +// const threeDaysAgo = new Date(now - 3 * 24 * 60 * 60 * 1000); +// const oneDayAgo = new Date(now - 24 * 60 * 60 * 1000); +// const today = new Date(now); - taskStatusColor() { - return function() { - const now = new Date(); - const threeDaysAgo = new Date(now - 3 * 24 * 60 * 60 * 1000); - const oneDayAgo = new Date(now - 24 * 60 * 60 * 1000); - const today = new Date(now); +// if (halfMonthAgo <= date && date <= threeDaysAgo) { +// return 'yellow'; +// } else if (today <= date && date <= threeDaysAgo) { +// return 'red'; +// } else { +// return 'blue'; +// } +// }; +// } - if (threeDaysAgo <= today && today <= oneDayAgo) { - return 'yellow'; - } else if (today <= threeDaysAgo) { - return 'blue'; - } else { - return 'red'; - } - }; - } }, created() { document.title = '宸ヤ綔鍙扳�斺�擬ES' diff --git a/src/views/product/workbench/operation-task-pane.vue b/src/views/product/workbench/operation-task-pane.vue index badea28..ad56dea 100644 --- a/src/views/product/workbench/operation-task-pane.vue +++ b/src/views/product/workbench/operation-task-pane.vue @@ -1,6 +1,6 @@ <template> <div> - <el-alert + <el-alert v-if="!operationTasks || operationTasks.length == 0" title="杩樻病鏈夊伐鍗曚笅鍙戝埌姝ゆ満鍙帮紒" type="warning" @@ -8,63 +8,88 @@ > </el-alert> <el-card - v-for="(item, index) in operationTasks" - @click.native="setCheckFlag(item)" + @click.native="setCheckFlag(item)" shadow="hover" :key="index" :class="['task-item', item.checkFlag ? 'card-checked' : 'card-unchecked']" - :style="{ backgroundColor: getBackgroundColor(item.planFinishDay) }" -> - <!-- <img class="selectedImg" /> --> - <div class="header" > - <div>宸ュ崟鍙凤細{{ item.taskNo }}</div> - <!-- <div>璁″垝鍙凤細{{ item.mpsNo }}</div> --> - <div - :class="[ - 'status-change-div', - item.checkFlag ? 'card-checked-status' : 'card-status' - ]" - > - <el-select - v-if="permissions.product_operationTask_state" - v-model="item.statusAction" - placeholder="鍔熻兘鑿滃崟" - @change=" - changeTaskState(item.statusAction, item.status, item.id, item) - " - > - <el-option - v-for="ele in statusActions" - :key="ele.value" - :label="ele.label" - :value="ele.value" - :disabled="ele.disabled" - > - </el-option> - </el-select> - </div> - </div> - <div class="body"> - <div class="row"> - <div class="l">闆朵欢鍚嶇О锛�</div> - <div class="r">{{ item.partName }}</div> - </div> - <div class="row"> - <div class="l">闆朵欢鍙凤細</div> - <div class="r">{{ item.partNo }}</div> - </div> - <!-- <div class="row"> - <div class="l">鎴愬搧锛�</div> - <div class="r">{{ item.productName }}</div> - </div> --> - <div class="row"> - <div class="l">璁″垝瀹屾垚鏃堕棿锛�</div> - <div class="r" >{{ item.planFinishDay }}</div> - </div> - </div> -</el-card> +> + <img class="selectedImg" src="/img/workbench/icon_selected.png" /> + <div class="header"> + <div>宸ュ崟鍙凤細{{ item.taskNo }}</div> + <!-- <div class="tag" :style="{ backgroundColor: getTagColor(item.planFinishDay) }"> + {{ getTagText(item.planFinishDay) }} + </div> --> + <el-alert + center + style="width: 80px;height:30px;line-height: 30px;" + :title="getTagText(item.planFinishDay)" + :type="getTagColor(item.planFinishDay)" + effect="dark" + :closable="false"> + </el-alert> + <!-- <div>璁″垝鍙凤細{{ item.mpsNo }}</div> --> + <div + :class="[ + 'status-change-div', + item.checkFlag ? 'card-checked-status' : 'card-status' + ]" + > + <el-select + v-if="permissions.product_operationTask_state" + v-model="item.statusAction" + placeholder="鍔熻兘鑿滃崟" + @change=" + changeTaskState(item.statusAction, item.status, item.id, item) + " + > + <el-option + v-for="ele in statusActions" + :key="ele.value" + :label="ele.label" + :value="ele.value" + :disabled="ele.disabled" + > + </el-option> + </el-select> + </div> + </div> + <div class="body"> + <div class="row"> + <div class="l">闆朵欢鍚嶇О锛�</div> + <div class="r">{{ item.partName }}</div> + </div> + <div class="row"> + <div class="l">闆朵欢鍙凤細</div> + <div class="r">{{ item.partNo }}</div> + </div> + <!-- <div class="row"> + <div class="l">鎴愬搧锛�</div> + <div class="r">{{ item.productName }}</div> + </div> --> + <div class="row"> + <div class="l">璁″垝瀹屾垚鏃堕棿锛�</div> + <div class="r">{{ item.planFinishDay }}</div> + </div> + </div> + + <el-progress + class="task-progress" + :text-inside="true" + :stroke-width="20" + :percentage=" + Number((item.completedQuantity / item.plannedQuantity).toFixed(2)) * + 100 > + 100 + ? 100 + : Number( + (item.completedQuantity / item.plannedQuantity).toFixed(2) + ) * 100 + " + :format="formatPercentage(item.completedQuantity, item.plannedQuantity)" + ></el-progress> + </el-card> </div> </template> <style lang="scss" scoped> @@ -78,42 +103,52 @@ flex-direction: column; align-items: center; } + +.tag{ +width: 80px; +height: 30px; +line-height: 30px; +border-radius:15% ; +text-align: center; +font-size:8px; +color:white; +align-content: 30px; +} + + .task-item { width: 100%; border-radius: 12px; cursor: pointer; position: relative; -background:none; box-shadow: 1px 2px 24px 1px rgba(4, 0, 0, 0.14); - & + .task-item { margin-top: 10px; } - &.card-checked { // color: white; - // background-image: -webkit-linear-gradient( - // 90deg, - // rgba(12, 149, 255, 0.7) 0%, - // rgba(38, 176, 254, 0.8) 34%, - // rgba(12, 149, 255, 0.8) 100% - // ), - // -webkit-linear-gradient(#5a97fa, #5a97fa); - // background-image: -moz-linear-gradient( - // 90deg, - // rgba(12, 149, 255, 0.7) 0%, - // rgba(38, 176, 254, 0.8) 34%, - // rgba(12, 149, 255, 0.8) 100% - // ), - // -moz-linear-gradient(#5a97fa, #5a97fa); - // background-image: linear-gradient( - // 90deg, - // rgba(12, 149, 255, 0.7) 0%, - // rgba(38, 176, 254, 0.8) 34%, - // rgba(12, 149, 255, 0.8) 100% - // ), - // linear-gradient(#5a97fa, #5a97fa); - // background-blend-mode: normal, normal; + background-image: -webkit-linear-gradient( + 90deg, + rgba(12, 149, 255, 0.7) 0%, + rgba(38, 176, 254, 0.8) 34%, + rgba(12, 149, 255, 0.8) 100% + ), + -webkit-linear-gradient(#5a97fa, #5a97fa); + background-image: -moz-linear-gradient( + 90deg, + rgba(12, 149, 255, 0.7) 0%, + rgba(38, 176, 254, 0.8) 34%, + rgba(12, 149, 255, 0.8) 100% + ), + -moz-linear-gradient(#5a97fa, #5a97fa); + background-image: linear-gradient( + 90deg, + rgba(12, 149, 255, 0.7) 0%, + rgba(38, 176, 254, 0.8) 34%, + rgba(12, 149, 255, 0.8) 100% + ), + linear-gradient(#5a97fa, #5a97fa); + background-blend-mode: normal, normal; } .selectedImg { position: absolute; @@ -314,7 +349,7 @@ } }, computed: { - ...mapGetters(['permissions']) + ...mapGetters(['permissions']), }, created() { if (!this.defaultOperationId) { @@ -334,32 +369,57 @@ } }, methods: { - getBackgroundColor(planFinishDay) { - const currentDate = new Date(); - currentDate.setHours(0, 0, 0, 0); // 璁剧疆鏃堕棿涓哄綋澶╃殑寮�濮嬶紝蹇界暐鏃跺垎绉掓绉� - const planFinishDayObj = new Date(planFinishDay); - planFinishDayObj.setHours(0, 0, 0, 0); // 鍚屾牱璁剧疆鏃堕棿涓鸿鍒掑畬鎴愭棩鐨勫紑濮� - if (planFinishDayObj < currentDate) { - // 濡傛灉璁″垝瀹屾垚鏃ュ湪褰撳墠鏃ヤ箣鍓嶏紝杩斿洖'blue'琛ㄧず杩囨湡 - return 'red'; +// getBackgroundColor(planFinishDay) { +// const today = new Date(); +// const planDate = new Date(planFinishDay); +// if (planDate < today) { +// return 'rgba( 255,0,0,1)'; // 瓒呮湡涓虹孩鑹� +// } else { +// const timeDiff = planDate.getTime() - today.getTime(); +// const daysDiff = Math.ceil(timeDiff / (1000 * 3600 * 24)); +// if (daysDiff <= 3) { +// return 'rgba(255,204,62, 1)'; // 涓存湡涓洪粍鑹� +// } else { +// return 'rgba(86,219, 25,1)'; // 姝e父涓虹豢鑹� +// } +// } +// }, + +getTagColor(planFinishDay) { + const today = new Date(); + const planDate = new Date(planFinishDay); + if (planDate < today) { + //return 'rgba( 255,0,0,1)'; // 瓒呮湡涓虹孩鑹� + return 'error'; // 瓒呮湡涓虹孩鑹� + } else { + const timeDiff = planDate.getTime() - today.getTime(); + const daysDiff = Math.ceil(timeDiff / (1000 * 3600 * 24)); + if (daysDiff <= 3) { + //return 'rgba(255,204,62, 1)'; // 涓存湡涓洪粍鑹� + return 'warning'; // 涓存湡涓洪粍鑹� } else { - const timeDifference = currentDate - planFinishDayObj; - const daysDifference = Math.ceil(timeDifference / (1000 * 60 * 60 * 24)); - - if (daysDifference < 0) { - // 濡傛灉璁″垝瀹屾垚鏃ュ湪鏈潵锛岃绠楀畠鏄惁鍦�10澶╁唴 - const daysUntilDue = Math.abs(daysDifference); - if (daysUntilDue <= 10) { - // 濡傛灉鍦�10澶╁唴锛岃繑鍥�'yellow'琛ㄧず鍗冲皢鍒版湡 - return 'yellow'; - } - } + //return 'rgba(86,219, 25,1)'; // 姝e父涓虹豢鑹� + return 'success'; // 姝e父涓虹豢鑹� } - // 濡傛灉涓嶆槸鍗冲皢鍒版湡鎴栧凡杩囨湡锛岃繑鍥�'red'琛ㄧず宸插埌鏈� - return 'blue'; + } }, - + +getTagText(planFinishDay) { + const today = new Date(); + const planDate = new Date(planFinishDay); + if (planDate < today) { + return '瓒呮湡'; + } else { + const timeDiff = planDate.getTime() - today.getTime(); + const daysDiff = Math.ceil(timeDiff / (1000 * 3600 * 24)); + if (daysDiff <= 3) { + return '涓存湡'; + } else { + return '姝e父'; + } + } +}, // 鐐瑰嚮宸ュ崟锛岄�変腑宸ュ崟 setCheckFlag(item) { if (item.checkFlag) { @@ -668,7 +728,7 @@ break } } - console.log(this.operationTasks) + // console.log(this.operationTasks) // 鑻ュ綋鍓嶅伐鍗曞湪宸ュ崟鍒楄〃鏈鎵惧埌涓斿綋鍓嶅伐鍗曠姸鎬佷负宸插畬鎴愭垨宸插彇娑堟椂锛屽垯灏嗗綋鍓嶅伐鍗曢噸缃负绌哄苟鎶涘嚭浜嬩欢锛屽惁鍒欎笉绠� if (isResetCurrOpertionTaskFlag) { getOperationTaskById(taskId).then((res) => { diff --git a/src/views/product/workbench/productInDialog.vue b/src/views/product/workbench/productInDialog.vue index 6c6bf7c..15c4b15 100644 --- a/src/views/product/workbench/productInDialog.vue +++ b/src/views/product/workbench/productInDialog.vue @@ -25,14 +25,14 @@ > </el-table-column> <el-table-column - label="IFS鎵规鍙�" + label="鎵规鍙�" prop="ifsBatchNo" align="center" :show-overflow-tooltip="true" > </el-table-column> - <el-table-column label="闆朵欢鎵瑰彿" prop="partBatchNo" align="center"> - </el-table-column> + <!-- <el-table-column label="闆朵欢鎵瑰彿" prop="partBatchNo" align="center"> + </el-table-column> --> <el-table-column label="瑙勬牸鍨嬪彿" prop="specs" align="center"> </el-table-column> <el-table-column @@ -45,6 +45,14 @@ </el-table-column> <el-table-column label="鍗曚綅" prop="unit" align="center"> </el-table-column> + <el-table-column label="鏄惁宸ュ簭搴撳瓨" prop="operationStockStatus" align="center"> + <template slot-scope="scope"> + <span v-if="scope.row.operationStockStatus">鏄�</span> + <span v-else>鍚�</span> + </template> + </el-table-column> + <el-table-column label="鎵�灞炲伐搴�" prop="name" align="center"> + </el-table-column> </el-table> <div slot="footer" class="dialog-footer"> diff --git a/src/views/product/workbench/productoutput-list.vue b/src/views/product/workbench/productoutput-list.vue index 1cd3a4f..f4b8989 100644 --- a/src/views/product/workbench/productoutput-list.vue +++ b/src/views/product/workbench/productoutput-list.vue @@ -130,7 +130,7 @@ isSearch: true, searchInfoType: 'text' }, - { + /* { minWidth: '100', prop: 'checkStatus', label: '妫�娴嬬姸鎬�', @@ -152,8 +152,8 @@ optList: () => { return this.checkStatusOptions } - }, - { + }, */ + /* { minWidth: '140', prop: 'isQualified', label: '妫�娴嬫槸鍚﹀悎鏍�', @@ -198,7 +198,7 @@ optList: () => { return this.booleanOptions } - }, + }, */ { minWidth: '140', prop: 'remark', diff --git a/src/views/product/workbench/productoutput-table.vue b/src/views/product/workbench/productoutput-table.vue index b722f1f..db8b726 100644 --- a/src/views/product/workbench/productoutput-table.vue +++ b/src/views/product/workbench/productoutput-table.vue @@ -438,6 +438,15 @@ searchInfoType: 'text' }, { + minWidth: '100', + prop: 'scrapQty', + label: '鎶ュ簾鏁伴噺', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { minWidth: '80', prop: 'unit', label: '鍗曚綅', @@ -446,7 +455,7 @@ isSearch: true, searchInfoType: 'text' }, - { + /* { minWidth: '100', prop: 'checkStatus', label: '妫�娴嬬姸鎬�', @@ -537,7 +546,7 @@ optList: () => { return this.booleanOptions } - }, + }, */ { minWidth: '140', prop: 'remark', diff --git a/src/views/product/workbench/workReportCard.vue b/src/views/product/workbench/workReportCard.vue index be4d807..d6c3704 100644 --- a/src/views/product/workbench/workReportCard.vue +++ b/src/views/product/workbench/workReportCard.vue @@ -13,9 +13,9 @@ <div class="product-out-header-left"> <div style="height:28px;line-height:28px;"> <el-divider class="pane-divider" direction="vertical"></el-divider><span - style="font-size:14px;font-weight:bold">浜у嚭</span> + style="font-size:14px;font-weight:bold;">浜у嚭 </span> <el-tooltip effect="dark" content="鍒锋柊鍒楄〃" placement="top"> - <el-button class="step-refresh-btn" icon="el-icon-refresh" type="info" circle + <el-button size="small" class="step-refresh-btn" icon="el-icon-refresh" type="info" circle @click="getBatchReport(5)"></el-button> </el-tooltip> </div> @@ -126,7 +126,7 @@ <!-- <el-button class="tracking-out-revoke-btn" type="primary" icon="tracking-btn-out" :disabled="currProductMainDisable || currentDutyRecord.isConfirm" v-if="!editShow" >浜ょ彮 </el-button> --> - <el-button class="submit-out-btn" type="primary" + <el-button class="submit-out-btn" type="primary" :disabled="currProductMainDisable || currentDutyRecord.isConfirm" v-if="!editShow" @click="submitList()" :loading="submitLoading">鎻愪氦 </el-button> @@ -256,7 +256,7 @@ }}</template> </template> </el-table-column> - <el-table-column label="WDR鍙�" prop="wdr" align="center" width="100"> + <!-- <el-table-column label="WDR鍙�" prop="wdr" align="center" width="100"> <template slot-scope="scope"> <el-input :id="'idReport_' + +scope.$index" :ref="'reference_' + scope.$index" v-if="scope.row.isEdit" v-model="scope.row.wdr" placeholder="WDR鍙�"></el-input> @@ -264,7 +264,7 @@ scope.row.wdr }}</template> </template> - </el-table-column> + </el-table-column> --> <!-- <el-table-column label="鍒嗘鎻忚堪" prop="segmentDesc" align="center"> <template slot-scope="scope"> <el-input @@ -288,8 +288,8 @@ }}</template> </template> </el-table-column> - <el-table-column label="IFS鎵规鍙�" prop="ifsBatchNo" align="center" width="120"> - <!-- <template slot="header" slot-scope="scope"> + <!-- <el-table-column label="IFS鎵规鍙�" prop="ifsBatchNo" align="center" width="120"> + <template slot="header" slot-scope="scope"> <div style="line-height: 14px;">IFS鎵规鍙�</div> <div class="th" @click.stop> <template> @@ -305,8 +305,8 @@ <template v-if="!scope.row.isIfsBatchNoEdit">{{ scope.row.ifsBatchNo }}</template> - </template> --> - </el-table-column> + </template> + </el-table-column> --> <el-table-column label="澶囨敞" prop="remark" align="center"> <template slot-scope="scope"> <el-input :id="'idReport_' + +scope.$index" :ref="'reference_' + scope.$index" v-if="scope.row.isEdit" @@ -3246,7 +3246,7 @@ // 鍒锋柊浜у嚭璁板綍 // this.$emit('refreshProductOutput') } else if (refreshType === 5) { - // 鎻愪氦鎶ュ憡鍚庯紝鍒锋柊 + // 鎻愪氦鎶ュ憡鍚庯紝鍒� // 鍒锋柊宸ュ崟鍒楄〃 this.$emit('refreshOperateTasks') // 鍒锋柊浜у嚭璁板綍 @@ -3270,7 +3270,9 @@ this.options = res.data.data if (this.options.length > 1) { this.dialogVisible = true - } else { + // } else if(this.options.length == 0){ + // this.$message.error('宸ヤ綔绔欐湭缁戝畾鍚堟牸搴撲綅') + } else { this.locationIdValue = this.options[0].id this.submitListApi() } diff --git a/src/views/quality/Packaging_ledger/index.vue b/src/views/quality/Packaging_ledger/index.vue new file mode 100644 index 0000000..b4837ac --- /dev/null +++ b/src/views/quality/Packaging_ledger/index.vue @@ -0,0 +1,441 @@ +<template> + <div class="mod-config"> + <basic-container> + <el-row> + <el-col :span="11"> + <ttable + :table="table" + :isShowHide="true" + :prelang="prelang" + :ajaxFun="ajaxFun" + :options="options" + @handleSelectionChange="handleSelectionChange" + ref="processconfiguration" + > + <template #toolbar></template> + </ttable> + </el-col> + <el-col :span="13" style="padding-left: 10px"> + <el-card> + <div slot="header"> + <el-row> + <el-col :span="8"> + <span>瑁呯鏄庣粏</span> + </el-col> + <el-col :span="8" :offset="4"> + <!-- <el-button + style="float: right; padding: 3px 0" + type="text" + @click="beginItemLayOut" + > + 甯冨眬 + </el-button> --> + </el-col> + <el-col :span="2"> + <el-button + style="float: right; padding: 3px 0" + type="text" + @click="addpreserve" + >淇濆瓨 + </el-button> + </el-col> + <el-col :span="2"> + <el-button + v-if="!isCheck" + style="float: right; padding: 3px 0" + type="text" + @click="relateOperationParam()" + >娣诲姞 + </el-button> + </el-col> + </el-row> + </div> + <el-table + :data="testStandardParams" + id="testStandardParamTable" + ref="testStandardParam" + + highlight-current-row + height="700" + style="width: 100%" + class="l-mes-table" + border + stripe + > + <el-table-column + type ="index" + label="搴忓彿" + align="center" + width="50" + /> + <el-table-column + label="浜у搧" + prop="product" + align="center" + /> + <el-table-column + label="浜у搧缂栧彿" + prop="productNo" + align="center" + > + </el-table-column> + <el-table-column + label="瑙勬牸鍨嬪彿" + prop="specs" + align="center" + > + </el-table-column> + <el-table-column + label="鍗曚綅" + prop="unit" + align="center" + > + </el-table-column> + <el-table-column + label="鏁伴噺" + prop="number" + align="center" + width="80" + > + <template slot-scope="scope"> + <el-input v-model="scope.row.number"></el-input> + </template> + </el-table-column> + <el-table-column + fixed="right" + label="鎿嶄綔" + align="center" + width="80"> + <template slot-scope="scope"> + <el-button @click="deleteadd(scope.row)" size="small">鍒犻櫎</el-button> + </template> + </el-table-column> + </el-table> + </el-card> + </el-col> + </el-row> + + <!-- 鏂板 --> + <packfrom + :currshowlist.sync="addOrUpdateVisible" + @refreshDataList="getData"> + </packfrom> + <packfromadd + :currshowlist.sync="increase" + :packageBoxIddata ="packageBoxId" + @handleSelectionChange = "preserve" + > + </packfromadd> + </basic-container> + <el-dialog title="鏍囩鍒楄〃" top="5vh" :visible.sync="diaPrintTab" width="500px"> + <div id="qrCard" class="dia_body" style="height: 400px;overflow-y: auto;padding: 0 10px;"> + <el-card class="box-card" v-for="(item, i) in qrData" :key="i" style="margin-bottom: 15px;"> + <el-row> + <el-col :span="10" :offset="3">搴忓彿锛�</el-col> + <el-col :span="10" style="font-weight: bold;">{{ i + 1 }}</el-col> + </el-row> + <el-row> + <el-col :span="10" :offset="3">鍖呰缂栧彿锛�</el-col> + <el-col :span="10" style="font-weight: bold;">{{ item.packageNo }}</el-col> + </el-row> + <el-row> + <el-col :span="10" :offset="3">浜岀淮鐮侊細</el-col> + <el-col :span="10"> + <vueQr :text="JSON.stringify(item)" :size="120" :margin="1"></vueQr> + </el-col> + </el-row> + </el-card> + </div> + <span slot="footer" class="dialog-footer"> + <el-button @click="diaPrintTab = false">鍙� 娑�</el-button> + <el-button type="primary" @click="printFun">鎵� 鍗�</el-button> + </span> + </el-dialog> + </div> +</template> + +<script> +import { pagedata,dropById,list,saveList,deledata,sAuditstatus} from '@/api/quality/Packaging_ledger' +import ttable from '@/views/common/ztt-table.vue' +import packfrom from './pack-from.vue' +import packfromadd from './pack-fromadd.vue' +import vueQr from 'vue-qr' +import PrintJS from 'print-js' +export default { + data(){ + return { + qrData:[], + diaPrintTab: false, + multipleSelection: [], + isCheck: false, + dataway:{}, + goid:'', + testStandardParams: [], + packageBoxId:{}, + prelang: 'operation', + dataListLoading: false, + ajaxFun: pagedata, + increase:false, + addOrUpdateVisible:false, + options: { + height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 + stripe: true, // 鏄惁涓烘枒椹汗 table + highlightCurrentRow: false, // 鏄惁瑕侀珮浜綋鍓嶈 + border: true, // 鏄惁鏈夌旱鍚戣竟妗� + lazy: false, // 鏄惁闇�瑕佹噿鍔犺浇 + fit: true, // 鍒楃殑瀹藉害鏄惁鑷拺寮� + multiSelect: true, // + isEdit:false, + seqNo: true, + isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳 + isRefresh: true, // 鏄惁鏄剧ず鍒锋柊鎸夐挳 + isSearch: true, // 楂樼骇鏌ヨ鎸夐挳 + defaultOrderBy: { column: 'createTime', direction: 'desc' } + }, + table: { + total: 0, + currentPage: 1, + pageSize: 20, + data: [], + // 鏍囬 + column: [ + { + minWidth: 'code', + prop: 'state', + label: '鐘舵��', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '140', + prop: 'packageNo', + label: '鍖呰缂栧彿', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + },{ + minWidth: '140', + prop: 'createUser', + label: '鍒涘缓浜�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + },{ + minWidth: '140', + prop: 'contractNo', + label: '鍚堝悓鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'updateUser', + label: '鏇存柊浜�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '130', + width: '150', + prop: 'updateTime', + label: '鏇存柊鏃ユ湡', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'datetimerange', + }, + { + minWidth: '130', + width: '150', + prop: 'createTime', + label: '鍒涘缓鏃ユ湡', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'datetimerange', + }, + ], + toolbar: [ + { + text: '鏂板', + type: 'primary', + fun: this.addOrUpdateHandle + }, + { + text: '鏍囩鎵撳嵃', + type: 'primary', + fun: this.printLabel + }, + ], + operator: [ + { + text: '妫�楠�', + icon: 'el-icon-position', + type: 'text', + size: 'small', + fun: this.check + },{ + text: '鍒犻櫎', + icon: 'el-icon-delete', + type: 'text', + size: 'small', + fun: this.deleteHandle + } + ], + operatorConfig: { + fixed: 'right', + label: '鎿嶄綔', + width: 120, + minWidth: 120 + } + }, + } + }, + components: { + ttable, + packfrom, + packfromadd, + vueQr + }, + watch: { + diaPrintTab(newVal){ + if(!newVal){ + this.qrData = [] + } + } + }, + methods: { + //鎵撳嵃鎸夐挳 + printFun() { + this.diaPrintTab = false; + PrintJS({ + printable: "qrCard", + type: "html", + // header: "鍘熸潗鏂欐娴嬫姤鍛�", + targetStyles: ["*"], + style: `@page {margin: 0mm 5mm;} + html {zoom:100%;} + @media print { + html,body{ + width:60mm; + height:40mm; + } + }`, + ignoreElements: ["no-ignore"], + orientation: 'portrait' + }); + }, + handleSelectionChange(val){ + this.multipleSelection = val + let lastRow = val[val.length - 1] + this.handleCurrentChange(lastRow) + }, + printLabel(){ + if(this.multipleSelection.length==0){ + this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') + return + } + this.diaPrintTab = true + console.log(this.multipleSelection); + this.multipleSelection.forEach(item=>{ + let obj = { + packageNo: item.packageNo, + contractNo: item.contractNo, + boxInfo: [] + } + list({packageBoxId:item.id}).then((res) =>{ + res.data.data.forEach(ele=>{ + obj.boxInfo.push({ + product: ele.product, + productNo: ele.productNo, + specs: ele.specs, + unit: ele.unit, + number: ele.number + }) + }) + }) + this.qrData.push(obj) + }) + }, + // 鑾峰彇鏁版嵁鍒楄〃 + getData() { + this.$refs.processconfiguration.refreshData() + }, + wayRenovate(){ + this.getData() + }, + //add + addOrUpdateHandle(){ + this.addOrUpdateVisible = true + }, + //鍒犻櫎 + deleteHandle(row){ + dropById({id:row.id}).then((res) =>{ + this.getData() + this.$message.success('鍒犻櫎鎴愬姛') + }) + }, + handleCurrentChange(row){ + if(row.state=='宸叉姤妫�'){ + this.isCheck = true + } + this.dataway = row + this.packageBoxId = { + packageBoxId:row.id + } + this.goid = row.id + this.rightquery() + }, + rightquery(){ + list({packageBoxId:this.goid}).then((res) =>{ + this.testStandardParams = res.data.data + }) + }, + //璇︽儏娣诲姞 + relateOperationParam(){ + if (this.dataway.state == "鏈姤妫�") { + this.increase = true + }else{ + this.$message.error('璇峰厛閫夋嫨鍖呰椤圭洰') + } + }, + preserve(datalist){ + this.testStandardParams = datalist + }, + //鍙宠竟淇濆瓨 + addpreserve(){ + this.testStandardParams.forEach(el => { + el.packageBoxId =this.goid + }); + saveList(this.testStandardParams).then((res) =>{ + this.$message.success('淇濆瓨鎴愬姛') + this.rightquery() + }) + }, + //鍒犻櫎 + deleteadd(row){ + deledata({id:row.id}).then((res)=>{ + this.$message.success('鍒犻櫎鎴愬姛') + this.rightquery() + }) + }, + //瀹℃牳 + check(row){ + let packageBox = { + id:row.id, + packageNo:row.packageNo, + contractNo:row.contractNo, + customerId:row.customerId, + } + sAuditstatus(packageBox).then((res) =>{ + this.getData() + this.$message.success('妫�楠屾垚鍔�') + }) + }, + }, +} +</script> \ No newline at end of file diff --git a/src/views/quality/Packaging_ledger/pack-from.vue b/src/views/quality/Packaging_ledger/pack-from.vue new file mode 100644 index 0000000..7398799 --- /dev/null +++ b/src/views/quality/Packaging_ledger/pack-from.vue @@ -0,0 +1,174 @@ +<template> + <el-dialog + width="60%" + title="鏂板" + top="5vh" + :visible.sync="innerVisible" + :show="currshowlist" + @close="$emit('update:currshowlist', false)" + append-to-body + class="part-dialog" + > + <ttable + :table="table" + @currentChange="Getdata" + :prelang="prelang" + :options="options" + :ajaxFun="ajaxFun" + :bottomOffset="350" + ref="paramTable" + > + <template #toolbar></template> + </ttable> + <div slot="footer" class="dialog-footer"> + <el-button @click="innerVisible = false">鍙� 娑�</el-button> + <el-button type="primary" @click="saveSelectRow">纭� 瀹�</el-button> + </div> + </el-dialog> + </template> + <script> +import { customerpage,pagedataadd } from '@/api/quality/Packaging_ledger' +import ttable from '@/views/common/ztt-table.vue' + export default { + props:{ + currshowlist: { + type: Boolean, + default: false + }, + }, + data() { + return { + datalistid:{}, + ajaxFun: customerpage, + currentRow: false, + typeOptions: [], + innerVisible: false, + listLoading: true, + multipleSelection: [], + isShowQuery: false, + uploadInfo: { + // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl + isShow: false, + url: '' + }, + prelang: 'operation', + options: { + height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 + stripe: true, // 鏄惁涓烘枒椹汗 table + highlightCurrentRow: false, // 鏄惁瑕侀珮浜綋鍓嶈 + border: true, // 鏄惁鏈夌旱鍚戣竟妗� + lazy: false, // 鏄惁闇�瑕佹噿鍔犺浇 + fit: true, // 鍒楃殑瀹藉害鏄惁鑷拺寮� + multiSelect: false, // + isEdit:false, + seqNo: true, + isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳 + isSearch: true, // 楂樼骇鏌ヨ鎸夐挳 + defaultOrderBy: { column: 'createTime', direction: 'desc' } + }, + table: { + total: 0, + currentPage: 1, + pageSize: 20, + data: [], + // 鏍囬 + column: [ + { + minWidth: 'code', + prop: 'contractNo', + label: '鍚堝悓鍙�', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '120', + prop: 'customerName', + label: '瀹㈡埛鍚嶇О', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '140', + prop: 'customerNo', + label: '瀹㈡埛缂栫爜', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '120', + prop: 'deliveryDate', + label: '浜よ揣鏃ユ湡', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'datetimerange' + }, + { + minWidth: '120', + prop: 'entityName', + label: '宸ョ▼鍚嶇О', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + ], + }, + addOrUpdateVisible: false + } + }, + components: { + ttable + }, + watch: { + currshowlist() { + console.log(22211); + this.innerVisible = this.currshowlist + if (this.currshowlist) { + this.$nextTick(() => { + this.getData() + }) + } + } + }, + computed: { + // ...mapGetters(['permissions']) + }, + created() { + this.getParamType() + }, + methods: { + // 鑾峰彇鏁版嵁鍒楄〃 + // getData() { + // this.$refs.paramTable.getDataList() + // }, + Getdata(val){ + console.log(val); + this.datalistid = val + }, + saveSelectRow() { + let packageBox = { + customerId:this.datalistid.id, + contractNo:this.datalistid.contractNo + } + pagedataadd (packageBox).then((res =>{ + if (res.status === 200) { + this.$message.success('鏂板鎴愬姛') + this.$emit('refreshDataList') + }else{ + this.$message.error('鍒涘缓澶辫触') + } + })) + this.innerVisible = false + this.$emit('wayapi',this.innerVisible ) + }, + } + } + </script> + \ No newline at end of file diff --git a/src/views/quality/Packaging_ledger/pack-fromadd.vue b/src/views/quality/Packaging_ledger/pack-fromadd.vue new file mode 100644 index 0000000..71b7eb5 --- /dev/null +++ b/src/views/quality/Packaging_ledger/pack-fromadd.vue @@ -0,0 +1,171 @@ +<template> + <el-dialog + width="60%" + title="鍙傛暟" + top="5vh" + :visible.sync="innerVisible" + :show="currshowlist" + @close="$emit('update:currshowlist', false)" + append-to-body + class="part-dialog" + > + <ttable + :table="table" + @handleSelectionChange="handleSelectionChange" + :prelang="prelang" + :options="options" + :ajaxFun="ajaxFun" + :paramObj="packageBoxIddata" + :bottomOffset="350" + ref="paramTable" + > + <template #toolbar></template> + </ttable> + <div slot="footer" class="dialog-footer"> + <el-button @click="innerVisible = false">鍙� 娑�</el-button> + <el-button type="primary" @click="saveSelectRow">纭� 瀹�</el-button> + </div> + </el-dialog> + </template> + <script> +import { dataadd,saveList } from '@/api/quality/Packaging_ledger' +import ttable from '@/views/common/ztt-table.vue' + export default { + props:{ + currshowlist: { + type: Boolean, + default: false + }, + packageBoxIddata:{ + type: Object + }, + }, + data() { + return { + datalist:[], + datalistid:"", + ajaxFun: dataadd, + currentRow: false, + typeOptions: [], + innerVisible: false, + listLoading: true, + multipleSelection: [], + isShowQuery: false, + uploadInfo: { + // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl + isShow: false, + url: '' + }, + prelang: 'operation', + options: { + height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 + stripe: true, // 鏄惁涓烘枒椹汗 table + highlightCurrentRow: false, // 鏄惁瑕侀珮浜綋鍓嶈 + border: true, // 鏄惁鏈夌旱鍚戣竟妗� + lazy: false, // 鏄惁闇�瑕佹噿鍔犺浇 + fit: true, // 鍒楃殑瀹藉害鏄惁鑷拺寮� + multiSelect: true, // + seqNo: true, + isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳 + isSearch: true, // 楂樼骇鏌ヨ鎸夐挳 + defaultOrderBy: { column: 'createTime', direction: 'desc' } + }, + table: { + total: 0, + currentPage: 1, + pageSize: 20, + data: [], + // 鏍囬 + column: [ + { + minWidth: 'code', + prop: 'product', + label: '浜у搧', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '120', + prop: 'productNo', + label: '浜у搧缂栧彿', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '140', + prop: 'specs', + label: '瑙勬牸鍨嬪彿', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '120', + prop: 'unit', + label: '鍗曚綅', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'datetimerange' + }, + ], + }, + addOrUpdateVisible: false + } + }, + components: { + ttable + }, + watch: { + currshowlist() { + console.log(22211); + this.innerVisible = this.currshowlist + } + }, + computed: { + // ...mapGetters(['permissions']) + }, + created() { + this.getParamType() + }, + methods: { + // 鑾峰彇鏁版嵁鍒楄〃 + getData() { + this.$refs.paramTable.getDataList() + }, + handleSelectionChange(val){ + let data = val + data.forEach(el => { + this.datalistid = el + }); + }, + saveSelectRow() { + console.log(this.packageBoxIddata,"123"); + // saveList ({customerId:this.datalistid.id,contractNo:this.datalistid.contractNo}).then((res =>{ + // console.log(res); + // if (res.status === 200) { + // this.$message.success('鏂板鎴愬姛') + // }else{ + // this.$message.error('鍒涘缓澶辫触') + // } + // })) + this.innerVisible = false + // this.$emit('handleSelectionChange',this.innerVisible ) + }, + handleSelectionChange(val){ + this.datalist = val + console.log(this.datalist,"鏁版嵁"); + }, + saveSelectRow(){ + this.$emit('handleSelectionChange',this.datalist ) + this.innerVisible = false + } + } + } + </script> + \ No newline at end of file diff --git a/src/views/quality/exception/exception.vue b/src/views/quality/exception/exception.vue index 1179697..0c49eae 100644 --- a/src/views/quality/exception/exception.vue +++ b/src/views/quality/exception/exception.vue @@ -31,8 +31,8 @@ action="/mes/exception/upload" :headers="headers" :before-upload="submitUpload" - :on-preview="handlePreview" :on-remove="handleRemove" + :on-preview="handlePreview" :on-success="uploadSuccess" :data="paramData" :file-list="fileList" @@ -41,7 +41,7 @@ > <el-button size="small" type="primary">鐐瑰嚮涓婁紶</el-button> <div slot="tip" class="el-upload__tip"> - 鍙兘涓婁紶jpg鍥剧墖锛屼笖涓嶈秴杩�2MB + 鍙兘涓婁紶jpg/png鍥剧墖锛屼笖涓嶈秴杩�5MB </div> </el-upload> </el-col> @@ -53,6 +53,9 @@ @refreshDataList="getData" ></table-form> </div> + <el-dialog title="鍥剧墖棰勮" width="60%" :visible.sync="previewVisible" top="5vh"> + <img style="width:100%;height: 70vh" :src="dialogImageUrl" alt=""> + </el-dialog> </div> </template> <style lang="scss" scoped> @@ -111,6 +114,8 @@ }, data() { return { + previewVisible: false, + dialogImageUrl: null, fileList: [], headers: { Authorization: 'Bearer ' + getStore({ name: 'access_token' }) @@ -293,7 +298,7 @@ } }, handlePreview(file) { - window.open(file.url) + this.previewVisible = true }, uploadSuccess(response, file, fileList) { this.getFileList() @@ -312,6 +317,7 @@ fileEl = {} fileEl.name = attachment.original fileEl.url = attachment.url + this.dialogImageUrl = attachment.url fileEl.id = attachment.id fileEl.fileName = attachment.fileName this.fileList.push(fileEl) @@ -320,10 +326,22 @@ }) } }, - submitUpload() { + submitUpload(file) { console.info(this.currentRow && this.currentRow.id) + console.log(file); if (this.currentRow && this.currentRow.id) { + const maxSize = 5 * 1024 *1024 + let jpgType = 'image/jpeg' + let pngType = 'image/png' + if(file.type != jpgType && file.type != pngType){ + this.$message.error('鍙兘涓婁紶.jpg/.png绫诲瀷鐨勫浘鐗�') + return false + } + if(file.szie > maxSize){ + this.$message.error('鍥剧墖澶у皬涓嶈兘瓒呰繃5MB') + } this.paramData.exceptionId = this.currentRow.id + } else { this.$message.error('璇峰厛閫夋嫨鐢熶骇寮傚父璁板綍') return false diff --git a/src/views/quality/finishedProductInspection/finishedProduct-form.vue b/src/views/quality/finishedProductInspection/finishedProduct-form.vue index a09ed00..320ecd9 100644 --- a/src/views/quality/finishedProductInspection/finishedProduct-form.vue +++ b/src/views/quality/finishedProductInspection/finishedProduct-form.vue @@ -14,9 +14,15 @@ <div class="page-main"> <div class="finishedProduct-basic"> <el-form :model="processInspectVo" ref="addInspectionform" class="l-mes" - label-position="right" label-width="120px" style="width: 100%" size="small"> + label-position="right" label-width="120px" style="width: 100%" size="small"> <div class="formwrapper"> <el-row> + <el-col :span="6"> + <el-form-item label="浜у搧妫�楠岀紪鍙凤細"> + <el-input @blur="selectInfoByOrderId" disabled + v-model="processInspectVo.finInsNo" autocomplete="off" /> + </el-form-item> + </el-col> <el-col :span="6"> <el-form-item label="璁㈠崟鍙凤細"> <el-input @blur="selectInfoByOrderId" :disabled="processInspectVo.id != null" @@ -35,6 +41,8 @@ placeholder="璇疯緭鍏ュ伐绋嬪悕绉�" autocomplete="off" /> </el-form-item> </el-col> + </el-row> + <el-row> <el-col :span="6"> <el-form-item label="浜у搧鍚嶇О锛�"> <el-select style="width: 100%" @change="changeOptionsSamplename" :disabled="processInspectVo.id != null" @@ -45,8 +53,6 @@ </el-select> </el-form-item> </el-col> - </el-row> - <el-row> <el-col :span="6"> <el-form-item label="浜у搧缂栫爜锛�"> <el-input disabled v-model="processInspectVo.mcode" @@ -65,6 +71,8 @@ placeholder="璇疯緭鍏ュ崟浣�" autocomplete="off" /> </el-form-item> </el-col> + </el-row> + <el-row> <el-col :span="6"> <el-form-item label="鏁伴噺锛�"> <el-input v-model="processInspectVo.quantity" placeholder="璇疯緭鍏ユ暟閲�" @@ -241,6 +249,7 @@ empiricalValueAddMaxNumber: 0, processInspectVo: { id: null, + finInsNo: null, material: null, mcode: null, prname: null, @@ -250,7 +259,8 @@ quantity: null, specificationsModel: null, unit: null, - technologyId: null + technologyId: null, + documentId: null }, inspectionItems: [], // 鏂板妫�楠岄」鐩〃鏍� inspectionResultForm: [], @@ -339,6 +349,7 @@ if(id != null){ queryById(id).then(res=>{ let result = res.data.data + this.processInspectVo.finInsNo = result.finInsNo this.processInspectVo.orderNumber = result.orderNumber this.processInspectVo.mcode = result.materialCode this.processInspectVo.prname = result.customerName @@ -347,6 +358,7 @@ this.processInspectVo.specificationsModel = result.specs this.processInspectVo.unit = result.punit this.processInspectVo.quantity = result.quantity + this.processInspectVo.documentId = result.documentId let userList = [] result.children.forEach(item=>{ item.iid = Math.random() @@ -424,6 +436,7 @@ this.processInspectVo.material = sample.material this.processInspectVo.specificationsModel = sample.specs this.processInspectVo.unit = sample.unit + this.processInspectVo.documentId = sample.documentId }, changeState(row, index) { if (row.iid != null && row.iid != '') { @@ -454,6 +467,7 @@ addTestProject() { let val = this.processInspectVo let data = { + finInsNo: val.finInsNo, customerName: val.prname, material: val.material, materialCode: val.mcode, @@ -462,6 +476,7 @@ quantity: val.quantity, specs: val.specificationsModel, unit: val.unit, + documentId: val.documentId } addFinish(data).then(res=>{ let id = res.data.data @@ -506,6 +521,7 @@ this.processInspectVo.material = null this.processInspectVo.specificationsModel = null this.processInspectVo.unit = null + this.processInspectVo.documentId = null } }) }, @@ -542,7 +558,7 @@ flex-wrap: wrap; } -.finishedProduct-result { +basic.finishedProduct-result { width: 100%; height: 150px; padding: 10px 20px; @@ -556,7 +572,7 @@ .finishedProduct-basic { background-color: #fff; - height: 120px; + height: 155px; display: flex; flex-wrap: wrap; padding: 10px 20px; diff --git a/src/views/quality/finishedProductInspection/finishedProducter-print.vue b/src/views/quality/finishedProductInspection/finishedProducter-print.vue index df1bb35..173dbf1 100644 --- a/src/views/quality/finishedProductInspection/finishedProducter-print.vue +++ b/src/views/quality/finishedProductInspection/finishedProducter-print.vue @@ -1,157 +1,159 @@ <template> - <div id="20230721_24921" align=center x:publishsource="Excel" style="margin-top: 65pt;margin-left: 15pt;"> - <table border=0 cellpadding=0 cellspacing=0 width=1194 style='border-collapse:collapse;table-layout:fixed;width:629pt;page-break-after: always;'> - <tr class=xl6524921 height=20 style='mso-height-source:userset;height:30.0pt'> - <td colspan=3 rowspan=2 height=40 width=122 style='width:150pt;border: 1pt solid windowtext'> - <span style='mso-ignore:vglayout;margin-left:12px;margin-top:14px;width:104px;height:42px'> - <img width=174 height=58 src="../../../../public/img/image001.jpg"> - </span> +<div class="WordSection1" align=center style="word-wrap:break-word;text-justify-trim:punctuation"> + <div align="center" > + <table style="border-collapse:collapse;table-layout:fixed;page-break-after: always;margin-top: 0px;" width="629"> + <tr class="xl6524921" height=20 style='mso-height-source:userset;height:30.0pt'> + <td colspan=3 rowspan=2 style='width:160pt;height: 60pt;border: 1pt solid windowtext'> + <span style='mso-ignore:vglayout;margin-left:12px;margin-top:14px;width:104px;height:42px'> + <img width=174 height=58 src="../../../../public/img/image001.jpg"> + </span> + </td> + <td colspan=6 class="xl6624921" style='border-right:.5pt solid black;border-left:none;width:380pt;height: 60pt'>璁板綍鍚嶇О:杩炴帴鍣ㄥ強鎴愬搧妫�楠岃褰曡〃</td> + <td colspan=3 class="xl6624921" style='border-left:none;width: 160pt;height: 60pt'>淇濆瓨鏈熼檺:25骞�</td> + <td rowspan=2 colspan=3 class="xl6824921" style='width:136pt;height: 60pt' >鐗堟湰鍙�: A/0</td> + </tr> + <tr class="xl6524921" height=33 style='mso-height-source:userset;height:25.05pt'> + <td colspan=6 height=33 class=xl6624921 style='border-right:.5pt solid black;height:25.05pt;border-left:none'> + 璁板綍缂栧彿:{{ tableData.finInsNo }} + </td> + <td colspan=3 class=xl6624921 style='border-top:none;border-left:none'> + 褰掓。閮ㄩ棬:璐ㄩ噺淇濊瘉閮� + </td> + <td colspan=2 class=xl6824921 style='border-top:none'></td> + </tr> + <tr class="xl6524921" style='mso-height-source:userset;height:25.05pt'> + <td colspan=16 class=xl7424921 width=1194 style='height:25.05pt; width:897pt'> + 杩炴帴鍣ㄥ強鎴愬搧妫�楠岃褰曡〃 + </td> + </tr> + <tr class="xl6524921" style='mso-height-source:userset;height:40.05pt'> + <td colspan=2 class="xl7624921" style='border-right:.5pt solid black; height:40.05pt'> + 椤圭洰鍚嶇О: + </td> + <td colspan=5 class="xl6624921" style='border-right:.5pt solid black; border-left:none'>銆� + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="deviceStr"></span> + </p> </td> - <td colspan=6 class=xl6624921 width=399 style='border-right:.5pt solid black;border-left:none;width:250pt'>璁板綍鍚嶇О:杩炴帴鍣ㄥ強鎴愬搧妫�楠岃褰曡〃</td> - <td colspan=3 class=xl6624921 width=226 style='border-left:none;width: 150pt'>淇濆瓨鏈熼檺:25骞�</td> - <td rowspan=2 colspan=3 class=xl6824921 width=235 style='width:126pt' >鐗堟湰鍙�: A/0</td> - </tr> - <tr class=xl6524921 height=33 style='mso-height-source:userset;height:25.05pt'> - <td colspan=6 height=33 class=xl6624921 style='border-right:.5pt solid black;height:25.05pt;border-left:none'> - 璁板綍缂栧彿:ZTT/QR-8.6-05锛圓/0) - </td> - <td colspan=3 class=xl6624921 style='border-top:none;border-left:none'> - 褰掓。閮ㄩ棬:璐ㄩ噺淇濊瘉閮� - </td> - <td colspan=2 class=xl6824921 style='border-top:none'></td> - </tr> - <tr class=xl6524921 height=33 style='mso-height-source:userset;height:25.05pt'> - <td colspan=16 height=33 class=xl7424921 width=1194 style='height:25.05pt; width:897pt'> - 杩炴帴鍣ㄥ強鎴愬搧妫�楠岃褰曡〃 - </td> - </tr> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td colspan=2 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> - 椤圭洰鍚嶇О: - </td> - <td colspan=5 class=xl6624921 style='border-right:.5pt solid black; border-left:none'>銆� + <td colspan=2 class="xl6924921" style='border-top:none;border-left:none'>妫�楠屼緷鎹�:</td> + <td colspan=7 class="xl6624921" style='border-right:.5pt solid black; border-left:none'>{{ tableData.dname }} + 銆� </td> + </tr> + <tr class="xl6524921" height=53 style='mso-height-source:userset;height:40.05pt'> + <td colspan=2 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> + 浜у搧鍚嶇О: + </td> + <td colspan=4 class="xl6624921" style='border-right:.5pt solid black; border-left:none'> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="product"></span> + </p> + </td> + <td colspan=2 class="xl6924921" style='border-top:none;border-left:none'>浜у搧鍨嬪彿:</td> + <td colspan=3 class="xl6624921" style='border-right:.5pt solid black; border-left:none'> <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="deviceStr"></span> + <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="typedata"></span> </p> - </td> - <td colspan=2 class=xl6924921 style='border-top:none;border-left:none'>妫�楠屼緷鎹�:</td> - <td colspan=7 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> -銆� </td> - </tr> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td colspan=2 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> - 浜у搧鍚嶇О: </td> - <td colspan=4 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> + <td colspan=2 class="xl6924921" style='border-top:none;border-left:none'>浜у搧鏁伴噺:</td> + <td colspan=3 class="xl6624921" style='border-right:.5pt solid black; border-left:none'> <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="product"></span> + <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="number"></span> </p> </td> - <td colspan=2 class=xl6924921 style='border-top:none;border-left:none'>浜у搧鍨嬪彿:</td> - <td colspan=3 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="typedata"></span> - </p> - </td> - <td colspan=2 class=xl6924921 style='border-top:none;border-left:none'>浜у搧鏁伴噺:</td> - <td colspan=3 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="number"></span> - </p> - </td> - </tr> + </tr> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td colspan=2 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> - 妫�楠屽唴瀹�: - </td> - <td colspan=14 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - 妫�楠岀粨鏋� - </td> - </tr> + <tr class="xl6524921" height=53 style='mso-height-source:userset;height:40.05pt'> + <td colspan=2 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> + 妫�楠屽唴瀹�: + </td> + <td colspan=14 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> + 妫�楠岀粨鏋� + </td> + </tr> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td colspan=3 height=53 class=xl7624921 style='border-right:.5pt solid black;height:40.05pt'> - 妫�楠岃姹� - </td> - <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - 鏍囧噯鍊� - </td> - <td colspan=1 v-for="a in columnLength" class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - {{a>9?item:'0'+a}} - </td> - <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - 鍒ゅ畾 - </td> - </tr> + <tr class="xl6524921" height=53 style='mso-height-source:userset;height:40.05pt'> + <td colspan=3 height=53 class=xl7624921 style='border-right:.5pt solid black;height:40.05pt'> + 妫�楠岃姹� + </td> + <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + 鏍囧噯鍊� + </td> + <td colspan=1 v-for="a in columnLength" class=xl6624921 style='border-right:.5pt solid black; border-left:none'> + {{a>9?item:'0'+a}} + </td> + <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + 鍒ゅ畾 + </td> + </tr> - <tbody v-for="(item,index) in prjdata" :key="index"> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td :rowspan="item.children.length" height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> - <p > - <span style=" writing-mode: vertical-rl;font-size: 26pt;">{{item.father}}</span> - </p> - </td> - <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{item.children[0].iname}}</span> - </td> - <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{item.children[0].required}}</span> - </td> - <td colspan=1 v-for="(val,index) in item.children[0].testValueList" class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{val}}</span> - </td> + <tbody v-for="(item,index) in prjdata" :key="index"> + <tr class="xl6524921" height=53 style='mso-height-source:userset;height:40.05pt'> + <td :rowspan="item.children.length" height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt'> + <p > + <span style=" writing-mode: vertical-rl;font-size: 26pt;">{{item.father}}</span> + </p> + </td> + <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{item.children[0].iname}}</span> + </td> + <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{item.children[0].required}}</span> + </td> + <td colspan=1 v-for="(val,index) in item.children[0].testValueList" class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{val}}</span> + </td> - <td colspan=2 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - <p v-if="item.children[0].iresult ==1" class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif">鍚堟牸</span></p> - <p v-if="item.children[0].iresult ==0" class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif">涓嶅悎鏍�</span></p> - </td> - </tr> - <tr class=xl6524921 height=53 v-for="(el,index) in (item.children.slice(1))" :key="index" style='mso-height-source:userset;height:40.05pt'> - <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{el.iname}}</span> - </td> - <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{el.required}}</span> - </td> - <td colspan=1 v-for="(testValue,index) in el.testValueList" class=xl6624921 style='border-right:.5pt solid black;border-left:none'> - <span style="font-family:瀹嬩綋">{{testValue}}</span> - </td> - <td colspan=2 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif">{{ el.iresult | formatState}}</span></p> + <td colspan=2 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> + <p v-if="item.children[0].iresult ==1" class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif">鍚堟牸</span></p> + <p v-if="item.children[0].iresult ==0" class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif">涓嶅悎鏍�</span></p> + </td> + </tr> + <tr class="xl6524921" height=53 v-for="(el,index) in (item.children.slice(1))" :key="index" style='mso-height-source:userset;height:40.05pt'> + <td colspan=2 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{el.iname}}</span> + </td> + <td colspan=1 class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{el.required}}</span> + </td> + <td colspan=1 v-for="(testValue,index) in el.testValueList" class=xl6624921 style='border-right:.5pt solid black;border-left:none'> + <span style="font-family:瀹嬩綋">{{testValue}}</span> + </td> + <td colspan=2 class=xl6624921 style='border-right:.5pt solid black; border-left:none'> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif">{{ el.iresult | formatState}}</span></p> - - </td> - </tr> - </tbody> - <tr class=xl6524921 height=53 style='mso-height-source:userset;height:40.05pt'> - <td colspan=8 height=53 class=xl7624921 style='border-right:.5pt solid black; - height:40.05pt;text-align: left;'><p> 妫�楠�/鏃堕棿:</p></td> - <td colspan=8 height=53 class=xl7624921 style='border-right:.5pt solid black; - height:40.05pt;text-align: left;'><p> 瀹℃壒:</p></td> - </tr> + + </td> + </tr> + </tbody> + <tr class="xl6524921" height=53 style='mso-height-source:userset;height:40.05pt'> + <td colspan=8 height=53 class=xl7624921 style='border-right:.5pt solid black;height:40.05pt;text-align: left;'> + <p> 妫�楠�/鏃堕棿:<span>{{tableData.updateTime}}</span></p></td> + <td colspan=8 height=53 class=xl7624921 style='border-right:.5pt solid black; height:40.05pt;text-align: left;'> + <p> 瀹℃壒:<span>{{username}}</span></p></td> + </tr> - <tr height=0 style='display:none'> - <td width=64 style='width:48pt'></td> - <td width=58 style='width:44pt'></td> - <td width=137 style='width:103pt'></td> - <td width=262 style='width:197pt'></td> - <td width=212 style='width:159pt'></td> - <td width=226 style='width:170pt'></td> - <td width=235 style='width:176pt'></td> - </tr> - </table> - <!-- <div v-for="items in prjdata"> - <div v-for="aa in items.length"> --> + <tr height=0 style='display:none'> + <td width=64 style='width:48pt'></td> + <td width=58 style='width:44pt'></td> + <td width=137 style='width:103pt'></td> + <td width=262 style='width:197pt'></td> + <td width=212 style='width:159pt'></td> + <td width=226 style='width:170pt'></td> + <td width=235 style='width:176pt'></td> + </tr> + </table> + + </div> + <div v-for="pel in prjdata"> <template> - <div style="page-break-after: always;"> - <div> - <div class="head" id="head"> + <div align="center" style="page-break-after: always;border-collapse:collapse;table-layout:fixed;page-break-after: always;" width="629"> + <div > + <div class="head"> <div class="head-1"> <img width=174 height=58 src="../../../../public/img/image002.png"> </div> @@ -164,18 +166,19 @@ <div class="bodycs"> <p class=x1111111><span>妫� 娴� 鎶� 鍛�<br> <span class=x1111112 >Test Report</span><br> - <p style=" border-top: 1px solid black;width: 96%;margin-top: -1px;"></p> + <p style=" border-top: 1px solid black;width: 900pt;margin-top: -1px;"></p> </span></p> </div> - <div class="bodycs-1"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:锛圢o锛�:ZTMS01-<br>Report No.锛�</span></p> - <p style="margin-left: 350px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡鏃ユ湡<br> Report Date</span></p> - <p style="margin-left: 180px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�1/8<br> Page</span></p> + <div style="margin-left:40pt"> + <div class="bodycs-1"> + <p ><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:{{ tableData.finInsNo }}<br>Report No.锛�</span></p> + <p style="margin-left: 200px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡鏃ユ湡:{{ tableData.updateTime }}<br> Report Date</span></p> + <p style="margin-left: 200px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�1/8<br> Page</span></p> </div> <div> <div class="bodycs-2"> <p ><span class=x1111112 style='margin-left: 40px;'>妫�楠岄」鐩�:<br> Test Item</span></p> - <p v-for="pel in prjdata"><span class="ziti">{{pel.father}}</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 80px;"></span></span></p> + <p ><span class="ziti">{{pel.father}}</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 80px;"></span></span></p> </div> <div class="bodycs-3"> <p ><span class=x1111112 style='margin-left: 36px;'>鏍峰搧鍚嶇О:<br>Description</span></p> @@ -187,38 +190,51 @@ </div> <div class="bodycs-3"> <p ><span class=x1111112 style='margin-left: 36px;'>鏍峰搧鏁伴噺:<br>Quantity</span></p> - <p v-for="pel in prjdata"><span class="ziti">{{quantity}}</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="ziti">{{quantity}}</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> <div class="bodycs-3"> <p ><span class=x1111112 style='margin-left: 36px;'>妫�楠岀被鍒�:<br>Type of Test</span></p> - <p v-for="pel in prjdata"><span class="ziti">浜у搧妫�楠�</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="ziti">浜у搧妫�楠�</span><br><span style="display: block;height: 2px; width: 500px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> + <div> + <br> + <br> + <span + style='mso-spacerun:yes'> </span> + </div> <div> <div class="chilen"> <p ><span class="x1111113">鎵� 鍑�:<br> Approved by</span></p> - <p v-for="pel in prjdata"><span class="time"></span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="time"></span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> <div class="chilen"> <p ><span class="x1111113">鏍搁獙鍛�:<br> Inspected by</span></p> - <p v-for="pel in prjdata"><span class="time"></span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="time"></span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> <div style="display: flex;margin-left: 280px;"> <p ><span class="x1111113">妫�楠屽憳锛�<br> Tested by</span></p> <p ><span class="time">{{username}}</span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> + <div> + <br> + <br> + <span + style='mso-spacerun:yes'> </span> + </div> <div class="cldata"> <p ><span class="x1111113">閫佹牱鏃ユ湡:<br>Delivery Date</span></p> - <p v-for="pel in prjdata"><span class="time">{{tableData.updateTime}}</span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="time">{{tableData.updateTime}}</span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> <div class="cldata"> <p ><span class="x1111113">娴嬭瘯鏃ユ湡:<br>Testing Date</span></p> - <p v-for="pel in prjdata"><span class="time">{{tableData.createTime}}</span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> + <p ><span class="time">{{tableData.createTime}}</span><br><span style="display: block;height: 2px; width: 300px; background: rgb(20, 20, 22);margin-left: 75px;"></span></span></p> </div> + </div> </div> </div> </div> <div class="pagefooting"> - <p><span style="font-size:8pt;font-family:瀹嬩綋;color: cornflowerblue;"> + <p><span style="font-size:14pt;font-family:瀹嬩綋;color: cornflowerblue;"> 鍦板潃:姹熻嫃鐪佸崡閫氬競缁忔祹鎶�鏈紑鍙戝尯鏂板紑鍗楄矾1鍙�(226010) 鐢佃瘽:051389191125 浼犵湡:051389191123 <br>Add: No 1 Xinkainan Road, NETDZ Nantong, Jiangsu, China (226010); TEL: 051389191125 ; Fax:051389191123 </span></p> @@ -245,7 +261,7 @@ <span class=x1111112 >Test Report</span><br> </span></p> <div class="bodycs-1"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:锛圢o锛�:ZTMS01-<br>Report No.锛�</span></p> + <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:{{ tableData.finInsNo }}<br>Report No.锛�</span></p> <p style="margin-left: 620px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�2/8<br> Page</span></p> </div> </div> @@ -266,8 +282,16 @@ </div> </div> </div> + <div> + <br> + <br> + <br> + <br><br><br> + <span + style='mso-spacerun:yes'> </span> + </div> <div class="pagefooting"> - <p><span style="font-size:8pt;font-family:瀹嬩綋;color: cornflowerblue;"> + <p><span style="font-size:14pt;font-family:瀹嬩綋;color: cornflowerblue;"> 鍦板潃:姹熻嫃鐪佸崡閫氬競缁忔祹鎶�鏈紑鍙戝尯鏂板紑鍗楄矾1鍙�(226010) 鐢佃瘽:051389191125 浼犵湡:051389191123 <br>Add: No 1 Xinkainan Road, NETDZ Nantong, Jiangsu, China (226010); TEL: 051389191125 ; Fax:051389191123 </span></p> @@ -291,47 +315,64 @@ <div class="bodycs"> <p class=x1111111><span>妫� 娴� 鎶� 鍛�<br> <span class=x1111112 >Test Report</span><br> + <p style=" border-top: 1px solid black;width: 900pt;margin-top: -1px;"></p> </span></p> <div class="bodycs-1"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:锛圢o锛�:ZTMS01-<br>Report No.锛�</span></p> + <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:{{ tableData.finInsNo }}<br>Report No.锛�</span></p> <p style="margin-left: 620px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�3/8<br> Page</span></p> </div> </div> - <div> - <p style=" border-top: 1px solid black;width: 96%;margin-top: -1px;"></p> - <p class="x1111113" ><span style="display: flex;margin-top: 40px;margin-left: 40px;">鎶ュ憡姝f枃锛�</span></p> + + + <div> + <p class=x1111112 style="display: flex;margin-left: 40px;">1.娴嬭瘯璁惧</p> + <div class="bodycs" style="margin-top: 80px;" v-if='ela.iname !== "" ' v-for="ela in pel.children"> + <div class="bodycs-1" style="margin-top: 10px;"> + <p style="margin-left: 40px;font-size:12pt;font-family:榛戜綋">妫�楠岄」鐩細<span style="width: 60px;"> {{ela.iname}}<br><span>璁惧鍚嶇О锛歿{ ela.ename }}</span><br>Name of Equipment</span></p> + <p style="padding-left: 100px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>璁惧鍨嬪彿:{{ ela.specifications }}<br> Model</span></p> + <p style="padding-left: 100px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>璁惧缂栧彿:{{ ela.code}}<br>Serial No.</span></p> + <p style="margin-left: 110px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>鏍″噯鏈夋晥鏈�:{{ ela.date }}<br>Calibration Due Date</span></p> + </div> + </div> + <!-- <div> + <p style=" border-top: 1px solid black;width: 96%;margin-top: 20px;"></p> + </div> --> </div> - <div class="bodycs" style="margin-top: 30px;"> - <p class=x1111112><span>{{iname}}<br> + + + + <div style="display: flex;margin-top: 60px;"> + <p ><span><span class=x1111112 style="margin-left: 40px;">2.鍙傝�冩爣鍑哛eference standards</span> + <!-- + <br>鏈妫�娴嬫墍渚濇嵁鐨勬妧鏈枃浠讹紙浠e彿銆佸悕绉帮級锛�<br>Reference documents for this testing --> </span></p> - <div class="bodycs-1" style="margin-top: 10px;"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">1.娴嬭瘯璁惧<br> 璁惧鍚嶇О<br>Name of Equipment</span></p> - <p style="margin-left: 150px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>璁惧鍨嬪彿<br> Model</span></p> - <p style="margin-left: 150px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>璁惧缂栧彿<br>Serial No.</span></p> - <p style="margin-left: 150px;"><span style="font-size:12pt;font-family:榛戜綋"> <br>鏍″噯鏈夋晥鏈�<br>Calibration Due Date</span></p> - </div> - <div> - <p style=" border-top: 1px solid black;width: 96%;margin-top: 20px;"></p> - </div> </div> - <div style="margin-top: 50px;display: flex;"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">2.鍙傝�冩爣鍑哛eference standards <br>鏈妫�娴嬫墍渚濇嵁鐨勬妧鏈枃浠讹紙浠e彿銆佸悕绉帮級锛�<br>Reference documents for this testing </span></p> - </div> + <br> + <br> + + <p style="font-size:18pt;font-family:瀹嬩綋">鏈妫�楠屽弬鑰冪殑鎶�鏈枃浠舵槸:<span>{{tableData.dname}}锛岀紪鍙�:{{tableData.dnumber }}</span></p> <div> <p style=" border-top: 1px solid black;width: 96%;margin-top: 1px;"></p> </div> - <div style="margin-top: 50px;display: flex;"> - <p class=x1111112 style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">3.鐜鏉′欢Environmental conditions锛�</span></p> + + <div style="margin-top: 80px;display: flex;"> + <p class=x1111112 style="margin-left: 40px;"><span >3.鐜鏉′欢Environmental conditions锛�</span></p> </div> <div style="display: flex;"> <p style="margin-left: 50px;"><span >娓╁害(Temperature)锛氣剝 </span></p> <p style="margin-left: 450px;"><span >鐩稿婀垮害(R.H.)锛�%</span></p> </div> <div style="margin-top: 50px;display: flex;"> - <p class=x1111112 style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">4.娴嬭瘯鐩殑Test purpose锛�</span></p> + <p class=x1111112 style="margin-left: 40px;"><span>4.娴嬭瘯鐩殑Test purpose锛�</span></p> </div> - <div style="margin-top: 50px;display: flex;"> - <p class=x1111112 style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">5.娴嬭瘯鏂规硶Test method锛�</span></p> + <div v-for="ela in pel.children" v-if='ela.iname !== "" ' style="display: flex;margin-left: 40px;"> + <p>妫�楠岄」鐩細{{ ela.iname }},娴嬭瘯鐩殑鏄細{{ ela.method }}</p> + </div> + <div style="margin-top: 80px;display: flex;"> + <p class=x1111112 style="margin-left: 40px;"><span>5.娴嬭瘯鏂规硶Test method锛�</span></p> + </div> + <div v-for="ela in pel.children" v-if='ela.iname !== "" ' style="display: flex;margin-left: 40px;"> + <p>妫�楠岄」鐩細{{ ela.iname }},娴嬭瘯鐩殑鏄細{{ ela.purpose }}</p> </div> <div> <br> @@ -343,7 +384,7 @@ </div> </div> <div class="pagefooting"> - <p><span style="font-size:8pt;font-family:瀹嬩綋;color: cornflowerblue;"> + <p><span style="font-size:14pt;font-family:瀹嬩綋;color: cornflowerblue;"> 鍦板潃:姹熻嫃鐪佸崡閫氬競缁忔祹鎶�鏈紑鍙戝尯鏂板紑鍗楄矾1鍙�(226010) 鐢佃瘽:051389191125 浼犵湡:051389191123 <br>Add: No 1 Xinkainan Road, NETDZ Nantong, Jiangsu, China (226010); TEL: 051389191125 ; Fax:051389191123 </span></p> @@ -369,7 +410,7 @@ <span class=x1111112 >Test Report</span><br> </span></p> <div class="bodycs-1"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:锛圢o锛�:ZTMS01-<br>Report No.锛�</span></p> + <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:{{ tableData.finInsNo }}<br>Report No.锛�</span></p> <p style="margin-left: 620px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�4/8<br> Page</span></p> </div> </div> @@ -378,20 +419,20 @@ <p class="x1111113" ><span style="font-size 40pt;display: flex;margin-top: 40px;margin-left: 40px;;font-family:榛戜綋">6.娴嬭瘯缁撴灉Test result锛�</span></p> </div> <div> - <table border="2px" style="width: 800px;height: 100px;margin-top: 10px;"> + <table border="2px" style="width: 800px;height: 100px;margin-top: 10px;" > <tr style="height: 80px;"> <td class="x1111113"><span style="font-size 40pt;margin-left: 80px;font-family:榛戜綋">娴嬭瘯椤圭洰</span></td> <td class="x1111113"><span style="font-size 40pt;margin-left: 80px;font-family:榛戜綋">鏍峰搧鏁伴噺</span></td> <td class="x1111113"><span style="font-size 40pt;margin-left: 80px;font-family:榛戜綋">娴嬭瘯缁撴灉</span></td> </tr> - <tr style="height: 100px;"> - <td></td> - <td></td> + <tr style="height: 100px;" v-if='ela.iname !== "" ' v-for="ela in pel.children"> + <td class="x1111113" style="text-align: center;">{{ ela.iname }}</td> + <td class="x1111113" style="text-align: center;">{{ tableData.quantity }}</td> <td></td> </tr> - <tr style="height: 80px;"> + <!-- <tr style="height: 80px;"> <td colspan=3></td> - </tr> + </tr> --> </table> </div> <div> @@ -411,10 +452,17 @@ <span style='mso-spacerun:yes'> </span> </div> + <div> + <br> + <br> + <br> + <span + style='mso-spacerun:yes'> </span> + </div> </div> </div> <div class="pagefooting"> - <p><span style="font-size:8pt;font-family:瀹嬩綋;color: cornflowerblue;"> + <p><span style="font-size:14pt;font-family:瀹嬩綋;color: cornflowerblue;"> 鍦板潃:姹熻嫃鐪佸崡閫氬競缁忔祹鎶�鏈紑鍙戝尯鏂板紑鍗楄矾1鍙�(226010) 鐢佃瘽:051389191125 浼犵湡:051389191123 <br>Add: No 1 Xinkainan Road, NETDZ Nantong, Jiangsu, China (226010); TEL: 051389191125 ; Fax:051389191123 </span></p> @@ -440,7 +488,7 @@ <span class=x1111112 >Test Report</span><br> </span></p> <div class="bodycs-1"> - <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:锛圢o锛�:ZTMS01-<br>Report No.锛�</span></p> + <p style="margin-left: 40px;"><span style="font-size:12pt;font-family:榛戜綋">鎶ュ憡缂栧彿:{{ tableData.finInsNo }}<br>Report No.锛�</span></p> <p style="margin-left: 620px;"><span style="font-size:12pt;font-family:榛戜綋">椤垫锛�5/8<br> Page</span></p> </div> </div> @@ -457,6 +505,13 @@ <br> <br> <span> </span> + </div> + <div> + <br> + <br> + <br> + <span + style='mso-spacerun:yes'> </span> </div> <div> <p class="x1111113" ><span style="font-size 40pt;display: flex;margin-top: 40px;margin-left: 40px;;font-family:榛戜綋">9.娴嬭瘯鍚庢鏌osttest check锛�</span></p> @@ -477,16 +532,22 @@ </div> </div> </div> + <div> + <br> + <br> + <br> + <span + style='mso-spacerun:yes'> </span> + </div> <div class="pagefooting"> - <p><span style="font-size:8pt;font-family:瀹嬩綋;color: cornflowerblue;"> + <p><span style="font-size:14pt;font-family:瀹嬩綋;color: cornflowerblue;"> 鍦板潃:姹熻嫃鐪佸崡閫氬競缁忔祹鎶�鏈紑鍙戝尯鏂板紑鍗楄矾1鍙�(226010) 鐢佃瘽:051389191125 浼犵湡:051389191123 <br>Add: No 1 Xinkainan Road, NETDZ Nantong, Jiangsu, China (226010); TEL: 051389191125 ; Fax:051389191123 </span></p> </div> </div> </template> - <!-- </div> - </div> --> + </div> </div> </template> @@ -580,12 +641,12 @@ itype: '', testValueList: new Array(this.columnLength) } - let rowNum = 15 + let rowNum = 20 let columnNum = this.columnLength if(list && list.length<2){ list.forEach(item=>{ if(item.children && item.children.length < rowNum){ - rowNum = 15 - item.children.length + rowNum = 20 - item.children.length for(let j=0;j<item.children.length;j++){ let arr = [] if(item.children[j].inspectionValue){ @@ -621,7 +682,7 @@ } } }else{ - obj.testValueList = new Array(12) + obj.testValueList = new Array(20) } }) } @@ -650,12 +711,9 @@ } </script> -<style lang="scss"> -table{ - mso-displayed-decimal-separator: "\."; - mso-displayed-thousand-separator: "\,"; -} + +<style lang="scss" > .xl6524921 { padding: 0px; mso-ignore: padding; @@ -1763,6 +1821,7 @@ .head{ display: flex; + width: 900pt; .head-1{ padding: 40px; } @@ -1774,7 +1833,7 @@ } } .bodycss{ - // margin-left: 85px; + margin-left: 85px; } .bodycs{ // margin-left: 135px; @@ -1904,4 +1963,5 @@ mso-pattern: auto; white-space: nowrap; } + </style> \ No newline at end of file diff --git a/src/views/quality/finishedProductInspection/index.vue b/src/views/quality/finishedProductInspection/index.vue index 9d582da..fe633e3 100644 --- a/src/views/quality/finishedProductInspection/index.vue +++ b/src/views/quality/finishedProductInspection/index.vue @@ -37,6 +37,7 @@ import { transform } from '@/util/fileTransform' import printTemplate from './finishedProducter-print.vue' import PrintJS from 'print-js' +import { title } from 'process' export default { components: { finishedProductInspectionAdd, @@ -72,14 +73,22 @@ data: [], // 鏍囬 column: [ + { + minWidth: '120', + prop: 'finInsNo', + label: '浜у搧妫�楠岀紪鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + render: { fun: this.addOrUpdateHandle } + }, { minWidth: '120', prop: 'orderNumber', label: '璁㈠崟鍙�', isTrue: true, isSearch: true, - searchInfoType: 'text', - render: { fun: this.addOrUpdateHandle } + searchInfoType: 'text' }, { minWidth: '120', @@ -211,28 +220,18 @@ } }, methods: { - closedown(){ - // this.printFormData = [] - this.printDialogVisible = false; - }, //鎵撳嵃鎸夐挳 printFun() { - const printSettings = { - paper: { - width: 827, // A4绾哥殑瀹藉害锛堝崟浣嶏細鍍忕礌锛� - height: 595, // A4绾哥殑楂樺害锛堝崟浣嶏細鍍忕礌锛� - orientation: 'portrait', // 绔栧悜鎵撳嵃 - }} - + const style = '@page {margin: 10mm 5mm; margin-bottom: 0;margin-top:0;} ' +'@media print {.title{font-size:30pt;font-weight: 400;font-family: 榛戜綋;!important;}' ; PrintJS({ printable: "printRaw", type: "html", - header:"", - maxWidth: 1000, - printSettings, - style: '@page {margin: 2.0mm 2.0mm;size:A4;}', + scanStyles: false, + maxWidth: 1200, + header: "浜у搧妫�娴嬫姤鍛�", + style:style, + css:'./title.css', targetStyles: ["*"], - fontSize: '30px', ignoreElements: ["no-ignore"], orientation: 'portrait' }); diff --git a/src/views/quality/package/index.vue b/src/views/quality/package/index.vue index 99aee6a..ba390b6 100644 --- a/src/views/quality/package/index.vue +++ b/src/views/quality/package/index.vue @@ -1,13 +1,171 @@ <template> - <div>鍖呰妫�楠�</div> + <div class="mod-config"> + <basic-container> + <ttable + :table="table" + :isShowHide="true" + :prelang="prelang" + :options="options" + ref="processconfiguration" + > + <template #toolbar></template> + </ttable> + </basic-container> + </div> </template> <script> +import ttable from '@/views/common/ztt-table.vue' export default { - + data(){ + return { + prelang: 'operation', + dataListLoading: false, + options: { + height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 + stripe: true, // 鏄惁涓烘枒椹汗 table + highlightCurrentRow: false, // 鏄惁瑕侀珮浜綋鍓嶈 + border: true, // 鏄惁鏈夌旱鍚戣竟妗� + lazy: false, // 鏄惁闇�瑕佹噿鍔犺浇 + fit: true, // 鍒楃殑瀹藉害鏄惁鑷拺寮� + multiSelect: true, // + seqNo: true, + isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳 + isRefresh: true, // 鏄惁鏄剧ず鍒锋柊鎸夐挳 + isSearch: true, // 楂樼骇鏌ヨ鎸夐挳 + defaultOrderBy: { column: 'createTime', direction: 'desc' } + }, + table: { + total: 0, + currentPage: 1, + pageSize: 20, + data: [], + // 鏍囬 + column: [ + { + minWidth: '140', + prop: 'material', + label: '璁㈠崟缂栫爜', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'type', + label: '浜у搧鍚嶇О', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + },{ + minWidth: '140', + prop: 'oo', + label: '浜у搧鍨嬪彿', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + },{ + minWidth: '140', + prop: 'materhhooial', + label: '璐ㄩ噺杩芥函鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'mateuurial', + label: '瀹㈡埛鍚嶇О', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'materoiial', + label: '宸ヨ壓鏂囦欢缂栧彿', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'matperoial', + label: '搴撲綅鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '140', + prop: 'materpial', + label: '浜у搧鍚嶇О', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + { + minWidth: '130', + width: '150', + prop: 'dealTime', + label: '瀹℃牳鏃堕棿', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'datetimerange', + // formatter: this.formatDateTime, + }, + { + minWidth: '140', + prop: 'maial', + label: '鏁伴噺', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + }, + ], + operator: [{ + text: '鎵撳嵃', + type: 'text', + size: 'small', + fun: this.showPrint, + show: { + val: [ + '1', + '0' + ], + key: 'result' + } + },{ + text: '浣滃簾', + type: 'text', + size: 'small', + fun: this.deleteHandle + }], + operatorConfig: { + fixed: 'right', + label: '鎿嶄綔', + width: 100, + minWidth: 100 + }, + toolbar: [ + { + text: '鑾峰彇IFS鎴愬搧搴�', + type: 'primary', + // fun: this.addOrUpdateHandle + }, + ], + // operator: [], + // operatorConfig: {} + }, + } + }, + medthods: {}, +// computed: { +// ...mapGetters(['permissions']) +// }, + components: { + ttable + }, } -</script> - -<style> - -</style> \ No newline at end of file +</script> \ No newline at end of file diff --git a/src/views/quality/packageinspect/index.vue b/src/views/quality/packageinspect/index.vue new file mode 100644 index 0000000..a575e60 --- /dev/null +++ b/src/views/quality/packageinspect/index.vue @@ -0,0 +1,231 @@ +<!-- + - Copyright (c) 2018-2025, ztt All rights reserved. + - + - Redistribution and use in source and binary forms, with or without + - modification, are permitted provided that the following conditions are met: + - + - Redistributions of source code must retain the above copyright notice, + - this list of conditions and the following disclaimer. + - Redistributions in binary form must reproduce the above copyright + - notice, this list of conditions and the following disclaimer in the + - documentation and/or other materials provided with the distribution. + - Neither the name of the pig4cloud.com developer nor the names of its + - contributors may be used to endorse or promote products derived from + - this software without specific prior written permission. + - Author: ztt + --> + <template> + <div class="mod-config"> + <basic-container> + <ttable + :table="table" + :resultData="resultData" + @handleSelectionChange="handleSelectionChange" + :prelang="prelang" + :options="options" + :ajaxFun="ajaxFun" + ref="packageInspectTable"> + <template #toolbar> + </template> + </ttable> + </basic-container> + <!-- 寮圭獥, 鏂板 / 淇敼 --> + <!-- <RawMaterialForm + v-if="addOrUpdateVisible" + ref="addOrUpdate" + @refreshDataList="getData" + ></RawMaterialForm> --> + </div> +</template> +<script> +import ttable from '@/views/common/ztt-table.vue' +import { fetchList,deleteById } from '@/api/quality/packageInspect' +// import RawMaterialForm from './rawMaterial-form' +import * as fecha from 'element-ui/lib/utils/date' +import { mapGetters } from 'vuex' + export default { + data() { + return { + resultData:[], + addOrUpdateVisible: false, + type: [1], + multipleSelection: [], + prelang: 'packageInspect', + ajaxFun: fetchList, + options: { + height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 + stripe: true, // 鏄惁涓烘枒椹汗 table + highlightCurrentRow: false, // 鏄惁瑕侀珮浜綋鍓嶈 + border: true, // 鏄惁鏈夌旱鍚戣竟妗� + lazy: false, // 鏄惁闇�瑕佹噿鍔犺浇 + fit: true, // 鍒楃殑瀹藉害鏄惁鑷拺寮� + multiSelect: true, // + seqNo: true, + isRefresh: true, // 鏄惁鏄剧ず鍒锋柊鎸夐挳 + isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳H + isSearch: true, // 楂樼骇鏌ヨ鎸夐挳 + defaultOrderBy: { column: 'createTime', direction: 'desc' }, + }, + table: { + total: 0, + currentPage: 1, + pageSize: 20, + data: [], + // 鏍囬 + column: [ + { + minWidth: '180', + prop: 'packInsNo', + label: '鍖呰妫�楠岀紪鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text', + render: { fun: this.addOrUpdateHandle } + }, + { + minWidth: '180', + prop: 'packageNo', + label: '鍖呰缂栫爜', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '180', + prop: 'contractNo', + label: '鍚堝悓鍙�', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '180', + prop: 'projectName', + label: '椤圭洰鍚嶇О', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '180', + prop: 'customerName', + label: '瀹㈡埛鍚嶇О', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '180', + prop: 'createTime', + label: '鎶ユ鏃ユ湡', + isTrue: true, + sort: true, + isSearch: true, + searchInfoType: 'text', + formatter: this.formatDateTime, + }, + { + minWidth: '180', + prop: 'createUser', + label: '鎶ユ浜�', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '200', + prop: 'result', + label: '缁撹', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + ], + toolbar: [ + // { + // text: '鏂板', + // type: 'primary', + // fun: this.addOrUpdateHandle + // }, + ], + operator: [ + { + text: '浣滃簾', + type: 'text', + size: 'small', + fun: this.deleteHandle + }], + operatorConfig: { + fixed: 'right', + label: '鎿嶄綔', + width: 100, + minWidth: 100 + }, + }, + } + }, + components: { + ttable, + }, + created() { }, + computed: { + ...mapGetters(['permissions']) + }, + watch:{ + + }, + methods:{ + // 鍒犻櫎 + deleteHandle(row) { + const _than = this + this.$confirm('鏄惁纭鍒犻櫎鍖呰缂栧彿銆�' + row.packInsNo+'銆戠殑鏁版嵁锛�' , '鎻愮ず', { + confirmButtonText: '纭畾', + cancelButtonText: '鍙栨秷', + closeOnClickModal: false, + type: 'warning' + }).then(function() { + deleteById(row.id).then((response)=>{ + var data = response.data + if (data.code == 0) { + _than.$message.success('鍒犻櫎鎴愬姛') + } else { + _than.$message.error('鍒犻櫎澶辫触') + } + _than.getData() + }) + }).catch((error) => { + console.log(error); + }) + }, + // 鏂板 / 淇敼 + addOrUpdateHandle(row) { + this.$router.push({ + name: 'packageInspectForm', + query: { + id: row == null ? null : row.id + }, + params:{resultVal : row.result=='' ? null : row.result} + }) + }, + formatResult(row, column, cellValue){ + if(cellValue != undefined || cellValue != null){ + if(cellValue == '涓嶅悎鏍�'){ + return "<span style='color:#E84738;'>涓嶅悎鏍�</span>" + } + return "<span style='color:#34BD66;'>鍚堟牸</span>" + } + }, + formatDateTime(row, column, cellValue) { + return cellValue ? fecha.format(new Date(cellValue), 'yyyy-MM-dd') : '' + }, + getData() { + this.$refs.packageInspectTable.getDataList() + }, + // table鑷甫浜嬩欢 + handleSelectionChange(val) { + this.multipleSelection = val + }, + } + } + </script> + \ No newline at end of file diff --git a/src/views/quality/packageinspect/packageInspect-form.vue b/src/views/quality/packageinspect/packageInspect-form.vue new file mode 100644 index 0000000..891b0dd --- /dev/null +++ b/src/views/quality/packageinspect/packageInspect-form.vue @@ -0,0 +1,602 @@ +<template> + <div style="height: 100%"> + <div class="page-header"> + <div class="header-left"> + <a @click="$router.go(-1)"><i class="icon-btn-back"></i></a> + <h2 v-if="resultVal=='' || resultVal==null">缂栬緫-鍖呰妫�楠�</h2> + <h2 v-else>鏌ョ湅-鍖呰妫�楠�</h2> + </div> + <div class="btn-group header-right"> + </div> + </div> + <div class="page-main"> + <div class="packageInspect-basic"> + <el-form + :model="dataForm" + :rules="dataRule" + ref="dataForm" + style="width: 100%" + class="l-mes" + label-width="110px"> + <el-row> + <el-col :span="6"> + <el-form-item label="鍖呰妫�楠岀紪鍙�" prop="packInsNo"> + <el-input v-model="dataForm.packInsNo" disabled> + </el-input> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="鍖呰缂栧彿" prop="packageNo"> + <el-input v-model="dataForm.packageNo" disabled></el-input> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item prop="projectName" label="椤圭洰鍚嶇О" > + <el-tooltip :disabled="dataForm.projectName==null" :content="dataForm.projectName"> + <el-input v-model="dataForm.projectName" disabled ></el-input> + </el-tooltip> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="瀹㈡埛鍚嶇О" prop="customerName"> + <el-input v-model="dataForm.customerName" disabled /> + </el-form-item> + </el-col> + </el-row> + <el-row> + <el-col :span="6"> + <el-form-item label="鍚堝悓鍙�" prop="contractNo"> + <el-input v-model="dataForm.contractNo" disabled></el-input> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="鎶ユ鏃ユ湡" prop="createTime"> + <el-input v-model="dataForm.createTime" disabled /> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="鎶ユ浜�" prop="createUser"> + <el-input v-model="dataForm.createUser" disabled /> + </el-form-item> + </el-col> + </el-row> + </el-form> + </div> + <div class="packageInspect-detail"> + <el-row :gutter="10" style="width:100%;z-index: 10;height:50px;"> + <el-col :span="20">妫�楠岄」鐩�</el-col> + <el-col :span="2"> + <el-button v-if="resultVal=='' || resultVal==null" style="width:100%" size="small" @click="clickAddLine()">娣诲姞妫�楠岄」鐩�</el-button> + </el-col> + <el-col :span="2"> + <el-button v-if="resultVal=='' || resultVal==null" style="width:100%" type="primary" size="small" + @click="savePackIns()">淇濆瓨</el-button> + </el-col> + </el-row> + <el-row style="width:100%;"> + <el-col :span="24"> + <el-table + :header-cell-style="{textAlign:'center',color:'black',backgroundColor:'#fafafa'}" + :cell-style="{textAlign:'center'}" + ref="table" + :data="list" + border + style="width: 100%;" + height="400" + row-key="randomId" class="l-mes" + default-expand-all + :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> + <el-table-column type="index" label="搴忓彿" width="60"> + </el-table-column> + <el-table-column prop="name" label="椤圭洰" width="260"> + <template slot-scope="scope"> + <el-input :readonly="resultVal!=null" v-if="scope.row.children" class="inline-input" style="width:90%;" v-model="scope.row.name" + placeholder="璇疯緭鍏ラ」鐩悕绉�"></el-input> + </template> + </el-table-column> + <el-table-column prop="required" label="瑕佹眰" width="260"> + <template slot-scope="scope"> + <div v-if="!scope.row.children"> + <el-input :readonly="resultVal!=null" v-model="scope.row.required" + placeholder="璇疯緭鍏ヨ姹�"></el-input> + </div> + </template> + </el-table-column> + <el-table-column prop="note" label="妫�楠屾弿杩�" width="260" > + <template slot-scope="scope"> + <div v-if="!scope.row.children"> + <el-input :readonly="resultVal!=null" v-model="scope.row.note" placeholder="妫�楠屾弿杩�"></el-input> + </div> + </template> + </el-table-column> + <el-table-column prop="testState" label="缁撹" min-width="150"> + <template slot-scope="scope"> + <el-select style="width:100%" :disabled="resultVal!=null" @change="changeResult" v-model="scope.row.result" v-if="!scope.row.children"> + <el-option label="鍚堟牸" value="鍚堟牸"></el-option> + <el-option label="涓嶅悎鏍�" value="涓嶅悎鏍�"></el-option> + </el-select> + </template> + </el-table-column> + <el-table-column v-if="resultVal=='' || resultVal==null" fixed="right" style="background-color: white;" label="鎿嶄綔" width="200"> + <template slot-scope="scope"> + <el-button v-if="scope.row.children" icon="el-icon-circle-plus-outline" type="text" @click="clickAddChildren(scope.row,scope.$index)">娣诲姞琛�</el-button> + <el-button v-if="!scope.row.children" icon="el-icon-circle-close" type="text" + @click="clickDelLine(scope.row,scope.$index,scope.row.children!=null)">鍙栨秷</el-button> + <el-button v-if="scope.row.children" icon="el-icon-circle-close" type="text" + @click="clickDelLine(scope.row,scope.$index,scope.row.children!=null)">鍒犻櫎椤圭洰</el-button> + + </template> + </el-table-column> + </el-table> + </el-col> + </el-row> + </div> + <div class="packageInspect-result"> + <el-row> + <el-col :span="24">妫�楠岀粨璁�</el-col> + </el-row> + <el-row style="width:100%"> + <el-col :span="24"> + <el-table class="l-mes" border height="90" :data="conclusionTable" ref="conclusion" v-model="conclusion" + :header-cell-style="{textAlign:'center',color:'black',backgroundColor:'#fafafa'}" + :cell-style="{textAlign:'center'}"> + <el-table-column prop="packageNo" label="鍖呰缂栧彿"></el-table-column> + <el-table-column prop="userName" label="妫�楠屽憳"></el-table-column> + <el-table-column prop="result" label="妫�楠岀粨璁�"> + <template slot-scope="scope"> + <el-select :disabled="resultVal!=null" style="width:100%" v-model="scope.row.result"> + <el-option label="鍚堟牸" value="鍚堟牸"></el-option> + <el-option label="涓嶅悎鏍�" value="涓嶅悎鏍�"></el-option> + </el-select> + </template> + </el-table-column> + <el-table-column label="鎿嶄綔"> + <template> + <el-button type="text" :disabled="resultVal!=null" @click="submitSave()" size="small">涓婃姤</el-button> + </template> + </el-table-column> + </el-table> + </el-col> + </el-row> + </div> + </div> + </div> +</template> + +<script> +import { + fetchListById, + updatePackageInsProduct, + updatePackageInspectById, +} from '@/api/quality/packageInspect' +export default { + computed:{}, + components:{ + }, + data(){ + return{ + loading: false, + resultVal: null, + dataForm:{ + id: null, + packInsNo: null, + packageNo: '', + contractNo: '', + projectName: '', + customerName: '', + packageInsProductS: [{ + deviceId: 0, + father:'', + name: '', + required: '', + testValue: '', + unit: '', + testValueList: [] + }] + }, + form: null, + list:[], + conclusion: null, + conclusionTable: [{ + packageNo: '', + userName: '', + result: '' + }], + dataRule: {}, + } + }, + beforeUpdate(){ + this.$nextTick(()=>{ + this.$refs.table.doLayout(); + }) + }, + created(){ + this.dataForm.id = this.$route.query.id + this.resultVal = this.$route.params.resultVal + if(!this.resultVal){ + let val = sessionStorage.getItem("packIns-resultVal-"+this.dataForm.id) + if(val){ + this.resultVal=val + } + } + this.init() + }, + watch:{ + }, + methods:{ + changeResult(){ + let result = '' + let data = this.list + if(data){ + result='鍚堟牸' + data.forEach(item=>{ + if(item.children){ + item.children.forEach(ele=>{ + if(ele.result=='涓嶅悎鏍�'){ + result='涓嶅悎鏍�' + } + }) + } + }) + } + this.conclusionTable[0].result = result + }, + //涓婃姤 + submitSave(){ + const _than = this + this.$confirm('涓婃姤鍓嶏紝璇风‘璁ゆ楠岄」鐩槸鍚﹀凡淇濆瓨!', '鎻愮ず', { + confirmButtonText: '纭涓婃姤', + cancelButtonText: '鍙栨秷', + type: 'warning' + }).then(() => { + let data = { + id: _than.dataForm.id, + result: _than.conclusionTable[0].result, + } + updatePackageInspectById(data).then(res => { + if(res.data.code === 0){ + _than.resultVal = res.data.data + sessionStorage.setItem("packIns-resultVal-"+_than.dataForm.id,res.data.data) + _than.$message.success("涓婃姤鎴愬姛"); + }else{ + _than.$message.error("涓婃姤澶辫触",res.data.data); + } + }) + }).catch(() => {}) + }, + // 娣诲姞琛� + clickAddLine() { + this.list.push({ + name: '', + randomId: Math.random(), + children: [{ + name: '', + note: '', + required: '', + result: '', + randomId: Math.random(), + }] + }) + }, + //娣诲姞瀛愮骇 + clickAddChildren(row,index){ + row.children.push({ + name: row.name, + note: '', + required: '', + result: '', + randomId: Math.random(), + }) + }, + // 鍒犻櫎琛� + clickDelLine(row,index,isParent) { + if(isParent){ + let parentIndex = this.list.findIndex(el =>{ + return el.randomId == row.randomId + }) + this.list.splice(parentIndex,1) + }else{ + let i = this.list.findIndex(el =>{ + return el.children.find(ele => ele.randomId == row.randomId) + }) + let childrenIndex = this.list[i].children.findIndex(el =>{ + return el.randomId == row.randomId + }) + this.list[i].children.splice(childrenIndex,1) + } + }, + //淇濆瓨妫�鏌ラ」 + savePackIns(){ + if(this.list.length==0){ + this.$message.error("妫�楠岄」鐩负绌�!") + return + }else{ + let dataList = [] + this.list.forEach(item=>{ + if(item.children){ + item.children.forEach(ele=>{ + let obj = { + id: ele.pid || null, + name: item.name, + note: ele.note, + packageInspectId: this.dataForm.id, + required: ele.required, + result: ele.result, + } + dataList.push(obj) + }) + } + }) + updatePackageInsProduct(dataList).then(res=>{ + if(res.status===200){ + this.$message.success("淇濆瓨鎴愬姛") + } + }).catch(error=>{ + console.log(error); + this.$message.error("淇濆瓨澶辫触") + }) + } + }, + init(){ + if(this.dataForm.id){ + fetchListById(this.dataForm.id).then(res=>{ + let data = res.data.data + this.dataForm.packInsNo = data.packInsNo + this.dataForm.packageNo = data.packageNo + this.dataForm.contractNo = data.contractNo + this.dataForm.customerName = data.customerName + this.dataForm.projectName = data.projectName + this.dataForm.createTime = data.createTime + this.dataForm.createUser = data.createUser + this.list = [] + let userNameList = [] + data.packageInsProductS.forEach(item => { + if (item.children) { + let ele = { + randomId: Math.random(), + name: null, + children: [] + } + ele.name = item.name + item.children.forEach(obj => { + if(obj.userName){ + userNameList.push(obj.userName) + } + let o = { + name: item.name, + randomId: Math.random(), + required: obj.required, + pid: obj.pid, + note: obj.note?obj.note:'', + result: obj.presult + } + ele.children.push(o) + }) + this.list.push(ele) + } + }) + this.conclusionTable = [{ + packageNo: data.packageNo, + userName: Array.from(new Set(userNameList)).join(','), + result: null + }] + this.$nextTick(()=>{ + if(this.list.length>0){ + this.changeResult() + } + }) + }).catch(error=>{ + this.$message.error("鑾峰彇澶辫触",error) + }) + }else{ + this.conclusionTable = [] + } + }, + }, +} +</script> + +<style> +.packageInspect-detail { + width: 100%; + height: 490px; + padding: 10px 20px; + display: flex; + border: 1px solid #ddd; + background-color: #fff; + margin-top: 10px; + box-sizing: border-box; + flex-wrap: wrap; +} + +.packageInspect-result { + width: 100%; + height: 150px; + padding: 10px 20px; + display: flex; + border: 1px solid #ddd; + background-color: #fff; + margin-top: 10px; + box-sizing: border-box; + flex-wrap: wrap; +} + +.packageInspect-basic { + background-color: #fff; + height: 120px; + display: flex; + flex-wrap: wrap; + padding: 10px 20px; + border: 1px solid #ddd; + box-sizing: border-box; +} + +.packageInspect-related-stock-part { + background-color: #fff; + width: 100%; + height: 220px; + border: 1px solid #ddd; + padding: 10px 20px 0px 20px; + box-sizing: border-box; +} + +.packageInspect-bom { + background-color: #fff; + width: 100%; + height: 499px; + border: 1px solid #ddd; + padding: 10px 20px; + box-sizing: border-box; +} + +.packageInspect-bom .el-card__header { + padding: 1px 20px; + border-bottom: 0px solid #ebeef5; +} + +.packageInspect-bom .el-card__body { + height: calc(100% - 22px); +} + +.packageInspect-bom .el-card__body .el-collapse { + height: 100%; + overflow: auto; +} + +.packageInspect-technology-params { + background-color: #fff; + width: calc(52% - 20px); + float: left; + height: 719px; + border: 1px solid #ddd; + padding: 10px 20px; + margin-left: 20px; +} + +.packageInspect-structure { + background-color: #fff; + width: 35%; + float: left; + height: 719px; + border: 1px solid #ddd; + padding: 10px 20px; + box-sizing: border-box; +} + +.packageInspect-flow { + background-color: #fff; + width: calc(65% - 20px); + float: left; + height: 719px; + border: 1px solid #ddd; + padding: 10px 20px; + margin-left: 20px; + box-sizing: border-box; +} + +/*鑷畾涔塪isabled鐘舵�佷笅checkbox鐨勬牱寮�*/ +.completeproductstructure-checkout + .el-checkbox__input.is-disabled.is-checked + .el-checkbox__inner { + background-color: #006eff; + border-color: #006eff; +} + +.completeproductstructure-checkout + .el-checkbox__input.is-disabled.is-checked + + span.el-checkbox__label { + color: #006eff; + border-color: #006eff; +} + +.completeproductstructure-checkout + .el-checkbox__input.is-disabled + .el-checkbox__inner { + background-color: #ffffff; + cursor: pointer; +} + +.completeproductstructure-checkout + .el-checkbox__input.is-disabled + + span.el-checkbox__label { + color: #606266; + cursor: pointer; +} + +.completeproductstructure-checkout .el-checkbox__inner::after { + border: 1px solid #fff !important; + border-left: 0 !important; + border-top: 0 !important; + cursor: pointer !important; +} + +.packageInspect-bom-div { + width: 100%; + margin-bottom: 5px; +} + +.packageInspect-technology-div { + width: 100%; + margin-bottom: 5px; + margin-right: 10px; +} + +.packageInspect-technology-div .el-collapse { + border-top: 0px; + border-bottom: 0px; +} + +.structure-detail-table th.gutter { + display: table-cell !important; + width: 10px !important; +} + +.structure-detail-table colgroup.gutter { + display: table-cell !important; + width: 10px !important; +} + +.final-product-checkout .el-card__header { + padding: 0px 20px; + border-bottom: 0px; +} + +.final-product-checkout .el-card__body { + padding: 0px 20px 20px; +} + +.orimaterial-quantity .el-card__header { + padding: 0px 20px; + border-bottom: 0px; +} + +.orimaterial-quantity .el-card__body { + padding: 0px 20px 20px; +} + +.packageInspect-materialcost-table th.gutter { + display: table-cell !important; + width: 10px !important; +} + +.packageInspect-materialcost-table colgroup.gutter { + display: table-cell !important; + width: 10px !important; +} + +.GooFlow .ico .ico_start:before { + color: red; +} +.highlight-tab-class { + color: #006eff; + background: #e4e7ed; + border-top: 1px solid #006eff; +} +.unhighlight-tab-class { + border: 1px solid #e4e7ed; + border-bottom: none; +} +.avue-crud__menu{ + min-height: 0px; +} +</style> diff --git a/src/views/quality/processInspect/index.vue b/src/views/quality/processInspect/index.vue index 2f8ca18..952ef6c 100644 --- a/src/views/quality/processInspect/index.vue +++ b/src/views/quality/processInspect/index.vue @@ -56,8 +56,8 @@ column: [ { minWidth: '120', - prop: 'orderNumber', - label: '璁㈠崟缂栧彿', + prop: 'proInsNo', + label: '杩囩▼妫�楠岀紪鍙�', isTrue: true, isSearch: true, searchInfoType: 'text', @@ -65,6 +65,14 @@ }, { minWidth: '120', + prop: 'orderNumber', + label: '璁㈠崟缂栧彿', + isTrue: true, + isSearch: true, + searchInfoType: 'text' + }, + { + minWidth: '120', prop: 'material', label: '浜у搧鍚嶇О', isTrue: true, diff --git a/src/views/quality/processInspect/processInspect-form.vue b/src/views/quality/processInspect/processInspect-form.vue index 6a85e93..60b4afb 100644 --- a/src/views/quality/processInspect/processInspect-form.vue +++ b/src/views/quality/processInspect/processInspect-form.vue @@ -18,6 +18,12 @@ <div class="formwrapper"> <el-row> <el-col :span="6"> + <el-form-item label="杩囩▼妫�楠岀紪鍙凤細"> + <el-input @blur="selectInfoByOrderId" disabled + v-model="processInspectVo.proInsNo" autocomplete="off" /> + </el-form-item> + </el-col> + <el-col :span="6"> <el-form-item label="璁㈠崟鍙凤細"> <el-input @blur="selectInfoByOrderId" :disabled="processInspectVo.id != null" v-model="processInspectVo.orderNumber" placeholder="璇疯緭鍏ヨ鍗曞彿" autocomplete="off" /> @@ -40,14 +46,15 @@ autocomplete="off" /> </el-form-item> </el-col> + </el-row> + <el-row> <el-col :span="6"> <el-form-item label="瑙勬牸鍨嬪彿锛�"> <el-input disabled v-model="processInspectVo.specs" placeholder="璇疯緭鍏ヨ鏍煎瀷鍙�" autocomplete="off" /> </el-form-item> </el-col> - </el-row> - <el-row> + <el-col :span="6"> <el-form-item label="宸ュ簭鍚嶇О"> <el-select style="width: 100%" :disabled="processInspectVo.id != null" @@ -64,8 +71,6 @@ autocomplete="off" /> </el-form-item> </el-col> - </el-row> - <el-row> <el-col :span="6"> <el-form-item label="鏁伴噺锛�"> <el-input v-model="processInspectVo.quantity" placeholder="璇疯緭鍏ユ暟閲�" autocomplete="off" @@ -249,6 +254,7 @@ empiricalValueAddMaxNumber: 0, processInspectVo: { id: null, + proInsNo: null, material: null, materialCode: null, orderNumber: "ZTTIC20230001", @@ -352,6 +358,7 @@ if (id != null) { queryById(id).then(res => { let result = res.data.data + this.processInspectVo.proInsNo = result.proInsNo this.processInspectVo.orderNumber = result.orderNumber this.processInspectVo.materialCode = result.materialCode this.processInspectVo.material = result.material diff --git a/src/views/quality/processconfiguration/index.vue b/src/views/quality/processconfiguration/index.vue index e608a41..41372ea 100644 --- a/src/views/quality/processconfiguration/index.vue +++ b/src/views/quality/processconfiguration/index.vue @@ -299,7 +299,7 @@ minWidth: 100 } }, - materialType: [{label:'鍘熸潗鏂欐楠�',value:'鍘熸潗鏂欐楠�'},{label:'杩囩▼妫�楠�',value:'杩囩▼妫�楠�'},{label:'浜у搧妫�楠�',value:'浜у搧妫�楠�'}], + materialType: [{label:'鍘熸潗鏂欐楠�',value:'鍘熸潗鏂欐楠�'},{label:'杩囩▼妫�楠�',value:'杩囩▼妫�楠�'},{label:'浜у搧妫�楠�',value:'浜у搧妫�楠�'},{label:'鍖呰妫�楠�',value:'鍖呰妫�楠�'}], StateList: [{label:'鍏ㄩ儴',value:''},{label:'宸叉彁浜ゅ鏍�',value:'1'},{label:'寰呭鐞�',value:'0'},{label:'宸插鐞�',value:'2'}], insStateList: [{label:'鍏朵粬',value:''},{label:'鐟曠柕',value:'1'}], } diff --git a/src/views/quality/rawMaterial/QrcodeReader.vue b/src/views/quality/rawMaterial/QrcodeReader.vue new file mode 100644 index 0000000..2dbdff2 --- /dev/null +++ b/src/views/quality/rawMaterial/QrcodeReader.vue @@ -0,0 +1,77 @@ +<template> + <div class="qrcode"> + <div class="code"> + <!-- decode鏄壂鎻忕粨鏋滅殑鍑芥暟锛宼orch鐢ㄤ簬鏄惁闇�瑕佹墦寮�鎵嬬數绛掞紝init鐢ㄤ簬妫�鏌ヨ璁惧鏄惁鑳藉璋冪敤鎽勫儚澶寸殑鏉冮檺锛宑amera鍙敤浜庢墦寮�鍓嶉潰鎴栬�呭悗闈㈡憚鍍忓ご --> + <qrcode-drop-zone @decode="onDecode"> + <qrcode-stream @decode="onDecode" :torch="torchActive" @init="onInit" :camera="camera" /> + </qrcode-drop-zone> + <div class="code-button"> + <button @click="switchCamera">鐩告満鍙嶈浆</button> + <button @click="ClickFlash">鎵撳紑鎵嬬數绛�</button> + <button @click="turnCameraOff">鍏抽棴鐩告満</button> + </div> + </div> + </div> + </template> + + <script> + // 寮曠敤vue-qrcode-reader鎻掍欢 + import { QrcodeStream, QrcodeDropZone, QrcodeCapture } from 'vue-qrcode-reader' + + export default { + name: 'Approve', + props: { + camera: { + type: String, + default: 'rear', + }, + torchActive: { + type: Boolean, + default: false, + }, + qrcode: { + type: Boolean, + default: false, + }, + noStreamApiSupport: { + type: Boolean, + default: false, + }, + }, + data() { + return {} + }, + created() { + console.log(222222222222224564646); + }, + + components: { + // 娉ㄥ唽缁勪欢 + QrcodeStream, + QrcodeDropZone, + QrcodeCapture, + }, + methods: { + // 鎵爜缁撴灉鍥炶皟 + onDecode(result) { + this.$emit('onDecode', result) + }, + // 鐩告満鍙嶈浆 + switchCamera() { + this.$emit('switchCamera') + }, + // 鍏抽棴鐩告満锛燂紵锛燂紵锛燂紵 + turnCameraOff() { + this.$emit('turnCameraOff') + }, + // 鎵撳紑鎵嬬數绛� + ClickFlash() { + this.$emit('ClickFlash') + }, + // 妫�鏌ユ槸鍚﹁皟鐢ㄦ憚鍍忓ご + onInit(promise) { + this.$emit('onInit', promise) + }, + }, + } + </script> \ No newline at end of file diff --git a/src/views/quality/rawMaterial/index.vue b/src/views/quality/rawMaterial/index.vue index b5ba1b6..ea1c0a3 100644 --- a/src/views/quality/rawMaterial/index.vue +++ b/src/views/quality/rawMaterial/index.vue @@ -38,11 +38,11 @@ @refreshDataList="getData" ></RawMaterialForm> <el-dialog - top="10vh" + top="7vh" title="鎵撳嵃棰勮" :visible.sync="printDialogVisible" - width="60%"> - <div style="width:100%;height: 60vh;overflow-y: scroll;"> + width="70%"> + <div style="width:90%;margin-left:5%;height: 60vh;overflow-y: scroll;"> <printTemplate id="printRaw" :formData="printFormData"></printTemplate> </div> <span slot="footer" class="dialog-footer"> @@ -54,11 +54,12 @@ </template> <script> import ttable from '@/views/common/ztt-table.vue' -import { getRawInspectList,delObj,exportRawMaterial,getObj } from '@/api/quality/rawMaterial' +import { getRawInspectList,delObj,exportRawMaterial,getObj,downloadReport } from '@/api/quality/rawMaterial' import RawMaterialForm from './rawMaterial-form' import * as fecha from 'element-ui/lib/utils/date' import { mapGetters } from 'vuex' import PrintJS from 'print-js' +import { transformZip } from '@/util/fileTransform' import printTemplate from './rawMaterial-print.vue' export default { data() { @@ -69,6 +70,7 @@ resultData:[], addOrUpdateVisible: false, type: [1], + multipleSelection: [], prelang: 'rawMaterial', ajaxFun: getRawInspectList, options: { @@ -94,12 +96,20 @@ column: [ { minWidth: '120', - prop: 'code', - label: '鍘熸潗鏂欑紪鐮�', + prop: 'rawInsNo', + label: '鍘熸潗鏂欐楠岀紪鍙�', isTrue: true, isSearch: true, searchInfoType: 'text', render: { fun: this.addOrUpdateHandle } + }, + { + minWidth: '120', + prop: 'code', + label: '鍘熸潗鏂欑紪鐮�', + isTrue: true, + isSearch: true, + searchInfoType: 'text' }, { minWidth: '120', @@ -205,24 +215,31 @@ }, ], toolbar: [ - { - text: '鏂板', - type: 'primary', - fun: this.addOrUpdateHandle - }], - operator: [{ - text: '鎵撳嵃', - type: 'text', - size: 'small', - fun: this.previewFun, - show: { - val: [ - '1', - '0' - ], - key: 'judgeState' + { + text: '鏂板', + type: 'primary', + fun: this.addOrUpdateHandle + }, + { + text: '涓嬭浇妫�楠屾姤鍛�', + type: 'primary', + fun: this.downloadReport } - }, + ], + operator: [ + // { + // text: '鎵撳嵃', + // type: 'text', + // size: 'small', + // fun: this.previewFun, + // show: { + // val: [ + // '1', + // '0' + // ], + // key: 'judgeState' + // } + // }, { text: '浣滃簾', type: 'text', @@ -245,9 +262,7 @@ RawMaterialForm, printTemplate, }, - created() { - - }, + created() { }, computed: { ...mapGetters(['permissions']) }, @@ -259,6 +274,30 @@ } }, methods:{ + downloadReport(){ + let selection = this.multipleSelection + if(!selection || selection.length < 1){ + this.$message.error("璇峰厛閫夋嫨妫�楠屾暟鎹�") + return + }else{ + let arr = selection.filter(s=>{ + return s.judgeState==null || s.judgeState=='' + }) + if(arr.length > 0){ + this.$message.error("鍙兘閫夋嫨宸叉娴嬬殑鏁版嵁") + return + } + let ids = [] + selection.forEach(ele=>{ + ids.push(ele.id) + }) + downloadReport({ids : ids}).then(res=>{ + transformZip(res) + }).catch(error=>{ + console.log(error) + }) + } + }, //鏌ョ湅鎶ュ憡鎸夐挳 previewFun(row){ getObj(row.id).then(res=>{ @@ -274,10 +313,16 @@ PrintJS({ printable: "printRaw", type: "html", - maxWidth: 880, // header: "鍘熸潗鏂欐娴嬫姤鍛�", - style: '@page {margin: 10mm 5mm;}', targetStyles: ["*"], + style: `@page {margin: 0mm 5mm;size: A4;} + html {zoom:100%;} + @media print { + html,body{ + width:200mm; + height:297mm; + } + }`, ignoreElements: ["no-ignore"], orientation: 'portrait' }); @@ -331,7 +376,6 @@ }, // 鏂板 / 淇敼 addOrUpdateHandle(row) { - console.log(row); this.$router.push({ name: 'rawMaterialForm', query: { @@ -361,37 +405,36 @@ }, getData() { this.$refs.rawMaterialTable.getDataList() - }, // table鑷甫浜嬩欢 handleSelectionChange(val) { + this.multipleSelection = val // 鏍规嵁鐘舵�侊紝绂佺敤琛ㄥご鎸夐挳 // 绛涢�夊嚭閫変腑璁板綍鐨勭姸鎬� - var stateArr = val.map(function(value, index) { - return value.coState - }) + // var stateArr = val.map(function(value, index) { + // return value.coState + // }) // 閫変腑鐘舵�佹暟缁勫厓绱犲幓閲� - var uniqueStateArr = [] - for (var i = 0; i < stateArr.length; i++) { - if (uniqueStateArr.indexOf(stateArr[i]) == -1) { - uniqueStateArr.push(stateArr[i]) - } - } + // var uniqueStateArr = [] + // for (var i = 0; i < stateArr.length; i++) { + // if (uniqueStateArr.indexOf(stateArr[i]) == -1) { + // uniqueStateArr.push(stateArr[i]) + // } + // } // 寰幆鑷畾涔夋寜閽紝鍒ゆ柇姣忎釜鎸夐挳鐨刾ermitArr鏄惁瀹屽叏鍖呭惈閫変腑鐘舵�侊紝鑻ュ畬鍏ㄥ寘鍚紝鍒欐寜閽寒锛屽惁鍒欐寜閽伆 - for (var i = 0; i < this.stateTagArr.length; i++) { - if ( - uniqueStateArr.every((val) => - this.stateTagArr[i].permitArr.length <= 0 - ? true - : this.stateTagArr[i].permitArr.includes(val) - ) - ) { - this.stateTagArr[i].disabled = false - } else { - this.stateTagArr[i].disabled = true - } - } - this.multipleSelection = val + // for (var i = 0; i < this.stateTagArr.length; i++) { + // if ( + // uniqueStateArr.every((val) => + // this.stateTagArr[i].permitArr.length <= 0 + // ? true + // : this.stateTagArr[i].permitArr.includes(val) + // ) + // ) { + // this.stateTagArr[i].disabled = false + // } else { + // this.stateTagArr[i].disabled = true + // } + // } }, } } diff --git a/src/views/quality/rawMaterial/rawMaterial-form.vue b/src/views/quality/rawMaterial/rawMaterial-form.vue index 7f01ce0..7e8f9be 100644 --- a/src/views/quality/rawMaterial/rawMaterial-form.vue +++ b/src/views/quality/rawMaterial/rawMaterial-form.vue @@ -21,6 +21,12 @@ label-width="110px"> <el-row> <el-col :span="6"> + <el-form-item label="鍘熸潗鏂欐楠岀紪鍙�" prop="rawInsNo"> + <el-input v-model="dataForm.rawInsNo" disabled> + </el-input> + </el-form-item> + </el-col> + <el-col :span="6"> <el-form-item label="闆朵欢鍙�" prop="code"> <el-input v-model="dataForm.code" :disabled="resultVal!=null && dataForm.id!=null"> <el-button @@ -28,6 +34,11 @@ icon="el-icon-search" :disabled="resultVal!=null && dataForm.id!=null" @click="queryCode()"></el-button> + <!-- <el-button + slot="append" + icon="el-icon-full-screen" + :disabled="resultVal!=null && dataForm.id!=null" + @click="Turnonthecamera"></el-button> --> </el-input> </el-form-item> </el-col> @@ -45,17 +56,16 @@ type="datetime" value-format="yyyy-MM-dd HH:mm:ss" disabled> - </el-date-picker> - </el-form-item> - </el-col> - <el-col :span="6"> - <el-form-item label="瑙勬牸鍨嬪彿" prop="specs"> - <el-input v-model="dataForm.specs" disabled></el-input> </el-form-item> </el-col> </el-row> <el-row> + <el-col :span="6"> + <el-form-item label="瑙勬牸鍨嬪彿" prop="specs"> + <el-input v-model="dataForm.specs" disabled></el-input> + </el-form-item> + </el-col> <el-col :span="6"> <el-form-item prop="unit" label="鍗曚綅"> <el-input @@ -74,15 +84,15 @@ <el-input v-model="dataForm.number" :disabled="resultVal!=null" /> </el-form-item> </el-col> + </el-row> + <el-row> <el-col :span="6"> - <el-form-item prop="projectName" label="椤圭洰鍚嶇О"> + <el-form-item prop="projectName" label="椤圭洰鍚嶇О" v-if="dataForm.id!=null"> <el-tooltip :disabled="dataForm.projectName==null" :content="dataForm.projectName"> <el-input v-model="dataForm.projectName" disabled ></el-input> </el-tooltip> </el-form-item> </el-col> - </el-row> - <el-row> <el-col :span="6"> <el-form-item label="鎶ユ鏃ユ湡" prop="createTime" v-if="dataForm.id!=null"> <el-input v-model="dataForm.createTime" disabled /> @@ -160,7 +170,7 @@ <template slot-scope="scope"> <div v-if="!scope.row.children"> <el-tooltip :disabled="scope.row.deviceId != null" class="item" effect="dark" content="璇峰厛閫夋嫨璁惧锛�" placement="top-start"> - <el-select @blur="changeState(scope.row, index)" style="width:100%" allow-create filterable default-first-option + <el-select @blur="changeState(scope.row, index)" style="width:100%" allow-create filterable default-first-option :disabled="scope.row.deviceId == null || (dataForm.id!=null&&resultVal!=null)" v-model="scope.row.testValueList[index]" placeholder="璇疯緭鍏ユ垨閫夋嫨妫�娴嬪��" @change="updateTestValue(scope.row,scope.$index)"> @@ -171,10 +181,6 @@ </div> </template> </el-table-column> - - - - <el-table-column prop="deviceName" label="璇曢獙璁惧" min-width="260"> <template slot-scope="scope"> <div v-if="!scope.row.children"> @@ -189,7 +195,7 @@ <el-table-column prop="note" label="妫�楠屾弿杩�" width="260" > <template slot-scope="scope"> <div v-if="!scope.row.children"> - <el-input @blur="changeState(scope.row, note)" :disabled="scope.row.deviceId == null || (dataForm.id!=null&&resultVal!=null)" v-model="scope.row.note" placeholder="妫�楠屾弿杩�"></el-input> + <el-input @blur="changeState(scope.row, scope.$index)" :disabled="scope.row.deviceId == null || (dataForm.id!=null&&resultVal!=null)" v-model="scope.row.note" placeholder="妫�楠屾弿杩�"></el-input> </div> </template> </el-table-column> @@ -215,8 +221,6 @@ </el-col> </el-row> </div> - - <div class="rawMaterial-result"> <el-row> <el-col :span="24">妫�楠岀粨璁�</el-col> @@ -261,6 +265,7 @@ <el-button type="primary" @click="submitSave()">纭� 瀹�</el-button> </span> </el-dialog> + <!-- <qrcode :qrcode="qrcode" v-show="qrcode" :camera="camera" /> --> </div> </template> @@ -273,13 +278,19 @@ updateRawInspectsById, updateDeviceById, } from '@/api/quality/rawMaterial' import rawMaterialPartDialog from '@/views/common/rawMaterial-part' + // import qrcode from './QrcodeReader.vue' export default { computed:{}, components:{ - rawMaterialPartDialog + rawMaterialPartDialog, + // qrcode + // qrcode: () => import('./QrcodeReader.vue'), }, data(){ return{ + qrcode: false, + torchActive: false, + camera: 'off', userdata:[], currentRow:[], userlist:[], @@ -334,7 +345,7 @@ this.$refs.table.doLayout(); }) }, - mounted(){ + created(){ this.dataForm.id = this.$route.query.id this.resultVal = this.$route.query.resultVal if(this.resultVal == null){ @@ -352,17 +363,77 @@ }, }, methods:{ - changeName(index,row){ - this.projectList.forEach(item=>{ - if(row.name == item.name){ - this.list[index].unit = item.unit - this.list[index].required = item.required - } - }) - }, + // 鎵撳紑鐩告満 + Turnonthecamera() { + this.qrcode = true + this.camera = 'rear' + console.log(2222222); + }, + // 鎵爜缁撴灉鍥炶皟 + // onDecode(result) { + // console.log(result) + // this.turnCameraOff() + // }, + // 鐩告満鍙嶈浆 + // switchCamera() { + // switch (this.camera) { + // case 'front': + // this.camera = 'rear' + // break + // case 'rear': + // this.camera = 'front' + // break + // default: + // this.$toast('閿欒') + // } + // }, + // 鍏抽棴鐩告満 + // turnCameraOff() { + // this.camera = 'off' + // this.qrcode = false + // }, + // 鎵撳紑鎵嬬數绛� + // ClickFlash() { + // switch (this.torchActive) { + // case true: + // this.torchActive = false + // break + // case false: + // this.torchActive = true + // break + // default: + // this.$toast('閿欒') + // } + // }, + + // 妫�鏌ユ槸鍚﹁皟鐢ㄦ憚鍍忓ご + // async onInit(promise) { + // try { + // await promise + // } catch (error) { + // if (error.name === 'StreamApiNotSupportedError') { + // } else if (error.name === 'NotAllowedError') { + // this.errorMessage = 'Hey! I need access to your camera' + // } else if (error.name === 'NotFoundError') { + // this.errorMessage = 'Do you even have a camera on your device?' + // } else if (error.name === 'NotSupportedError') { + // this.errorMessage = + // 'Seems like this page is served in non-secure context (HTTPS, localhost or file://)' + // } else if (error.name === 'NotReadableError') { + // this.errorMessage = + // "Couldn't access your camera. Is it already in use?" + // } else if (error.name === 'OverconstrainedError') { + // this.errorMessage = + // "Constraints don't match any installed camera. Did you asked for the front camera although there is none?" + // } else { + // this.errorMessage = 'UNKNOWN ERROR: ' + error.message + // } + // } + // }, // 纭鍥炶皟 selectPart(param, nodePart, index) { if (typeof param !== 'undefined') { + this.dataForm.rawInsNo = param.rawInsNo this.dataForm.code = param.code this.dataForm.name = param.name this.dataForm.formTime = param.formTime @@ -385,47 +456,25 @@ } this.showPart = true }, - updateDevice(row, index) { - let rowId=JSON.stringify(row.rpId) - updateDeviceById({ deviceId: row.deviceId, rpId: row.rpId }).then(res => { - this.list.forEach(obj => { - obj.children.forEach(c=>{ - if(c.rpId==rowId){ - c.testValue = '' - c.testState = null - c.testValueList = [] - c.note='' - } - }) - }) - }).catch(error => { - console.log(error) - }) - }, - - // updateDevice(row,index){ - // if(this.dataForm.id != null){ - // updateDeviceById({deviceId:row.deviceId,rpId:row.rpId}).then(res=>{ - // this.inspectionItems.forEach(obj => { - // this.list[index-1].testValue = '' - // this.list[index-1].testState = null - // this.list[index-1].testValueList = [] - // this.list[index-1].note = '' - - // }) - // }).catch(error=>{ - // console.log(error) - // }) - // } - // }, + updateDeviceById({ deviceId: row.deviceId, rpId: row.rpId }).then(res => { + row.testValue = null + row.testState = null + row.testValueList = [] + row.note = null + }).catch(error => { + console.log(error) + }) + }, checkTestState(){ let resultVal = '1' this.list.forEach(item=>{ if(item.children){ - if(obj.testState == 0){ - resultVal = '0' - } + item.children.forEach(ele=>{ + if(ele.testState == 0){ + resultVal = '0' + } + }) } }) this.resultVal = resultVal @@ -455,13 +504,15 @@ number: this.unqualifiedNum, } updateRawInspectsById(data).then(res => { - if(res.data.code == 0){ + if(res.data.code == 0 && (res.data.data=='1'|| res.data.data=='0')){ sessionStorage.setItem("raw-resultVal-"+this.dataForm.id,res.data.data) this.$message.success("涓婃姤鎴愬姛"); - this.dialogVisible = false + }else{ + this.$message.error("涓婃姤澶辫触锛�",res.data.data); } + this.dialogVisible = false + this.checkTestState() }); - this.checkTestState() }, addTeatValueColumn(){ this.empiricalValueAdd = this.empiricalValueAdd + 1; @@ -496,8 +547,8 @@ if (arr.length > this.empiricalValueAdd) { this.empiricalValueAdd = arr.length } + }) this.list.push(ele) - }) }else{ ele.children.push({ deviceId: null, @@ -510,7 +561,7 @@ userName: null, testValue: '', testValueList: [], - note: '', + note: null, testState: '' }) this.list.push(ele) @@ -518,7 +569,7 @@ }, delTeatValueColumn(){ - if (this.empiricalValueAdd - 1 === 0) { } else { + if (this.empiricalValueAdd - 1 > 0) { if (this.empiricalValueAddMaxNumber != this.empiricalValueAdd - 1) { this.empiricalValueAdd = this.empiricalValueAdd - 1; this.list.forEach(i => { @@ -527,12 +578,8 @@ } } }, - updateTestValue(row,index){ - console.log(row); if(row.rpId == null){ - - return } let val = row.testValueList.join(","); @@ -553,12 +600,11 @@ this.$message.error(error) }) }, - - init(){ if(this.dataForm.id){ getObj(this.dataForm.id).then(res=>{ let data = res.data.data + this.dataForm.rawInsNo = data.rawInsNo this.dataForm.name = data.name this.dataForm.formTime = data.formTime this.dataForm.code = data.code @@ -586,13 +632,12 @@ if(obj.userName){ userNameList.push(obj.userName) } - if(obj.testValue){ arr = obj.testValue.split(",") } if (arr.length > this.empiricalValueAdd) { - this.empiricalValueAdd = arr.length - } + this.empiricalValueAdd = arr.length + } let o = { deviceId: obj.deviceId, deviceName: obj.deviceName, @@ -626,44 +671,27 @@ } }, changeState(row, index) { - console.log(row) - if (row.rpId != null && row.rpId != '') { - let val = "" - row.testValueList.forEach(e => { - val += e + "," - }) - - // if (note === undefined || note === '' || note === null) { - // return - // } - console.log(val) - val = val.slice(0, -1); - if (val === undefined || val === '' || val === null) { - return - } - - - let obj = { - deviceId: row.deviceId, - rpId: row.rpId, - testValue: val, - note: row.note - - } - console.log(obj) - updateRawInsProduct(obj).then(res => { - if (res.data.code == 0) { - this.$message.success("鏇存柊鎴愬姛") - } else { - this.$message.error("鏇存柊澶辫触") - } - this.init() - }) + if (row.rpId != null && row.rpId != '') { + let val = row.testValueList.join(",") + if (val === undefined || val === '' || val === null) { + return } - }, - - - + let obj = { + deviceId: row.deviceId, + rpId: row.rpId, + testValue: val, + note: row.note + } + updateRawInsProduct(obj).then(res => { + if (res.data.code == 0) { + this.$message.success("鏇存柊鎴愬姛") + } else { + this.$message.error("鏇存柊澶辫触") + } + this.init() + }) + } + }, // 鍒犻櫎瀛愰」鐩� delChildren(row,index,isParent) { if(isParent){ @@ -683,7 +711,6 @@ }, //娣诲姞瀛愰」鐩� addChildren(row){ - console.log(row); let obj = { deviceId: null, deviceName: null, @@ -701,19 +728,10 @@ row.children.push(obj) }, save(){ - let data = this.dataForm - console.log('--------',data); - console.log("-----",this.list); this.list.forEach(item=>{ item.children.forEach(c=>{ - let arr=c.testValueList - let val='' - arr.forEach(a=>{ - val+=a+"," - }) - let end=val.substring(0,val.length-1) - c.testValue=end + c.testValue=c.testValueList.join(",") }) }) data.rawInsProducts = this.list diff --git a/src/views/quality/rawMaterial/rawMaterial-print.vue b/src/views/quality/rawMaterial/rawMaterial-print.vue index a13a09a..c93f0d2 100644 --- a/src/views/quality/rawMaterial/rawMaterial-print.vue +++ b/src/views/quality/rawMaterial/rawMaterial-print.vue @@ -1,326 +1,334 @@ <template> -<div style="word-wrap:break-word;text-justify-trim:punctuation"> - <div class="WordSection1" style="layout-grid:15.6pt;"> - <div align="center"> - <table class="MsoTableGrid" border="1" cellspacing="0" cellpadding="0" width="629" - style="width:620pt;border-collapse:collapse;border:1pt solid windowtext"> - <tbody> - <tr> - <td width="199" rowspan="2" style="width:149.45pt;border:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:12.0pt;font-family:"Arial",sans-serif"><img width="174" - height="58" id="logo" src="../../../../public/img/image001.jpg" - alt="IMG_256"></span></p> - </td> - <td width="226" style="width:169.65pt;border:solid windowtext 1.0pt;border-left: - 1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> +<div> + <div class="page" style="word-wrap:break-word;text-justify-trim:punctuation" :key="i" v-for="(project,i) in projectList"> + <div style="width:100%;height:10pt"></div> + <div class="WordSection1" style="layout-grid:15.6pt;"> + <div align="center"> + <table class="MsoTableGrid" border="1" cellspacing="0" cellpadding="0" width="629" + style="width:620pt;border-collapse:collapse;border:1pt solid windowtext"> + <tbody> + <tr> + <td width="199" rowspan="2" style="width:149.45pt;border:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:12.0pt;font-family:"Arial",sans-serif"><img width="174" + height="58" id="logo" src="../../../../public/img/image001.jpg" + alt="IMG_256"></span></p> + </td> + <td width="226" style="width:169.65pt;border:solid windowtext 1.0pt;border-left: + 1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:10.0pt;font-family:瀹嬩綋">璁板綍鍚嶇О锛氭楠岃褰曡〃</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">Table: Inspection + Record</span></p> + </td> + <td width="204" style="width:152.8pt;border:solid windowtext 1.0pt;border-left: + 1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:10.0pt;font-family:瀹嬩綋">淇濆瓨鏈熼檺锛�</span><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">25</span><span + style="font-size:10.0pt;font-family:瀹嬩綋">骞�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">Storage Life: 25 + years</span></p> + </td> + </tr> + <tr> + <td width="226" style="width:169.65pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; + border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:10.0pt;font-family:瀹嬩綋">璁板綍缂栧彿锛�</span><a name="OLE_LINK1"><span + lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">ZTT/QR-8.6-07</span></a><span + style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">A/0</span><span + style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">Record No.: + ZTT/QR-8.6-07</span></p> + </td> + <td width="204" style="width:152.8pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; + border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:10.0pt;font-family:瀹嬩綋">褰掓。閮ㄩ棬锛氳川閲忎繚璇侀儴</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:10.0pt;font-family:"Arial",sans-serif">Department: QC</span> + </p> + </td> + </tr> + </tbody> + </table> + </div> + <p class="MsoNormal" align="center" style="margin-top:7.8pt;margin-bottom:3pt;text-align:center"> + <span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span> + <span style="font-size:10.0pt;font-family:瀹嬩綋">妫�楠岃褰曡〃</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">-</span> + <span style="font-size:10.0pt;font-family:瀹嬩綋">鏈哄姞宸ヤ欢</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span><span style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Inpection Record-machining </span> + <span style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span> + <span style="font-size:10.0pt;font-family:瀹嬩綋">椤电爜锛�</span> + <span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> Page No.</span> + <span style="font-size:10.0pt;font-family:瀹嬩綋">锛夛細</span> + <span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> + {{i+1}} + </span> + </p> + <div align="center"> + <table class="MsoTableGrid" border="1" cellspacing="0" cellpadding="0" width="628" + style="width:620pt;border-collapse:collapse;border:1pt solid windowtext"> + <tbody> + <tr> + <td width="121" colspan="2" style="width:120pt;height:50pt;border:solid windowtext 1.0pt;padding:1pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">闆朵欢鍚嶇О</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Part Description</span> + </p> + </td> + <td width="127" colspan="5" style="width:95.5pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="project.name"></span> + </p> + </td> + <td width="113" colspan="3" style="width:84.95pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">鍨�</span><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif"> + </span><span style="font-size:9.0pt;font-family:瀹嬩綋">鍙�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Model</span></p> + </td> + <td width="86" colspan="4" style="width:64.65pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="project.specs"></span></p> + </td> + <td width="72" colspan="2" style="width:54.35pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">鍔犲伐鍗曞彿</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Order No.</span></p> + </td> + <td width="128" colspan="3" style="width:96.0pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="project.rmessage.split(',')[0]"></span></p> + </td> + </tr> + <tr> + <td width="101" colspan="2" style="width:110pt;height:50pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.2cm 1.4pt 0.2cm 1.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠屼华鍣�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Inspection + instrument</span></p> + </td> + <td width="127" colspan="5" style="width:95.5pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="deviceStr"></span></p> + </td> + <td width="113" colspan="3" style="width:84.95pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠屾暟閲�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Quantity to + check</span></p> + </td> + <td width="86" colspan="4" style="width:64.65pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="project.number"></span></p> + </td> + <td width="72" colspan="2" style="width:54.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">渚涜揣鍗曚綅</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Supplier</span></p> + </td> + <td width="128" colspan="3" style="width:96.0pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="project.supplier"></span></p> + </td> + </tr> + <tr> + <td width="145" colspan="3" style="width:109.1pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.2cm 0.4pt 0.2cm 0.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠岄」鐩�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Inspection Item</span> + </p> + </td> + <td width="408" colspan="14" style="width:306.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠岀粨鏋滐紙瀹炴祴鍊硷級</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Test result (Measured + value)</span></p> + </td> + <td width="74" rowspan="2" colspan="2" style="width:55.8pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 3.4pt 0.2cm 3.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">鍒ゅ畾</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Conclusion</span></p> + </td> + </tr> + <tr> + <td width="145" colspan="5" style="width:109.1pt;height:40pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.4cm 5.4pt 0.4cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-size:9.0pt;font-family:瀹嬩綋">鎶�鏈姹�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">Technical + Requirement</span></p> + </td> + <td width="59" colspan="4" style="width:44.4pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 4.4pt 0.2cm 4.4pt"> + <div class="MsoNormal" align="center" style="text-align:center"> + <span style="font-size:9.0pt;font-family:瀹嬩綋">鍏樊</span> + <p lang="EN-US" style="font-size:9.0pt;text-align: center;font-family:"Arial",sans-serif">TOL</p> + </div> + </td> + <td width="43" v-for="(item,index) in columnLength" :key="index" colspan="1" style="width:32.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-size:9.0pt;font-family:"Arial",sans-serif">{{(item+(i*columnLength)) | formateNum}}</span></p> + </td> + </tr> + </tbody> + <tbody v-for="(item,index) in project.children" :key="index"> + <tr style="height:19.85pt"> + <td width="85" colspan="2" :rowspan="item.children.length" style="width:63.95pt;border:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-family:瀹嬩綋" v-text="item.rpFather"></span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif"></span></p> + </td> + <td width="60" colspan="3" style="width:65.15pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="item.children[0].rpName"></span></p> + </td> + <td width="59" colspan="4" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="item.children[0].required"></span></p> + </td> + <td width="43" v-for="(val,index) in item.children[0].testValList" :key="index" colspan="1" style="width:32.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">{{val}}</span></p> + </td> + <td width="74" colspan="2" style="width:70pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.1cm 2.4pt 0.1cm 2.4pt;height:19.85pt"> + <p v-if="item.children[0].testState=='1'" class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">鍚堟牸</span></p> + <p v-if="item.children[0].testState=='0'" class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">涓嶅悎鏍�</span></p> + <p v-else class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif"></span></p> + </td> + </tr> + <tr class="pageTr" style="height:19.85pt" v-for="(j,index) in (item.children.slice(1))" :key="index"> + <td width="60" colspan="3" style="width:45.15pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">{{j.rpName}}</span></p> + </td> + <td width="59" colspan="4" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">{{j.required}}</span></p> + </td> + <td width="59" v-for="(testValue,index) in j.testValList" :key="index" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">{{testValue}}</span></p> + </td> + <td width="43" colspan="2" style="width:70pt;border:1pt solid windowtext;padding:0.1cm 2.4pt 0.1cm 2.4pt;height:19.85pt"> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif"> + {{ j.testState | formatState}} + </span> + </p> + </td> + </tr> + </tbody> + <!-- bottom --> + <tr style="height:40.95pt" class="pageTr"> + <td width="145" colspan="3" style="width:109.1pt;border:solid windowtext 1.0pt; + border-top:1pt solid windowtext;padding:0cm 5.4pt 0cm 5.4pt;height:40.95pt"> <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:10.0pt;font-family:瀹嬩綋">璁板綍鍚嶇О锛氭楠岃褰曡〃</span></p> + style="font-family:瀹嬩綋">澶�</span><span lang="EN-US" + style="font-family:"Arial",sans-serif"> + </span><span style="font-family:瀹嬩綋">娉�</span></p> <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">Table: Inspection - Record</span></p> + style="font-family:"Arial",sans-serif">Remark</span></p> </td> - <td width="204" style="width:152.8pt;border:solid windowtext 1.0pt;border-left: - 1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:10.0pt;font-family:瀹嬩綋">淇濆瓨鏈熼檺锛�</span><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">25</span><span - style="font-size:10.0pt;font-family:瀹嬩綋">骞�</span></p> + <td width="483" colspan="16" style="width:362.15pt;border-top:1pt solid windowtext;border-left: + 1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt;height:40.95pt"> <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">Storage Life: 25 - years</span></p> + style="font-family:"Arial",sans-serif"> </span></p> </td> </tr> <tr> - <td width="226" style="width:169.65pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; - border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <td width="145" colspan="3" style="width:109.1pt;border:none; + border-top:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:10.0pt;font-family:瀹嬩綋">璁板綍缂栧彿锛�</span><a name="OLE_LINK1"><span - lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">ZTT/QR-8.6-07</span></a><span - style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">A/0</span><span - style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span></p> + style="font-family:瀹嬩綋">妫�楠屽憳</span></p> <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">Record No.: - ZTT/QR-8.6-07</span></p> + style="font-family:"Arial",sans-serif">Inspector</span></p> </td> - <td width="204" style="width:152.8pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; - border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:10.0pt;font-family:瀹嬩綋">褰掓。閮ㄩ棬锛氳川閲忎繚璇侀儴</span></p> + <td width="120" colspan="4" style="width:90.25pt;border-top:1pt solid windowtext;border-left: + 1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt"> <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:10.0pt;font-family:"Arial",sans-serif">Department: QC</span> + style="font-family:"Arial",sans-serif" v-text="tableData.createUser"></span></p> + </td> + <td width="82" colspan="4" style="width:61.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; + border-bottom:none;border-right:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span + style="font-family:瀹嬩綋">鏃�</span><span lang="EN-US" + style="font-family:"Arial",sans-serif"> + </span><span style="font-family:瀹嬩綋">鏈�</span></p> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif">Date</span></p> + </td> + <td width="80" colspan="3" style="width:60.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; + border-bottom:none;border-right:solid windowtext 1.0pt; + padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" + style="font-family:"Arial",sans-serif" v-text="tableData.creatTime.split(' ')[0]"></span></p> + </td> + <td width="83" dis colspan="3" style="width:62.25pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"> + <span style="font-family:瀹嬩綋">瀹�</span> + <span lang="EN-US" style="font-family:"Arial",sans-serif"> </span> + <span style="font-family:瀹嬩綋">鏍�</span> + </p> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif">Audit</span> + </p> + </td> + <td width="117" colspan="2" style="width:88.1pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> + <p class="MsoNormal" align="center" style="text-align:center"> + <span lang="EN-US" style="font-family:"Arial",sans-serif"> </span> </p> </td> </tr> - </tbody> + <tr height="0"> + <td width="85" style="border:none"></td> + <td width="16" style="border:none"></td> + <td width="44" style="border:none"></td> + <td width="59" style="border:none"></td> + <td width="23" style="border:none"></td> + <td width="19" style="border:none"></td> + <td width="18" style="border:none"></td> + <td width="27" style="border:none"></td> + <td width="43" style="border:none"></td> + <td width="6" style="border:none"></td> + <td width="6" style="border:none"></td> + <td width="32" style="border:none"></td> + <td width="43" style="border:none"></td> + <td width="6" style="border:none"></td> + <td width="40" style="border:none"></td> + <td width="32" style="border:none"></td> + <td width="11" style="border:none"></td> + <td width="43" style="border:none"></td> + <td width="74" style="border:none"></td> + </tr> </table> </div> - <p class="MsoNormal" align="center" style="margin-top:7.8pt;margin-bottom:3pt;text-align:center"> - <span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span> - <span style="font-size:10.0pt;font-family:瀹嬩綋">妫�楠岃褰曡〃</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">-</span> - <span style="font-size:10.0pt;font-family:瀹嬩綋">鏈哄姞宸ヤ欢</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span><span style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif">Inpection Record-machining </span> - <span style="font-size:10.0pt;font-family:瀹嬩綋">锛�</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span> - <span style="font-size:10.0pt;font-family:瀹嬩綋">椤电爜锛�</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> Page No.</span><span style="font-size:10.0pt;font-family:瀹嬩綋">锛夛細</span><span lang="EN-US" style="font-size:10.0pt;font-family:"Arial",sans-serif"> </span> - </p> - <div align="center"> - <table class="MsoTableGrid" border="1" cellspacing="0" cellpadding="0" width="628" - style="width:620pt;border-collapse:collapse;border:1pt solid windowtext"> - <tbody> - <tr> - <td width="121" colspan="2" style="width:120pt;height:50pt;border:solid windowtext 1.0pt;padding:1pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">闆朵欢鍚嶇О</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Part Description</span> - </p> - </td> - <td width="127" colspan="5" style="width:95.5pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif" v-text="tableData.name"></span> - </p> - </td> - <td width="113" colspan="3" style="width:84.95pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">鍨�</span><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif"> - </span><span style="font-size:9.0pt;font-family:瀹嬩綋">鍙�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Model</span></p> - </td> - <td width="86" colspan="4" style="width:64.65pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.specs"></span></p> - </td> - <td width="72" colspan="2" style="width:54.35pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">鍔犲伐鍗曞彿</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Order No.</span></p> - </td> - <td width="128" colspan="3" style="width:96.0pt;border:solid windowtext 1.0pt;border-left:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.rmessage.split(',')[0]"></span></p> - </td> - </tr> - <tr> - <td width="101" colspan="2" style="width:110pt;height:50pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.2cm 1.4pt 0.2cm 1.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠屼华鍣�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Inspection - instrument</span></p> - </td> - <td width="127" colspan="5" style="width:95.5pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="deviceStr"></span></p> - </td> - <td width="113" colspan="3" style="width:84.95pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠屾暟閲�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Quantity to - check</span></p> - </td> - <td width="86" colspan="4" style="width:64.65pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.number"></span></p> - </td> - <td width="72" colspan="2" style="width:54.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">渚涜揣鍗曚綅</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Supplier</span></p> - </td> - <td width="128" colspan="3" style="width:96.0pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.supplier"></span></p> - </td> - </tr> - <tr> - <td width="145" colspan="3" style="width:109.1pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.2cm 0.4pt 0.2cm 0.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠岄」鐩�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Inspection Item</span> - </p> - </td> - <td width="408" colspan="15" style="width:306.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">妫�楠岀粨鏋滐紙瀹炴祴鍊硷級</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Test result (Measured - value)</span></p> - </td> - <td width="74" rowspan="2" style="width:55.8pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 3.4pt 0.2cm 3.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">鍒ゅ畾</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Conclusion</span></p> - </td> - </tr> - <tr> - <td width="145" colspan="3" style="width:109.1pt;height:40pt;border:solid windowtext 1.0pt;border-top:1pt solid windowtext;padding:0.4cm 5.4pt 0.4cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-size:9.0pt;font-family:瀹嬩綋">鎶�鏈姹�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">Technical - Requirement</span></p> - </td> - <td width="59" colspan="3" style="width:44.4pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 4.4pt 0.2cm 4.4pt"> - <div class="MsoNormal" align="center" style="text-align:center"> - <span style="font-size:9.0pt;font-family:瀹嬩綋">鍏樊</span> - <p lang="EN-US" style="font-size:9.0pt;text-align: center;font-family:"Arial",sans-serif">TOL</p> - </div> - </td> - <td width="43" v-for="(item,index) in columnLength" :key="index" colspan="1" style="width:32.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-size:9.0pt;font-family:"Arial",sans-serif">{{item>9?item:'0'+item}}</span></p> - </td> - </tr> - </tbody> - <tbody v-for="(item,index) in projectList" :key="index"> - <tr style="height:19.85pt"> - <td width="85" :rowspan="item.children.length" style="width:63.95pt;border:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-family:瀹嬩綋" v-text="item.rpFather"></span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif"></span></p> - </td> - <td width="60" colspan="2" style="width:65.15pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="item.children[0].rpName"></span></p> - </td> - <td width="59" colspan="3" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="item.children[0].required"></span></p> - </td> - <td width="43" v-for="(val,index) in item.children[0].testValueList" :key="index" colspan="1" style="width:32.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">{{val}}</span></p> - </td> - <td width="74" style="width:70pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0.1cm 2.4pt 0.1cm 2.4pt;height:19.85pt"> - <p v-if="item.children[0].testState=='1'" class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">鍚堟牸</span></p> - <p v-if="item.children[0].testState=='0'" class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">涓嶅悎鏍�</span></p> - <p v-else class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif"></span></p> - </td> - </tr> - <tr class="pageTr" style="height:19.85pt" v-for="(j,index) in (item.children.slice(1))" :key="index"> - <td width="60" colspan="2" style="width:45.15pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">{{j.rpName}}</span></p> - </td> - <td width="59" colspan="3" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">{{j.required}}</span></p> - </td> - <td width="59" v-for="(testValue,index) in j.testValueList" :key="index" style="width:44.4pt;border:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">{{testValue}}</span></p> - </td> - <td width="43" colspan="1" style="width:70pt;border:1pt solid windowtext;padding:0.1cm 2.4pt 0.1cm 2.4pt;height:19.85pt"> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif"> - {{ j.testState | formatState}} - </span> - </p> - </td> - </tr> - </tbody> - <!-- bottom --> - <tr style="height:40.95pt" class="pageTr"> - <td width="145" colspan="3" style="width:109.1pt;border:solid windowtext 1.0pt; - border-top:1pt solid windowtext;padding:0cm 5.4pt 0cm 5.4pt;height:40.95pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-family:瀹嬩綋">澶�</span><span lang="EN-US" - style="font-family:"Arial",sans-serif"> - </span><span style="font-family:瀹嬩綋">娉�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">Remark</span></p> - </td> - <td width="483" colspan="16" style="width:362.15pt;border-top:1pt solid windowtext;border-left: - 1pt solid windowtext;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt;height:40.95pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif"> </span></p> - </td> - </tr> - <tr> - <td width="145" colspan="3" style="width:109.1pt;border:none; - border-top:1pt solid windowtext;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-family:瀹嬩綋">妫�楠屽憳</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">Inspector</span></p> - </td> - <td width="120" colspan="4" style="width:90.25pt;border-top:1pt solid windowtext;border-left: - 1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.createUser"></span></p> - </td> - <td width="82" colspan="4" style="width:61.35pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; - border-bottom:none;border-right:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span - style="font-family:瀹嬩綋">鏃�</span><span lang="EN-US" - style="font-family:"Arial",sans-serif"> - </span><span style="font-family:瀹嬩綋">鏈�</span></p> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif">Date</span></p> - </td> - <td width="80" colspan="3" style="width:60.2pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext; - border-bottom:none;border-right:solid windowtext 1.0pt; - padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"><span lang="EN-US" - style="font-family:"Arial",sans-serif" v-text="tableData.creatTime.split(' ')[0]"></span></p> - </td> - <td width="83" colspan="3" style="width:62.25pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"> - <span style="font-family:瀹嬩綋">瀹�</span> - <span lang="EN-US" style="font-family:"Arial",sans-serif"> </span> - <span style="font-family:瀹嬩綋">鏍�</span> - </p> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif">Audit</span> - </p> - </td> - <td width="117" colspan="2" style="width:88.1pt;border-top:1pt solid windowtext;border-left:1pt solid windowtext;border-bottom:none;border-right:solid windowtext 1.0pt;padding:0.2cm 5.4pt 0.2cm 5.4pt"> - <p class="MsoNormal" align="center" style="text-align:center"> - <span lang="EN-US" style="font-family:"Arial",sans-serif"> </span> - </p> - </td> - </tr> - <tr height="0"> - <td width="85" style="border:none"></td> - <td width="16" style="border:none"></td> - <td width="44" style="border:none"></td> - <td width="59" style="border:none"></td> - <td width="23" style="border:none"></td> - <td width="19" style="border:none"></td> - <td width="18" style="border:none"></td> - <td width="27" style="border:none"></td> - <td width="43" style="border:none"></td> - <td width="6" style="border:none"></td> - <td width="6" style="border:none"></td> - <td width="32" style="border:none"></td> - <td width="43" style="border:none"></td> - <td width="6" style="border:none"></td> - <td width="40" style="border:none"></td> - <td width="32" style="border:none"></td> - <td width="11" style="border:none"></td> - <td width="43" style="border:none"></td> - <td width="74" style="border:none"></td> - </tr> - </table> - </div> - <p class="MsoNormal"><span lang="EN-US"> </span></p> + <p class="MsoNormal"><span lang="EN-US"> </span></p> + </div> </div> </div> </template> @@ -335,13 +343,26 @@ } } }, + created(){ + this.tableData = this.formData + this.initData() + }, + watch:{ + formData(newVal){ + if(newVal){ + this.projectList = [] + this.tableData = newVal + this.initData() + } + } + }, data(){ return{ tableData: null, projectList: [], deviceStr: null, childrenData: [], - columnLength: 12, + columnLength: 8, } }, filters:{ @@ -356,26 +377,82 @@ return null } return null + }, + formateNum(val){ + if(val!=null && val < 10){ + return '0'+val + } + return val } }, methods:{ initData(){ let deviceNameList = [] + let maxLen = 0 + let pageSize = 0 if(this.tableData.children){ this.tableData.children.forEach(e => { - this.projectList.push(e) if(e.children){ e.children.forEach(o =>{ + if(o.testValue){ + let testValList = o.testValue.split(",") + if( testValList.length > maxLen){ + maxLen = testValList.length + } + } if(o.deviceName){ deviceNameList.push(o.deviceName) } }) } - }); + }) + pageSize = Math.ceil(Number(maxLen)/Number(this.columnLength)) + this.tableData.children.forEach(ele=>{ + if(ele.children){ + ele.children.forEach(obj =>{ + let testValList = [] + if(obj.testValue){ + testValList = obj.testValue.split(",") + } + let size = (this.columnLength*pageSize) - (testValList.length) + obj.testValList = testValList + for(var i=0;i<size;i++){ + obj.testValList.push('') + } + }) + } + }) } + this.pageDataFun(pageSize,this.tableData) this.deviceStr = Array.from(new Set(deviceNameList)).join(",") }, - initProjectList(list){ + //鑾峰彇姣忛〉鐨勬楠岄」鐩� + pageDataFun(pageSize,data){ + let tabData = [] + if(pageSize>0 && data){ + for(var i=0;i<pageSize;i++){ + let obj = JSON.parse(JSON.stringify(data)) + if(obj.children){ + obj.children.forEach(o=>{ + if(o.children){ + o.children.forEach(e=>{ + if(e.testValList){ + let colLen = this.columnLength + let start = colLen*i + let end = ((1+i)*colLen) + e.testValList = e.testValList.slice(start,end) + tabData.push(obj) + } + }) + } + }) + this.initRow(obj.children) + } + } + } + this.projectList = tabData + }, + initRow(list){ const data = { deviceId: '', deviceName: '', @@ -384,27 +461,13 @@ rpUnit: '', testState: null, userName: '', - testValueList: new Array(this.columnLength) + testValList: new Array(this.columnLength) } let rowNum = 15 - let columnNum = this.columnLength if(list && list.length<2){ list.forEach(item=>{ if(item.children && item.children.length < rowNum){ rowNum-=item.children.length - for(let j=0;j<item.children.length;j++){ - let arr = [] - if(item.children[j].testValue){ - arr = item.children[j].testValue.split(",") - } - item.children[j].testValueList = arr - if(item.children[0].testValueList.length< columnNum ){ - let num = columnNum - item.children[j].testValueList.length - for(let i=0;i<num;i++){ - item.children[j].testValueList.push("") - } - } - } for(let i=0;i< rowNum;i++){ item.children.push(data) } @@ -415,20 +478,6 @@ list.forEach(item=>{ if(item.children){ size+=item.children.length - item.children.forEach(obj=>{ - if(obj.testValue){ - let testValueList = obj.testValue.split(",") - obj.testValueList = testValueList - if(testValueList.length < columnNum){ - let len = columnNum-testValueList.length - for(var i=0;i<len;i++){ - obj.testValueList.push("") - } - } - }else{ - obj.testValueList = new Array(12) - } - }) } }) if(size < rowNum){ @@ -438,24 +487,8 @@ } } } - this.projectList = list - } + }, }, - created(){ - this.tableData = this.formData - this.initData() - this.initProjectList(this.projectList) - }, - watch:{ - formData(newVal){ - if(newVal){ - this.projectList = [] - this.tableData = newVal - this.initData() - this.initProjectList(this.projectList) - } - } - } } </script> @@ -493,6 +526,9 @@ .pageTr{ page-break-inside: avoid; } +.page{ + page-break-inside: avoid; +} div.WordSection1{ page : WordSection1; } diff --git a/src/views/quality/teststandard/index.vue b/src/views/quality/teststandard/index.vue index 709f3b4..a8481fb 100644 --- a/src/views/quality/teststandard/index.vue +++ b/src/views/quality/teststandard/index.vue @@ -78,7 +78,7 @@ align="center" width="50" /> - <el-table-column + <!-- <el-table-column label="鏄惁寮曠敤宸ヨ壓鍙傛暟" prop="isReference" align="center" @@ -125,7 +125,7 @@ <template slot-scope="scope"> <el-input v-model="scope.row.wireCore"></el-input> </template> - </el-table-column> + </el-table-column> --> <el-table-column label="鍙傛暟缂栧彿" prop="code" align="center" /> <el-table-column label="鍙傛暟椤�" @@ -188,8 +188,28 @@ <template slot-scope="scope"> <el-input v-model="scope.row.parameterFormat"></el-input> </template> + </el-table-column><el-table-column + label="娴嬭瘯鏂规硶" + prop="purpose" + align="center" + width="80" + > + <template slot-scope="scope"> + <el-input v-model="scope.row.purpose"></el-input> + </template> </el-table-column> <el-table-column + label="娴嬭瘯鐩殑" + prop="method" + align="center" + width="80" + > + <template slot-scope="scope"> + <el-input v-model="scope.row.method"></el-input> + </template> + </el-table-column> + + <!-- <el-table-column label="閫氶亾" prop="aisle" align="center" @@ -208,7 +228,7 @@ <template slot-scope="scope"> <el-input v-model="scope.row.position"></el-input> </template> - </el-table-column> + </el-table-column> --> <el-table-column label="鍗曚綅" prop="unit" align="center" /> <!--<el-table-column label="鍙傛暟绫诲瀷" prop="type" align="center" :formatter="getParam"/>--> <el-table-column label="鎿嶄綔" align="center"> @@ -220,13 +240,13 @@ v-if="editable" >鎻掑叆 </el-button> - <el-button + <!-- <el-button type="text" size="mini" @click.stop="editTestStandardParam(scope.row)" v-if="editable && scope.row.id != null" >鍏紡 - </el-button> + </el-button> --> <el-button type="text" size="mini" diff --git a/src/views/quality/teststandard/standard-form.vue b/src/views/quality/teststandard/standard-form.vue index 4abc0be..3b0cbde 100644 --- a/src/views/quality/teststandard/standard-form.vue +++ b/src/views/quality/teststandard/standard-form.vue @@ -155,6 +155,23 @@ ZttMonacoEditor, operationDialog }, + watch:{ + visible(newVal){ + if(!newVal){ + this.dataForm = { + id: 0, + standardName: '', + standardNo: '', + remark: '', + judgeFormula: '', + inspectionType: null, + operationId: null, + operationNo: null, + operationName: null, + } + } + } + }, created() { this.funcs = funcForStandard() this.constants = constantForStandard() @@ -197,11 +214,11 @@ if (this.dataForm.id) { getTestStandard(this.dataForm.id).then((response) => { this.dataForm = response.data.data - this.$refs.templateJudgmentCondition.setVal( - this.dataForm.judgeFormula == null - ? '' - : this.dataForm.judgeFormula - ) + // this.$refs.templateJudgmentCondition.setVal( + // this.dataForm.judgeFormula == null + // ? '' + // : this.dataForm.judgeFormula + // ) }) this.params = [] getTestStandardParams( @@ -237,162 +254,163 @@ // 琛ㄥ崟鎻愪氦 dataFormSubmit() { this.isSubmit = true - // 鏍¢獙鍒ゅ畾鍏紡 - let judgeFormula = this.$refs.templateJudgmentCondition.getVal() - // 鏇挎崲鍏紡涓殑pi甯搁噺涓�3.14 - if (judgeFormula.length > 0) { - const piExistIndex = judgeFormula.indexOf('pi') - if (piExistIndex >= 0) { - judgeFormula = judgeFormula.replace(/pi/g, '3.14') - } - } - // 鏇挎崲鍏紡涓殑passAll()鍑芥暟涓簍rue - if (judgeFormula.length > 0) { - const piExistIndex = judgeFormula.indexOf('passAll()') - if (piExistIndex >= 0) { - judgeFormula = judgeFormula.replace(/passAll[(][)]/g, 'true') - } - } - // 鍏堝垽瀹氬叕寮忎腑鍑芥暟鏍煎紡鏄惁姝g‘锛屽啀鐢ㄩ粯璁ゅ�艰绠楀嚭鍑芥暟鍊硷紝鏇挎崲杩涘叕寮忥紝鏈�鍚庡皢鍏紡涓墿浣欑殑鍙傛暟杩涜榛樿鍊兼浛鎹紝鍒╃敤js eval鍑芥暟杩涜鍏紡鏍¢獙 - let flag = true - let funcEl - for (let j = 0; j < this.funcs.length; j++) { - funcEl = this.funcs[j] - // 璁$畻鍑芥暟鍏抽敭鍦ㄥ叕寮忎腑鍑虹幇鐨勬鏁� - const num = this.getNumCharInStr(judgeFormula, funcEl.name, 0) - // for寰幆娆℃暟鏍¢獙鏇挎崲 - for (let k = 0; k < num; k++) { - const existIndex = judgeFormula.indexOf(funcEl.name) - if (existIndex >= 0) { - // 鍑芥暟鍏抽敭瀛楀湪鍏紡涓瓨鍦� - const prefixStr = judgeFormula.substring(0, existIndex) - const startToEndStr = judgeFormula.substring( - existIndex + funcEl.name.length - ) - if (startToEndStr.length > 0) { - const paramStartIndex = startToEndStr.indexOf('(') - const paramEndIndex = startToEndStr.indexOf(')') - if (paramStartIndex === 0 && paramEndIndex > 0) { - const suffixStr = startToEndStr.substring(paramEndIndex + 1) - const paramStr = startToEndStr.substring( - paramStartIndex + 1, - paramEndIndex - ) - if (paramStr.trim() !== '') { - const paramArr = paramStr.split(',') - if (paramArr.length > 0) { - if ( - (funcEl.singleParam && paramArr.length === 1) || - !funcEl.singleParam - ) { - let paramFlag = true - for (let i = 0; i < paramArr.length; i++) { - const param = this.params.find( - (item) => - paramArr[i].trim() === 'V[' + item.code + ']' - ) - if (param !== undefined) { - } else { - flag = false - paramFlag = false - this.$message.error('鍑芥暟鍙傛暟涓嶅瓨鍦�') - } - } - if (paramFlag) { - if (funcEl.returnType === 'number') { - judgeFormula = prefixStr + '1' + suffixStr - } else { - judgeFormula = prefixStr + 'true' + suffixStr - } - } else { - break - } - } else { - flag = false - this.$message.error('鍑芥暟鍙傛暟涓暟涓嶆纭�') - break - } - } else { - break - } - } else { - flag = false - this.$message.error('鍑芥暟蹇呴』瑕佹湁鍙傛暟') - break - } - } else { - flag = false - this.$message.error( - '鍑芥暟闇�鍖呭惈宸﹀彸灏忔嫭鍙凤紝涓斿乏渚у皬鎷彿闇�绱ч偦鍑芥暟' - ) - break - } - } else { - flag = false - this.$message.error('鍑芥暟闇�鍖呭惈宸﹀彸灏忔嫭鍙�') - break - } - } - } - } - if (flag) { - // 灏嗗叕寮忎腑鍓╀綑鐨勫弬鏁拌繘琛岄粯璁ゅ�兼浛鎹� - let param - for (let x = 0; x < this.params.length; x++) { - param = this.params[x] - // 璁$畻鍙傛暟鍦ㄥ叕寮忎腑鍑虹幇鐨勬鏁� - const num = this.getNumCharInStr( - judgeFormula, - 'V[' + param.code + ']', - 0 - ) - // for寰幆娆℃暟鏍¢獙鏇挎崲 - for (let y = 0; y < num; y++) { - const existIndex = judgeFormula.indexOf('V[' + param.code + ']') - if (existIndex >= 0) { - const prefixStr = judgeFormula.substring(0, existIndex) - const suffixStr = judgeFormula.substring( - existIndex + ('V[' + param.code + ']').length - ) - judgeFormula = prefixStr + this.getRandom() + suffixStr - } - } - } - try { - eval(judgeFormula) - } catch (exception) { - flag = false - } - if (flag) { - this.dataForm.judgeFormula = this.$refs.templateJudgmentCondition.getVal() - this.$refs.dataForm.validate((valid) => { - if (valid) { - if (this.dataForm.id) { - putTestStandard(this.dataForm).then((data) => { - this.$message.success('淇敼鎴愬姛') - this.visible = false - this.isSubmit = false - this.$emit('refreshDataList') - }) - } else { - addTestStandard(this.dataForm).then((data) => { - this.$message.success('娣诲姞鎴愬姛') - this.visible = false - this.isSubmit = false - this.$emit('refreshDataList') - }) - } - } else { + this.$refs.dataForm.validate((valid) => { + if (valid) { + if (this.dataForm.id) { + putTestStandard(this.dataForm).then((data) => { + this.$message.success('淇敼鎴愬姛') + this.visible = false this.isSubmit = false - } - }) + this.$emit('refreshDataList') + }) + } else { + addTestStandard(this.dataForm).then((data) => { + this.$message.success('娣诲姞鎴愬姛') + this.visible = false + this.isSubmit = false + this.$emit('refreshDataList') + }) + } } else { this.isSubmit = false - this.$message.error('鍏紡鏍煎紡閿欒锛岃浠旂粏妫�鏌�') } - } else { - this.isSubmit = false - } + }) + // 鏍¢獙鍒ゅ畾鍏紡 + // let judgeFormula = this.$refs.templateJudgmentCondition.getVal() + // // 鏇挎崲鍏紡涓殑pi甯搁噺涓�3.14 + // if (judgeFormula.length > 0) { + // const piExistIndex = judgeFormula.indexOf('pi') + // if (piExistIndex >= 0) { + // judgeFormula = judgeFormula.replace(/pi/g, '3.14') + // } + // } + // // 鏇挎崲鍏紡涓殑passAll()鍑芥暟涓簍rue + // if (judgeFormula.length > 0) { + // const piExistIndex = judgeFormula.indexOf('passAll()') + // if (piExistIndex >= 0) { + // judgeFormula = judgeFormula.replace(/passAll[(][)]/g, 'true') + // } + // } + // // 鍏堝垽瀹氬叕寮忎腑鍑芥暟鏍煎紡鏄惁姝g‘锛屽啀鐢ㄩ粯璁ゅ�艰绠楀嚭鍑芥暟鍊硷紝鏇挎崲杩涘叕寮忥紝鏈�鍚庡皢鍏紡涓墿浣欑殑鍙傛暟杩涜榛樿鍊兼浛鎹紝鍒╃敤js eval鍑芥暟杩涜鍏紡鏍¢獙 + // let flag = true + // let funcEl + // for (let j = 0; j < this.funcs.length; j++) { + // funcEl = this.funcs[j] + // // 璁$畻鍑芥暟鍏抽敭鍦ㄥ叕寮忎腑鍑虹幇鐨勬鏁� + // const num = this.getNumCharInStr(judgeFormula, funcEl.name, 0) + // // for寰幆娆℃暟鏍¢獙鏇挎崲 + // for (let k = 0; k < num; k++) { + // const existIndex = judgeFormula.indexOf(funcEl.name) + // if (existIndex >= 0) { + // // 鍑芥暟鍏抽敭瀛楀湪鍏紡涓瓨鍦� + // const prefixStr = judgeFormula.substring(0, existIndex) + // const startToEndStr = judgeFormula.substring( + // existIndex + funcEl.name.length + // ) + // if (startToEndStr.length > 0) { + // const paramStartIndex = startToEndStr.indexOf('(') + // const paramEndIndex = startToEndStr.indexOf(')') + // if (paramStartIndex === 0 && paramEndIndex > 0) { + // const suffixStr = startToEndStr.substring(paramEndIndex + 1) + // const paramStr = startToEndStr.substring( + // paramStartIndex + 1, + // paramEndIndex + // ) + // if (paramStr.trim() !== '') { + // const paramArr = paramStr.split(',') + // if (paramArr.length > 0) { + // if ( + // (funcEl.singleParam && paramArr.length === 1) || + // !funcEl.singleParam + // ) { + // let paramFlag = true + // for (let i = 0; i < paramArr.length; i++) { + // const param = this.params.find( + // (item) => + // paramArr[i].trim() === 'V[' + item.code + ']' + // ) + // if (param !== undefined) { + // } else { + // flag = false + // paramFlag = false + // this.$message.error('鍑芥暟鍙傛暟涓嶅瓨鍦�') + // } + // } + // if (paramFlag) { + // if (funcEl.returnType === 'number') { + // judgeFormula = prefixStr + '1' + suffixStr + // } else { + // judgeFormula = prefixStr + 'true' + suffixStr + // } + // } else { + // break + // } + // } else { + // flag = false + // this.$message.error('鍑芥暟鍙傛暟涓暟涓嶆纭�') + // break + // } + // } else { + // break + // } + // } else { + // flag = false + // this.$message.error('鍑芥暟蹇呴』瑕佹湁鍙傛暟') + // break + // } + // } else { + // flag = false + // this.$message.error( + // '鍑芥暟闇�鍖呭惈宸﹀彸灏忔嫭鍙凤紝涓斿乏渚у皬鎷彿闇�绱ч偦鍑芥暟' + // ) + // break + // } + // } else { + // flag = false + // this.$message.error('鍑芥暟闇�鍖呭惈宸﹀彸灏忔嫭鍙�') + // break + // } + // } + // } + // } + // if (flag) { + // // 灏嗗叕寮忎腑鍓╀綑鐨勫弬鏁拌繘琛岄粯璁ゅ�兼浛鎹� + // let param + // for (let x = 0; x < this.params.length; x++) { + // param = this.params[x] + // // 璁$畻鍙傛暟鍦ㄥ叕寮忎腑鍑虹幇鐨勬鏁� + // const num = this.getNumCharInStr( + // judgeFormula, + // 'V[' + param.code + ']', + // 0 + // ) + // // for寰幆娆℃暟鏍¢獙鏇挎崲 + // for (let y = 0; y < num; y++) { + // const existIndex = judgeFormula.indexOf('V[' + param.code + ']') + // if (existIndex >= 0) { + // const prefixStr = judgeFormula.substring(0, existIndex) + // const suffixStr = judgeFormula.substring( + // existIndex + ('V[' + param.code + ']').length + // ) + // judgeFormula = prefixStr + this.getRandom() + suffixStr + // } + // } + // } + // try { + // eval(judgeFormula) + // } catch (exception) { + // flag = false + // } + // if (flag) { + // this.dataForm.judgeFormula = this.$refs.templateJudgmentCondition.getVal() + + // } else { + // this.isSubmit = false + // this.$message.error('鍏紡鏍煎紡閿欒锛岃浠旂粏妫�鏌�') + // } + // } else { + // this.isSubmit = false + // } }, openOperationDialog() { this.showOperate = true diff --git a/src/views/technology/completeproductstructure/completeproductstructure-form.vue b/src/views/technology/completeproductstructure/completeproductstructure-form.vue index 74b5c07..b0931ef 100644 --- a/src/views/technology/completeproductstructure/completeproductstructure-form.vue +++ b/src/views/technology/completeproductstructure/completeproductstructure-form.vue @@ -75,32 +75,26 @@ </el-input> </el-form-item> - <el-form-item label="鏇夸唬鍙�" prop="alternativeNo"> + <!-- <el-form-item label="鏇夸唬鍙�" prop="alternativeNo"> <el-input v-model="treeForm.alternativeNo" placeholder="鏇夸唬鍙�" disabled > </el-input> - </el-form-item> + </el-form-item> --> - <el-form-item label="鏇夸唬鎻忚堪" prop="alternativeDesc"> + <!-- <el-form-item label="鏇夸唬鎻忚堪" prop="alternativeDesc"> <el-input v-model="treeForm.alternativeDesc" placeholder="鏇夸唬鎻忚堪" disabled > </el-input> - </el-form-item> + </el-form-item> --> - <el-form-item label="缁濈紭棰滆壊"> - <el-input - v-model="treeForm.insulationColor" - placeholder="缁濈紭棰滆壊" - > - </el-input> - </el-form-item> - <el-form-item label="鎶ゅ棰滆壊"> + <!-- --> + <!-- <el-form-item label="鎶ゅ棰滆壊"> <el-input v-model="treeForm.sheathColor" placeholder="鎶ゅ棰滆壊"> </el-input> </el-form-item> @@ -110,7 +104,7 @@ placeholder="鐗规��1" > </el-input> - </el-form-item> + </el-form-item> --> </el-col> </el-row> </el-form> @@ -134,7 +128,7 @@ <el-table-column label="闆朵欢鍚嶇О" prop="partName"></el-table-column> <el-table-column label="鍗曚綅" prop="unit"></el-table-column> <el-table-column label="鏁伴噺" prop="qpa"></el-table-column> - <el-table-column label="鐩樻暟" prop="discNum"></el-table-column> + <!-- <el-table-column label="鐩樻暟" prop="discNum"></el-table-column> --> </el-table> <!-- <el-table class="tree-select-table" diff --git a/src/views/technology/completeproductstructure/index.vue b/src/views/technology/completeproductstructure/index.vue index 4af4a00..1be5f56 100644 --- a/src/views/technology/completeproductstructure/index.vue +++ b/src/views/technology/completeproductstructure/index.vue @@ -20,12 +20,13 @@ import { fetchList, delObj, - addByStructure + addByStructure, } from '@/api/technology/completeproductstructure' import ttable from '@/views/common/ztt-table.vue' import { mapGetters } from 'vuex' import { changeState } from '../../../api/technology/completeproductstructure' import { remote } from '@/api/admin/dict' + export default { data() { return { @@ -34,7 +35,7 @@ uploadInfo: { // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, - url: 'mes/bom/uploadExcel' + url: 'mes/bom/uploadExcel', }, prelang: 'completeProductStructure', options: { @@ -49,7 +50,7 @@ isRefresh: true, // 鏄惁鏄剧ず鍒锋柊鎸夐挳 isShowHide: true, // 鏄惁鏄剧ず鏄惧奖鎸夐挳 isSearch: false, // 楂樼骇鏌ヨ鎸夐挳 - defaultOrderBy: { column: 'id', direction: 'desc' } + defaultOrderBy: { column: 'id', direction: 'desc' }, }, table: { total: 0, @@ -67,7 +68,7 @@ isTrue: true, isSearch: true, searchInfoType: 'text', - render: { fun: this.addOrUpdateHandle } + render: { fun: this.addOrUpdateHandle }, }, // 闆朵欢鍚嶇О { @@ -77,7 +78,7 @@ sort: true, isTrue: true, isSearch: true, - searchInfoType: 'text' + searchInfoType: 'text', }, // 闆朵欢鍙� { @@ -87,7 +88,7 @@ sort: true, isTrue: true, isSearch: true, - searchInfoType: 'text' + searchInfoType: 'text', }, // 鐘舵�� @@ -112,7 +113,7 @@ formatVal = '宸插彇娑�' } return formatVal - } + }, }, // 绫诲瀷 @@ -127,7 +128,7 @@ formatter: this.formatBomTypeDbType, optList: () => { return this.bomTypeDbOptions - } + }, }, // 鐗堟湰鍙� { @@ -137,61 +138,61 @@ sort: true, isTrue: true, isSearch: true, - searchInfoType: 'text' + searchInfoType: 'text', }, // 鏇夸唬鍙� - { - minWidth: '120', - prop: 'alternativeNo', - label: '鏇夸唬鍙�', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text' - }, + // { + // minWidth: '120', + // prop: 'alternativeNo', + // label: '鏇夸唬鍙�', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'text', + // }, // 鏇夸唬鎻忚堪 - { - minWidth: '120', - prop: 'alternativeDesc', - label: '鏇夸唬鎻忚堪', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text' - }, + // { + // minWidth: '120', + // prop: 'alternativeDesc', + // label: '鏇夸唬鎻忚堪', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'text', + // }, // 缁濈紭棰滆壊 - { - minWidth: '120', - prop: 'insulationColor', - label: '缁濈紭棰滆壊', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text' - }, + // { + // minWidth: '120', + // prop: 'insulationColor', + // label: '缁濈紭棰滆壊', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'text', + // }, // 鎶ゅ棰滆壊 - { - minWidth: '120', - prop: 'sheathColor', - label: '鎶ゅ棰滆壊', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text' - }, + // { + // minWidth: '120', + // prop: 'sheathColor', + // label: '鎶ゅ棰滆壊', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'text', + // }, // 鐗规��1 - { - minWidth: '120', - prop: 'characteristicOne', - label: '鐗规��1', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text' - }, + // { + // minWidth: '120', + // prop: 'characteristicOne', + // label: '鐗规��1', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'text', + // }, // 鍒涘缓浜� { minWidth: '120', @@ -200,7 +201,7 @@ sort: true, isTrue: true, isSearch: true, - searchInfoType: 'text' + searchInfoType: 'text', }, // 鍒涘缓鏃堕棿 { @@ -210,8 +211,8 @@ sort: true, isTrue: true, isSearch: true, - searchInfoType: 'datetimerange' - } + searchInfoType: 'datetimerange', + }, ], toolbar: [ // { @@ -226,7 +227,7 @@ text: '浜у搧缁撴瀯鐢熸垚BOM', fun: this.addByStructureHandle, disabled: false, - permitArr: [] + permitArr: [], }, { text: '鎵瑰噯', @@ -234,7 +235,7 @@ this.approveHandle('ACCEPT') }, disabled: false, - permitArr: ['01draft'] + permitArr: ['01draft'], }, { text: '鎾ゅ洖', @@ -242,7 +243,7 @@ this.approveHandle('REVOKE') }, disabled: false, - permitArr: ['02accepted'] + permitArr: ['02accepted'], }, { text: '鎷掔粷', @@ -250,7 +251,7 @@ this.approveHandle('CANCEL') }, disabled: false, - permitArr: ['02accepted'] + permitArr: ['02accepted'], }, { text: '鍒犻櫎', @@ -258,46 +259,46 @@ this.deleteAll() }, disabled: false, - permitArr: [] - } + permitArr: [], + }, ], operator: [ { text: '鍒犻櫎', type: 'text', size: 'small', - fun: this.deleteHandle - } + fun: this.deleteHandle, + }, ], operatorConfig: { fixed: 'right', label: '鎿嶄綔', width: 100, - minWidth: 100 - } + minWidth: 100, + }, }, stateOptionList: [ { value: '01draft', - label: '鑽夌' + label: '鑽夌', }, { value: '02accepted', - label: '宸叉帴鍙�' + label: '宸叉帴鍙�', }, { value: '03cancelled', - label: '宸插彇娑�' - } + label: '宸插彇娑�', + }, ], - bomTypeDbOptions: [] + bomTypeDbOptions: [], } }, components: { - ttable + ttable, }, computed: { - ...mapGetters(['permissions']) + ...mapGetters(['permissions']), }, activated() { this.getData() @@ -334,16 +335,20 @@ addOrUpdateHandle(row) { this.$router.push({ name: 'completeProductStructure', - params: { id: row == null ? null : row.id } + params: { id: row == null ? null : row.id }, }) }, // 鎸変骇鍝佺粨鏋勭敓鎴怋OM addByStructureHandle() { - addByStructure() - this.$message({ - message: '宸插湪鍚庡彴鐢熸垚BOM锛岃鎵ц缁撴潫鍚庡埛鏂伴〉闈�', - type: 'success' + addByStructure().then((res) => { + let result = Array.from(new Set(res.data.data)) + this.$message.success(result.join(',')) + this.getData() }) + // this.$message({ + // message: '宸插湪鍚庡彴鐢熸垚BOM锛岃鎵ц缁撴潫鍚庡埛鏂伴〉闈�', + // type: 'success', + // }) }, // 鍒犻櫎 deleteHandle(row) { @@ -351,9 +356,9 @@ confirmButtonText: '纭畾', cancelButtonText: '鍙栨秷', type: 'warning', - closeOnClickModal: false + closeOnClickModal: false, }) - .then(function() { + .then(function () { const ids = [] ids.push(row.id) return delObj(ids) @@ -375,9 +380,9 @@ confirmButtonText: '纭畾', cancelButtonText: '鍙栨秷', type: 'warning', - closeOnClickModal: false + closeOnClickModal: false, }) - .then(function() { + .then(function () { const ids = that.multipleSelection.map((item) => { return item.id }) @@ -428,7 +433,7 @@ handleSelectionChange(val) { // 鏍规嵁鐘舵�侊紝绂佺敤琛ㄥご鎸夐挳 // 绛涢�夊嚭閫変腑璁板綍鐨勭姸鎬� - var stateArr = val.map(function(value, index) { + var stateArr = val.map(function (value, index) { return value.state }) // 閫変腑鐘舵�佹暟缁勫厓绱犲幓閲� @@ -458,7 +463,7 @@ }, getStateOptionList() { return this.stateOptionList - } - } + }, + }, } </script> diff --git a/src/views/technology/operation/index.vue b/src/views/technology/operation/index.vue index 2aa2d7c..70e46eb 100644 --- a/src/views/technology/operation/index.vue +++ b/src/views/technology/operation/index.vue @@ -35,7 +35,7 @@ multipleSelection: [], uploadInfo: { // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl - isShow: true, + isShow: false, url: '/mes/operation/excel/upload' }, prelang: 'operation', @@ -186,19 +186,19 @@ // isSearch: true, // searchInfoType: 'text' // }, - { - minWidth: '120', - prop: 'outsideOpItem', - label: '澶栭儴宸ュ簭椤圭洰', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'select', - formatter: this.formatOutsideOpItem, - optList: () => { - return this.outsideOpItemOptions - } - }, + // { + // minWidth: '120', + // prop: 'outsideOpItem', + // label: '澶栭儴宸ュ簭椤圭洰', + // sort: true, + // isTrue: true, + // isSearch: true, + // searchInfoType: 'select', + // formatter: this.formatOutsideOpItem, + // optList: () => { + // return this.outsideOpItemOptions + // } + // }, // 澶囨敞 { minWidth: '120', diff --git a/src/views/technology/operation/operation-form.vue b/src/views/technology/operation/operation-form.vue index 282dcc6..d6bd9e4 100644 --- a/src/views/technology/operation/operation-form.vue +++ b/src/views/technology/operation/operation-form.vue @@ -120,12 +120,12 @@ /> </el-select> </el-form-item> --> - <!-- <el-form-item label="鐝粍浜哄憳" prop="crewSize"> + <el-form-item label="鐝粍浜哄憳" prop="crewSize"> <el-input v-model="dataForm.crewSize" placeholder="鐝粍浜哄憳" ></el-input> - </el-form-item> --> + </el-form-item> <!-- <el-form-item label="澶栭儴宸ュ簭椤圭洰" prop="outsideOpItem"> <el-select v-model="dataForm.outsideOpItem" @@ -150,7 +150,7 @@ </el-form-item> </el-col> </el-row> - <el-row style="padding-top: 10px"> + <!-- <el-row style="padding-top: 10px"> <el-col :span="24"> <el-form-item label="閰嶇疆椤�"> <el-checkbox-group @@ -182,7 +182,7 @@ </el-checkbox-group> </el-form-item> </el-col> - </el-row> + </el-row> --> </el-form> </div> diff --git a/src/views/technology/routing/edit-routing-operation.vue b/src/views/technology/routing/edit-routing-operation.vue index afeecf0..9823313 100644 --- a/src/views/technology/routing/edit-routing-operation.vue +++ b/src/views/technology/routing/edit-routing-operation.vue @@ -35,7 +35,7 @@ </el-select> </el-form-item> </el-col> - <el-col :span="12"> + <!-- <el-col :span="12"> <el-form-item label="鍥犵礌鍗曚綅" prop="runTimeCodeDb" :rules="disabled ? [{required: false}] : dataRule.runTimeCodeDb"> <el-select v-model="dataForm.runTimeCodeDb" @@ -51,9 +51,9 @@ /> </el-select> </el-form-item> - </el-col> + </el-col> --> </el-row> - <el-row> + <!-- <el-row> <el-col :span="12"> <el-form-item label="鏈哄櫒杩愯浆鍥犵礌" prop="machRunFactor" :rules="disabled ? [{required: false}] : dataRule.machRunFactor"> <el-input @@ -92,7 +92,7 @@ ></el-input> </el-form-item> </el-col> - </el-row> + </el-row> --> <el-row> <el-col :span="12"> <el-form-item label="浜哄伐绫诲埆" prop="laborClassNo"> @@ -124,7 +124,7 @@ </el-col> </el-row> <el-row> - <el-col :span="12"> + <!-- <el-col :span="12"> <el-form-item label="澶栭儴宸ュ簭椤圭洰" prop="outsideOpItem"> <el-select v-model="dataForm.outsideOpItem" @@ -141,7 +141,7 @@ /> </el-select> </el-form-item> - </el-col> + </el-col> --> <el-col :span="12"> </el-col> </el-row> </el-form> diff --git a/src/views/technology/routing/index.vue b/src/views/technology/routing/index.vue index 7b31528..e3d7d29 100644 --- a/src/views/technology/routing/index.vue +++ b/src/views/technology/routing/index.vue @@ -196,7 +196,7 @@ noShowTip: false }, // 鏄惁涓轰富宸ヨ壓 - { + /* { minWidth: '120', prop: 'master', label: '涓诲伐鑹�', @@ -210,7 +210,7 @@ formatter: (row, column, cellValue) => { return cellValue == true ? '鏄�' : '鍚�' } - }, + }, */ // 鐘舵�� { minWidth: '120', @@ -300,7 +300,7 @@ searchInfoType: 'datetimerange' }, // 鏇夸唬 - { + /* { minWidth: '120', prop: 'alternativeNo', label: '鏇夸唬', @@ -308,9 +308,9 @@ isTrue: true, isSearch: true, searchInfoType: 'text' - }, + }, */ // 鏇夸唬鎻忚堪 - { + /* { minWidth: '120', prop: 'alternativeDesc', label: '鏇夸唬鎻忚堪', @@ -318,7 +318,7 @@ isTrue: true, isSearch: true, searchInfoType: 'text' - }, + }, */ // 鏄惁宸插悓姝ヨ嚦IFS // { // minWidth: '120', diff --git a/src/views/technology/routing/routing-form.vue b/src/views/technology/routing/routing-form.vue index b65541c..38698da 100644 --- a/src/views/technology/routing/routing-form.vue +++ b/src/views/technology/routing/routing-form.vue @@ -58,13 +58,13 @@ style="width: 280px" ></el-input> </el-form-item> - <el-form-item prop="wireCore" label="绾胯姱"> + <!-- <el-form-item prop="wireCore" label="绾胯姱"> <el-input v-model="dataForm.wireCore" placeholder="绾胯姱" style="width: 60px" ></el-input> - </el-form-item> + </el-form-item> --> <el-form-item label="BOM" prop="bomId"> <el-select :disabled="dataForm.id != null" v-model="dataForm.bomId" placeholder="" filterable> <el-option @@ -133,9 +133,9 @@ >{{ dataForm.ifsSync ? '鏄�' : '鍚�' }}</span > </el-form-item> --> - <el-form-item label="涓诲伐鑹�" prop="master"> + <!-- <el-form-item label="涓诲伐鑹�" prop="master"> <el-switch v-model="dataForm.master"> </el-switch> - </el-form-item> + </el-form-item> --> </el-col> </el-row> </el-form> @@ -277,13 +277,13 @@ <span v-if="!editable">{{ scope.row.operationName }}</span> </template> </el-table-column> - <el-table-column + <!-- <el-table-column prop="outsideOpItem" label="澶栭儴宸ュ簭椤圭洰" align="center" show-overflow-tooltip > - </el-table-column> + </el-table-column> --> <el-table-column prop="partName" label="闆朵欢" @@ -310,7 +310,7 @@ }}</span> </template> </el-table-column> - <el-table-column + <!-- <el-table-column prop="runTimeCodeDb" label="鍥犵礌鍗曚綅" align="center" @@ -350,7 +350,7 @@ label="鍔冲姏璁剧疆鏃堕棿" align="center" > - </el-table-column> + </el-table-column> --> <el-table-column prop="laborClassNo" label="浜哄伐绫诲埆" @@ -428,7 +428,7 @@ </el-input> </div> - <el-divider content-position="left">閰嶇疆椤�</el-divider> + <!-- <el-divider content-position="left">閰嶇疆椤�</el-divider> <div class="node-content-config"> <el-checkbox-group @@ -462,7 +462,7 @@ >宸ュ崟棰勭暀</el-checkbox-button > </el-checkbox-group> - </div> + </div> --> <!-- <el-divider content-position="left">鑳藉姏</el-divider> <div class="node-content"> diff --git a/src/views/technology/structure/index.vue b/src/views/technology/structure/index.vue index 996ffb6..74037af 100644 --- a/src/views/technology/structure/index.vue +++ b/src/views/technology/structure/index.vue @@ -235,7 +235,7 @@ } }, // 鏄惁涓洪粯璁ょ粨鏋� - { + /* { minWidth: '120', prop: 'master', label: '榛樿缁撴瀯', @@ -249,7 +249,7 @@ formatter: (row, column, cellValue) => { return cellValue == true ? '鏄�' : '鍚�' } - }, + }, */ // 鎻忚堪 { minWidth: '120', diff --git a/src/views/technology/structure/single-structure-form.vue b/src/views/technology/structure/single-structure-form.vue index 87eca90..8611912 100644 --- a/src/views/technology/structure/single-structure-form.vue +++ b/src/views/technology/structure/single-structure-form.vue @@ -88,9 +88,9 @@ >{{ dataForm.ifsSync ? '鏄�' : '鍚�' }}</span > </el-form-item> --> - <el-form-item label="榛樿缁撴瀯" prop="master"> + <!-- <el-form-item label="榛樿缁撴瀯" prop="master"> <el-checkbox v-model="dataForm.master"></el-checkbox> - </el-form-item> + </el-form-item> --> </el-col> </el-row> </el-form> @@ -196,7 +196,7 @@ <el-table-column label="鍗曚綅" prop="unit" align="center"> </el-table-column> - <el-table-column label="鐩樻暟(鐩�)" prop="discNum" align="center"> + <!-- <el-table-column label="鐩樻暟(鐩�)" prop="discNum" align="center"> <template slot-scope="scope"> <el-input size="small" @@ -208,7 +208,7 @@ scope.row.discNum }}</span> </template> - </el-table-column> + </el-table-column> --> <!-- <el-table-column label="鍥惧彿" prop="drawingNumber" align="center"> </el-table-column> --> <el-table-column align="center" label="鎿嶄綔" width="85px"> diff --git a/src/views/warehouse/pallettransports/detail-ifslocation-form.vue b/src/views/warehouse/pallettransports/detail-ifslocation-form.vue index fa59ea8..879c1a7 100644 --- a/src/views/warehouse/pallettransports/detail-ifslocation-form.vue +++ b/src/views/warehouse/pallettransports/detail-ifslocation-form.vue @@ -23,7 +23,7 @@ </div> <div style="display:flex;align-items:center;margin-left:10px;"> <div> - <span>搴撲綅鎻忚堪锛�</span> + <span>搴撲綅鍚嶇О锛�</span> </div> <div> <el-input @@ -56,25 +56,32 @@ </template> </el-table-column> <el-table-column type="index" width="50" label="搴忓彿"> </el-table-column> - <el-table-column prop="locationNo" label="搴撲綅鍙�" align="center"> + <el-table-column prop="locNo" label="搴撲綅鍙�" align="center"> </el-table-column> <el-table-column - prop="locationDesc" - label="搴撲綅鎻忚堪" + prop="locName" + label="搴撲綅鍚嶇О" align="center" show-overflow-tooltip > </el-table-column> <el-table-column - prop="locationGroupDesc" - label="搴撲綅缁勬弿杩�" + prop="locType" + label="搴撲綅绫诲瀷" align="center" show-overflow-tooltip > </el-table-column> <el-table-column - prop="locationTypeDesc" - label="搴撲綅绫诲瀷鎻忚堪" + prop="ifsLocation" + label="ifs搴撲綅" + align="center" + show-overflow-tooltip + > + </el-table-column> + <el-table-column + prop="ifsLocationGroup" + label="ifs搴撲綅缁�" align="center" show-overflow-tooltip > @@ -92,7 +99,7 @@ </el-dialog> </template> <script> -import { getIfsLocationByGroup } from '@/api/warehouse/location' +import { getIfsLocationByGroupCopyAll } from '@/api/warehouse/location' import { updateBatchPalletTransportsDetail } from '@/api/warehouse/pallettransports' export default { components: {}, @@ -124,19 +131,20 @@ // 鏌ヨifs搴撲綅鍒楄〃 queryLocation() { this.ifsLocationData = [] - getIfsLocationByGroup({ + getIfsLocationByGroupCopyAll({ locationNo: this.dataForm.locationNo, locationDesc: this.dataForm.locationDesc }).then((response) => { - if (response.data.code === 0) { + if (response.data.code == 0) { const _data = response.data.data this.ifsLocationData = _data.map((item, index) => { return { id: index + 1, - locationNo: item.LOCATION_NO, - locationDesc: item.LOCATION_DESC, - locationGroupDesc: item.LOCATION_GROUP_DESC, - locationTypeDesc: item.LOCATION_TYPE_DESC, + locNo: item.locNo, + locName: item.locName, + locType: item.locType, + ifsLocation: item.ifsLocation, + ifsLocationGroup: item.ifsLocationGroup, commonChecked: false } }) @@ -168,8 +176,8 @@ this.detailList.forEach((item) => { transportsDetails.push({ id: item.id, - toIfsLocationName: this.currLocationRow.locationDesc, - toIfsLocationNo: this.currLocationRow.locationNo + toIfsLocationName: this.currLocationRow.locName, + toIfsLocationNo: this.currLocationRow.locNo }) }) updateBatchPalletTransportsDetail(transportsDetails) diff --git a/src/views/warehouse/pallettransports/ifslocation-form.vue b/src/views/warehouse/pallettransports/ifslocation-form.vue index 8e65546..babb2ae 100644 --- a/src/views/warehouse/pallettransports/ifslocation-form.vue +++ b/src/views/warehouse/pallettransports/ifslocation-form.vue @@ -23,7 +23,7 @@ </div> <div style="display:flex;align-items:center;margin-left:10px;"> <div> - <span>搴撲綅鎻忚堪锛�</span> + <span>搴撲綅鍚嶇О锛�</span> </div> <div> <el-input @@ -56,29 +56,39 @@ </template> </el-table-column> <el-table-column type="index" width="50" label="搴忓彿"> </el-table-column> - <el-table-column prop="locationNo" label="搴撲綅鍙�" align="center"> + <el-table-column prop="locNo" label="搴撲綅鍙�" align="center"> </el-table-column> <el-table-column - prop="locationDesc" - label="搴撲綅鎻忚堪" + prop="locName" + label="搴撲綅鍚嶇О" align="center" show-overflow-tooltip > </el-table-column> <el-table-column - prop="locationGroupDesc" - label="搴撲綅缁勬弿杩�" + prop="locType" + label="搴撲綅绫诲瀷" + align="center" + show-overflow-tooltip + > + <template scope="scope"> + {{formatLocType(scope.row.locType)}} + </template> + </el-table-column> + <!-- <el-table-column + prop="ifsLocation" + label="ifs搴撲綅" align="center" show-overflow-tooltip > </el-table-column> <el-table-column - prop="locationTypeDesc" - label="搴撲綅绫诲瀷鎻忚堪" + prop="ifsLocationGroup" + label="ifs搴撲綅缁�" align="center" show-overflow-tooltip > - </el-table-column> + </el-table-column> --> </el-table> <div slot="footer" class="dialog-footer"> <el-button @click="innerVisible = false">鍙� 娑�</el-button> @@ -92,10 +102,12 @@ </el-dialog> </template> <script> -import { getIfsLocationByGroup } from '@/api/warehouse/location' +import { getIfsLocationByGroupCopyAll } from '@/api/warehouse/location' import { updateBatchPalletTransportsMaterial } from '@/api/warehouse/pallettransports' +import Template from '../../quality/parts/template.vue' +import { remote } from '../../../api/admin/dict' export default { - components: {}, + components: {Template}, props: { currshowlist: { type: Boolean, @@ -108,39 +120,66 @@ } } }, + filters:{ + + }, data() { return { innerVisible: false, + locTypeOption: [], isSubmit: false, dataForm: { - locationNo: null, - locationDesc: null + locationNo: '', + locationDesc: '' }, ifsLocationData: [], currLocationRow: null } }, + created() { + this.getLoc() + }, methods: { + formatLocType(val){ + let list = this.locTypeOption + let index = list.findIndex(ele=>{ + return ele.value == val + }) + if(index!=null){ + return list[index].label + } + return null + }, // 鏌ヨifs搴撲綅鍒楄〃 queryLocation() { this.ifsLocationData = [] - getIfsLocationByGroup({ + getIfsLocationByGroupCopyAll({ locationNo: this.dataForm.locationNo, locationDesc: this.dataForm.locationDesc }).then((response) => { - if (response.data.code === 0) { + if (response.data.code == 0) { const _data = response.data.data this.ifsLocationData = _data.map((item, index) => { return { id: index + 1, - locationNo: item.LOCATION_NO, - locationDesc: item.LOCATION_DESC, - locationGroupDesc: item.LOCATION_GROUP_DESC, - locationTypeDesc: item.LOCATION_TYPE_DESC, + locNo: item.locNo, + locName: item.locName, + locType: item.locType, + ifsLocation: item.ifsLocation, + ifsLocationGroup: item.ifsLocationGroup, commonChecked: false } }) } + }) + }, + // 鑾峰彇搴撲綅绫诲瀷鐨勬暟鎹瓧鍏� + getLoc() { + remote('warehouse_type').then((response) => { + if (response.data.code === 0) { + this.locTypeOption = response.data.data + } + console.log(response); }) }, // 鍗曡閫変腑 @@ -165,11 +204,12 @@ saveSelectRow() { this.isSubmit = true const transportsMaterials = [] + console.log(`output->this.transportsList`,this.transportsList) this.transportsList.forEach((item) => { transportsMaterials.push({ id: item.id, - toIfsLocationName: this.currLocationRow.locationDesc, - toIfsLocationNo: this.currLocationRow.locationNo + toIfsLocationName: this.currLocationRow.locName, + toIfsLocationNo: this.currLocationRow.locNo }) }) updateBatchPalletTransportsMaterial(transportsMaterials) diff --git a/src/views/warehouse/pallettransports/ifsstock-form.vue b/src/views/warehouse/pallettransports/ifsstock-form.vue index 9e8d42a..39cb352 100644 --- a/src/views/warehouse/pallettransports/ifsstock-form.vue +++ b/src/views/warehouse/pallettransports/ifsstock-form.vue @@ -1,93 +1,34 @@ <template> - <el-dialog - width="65%" - title="IFS搴撳瓨鐗╂枡" - top="5vh" - :visible.sync="innerVisible" - append-to-body - @close="$emit('update:currshowlist', false)" - :show="currshowlist" - class="part-dialog" - > + <el-dialog width="65%" title="IFS搴撳瓨鐗╂枡" top="5vh" :visible.sync="innerVisible" append-to-body + @close="$emit('update:currshowlist', false)" :show="currshowlist" class="part-dialog"> <div> - <span>闇�姹傛暟閲忥細</span - ><span style="color:Red;">{{ + <span>闇�姹傛暟閲忥細</span><span style="color:Red;">{{ materialRow == null - ? '' - : materialRow.surplusQuantity - totalPlanMoveQuality + ? '' + : materialRow.surplusQuantity - totalPlanMoveQuality }}</span> </div> - <el-table - class="ifs-stock-table" - :data="ifsStockData" - style="width: 100%;" - height="450px" - border - @selection-change="ifsStockSelectionChange" - stripe - ref="ifsStockTable" - > + <el-table class="ifs-stock-table" :data="ifsStockData" style="width: 100%;" height="450px" border + @selection-change="ifsStockSelectionChange" stripe ref="ifsStockTables"> <el-table-column type="selection" width="55"> </el-table-column> <el-table-column type="index" width="50" label="搴忓彿"> </el-table-column> - <el-table-column - prop="partNo" - label="闆朵欢鍙�" - align="center" - show-overflow-tooltip - > + <el-table-column prop="partNo" label="闆朵欢鍙�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="partDesc" - label="闆朵欢鎻忚堪" - align="center" - show-overflow-tooltip - > + <el-table-column prop="partDesc" label="闆朵欢鎻忚堪" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="locationDesc" - label="搴撲綅" - align="center" - show-overflow-tooltip - > + <el-table-column prop="locationDesc" label="搴撲綅" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="batchNo" - label="鎵规鍙�" - align="center" - show-overflow-tooltip - > + <el-table-column prop="batchNo" label="鎵规鍙�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="wdr" - label="WDR" - align="center" - show-overflow-tooltip - > + <el-table-column prop="wdr" label="WDR" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="optaskNo" - label="宸ュ崟" - align="center" - show-overflow-tooltip - > + <el-table-column prop="optaskNo" label="宸ュ崟" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="available" - label="鍙敤搴撳瓨鏁伴噺" - align="center" - show-overflow-tooltip - > + <el-table-column prop="available" label="鍙敤搴撳瓨鏁伴噺" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="planMoveQuality" - label="璁″垝绉诲簱鏁伴噺" - align="center" - > + <el-table-column prop="planMoveQuality" label="璁″垝绉诲簱鏁伴噺" align="center"> <template slot-scope="scope"> - <el-input - v-model="scope.row.planMoveQuality" - @blur="blurChangeCallback(scope.row)" - ></el-input> + <el-input v-model="scope.row.planMoveQuality" @blur="blurChangeCallback(scope.row)"></el-input> </template> </el-table-column> <el-table-column prop="unit" label="鍗曚綅" align="center"> @@ -97,12 +38,7 @@ </el-table> <div slot="footer" class="dialog-footer"> <el-button @click="innerVisible = false">鍙� 娑�</el-button> - <el-button - type="primary" - :disabled="isSubmit" - v-thinclick="`saveSelectRow`" - >纭� 瀹�</el-button - > + <el-button type="primary" v-thinclick="`saveSelectRow`">纭� 瀹�</el-button> </div> </el-dialog> </template> @@ -177,18 +113,18 @@ flagMsg = flagMsg + '绗�' + (i + 1) + '琛岋紝璁″垝绉诲簱鏁伴噺鏈�澶氬叚浣嶅皬鏁帮紱' } else { - console.log( - 'this.ifsStockData[i].planMoveQuality', - this.ifsStockData[i].planMoveQuality - ) - console.log( - 'this.ifsStockData[i].available', - this.ifsStockData[i].available - ) - console.log( - this.ifsStockData[i].planMoveQuality > - this.ifsStockData[i].available - ) + // console.log( + // 'this.ifsStockData[i].planMoveQuality', + // this.ifsStockData[i].planMoveQuality + // ) + // console.log( + // 'this.ifsStockData[i].available', + // this.ifsStockData[i].available + // ) + // console.log( + // this.ifsStockData[i].planMoveQuality > + // this.ifsStockData[i].available + // ) if ( this.ifsStockData[i].planMoveQuality > this.ifsStockData[i].available @@ -262,9 +198,16 @@ partDesc: item.partDesc, batchNo: item.batchNo, wdr: item.wdr, + serialNo: item.serialNo, + engChgLevel: item.engChgLevel, + configurationId: item.configurationId, + activitySeq: item.activitySeq, transferQuantity: item.planMoveQuality, fromIfsLocationNo: item.locationNo, transportsMaterialId: this.materialRow.id, + toIfsLocationNo: this.materialRow.toIfsLocationNo, + toIfsLocationName: this.materialRow.toIfsLocationName, + partId: this.materialRow.partId, transportsId: this.transportsRow.id, operationTaskId: item.optaskId, operationTaskNo: item.optaskNo, @@ -282,10 +225,10 @@ } else { this.$message.error('娣诲姞绉诲簱鏄庣粏澶辫触') } - this.isSubmit = false + this.isSubmit = true }) .catch(() => { - this.isSubmit = false + this.isSubmit = true }) } else { this.$message.error('璇烽�夋嫨IFS搴撳瓨鐗╂枡') @@ -295,7 +238,7 @@ this.isSubmit = false } }, - initData() {} + initData() { } }, watch: { currshowlist() { @@ -318,14 +261,18 @@ id: index + 1, partNo: item.PART_NO, partDesc: item.PART_DESC, - locationDesc: item.LOCATION_DESC, + locationDesc: item.LOCATION_NO, locationNo: item.LOCATION_NO, batchNo: item.LOT_BATCH_NO, wdr: item.WAIV_DEV_REJ_NO, available: Number(item.QTY_AVAILABLE), unit: item.UNIT_MEAS_DESC, engChgLevel: item.ENG_CHG_LEVEL, + serialNo: item.SERIAL_NO, + configurationId: item.CONFIGURATION_ID, + activitySeq: item.ACTIVITY_SEQ, planMoveQuality: Number(item.QTY_AVAILABLE), + partId: this.materialRow.partId, optaskNo: this.optask != null ? this.optask.optaskNo : null, optaskId: this.optask != null ? this.optask.id : null }) @@ -333,6 +280,7 @@ } } }) + console.log(`output->this.ifsStockData`,this.ifsStockData) }) } } @@ -343,9 +291,11 @@ .part-dialog .el-dialog__header { padding: 10px 20px 10px; } + .part-dialog .el-dialog__header .el-dialog__headerbtn { top: 10px; } + .part-dialog .el-dialog__body { padding: 5px 20px; } diff --git a/src/views/warehouse/pallettransports/index.vue b/src/views/warehouse/pallettransports/index.vue index ccce219..caff534 100644 --- a/src/views/warehouse/pallettransports/index.vue +++ b/src/views/warehouse/pallettransports/index.vue @@ -3,321 +3,149 @@ <basic-container> <el-row> <el-col :span="9"> - <ttable - :table="table" - @currentChange="palletTransportsChange" - :uploadInfo="uploadInfo" - :prelang="prelang" - :options="options" - :ajaxFun="ajaxFun" - :fixedHeight="palletTransportsFixedHeight" - ref="pallettransportsTable" - > + <ttable :table="table" @currentChange="palletTransportsChange" :uploadInfo="uploadInfo" :prelang="prelang" + :options="options" :ajaxFun="ajaxFun" :fixedHeight="palletTransportsFixedHeight" ref="pallettransportsTable"> <template #toolbar> - <el-button - v-if="permissions.warehouse_pallettransports_add" - type="primary" - @click="addOrUpdateHandle()" - >鏂板</el-button - > + <el-button v-if="permissions.warehouse_pallettransports_add" type="primary" + @click="addOrUpdateHandle()">鏂板</el-button> </template> </ttable> - <div - style="margin:0px 20px 0px;display:flex;height:36px;justify-content: space-between;align-items:center;" - > + <div style="margin:0px 20px 0px;display:flex;height:36px;justify-content: space-between;align-items:center;"> <div> <span style="font-weight:bold;">瀵瑰簲宸ュ崟</span> </div> <div></div> </div> <div style="padding:0px 20px 0px;"> - <el-table - class="pallet-transports-optask-table" - :data="palletTransportsOptaskData" - style="width: 100%;" - v-adaptive="{ bottomOffset: 20, fixedHeight: 0 }" - height="100px" - border - highlight-current-row - @row-click="optaskRowClick" - stripe - ref="palletTransportsOptaskTable" - > + <el-table class="pallet-transports-optask-table" :data="palletTransportsOptaskData" + style="width: 100%;" + v-adaptive="{ bottomOffset: 20, fixedHeight: 0 }" height="100px" border highlight-current-row + @row-click="optaskRowClick" stripe ref="palletTransportsOptaskTable"> <el-table-column align="center" width="55" label="鍗曢��"> <template slot-scope="scope"> - <el-checkbox - class="optask-table-single-checkbox" - v-model="scope.row.commonChecked" - disabled - ></el-checkbox> + <el-checkbox class="optask-table-single-checkbox" v-model="scope.row.commonChecked" + disabled></el-checkbox> </template> </el-table-column> - <el-table-column - prop="optaskNo" - label="宸ュ崟鍙�" - align="center" - show-overflow-tooltip - > + <el-table-column prop="optaskNo" label="宸ュ崟鍙�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="partName" - label="闆朵欢" - align="center" - show-overflow-tooltip - > + <el-table-column prop="partName" label="闆朵欢" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="workCenter" - label="宸ヤ綔涓績" - align="center" - show-overflow-tooltip - > + <el-table-column prop="workCenter" label="宸ヤ綔涓績" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="workstationName" - label="宸ヤ綔绔�" - align="center" - show-overflow-tooltip - > + <el-table-column prop="workstationName" label="宸ヤ綔绔�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="plannedQuantity" - label="璁″垝鏁伴噺" - align="center" - show-overflow-tooltip - > + <el-table-column prop="plannedQuantity" label="璁″垝鏁伴噺" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="unit" - label="鍗曚綅" - align="center" - show-overflow-tooltip - > + <el-table-column prop="unit" label="鍗曚綅" align="center" show-overflow-tooltip> </el-table-column> </el-table> </div> </el-col> <el-col :span="15" style="padding-left: 10px;padding-right: 10px"> - <div - style="display:flex;height:36px;justify-content: space-between;align-items:center;" - > + <div style="display:flex;height:36px;justify-content: space-between;align-items:center;"> <div><span style="font-weight:bold;">鐗╂枡闇�姹�</span></div> <div> - <el-button - type="text" - v-if="permissions.warehouse_pallettransports_demand_add" - @click="openPartDialog" - >鏂板</el-button - ><el-button - type="text" - v-if="permissions.warehouse_pallettransports_ifs" - @click="openLocationDialog" - >IFS鑷冲簱浣�</el-button - > + <el-button type="text" v-if="permissions.warehouse_pallettransports_demand_add" + @click="openPartDialog">鏂板</el-button><el-button type="text" + v-if="permissions.warehouse_pallettransports_ifs" @click="openLocationDialog">绉昏嚦搴撲綅</el-button> </div> </div> <div> - <el-table - class="pallet-transports-material-table" - :data="palletTransportsMaterialData" - style="width: 100%;" - height="350px" - border - @selection-change="palletTransportsMaterialSelectionChange" - stripe - ref="palletTransportsMaterialTable" - > - <el-table-column type="selection" width="55"> </el-table-column> - <el-table-column - prop="partNo" - label="闆朵欢鍙�" - align="center" - show-overflow-tooltip - > + <el-table class="pallet-transports-material-table" @current-change="handleCurrentChange" :data="palletTransportsMaterialData" style="width: 100%;" + height="350px" border stripe + ref="palletTransportsMaterialTable"> + <!--鍗曢�夋 @selection-change="palletTransportsMaterialSelectionChange"--> + <el-table-column align="center" width="55" label="鍗曢��"> + <template slot-scope="scope"> + <el-checkbox v-model="scope.row.commonChecked" @change="handleCurrentChange(scope.row)" ></el-checkbox> + </template> + </el-table-column> + <el-table-column prop="partNo" label="闆朵欢鍙�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="partDesc" - label="闆朵欢鎻忚堪" - align="center" - show-overflow-tooltip - > + <el-table-column prop="partDesc" label="闆朵欢鎻忚堪" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="demandQuantity" - label="闇�姹傛暟閲�" - align="center" - > + <el-table-column prop="demandQuantity" label="闇�姹傛暟閲�" align="center"> <template slot-scope="scope"> - <el-input - v-show="scope.row.canEdit" - v-model="scope.row.demandQuantity" - ></el-input> + <el-input v-show="scope.row.canEdit" v-model="scope.row.demandQuantity"></el-input> <span v-show="!scope.row.canEdit">{{ scope.row.demandQuantity }}</span> </template> </el-table-column> - <el-table-column - prop="transferQuantity" - label="绉诲簱鏁伴噺" - align="center" - > + <el-table-column prop="transferQuantity" label="绉诲簱鏁伴噺" align="center"> </el-table-column> - <el-table-column - prop="surplusQuantity" - label="鍓╀綑鏁伴噺" - align="center" - > + <el-table-column prop="surplusQuantity" label="鍓╀綑鏁伴噺" align="center"> </el-table-column> <el-table-column prop="unit" label="璁¢噺鍗曚綅" align="center"> </el-table-column> - <el-table-column - prop="toIfsLocationNo" - label="IFS鑷冲簱浣�" - align="center" - > + <el-table-column prop="toIfsLocationNo" label="绉昏嚦搴撲綅" align="center"> </el-table-column> <el-table-column label="鎿嶄綔" align="center" width="100"> <template slot-scope="scope"> - <el-button - v-show="!scope.row.canEdit" - type="text" - :disabled="scope.row.detailExistState" - @click="scope.row.canEdit = true" - >缂栬緫</el-button - > - <el-button - v-show="scope.row.canEdit" - type="text" - :disabled="scope.row.detailExistState" - @click="updateMaterial(scope.row)" - >淇濆瓨</el-button - > - <el-button - type="text" - :disabled="scope.row.detailExistState" - @click="delMaterial(scope.row)" - >鍒犻櫎</el-button - > + <!-- <el-button v-show="!scope.row.canEdit" type="text" :disabled="scope.row.detailExistState" + @click="scope.row.canEdit = true">缂栬緫</el-button> --> + <!-- <el-button v-show="scope.row.canEdit" type="text" :disabled="scope.row.detailExistState" + @click="updateMaterial(scope.row)">淇濆瓨</el-button> --> + <el-button type="text" :disabled="scope.row.detailExistState" + @click="delMaterial(scope.row)">鍒犻櫎</el-button> </template> </el-table-column> </el-table> </div> - <div - style="margin-top:10px;display:flex;height:36px;justify-content: space-between;align-items:center;" - > + <div style="margin-top:10px;display:flex;height:36px;justify-content: space-between;align-items:center;"> <div> - <span style="font-weight:bold;">绉诲簱鏄庣粏</span - ><span style="color:red;" - >({{ - palletTransportsMaterialMultipleSelection.length > 0 - ? palletTransportsMaterialMultipleSelection[ - palletTransportsMaterialMultipleSelection.length - 1 - ].partDesc - : '' - }})</span - > + <span style="font-weight:bold;">绉诲簱鏄庣粏</span> + <span style="color:red;">({{ + palletTransportsMaterialMultipleSelection.length > 0 + ? palletTransportsMaterialMultipleSelection[ + palletTransportsMaterialMultipleSelection.length - 1 + ].partDesc + : '' + }})</span> </div> <div> - <el-button - type="primary" - v-if="permissions.warehouse_pallettransports_detail_add" - round - @click="openStockDialog" - >娣诲姞鏄庣粏</el-button - > - <el-button - type="warning" - v-if="permissions.warehouse_pallettransports_detail_library" - round - @click="openDetailLocationDialog" - >涓�閿嚦搴撲綅</el-button - > - <el-button - type="success" - v-if="permissions.warehouse_pallettransports_detail_execute" - round - @click="executeMove" - >鎵� 琛�</el-button - > + <el-button type="primary" v-if="permissions.warehouse_pallettransports_detail_add" round + @click="getPalletTransportsDetailData">娣诲姞鏄庣粏</el-button> + <!-- <el-button type="warning" v-if="permissions.warehouse_pallettransports_detail_library" round + @click="openDetailLocationDialog">涓�閿嚦搴撲綅</el-button> --> + <el-button type="success" v-if="permissions.warehouse_pallettransports_detail_execute" round + @click="executeMove">鎵� 琛�</el-button> </div> </div> <div> - <el-table - class="pallet-transports-detail-table" - :data="palletTransportsDetailData" - style="width: 100%;" - v-adaptive="{ bottomOffset: 20, fixedHeight: 0 }" - height="100px" - border - @selection-change="palletTransportsDetailSelectionChange" - stripe - ref="palletTransportsDetailTable" - > + <el-table class="pallet-transports-detail-table" :data="palletTransportsDetailData" style="width: 100%;" + v-adaptive="{ bottomOffset: 20, fixedHeight: 0 }" height="100px" border + @selection-change="palletTransportsDetailSelectionChange" stripe ref="palletTransportsDetailTable"> <el-table-column type="selection" width="55"> </el-table-column> - <el-table-column - prop="partNo" - label="闆朵欢鍙�" - align="center" - show-overflow-tooltip - > + <el-table-column prop="part_no" label="闆朵欢鍙�" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="partDesc" - label="闆朵欢鎻忚堪" - align="center" - show-overflow-tooltip - > + <el-table-column prop="part_desc" label="闆朵欢鎻忚堪" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="batchNo" - label="鎵规鍙�" - align="center" - show-overflow-tooltip - > + <!-- <el-table-column prop="batchNo" label="鎵规鍙�" align="center" show-overflow-tooltip> </el-table-column> <el-table-column prop="wdr" label="WDR" align="center"> + </el-table-column> --> + <el-table-column prop="operation_task_no" label="宸ュ崟" align="center" show-overflow-tooltip> </el-table-column> - <el-table-column - prop="operationTaskNo" - label="宸ュ崟" - align="center" - show-overflow-tooltip - > - </el-table-column> - <el-table-column - prop="transferQuantity" - label="绉诲簱鏁伴噺" - align="center" - > + <el-table-column prop="transfer_quantity" label="绉诲簱鏁伴噺" align="center"> </el-table-column> <el-table-column prop="unit" label="鍗曚綅" align="center"> </el-table-column> - <el-table-column - prop="fromIfsLocationNo" - label="IFS浠庡簱浣�" - align="center" - > - </el-table-column> - <el-table-column - prop="toIfsLocationNo" - label="IFS鑷冲簱浣�" - align="center" - > - <template slot-scope="scope"> - <el-link - type="primary" - @click="openSingleLocationDialog(scope.row)" - >{{ scope.row.toIfsLocationNo }}</el-link - > - </template> + <!-- <el-table-column prop="fromIfsLocationNo" label="IFS浠庡簱浣�" align="center"> + </el-table-column> --> + <el-table-column prop="to_ifs_location_no" label="绉昏嚦搴撲綅" align="center"> + <!-- <template slot-scope="scope"> + <el-link type="primary" @click="openSingleLocationDialog(scope.row)">{{ scope.row.toIfsLocationNo + }}</el-link> + </template> --> </el-table-column> <el-table-column prop="state" label="鐘舵��" align="center"> <template slot-scope="scope"> <span>{{ scope.row.state == null - ? '' - : scope.row.state === '01initial' + ? '' + : scope.row.state === '01initial' ? '宸插垱寤�' : '宸叉墽琛�' }}</span> @@ -325,18 +153,10 @@ </el-table-column> <el-table-column label="鎿嶄綔" align="center" width="85"> <template slot-scope="scope"> - <el-button - type="text" - @click="openEditStockDialog(scope.row)" - :disabled="scope.row.state === '01initial' ? false : true" - >缂栬緫</el-button - > - <el-button - type="text" - @click="delDetail(scope.row)" - :disabled="scope.row.state === '01initial' ? false : true" - >鍒犻櫎</el-button - > + <!-- <el-button type="text" @click="openEditStockDialog(scope.row)" + :disabled="scope.row.state === '01initial' ? false : true">缂栬緫</el-button> --> + <el-button type="text" @click="delDetail(scope.row)" + :disabled="scope.row.state === '01initial' ? false : true">鍒犻櫎</el-button> </template> </el-table-column> </el-table> @@ -344,44 +164,22 @@ </el-col> </el-row> <!-- 寮圭獥, 鏂板 / 淇敼 --> - <pallettransportsFormDialog - :currshowlist.sync="showPallettransportsForm" - :palletTransportsId="palletTransportsId" - @refreshPalletTransports="getPallettransportsData" - /> + <pallettransportsFormDialog :currshowlist.sync="showPallettransportsForm" :palletTransportsId="palletTransportsId" + @refreshPalletTransports="getPallettransportsData" /> <!-- 寮圭獥, 闆朵欢鍒楄〃 --> - <partDialog - :currshowlist.sync="showPart" - @listenToPartEvent="selectPartCallback" - /> + <partDialog :currshowlist.sync="showPart" @listenToPartEvent="selectPartCallback" /> <!-- 寮圭獥, IFS搴撲綅鍒楄〃 --> - <ifsLocationDialog - :currshowlist.sync="showLocation" - :transportsList="palletTransportsMaterialMultipleSelection" - @refreshDataList="selectLocationCallback" - /> + <ifsLocationDialog :currshowlist.sync="showLocation" :transportsList="palletTransportsMaterialMultipleSelection" + @refreshDataList="selectLocationCallback" /> <!-- 寮圭獥, IFS搴撳瓨鍒楄〃 --> - <ifsStockDialog - :currshowlist.sync="showStock" - :materialRow="materialRow" - :transportsRow="currPalletTransportsRow" - :optask="currOptask" - @refreshDataList="addIfsStockCallback" - /> + <ifsStockDialog :currshowlist.sync="showStock" :materialRow="materialRow" :transportsRow="currPalletTransportsRow" + :optask="currOptask" @refreshDataList="addIfsStockCallback" /> <!-- 寮圭獥, 缂栬緫IFS搴撳瓨鍒楄〃 --> - <detailIfsStockDialog - :currshowlist.sync="showDetailStock" - :materialRow="materialRow" - :transportsRow="currPalletTransportsRow" - :detailRow="currDetailRow" - @refreshDataList="addIfsStockCallback" - /> + <detailIfsStockDialog :currshowlist.sync="showDetailStock" :materialRow="materialRow" + :transportsRow="currPalletTransportsRow" :detailRow="currDetailRow" @refreshDataList="addIfsStockCallback" /> <!-- 寮圭獥, 鏄庣粏鐨処FS搴撲綅鍒楄〃 --> - <detailIfsLocationDialog - :currshowlist.sync="showDetailLocation" - :detailList="detailList" - @refreshDataList="selectDetailLocationCallback" - /> + <detailIfsLocationDialog :currshowlist.sync="showDetailLocation" :detailList="detailList" + @refreshDataList="selectDetailLocationCallback" /> </basic-container> </div> </template> @@ -395,7 +193,8 @@ delPalletTransportsMaterialObj, palletTransportsDetailFetchList, delPalletTransportsDetailObj, - executeMoveLocation + executeMoveLocation, + selectAll, } from '@/api/warehouse/pallettransports' import { getByPalletTransId } from '@/api/plan/operationtask' import ttable from '@/views/common/ztt-table.vue' @@ -407,10 +206,11 @@ import detailIfsLocationDialog from './detail-ifslocation-form' import adaptive from '@/util/adaptive' import { mapGetters } from 'vuex' - +import { saveBatchPalletTransportsDetail } from '@/api/warehouse/pallettransports' export default { data() { return { + partDesc: null, ajaxFun: palletTransportsFetchList, currPalletTransportsRow: null, palletTransportsMaterialMultipleSelection: [], @@ -420,6 +220,8 @@ isShow: false, url: '' }, + WorkOrder:{}, + datalistAPI:'', prelang: 'pallettransports', options: { height: 300, // 榛樿楂樺害-涓轰簡琛ㄥご鍥哄畾 @@ -552,8 +354,30 @@ computed: { ...mapGetters(['permissions']) }, - created() {}, + watch:{ + palletTransportsMaterialMultipleSelection(newVal){ + if(newVal.length>0){ + this.palletTransportsMaterialSelectionChange(newVal) + }else{ + this.palletTransportsDetailData = [] + } + } + }, + created() { }, methods: { + // 鍗曡閫変腑 + handleCurrentChange(row) { + this.palletTransportsMaterialData.forEach((item) => { + // 鎺掍粬,姣忔閫夋嫨鏃舵妸鍏朵粬閫夐」閮芥竻闄� + if (item.id !== row.id) { + item.commonChecked = false + }else{ + item.commonChecked = true + } + }) + this.palletTransportsMaterialSelectionChange([row]) + console.log(row); + }, // 宸ヨ壓绫诲瀷涓枃鏍煎紡鍖� formatStateType(row, column, cellValue) { this.stateOptions.forEach((obj) => { @@ -602,7 +426,8 @@ unit: item.unit, transportsId: item.transportsId, detailExistState: item.detailExistState, - canEdit: false + canEdit: false, + commonChecked: false } this.palletTransportsMaterialData.push(palletTransportsMaterial) }) @@ -624,31 +449,6 @@ } }) }, - // 鑾峰彇绉诲簱鏄庣粏鏁版嵁鍒楄〃 - getPalletTransportsDetailData() { - this.palletTransportsDetailData = [] - if (this.palletTransportsMaterialMultipleSelection.length > 0) { - const currPalletTransportsMaterial = this - .palletTransportsMaterialMultipleSelection[ - this.palletTransportsMaterialMultipleSelection.length - 1 - ] - const queryParam = Object.assign( - { - current: 1, - size: 200 - }, - { - transportsMaterialId: currPalletTransportsMaterial.id - } - ) - palletTransportsDetailFetchList(queryParam).then((response) => { - const resData = response.data - if (resData.code === 0) { - this.palletTransportsDetailData = resData.data.records - } - }) - } - }, // 鏂板 / 淇敼 addOrUpdateHandle(row) { if (row != null) { @@ -666,7 +466,7 @@ closeOnClickModal: false, type: 'warning' }) - .then(function() { + .then(function () { return delPalletTransportsObj(row.id) }) .then((data) => { @@ -675,7 +475,7 @@ this.palletTransportsMaterialData = [] this.palletTransportsDetailData = [] }) - .catch(() => {}) + .catch(() => { }) }, // 鎵撳紑闆朵欢鍒楄〃 openPartDialog() { @@ -776,22 +576,54 @@ } }) }, - // 鎵撳紑ifs鐗╂枡搴撳瓨鍒楄〃 - openStockDialog() { - if (this.palletTransportsMaterialMultipleSelection.length > 0) { - this.showStock = true - } else { - this.$message.error('璇峰厛閫夋嫨鐗╂枡闇�姹�') - } + // 鑾峰彇绉诲簱鏄庣粏鏁版嵁鍒楄〃 + getPalletTransportsDetailData() { + // console.log("瀵瑰簲宸ュ崟",this.WorkOrder); + // console.log("閫変腑鐗╂枡闇�姹�",this.palletTransportsMaterialMultipleSelection); + let transportsDetails =[] + transportsDetails = this.palletTransportsMaterialMultipleSelection.map(el =>{ + return{ + partNo:el.partNo, + partDesc: el.partDesc, + transferQuantity: el.surplusQuantity, + toIfsLocationNo:el.toIfsLocationNo, + toIfsLocationName: el.toIfsLocationName, + transportsId: el.transportsId, + transportsMaterialId:el.id, + operationTaskNo:this.WorkOrder.optaskNo, + operationTaskId:this.WorkOrder.id, + unit: el.unit, + }}) + // this.palletTransportsDetailData = transportsDetails + if (transportsDetails.length > 0) { + let selectionList = this.palletTransportsMaterialMultipleSelection + saveBatchPalletTransportsDetail(transportsDetails) + .then((response) => { + const resData = response.data + if (resData.code === 0) { + this.innerVisible = false + this.$message.success('娣诲姞绉诲簱鏄庣粏鎴愬姛') + let materialRow = selectionList[selectionList.length - 1] + console.log("materialRow-----",materialRow); + this.palletTransportsMaterialData.forEach(ele=>{ + if(ele.id==materialRow.id){ + console.log("ele-------",ele); + ele.transferQuantity = materialRow.surplusQuantity + ele.surplusQuantity = 0 + } + }) + } else { + this.$message.error('娣诲姞绉诲簱鏄庣粏澶辫触') + } + // this.getPalletTransportsMaterialData() + this.palletTransportsMaterialSelectionChange(selectionList) + }) + // .catch(() => { + // }) + } }, // 娣诲姞ifs鐗╂枡搴撳瓨鍥炶皟 addIfsStockCallback() { - // 鍒锋柊鐗╂枡闇�姹傘�佸埛鏂扮Щ搴撴槑缁� - // this.getPalletTransportsMaterialData() - // 鍒锋柊璐х洏杩愯緭浠诲姟鍒楄〃 - // if (this.showStock) { - // this.getPallettransportsData() - // } const currRow = this.currPalletTransportsRow this.getPallettransportsData().then(() => { if (currRow) { @@ -820,10 +652,11 @@ }, // 鎵撳紑鍗曚釜鏄庣粏鎵归噺鏇存柊搴撲綅寮规 openSingleLocationDialog(row) { + console.log(row); if (row.state === '01initial') { this.detailList = [] this.detailList.push(row) - this.showDetailLocation = true + // this.showDetailLocation = true } else { this.$message.error('绉诲簱鏄庣粏宸叉墽琛�') } @@ -906,16 +739,26 @@ }, palletTransportsMaterialSelectionChange(val) { this.palletTransportsMaterialMultipleSelection = val - if (this.palletTransportsMaterialMultipleSelection.length > 0) { - const currPalletTransportsMaterial = this - .palletTransportsMaterialMultipleSelection[ - this.palletTransportsMaterialMultipleSelection.length - 1 - ] - this.materialRow = currPalletTransportsMaterial - } else { - this.materialRow = null + console.log(this.palletTransportsMaterialMultipleSelection); + if(val && val.length>0){ + let ids =[] + this.palletTransportsMaterialMultipleSelection.forEach(el =>{ids.push(el.id)}) + let pId = ids[ids.length - 1]; + console.log(pId); + if(pId!=null){ + selectAll({ + transportsId:this.currPalletTransportsRow.id, + transportsMaterialId: pId + }).then((res) =>{ + this.palletTransportsDetailData = [] + if(res.data.data){ + this.palletTransportsDetailData.push(res.data.data) + } + }) + }else{ + this.palletTransportsDetailData = [] + } } - this.getPalletTransportsDetailData() }, palletTransportsDetailSelectionChange(val) { this.palletTransportsDetailMultipleSelection = val @@ -932,6 +775,7 @@ }) }, optaskRowClick(row, column) { + this.WorkOrder = row this.palletTransportsOptaskData.forEach((item) => { if (row.id !== item.id) { item.commonChecked = false @@ -951,57 +795,59 @@ } </script> <style scoped> -.pallet-transports-material-table >>> .el-table__header th { +.pallet-transports-material-table>>>.el-table__header th { color: #666666; } -.pallet-transports-material-table >>> th { +.pallet-transports-material-table>>>th { padding: 3px 0px; height: 31px; } -.pallet-transports-material-table >>> td { + +.pallet-transports-material-table>>>td { padding: 1px 0 0 0; } -.pallet-transports-detail-table >>> .el-table__header th { +.pallet-transports-detail-table>>>.el-table__header th { color: #666666; } -.pallet-transports-detail-table >>> th { +.pallet-transports-detail-table>>>th { padding: 3px 0px; height: 31px; } -.pallet-transports-detail-table >>> td { + +.pallet-transports-detail-table>>>td { padding: 1px 0 0 0; } -.pallet-transports-optask-table >>> .el-table__header th { +.pallet-transports-optask-table>>>.el-table__header th { color: #666666; } -.pallet-transports-optask-table >>> th { +.pallet-transports-optask-table>>>th { padding: 3px 0px; height: 31px; } -.pallet-transports-optask-table >>> td { + +.pallet-transports-optask-table>>>td { padding: 1px 0 0 0; } -.optask-table-single-checkbox - >>> .el-checkbox__input.is-disabled.is-checked - .el-checkbox__inner { + +.optask-table-single-checkbox>>>.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner { background-color: #006eff; border-color: #006eff; } -.optask-table-single-checkbox - >>> .el-checkbox__input.is-disabled - .el-checkbox__inner { + +.optask-table-single-checkbox>>>.el-checkbox__input.is-disabled .el-checkbox__inner { background-color: #ffffff; cursor: pointer; } -.optask-table-single-checkbox >>> .el-checkbox__inner::after { + +.optask-table-single-checkbox>>>.el-checkbox__inner::after { border: 1px solid #fff !important; border-left: 0 !important; border-top: 0 !important; cursor: pointer !important; } -</style> +</style> \ No newline at end of file diff --git a/vue.config.js b/vue.config.js index 94a4809..d03924e 100644 --- a/vue.config.js +++ b/vue.config.js @@ -2,10 +2,12 @@ * 閰嶇疆鍙傝��: * https://cli.vuejs.org/zh/config/ */ +// const url = 'http://192.168.2.7:9999' +//const url = 'http://192.168.2.7:9999' +//const url = 'http://192.168.32.45:9999' // const url = 'http://192.168.0.23:9999' - // const url = 'http://192.168.0.60:9999' - const url = 'http://localhost:9999' + const url = 'http://localhost:9999' // const url = 'http://ztt-gateway:9999' const localUrl = 'http://localhost:8089' -- Gitblit v1.9.3