From b79a39d92db3baae7c3c8587e2858561bec0d6ca Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期三, 17 四月 2024 14:37:34 +0800
Subject: [PATCH] mrshi

---
 wx/pages/details_dispatch_unit/details_dispatch_unit.vue |   24 ++++++++++++++++++++++++
 1 files changed, 24 insertions(+), 0 deletions(-)

diff --git a/wx/pages/details_dispatch_unit/details_dispatch_unit.vue b/wx/pages/details_dispatch_unit/details_dispatch_unit.vue
index 70091b0..5e9b14f 100644
--- a/wx/pages/details_dispatch_unit/details_dispatch_unit.vue
+++ b/wx/pages/details_dispatch_unit/details_dispatch_unit.vue
@@ -151,6 +151,7 @@
 </template>
 
 <script>
+	import { mapState } from 'vuex'
 	export default {
 		data() {
 			return {
@@ -182,7 +183,30 @@
 		onReachBottom() {
 			this.getList()
 		},
+		computed: {
+			...mapState(['userInfo'])
+		},
 		methods: {
+			send () {
+				this.$u.api.sendSms({
+					phone: this.userInfo.mobile
+				}).then(res => {
+					if (res.code === 200) {
+						this.num = 60
+						this.setTime()
+					}
+				})
+			},
+			setTime () {
+				this.timer = setInterval(() => {
+					if (this.num === 0) {
+						clearInterval(this.timer)
+						this.timer = null
+						return
+					}
+					this.num = this.num - 1
+				}, 1000)
+			},
 			// 绛剧讲
 			confirm1() {
 				if (!this.code) {

--
Gitblit v1.9.3