| | |
| | | <el-button v-if="active==1&&addObj.sampleType!=undefined&&addObj.sampleType.indexOf('电缆')>-1" size="small" type="primary" @click="openAuxiliaryCore">辅助线芯配置</el-button> |
| | | <el-button v-show="active==1||(tabIndex==4&&active==2)" :loading="saveLoad" size="small" type="primary" @click="save">提交</el-button> |
| | | <!-- 审核 --> |
| | | <el-button v-show="active==3&&addObj.companyId" :disabled="saveLoad" :loading="saveLoad" size="small" |
| | | <el-button v-show="active==3" :disabled="saveLoad" :loading="saveLoad" size="small" |
| | | @click="upInsOrderOfState(2)">不通过</el-button> |
| | | <el-button v-show="active==3&&addObj.companyId" :loading="saveLoad" size="small" type="primary" |
| | | <el-button v-show="active==3" :loading="saveLoad" size="small" type="primary" |
| | | @click="upInsOrderOfState(1)">通过</el-button> |
| | | <el-button size="small" @click="goBack"> |
| | | <span style="color: #3A7BFA;">返回</span> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-table ref="productTable" v-loading="getProductLoad" :data="productList" :row-class-name="tableRowClassName" border class="el-table" |
| | | :key="upIndex" |
| | | max-height="400px" style="margin-bottom: 10px;" tooltip-effect="dark" |
| | | @select="selectOne" @selection-change="selectProduct" @select-all="handleAll"> |
| | | <el-table-column v-if="active==1" :selectable="selectable0" type="selection" width="65"></el-table-column> |
| | |
| | | AuxiliaryWireCore |
| | | }, |
| | | dicts: ['check_type1', 'urgency_level', 'form_type', 'sample_status_list'], |
| | | data() { |
| | | return { |
| | | active: '', |
| | | tabIndex: '', |
| | | currentId: '', |
| | | sampleSelectionList: [],//样品表格选中数据 |
| | | editTable:[], |
| | | template: null, |
| | | templates: [], |
| | | addObj: { |
| | | entrustCode: null, |
| | | custom: null, |
| | | company: null, |
| | | userId: null, |
| | | type: '0', |
| | | code: null, |
| | | appointed: null, |
| | | remark: null, // 备注 |
| | | remarkEn: null, // 备注英文 |
| | | sample: null, |
| | | factory: null, |
| | | laboratory: null, |
| | | sampleType: null, |
| | | sampleNum: 1, |
| | | unit: null, |
| | | model: null, |
| | | method: null, |
| | | phone: null, |
| | | processing: 1, |
| | | isLeave: 0, |
| | | orderType: null, |
| | | send: 1, |
| | | formType: '送检', // 来样方式 |
| | | sampleStatus: 'In good condition', // 样品状态 |
| | | testQuantity: '', // 样品状态 |
| | | production: null, |
| | | productionEn: null, |
| | | companyId: null, |
| | | prepareUser:null, // 委托人 |
| | | prepareUserEn:null, // 委托人英文 |
| | | prepareCode: '', // 委托人工号 |
| | | quarterItemId: '', |
| | | sampleView: '', // 样品名称(报告展示字段) |
| | | sampleViewEn: '', // 样品名称英文(报告展示字段) |
| | | }, |
| | | addObjRules: { // 表单校验规则 |
| | | orderType: [ |
| | | { required: true, message: '请选择检验类别', trigger: 'change' } |
| | | ], |
| | | company: [ |
| | | { required: true, message: '请选择委托单位', trigger: 'change' } |
| | | ], |
| | | phone: [ |
| | | { required: true, message: '请填写联系方式', trigger: 'blur' } |
| | | ], |
| | | type: [ |
| | | { required: true, message: '请选择紧急程度', trigger: 'change' } |
| | | ], |
| | | sample: [ |
| | | { required: true, message: '请选择样品名称', trigger: 'change' } |
| | | ], |
| | | sampleNum: [ |
| | | { required: true, message: '请填写样品数量', trigger: 'blur' } |
| | | ], |
| | | sampleStatus: [ |
| | | { required: true, message: '请选择样品状态', trigger: 'change' } |
| | | ], |
| | | formType: [ |
| | | { required: true, message: '请选择来样方式', trigger: 'change' } |
| | | ], |
| | | testQuantity: [ |
| | | { required: true, message: '请填写抽检数量', trigger: 'blur' } |
| | | ], |
| | | production: [ |
| | | { required: true, message: '请填写生产单位', trigger: 'blur' } |
| | | ], |
| | | productionEn: [ |
| | | { required: true, message: '请填写生产单位EN', trigger: 'blur' } |
| | | ], |
| | | }, |
| | | sample: { |
| | | sampleCode: null, |
| | | laboratory: null, |
| | | factory: null, |
| | | sampleType: null, |
| | | sample: null, |
| | | model: null, |
| | | modelNum: null, |
| | | sampleNum: 1, |
| | | isLeave: 0, |
| | | unit: null |
| | | }, |
| | | type: [], |
| | | selectUserDia: false, |
| | | tableData1: [], |
| | | tableLoading1: false, |
| | | multipleSelection: [], |
| | | column1: [ |
| | | {label: '客户名称', prop: 'company'}, |
| | | {label: '客户单位EN', prop: 'companyEn'}, |
| | | {label: '单位地址', prop: 'address'}, |
| | | {label: '单位地址EN', prop: 'addressEn'}, |
| | | {label: '单位电话', prop: 'phone'}, |
| | | {label: '加急额度', prop: 'num'}, |
| | | {label: '客户编号', prop: 'code2'}, |
| | | {label: '工厂域', prop: 'code'} |
| | | ], |
| | | page1: { |
| | | total:0, |
| | | size:10, |
| | | current:1 |
| | | }, |
| | | selectStandardTree: false, |
| | | search: null, |
| | | list: [], |
| | | selectStandardTreeLoading: false, |
| | | selectTree: null, |
| | | sampleViewEn: null, |
| | | expandedKeys: [], |
| | | sampleList: [], |
| | | sampleIds: [], |
| | | methodList: [], |
| | | addSampleDia: false, |
| | | count: 1, |
| | | productList: [], |
| | | productList0: [], |
| | | bsm1DiaList: [], |
| | | productIds: [], |
| | | getProductLoad: false, |
| | | saveLoad: false, |
| | | templateDia: false, |
| | | templateLoading: false, |
| | | templateName: '', |
| | | issuedDialogVisible: false, |
| | | distributeData: { |
| | | appointed: '', |
| | | userId: '', |
| | | sonLaboratory:'' |
| | | }, |
| | | personList: [], |
| | | upLoad: false, |
| | | models: [], |
| | | methods: [], |
| | | methodLoad: false, |
| | | noDialogVisible: false, |
| | | tell: '', |
| | | noLoading: false, |
| | | orderType: [], |
| | | filters: [], |
| | | formType: [], |
| | | currentMethod: null, |
| | | isAskOnlyRead: false, |
| | | sampleId: null, |
| | | bsmRow: null, |
| | | bsm1: false, |
| | | bsm1Val: null, |
| | | bsm1DiaAll: false, |
| | | cableConfigShow: false, |
| | | auxiliaryShow: false, |
| | | bsm3Dia: false, |
| | | // total: 0, |
| | | RTS: '', |
| | | totalArr: [], |
| | | addObj1: {}, |
| | | data() { |
| | | return { |
| | | active: '', |
| | | tabIndex: '', |
| | | currentId: '', |
| | | sampleSelectionList: [],//样品表格选中数据 |
| | | editTable:[], |
| | | template: null, |
| | | templates: [], |
| | | addObj: { |
| | | entrustCode: null, |
| | | custom: null, |
| | | company: null, |
| | | userId: null, |
| | | type: '0', |
| | | code: null, |
| | | appointed: null, |
| | | remark: null, // 备注 |
| | | remarkEn: null, // 备注英文 |
| | | sample: null, |
| | | factory: null, |
| | | laboratory: null, |
| | | sampleType: null, |
| | | sampleNum: 1, |
| | | unit: null, |
| | | model: null, |
| | | standardMethodListId: null, |
| | | symbolList:['RTS'], |
| | | inspectionItem:null, |
| | | inspectionItemSubclass:null, |
| | | methodS:null, |
| | | isBsm2Val2:false, |
| | | temperatureEngList: [], |
| | | isShowInput: false, |
| | | temId: '', |
| | | sonLaboratoryList:[], |
| | | selectiveEcho: [], // 检验下单的时候勾选检验项目,如果使用筛选提交显示检验项目为空 回显列表 |
| | | quarterItemOptions: [], // 查询季度信息 |
| | | specialStandardMethod: '', |
| | | isSpecial: false, |
| | | } |
| | | method: null, |
| | | phone: null, |
| | | processing: 1, |
| | | isLeave: 0, |
| | | orderType: null, |
| | | send: 1, |
| | | formType: '送检', // 来样方式 |
| | | sampleStatus: 'In good condition', // 样品状态 |
| | | testQuantity: '', // 样品状态 |
| | | production: null, |
| | | productionEn: null, |
| | | companyId: null, |
| | | prepareUser:null, // 委托人 |
| | | prepareUserEn:null, // 委托人英文 |
| | | prepareCode: '', // 委托人工号 |
| | | quarterItemId: '', |
| | | sampleView: '', // 样品名称(报告展示字段) |
| | | sampleViewEn: '', // 样品名称英文(报告展示字段) |
| | | }, |
| | | addObjRules: { // 表单校验规则 |
| | | orderType: [ |
| | | { required: true, message: '请选择检验类别', trigger: 'change' } |
| | | ], |
| | | company: [ |
| | | { required: true, message: '请选择委托单位', trigger: 'change' } |
| | | ], |
| | | phone: [ |
| | | { required: true, message: '请填写联系方式', trigger: 'blur' } |
| | | ], |
| | | type: [ |
| | | { required: true, message: '请选择紧急程度', trigger: 'change' } |
| | | ], |
| | | sample: [ |
| | | { required: true, message: '请选择样品名称', trigger: 'change' } |
| | | ], |
| | | sampleNum: [ |
| | | { required: true, message: '请填写样品数量', trigger: 'blur' } |
| | | ], |
| | | sampleStatus: [ |
| | | { required: true, message: '请选择样品状态', trigger: 'change' } |
| | | ], |
| | | formType: [ |
| | | { required: true, message: '请选择来样方式', trigger: 'change' } |
| | | ], |
| | | testQuantity: [ |
| | | { required: true, message: '请填写抽检数量', trigger: 'blur' } |
| | | ], |
| | | production: [ |
| | | { required: true, message: '请填写生产单位', trigger: 'blur' } |
| | | ], |
| | | productionEn: [ |
| | | { required: true, message: '请填写生产单位EN', trigger: 'blur' } |
| | | ], |
| | | }, |
| | | sample: { |
| | | sampleCode: null, |
| | | laboratory: null, |
| | | factory: null, |
| | | sampleType: null, |
| | | sample: null, |
| | | model: null, |
| | | modelNum: null, |
| | | sampleNum: 1, |
| | | isLeave: 0, |
| | | unit: null |
| | | }, |
| | | type: [], |
| | | selectUserDia: false, |
| | | tableData1: [], |
| | | tableLoading1: false, |
| | | multipleSelection: [], |
| | | column1: [ |
| | | {label: '客户名称', prop: 'company'}, |
| | | {label: '客户单位EN', prop: 'companyEn'}, |
| | | {label: '单位地址', prop: 'address'}, |
| | | {label: '单位地址EN', prop: 'addressEn'}, |
| | | {label: '单位电话', prop: 'phone'}, |
| | | {label: '加急额度', prop: 'num'}, |
| | | {label: '客户编号', prop: 'code2'}, |
| | | {label: '工厂域', prop: 'code'} |
| | | ], |
| | | page1: { |
| | | total:0, |
| | | size:10, |
| | | current:1 |
| | | }, |
| | | selectStandardTree: false, |
| | | search: null, |
| | | list: [], |
| | | selectStandardTreeLoading: false, |
| | | selectTree: null, |
| | | sampleViewEn: null, |
| | | expandedKeys: [], |
| | | sampleList: [], |
| | | upIndex: 0, |
| | | sampleIds: [], |
| | | methodList: [], |
| | | addSampleDia: false, |
| | | count: 1, |
| | | productList: [], |
| | | productList0: [], |
| | | bsm1DiaList: [], |
| | | productIds: [], |
| | | getProductLoad: false, |
| | | saveLoad: false, |
| | | templateDia: false, |
| | | templateLoading: false, |
| | | templateName: '', |
| | | issuedDialogVisible: false, |
| | | distributeData: { |
| | | appointed: '', |
| | | userId: '', |
| | | sonLaboratory:'' |
| | | }, |
| | | personList: [], |
| | | upLoad: false, |
| | | models: [], |
| | | methods: [], |
| | | methodLoad: false, |
| | | noDialogVisible: false, |
| | | tell: '', |
| | | noLoading: false, |
| | | orderType: [], |
| | | filters: [], |
| | | formType: [], |
| | | currentMethod: null, |
| | | isAskOnlyRead: false, |
| | | sampleId: null, |
| | | bsmRow: null, |
| | | bsm1: false, |
| | | bsm1Val: null, |
| | | bsm1DiaAll: false, |
| | | cableConfigShow: false, |
| | | auxiliaryShow: false, |
| | | bsm3Dia: false, |
| | | // total: 0, |
| | | RTS: '', |
| | | totalArr: [], |
| | | addObj1: {}, |
| | | model: null, |
| | | standardMethodListId: null, |
| | | symbolList:['RTS'], |
| | | inspectionItem:null, |
| | | inspectionItemSubclass:null, |
| | | methodS:null, |
| | | isBsm2Val2:false, |
| | | temperatureEngList: [], |
| | | isShowInput: false, |
| | | temId: '', |
| | | sonLaboratoryList:[], |
| | | selectiveEcho: [], // 检验下单的时候勾选检验项目,如果使用筛选提交显示检验项目为空 回显列表 |
| | | quarterItemOptions: [], // 查询季度信息 |
| | | specialStandardMethod: '', |
| | | isSpecial: false, |
| | | } |
| | | }, |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | this.productList = [] |
| | | }, |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | this.productList = [] |
| | | }, |
| | | productList: { |
| | | deep: true, |
| | | handler(val) { |
| | | if (val && val.length > 0) { |
| | | let arr = []; |
| | | val.forEach(item => { |
| | | if (item.sonLaboratory && !arr.find(a => a.value == item.sonLaboratory)) { |
| | | arr.push({ |
| | | text: item.sonLaboratory, |
| | | value: item.sonLaboratory |
| | | }) |
| | | } |
| | | }) |
| | | this.filters = arr |
| | | } |
| | | } |
| | | }, |
| | | sampleList: { |
| | | deep: true, |
| | | handler(val) { |
| | | this.getTotal() |
| | | } |
| | | }, |
| | | 'addObj.sample'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | }, |
| | | 'addObj.sampleNum'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | }, |
| | | tabIndex(val){ |
| | | if(val==4&&this.active==2){ |
| | | this.isSpecial = true |
| | | }else{ |
| | | this.isSpecial = false |
| | | productList: { |
| | | deep: true, |
| | | handler(val) { |
| | | if (val && val.length > 0) { |
| | | let arr = []; |
| | | val.forEach(item => { |
| | | if (item.sonLaboratory && !arr.find(a => a.value == item.sonLaboratory)) { |
| | | arr.push({ |
| | | text: item.sonLaboratory, |
| | | value: item.sonLaboratory |
| | | }) |
| | | } |
| | | }) |
| | | this.filters = arr |
| | | } |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.active = this.$route.query.active |
| | | this.tabIndex = this.$route.query.tabIndex |
| | | this.currentId = this.$route.query.currentId |
| | | sampleList: { |
| | | deep: true, |
| | | handler(val) { |
| | | this.getTotal() |
| | | } |
| | | }, |
| | | 'addObj.sample'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | }, |
| | | 'addObj.sampleNum'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | }, |
| | | tabIndex(val){ |
| | | if(val==4&&this.active==2){ |
| | | this.isSpecial = true |
| | | }else{ |
| | | this.isSpecial = false |
| | | } |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.active = this.$route.query.active |
| | | this.tabIndex = this.$route.query.tabIndex |
| | | this.currentId = this.$route.query.currentId |
| | | this.getInfo() |
| | | }, |
| | | activated() { |
| | | this.active = this.$route.query.active |
| | | this.tabIndex = this.$route.query.tabIndex |
| | | this.currentId = this.$route.query.currentId |
| | | this.getInfo(); |
| | | }, |
| | | methods: { |
| | | getInfo() { |
| | | this.getUserNowData() |
| | | this.selectStandardTreeList() |
| | | this.getAuthorizedPerson(); |
| | |
| | | this.isSpecial = false |
| | | } |
| | | }, |
| | | methods: { |
| | | getPrepareUser () { |
| | | getPrepareUser () { |
| | | // this.addObj.prepareUser = JSON.parse(localStorage.getItem("user")).name; |
| | | // this.addObj.prepareUserEn = JSON.parse(localStorage.getItem("user")).nameEn |
| | | // this.addObj.prepareCode = JSON.parse(localStorage.getItem("user")).account |
| | | }, |
| | | }, |
| | | // 编辑要求值表格 |
| | | editSpecial () { |
| | | this.isSpecial = true |
| | | this.$nextTick(() => { |
| | | this.$refs.productTable.doLayout(); |
| | | this.upIndex++ |
| | | }); |
| | | }, |
| | | getQuarterOnOrderList () { |
| | | getQuarterOnOrder().then(res => { |
| | |
| | | this.productList = row.insProduct |
| | | this.productList0 = JSON.parse(JSON.stringify(this.productList)) |
| | | this.$refs.sampleTable.setCurrentRow(row) |
| | | this.$nextTick(() => { |
| | | this.$refs.productTable.doLayout(); |
| | | this.upIndex++ |
| | | }); |
| | | setTimeout(() => { |
| | | this.productList.forEach(a => { |
| | | if (a.state == 1) this.toggleSelection(a) |