| | |
| | | deviceGroup: null, |
| | | orderBy: { |
| | | field: 'id', |
| | | order: 'desc' |
| | | order: 'asc' |
| | | } |
| | | }, |
| | | isIndex: false, |
| | |
| | | inspectionItemType: { |
| | | select: [] |
| | | }, |
| | | valueType: { |
| | | select: [] |
| | | }, |
| | | bsm:{ |
| | | select: [] |
| | | }, |
| | |
| | | }, |
| | | laboratory:{ |
| | | select:[] |
| | | } |
| | | }, |
| | | method:{select:[]}, |
| | | deviceGroup:{select:[]}, |
| | | templateId:{ |
| | | select:[] |
| | | }, |
| | | sonLaboratory: {select:[]}, |
| | | unit: {select:[]}, |
| | | sample: {select:[]}, |
| | | }, |
| | | selectField: { |
| | | inspectionItemType: { |
| | | select: [] |
| | | }, |
| | | valueType: { |
| | | select: [] |
| | | }, |
| | | bsm:{ |
| | | select: [] |
| | | }, |
| | |
| | | }, |
| | | laboratory:{ |
| | | select:[] |
| | | } |
| | | }, |
| | | templateId:{ |
| | | select:[] |
| | | }, |
| | | method:{select:[],choose: true}, |
| | | deviceGroup:{select:[]}, |
| | | sample: {select:[]}, |
| | | sonLaboratory: {select:[]}, |
| | | unit: {select:[]} |
| | | }, |
| | | requiredAdd: ['inspectionItem', 'manHour', 'inspectionItemType','inspectionValueType','inspectionItemClassify','laboratory','unit','method','price','manDay','deviceGroup','checkoutNumber','valueType'], |
| | | requiredUp: ['inspectionItem', 'manHour', 'inspectionItemType','inspectionValueType','inspectionItemClassify','laboratory','unit','method','price','manDay','deviceGroup','checkoutNumber','valueType'] |
| | | requiredAdd: ['sonLaboratory','inspectionItem', 'manHour', 'inspectionItemType','inspectionItemSubclass','inspectionValueType','laboratory','unit','method','price','manDay','deviceGroup','checkoutNumber','sample'], |
| | | requiredUp: ['sonLaboratory','inspectionItem', 'manHour', 'inspectionItemType','inspectionItemSubclass','inspectionValueType','laboratory','unit','method','price','manDay','deviceGroup','checkoutNumber','sample'] |
| | | }, |
| | | testObjectData: { |
| | | entity: { |
| | | specimenName: null, |
| | | orderBy: { |
| | | field: 'id', |
| | | order: 'desc' |
| | | order: 'asc' |
| | | } |
| | | }, |
| | | isIndex: false, |
| | |
| | | this.itemParameterEntityCopy = this.HaveJson(this.itemParameterData.entity) |
| | | this.testObjectDataEntityCopy = this.HaveJson(this.testObjectData.entity) |
| | | this.selectEnumByCategory() |
| | | this.selectEnumByCategoryForValue() |
| | | // this.selectEnumByCategoryForValue() |
| | | this.selectEnumByCategoryForSpecial() |
| | | this.selectEnumByCategoryForInspectionValueType() |
| | | this.obtainItemParameterList() |
| | | this.selectStandardMethods() |
| | | this.selectEnumByCategoryForDevice() |
| | | this.selectTestObjectByName() |
| | | this.getStandardTemplate() |
| | | this.selectEnumByCategoryForSLaboratory() |
| | | this.selectEnumByCategoryForUnit() |
| | | this.getPower('0') |
| | | }, |
| | | methods: { |
| | |
| | | }, |
| | | selectEnumByCategoryForSpecial() { |
| | | this.$axios.post(this.$api.enums.selectEnumByCategory, { |
| | | category: "特殊标识" |
| | | category: "是否" |
| | | }).then(res => { |
| | | this.itemParameterData.selectField.bsm.select = res.data |
| | | this.itemParameterData.tagField.bsm.select = res.data |
| | |
| | | this.itemParameterData.tagField.inspectionValueType.select = res.data |
| | | }) |
| | | }, |
| | | selectEnumByCategoryForDevice() { |
| | | this.$axios.post(this.$api.enums.selectEnumByCategory, { |
| | | category: "设备分类" |
| | | }).then(res => { |
| | | this.itemParameterData.selectField.deviceGroup.select = res.data |
| | | this.itemParameterData.tagField.deviceGroup.select = res.data |
| | | }) |
| | | }, |
| | | selectEnumByCategoryForSLaboratory() { |
| | | this.$axios.post(this.$api.enums.selectEnumByCategory, { |
| | | category: "子实验室" |
| | | }).then(res => { |
| | | this.itemParameterData.selectField.sonLaboratory.select = res.data |
| | | this.itemParameterData.tagField.sonLaboratory.select = res.data |
| | | }) |
| | | }, |
| | | selectEnumByCategoryForUnit() { |
| | | this.$axios.post(this.$api.enums.selectEnumByCategory, { |
| | | category: "单位" |
| | | }).then(res => { |
| | | this.itemParameterData.selectField.unit.select = res.data |
| | | this.itemParameterData.tagField.unit.select = res.data |
| | | }) |
| | | }, |
| | | obtainItemParameterList() { |
| | | this.$axios.get(this.$api.laboratoryScope.obtainItemParameterList).then(res => { |
| | | let data = [] |
| | |
| | | this.itemParameterData.tagField.laboratory.select = data |
| | | }) |
| | | }, |
| | | selectStandardMethods() { |
| | | this.$axios.get(this.$api.standardMethod.selectStandardMethods).then(res => { |
| | | let data = [] |
| | | res.data.forEach(a=>{ |
| | | data.push({ |
| | | label: a.name, |
| | | value: a.code |
| | | }) |
| | | }) |
| | | this.itemParameterData.selectField.method.select = data |
| | | this.itemParameterData.tagField.method.select = data |
| | | }) |
| | | }, |
| | | selectTestObjectByName() { |
| | | this.$axios.get(this.$api.capacityScope.selectTestObjectByName).then(res => { |
| | | let data = [] |
| | | res.data.forEach(a => { |
| | | data.push({ |
| | | label: a.specimenName, |
| | | value: a.id, |
| | | type: 'success' |
| | | }) |
| | | }) |
| | | this.itemParameterData.selectField.sample.select = data |
| | | this.itemParameterData.tagField.sample.select = data |
| | | }) |
| | | }, |
| | | getStandardTemplate() { |
| | | this.$axios.get(this.$api.StandardTemplate.getStandardTemplate).then(res => { |
| | | let data = [] |
| | | res.data.forEach(a => { |
| | | data.push({ |
| | | label: a.name, |
| | | value: a.id, |
| | | type: 'success' |
| | | }) |
| | | }) |
| | | this.itemParameterData.selectField.templateId.select = data |
| | | this.itemParameterData.tagField.templateId.select = data |
| | | }) |
| | | }, |
| | | // 权限分配 |
| | | getPower(radio) { |
| | | let power = JSON.parse(sessionStorage.getItem('power')) |