|
|
@ -78,7 +78,8 @@ import TableOpertaion from "@/components/Template/operation/TableOpertaion.vue" |
|
|
import SelectReagentDialog from '../../../dialog/SelectReagentDialog.vue'; |
|
|
import SelectReagentDialog from '../../../dialog/SelectReagentDialog.vue'; |
|
|
import { EventBus } from "@/utils/eventBus"; |
|
|
import { EventBus } from "@/utils/eventBus"; |
|
|
import { sj_subpackage,sj_startConfiguration,sj_configurationCompleted } from '@/api/business/sj/sj'; |
|
|
import { sj_subpackage,sj_startConfiguration,sj_configurationCompleted } from '@/api/business/sj/sj'; |
|
|
import { addTj,uniqeResource } from "@/utils/calUnitTools"; |
|
|
|
|
|
|
|
|
import { addTj,uniqeResource,uniqeResourceOne,addDecimals } from "@/utils/calUnitTools"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "SWYPFXRYPZB", |
|
|
name: "SWYPFXRYPZB", |
|
|
components: { BaseInfoFormPackage, LineLabel, TableList, Step, CustomTable, TableOpertaion, SelectReagentDialog }, |
|
|
components: { BaseInfoFormPackage, LineLabel, TableList, Step, CustomTable, TableOpertaion, SelectReagentDialog }, |
|
|
@ -379,6 +380,7 @@ export default { |
|
|
type:1 |
|
|
type:1 |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
|
|
|
const result = await getLatestSnArr(postSn) |
|
|
if(result.code == 200){ |
|
|
if(result.code == 200){ |
|
|
for(let i=0;i<stepTableFormData_1.length;i++){ |
|
|
for(let i=0;i<stepTableFormData_1.length;i++){ |
|
|
this.$refs.rongyeTableRef.updateDataSourceByRowIndex(i,{ |
|
|
this.$refs.rongyeTableRef.updateDataSourceByRowIndex(i,{ |
|
|
@ -416,7 +418,73 @@ export default { |
|
|
for(let i=0;i<tableList.length;i++){ |
|
|
for(let i=0;i<tableList.length;i++){ |
|
|
//配置的试剂 |
|
|
//配置的试剂 |
|
|
let item = tableList[i] |
|
|
let item = tableList[i] |
|
|
|
|
|
console.log('表格item:'+JSON.stringify(item)) |
|
|
|
|
|
|
|
|
|
|
|
//使用的 实际溶液 |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: item.sjry, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: null, |
|
|
|
|
|
nd: null, |
|
|
|
|
|
nddw: null, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: null, |
|
|
|
|
|
kcdw: null, |
|
|
|
|
|
syl: item.sjryxql, |
|
|
|
|
|
type: 1, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:content.headerSelectFields.sjryxqlUnit, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
// 基质吸取量 |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: content.subJz, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: null, |
|
|
|
|
|
nd: null, |
|
|
|
|
|
nddw: null, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: null, |
|
|
|
|
|
kcdw: null, |
|
|
|
|
|
syl: item.sjjzxql, |
|
|
|
|
|
type: 1, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:content.headerSelectFields.sjjzxqlUnit, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
//分装的 |
|
|
|
|
|
let fzTotal = 0//分装总量 |
|
|
|
|
|
if(item.fzsj && item.fzsj.fzList && item.fzsj.fzList.length>0){ |
|
|
|
|
|
for(let j=0;j<item.fzsj.fzList.length;j++){ |
|
|
|
|
|
let fzItem = item.fzsj.fzList[j] |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: item.fzsj.mybh+fzItem.preCode, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: item.hhwznd + content.headerSelectFields.hhwzndUnit, |
|
|
|
|
|
nd: item.hhwznd, |
|
|
|
|
|
nddw: content.headerSelectFields.hhwzndUnit, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: fzItem.num, |
|
|
|
|
|
kcdw: item.fzsj.dw, |
|
|
|
|
|
syl: null, |
|
|
|
|
|
type: null, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:item.fzsj.dw, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
fzTotal=addDecimals(fzTotal,fzItem.num) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
//生成的 |
|
|
const { total, unit } = addTj([item.sjjzxql, item.sjryxql], [content.headerSelectFields.sjjzxqlUnit, content.headerSelectFields.sjryxqlUnit]) |
|
|
const { total, unit } = addTj([item.sjjzxql, item.sjryxql], [content.headerSelectFields.sjjzxqlUnit, content.headerSelectFields.sjryxqlUnit]) |
|
|
|
|
|
|
|
|
tmpResource.push({ |
|
|
tmpResource.push({ |
|
|
@ -430,10 +498,10 @@ export default { |
|
|
sxrq: null, |
|
|
sxrq: null, |
|
|
kc: total, |
|
|
kc: total, |
|
|
kcdw: unit, |
|
|
kcdw: unit, |
|
|
syl: null, |
|
|
|
|
|
|
|
|
syl: fzTotal>0?fzTotal:null, |
|
|
type: null, |
|
|
type: null, |
|
|
elnType: this.product, |
|
|
elnType: this.product, |
|
|
syldw:unit, |
|
|
|
|
|
|
|
|
syldw:fzTotal>0?item.fzsj.dw:unit, |
|
|
yxzq:null, |
|
|
yxzq:null, |
|
|
yxzqdw:null, |
|
|
yxzqdw:null, |
|
|
}) |
|
|
}) |
|
|
@ -445,6 +513,92 @@ export default { |
|
|
for(let i=0;i<tableList.length;i++){ |
|
|
for(let i=0;i<tableList.length;i++){ |
|
|
//配置的试剂 |
|
|
//配置的试剂 |
|
|
let item = tableList[i] |
|
|
let item = tableList[i] |
|
|
|
|
|
console.log('表格item:'+JSON.stringify(item)) |
|
|
|
|
|
|
|
|
|
|
|
//使用的 实际溶液 |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: item.sjry, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: null, |
|
|
|
|
|
nd: null, |
|
|
|
|
|
nddw: null, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: null, |
|
|
|
|
|
kcdw: null, |
|
|
|
|
|
syl: item.sjryxql, |
|
|
|
|
|
type: 1, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:content.headerSelectFields.sjryxqlUnit, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
// 工作液 |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: content.subGzy, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: null, |
|
|
|
|
|
nd: null, |
|
|
|
|
|
nddw: null, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: null, |
|
|
|
|
|
kcdw: null, |
|
|
|
|
|
syl: item.sjgzyxql, |
|
|
|
|
|
type: 1, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:content.headerSelectFields.sjgzyxqlUnit, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
// 稀释液 |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: content.subXsy, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: null, |
|
|
|
|
|
nd: null, |
|
|
|
|
|
nddw: null, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: null, |
|
|
|
|
|
kcdw: null, |
|
|
|
|
|
syl: item.sjxsyxql, |
|
|
|
|
|
type: 1, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:content.headerSelectFields.sjxsyxqlUnit, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
//分装的 |
|
|
|
|
|
let fzTotal = 0//分装总量 |
|
|
|
|
|
if(item.fzsj && item.fzsj.fzList && item.fzsj.fzList.length>0){ |
|
|
|
|
|
for(let j=0;j<item.fzsj.fzList.length;j++){ |
|
|
|
|
|
let fzItem = item.fzsj.fzList[j] |
|
|
|
|
|
tmpResource.push({ |
|
|
|
|
|
mc: null, |
|
|
|
|
|
bh: item.fzsj.mybh+fzItem.preCode, |
|
|
|
|
|
ph: null, |
|
|
|
|
|
ndz: item.hhwznd + content.headerSelectFields.hhwzndUnit, |
|
|
|
|
|
nd: item.hhwznd, |
|
|
|
|
|
nddw: content.headerSelectFields.hhwzndUnit, |
|
|
|
|
|
ly: 'ELN配制', |
|
|
|
|
|
sxrq: null, |
|
|
|
|
|
kc: fzItem.num, |
|
|
|
|
|
kcdw: item.fzsj.dw, |
|
|
|
|
|
syl: null, |
|
|
|
|
|
type: null, |
|
|
|
|
|
elnType: this.product, |
|
|
|
|
|
syldw:item.fzsj.dw, |
|
|
|
|
|
yxzq:null, |
|
|
|
|
|
yxzqdw:null, |
|
|
|
|
|
}) |
|
|
|
|
|
fzTotal=addDecimals(fzTotal,fzItem.num) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
// 生成的 |
|
|
const { total, unit } = addTj([item.sjryxql, item.sjgzyxql,item.sjxsyxql], [content.headerSelectFields_1.sjryxqlUnit, content.headerSelectFields_1.sjgzyxqlUnit,content.headerSelectFields_1.sjxsyxqlUnit]) |
|
|
const { total, unit } = addTj([item.sjryxql, item.sjgzyxql,item.sjxsyxql], [content.headerSelectFields_1.sjryxqlUnit, content.headerSelectFields_1.sjgzyxqlUnit,content.headerSelectFields_1.sjxsyxqlUnit]) |
|
|
tmpResource.push({ |
|
|
tmpResource.push({ |
|
|
mc: null, |
|
|
mc: null, |
|
|
@ -457,16 +611,19 @@ export default { |
|
|
sxrq: null, |
|
|
sxrq: null, |
|
|
kc: total, |
|
|
kc: total, |
|
|
kcdw: unit, |
|
|
kcdw: unit, |
|
|
syl: null, |
|
|
|
|
|
|
|
|
syl: fzTotal>0?fzTotal:null, |
|
|
type: null, |
|
|
type: null, |
|
|
elnType: this.product, |
|
|
elnType: this.product, |
|
|
syldw:unit, |
|
|
|
|
|
|
|
|
syldw:fzTotal>0?item.fzsj.dw:unit, |
|
|
yxzq:null, |
|
|
yxzq:null, |
|
|
yxzqdw:null, |
|
|
yxzqdw:null, |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
if(tmpResource.length>0){ |
|
|
|
|
|
tmpResource = uniqeResourceOne(tmpResource) |
|
|
|
|
|
} |
|
|
//使用的试剂、仪器 |
|
|
//使用的试剂、仪器 |
|
|
const stepResource = this.$refs.stepRef.getStepResource() |
|
|
const stepResource = this.$refs.stepRef.getStepResource() |
|
|
this.resourceTmp =uniqeResource(tmpResource,stepResource.sjResource||[]) |
|
|
this.resourceTmp =uniqeResource(tmpResource,stepResource.sjResource||[]) |
|
|
|