parent
c72c71ff13
commit
efd2d003da
|
|
@ -316,6 +316,30 @@
|
|||
<!-- 批量添加样品对话框 -->
|
||||
<el-dialog title="批量添加样品" :visible.sync="batchSampleOpen" width="600px" append-to-body :close-on-click-modal="false">
|
||||
<el-form label-width="120px">
|
||||
<el-form-item label="样品型号">
|
||||
<el-autocomplete
|
||||
v-model="batchSampleModel"
|
||||
:fetch-suggestions="querySampleModelForReceipt"
|
||||
placeholder="请输入样品型号"
|
||||
style="width: 100%"
|
||||
:trigger-on-focus="false"
|
||||
/>
|
||||
<div style="margin-top: 5px; color: #909399; font-size: 12px">
|
||||
<i class="el-icon-info"></i> 提示:该型号将应用于所有批量添加的样品
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="硬件版本号">
|
||||
<el-autocomplete
|
||||
v-model="batchHardwareVersion"
|
||||
:fetch-suggestions="queryHardwareVersionForReceipt"
|
||||
placeholder="请输入硬件版本号"
|
||||
style="width: 100%"
|
||||
:trigger-on-focus="false"
|
||||
/>
|
||||
<div style="margin-top: 5px; color: #909399; font-size: 12px">
|
||||
<i class="el-icon-info"></i> 提示:该版本号将应用于所有批量添加的样品
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="样品SN号">
|
||||
<el-input
|
||||
v-model="batchSampleText"
|
||||
|
|
@ -365,6 +389,10 @@ export default {
|
|||
batchSampleOpen: false,
|
||||
// 批量添加样品文本
|
||||
batchSampleText: "",
|
||||
// 批量添加样品型号
|
||||
batchSampleModel: "",
|
||||
// 批量添加硬件版本号
|
||||
batchHardwareVersion: "",
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
|
|
@ -522,6 +550,8 @@ export default {
|
|||
/** 批量添加样品 */
|
||||
handleBatchAddSample() {
|
||||
this.batchSampleText = "";
|
||||
this.batchSampleModel = "";
|
||||
this.batchHardwareVersion = "";
|
||||
this.batchSampleOpen = true;
|
||||
},
|
||||
/** 提交批量添加样品 */
|
||||
|
|
@ -544,9 +574,9 @@ export default {
|
|||
const exists = this.form.samples.some(sample => sample.sampleSn === sn);
|
||||
if (!exists) {
|
||||
this.form.samples.push({
|
||||
sampleModel: null,
|
||||
sampleModel: this.batchSampleModel || null,
|
||||
sampleSn: sn,
|
||||
hardwareVersion: null,
|
||||
hardwareVersion: this.batchHardwareVersion || null,
|
||||
externalStatus: null,
|
||||
testDeadline: null,
|
||||
testItems: null,
|
||||
|
|
|
|||
Loading…
Reference in New Issue