新增分享按钮,自动复制分享链接(傻逼Safari),狮子可以查看下载人(同步更新)。交换按钮位置

This commit is contained in:
chuzhongzai
2023-02-13 10:37:12 +08:00
parent 4f06a20e52
commit 8ab862093b
2 changed files with 35 additions and 6 deletions
+5 -4
View File
@@ -153,8 +153,7 @@ const actions = {
validate(context, AuthCode){
axios.post(BaseUrl + "validate?AuthCode=" + AuthCode).then((res)=>{
if(res.data.result === 'success'){
state.userId = parseInt(res.data.data)
context.commit("_authed", AuthCode)
context.commit("_authed", {AuthCode, userId: parseInt(res.data.data)})
//初始化
context.dispatch("loadMaskDomain").then()
context.dispatch("loadWeekUsedAmount").then()
@@ -446,14 +445,16 @@ const mutations = {
_changePage(state, targetPage){
state.page = targetPage
},
_authed(state, AuthCode){
state.AuthCode = AuthCode
_authed(state, data){
state.AuthCode = data.AuthCode
state.userId = data.userId
state.isAuth = true
ElMessage("验证成功,加载中")
},
_unAuthed(state){
state.isAuth = false
state.AuthCode = ""
state.userId = -1
ElMessage("授权码错误")
localStorage.removeItem("auth")
},