fix:如果是单次钥匙开锁成功之后就调用删除
This commit is contained in:
parent
b61aceeac9
commit
0520733080
@ -126,6 +126,17 @@ class LockDetailLogic extends BaseGetXController {
|
|||||||
TalkStatus.answeredSuccessfully) {
|
TalkStatus.answeredSuccessfully) {
|
||||||
showToast('开锁成功'.tr);
|
showToast('开锁成功'.tr);
|
||||||
}
|
}
|
||||||
|
// 如果是单次钥匙,则开锁成功之后调用删除
|
||||||
|
if (state.keyInfos.value.keyType == 3) {
|
||||||
|
final LockListInfoEntity entity = await ApiRepository.to
|
||||||
|
.deletOwnerKeyData(
|
||||||
|
lockId: state.keyInfos.value.lockId.toString(),
|
||||||
|
keyId: state.keyInfos.value!.keyId.toString(),
|
||||||
|
includeUnderlings: 0);
|
||||||
|
if (entity.errorCode!.codeIsSuccessful) {
|
||||||
|
AppLog.log("删除成功");
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 0x06:
|
case 0x06:
|
||||||
//无权限
|
//无权限
|
||||||
@ -532,8 +543,7 @@ class LockDetailLogic extends BaseGetXController {
|
|||||||
final List<int> getPublicKeyList =
|
final List<int> getPublicKeyList =
|
||||||
changeStringListToIntList(publicKey!);
|
changeStringListToIntList(publicKey!);
|
||||||
|
|
||||||
AppLog.log(
|
AppLog.log('发送同步锁记录命令:${BlueManage().connectDeviceName}');
|
||||||
'发送同步锁记录命令:${BlueManage().connectDeviceName}');
|
|
||||||
IoSenderManage.senderReferEventRecordTimeCommand(
|
IoSenderManage.senderReferEventRecordTimeCommand(
|
||||||
keyID: BlueManage().connectDeviceName,
|
keyID: BlueManage().connectDeviceName,
|
||||||
userID: await Storage.getUid(),
|
userID: await Storage.getUid(),
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user