From 893efaff3c2523976993063543dfedf4a5b412f3 Mon Sep 17 00:00:00 2001
From: spring <2396852758@qq.com>
Date: 星期四, 13 三月 2025 14:27:42 +0800
Subject: [PATCH] Merge branch 'dev' of http://114.132.189.42:9002/r/center-lims-before-ruoyi into dev
---
src/views/business/inspectionOrder/add.vue | 266 +++++++++++++++++++++++++---------------------------
1 files changed, 127 insertions(+), 139 deletions(-)
diff --git a/src/views/business/inspectionOrder/add.vue b/src/views/business/inspectionOrder/add.vue
index ade64a8..27f393d 100644
--- a/src/views/business/inspectionOrder/add.vue
+++ b/src/views/business/inspectionOrder/add.vue
@@ -1,9 +1,6 @@
<template>
<div class="bg-1">
- <div
- v-show="!configShow && !equipConfigShow && !cableConfigShow"
- style="margin: 5px 15px"
- >
+ <div style="margin: 5px 15px" v-show="!configShow && !equipConfigShow">
<el-row class="title">
<el-col :span="6"
>濮旀墭鍗曚俊鎭� 鎬讳环锛�<span style="color: #3a7bfa"
@@ -80,17 +77,17 @@
v-show="active == 3 && addObj.companyId"
>閫氳繃</el-button
>
- <el-button size="medium" @click="$router.go(-1)">
+ <el-button
+ size="medium"
+ @click="$router.push('/business/inspectionOrder')"
+ >
<span style="color: #3a7bfa">杩斿洖</span>
</el-button>
</el-col>
</el-row>
</div>
- <basic-container>
- <div
- class="search"
- v-show="!configShow && !equipConfigShow && !cableConfigShow"
- >
+ <basic-container v-show="!configShow && !equipConfigShow">
+ <div class="search">
<el-form
:model="addObj"
:rules="formRule"
@@ -395,7 +392,7 @@
</basic-container>
<div
class="search"
- v-if="active == 1"
+ v-if="active == 1 && !configShow && !equipConfigShow"
style="display: flex; background: transparent"
>
<div style="display: flex; align-items: center">
@@ -443,7 +440,7 @@
</div>
</div>
</div>
- <basic-container>
+ <basic-container v-show="!configShow && !equipConfigShow">
<div style="height: auto">
<el-table
class="el-table sampleTable"
@@ -909,104 +906,103 @@
<el-dialog
title="妫�楠屼笅鍙�"
:visible.sync="issuedDialogVisible"
- width="400px"
+ width="450px"
:close-on-click-modal="false"
:close-on-press-escape="false"
:show-close="false"
>
<div class="body" style="max-height: 60vh">
- <el-row>
- <el-col class="search_thing" :span="22">
- <div class="search_label">
- <span class="required-span">* </span>绾﹀畾鏃堕棿锛�
- </div>
- <div class="search_input">
- <el-date-picker
- size="small"
- v-model="distributeData.appointed"
- :picker-options="pickerOptions"
- type="date"
- placeholder="閫夋嫨鏃ユ湡"
- value-format="yyyy-MM-dd"
- style="width: 100%"
- format="yyyy-MM-dd"
- >
- </el-date-picker>
- </div>
+ <el-row style="margin-bottom: 20px">
+ <el-col :span="8" style="text-align: right">
+ <div><span class="required-span">* </span>绾﹀畾鏃堕棿锛�</div>
</el-col>
- <el-col class="search_thing" :span="22">
- <div class="search_label">
+ <el-col :span="16">
+ <el-date-picker
+ size="small"
+ v-model="distributeData.appointed"
+ :picker-options="{ disabledDate: this.disabledDate }"
+ type="date"
+ placeholder="閫夋嫨鏃ユ湡"
+ value-format="yyyy-MM-dd"
+ style="width: 100%"
+ format="yyyy-MM-dd"
+ >
+ </el-date-picker>
+ </el-col>
+ </el-row>
+ <el-row style="margin-bottom: 20px">
+ <el-col :span="8" style="text-align: right">
+ <div>
<span class="required-span" v-if="addObj.type == 2">* </span
>鎸囨淳浜哄憳锛�
</div>
- <div class="search_input">
- <el-select
- multiple
- v-model="distributeData.userId"
- placeholder="璇烽�夋嫨"
- size="small"
- filterable
- style="width: 100%"
- @change="changeUser"
- >
- <el-option-group
- v-for="(item, index) in Object.keys(personList)"
- :key="index"
- :label="item"
- >
- <el-option
- v-for="op in personList[item]"
- :key="op.id"
- :label="op.name"
- :value="op.id"
- >
- </el-option>
- </el-option-group>
- </el-select>
- </div>
</el-col>
- <el-col
- class="search_thing"
- :span="22"
- v-if="distributeData.userId.length > 0"
- >
- <div class="search_label">
- <span class="required-span">* </span>璇曢獙瀹わ細
- </div>
- <div class="search_input">
- <el-select
- v-model="distributeData.sonLaboratory"
- placeholder="璇烽�夋嫨"
- size="small"
- filterable
- style="width: 100%"
+ <el-col :span="16">
+ <el-select
+ multiple
+ v-model="distributeData.userId"
+ placeholder="璇烽�夋嫨"
+ size="small"
+ filterable
+ style="width: 100%"
+ @change="changeUser"
+ >
+ <el-option-group
+ v-for="(item, index) in Object.keys(personList)"
+ :key="index"
+ :label="item"
>
<el-option
- v-for="item in sonLaboratoryList"
- :key="item.value"
- :label="item.label"
- :value="item.value"
+ v-for="op in personList[item]"
+ :key="op.id"
+ :label="op.name"
+ :value="op.id"
>
</el-option>
- </el-select>
- </div>
+ </el-option-group>
+ </el-select>
</el-col>
- <el-col class="search_thing" :span="22">
- <div class="search_label">
- <span class="required-span">* </span>鍒涘缓濮旀墭鍗曪細
- </div>
- <div class="search_input">
- <el-select
- v-model="distributeData.isCreate"
- placeholder="璇烽�夋嫨"
- size="small"
- filterable
- style="width: 100%"
+ </el-row>
+ <el-row
+ v-if="distributeData.userId.length > 0"
+ style="margin-bottom: 20px"
+ >
+ <el-col :span="8" style="text-align: right">
+ <div><span class="required-span">* </span>璇曢獙瀹わ細</div>
+ </el-col>
+ <el-col :span="16">
+ <el-select
+ v-model="distributeData.sonLaboratory"
+ placeholder="璇烽�夋嫨"
+ size="small"
+ filterable
+ style="width: 100%"
+ >
+ <el-option
+ v-for="item in sonLaboratoryList"
+ :key="item.value"
+ :label="item.label"
+ :value="item.value"
>
- <el-option label="鏄�" :value="true"></el-option>
- <el-option label="鍚�" :value="false"></el-option>
- </el-select>
- </div>
+ </el-option>
+ </el-select>
+ </el-col>
+ </el-row>
+ <el-row style="margin-bottom: 20px">
+ <el-col :span="8" style="text-align: right">
+ <div><span class="required-span">* </span>鍒涘缓濮旀墭鍗曪細</div>
+ </el-col>
+ <el-col :span="16">
+ <el-select
+ v-model="distributeData.isCreate"
+ placeholder="璇烽�夋嫨"
+ size="small"
+ filterable
+ style="width: 100%"
+ >
+ <el-option label="鏄�" :value="true"></el-option>
+ <el-option label="鍚�" :value="false"></el-option>
+ </el-select>
</el-col>
</el-row>
</div>
@@ -1022,17 +1018,15 @@
<el-dialog title="涓嶉�氳繃鍘熷洜" :visible.sync="noDialogVisible" width="400px">
<div class="body" style="max-height: 60vh">
<el-row>
- <el-col class="search_thing" :span="22">
- <div class="search_label">
- <span class="required-span">* </span>涓嶉�氳繃鍘熷洜锛�
- </div>
- <div class="search_input">
- <el-input
- v-model="tell"
- size="small"
- placeholder="璇疯緭鍏ヤ笉閫氳繃鍘熷洜"
- ></el-input>
- </div>
+ <el-col :span="8" style="text-align: right">
+ <div><span class="required-span">* </span>涓嶉�氳繃鍘熷洜锛�</div>
+ </el-col>
+ <el-col :span="16">
+ <el-input
+ v-model="tell"
+ size="small"
+ placeholder="璇疯緭鍏ヤ笉閫氳繃鍘熷洜"
+ ></el-input>
</el-col>
</el-row>
</div>
@@ -1055,7 +1049,7 @@
:active="active"
:inspectionItemST="inspectionItemST"
/>
- <fiberOpticConfigTwo
+ <fiberOpticConfigReadOnly
:currentId="currentId"
v-if="configShow && examine == 1"
:active="active"
@@ -1065,7 +1059,6 @@
v-if="equipConfigShow"
:active="active"
/>
- <cableConfig v-if="cableConfigShow" :active="active" />
<!-- 鍗曢�夌壒娈婂�煎鐞嗘-->
<el-dialog
title="妫�娴嬪埌鐗规畩椤癸紝璇蜂綔鍑轰互涓嬮�夋嫨"
@@ -1572,7 +1565,6 @@
import fiberOpticConfig from "./fiberoptic-config.vue";
import fiberOpticConfigReadOnly from "./fiberoptic-config-readonly.vue";
import equipConfig from "./equip-config.vue";
-import cableConfig from "./cable-config.vue";
import getLodop from "@/utils/lodop";
import { bigEval } from "@/utils/bigEval";
import { getDicts } from "@/api/system/dict/data";
@@ -1581,7 +1573,6 @@
fiberOpticConfig,
fiberOpticConfigReadOnly,
equipConfig,
- cableConfig,
},
computed: {
...mapGetters(["nickName", "loginUserInfo"]),
@@ -1593,14 +1584,6 @@
examine: 0,
active: 0,
currentId: 0,
- pickerOptions: {
- disabledDate(time) {
- // 褰撳墠鏃堕棿鍔犱笂涓夊ぉ鐨勬椂闂存埑
- const threeDaysLater = Date.now() + 24 * 60 * 60 * 1000;
- // 绂佺敤涓夊ぉ鍚庝箣鍓嶇殑鎵�鏈夋棩鏈�
- return time.getTime() < threeDaysLater;
- },
- },
fiberLoss: [],
qrDataList: [],
isFocus: false,
@@ -1769,7 +1752,6 @@
bsm1Dia: false,
bsm1DiaAll: false,
equipConfigShow: false,
- cableConfigShow: false,
bsm2: false,
bsm2Val: null,
bsm2Dia: false,
@@ -1887,7 +1869,7 @@
},
},
created() {
- this.active = this.$route.query.active;
+ this.active = Number(this.$route.query.active);
this.currentId = this.$route.query.currentId;
this.examine = this.$route.query.examine;
this.isReview = this.$route.query.isReview;
@@ -1934,6 +1916,15 @@
}
},
methods: {
+ //涓嬫鏍告煡鏃ユ湡:绂佺敤鍦ㄦ牳鏌ユ棩鏈熷墠鐨勬棩鏈�
+ disabledDate(time) {
+ if (time) {
+ let now = new Date();
+ now.setHours(0, 0, 0, 0);
+ return time < now.getTime();
+ }
+ return false;
+ },
changeType(type) {
this.hasSendUrgentOrder(type)
.then((res) => {
@@ -3324,6 +3315,20 @@
b.id = null;
delete b.bsmRow;
});
+ if (a.bushing && a.bushing.length > 0) {
+ a.bushing.forEach((b) => {
+ b.fiber.forEach((c) => {
+ c.productList.forEach((d) => {
+ d.id = null;
+ });
+ });
+ b.fibers.forEach((c) => {
+ c.productList.forEach((d) => {
+ d.id = null;
+ });
+ });
+ });
+ }
});
this.editTable.forEach((item) => {
sampleList.forEach((a) => {
@@ -3358,7 +3363,7 @@
if (res.code === 200) {
this.$message.success("宸叉彁浜�");
this.bsm3Dia = false;
- this.$router.go(-1);
+ this.$router.push("/business/inspectionOrder");
}
this.saveLoad = false;
})
@@ -3369,7 +3374,6 @@
},
upInsOrderOfState(state) {
if (state == 1) {
- //this.saveLoad = true
this.issuedDialogVisible = true;
selectOrderManDay({
id: this.currentId,
@@ -3378,7 +3382,6 @@
if (res.code === 200) {
this.distributeData.orderId = this.currentId;
this.distributeData.appointed = res.data;
- console.log("绾﹀畾鏃堕棿", this.distributeData.appointed);
}
})
.catch((error) => {
@@ -3530,7 +3533,7 @@
this.$message.success("鎻愪氦鎴愬姛");
this.issuedDialogVisible = false;
this.upLoad = false;
- this.$router.go(-1);
+ this.$router.replace("/business/inspectionOrder");
//瀹℃牳閫氳繃鍚庯紝鑷姩鎵撳嵃浜岀淮鐮�
//TODO: 鐢靛姏璇曢獙瀹ゆ殏鏃朵笉鐢ㄦ爣绛炬墦鍗�
if (
@@ -3808,7 +3811,6 @@
val.forEach((a) => {
this.productIds.push(a.id);
});
- console.log("selectChange", this.sampleList);
},
rowClick(row, column, event) {
this.currentMethod = row;
@@ -4622,7 +4624,7 @@
this.tell = "";
this.$message.success("鎻愪氦鎴愬姛");
this.issuedDialogVisible = false;
- this.$router.go(-1);
+ this.$router.push("/business/inspectionOrder");
}
})
.catch((error) => {
@@ -4695,20 +4697,6 @@
return;
}
this.equipConfigShow = true;
- } else {
- if (this.sampleId === null) {
- this.$message.error("鏈�変腑鏍峰搧");
- return;
- }
- }
- },
- openCableConfig() {
- if (this.active === 1) {
- if (this.sampleIds.length === 0) {
- this.$message.error("鏈�夋嫨鏍峰搧");
- return;
- }
- this.cableConfigShow = true;
} else {
if (this.sampleId === null) {
this.$message.error("鏈�変腑鏍峰搧");
--
Gitblit v1.9.3