From 69a4517bb5887aefea88c13b6c095b252debd857 Mon Sep 17 00:00:00 2001
From: zmr900709 <1838875027@qq.com>
Date: Wed, 15 Jul 2020 16:04:31 +0800
Subject: [PATCH 1/2] null
---
common/api/user.js | 4 ++++
components/remaining/remaining.vue | 25 ++++++++++++++++---------
2 files changed, 20 insertions(+), 9 deletions(-)
diff --git a/common/api/user.js b/common/api/user.js
index 2833b3b..9a6e219 100644
--- a/common/api/user.js
+++ b/common/api/user.js
@@ -284,6 +284,10 @@ export default {
delMessage({ type }) {
return vm.$u.post('/message/readMessage', { type });
},
+ // 已读消息
+ refreshToken({ }) {
+ return vm.$u.post('/Auth/refreshToken', { });
+ },
}
}
}
\ No newline at end of file
diff --git a/components/remaining/remaining.vue b/components/remaining/remaining.vue
index c5e8bd7..533ac50 100644
--- a/components/remaining/remaining.vue
+++ b/components/remaining/remaining.vue
@@ -12,9 +12,7 @@
跳过{{remaining}}
跳过
-
- {{'ddd' + heightOut}}
- 111
+
@@ -24,7 +22,7 @@
-
+
@@ -199,10 +197,19 @@
},
durationChange(e) {
this.duration = e.target.value
+ },
+ refreshToken_function(){
+ this.$u.api.refreshToken({}).then((res) => {
+ console.log(res)
+ if (res.errCode == 0) {
+ let token = res.data.token;
+ uni.setStorageSync('token', token);//存储toke值
+ }
+ })
}
},
mounted() {
-
+ this.refreshToken_function()
// 3秒倒计时调用
this.remaining_time()
this.apiwelcome()
@@ -215,14 +222,14 @@
// height: 400rpx;
}
.welcome_jumpes {
- width: 90rpx;
- height: 35rpx;
+ width: 94rpx;
+ height: 36rpx;
opacity: 0.5;
border-radius: 18rpx;
position: absolute;
right: 37rpx;
- top: 34rpx;
- font-size: 20rpx;
+ top: 66rpx;
+ font-size: 22rpx;
text-align: center;
line-height: 35rpx;
color: #fff;
--
2.45.2
From 191806263943a260bfc442a069f9449c7dc7f4fc Mon Sep 17 00:00:00 2001
From: zmr900709 <1838875027@qq.com>
Date: Wed, 15 Jul 2020 16:16:40 +0800
Subject: [PATCH 2/2] vue install
---
package-lock.json | 5 +++++
package.json | 3 ++-
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/package-lock.json b/package-lock.json
index 5a8d228..dde9e73 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -8,6 +8,11 @@
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/uview-ui/-/uview-ui-1.5.0.tgz",
"integrity": "sha512-1UdMUGJqWx60ALbXXXs3rQHKUNBARDIV5XHc06mKFxpccO/i0tzoSqS6RuPdmYwXU1q59wnIU+NLABvcU5u4vw=="
+ },
+ "vuex": {
+ "version": "3.5.1",
+ "resolved": "https://registry.npmjs.org/vuex/-/vuex-3.5.1.tgz",
+ "integrity": "sha512-w7oJzmHQs0FM9LXodfskhw9wgKBiaB+totOdb8sNzbTB2KDCEEwEs29NzBZFh/lmEK1t5tDmM1vtsO7ubG1DFw=="
}
}
}
diff --git a/package.json b/package.json
index d8e4866..e570d02 100644
--- a/package.json
+++ b/package.json
@@ -13,6 +13,7 @@
"author": "",
"license": "ISC",
"dependencies": {
- "uview-ui": "^1.5.0"
+ "uview-ui": "^1.5.0",
+ "vuex": "^3.5.1"
}
}
--
2.45.2