|
@ -60,7 +60,7 @@ |
|
|
<span class="step-left-num" :class="{ 'step-active': 5 === step }">5</span> |
|
|
<span class="step-left-num" :class="{ 'step-active': 5 === step }">5</span> |
|
|
<div class="step-right-cont"> |
|
|
<div class="step-right-cont"> |
|
|
<p class="step-title">第五步<span>绑定成功</span></p> |
|
|
<p class="step-title">第五步<span>绑定成功</span></p> |
|
|
<p class="step-tip" :class="{ 'tip-active': 5 === step }">{{ step5Message }}</p> |
|
|
|
|
|
|
|
|
<p class="step-tip" :class="{ 'tip-error': 5 === errorStep,'tip-active': 5 === step }">{{ step5Message }}</p> |
|
|
<!-- tip: 当前标签与档案绑定成功 --> |
|
|
<!-- tip: 当前标签与档案绑定成功 --> |
|
|
<!-- tip: 绑定成功 --> |
|
|
<!-- tip: 绑定成功 --> |
|
|
</div> |
|
|
</div> |
|
@ -193,6 +193,7 @@ export default { |
|
|
} else if (res.code && res.code === '-2') { |
|
|
} else if (res.code && res.code === '-2') { |
|
|
this.errorStep = 2 |
|
|
this.errorStep = 2 |
|
|
this.step2Message = '未读取到标签,请重新放入' |
|
|
this.step2Message = '未读取到标签,请重新放入' |
|
|
|
|
|
this.step = 2 |
|
|
clearTimeout(this.timer) |
|
|
clearTimeout(this.timer) |
|
|
this.timer = setTimeout(() => { |
|
|
this.timer = setTimeout(() => { |
|
|
resolve(this.readEpc(param)) |
|
|
resolve(this.readEpc(param)) |
|
@ -277,8 +278,7 @@ export default { |
|
|
if (res === '当前标签已被绑定') { |
|
|
if (res === '当前标签已被绑定') { |
|
|
this.coverBindingVisible = true |
|
|
this.coverBindingVisible = true |
|
|
resolve() |
|
|
resolve() |
|
|
// else if() {} else {reject()} |
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
|
} else if (res === 1) { |
|
|
let writeRes = await RFID.writeEPC({ op: 'RFID_WriteEPC', sDevID: 'D001', EAS: '1', Type: this.bindingType, Code: this.bindingId, Tid: this.readData.tid }) |
|
|
let writeRes = await RFID.writeEPC({ op: 'RFID_WriteEPC', sDevID: 'D001', EAS: '1', Type: this.bindingType, Code: this.bindingId, Tid: this.readData.tid }) |
|
|
writeRes = JSON.parse(writeRes) |
|
|
writeRes = JSON.parse(writeRes) |
|
|
if (writeRes.code === '0') { |
|
|
if (writeRes.code === '0') { |
|
@ -299,6 +299,10 @@ export default { |
|
|
}) |
|
|
}) |
|
|
reject() |
|
|
reject() |
|
|
} |
|
|
} |
|
|
|
|
|
} else { |
|
|
|
|
|
this.step5Message = '绑定失败' |
|
|
|
|
|
this.errorStep = 5 |
|
|
|
|
|
reject() |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|