|
|
|
@ -16,11 +16,10 @@ |
|
|
|
<div class="template-form-item"> |
|
|
|
<span>基质</span> |
|
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" ref="stepFormPackageRef" |
|
|
|
:formConfig="stepFormConfig" @blur="onHandleBlur" :formData="formData" |
|
|
|
@clickable="handleJzClickable" /> |
|
|
|
:formConfig="stepFormConfig" @blur="onHandleBlur" :formData="formData" /> |
|
|
|
|
|
|
|
<CustomTable @blur="onHandleTableBlur" :ref="`tableRef`" :columns="tableStepColumns" |
|
|
|
:formData="formData" :prefixKey="`table`" @clickable="handleClickable" |
|
|
|
:formData="formData" :prefixKey="`table`" |
|
|
|
fieldItemLabel="template.common.operationSteps"> |
|
|
|
<template slot="operation" slot-scope="{ row, rowIndex, columns }"> |
|
|
|
<TableOpertaion :fillType="fillType" :row="row" :rowIndex="rowIndex" :columns="columns" |
|
|
|
@ -37,9 +36,9 @@ |
|
|
|
|
|
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" |
|
|
|
ref="rongyeStepFormPackageRef" :formConfig="rongyeStepFormConfig" @blur="onHandleBlur" |
|
|
|
:formData="formData" @clickable="handleRongyeClickable" /> |
|
|
|
:formData="formData" /> |
|
|
|
<CustomTable @blur="onHandleTableBlur" :ref="`rongyeTableRef`" :columns="rongyeTableStepColumns" |
|
|
|
:formData="{stepTableFormData:formData.stepTableFormData_1,headerSelectFields:formData.headerSelectFields_1}" :prefixKey="`rongyeTable`" @clickable="handleRongyeTableClickable" |
|
|
|
:formData="{stepTableFormData:formData.stepTableFormData_1,headerSelectFields:formData.headerSelectFields_1}" :prefixKey="`rongyeTable`" |
|
|
|
fieldItemLabel="template.common.operationSteps"> |
|
|
|
<template slot="operation" slot-scope="{ row, rowIndex, columns }"> |
|
|
|
<TableOpertaion :fillType="fillType" :row="row" :rowIndex="rowIndex" :columns="columns" |
|
|
|
@ -59,8 +58,6 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<!-- <button @click = "onSave">保存</button> --> |
|
|
|
<SelectReagentDialog @submit="onSelectReagentSubmit" ref="selectReagentDialogRef"> |
|
|
|
</SelectReagentDialog> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
|
@ -74,14 +71,13 @@ import CustomTable from '@/components/Template/CustomTable.vue'; |
|
|
|
import { getLatestSnArr } from '@/api/template'; |
|
|
|
import { getSWYPFXFFXYPZBBTableConfig, getSWYPFXFFXYPZBBTQHSLTableConfig } from "../../../formConfig/SWYPFXFFXYPZBBTableConfig.js"; |
|
|
|
import TableOpertaion from "@/components/Template/operation/TableOpertaion.vue" |
|
|
|
import SelectReagentDialog from '../../../dialog/SelectReagentDialog.vue'; |
|
|
|
import { EventBus } from "@/utils/eventBus"; |
|
|
|
import { sj_subpackage,sj_startConfiguration,sj_configurationCompleted } from '@/api/business/sj/sj'; |
|
|
|
import { addTj,uniqeResource,uniqeResourceOne,addDecimals } from "@/utils/calUnitTools"; |
|
|
|
|
|
|
|
export default { |
|
|
|
name: "SWYPFXRYPZB", |
|
|
|
components: { BaseInfoFormPackage, LineLabel, TableList, Step, CustomTable, TableOpertaion, SelectReagentDialog }, |
|
|
|
components: { BaseInfoFormPackage, LineLabel, TableList, Step, CustomTable, TableOpertaion }, |
|
|
|
mixins: [templateMixin], |
|
|
|
props: { |
|
|
|
fillType: { |
|
|
|
@ -224,7 +220,7 @@ export default { |
|
|
|
label: 'template.sp.sp008.xzjz', |
|
|
|
type: "input", |
|
|
|
fillType: "preFill", |
|
|
|
subType: "clickable", |
|
|
|
subType: "sj", |
|
|
|
subKey: "subJz", |
|
|
|
subFillType: "actFill", |
|
|
|
maxlength: 20, |
|
|
|
@ -243,7 +239,7 @@ export default { |
|
|
|
label: 'template.sp.sp009.xzgzy', |
|
|
|
type: "input", |
|
|
|
fillType: "preFill", |
|
|
|
subType: "clickable", |
|
|
|
subType: "sj", |
|
|
|
subKey: "subGzy", |
|
|
|
subFillType: "actFill", |
|
|
|
maxlength: 20, |
|
|
|
@ -258,7 +254,7 @@ export default { |
|
|
|
label: 'template.sp.sp009.xzxsy', |
|
|
|
type: "input", |
|
|
|
fillType: "preFill", |
|
|
|
subType: "clickable", |
|
|
|
subType: "sj", |
|
|
|
subKey: "subXsy", |
|
|
|
subFillType: "actFill", |
|
|
|
maxlength: 20, |
|
|
|
@ -289,56 +285,6 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
//点击基质选择 |
|
|
|
handleJzClickable(obj) { |
|
|
|
this.reagentType = 1//本表单特殊字段 |
|
|
|
this.currentSubKey = obj.subKey; |
|
|
|
this.$refs.selectReagentDialogRef.show(this.formData.id) |
|
|
|
}, |
|
|
|
handleRongyeClickable(obj) { |
|
|
|
this.reagentType = 2//本表单特殊字段 |
|
|
|
this.currentSubKey = obj.subKey; |
|
|
|
this.$refs.selectReagentDialogRef.show(this.formData.id) |
|
|
|
}, |
|
|
|
//选择试剂提交事件 |
|
|
|
onSelectReagentSubmit(code, row) { |
|
|
|
if (this.reagentType == 1) { |
|
|
|
this.$refs.stepFormPackageRef.updateFormData(this.currentSubKey, code); |
|
|
|
} else if(this.reagentType == 2){ |
|
|
|
this.$refs.rongyeStepFormPackageRef.updateFormData(this.currentSubKey, code); |
|
|
|
} else if(this.reagentType == 3) { |
|
|
|
this.$refs.tableRef.updateDataSourceByRowIndex(this.rowIndex,{ |
|
|
|
[this.currentSubKey]: code, |
|
|
|
}) |
|
|
|
} else if(this.reagentType == 4) { |
|
|
|
this.$refs.rongyeTableRef.updateDataSourceByRowIndex(this.rowIndex,{ |
|
|
|
[this.currentSubKey]: code, |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
this.$refs.selectReagentDialogRef.onCancel() |
|
|
|
}, |
|
|
|
//点击表格单元格 |
|
|
|
handleClickable(col, rowIndex) { |
|
|
|
this.reagentType = 3 |
|
|
|
this.rowIndex = rowIndex |
|
|
|
this.currentSubKey = col.prop; |
|
|
|
console.log("clickable",rowIndex, col) |
|
|
|
if(col.prop === "sjry"){ |
|
|
|
//调用对应弹窗的方法-多个点击的需要判断是哪个字段点击 |
|
|
|
this.$refs.selectReagentDialogRef.show(this.formData.id) |
|
|
|
} |
|
|
|
}, |
|
|
|
handleRongyeTableClickable(col, rowIndex) { |
|
|
|
this.reagentType = 4 |
|
|
|
this.rowIndex = rowIndex |
|
|
|
this.currentSubKey = col.prop; |
|
|
|
console.log("clickable",rowIndex, col) |
|
|
|
if(col.prop === "sjry"){ |
|
|
|
//调用对应弹窗的方法-多个点击的需要判断是哪个字段点击 |
|
|
|
this.$refs.selectReagentDialogRef.show(this.formData.id) |
|
|
|
} |
|
|
|
}, |
|
|
|
//获取目标溶液编号 |
|
|
|
async getCode(v) { |
|
|
|
// 基质表格 |
|
|
|
|