|
@@ -145,28 +145,44 @@ export default {
|
|
*/
|
|
*/
|
|
this.faceTestEnd = receivedMsg => {
|
|
this.faceTestEnd = receivedMsg => {
|
|
if (receivedMsg.verifyCount == 1) {
|
|
if (receivedMsg.verifyCount == 1) {
|
|
- if (
|
|
|
|
- receivedMsg.verifyResult == "VERIFY_FAILED" ||
|
|
|
|
- receivedMsg.verifyResult == "TIME_OUT"
|
|
|
|
- ) {
|
|
|
|
- this.$Message.info("第一次人脸检测失败,系统退出,请重新登录", {
|
|
|
|
- time: 5000
|
|
|
|
|
|
+ if (receivedMsg.verifyResult == "TIME_OUT") {
|
|
|
|
+ this.$Message.error({
|
|
|
|
+ content: "第一次人脸检测超时,检测失败,系统退出,请重新登录",
|
|
|
|
+ duration: 15000
|
|
|
|
+ });
|
|
|
|
+ this.logout();
|
|
|
|
+ } else if (receivedMsg.verifyResult == "VERIFY_FAILED") {
|
|
|
|
+ this.$Message.error({
|
|
|
|
+ content: "第一次人脸检测失败,系统退出,请重新登录",
|
|
|
|
+ duration: 15000
|
|
});
|
|
});
|
|
this.logout();
|
|
this.logout();
|
|
} else if (receivedMsg.verifyResult == "NOT_ONESELF") {
|
|
} else if (receivedMsg.verifyResult == "NOT_ONESELF") {
|
|
- this.$Message.info("人脸检测不合格,结束考试", { time: 5000 });
|
|
|
|
|
|
+ this.$Message.error({
|
|
|
|
+ content: "人脸检测不合格,结束考试",
|
|
|
|
+ duration: 15000
|
|
|
|
+ });
|
|
this.faceTestEndHandle("FAILED");
|
|
this.faceTestEndHandle("FAILED");
|
|
} else if (receivedMsg.verifyResult == "VERIFY_SUCCESS") {
|
|
} else if (receivedMsg.verifyResult == "VERIFY_SUCCESS") {
|
|
- this.$Message.info("人脸检测成功,请继续完成考试", { time: 5000 });
|
|
|
|
|
|
+ this.$Message.info({
|
|
|
|
+ content: "人脸检测成功,请继续完成考试",
|
|
|
|
+ duration: 15000
|
|
|
|
+ });
|
|
this.faceTestEndHandle("SUCCESS");
|
|
this.faceTestEndHandle("SUCCESS");
|
|
}
|
|
}
|
|
} else if (receivedMsg.verifyCount >= 2) {
|
|
} else if (receivedMsg.verifyCount >= 2) {
|
|
if (receivedMsg.verifyResult == "VERIFY_SUCCESS") {
|
|
if (receivedMsg.verifyResult == "VERIFY_SUCCESS") {
|
|
// FIXME: 什么逻辑?
|
|
// FIXME: 什么逻辑?
|
|
- this.$Message.info("人脸检测成功,请继续完成考试", { time: 5000 });
|
|
|
|
|
|
+ this.$Message.info({
|
|
|
|
+ content: "人脸检测成功,请继续完成考试",
|
|
|
|
+ duration: 15000
|
|
|
|
+ });
|
|
this.faceTestEndHandle("SUCCESS");
|
|
this.faceTestEndHandle("SUCCESS");
|
|
} else {
|
|
} else {
|
|
- this.$Message.info("人脸检测不合格,结束考试", { time: 5000 });
|
|
|
|
|
|
+ this.$Message.info({
|
|
|
|
+ content: "人脸检测不合格,结束考试",
|
|
|
|
+ duration: 15000
|
|
|
|
+ });
|
|
this.faceTestEndHandle("FAILED");
|
|
this.faceTestEndHandle("FAILED");
|
|
}
|
|
}
|
|
}
|
|
}
|