fix:修复发送注册卡片后不刷卡没有超时的回调
This commit is contained in:
parent
6613ad29d1
commit
5eaadc0e9a
35
common.js
35
common.js
@ -1011,6 +1011,7 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
case subCmdIds.registerCardConfirm:
|
case subCmdIds.registerCardConfirm:
|
||||||
// 收到锁版回复判断操作类型进行对应api操作
|
// 收到锁版回复判断操作类型进行对应api操作
|
||||||
if (decrypted[2] === Result.Success.code) {
|
if (decrypted[2] === Result.Success.code) {
|
||||||
|
if (decrypted[5] === Result.Success.code) {
|
||||||
switch (this.requestParams.operate) {
|
switch (this.requestParams.operate) {
|
||||||
case 0:
|
case 0:
|
||||||
// 注册
|
// 注册
|
||||||
@ -1032,6 +1033,10 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
await this.disconnectDevice()
|
await this.disconnectDevice()
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[5]))
|
||||||
|
this.characteristicValueCallback(new Result(decrypted[5]))
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
||||||
this.characteristicValueCallback(new Result(decrypted[2]))
|
this.characteristicValueCallback(new Result(decrypted[2]))
|
||||||
@ -1092,7 +1097,10 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
break;
|
break;
|
||||||
case subCmdIds.registerFingerprintConfirm:
|
case subCmdIds.registerFingerprintConfirm:
|
||||||
if (decrypted[2] === Result.Success.code) {
|
if (decrypted[2] === Result.Success.code) {
|
||||||
|
if (decrypted[5] === Result.Success.code) {
|
||||||
if (this.requestParams.operate === 0) {
|
if (this.requestParams.operate === 0) {
|
||||||
|
switch (this.requestParams.operate) {
|
||||||
|
case 0:
|
||||||
const addResult = await addFingerprintRequest({
|
const addResult = await addFingerprintRequest({
|
||||||
...this.requestParams,
|
...this.requestParams,
|
||||||
isCoerced: this.requestParams.isForce,
|
isCoerced: this.requestParams.isForce,
|
||||||
@ -1109,7 +1117,14 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
emitRegisterFingerprintConfirmEvent(addResult)
|
emitRegisterFingerprintConfirmEvent(addResult)
|
||||||
// 断开蓝牙连接
|
// 断开蓝牙连接
|
||||||
await this.disconnectDevice()
|
await this.disconnectDevice()
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[5]))
|
||||||
|
this.characteristicValueCallback(new Result(decrypted[5]))
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
||||||
this.characteristicValueCallback(new Result(decrypted[2]))
|
this.characteristicValueCallback(new Result(decrypted[2]))
|
||||||
@ -1168,6 +1183,9 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
break;
|
break;
|
||||||
case subCmdIds.registerFaceConfirm:
|
case subCmdIds.registerFaceConfirm:
|
||||||
if (this.requestParams.operate === 0) {
|
if (this.requestParams.operate === 0) {
|
||||||
|
if (decrypted[5] === Result.Success.code) {
|
||||||
|
switch (this.requestParams.operate) {
|
||||||
|
case 0:
|
||||||
const addResult = await addFaceRequest({
|
const addResult = await addFaceRequest({
|
||||||
...this.requestParams,
|
...this.requestParams,
|
||||||
isCoerced: this.requestParams.isForce,
|
isCoerced: this.requestParams.isForce,
|
||||||
@ -1184,6 +1202,12 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
emitRegisterFaceConfirmEvent(addResult)
|
emitRegisterFaceConfirmEvent(addResult)
|
||||||
// 断开蓝牙连接
|
// 断开蓝牙连接
|
||||||
await this.disconnectDevice()
|
await this.disconnectDevice()
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[5]))
|
||||||
|
this.characteristicValueCallback(new Result(decrypted[5]))
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
||||||
this.characteristicValueCallback(new Result(decrypted[2]))
|
this.characteristicValueCallback(new Result(decrypted[2]))
|
||||||
@ -1235,6 +1259,7 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
case subCmdIds.registerPalmVeinConfirm:
|
case subCmdIds.registerPalmVeinConfirm:
|
||||||
// 收到锁版回复判断操作类型进行对应api操作
|
// 收到锁版回复判断操作类型进行对应api操作
|
||||||
if (decrypted[2] === Result.Success.code) {
|
if (decrypted[2] === Result.Success.code) {
|
||||||
|
if (decrypted[5] === Result.Success.code) {
|
||||||
switch (this.requestParams.operate) {
|
switch (this.requestParams.operate) {
|
||||||
case 0:
|
case 0:
|
||||||
// 注册
|
// 注册
|
||||||
@ -1256,6 +1281,10 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
await this.disconnectDevice()
|
await this.disconnectDevice()
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[5]))
|
||||||
|
this.characteristicValueCallback(new Result(decrypted[5]))
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
||||||
this.characteristicValueCallback(new Result(decrypted[2]))
|
this.characteristicValueCallback(new Result(decrypted[2]))
|
||||||
@ -1305,6 +1334,7 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
case subCmdIds.registerRemoteConfirm:
|
case subCmdIds.registerRemoteConfirm:
|
||||||
// 收到锁版回复判断操作类型进行对应api操作
|
// 收到锁版回复判断操作类型进行对应api操作
|
||||||
if (decrypted[2] === Result.Success.code) {
|
if (decrypted[2] === Result.Success.code) {
|
||||||
|
if (decrypted[5] === Result.Success.code) {
|
||||||
switch (this.requestParams.operate) {
|
switch (this.requestParams.operate) {
|
||||||
case 0:
|
case 0:
|
||||||
// 注册
|
// 注册
|
||||||
@ -1326,6 +1356,11 @@ export async function parsingCharacteristicValue(binaryData) {
|
|||||||
await this.disconnectDevice()
|
await this.disconnectDevice()
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[5]))
|
||||||
|
this.characteristicValueCallback(new Result(decrypted[5]))
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
emitRegisterCardConfirmEvent(new Result(Result.Fail.code, null, decrypted[2]))
|
||||||
this.characteristicValueCallback(new Result(decrypted[2]))
|
this.characteristicValueCallback(new Result(decrypted[2]))
|
||||||
|
|||||||
4
env.js
4
env.js
@ -1,7 +1,7 @@
|
|||||||
// uni版本号
|
// uni版本号
|
||||||
export const uniVersion = '1.0.17'
|
export const uniVersion = '1.0.18'
|
||||||
// uni构建号
|
// uni构建号
|
||||||
export const uniBuildNumber = 18
|
export const uniBuildNumber = 19
|
||||||
|
|
||||||
// web版本号
|
// web版本号
|
||||||
export const webVersion = '1.0.1'
|
export const webVersion = '1.0.1'
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "star-cloud-uni",
|
"name": "star-cloud-uni",
|
||||||
"version": "1.0.15",
|
"version": "1.0.18",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./uni/index.js",
|
"main": "./uni/index.js",
|
||||||
"author": "zzc059",
|
"author": "zzc059",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user