From 190a164421a9d20a68e2b86b449721e93a92dde9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=88=98=E4=BB=95=E4=BC=9F?= <499672082@qq.com>
Date: Fri, 10 Feb 2023 17:57:44 +0000
Subject: [PATCH] Update AppSignIn.vue
---
src/project/qianxinan/AppSignIn/AppSignIn.vue | 41 ++++++++-----------
1 file changed, 16 insertions(+), 25 deletions(-)
diff --git a/src/project/qianxinan/AppSignIn/AppSignIn.vue b/src/project/qianxinan/AppSignIn/AppSignIn.vue
index c148ee67..b7afdb2e 100644
--- a/src/project/qianxinan/AppSignIn/AppSignIn.vue
+++ b/src/project/qianxinan/AppSignIn/AppSignIn.vue
@@ -7,7 +7,7 @@
{{ user.name }}
-
每天需要完成2次打卡,打卡间隔4小时以上,才算完成打卡任务。
+
{{ today }}
打卡记录
@@ -19,14 +19,13 @@
{{ item.createDate }}
打卡成功
- 打卡{{ item.times}}次
-
-
打卡
+
+
{{ status==1? '已打卡':'打卡'}}
{{ time }}
@@ -42,6 +41,7 @@ export default {
return {
time: '',
today: '',
+ status: 0, // 打卡状态:0、未打卡;1、已打卡
signlist: [],
current: 1,
}
@@ -73,22 +73,16 @@ export default {
},
// 打卡
signIn() {
- if(this.flag) return
- this.flag = true
+ if(this.status == 1) {
+ return this.$u.toast("已打卡,请勿重复打卡!")
+ }
this.$http.post(`/api/appwechatsigninfo/sign`).then(res=> {
if(res.code == 0) {
- this.flag = false
this.$u.toast(`打卡成功`)
this.getToday()
this.getList()
- } else {
- this.flag = false
- this.$u.toast(res.msg)
}
- }).catch(err=> {
- this.flag = false
- this.$u.toast(err)
- })
+ }).catch(err=> console.log(err))
}
},
onShow() {
@@ -106,7 +100,7 @@ export default {
\ No newline at end of file