|
@ -121,6 +121,28 @@ public class OrderVerificationResultActivity extends AppCompatActivity { |
|
|
message = intent.getStringExtra("message"); |
|
|
message = intent.getStringExtra("message"); |
|
|
project = intent.getStringExtra("project"); |
|
|
project = intent.getStringExtra("project"); |
|
|
|
|
|
|
|
|
|
|
|
// 核销成功时执行开门操作 |
|
|
|
|
|
if (status != null && status.contains("成功")) { |
|
|
|
|
|
// 获取GateABController实例并执行开门操作 |
|
|
|
|
|
com.ouxuan.oxface.device.GateABController gateABController = com.ouxuan.oxface.device.GateABController.getInstance(); |
|
|
|
|
|
if (gateABController != null) { |
|
|
|
|
|
gateABController.openGateAB(new com.ouxuan.oxface.device.GateABController.GateControlCallback() { |
|
|
|
|
|
@Override |
|
|
|
|
|
public void onSuccess(String message) { |
|
|
|
|
|
LogManager.logInfo(TAG, "核销成功后开门操作成功: " + message); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
public void onError(String errorMessage) { |
|
|
|
|
|
LogManager.logError(TAG, "核销成功后开门操作失败: " + errorMessage); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} else { |
|
|
|
|
|
LogManager.logError(TAG, "GateABController实例为空,无法执行开门操作"); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 获取完整的核销结果数据 |
|
|
// 获取完整的核销结果数据 |
|
|
String verifyResultJson = intent.getStringExtra("verify_result"); |
|
|
String verifyResultJson = intent.getStringExtra("verify_result"); |
|
|
if (verifyResultJson != null && !verifyResultJson.isEmpty()) { |
|
|
if (verifyResultJson != null && !verifyResultJson.isEmpty()) { |
|
@ -565,12 +587,6 @@ public class OrderVerificationResultActivity extends AppCompatActivity { |
|
|
|
|
|
|
|
|
Toast.makeText(this, confirmMessage, Toast.LENGTH_SHORT).show(); |
|
|
Toast.makeText(this, confirmMessage, Toast.LENGTH_SHORT).show(); |
|
|
|
|
|
|
|
|
// 保留语音播放和继电器开门功能的注释,但暂时不实现 |
|
|
|
|
|
// TODO: 根据需要实现语音播放功能 |
|
|
|
|
|
// if (status != null && status.contains("成功")) { |
|
|
|
|
|
// playSuccessVoice(); // 播放成功语音 |
|
|
|
|
|
// triggerRelayDoor(); // 触发继电器开门 |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
finish(); |
|
|
finish(); |
|
|
} |
|
|
} |
|
|