| | |
| | | if (!isTrue) { |
| | | n.v.v = n.v.v.replace('/', '') |
| | | } |
| | | let num = 0 |
| | | } |
| | | try { |
| | | // 向 Worker 发送消息,开始处理逻辑 |
| | |
| | | try{ |
| | | if(comResult==0){ |
| | | a[b].v.v = 0 |
| | | }else if(a[b].v.ct&&a[b].v.ct.fa&&typeof a[b].v.ct.fa == 'string'&&a[b].v.ct.fa.includes('.')){ |
| | | let num = 0 |
| | | let str = n.v.ct.fa.split('.')[1] |
| | | num = str.length |
| | | a[b].v.v = comResult?Number(comResult).toFixed(num):0 |
| | | }else{ |
| | | let val = parseFloat(Number(comResult).toFixed(3)) |
| | | a[b].v.v = isNaN(val) ? '' : val |
| | |
| | | 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] |
| | | num = str.length |
| | | } |
| | | n.v.v = dataAcquisitionInfo[str]?dataAcquisitionInfo[str].toFixed(num):0 |
| | | }else{ |
| | | n.v.v = dataAcquisitionInfo[str] |
| | | } |
| | | result = { |
| | | method:'changeInput', |
| | | value:{ |
| | |
| | | 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] |
| | | num = str.length |
| | | } |
| | | n.v.v = dataAcquisitionInfo[str]?Number(dataAcquisitionInfo[str]).toFixed(num):0 |
| | | }else{ |
| | | n.v.v = dataAcquisitionInfo[str] |
| | | } |
| | | result = { |
| | | method:'changeInput', |
| | | value:{ |
| | |
| | | } |
| | | self.postMessage(JSON.stringify(result)) |
| | | },2000) |
| | | // n.v.v = dataAcquisitionInfo[str] |
| | | // result = { |
| | | // method:'changeInput', |
| | | // value:{ |
| | | // list:list, |
| | | // n:n |
| | | // } |
| | | // } |
| | | // self.postMessage(JSON.stringify(result)) |
| | | // setTimeout(()=>{ |
| | | // this.$delete(n.v,'v') |
| | | // this.$set(n.v,'v',this.dataAcquisitionInfo[str]) |
| | | // this.changeInput('',`${this.currentSample.insProduct[0].templateId}-${n.r}-${n.c}-${n.i}`,n) |
| | | // },1000) |
| | | } |
| | | } |
| | | } |