Merge branch 'master' of http://114.132.189.42:9002/r/mes-ocea-before
| | |
| | | > |
| | | <template #toolbar></template> |
| | | </ttable> |
| | | |
| | | |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button @click="innerVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="saveSelectRow">确 定</el-button> |
| | |
| | | ttable |
| | | }, |
| | | created(){ |
| | | |
| | | |
| | | }, |
| | | mounted() { |
| | | console.log(this.currshowlist,"开"); |
| | | }, |
| | | // props:['currentRow'], |
| | | methods: { |
| | |
| | | .part-dialog .el-dialog__body { |
| | | padding: 5px 20px; |
| | | } |
| | | |
| | | |
| | | .part-dialog .el-dialog__footer { |
| | | padding: 5px 20px 10px; |
| | | } |
| | | |
| | | |
| | | .part-dialog .el-dialog__body .avue-crud__pagination { |
| | | margin-top: 0px; |
| | | margin-bottom: 5px; |
| | |
| | | } |
| | | } */ |
| | | </style> |
| | | |
| | |
| | | // 设备编号 |
| | | { |
| | | minWidth: '30', |
| | | width: '200', |
| | | prop: 'number', |
| | | label: '设备编号', |
| | | sort: true, |
| | |
| | | // 设备名称 |
| | | { |
| | | minWidth: '30', |
| | | width: '100', |
| | | prop: 'name', |
| | | label: '设备名称', |
| | | sort: true, |
| | | isTrue: true, |
| | | isSearch: true, |
| | | searchInfoType: 'text' |
| | | }, |
| | | // 状态 |
| | | { |
| | | minWidth: '30', |
| | | prop: 'state', |
| | | label: '状态', |
| | | sort: true, |
| | | isTrue: true, |
| | | isSearch: true, |
| | |
| | | searchInfoType: 'text' |
| | | }, |
| | | // 邮箱 |
| | | { |
| | | minWidth: '30', |
| | | prop: 'email', |
| | | label: '邮箱', |
| | | sort: true, |
| | | isTrue: true, |
| | | isSearch: false, |
| | | searchInfoType: 'text' |
| | | }, |
| | | // { |
| | | // minWidth: '30', |
| | | // prop: 'email', |
| | | // label: '邮箱', |
| | | // sort: true, |
| | | // isTrue: true, |
| | | // isSearch: false, |
| | | // searchInfoType: 'text' |
| | | // }, |
| | | // 供应商 |
| | | { |
| | | minWidth: '30', |
| | |
| | | // 制造日期 |
| | | { |
| | | minWidth: '150', |
| | | width: '250', |
| | | width: '100', |
| | | prop: 'manufactureDate', |
| | | label: '制造日期', |
| | | sort: true, |
| | |
| | | // 安装日期 |
| | | { |
| | | minWidth: '150', |
| | | width: '250', |
| | | width: '100', |
| | | prop: 'installDate', |
| | | label: '安装日期', |
| | | sort: true, |
| | |
| | | isSearch: true, |
| | | formatter: this.formatReceiveTime, |
| | | searchInfoType: 'datetimerange' |
| | | }, |
| | | // 状态 |
| | | { |
| | | minWidth: '30', |
| | | prop: 'state', |
| | | label: '状态', |
| | | sort: true, |
| | | isTrue: true, |
| | | isSearch: true, |
| | | searchInfoType: 'text' |
| | | } |
| | | ], |
| | | toolbar: [], |
| | |
| | | // 设备编号 |
| | | { |
| | | minWidth: '30', |
| | | width: '100', |
| | | prop: 'code', |
| | | label: '设备编号', |
| | | sort: true, |
| | |
| | | // 设备名称 |
| | | { |
| | | minWidth: '30', |
| | | width: '100', |
| | | prop: 'name', |
| | | label: '设备名称', |
| | | sort: true, |
| | |
| | | // 制造日期 |
| | | { |
| | | minWidth: '150', |
| | | width: '250', |
| | | width: '150', |
| | | prop: 'createTime', |
| | | label: '校准时间', |
| | | sort: true, |
| | |
| | | |
| | | { |
| | | minWidth: '150', |
| | | width: '250', |
| | | width: '150', |
| | | prop: 'updateTime', |
| | | label: '校准到期时间', |
| | | sort: true, |
| | |
| | | <el-dialog title="标签列表" :visible.sync="diaPrintTab" width="28%" top="5vh"> |
| | | <div style="width:100%;height: 400px;overflow-y: auto;"> |
| | | <div class="dia_body"> |
| | | <el-checkbox |
| | | <el-checkbox |
| | | style="margin: 10px 5px;" |
| | | :indeterminate="isIndeterminate" |
| | | v-model="checkAll" |
| | | :indeterminate="isIndeterminate" |
| | | v-model="checkAll" |
| | | @change="handleCheckAllChange">全选</el-checkbox> |
| | | <el-checkbox-group @change="changePrintCode()" v-model="checkIndexList"> |
| | | <el-card class="box-card" v-for="(item, i) in qrData" :key="i" style="margin-bottom: 15px; font-size: 16px !important;"> |
| | |
| | | return this.bomTypeDbOptions |
| | | } |
| | | }, |
| | | |
| | | |
| | | { |
| | | minWidth: '120', |
| | | prop: 'manufactureAttr', |
| | |
| | | printable: 'printMOrder',//页面 |
| | | type: "html",//文档类型 |
| | | maxWidth:450, |
| | | targetStyles:['*'], |
| | | targetStyles:['*'], |
| | | style: `@page { |
| | | margin:0; |
| | | size: 360px 175px; |
| | |
| | | console.log(data); |
| | | let index = Number(data.qtyRequired) + Number(data.scrapQty) |
| | | if(index>0){ |
| | | for(var i=1;i<= index;i++){ |
| | | for(var i=index;i>= 1;i--){ |
| | | let obj = { |
| | | orderNo: data.customerOrderNo, |
| | | cName: data.customerName, |
| | |
| | | :header-cell-style="{textAlign:'center',color:'black',backgroundColor:'#fafafa'}" |
| | | :cell-style="{textAlign:'center'}" row-key="iid" default-expand-all |
| | | style="width: 100%" ref="table" :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
| | | <el-table-column type="index" label="序号" width="60"></el-table-column> |
| | | <el-table-column type="index" prop="parentIndex" label="序号" width="60"> |
| | | <template scope="scope"> |
| | | <span v-if="scope.row.isIndex">{{scope.row.parentIndex}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="项目" prop="father" show-overflow-tooltip width="140" ></el-table-column> |
| | | <el-table-column prop="iname" label="指标" show-overflow-tooltip width="140" ></el-table-column> |
| | | <el-table-column prop="iunit" label="单位" show-overflow-tooltip width="140" ></el-table-column> |
| | |
| | | this.processInspectVo.locName = result.locName |
| | | this.processInspectVo.productNo = result.productNo |
| | | let userList = [] |
| | | result.children.forEach(item=>{ |
| | | result.children.forEach((item,index)=>{ |
| | | item.iid = Math.random() |
| | | item.isIndex = true; |
| | | item.parentIndex = index + 1; |
| | | if(item.children != undefined){ |
| | | item.children.forEach(obj=>{ |
| | | let arr = [] |
| | |
| | | row-key="randomId" class="l-mes" |
| | | default-expand-all |
| | | :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
| | | <el-table-column type="index" label="序号" width="60"> |
| | | <el-table-column type="index" prop="parentIndex" label="序号" width="60"> |
| | | <template scope="scope"> |
| | | <span v-if="scope.row.isIndex">{{scope.row.parentIndex}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="name" label="项目" width="160"> |
| | | <template slot-scope="scope"> |
| | |
| | | } |
| | | this.getAllInspect() |
| | | this.init() |
| | | this.checkShowState() |
| | | |
| | | }, |
| | | watch:{ |
| | |
| | | if(ele.children){ |
| | | ele.children.forEach(c=>{ |
| | | if(c.pid){ |
| | | num++ |
| | | num+=1 |
| | | } |
| | | }) |
| | | } |
| | |
| | | clickAddLine() { |
| | | this.list.push({ |
| | | name: '', |
| | | isIndex : true, |
| | | parentIndex : this.list.length + 1, |
| | | randomId: Math.random(), |
| | | isEdit: true, |
| | | children: [{ |
| | |
| | | let userNameList = [] |
| | | if(dataList){ |
| | | let tempList = [] |
| | | dataList.forEach(ele=>{ |
| | | dataList.forEach((ele,index)=>{ |
| | | let obj = { |
| | | randomId: Math.random(), |
| | | name: ele.inspectName, |
| | | isIndex: true, |
| | | parentIndex: index+1, |
| | | children: [] |
| | | } |
| | | if(ele.children){ |
| | |
| | | }) |
| | | _than.list = tempList |
| | | } |
| | | data.packageInsProductS.forEach(item => { |
| | | data.packageInsProductS.forEach((item,index) => { |
| | | if (item.children) { |
| | | let ele = { |
| | | isIndex: true, |
| | | parentIndex: index+1, |
| | | isEdit: true, |
| | | randomId: Math.random(), |
| | | name: null, |
| | |
| | | _than.list.push(ele) |
| | | } |
| | | }) |
| | | // let find1 = this.list.find(ele=>ele.name===inspect1[0].name&&ele.isEdit) !=undefined; |
| | | // let find2 = this.list.find(ele=>ele.name===inspect2[0].name&&ele.isEdit) !=undefined; |
| | | // this.isShow = find1||find2 |
| | | |
| | | _than.conclusionTable = [{ |
| | | packageNo: data.packageNo, |
| | | userName: Array.from(new Set(userNameList)).join(','), |
| | |
| | | _than.$nextTick(()=>{ |
| | | if(_than.list.length>0){ |
| | | _than.changeResult() |
| | | _than.checkShowState() |
| | | } |
| | | }) |
| | | }).catch(error=>{ |
| | |
| | | default-expand-all style="width: 100%" |
| | | ref="table" |
| | | :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"> |
| | | <el-table-column type="index" label="序号" show-overflow-tooltip width="60"></el-table-column> |
| | | <el-table-column type="index" prop="parentIndex" label="序号" width="60"> |
| | | <template scope="scope"> |
| | | <span v-if="scope.row.isIndex">{{scope.row.parentIndex}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="项目" prop="father" show-overflow-tooltip width="140"></el-table-column> |
| | | <el-table-column prop="iname" label="指标" show-overflow-tooltip width="140"></el-table-column> |
| | | <el-table-column prop="iunit" label="单位" show-overflow-tooltip width="140"></el-table-column> |
| | |
| | | }, |
| | | methods: { |
| | | queryCode(){ |
| | | console.log("llll"); |
| | | this.workshop = true |
| | | console.log(this.workshop); |
| | | // this.paramObj = { |
| | |
| | | this.processInspectVo.unit = result.punit |
| | | this.processInspectVo.quantity = result.quantity |
| | | let userList = [] |
| | | result.children.forEach(item => { |
| | | result.children.forEach((item,index) => { |
| | | item.isIndex = true; |
| | | item.parentIndex = index + 1; |
| | | item.iid = Math.random() |
| | | if (item.children != undefined) { |
| | | item.children.forEach(obj => { |
| | |
| | | <template> |
| | | <div class="mod-config"> |
| | | <basic-container> |
| | | <ttable |
| | | <ttable |
| | | :table="table" |
| | | :resultData="resultData" |
| | | @handleSelectionChange="handleSelectionChange" |
| | |
| | | import { mapGetters } from 'vuex' |
| | | import PrintJS from 'print-js' |
| | | import { transformZip } from '@/util/fileTransform' |
| | | import printTemplate from './rawMaterial-print.vue' |
| | | import printTemplate from './rawMaterial-print' |
| | | export default { |
| | | data() { |
| | | return { |
| | |
| | | RawMaterialForm, |
| | | printTemplate, |
| | | }, |
| | | created() { |
| | | created() { |
| | | if(this.permissions.quality_rawMaterial_add){ |
| | | this.table.toolbar.push({ |
| | | text: '新增', |
| | |
| | | } |
| | | this.$router.push({ |
| | | name: 'rawMaterialForm', |
| | | query: { |
| | | query: { |
| | | id: row == null ? null : row.id, |
| | | resultVal: row == null ? null : row.judgeState |
| | | } |
| | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | |
| | | row-key="iid" |
| | | default-expand-all |
| | | :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
| | | <el-table-column type="index" label="序号" width="60"> |
| | | <el-table-column type="index" prop="parentIndex" label="序号" width="60"> |
| | | <template scope="scope"> |
| | | <span v-if="scope.row.isIndex">{{scope.row.parentIndex}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="father" label="检验项目" width="160"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-if="scope.row.children" style="width:90%" :disabled="dataForm.id!=null" v-model="scope.row.father" placeholder="请输入检验项目"></el-input> |
| | | <el-input v-if="scope.row.children" style="width:80%" :disabled="dataForm.id!=null" v-model="scope.row.father" placeholder="请输入检验项目"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="name" label="项目" width="160"> |
| | |
| | | <template slot-scope="scope"> |
| | | <div v-if="!scope.row.children"> |
| | | <el-tooltip :disabled="scope.row.deviceId != null" class="item" effect="dark" content="请先选择设备!" placement="top-start"> |
| | | <el-select style="width:100%" allow-create filterable default-first-option |
| | | <!-- <el-autocomplete clearable |
| | | :disabled="scope.row.deviceId == null || (dataForm.id!=null&&resultVal!=null)" |
| | | @blur="changeState(scope.row,scope.$index)" |
| | | v-model="scope.row.testValueList[index]" |
| | | :fetch-suggestions="querySearch" |
| | | placeholder="请输入或选择检测值" > |
| | | <i style="line-height: normal;padding: 10px 7px;" class="el-icon-arrow-down" slot="suffix"></i> |
| | | <template slot-scope="{ item }"> |
| | | <div>{{ item.value }}</div> |
| | | </template> |
| | | </el-autocomplete> --> |
| | | |
| | | <el-select style="width:100%" filterable |
| | | :disabled="scope.row.deviceId == null || (dataForm.id!=null&&resultVal!=null)" |
| | | v-model="scope.row.testValueList[index]" |
| | | placeholder="请输入或选择检测值" |
| | | @change="changeState(scope.row,scope.$index)"> |
| | | @change="changeState(scope.row,scope.$index)" |
| | | @blur="selectBlur" |
| | | > |
| | | <el-option label="是" value="是"/> |
| | | <el-option label="否" value="否"/> |
| | | </el-select> |
| | |
| | | }, |
| | | }, |
| | | methods:{ |
| | | querySearch(queryString, cb){ |
| | | // 调用 callback 返回建议列表的数据 |
| | | cb([{value:'是'},{value:'否'}]); |
| | | }, |
| | | tabsClick(tab,even){ |
| | | if(tab.index == 1){ |
| | | if(this.dataForm.rawInsNo==null){ |
| | |
| | | this.updateDevice(this.row,this.proIndex) |
| | | }else{ |
| | | this.$message({ |
| | | message: '未识别出二位码计量器具信息!', |
| | | message: '二维码未识别出计量器具信息!', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | |
| | | getResultInfo(data){ |
| | | if(!data.includes("part_no")){ |
| | | this.$message({ |
| | | message: '未识别出二维码零件信息!', |
| | | message: '二维码未识别出零件信息!', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | |
| | | this.showPart = true |
| | | }else{ |
| | | this.$message({ |
| | | message: '未识别出二维码零件信息!', |
| | | message: '二维码未识别出零件信息!', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | |
| | | this.dataForm.message = param.message |
| | | this.dataForm.projectName = param.projectName |
| | | this.projectList = param.rawInsProducts == null ? [] : param.rawInsProducts |
| | | param.rawInsProducts.forEach(o=>{ |
| | | this.clickAddLine(o) |
| | | param.rawInsProducts.forEach((o,index)=>{ |
| | | this.clickAddLine(o,index) |
| | | }) |
| | | } |
| | | |
| | |
| | | this.empiricalValueAdd = this.empiricalValueAdd + 1; |
| | | }, |
| | | // 添加行 |
| | | clickAddLine(row) { |
| | | clickAddLine(row,index) { |
| | | let ele = { |
| | | fId: Math.random(), |
| | | father: null, |
| | |
| | | children:[] |
| | | } |
| | | if(row){ |
| | | ele.isIndex = true; |
| | | ele.parentIndex = index + 1; |
| | | ele.father = row.father?row.father:null |
| | | row.children.forEach(item => { |
| | | ele.children.push({ |
| | |
| | | }) |
| | | this.list.push(ele) |
| | | }else{ |
| | | ele.isIndex = true; |
| | | ele.parentIndex = this.list.length + 1; |
| | | ele.children.push({ |
| | | deviceId: null, |
| | | deviceName: null, |
| | |
| | | this.dataForm.createUser = data.createUser |
| | | let userNameList = [] |
| | | this.list = [] |
| | | data.children.forEach(item => { |
| | | data.children.forEach((item,index) => { |
| | | if (item.children) { |
| | | let ele = { |
| | | iid: null, |
| | | father: null, |
| | | children: [] |
| | | } |
| | | ele.isIndex = true; |
| | | ele.parentIndex = index + 1; |
| | | ele.iid = Math.random() |
| | | ele.father = item.rpFather |
| | | if (item.children != undefined) { |
| | | item.children.forEach(obj => { |
| | | item.children.forEach((obj) => { |
| | | let arr= [] |
| | | if(obj.userName){ |
| | | userNameList.push(obj.userName) |
| | |
| | | this.conclusionTable = [] |
| | | } |
| | | }, |
| | | selectBlur(e){ |
| | | console.log(e); |
| | | }, |
| | | changeState(row, index) { |
| | | if(row){ |
| | | let isTrue = true |
| | | for(var i=0;i<row.testValueList.length;i++){ |
| | | let val = row.testValueList[i] |
| | | let reg = /(^-?[0-9]{1,6}$)|(^-?[0-9]{1,6}[\.]{1}[0-9]{1,3}$)/ |
| | | if(!reg.test(val) && !['是','否'].includes(val)){ |
| | | this.$message.error("请输入数字或选择是否") |
| | | row.testValueList[i] = null |
| | | isTrue = false |
| | | } |
| | | } |
| | | if(!isTrue){ |
| | | return |
| | | } |
| | | console.log(row.testValueList); |
| | | return |
| | | this.$nextTick(()=>{ |
| | | if(row){ |
| | | let isTrue = true |
| | | for(var i=0;i<row.testValueList.length;i++){ |
| | | let val = row.testValueList[i] |
| | | let reg = /(^-?[0-9]{1,6}$)|(^-?[0-9]{1,6}[\.]{1}[0-9]{1,3}$)/ |
| | | if(!reg.test(val) && !['是','否'].includes(val)){ |
| | | row.testValueList[i] = null |
| | | this.$message.error("请输入数字或选择是否") |
| | | isTrue = false |
| | | } |
| | | } |
| | | if(!isTrue){ |
| | | return |
| | | } |
| | | } |
| | | if (row.rpId != null && row.rpId != '') { |
| | | let val = row.testValueList.join(",") |
| | | if (val === undefined || val === '' || val === null) { |
| | | return |
| | | } |
| | | console.log(val); |
| | | console.log(...row.testValueList); |
| | | let obj = { |
| | | deviceId: row.deviceId, |
| | | rpId: row.rpId, |
| | | testValue: val, |
| | | note: row.note |
| | | } |
| | | console.log(obj); |
| | | return |
| | | updateRawInsProduct(obj).then(res => { |
| | | if (res.data.code == 0) { |
| | | this.$message.success("更新成功") |
| | |
| | | this.init() |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | // 删除子项目 |
| | | delChildren(row,index,isParent) { |
| | |
| | | // const url = 'http://192.168.2.7:9999' |
| | | // const url = 'https://ztms-mes.chinaztt.cn/' |
| | | |
| | | const url = 'http://localhost:9999' |
| | | const url = 'http://localhost:9999' |
| | | |
| | | |
| | | const localUrl = 'http://localhost:8089' |