|
@ -245,8 +245,8 @@ export const lendingCrud = { |
|
|
}, |
|
|
}, |
|
|
async getDevId() { |
|
|
async getDevId() { |
|
|
return await new Promise(async(resolve, reject) => { |
|
|
return await new Promise(async(resolve, reject) => { |
|
|
// const mac = await RFID.getDeviceMac()
|
|
|
|
|
|
const mac = '12-34-56-12-34-56' |
|
|
|
|
|
|
|
|
const mac = await RFID.getDeviceMac() |
|
|
|
|
|
// const mac = '12-34-56-12-34-56'
|
|
|
if (!mac || mac === '') { |
|
|
if (!mac || mac === '') { |
|
|
this.$message.error('获取mac地址失败') |
|
|
this.$message.error('获取mac地址失败') |
|
|
} else { |
|
|
} else { |
|
@ -311,15 +311,19 @@ export const lendingCrud = { |
|
|
} else if (this.tipTable.filter((item) => { return item.warnState === '解除失败' || item.warnState === '恢复失败' }).length > 0) { |
|
|
} else if (this.tipTable.filter((item) => { return item.warnState === '解除失败' || item.warnState === '恢复失败' }).length > 0) { |
|
|
this.btnDisabled = true |
|
|
this.btnDisabled = true |
|
|
this.unbindWarnLoading = false |
|
|
this.unbindWarnLoading = false |
|
|
if (this.ase === 0) { |
|
|
|
|
|
this.$message.error('借阅成功n条数据' + ' ' + '借阅失败' + this.lendSelections.length + '条数据') |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$message.error('归还成功n条数据' + ' ' + '归还失败' + this.lendSelections.length + '条数据') |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
this.alarmErrorTip() |
|
|
} else { |
|
|
} else { |
|
|
this.btnDisabled = false |
|
|
this.btnDisabled = false |
|
|
this.unbindWarnLoading = false |
|
|
this.unbindWarnLoading = false |
|
|
this.$message.success('解绑/恢复成功n条数据') |
|
|
|
|
|
|
|
|
let params |
|
|
|
|
|
if (this.ase === 0) { |
|
|
|
|
|
params = this.lendSelections.map(item => item.orderNo) |
|
|
|
|
|
} else { |
|
|
|
|
|
params = this.lendSelections.map(item => item.id) |
|
|
|
|
|
} |
|
|
|
|
|
console.log(params) |
|
|
|
|
|
// 全部成功之后确认借出 / 归还
|
|
|
|
|
|
this.confirmLendOrReturn(this.ase, params, this.lendSelections) |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
async checkStatus(param) { |
|
|
async checkStatus(param) { |
|
|