mirror of
https://github.com/kuaifan/dootask.git
synced 2026-03-17 19:23:26 +00:00
隐私政策同意相关
This commit is contained in:
parent
7ab20707c3
commit
7ab858088b
2
public/css/app.css
vendored
2
public/css/app.css
vendored
File diff suppressed because one or more lines are too long
2
public/js/app.js
vendored
2
public/js/app.js
vendored
File diff suppressed because one or more lines are too long
1
public/js/build/225.js
vendored
Normal file
1
public/js/build/225.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
public/js/build/492.js
vendored
1
public/js/build/492.js
vendored
File diff suppressed because one or more lines are too long
@ -1 +1 @@
|
|||||||
38a09a69a7591dbd
|
639608afadc6cadc
|
||||||
|
|||||||
@ -14,9 +14,12 @@
|
|||||||
{{ $L('更新客户端') }}
|
{{ $L('更新客户端') }}
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<a v-if="showPrivacy" class="common-right-bottom-link" target="_blank" :href="$A.apiUrl('../privacy.html')">
|
<div v-if="showPrivacy" class="common-right-bottom-link privacy" :class="{shake:privacyShake}">
|
||||||
《{{ $L('隐私政策') }}》
|
<Checkbox v-model="privacyAgreed"></Checkbox>
|
||||||
</a>
|
<a target="_blank" :href="$A.apiUrl('../privacy.html')" @click="privacyAgreed=true">
|
||||||
|
《{{ $L('隐私政策') }}》
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
<Modal
|
<Modal
|
||||||
v-model="updateShow"
|
v-model="updateShow"
|
||||||
:closable="false"
|
:closable="false"
|
||||||
@ -62,6 +65,8 @@ export default {
|
|||||||
updateIng: false,
|
updateIng: false,
|
||||||
|
|
||||||
downloadUrl: '',
|
downloadUrl: '',
|
||||||
|
|
||||||
|
privacyAgreed: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -93,10 +98,20 @@ export default {
|
|||||||
if (show) {
|
if (show) {
|
||||||
this.updateBottomShow = true
|
this.updateBottomShow = true
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
privacyAgreed(val) {
|
||||||
|
this.$store.state.privacyAgreed = val
|
||||||
|
},
|
||||||
|
privacyShake(val) {
|
||||||
|
if (val) {
|
||||||
|
setTimeout(_ => this.$store.state.privacyShake = false, 600)
|
||||||
|
}
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
|
...mapState(['privacyShake']),
|
||||||
|
|
||||||
isSoftware() {
|
isSoftware() {
|
||||||
return this.$Electron || this.$isEEUiApp;
|
return this.$Electron || this.$isEEUiApp;
|
||||||
},
|
},
|
||||||
|
|||||||
@ -198,6 +198,8 @@ export default {
|
|||||||
|
|
||||||
'themeMode',
|
'themeMode',
|
||||||
'themeList',
|
'themeList',
|
||||||
|
|
||||||
|
'privacyAgreed',
|
||||||
]),
|
]),
|
||||||
|
|
||||||
isSoftware() {
|
isSoftware() {
|
||||||
@ -219,6 +221,15 @@ export default {
|
|||||||
text += "成功..."
|
text += "成功..."
|
||||||
}
|
}
|
||||||
return text
|
return text
|
||||||
|
},
|
||||||
|
|
||||||
|
showPrivacy() {
|
||||||
|
return [
|
||||||
|
'127.0.0.1:2222',
|
||||||
|
'dootask.com',
|
||||||
|
'www.dootask.com',
|
||||||
|
't.hitosea.com',
|
||||||
|
].includes($A.getDomain($A.apiUrl('../'))) && this.$isEEUiApp && ['login'].includes(this.$route.name)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -391,6 +402,11 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
onLogin() {
|
onLogin() {
|
||||||
|
if (this.showPrivacy && !this.privacyAgreed) {
|
||||||
|
this.$store.state.privacyShake = true
|
||||||
|
$A.messageWarning("请阅读《隐私政策》并同意");
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.chackServerUrl(true).then(() => {
|
this.chackServerUrl(true).then(() => {
|
||||||
this.email = $A.trim(this.email)
|
this.email = $A.trim(this.email)
|
||||||
this.password = $A.trim(this.password)
|
this.password = $A.trim(this.password)
|
||||||
|
|||||||
4
resources/assets/js/store/state.js
vendored
4
resources/assets/js/store/state.js
vendored
@ -11,6 +11,10 @@ const stateData = {
|
|||||||
// 窗口是否激活
|
// 窗口是否激活
|
||||||
windowActive: true,
|
windowActive: true,
|
||||||
|
|
||||||
|
// 隐私政策同意/抖动
|
||||||
|
privacyAgreed: false,
|
||||||
|
privacyShake: false,
|
||||||
|
|
||||||
// App通知权限
|
// App通知权限
|
||||||
appNotificationPermission: true,
|
appNotificationPermission: true,
|
||||||
|
|
||||||
|
|||||||
@ -20,6 +20,14 @@
|
|||||||
color: #fff;
|
color: #fff;
|
||||||
background-color: $primary-color;
|
background-color: $primary-color;
|
||||||
border-color: $primary-color;
|
border-color: $primary-color;
|
||||||
|
&.privacy {
|
||||||
|
.ivu-checkbox-wrapper {
|
||||||
|
margin-right: 2px;
|
||||||
|
}
|
||||||
|
&.shake {
|
||||||
|
animation: ani-privacy-agreed-shake 500ms ease-in-out;
|
||||||
|
}
|
||||||
|
}
|
||||||
&:hover {
|
&:hover {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
opacity: 0.9;
|
opacity: 0.9;
|
||||||
@ -88,6 +96,14 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@keyframes ani-privacy-agreed-shake {
|
||||||
|
10%, 90% { transform: translate3d(-1px, 0, 0); }
|
||||||
|
20%, 80% { transform: translate3d(+2px, 0, 0); }
|
||||||
|
30%, 70% { transform: translate3d(-4px, 0, 0); }
|
||||||
|
40%, 60% { transform: translate3d(+4px, 0, 0); }
|
||||||
|
50% { transform: translate3d(-4px, 0, 0); }
|
||||||
|
}
|
||||||
|
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
.common-right-bottom {
|
.common-right-bottom {
|
||||||
bottom: 20px;
|
bottom: 20px;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user