app打开默认弹出隐私弹窗

This commit is contained in:
kuaifan 2022-09-22 16:06:26 +08:00
parent 10c68a7dc5
commit 38c4e611c3
11 changed files with 41 additions and 60 deletions

2
public/css/app.css vendored

File diff suppressed because one or more lines are too long

2
public/js/app.js vendored

File diff suppressed because one or more lines are too long

1
public/js/build/205.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
639608afadc6cadc
e1d433fa71d06d04

View File

@ -14,12 +14,9 @@
{{ $L('更新客户端') }}
</div>
</template>
<div v-if="showPrivacy" class="common-right-bottom-link privacy" :class="{shake:privacyShake}">
<Checkbox v-model="privacyAgreed"></Checkbox>
<a target="_blank" :href="$A.apiUrl('../privacy.html')" @click="privacyAgreed=true">
{{ $L('隐私政策') }}
</a>
</div>
<a v-if="showPrivacy" class="common-right-bottom-link" target="_blank" :href="$A.apiUrl('../privacy.html')">
{{ $L('隐私政策') }}
</a>
<Modal
v-model="updateShow"
:closable="false"
@ -65,8 +62,6 @@ export default {
updateIng: false,
downloadUrl: '',
privacyAgreed: false,
}
},
@ -98,20 +93,10 @@ export default {
if (show) {
this.updateBottomShow = true
}
},
privacyAgreed(val) {
this.$store.state.privacyAgreed = val
},
privacyShake(val) {
if (val) {
setTimeout(_ => this.$store.state.privacyShake = false, 600)
}
},
}
},
computed: {
...mapState(['privacyShake']),
isSoftware() {
return this.$Electron || this.$isEEUiApp;
},

View File

@ -123,6 +123,21 @@
<div class="login-forgot">{{$L('忘记密码了?')}}<a href="javascript:void(0)" @click="forgotPassword">{{$L('重置密码')}}</a></div>
</div>
</div>
<!--隐私政策提醒-->
<Modal
v-model="privacyShow"
:title="$L('隐私协议')"
:mask-closable="false">
<div class="privacy-content">
<div>欢迎使用本软件</div>
<p>在您使用本软件前请您认真阅读并了解相应的<a target="_blank" :href="$A.apiUrl('../privacy.html')">{{ $L('隐私政策') }}</a>以了解我们的服务内容和您相关个人信息的处理规则我们将严格的按照隐私服务协议为您提供服务保护您的个人信息</p>
</div>
<div slot="footer" class="adaption">
<Button type="default" @click="onPrivacy(false)">{{$L('不同意')}}</Button>
<Button type="primary" @click="onPrivacy(true)">{{$L('同意')}}</Button>
</div>
</Modal>
</div>
</template>
@ -152,6 +167,8 @@ export default {
needInvite: false,
subscribe: null,
privacyShow: !!this.$isEEUiApp,
}
},
mounted() {
@ -198,8 +215,6 @@ export default {
'themeMode',
'themeList',
'privacyAgreed',
]),
isSoftware() {
@ -221,15 +236,6 @@ export default {
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)
}
},
@ -401,12 +407,13 @@ export default {
});
},
onLogin() {
if (this.showPrivacy && !this.privacyAgreed) {
this.$store.state.privacyShake = true
$A.messageWarning("请阅读《隐私政策》并同意");
return;
onPrivacy(agree) {
if (!agree) {
$A.eeuiAppGoDesktop()
}
},
onLogin() {
this.chackServerUrl(true).then(() => {
this.email = $A.trim(this.email)
this.password = $A.trim(this.password)

View File

@ -11,10 +11,6 @@ const stateData = {
// 窗口是否激活
windowActive: true,
// 隐私政策同意/抖动
privacyAgreed: false,
privacyShake: false,
// App通知权限
appNotificationPermission: true,

View File

@ -20,14 +20,6 @@
color: #fff;
background-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 {
color: #fff;
opacity: 0.9;
@ -96,14 +88,6 @@
}
}
@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) {
.common-right-bottom {
bottom: 20px;

View File

@ -151,6 +151,15 @@
}
}
.privacy-content {
margin-bottom: 12px;
line-height: 26px;
font-size: 16px;
> p {
text-indent: 2rem;
}
}
@media (max-width: 768px) {
.page-login {
.login-body {

@ -1 +1 @@
Subproject commit 5b26d9ce08d7877085b47f9617c7ad0e0fe12ec7
Subproject commit 5a48bcd34e7c79a1818bbe61d84b5ce47b005538