Merge branch 'master' of http://114.132.189.42:9002/r/center-lims-before
| | |
| | | <html> |
| | | <head> |
| | | <meta charset="utf-8"> |
| | | <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> |
| | | <meta http-equiv="Expires" CONTENT="0"> |
| | | <meta http-equiv="Cache-Control" CONTENT="no-cache"> |
| | | <meta http-equiv="Pragma" CONTENT="no-cache"> |
| | | |
| | | <meta http-equiv="pragram" content="no-cache"> |
| | | <meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate"> |
| | | <meta http-equiv="expires" content="0"> |
| | | <title>LIMSå®éªå®¤ç®¡çç³»ç»</title> |
| | | <link rel="icon" type="image/x-icon" href="./static/img/logo.png"> |
| | | |
| | |
| | | <el-button size="medium" type="primary" @click="openConfig" v-if="addObj.sampleType==='å
ç¼'">å
纤é
ç½®</el-button> |
| | | <el-button size="medium" type="primary" @click="save" :loading="saveLoad" v-show="active==1">æäº¤</el-button> |
| | | <!-- å®¡æ ¸ --> |
| | | <el-button size="medium" @click="upInsOrderOfState(2)" :loading="saveLoad" v-show="active==3" |
| | | <el-button size="medium" @click="upInsOrderOfState(2)" :loading="saveLoad" v-show="active==3&&addObj.companyId" |
| | | :disabled="saveLoad">ä¸éè¿</el-button> |
| | | <el-button size="medium" type="primary" @click="upInsOrderOfState(1)" :loading="saveLoad" |
| | | v-show="active==3">éè¿</el-button> |
| | | v-show="active==3&&addObj.companyId">éè¿</el-button> |
| | | <el-button size="medium" @click="$parent.playOrder(0)"> |
| | | <span style="color: #3A7BFA;">è¿å</span> |
| | | </el-button> |
| | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <el-table class="el-table sampleTable" ref="sampleTable" :data="sampleList" height="250px" tooltip-effect="dark" |
| | | <el-table class="el-table sampleTable" ref="sampleTable" :data="sampleList" max-height="400px" tooltip-effect="dark" |
| | | border @selection-change="selectSample" highlight-current-row @row-click="rowClick" style="margin-top: 10px;"> |
| | | <el-table-column type="selection" width="60" :selectable="selectable" v-if="active==1"></el-table-column> |
| | | <el-table-column type="index" label="åºå·" width="65" align="center"></el-table-column> |
| | |
| | | </el-table-column> |
| | | <el-table-column prop="proNum" label="å¾
æ£é¡¹æ°é" width="105" align="center"></el-table-column> |
| | | </el-table> |
| | | <el-table class="el-table" ref="productTable" :data="productList" height="380px" tooltip-effect="dark" border |
| | | <el-table class="el-table" ref="productTable" :data="productList" max-height="400px" tooltip-effect="dark" border |
| | | @selection-change="selectProduct" style="margin-bottom: 10px;" @select="upProductSelect" |
| | | :row-class-name="tableRowClassName" v-loading="getProductLoad" @select-all="handleAll"> |
| | | <el-table-column type="selection" width="65" :selectable="selectable" v-if="active==1"></el-table-column> |
| | |
| | | <template slot-scope="scope"> |
| | | <el-input size="small" placeholder="è¦æ±å¼" v-model="scope.row.ask" clearable type="textarea" |
| | | :autosize="{ minRows: 1, maxRows: 3}" @change="e=>requestChange(e,scope.row,'ask')" |
| | | v-if="active==1&&isAskOnlyRead"></el-input> |
| | | v-if="active==1&&isAskOnlyRead&&scope.row.inspectionValueType!='5'"></el-input> |
| | | <span v-else> |
| | | <!-- <template v-if="(scope.row.ask.indexOf('D')>-1 |
| | | ||scope.row.ask.indexOf('W')>-1 |
| | |
| | | <el-button type="primary" @click="addTemplateDia" :loading="templateLoading">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog title="æ£éªä¸å" :visible.sync="issuedDialogVisible" width="400px"> |
| | | <el-dialog title="æ£éªä¸å" :visible.sync="issuedDialogVisible" width="400px" :close-on-click-modal="false" |
| | | :close-on-press-escape="false" :show-close="false"> |
| | | <div class="body" style="max-height: 60vh;"> |
| | | <el-row> |
| | | <el-col class="search_thing" :span="22"> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-row> |
| | | <el-button @click="issuedDialogVisible=false">å æ¶</el-button> |
| | | <el-button @click="issuedDialogVisible=false;$parent.playOrder(0)">å æ¶</el-button> |
| | | <el-button type="primary" @click="submitForm2" :loading="upLoad">ç¡® å®</el-button> |
| | | </el-row> |
| | | </span> |
| | |
| | | prop="value" |
| | | label="è¯å«ç¬¦å¼"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.value" placeholder="请è¾å
¥" size="small"></el-input> |
| | | <el-input v-model="scope.row.value" placeholder="请è¾å
¥" @input="inputValueHandler(scope.row,scope.$index)" size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | sampleSelectionList: [],//æ ·åè¡¨æ ¼é䏿°æ® |
| | | editTable:[], |
| | | template: null, |
| | | templates: [], |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | //ç¹æ®å¼å¡«åå¤ç |
| | | inputValueHandler(row,index){ |
| | | if(row){ |
| | | const nextIndex = index+1 |
| | | for (let i = nextIndex; i < this.editTable.length; i++) { |
| | | const element = this.editTable[i]; |
| | | if(element.model==row.model){ |
| | | this.editTable[i].value = row.value |
| | | }else{ |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | |
| | | }, |
| | | spliceData () { |
| | | if (!this.circulateForm.entrustNum || !this.circulateForm.entrustTime || !this.circulateForm.entrustPoint || this.opticalProjectList.length === 0 || this.temperatureData.length === 0) { |
| | | this.$message.error('请填å宿´æ°æ®') |
| | |
| | | isHaveBushing = false |
| | | } |
| | | }) |
| | | //è¿æ»¤æ£æµé¡¹ï¼å»é¤ç¹æ®é¡¹ |
| | | let filterProductList = this.productListSelected.filter(ele=>ele.bsm==0&&/[0-9]/.test(ele.ask)).filter(ele=>{ |
| | | if(select[1].indexOf('éä¿¡')>=0 && ['å
ç¼','å
纤'].includes(select[2])){ |
| | | return !['温度循ç¯','å
纤æ¥å¤´æè'].includes(ele.inspectionItem) |
| | | } |
| | | return true |
| | | }).filter(ele=>{ |
| | | if(select[1].indexOf('çµå')>=0){ |
| | | return !['温åè¯éª','ç循ç¯'].includes(ele.inspectionItem) |
| | | } |
| | | return true |
| | | }) |
| | | //æ ¡éªæ£éªé¡¹çè¦æ±å¼åè¦æ±æè¿° |
| | | const isTrue = this.checkRequiredValueAndRemark(filterProductList) |
| | | if(!isTrue){ |
| | | this.$message.error('æ£éªé¡¹çè¦æ±å¼ä¸è¦æ±æè¿°ä¸å¹é
ï¼ è¯·æ£æ¥') |
| | | return |
| | | } |
| | | |
| | | console.log('isHaveBushing===', this.totalArr) |
| | | // inspectionItem |
| | | let spcialItem = null//this.totalArr.find(a => a.state == 1 && a.inspectionItem.includes('æ¾å¥ç®¡')) |
| | | // console.log('isHaveBushing===', isHaveBushing) |
| | | if (productListSelected && select[2] === 'å
ç¼' && isHaveBushing === false) { |
| | | this.$message.error('å
ç¼æ¸©åº¦å¾ªç¯é¡¹ç®å¿
é¡»è¿è¡å
纤é
ç½®') |
| | | |
| | | this.$refs.sampleTable.setCurrentRow(this.currentMethod, true) |
| | | this.rowClick(this.currentMethod) |
| | | this.sampleIds = [this.currentMethod.id] |
| | | this.openConfig() |
| | | return |
| | | }else if(spcialItem&& isHaveBushing === false){ |
| | | this.$message.error('æ¾å¥ç®¡é¡¹ç®å¿
é¡»è¿è¡å
纤é
ç½®') |
| | | this.$refs.sampleTable.setCurrentRow(this.currentMethod, true) |
| | | this.rowClick(this.currentMethod) |
| | | this.sampleIds = [this.currentMethod.id] |
| | |
| | | this.saveMethod(sampleList) |
| | | } |
| | | } |
| | | }, |
| | | checkRequiredValueAndRemark(data){ |
| | | let isTrue = true |
| | | try{ |
| | | data.forEach(ele=>{ |
| | | if(['â¤','â¥','>','<','='].includes(ele.ask[0])){ |
| | | const askVal = ele.ask.substring(1,ele.ask.length) |
| | | if(isNaN(askVal) || ele.tell.indexOf(askVal)<0){ |
| | | isTrue = false |
| | | } |
| | | } |
| | | if(ele.ask.indexOf('-')>0 && ele.ask.length>1){ |
| | | let tell = ele.tell |
| | | if(ele.tell.indexOf('~')>0){ |
| | | tell = ele.tell.replace('~','-') |
| | | } |
| | | const splits = ele.ask.split('-') |
| | | if(splits.length==2 && !isNaN(splits[0]) && !isNaN(splits[1])){ |
| | | let min = Math.min(...splits) |
| | | let max = Math.max(...splits) |
| | | if(ele.tell.indexOf('±')<0&&tell.indexOf(ele.ask)<0){ |
| | | isTrue = false |
| | | }else if(ele.tell.indexOf('±')>0&&ele.tell!=ele.ask){ |
| | | let splitNums = ele.tell.split('±') |
| | | if(splitNums.length<2){ |
| | | isTrue = false |
| | | }else{ |
| | | let minTell = Number(splitNums[0])-Number(splitNums[1]) |
| | | let maxTell = Number(splitNums[0])+Number(splitNums[1]) |
| | | if(minTell!=min || maxTell!=max){ |
| | | isTrue = false |
| | | } |
| | | } |
| | | } |
| | | }else{ |
| | | isTrue = false |
| | | } |
| | | } |
| | | }) |
| | | }catch(error){ |
| | | console.log(error); |
| | | isTrue = false |
| | | } |
| | | return isTrue |
| | | }, |
| | | save0(){ |
| | | if(this.editTable.every(m=>m.value)){ |
| | |
| | | }, |
| | | saveMethod(sampleList){ |
| | | this.saveLoad = true |
| | | console.log(333333,sampleList) |
| | | this.$axios.post(this.$api.insOrder.addInsOrder, { |
| | | str: JSON.stringify({ |
| | | insOrder: this.addObj, |
| | |
| | | }) |
| | | }, |
| | | getProNum() { |
| | | this.sampleList.forEach((m, i) => { |
| | | Vue.set(this.sampleList[i], 'proNum', m.insProduct.filter(a => a.state == 1).length) |
| | | this.sampleSelectionList.forEach((m, i) => { |
| | | Vue.set(this.sampleSelectionList[i], 'proNum', m.insProduct.filter(a => a.state == 1).length) |
| | | }) |
| | | this.$refs.sampleTable.doLayout() |
| | | }, |
| | |
| | | val.forEach(a => { |
| | | this.sampleIds.push(a.id) |
| | | }) |
| | | this.sampleSelectionList = val |
| | | }, |
| | | delSample() { |
| | | this.sampleIds.forEach(a => { |
| | |
| | | this.sampleId = row.id |
| | | if (this.active !== 1) { |
| | | this.sampleIds = [] |
| | | this.sampleIds.push(row.id) |
| | | this.sampleSelectionList.forEach(ele=>{ |
| | | if(ele.id == row.id){ |
| | | this.sampleIds.push(row.id) |
| | | } |
| | | }) |
| | | } |
| | | this.productList = row.insProduct |
| | | this.productList0 = JSON.parse(JSON.stringify(this.productList)) |
| | |
| | | row.bsm1 = false |
| | | }else if(arr.length>0){ |
| | | try{ |
| | | row.bsmRow = this.HaveJson(row) |
| | | let section = arr[0].section |
| | | let arr0 = JSON.parse(row.section) |
| | | let arr1 = JSON.parse(row.ask) |
| | |
| | | } |
| | | }, |
| | | handleAll(e) { |
| | | console.log(1111,this.bsm1DiaAll,this.bsm1Dia) |
| | | // console.log('e---', e) |
| | | if (e.length > 0) { |
| | | this.productList.map(m => { |
| | |
| | | this.$message.error('æªé䏿 ·å') |
| | | return |
| | | } |
| | | this.sampleIds = [this.sampleId] |
| | | this.$axios.post(this.$api.insBushing.selectBushingBySampleId, { |
| | | sampleId: this.sampleId |
| | | }).then(res => { |
| | |
| | | |
| | | .search .form-inline { |
| | | padding-top: 20px; |
| | | padding-left: 50px; |
| | | padding-left: 0px; |
| | | } |
| | | |
| | | .center { |
| | |
| | | </el-col> |
| | | </el-row> |
| | | <div class="search"> |
| | | <el-form :inline="true" :model="searchForm" class="form-inline" label-width="100px"> |
| | | <el-form :inline="true" :model="searchForm" class="form-inline" label-width="100px" label-position="right"> |
| | | <el-form-item label="å§æç¼å·:"> |
| | | <el-input clearable v-model="insOrder.entrustCode" disabled size="small" placeholder="请è¾å
¥"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·åç¼å·:"> |
| | | <el-input clearable v-model="currentSample.sampleCode" disabled size="small" placeholder="请è¾å
¥"></el-input> |
| | | <el-tooltip :disabled="!currentSample.sampleCode" :content="currentSample.sampleCode"> |
| | | <el-input clearable v-model="currentSample.sampleCode" disabled size="small" placeholder="请è¾å
¥" ></el-input> |
| | | </el-tooltip> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååç§°:"> |
| | | <el-input clearable v-model="currentSample.sample" disabled size="small" placeholder="请è¾å
¥"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·åæ°é:"> |
| | | <el-input clearable v-model="sampleProduct.length" disabled size="small" placeholder="请è¾å
¥"></el-input> |
| | | <el-input clearable v-model="sampleProduct.length" disabled size="small" placeholder="请è¾å
¥" ></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ä¸åæ¶é´:"> |
| | | <el-input clearable v-model="insOrder.sendTime" disabled size="small" placeholder="请è¾å
¥"></el-input> |
| | |
| | | <el-form-item label="å½åæ ·å使°:"> |
| | | <el-tag v-if="currentKey">{{ `NO.${currentKey}` }}</el-tag> |
| | | </el-form-item> |
| | | <el-form-item label="夿³¨:"> |
| | | <span style="color:red">{{ insOrder.remark?insOrder.remark:'-' }}</span> |
| | | <!-- <el-tag v-if="currentKey">{{ insOrder.remark }}</el-tag> --> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="center"> |
| | |
| | | </el-radio-group> |
| | | </div> |
| | | <div style="display: flex;align-items: center;"> |
| | | <span v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName=='æåç¼æ£éªåå§è®°å½'"> å¥ç®¡ï¼</span> |
| | | <el-select v-model="currentTab" placeholder="è¯·éæ©" @change="m=>handleChange(m,3)" v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName=='æåç¼æ£éªåå§è®°å½'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in casing" |
| | | :key="item.id" |
| | | :label="item.color" |
| | | :value="item.id"> |
| | | <span style="float: left">{{ item.color}}</span> |
| | | <el-tag :type="item.state==1?'success':'danger'" style="float: right;margin-top: 5px;" size="small">{{ item.state==1?'å·²æ£':'æªæ£' }}</el-tag> |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'"> å
纤带ï¼</span> |
| | | <el-select v-model="currentTab" placeholder="è¯·éæ©" @change="m=>handleChange(m,1)" v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'" size="small"> |
| | | <el-select v-model="currentTab" placeholder="è¯·éæ©" @change="m=>handleChange(m,1)" v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in fibers" |
| | | :key="item.value" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'"> å
纤ï¼</span> |
| | | <el-select v-model="currentTab" placeholder="è¯·éæ©" @change="m=>handleChange(m,2)" v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'" size="small"> |
| | | <el-select v-model="currentTab" placeholder="è¯·éæ©" @change="m=>handleChange(m,2)" v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='æ¸©åº¦å¾ªç¯æ£éªåå§è®°å½'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in fiber" |
| | | :label="item.bushColor+'-'+item.color" |
| | |
| | | size="medium" style="margin-right: 5px;">{{item.label}}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="checkName" label="æ£éªäºº" min-width="80px" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="isLeave" label="æ¯å¦çæ ·" width="95px" show-overflow-tooltip align="center"> |
| | | <template slot-scope="scope"> |
| | | <span>{{ scope.row.isLeave==0?'å¦':'æ¯' }}</span> |
| | |
| | | requiredUp: [] |
| | | }, |
| | | upIndex: 0, |
| | | getReportModelLoading:false, |
| | | insOrder: {}, |
| | | sampleProduct: [], |
| | | typeList: [], |
| | |
| | | temptList:null, |
| | | fiber:[], |
| | | fibers:[], |
| | | casing:[], |
| | | currentTab:null, |
| | | wareForm:{ |
| | | inspectionItem:1, |
| | |
| | | this.tableList = this.tableLists.filter(m => m.templateId == val1) |
| | | this.handleTableData() |
| | | } |
| | | // this.$delete(this.tableList,0) |
| | | // this.$set(this.tableList, 0, m) |
| | | // this.handleTableData() |
| | | } |
| | | }) |
| | | this.handleCasing() |
| | | if(this.tableLists.find(m=>m.templateId==val1)&&(this.tableLists.find(m=>m.templateId==val1).templateName=='æåç¼æ£éªåå§è®°å½')){ |
| | | if(this.casing.length>0){ |
| | | this.handleChange(this.casing[0].id,3) |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | equipForm:{ |
| | |
| | | value:data[i][j].result, |
| | | frequency:data[i].frequency |
| | | } |
| | | let list = this.tableList[0].arr |
| | | list.forEach((item,index)=>{ |
| | | let num0 = 0; |
| | | let str = '' |
| | | let str0 = i+','+j |
| | | item.forEach(m=>{ |
| | | if(m.v.ps&&(m.v.ps.value=='æ£éªå项'||m.v.ps.value=='æ£éªé¡¹')){ |
| | | if(m.v.ps&&m.v.ps.value=='æ£éªé¡¹'){ |
| | | if(num0==0){ |
| | | str = m.v.v+',' |
| | | num0++ |
| | | } |
| | | } |
| | | if(m.v.ps&&m.v.ps.value=='æ£éªå项'){ |
| | | if(num0==1){ |
| | | str = str+m.v.v |
| | | } |
| | | } |
| | | } |
| | | if(data[i][j].equipName&&data[i][j].equipValue&&m.v&&m.v.ps&&m.v.ps.value=='设å¤ç¼ç '&&str0==str){ |
| | | if(!m.v.v){ |
| | | this.changeEquip(data[i][j].equipValue,m,data[i][j].equipName) |
| | | } |
| | | } |
| | | }) |
| | | }) |
| | | }else if(j!='frequency'&&data[i][j]&&Array.isArray(data[i][j].result)){ |
| | | let str0 = i+','+j |
| | | let list = this.tableList[0].arr |
| | |
| | | maxNum = num |
| | | } |
| | | } |
| | | console.log('data[i][j].equipName',data[i][j].equipName,'data[i][j].equipValue',data[i][j].equipValue,'m.v',m.v,'m.v.ps',m.v.ps,'m.v.ps.value',m.v.ps.value,'str0',str0,'str',str,'m.v.v',m.v.v) |
| | | if(data[i][j].equipName&&data[i][j].equipValue&&m.v&&m.v.ps&&m.v.ps.value=='设å¤ç¼ç '&&str0==str){ |
| | | if(!m.v.v){ |
| | | this.changeEquip(data[i][j].equipValue,m,data[i][j].equipName) |
| | |
| | | this.currentSample = this.HaveJson(row) |
| | | let list = await this.getCurrentProduct(row.id,0) |
| | | this.currentSample.insProduct = this.HaveJson(list) |
| | | this.handleCasing() |
| | | this.currentSample.insProduct.forEach(a => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | |
| | | currentTable:this.currentTable |
| | | })); |
| | | }, |
| | | handleCasing(){ |
| | | if(this.tableLists.find(m=>m.templateId==this.currentTable)&&(this.tableLists.find(m=>m.templateId==this.currentTable).templateName!='æåç¼æ£éªåå§è®°å½')){ |
| | | this.currentSample.insProduct = this.currentSample.insProduct.filter(m=>!m.inspectionItem.includes('æ¾å¥ç®¡')) |
| | | } |
| | | }, |
| | | getReportModel(id){ |
| | | if(this.PROJECT!='æ£æµä¸å¿'){ |
| | | return |
| | | } |
| | | this.getReportModelLoading = true |
| | | this.$axios.post(this.$api.insOrderPlan.getReportModel+'?sampleId='+id, {}).then(res => { |
| | | this.getReportModelLoading = false |
| | | this.fibers = res.data['å
纤带'] |
| | | this.fiber = res.data['å
纤'] |
| | | this.casing = res.data['å¥ç®¡'] |
| | | }) |
| | | }, |
| | | async handleChange(m,type){ |
| | |
| | | type: 'saveData', |
| | | tableList:this.tableList, |
| | | param:this.param, |
| | | currentTable:this.currentTable |
| | | currentTable:this.currentTable, |
| | | bushing:m |
| | | })); |
| | | }else{ |
| | | this.tableLists = [] |
| | |
| | | this.handleExcelMethod() |
| | | }, |
| | | changeInput(m, code, n) { |
| | | let str = code.split('-') |
| | | let pId = str[3] |
| | | if(!this.param[pId].equipValue||this.param[pId].equipValue.length==0||!this.param[pId].equipValue[0].v.v){ |
| | | let inspectionItem = '' |
| | | let idS = [] |
| | | let child = 0 |
| | | for (let i in this.currentSample.insProduct) { |
| | | if(this.currentSample.insProduct[i].id==pId){ |
| | | inspectionItem = this.currentSample.insProduct[i].inspectionItem |
| | | } |
| | | } |
| | | for (let i in this.currentSample.insProduct) { |
| | | if(this.currentSample.insProduct[i].inspectionItem==inspectionItem&&this.currentSample.insProduct[i].id!=pId){ |
| | | idS.push(this.currentSample.insProduct[i].id) |
| | | } |
| | | } |
| | | for (let i = 0;i<idS.length;i++) { |
| | | if(this.param[idS[i]].equipValue&&this.param[idS[i]].equipValue.length>0&&this.param[idS[i]].equipValue[0].v.v){ |
| | | child++ |
| | | } |
| | | } |
| | | if(child==0){ |
| | | n.v.v = null |
| | | this.$message.error('请å
å¡«å设å¤ä¿¡æ¯') |
| | | return |
| | | } |
| | | } |
| | | // let str = code.split('-') |
| | | // let pId = str[3] |
| | | // if(!this.param[pId].equipValue||this.param[pId].equipValue.length==0||!this.param[pId].equipValue[0].v.v){ |
| | | // let inspectionItem = '' |
| | | // let idS = [] |
| | | // let child = 0 |
| | | // for (let i in this.currentSample.insProduct) { |
| | | // if(this.currentSample.insProduct[i].id==pId){ |
| | | // inspectionItem = this.currentSample.insProduct[i].inspectionItem |
| | | // } |
| | | // } |
| | | // for (let i in this.currentSample.insProduct) { |
| | | // if(this.currentSample.insProduct[i].inspectionItem==inspectionItem&&this.currentSample.insProduct[i].id!=pId){ |
| | | // idS.push(this.currentSample.insProduct[i].id) |
| | | // } |
| | | // } |
| | | // for (let i = 0;i<idS.length;i++) { |
| | | // if(this.param[idS[i]].equipValue&&this.param[idS[i]].equipValue.length>0&&this.param[idS[i]].equipValue[0].v.v){ |
| | | // child++ |
| | | // } |
| | | // } |
| | | // if(child==0){ |
| | | // n.v.v = null |
| | | // this.$message.error('请å
å¡«å设å¤ä¿¡æ¯') |
| | | // return |
| | | // } |
| | | // } |
| | | if (n) { |
| | | // if (this.PROJECT === 'è£
å¤çµç¼') { |
| | | // let num2 = new this.$Big(n.v.v) |
| | |
| | | } |
| | | } |
| | | } |
| | | // let obj = this.param[code.split('-')[3]] |
| | | // this.tableList[0].arr.forEach(item=>{ |
| | | // item.forEach(m=>{ |
| | | // if(obj&&obj.insResult&&m.c==obj.insResult.c&&m.r==obj.insResult.r){ |
| | | // m.v.v = obj.insResult.v.v |
| | | // } |
| | | // if(obj&&obj.resValue&&m.c==obj.resValue.c&&m.r==obj.resValue.r){ |
| | | // m.v.v = obj.resValue.v.v |
| | | // } |
| | | // }) |
| | | // }) |
| | | // console.log(this.tableList,this.param) |
| | | this.saveInsContext() |
| | | }) |
| | | break; |
| | |
| | | }, |
| | | changeEquip(val, n,v) { |
| | | this.$set(n.v,'v',val) |
| | | console.log(3333,val,n) |
| | | this.$set(n.v,'v',val) |
| | | this.tableList[0].arr.forEach((item,index)=>{ |
| | | item.forEach((m,i)=>{ |
| | | if(this.param[m.i]){ |
| | |
| | | } |
| | | } |
| | | for (let i in this.equipOptions) { |
| | | if (this.equipOptions[i].value === val) { |
| | | if (this.equipOptions[i].value == val) { |
| | | for (let i1 in this.param[n.i].equipName) { |
| | | if (this.param[n.i].equipName[i1].i === n.i && this.param[n.i].equipName[i1].r === n.r) { |
| | | this.$delete(this.param[n.i].equipValue[i1].v,'v') |
| | | this.$set(this.param[n.i].equipValue[i1].v,'v',val) |
| | | this.$delete(this.param[n.i].equipName[i1].v,'v') |
| | | this.$set(this.param[n.i].equipName[i1].v,'v',this.equipOptions[i].label) |
| | | this.tableList[0].arr.forEach((item,index)=>{ |
| | | item.forEach((m)=>{ |
| | | if(m.i==n.i&&m.v.ps&&m.v.ps.value=='设å¤åç§°'){ |
| | | this.$set(m.v,'v',this.equipOptions[i].label) |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | this.currentSample = this.HaveJson(this.sampleProduct[index - 1]) |
| | | let list = await this.getCurrentProduct(this.currentSample.id,0) |
| | | this.currentSample.insProduct = this.HaveJson(list) |
| | | this.handleCasing() |
| | | this.param = {} |
| | | this.currentSample.insProduct.forEach(a => { |
| | | this.param[a.id] = { |
| | |
| | | </el-table-column> |
| | | <el-table-column type="index" align="center" label="åºå·" :width="selectionWidth" v-if="data.isIndex" :key="Math.random()"> |
| | | </el-table-column> |
| | | <el-table-column :prop="a.label" :label="a.value" :sortable="a.sort === 'custom' ? 'custom' : false" :isColumnWidth="isColumnWidth" :width="a.width" :isShowZero="isShowZero" |
| | | <el-table-column :prop="a.label" :label="a.value" :sortable="a.sort === 'custom' ? 'custom' : false" :isColumnWidth="isColumnWidth" :isShowZero="isShowZero" |
| | | v-for="(a, ai) in tableHead" :key="ai" show-overflow-tooltip :min-width="columnMinWidth" v-if="!data.headNoShow||(data.headNoShow&&data.headNoShow.length==0)||(data.headNoShow&&data.headNoShow.length>0&&!data.headNoShow.find(d=>d==a.label))"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="showType(a.label, data.tagField) != null"> |
| | |
| | | if (this.tableData.length === 0 && this.page.current > 1) { |
| | | this.selectList('lastPage') |
| | | } |
| | | if (this.isColumnWidth) { |
| | | this.tableHead.forEach(item => { |
| | | if (item.value.length === 4) { |
| | | item.width = 120 |
| | | } else if (item.value.length === 3){ |
| | | item.width = item.label.includes('Hours') ? 50 : 100 |
| | | } else if (item.value.length === 5){ |
| | | item.width = 130 |
| | | } else if (item.value.length === 7){ |
| | | item.width = 160 |
| | | } else if (item.value.length === 6){ |
| | | item.width = 150 |
| | | } else if (item.value.length === 2){ |
| | | item.width = item.label.includes('Hours') ? 52 : 86 |
| | | } else { |
| | | item.width = item.label.includes('Hours') ? 46 : 86 |
| | | } |
| | | }) |
| | | } |
| | | // if (this.isColumnWidth) { |
| | | // this.tableHead.forEach(item => { |
| | | // if(!item.width){ |
| | | // if (item.value.length === 4) { |
| | | // item.width = 120 |
| | | // } else if (item.value.length === 3){ |
| | | // item.width = item.label.includes('Hours') ? 50 : 100 |
| | | // } else if (item.value.length === 5){ |
| | | // item.width = 130 |
| | | // } else if (item.value.length === 7){ |
| | | // item.width = 160 |
| | | // } else if (item.value.length === 6){ |
| | | // item.width = 150 |
| | | // } else if (item.value.length === 2){ |
| | | // item.width = item.label.includes('Hours') ? 52 : 86 |
| | | // } else { |
| | | // item.width = item.label.includes('Hours') ? 46 : 86 |
| | | // } |
| | | // } |
| | | // }) |
| | | // } |
| | | |
| | | // console.log(JSON.stringify(this.tableHead)+"---------"+JSON.stringify(this.tableData)) |
| | | for (var a in this.data.selectField) { |
| | |
| | | <Add :active="activeFace" :currentId="currentId"/> |
| | | </div> |
| | | <Inspection v-if="state>0" @goback="goback" :orderId="orderId" :sonLaboratory="componentData.entity.sonLaboratory" :state="state"/> |
| | | </div> |
| | | <el-dialog title="æ°æ®æ¥ç" :visible.sync="dataDialogVisible" width="80%"> |
| | | <div style="height: 70vh;overflow-y: auto;" v-if="dataDialogVisible"> |
| | | <ValueTable ref="ValueTableDataLook" :url="$api.insOrder.selectSampleAndProductByOrderId" |
| | | :componentData="componentDataDataLook"/> |
| | | </div> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | getYearAndMonthAndDays |
| | | } from '../../util/date' |
| | | import Add from '../do/b1-ins-order/add.vue' |
| | | import { CellGroup } from 'iview' |
| | | export default { |
| | | components: { |
| | | ValueTable, |
| | |
| | | tabList: [], |
| | | active: 1, |
| | | tabIndex: 0, |
| | | componentDataDataLook: { |
| | | entity: { |
| | | id: 0, |
| | | orderBy: { |
| | | field: 'sampleCode', |
| | | order: 'asc' |
| | | } |
| | | }, |
| | | isIndex: false, |
| | | showSelect: false, |
| | | select: false, |
| | | do: [], |
| | | tagField: { |
| | | insState: { |
| | | select: [] |
| | | }, |
| | | insResult: { |
| | | select: [{ |
| | | value: 1, |
| | | label: 'åæ ¼', |
| | | type: 'success' |
| | | },{ |
| | | value: 0, |
| | | label: 'ä¸åæ ¼', |
| | | type: 'danger' |
| | | }] |
| | | } |
| | | }, |
| | | selectField: {}, |
| | | spanConfig:{ |
| | | rows:[ |
| | | { |
| | | name:'sampleCode', |
| | | index:0 |
| | | }, |
| | | { |
| | | name:'sample', |
| | | index:1 |
| | | }, |
| | | { |
| | | name:'model', |
| | | index:5 |
| | | } |
| | | ] |
| | | }, |
| | | requiredAdd: [], |
| | | requiredUp: [] |
| | | }, |
| | | dataDialogVisible: false, |
| | | componentData: { |
| | | entity: { |
| | | sonLaboratory: null, |
| | |
| | | init: false, |
| | | needSort: ['createTime', 'sendTime', 'type', 'appointed', 'insState'], |
| | | do: [{ |
| | | id: '', |
| | | font: 'æ°æ®æ¥ç', |
| | | type: 'text', |
| | | method: 'handleDataLook', |
| | | disabFun: (row, index) => { |
| | | const user = JSON.parse(localStorage.getItem('user')) |
| | | let currentUserName = '' |
| | | if(user){ |
| | | currentUserName = user.name |
| | | } |
| | | return row.userName!=currentUserName && row.checkName!=currentUserName |
| | | } |
| | | },{ |
| | | id: '', |
| | | font: 'æ£éª', |
| | | type: 'text', |
| | |
| | | this.getPower() |
| | | }, |
| | | methods: { |
| | | // æ°æ®æ¥ç |
| | | handleDataLook(row) { |
| | | this.componentDataDataLook.entity.id = row.id |
| | | this.dataDialogVisible = true; |
| | | }, |
| | | // æéåé
|
| | | getPower(radio) { |
| | | let power = JSON.parse(sessionStorage.getItem('power')) |
| | |
| | | <div class="search_thing" style="width: 20%;"> |
| | | <div class="search_label">æ ·ååç§°ï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="componentData.entity.sample" @keyup.enter.native="refreshTable()"></el-input></div> |
| | | v-model="componentData.entity.sampleName" @keyup.enter.native="refreshTable()"></el-input></div> |
| | | </div> |
| | | <div class="search_thing" style="width: 20%;"> |
| | | <div class="search_label">æ ·ååå·ï¼</div> |
| | |
| | | <el-col style="font-weight: bold;"><span>è§æ ¼åå·: </span>{{ item.model }}</el-col> |
| | | </el-row> |
| | | <el-row style="margin-top: 1px;font-size: 14px;"> |
| | | <el-col style="font-weight: bold;"><span>æ ·ååç§°: </span>{{ item.sampleName }}</el-col> |
| | | <el-col style="font-weight: bold;"><span>æ ·ååç§°: </span>{{ item.sample }}</el-col> |
| | | </el-row> |
| | | <el-row style="margin-top: 1px;font-size: 14px;" class="ellipsis-multiline"> |
| | | <el-col style="font-weight: bold;"><span>æ£æµé¡¹ç®: </span>{{ item.item }}</el-col> |
| | |
| | | </span> |
| | | </el-dialog> |
| | | <div class="el-dialog__body" style="overflow-y: auto;margin-top: 0;position: fixed;top: 999px;z-index: 99999;display: none;"> |
| | | <div id="printMOrder" class="printMOrder"> |
| | | <el-card class="box-card" v-for="(item, i) in checkDataList" :key="i" style="font-size: 0.16cm !important;page-break-after: always;color: #000;box-shadow: none;margin: 0 !important;padding: 0 !important;"> |
| | | <div id="printMOrder" class="printMOrder" ref="printMOrder"> |
| | | <el-card class="box-card" v-for="(item, i) in checkDataList" :key="i" style="font-size: 0.20cm !important;page-break-after: always;color: #000;box-shadow: none;margin: 0 !important;padding: 0 !important;"> |
| | | <div style="display: flex;"> |
| | | <div> |
| | | <el-col :span="10" :offset="2"> |
| | | <vueQr :text="JSON.stringify(item.sampleCode)" :size="60" :margin="2"></vueQr> |
| | | </el-col> |
| | | </div> |
| | | <div style="margin-left: 0.32cm;line-height: 0.21cm;"> |
| | | <div style="margin-left: 0.32cm;line-height: 0.22cm;"> |
| | | <el-row> |
| | | <el-col style="font-size: 0.16cm;"><span>æ ·åç¼å·: </span>{{ item.sampleCode }}</el-col> |
| | | <el-col style="font-size: 0.20cm;width: 4cm;" class="single-line-ellipsis"><span>æ ·åç¼å·: </span>{{ item.sampleCode }}</el-col> |
| | | </el-row> |
| | | <el-row style="font-size: 0.16cm;"> |
| | | <el-row style="font-size: 0.20cm;"> |
| | | <el-col><span>å§æåå·: </span>{{ item.code }}</el-col> |
| | | </el-row> |
| | | <el-row style="font-size: 0.16cm;"> |
| | | <el-row style="font-size: 0.20cm;"> |
| | | <el-col><span>è§æ ¼åå·: </span>{{ item.model }}</el-col> |
| | | </el-row> |
| | | <el-row style="font-size: 0.16cm;"> |
| | | <el-col ><span>æ ·ååç§°: </span>{{ item.sampleName }}</el-col> |
| | | <el-row style="font-size: 0.20cm;"> |
| | | <el-col ><span>æ ·ååç§°: </span>{{ item.sample }}</el-col> |
| | | </el-row> |
| | | <el-row style="font-size: 0.16cm;width: 5.6cm;"> |
| | | <el-row style="font-size: 0.20cm;width: 4cm;"> |
| | | <el-col class="ellipsis-multiline"><span>æ£æµé¡¹ç®: </span>{{ item.item }}</el-col> |
| | | </el-row> |
| | | <el-row style="margin-top: 0.01cm;font-size: 0.16cm;"> |
| | | <el-row style="margin-top: 0.01cm;font-size: 0.20cm;"> |
| | | <el-col style="display: flex;align-items: center;"><span>æ ·åç¶æ: |
| | | </span> |
| | | <span style="white-space: nowrap;"><span v-if="item.insState==0">â</span><span class="scor" v-if="item.insState!=0"></span>å¾
æ£ |
| | |
| | | targetStyles:['*'], |
| | | style: `@page { |
| | | margin:0; |
| | | size: 360px 175px collapse; |
| | | size: 400px 75px collapse; |
| | | margin-top:3px; |
| | | &:first-of-type{ |
| | | margin-top:0 !important; |
| | |
| | | zoom:100%; |
| | | } |
| | | @media print{ |
| | | width: 360px; |
| | | height: 175px; |
| | | width: 400px; |
| | | height: 75px; |
| | | margin:0; |
| | | }`, |
| | | onPrintDialogClose: this.erexcel=false, |
| | | targetStyles: ["*"], // 使ç¨domçæææ ·å¼ï¼å¾éè¦ |
| | | font_size: '0.16cm', |
| | | font_size: '0.20cm', |
| | | }); |
| | | }, |
| | | print(){ |
| | |
| | | </span> |
| | | </el-dialog> |
| | | <notice ref="notice" @goNoticeDetail="checkForUnreadData()" /> |
| | | <timer></timer> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | import menus from '../../static/js/menu.js' |
| | | import nullFace from '../view/404.vue' |
| | | import notice from './notice.vue' |
| | | import timer from './timer.vue'; |
| | | comObj['nullFace'] = nullFace |
| | | export default { |
| | | components: {...comObj,notice}, |
| | | components: {...comObj,notice,timer}, |
| | | data() { |
| | | return { |
| | | userName: "value", |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div> |
| | | <el-dialog |
| | | title="æç¤º" |
| | | :visible.sync="dialogVisible" |
| | | :close-on-click-modal="false" |
| | | :close-on-press-escape="false" |
| | | :show-close="false" |
| | | width="30%"> |
| | | <div style="display: flex;align-items: center;"><i class="el-icon-warning" style="color: red;font-size: 40px;margin-right: 20px;"></i><span>ä»£ç æ£å¨é¨ç½²ï¼è¯·30åéåéæ°è¿å
¥ç³»ç»ï¼</span></div> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data(){ |
| | | return{ |
| | | timer:null, |
| | | closeTimeout:null, |
| | | dialogVisible:false, |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.startScheduler(); |
| | | }, |
| | | methods: { |
| | | startScheduler() { |
| | | this.checkTime(); |
| | | // æ¯å鿣æ¥ä¸æ¬¡ |
| | | this.timer = setInterval(this.checkTime, 60 * 1000); |
| | | }, |
| | | checkTime() { |
| | | const now = new Date(); |
| | | const hours = now.getHours(); |
| | | const minutes = now.getMinutes(); |
| | | |
| | | if (hours === 20 && minutes === 0) { |
| | | this.performTask(); |
| | | // 设置20åéåæç¤ºå
³é |
| | | this.closeTimeout = setTimeout(() => { |
| | | this.promptToClose(); |
| | | }, 20 * 60 * 1000); // 20åé |
| | | } |
| | | }, |
| | | performTask() { |
| | | // å¨è¿éæ§è¡ä½ æ³è¦ç宿¶ä»»å¡ |
| | | console.log("任塿§è¡äºï¼"); |
| | | this.dialogVisible = true; |
| | | // è¿éå¯ä»¥è§¦åä¸ä¸ª Vuex å¨ä½ãåèµ·ä¸ä¸ª HTTP 请æ±ï¼æè
å
¶ä»æä½ |
| | | }, |
| | | promptToClose() { |
| | | // æç¤ºç¨æ·å
³é |
| | | // alert("请记å¾å¨20åéåå
³éä»»å¡ï¼"); |
| | | this.dialogVisible = true; |
| | | } |
| | | }, |
| | | beforeDestroy() { |
| | | // ç»ä»¶éæ¯æ¶æ¸
é¤å®æ¶å¨ |
| | | if (this.timer) { |
| | | clearInterval(this.timer); |
| | | } |
| | | if (this.closeTimeout) { |
| | | clearTimeout(this.closeTimeout); |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | </style> |
| | |
| | | let comparisonList = [] |
| | | let currentSample = {} |
| | | let PROJECT = '' |
| | | let bushing = '' |
| | | let result = { |
| | | method:'', |
| | | value:null |
| | |
| | | if(data.type&&data.type=='saveData'){ |
| | | tableList = data.tableList; |
| | | param = data.param; |
| | | return |
| | | } |
| | | if(data.bushing&&(data.bushing!=bushing)&&data.type=='saveData'){ |
| | | tableList = data.tableList; |
| | | param = data.param; |
| | | bushing = data.bushing; |
| | | return |
| | | } |
| | | code = data.code; |
| | |
| | | let ask = currentSample.insProduct.find(m => m.id == item.i).ask?currentSample.insProduct.find(m => m.id == item.i).ask.split('&'):null; |
| | | let res = Object.values(comValue)[0] |
| | | let comp = [] |
| | | |
| | | if(res==''||res==null||res==undefined||res=='Infinity'){ |
| | | if(res===''||res===null||res===undefined||res==='Infinity'){ |
| | | item.v.v = null |
| | | list.forEach(a => { |
| | | if (a[0].r == item.r) { |
| | |
| | | } |
| | | }else{ |
| | | let str = handleFraction(m.split('â¤')[1]) |
| | | console.log(555555,res,str) |
| | | return eval(res) <= eval(str) |
| | | } |
| | | }else if (m.includes('<')) { |
| | |
| | | } |
| | | }) |
| | | } |
| | | // console.log(tableList) |
| | | // console.log(5555,tableList) |
| | | } |
| | | // console.log('1234567789', tableList,getParam()) |
| | | result = { |
| | |
| | | b.i &&b.v.v&& param[b.i].comValue.push(b) |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === '设å¤ç¼ç ') { |
| | | b.i &&b.v.v&& param[b.i].equipValue.push(b) |
| | | b.i &&b.v&& param[b.i].equipValue.push(b) |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === '设å¤åç§°') { |
| | | b.i &&b.v.v&& param[b.i].equipName.push(b) |
| | | b.i &&b.v&& param[b.i].equipName.push(b) |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === 'æç»å¼') { |
| | | b.i &&b.v.v&& (param[b.i].resValue = b) |
| | | b.i &&b.v&& (param[b.i].resValue = b) |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === 'ç»è®º') { |
| | | b.i &&(b.v.v||b.v.v===0||b.v.v==='0')&& (param[b.i].insResult = b) |
| | | if(b.i &&(b.v.v||b.v.v===0||b.v.v==='0')){ |
| | | if(b.v.v != 'åæ ¼'&&b.v.v != 'ä¸åæ ¼'){ |
| | | param[b.i].insResult = b |
| | | } |
| | | } |
| | | } |
| | | }) |
| | | }) |
| | |
| | | function SUM(...val){ |
| | | try { |
| | | let num = null; |
| | | if(val&&val.length>0){ |
| | | if(val!=null&&val!=undefined&&val!='undefined'&&val.length>0){ |
| | | val.forEach(item=>{ |
| | | num+=item; |
| | | }) |
| | |
| | | function MAX(...val){ |
| | | try { |
| | | let max = null; |
| | | if(val&&val.length>0){ |
| | | if(val!=null&&val!=undefined&&val!='undefined'&&val.length>0){ |
| | | val = val.filter(item=>item!=null&&item!=='') |
| | | if(val.length>0){ |
| | | max = Math.max(...val) |
| | |
| | | function MIN(...val){ |
| | | try { |
| | | let min = null; |
| | | if(val&&val.length>0){ |
| | | if(val!=null&&val!=undefined&&val!='undefined'&&val.length>0){ |
| | | val = val.filter(item=>item!=null&&item!=='') |
| | | if(val.length>0){ |
| | | min = Math.min(...val) |
| | |
| | | try { |
| | | let num = null; |
| | | let arr = []; |
| | | if(val&&val.length>0){ |
| | | arr = val.filter(item=>item!=null&&item!=''&&item!=undefined) |
| | | if(val!=null&&val!=undefined&&val!='undefined'&&val.length>0){ |
| | | arr = val.filter(item=>item!==null&&item!==''&&item!=undefined) |
| | | arr.forEach(item=>{ |
| | | num+=item; |
| | | }) |
| | |
| | | const data = JSON.parse(event.data); |
| | | dataAcquisitionInfo = data.dataAcquisitionInfo; |
| | | list = data.list; |
| | | // console.log(111,dataAcquisitionInfo) |
| | | handleData() |
| | | } |
| | | |
| | |
| | | setTimeout(()=>{ |
| | | let num0 = 0 |
| | | if(n.v.ct&&n.v.ct.fa&&typeof n.v.ct.fa == 'string'&&n.v.ct.fa.includes('.')){ |
| | | let str = n.v.ct.fa.split('.')[1] |
| | | num0 = str.length |
| | | n.v.v = dataAcquisitionInfo[str].value[i]?dataAcquisitionInfo[str].value[i].toFixed(num0):dataAcquisitionInfo[str].value[i] |
| | | let str0 = n.v.ct.fa.split('.')[1] |
| | | num0 = str0.length |
| | | n.v.v = dataAcquisitionInfo[str].value[i]?Number(dataAcquisitionInfo[str].value[i]).toFixed(num0):dataAcquisitionInfo[str].value[i] |
| | | }else{ |
| | | n.v.v = dataAcquisitionInfo[str].value[i] |
| | | } |
| | |
| | | setTimeout(()=>{ |
| | | let num0 = 0 |
| | | if(n.v.ct&&n.v.ct.fa&&typeof n.v.ct.fa == 'string'&&n.v.ct.fa.includes('.')){ |
| | | let str = n.v.ct.fa.split('.')[1] |
| | | num0 = str.length |
| | | n.v.v = dataAcquisitionInfo[str].value?dataAcquisitionInfo[str].value.toFixed(num0):dataAcquisitionInfo[str].value |
| | | let str0 = n.v.ct.fa.split('.')[1] |
| | | num0 = str0.length |
| | | n.v.v = dataAcquisitionInfo[str].value?Number(dataAcquisitionInfo[str].value).toFixed(num0):dataAcquisitionInfo[str].value |
| | | }else{ |
| | | n.v.v = dataAcquisitionInfo[str].value |
| | | } |
| | |
| | | setTimeout(()=>{ |
| | | let num0 = 0 |
| | | if(n.v.ct&&n.v.ct.fa&&typeof n.v.ct.fa == 'string'&&n.v.ct.fa.includes('.')){ |
| | | let str = n.v.ct.fa.split('.')[1] |
| | | num0 = str.length |
| | | let str0 = n.v.ct.fa.split('.')[1] |
| | | num0 = str0.length |
| | | n.v.v = dataAcquisitionInfo[str].value?Number(dataAcquisitionInfo[str].value).toFixed(num0):dataAcquisitionInfo[str].value |
| | | }else{ |
| | | n.v.v = dataAcquisitionInfo[str].value |