2022-03-17 07:49:07 +00:00
|
|
|
<template>
|
|
|
|
<view>
|
2022-03-18 11:01:31 +00:00
|
|
|
<status-nav navBarTitle="设置" returnColor="#c2c2c2"></status-nav>
|
|
|
|
<container-subgroup>
|
|
|
|
<view slot="content" style="margin: 0 -30rpx;" class="fon28">
|
2022-03-24 08:34:50 +00:00
|
|
|
<!-- #ifdef APP-PLUS -->
|
|
|
|
<view class="bacf pad30 disjbac bbot">
|
|
|
|
<view>开启语音提醒</view>
|
|
|
|
<view><evan-switch v-model="voiceStatus" @change="voiceEv" :size="18" inactive-color="#b3b3b3" active-color="#fd8956"></evan-switch></view>
|
|
|
|
</view>
|
|
|
|
<view class="bacf pad30 disjbac mar-x20">
|
|
|
|
<view>接受新消息通知</view>
|
|
|
|
<view><evan-switch v-model="newsStatus" @change="newsEv" :size="18" inactive-color="#b3b3b3" active-color="#fd8956"></evan-switch></view>
|
|
|
|
</view>
|
|
|
|
<!-- #endif -->
|
|
|
|
<view @tap="updatePassword" class="bacf pad30 disjbac bbot">
|
2022-03-18 11:01:31 +00:00
|
|
|
<view>修改登录密码</view>
|
|
|
|
<i class="icon icon-next col9" style="font-size: 26rpx;"></i>
|
|
|
|
</view>
|
2022-03-24 08:34:50 +00:00
|
|
|
<!-- #ifdef APP-PLUS -->
|
|
|
|
<view @tap="cleanEv" class="bacf pad30 disjbac">
|
|
|
|
<view>清除缓存</view>
|
|
|
|
<view class="col9">{{cacheSize}}</view>
|
|
|
|
</view>
|
|
|
|
<!-- #endif -->
|
2022-03-18 11:01:31 +00:00
|
|
|
<view class="bacf pad30 disjbac mar-s20 bbot">
|
|
|
|
<view>上门服务条款</view>
|
|
|
|
<view class="disac col9">
|
2022-04-01 08:56:35 +00:00
|
|
|
V3.0<i class="icon icon-next col9 mar-z10" style="font-size: 26rpx;"></i>
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="bacf pad30 disjbac bbot">
|
|
|
|
<view>用户服务协议</view>
|
|
|
|
<view class="disac col9">
|
2022-04-01 08:56:35 +00:00
|
|
|
V1.1<i class="icon icon-next col9 mar-z10" style="font-size: 26rpx;"></i>
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="bacf pad30 disjbac bbot">
|
|
|
|
<view>飞猴云服务隐私政策</view>
|
|
|
|
<view class="disac col9">
|
2022-04-01 08:56:35 +00:00
|
|
|
V1.2<i class="icon icon-next col9 mar-z10" style="font-size: 26rpx;"></i>
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="bacf pad30 disjbac bbot">
|
|
|
|
<view>技术服务合作协议</view>
|
|
|
|
<view class="disac col9">
|
2022-04-01 08:56:35 +00:00
|
|
|
V1.1<i class="icon icon-next col9 mar-z10" style="font-size: 26rpx;"></i>
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="bacf pad30 disjbac bbot">
|
|
|
|
<view>关于飞猴云服务</view>
|
|
|
|
<view class="disac col9">
|
2022-04-01 08:56:35 +00:00
|
|
|
V1.1<i class="icon icon-next col9 mar-z10" style="font-size: 26rpx;"></i>
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
2022-03-24 08:34:50 +00:00
|
|
|
<!-- #ifdef APP-PLUS -->
|
|
|
|
<view @tap="checkEdition" class="bacf pad30 disjbac">
|
|
|
|
<view>版本更新</view>
|
|
|
|
<view class="col9">当前版本 5.1.4</view>
|
|
|
|
</view>
|
|
|
|
<!-- #endif -->
|
2022-03-18 11:01:31 +00:00
|
|
|
</view>
|
|
|
|
</container-subgroup>
|
2022-03-17 07:49:07 +00:00
|
|
|
</view>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
2022-03-18 11:01:31 +00:00
|
|
|
import evanSwitch from '@/components/evan-switch/evan-switch.vue';
|
2022-03-17 07:49:07 +00:00
|
|
|
export default {
|
2022-03-18 11:01:31 +00:00
|
|
|
components:{
|
|
|
|
evanSwitch
|
|
|
|
},
|
2022-03-17 07:49:07 +00:00
|
|
|
data() {
|
|
|
|
return {
|
2022-03-18 11:01:31 +00:00
|
|
|
voiceStatus:false,//是否开启语音提醒
|
|
|
|
newsStatus:false,//是否开启接受新消息通知
|
2022-03-24 08:34:50 +00:00
|
|
|
cacheSize:'754.72 KB',//缓存数据大小
|
2022-03-17 07:49:07 +00:00
|
|
|
}
|
|
|
|
},
|
2022-03-18 11:01:31 +00:00
|
|
|
onLoad() {
|
|
|
|
// 调用获取缓存数据的大小
|
|
|
|
this.getStorageDataNum();
|
2022-03-30 10:04:40 +00:00
|
|
|
this.getSettings()
|
2022-03-18 11:01:31 +00:00
|
|
|
},
|
2022-03-17 07:49:07 +00:00
|
|
|
methods: {
|
2022-03-18 11:01:31 +00:00
|
|
|
// 获取缓存数据的大小
|
|
|
|
getStorageDataNum(){
|
|
|
|
// #ifdef APP-PLUS
|
|
|
|
var self = this;
|
|
|
|
plus.cache.calculate(function(size) { //size是多少个字节单位是b
|
|
|
|
//做下面相应的处理
|
|
|
|
if (size < 1024) {
|
2022-03-22 10:15:22 +00:00
|
|
|
self.cacheSize = size + ' B';
|
2022-03-18 11:01:31 +00:00
|
|
|
} else if (size / 1024 >= 1 && size / 1024 / 1024 < 1) {
|
2022-03-22 10:15:22 +00:00
|
|
|
self.cacheSize = Math.floor(size / 1024 * 100) / 100 + ' KB';
|
2022-03-18 11:01:31 +00:00
|
|
|
} else if (size / 1024 / 1024 >= 1) {
|
2022-03-22 10:15:22 +00:00
|
|
|
self.cacheSize = Math.floor(size / 1024 / 1024 * 100) / 100 + ' M';
|
2022-03-18 11:01:31 +00:00
|
|
|
}
|
|
|
|
});
|
|
|
|
// #endif
|
|
|
|
},
|
|
|
|
// 语音提醒事件
|
|
|
|
voiceEv(status){
|
|
|
|
console.log(status);
|
|
|
|
},
|
|
|
|
// 新消息通知事件
|
|
|
|
newsEv(status){
|
|
|
|
console.log(status);
|
|
|
|
},
|
|
|
|
// 修改登录密码
|
|
|
|
updatePassword(){
|
2022-03-30 01:04:25 +00:00
|
|
|
uni.navigateTo({
|
|
|
|
url:'/pages/forget/forget'
|
|
|
|
})
|
2022-03-18 11:01:31 +00:00
|
|
|
},
|
2022-03-30 10:04:40 +00:00
|
|
|
// 设置
|
|
|
|
getSettings(){
|
|
|
|
this.$requst.post('/universal/api.settings/settings').then(res=>{
|
2022-04-06 03:24:55 +00:00
|
|
|
if(res.code){
|
2022-03-30 10:04:40 +00:00
|
|
|
|
|
|
|
// uni.navigateBack({delta:1})
|
|
|
|
|
|
|
|
}
|
|
|
|
})
|
|
|
|
},
|
2022-03-18 11:01:31 +00:00
|
|
|
// 清除缓存事件
|
|
|
|
cleanEv(){
|
|
|
|
console.log('清除缓存事件');
|
|
|
|
// #ifdef APP-PLUS
|
|
|
|
var self = this;
|
|
|
|
//使用plus.cache.clear 清除应用中的缓存数据
|
|
|
|
plus.cache.clear(function() {
|
|
|
|
uni.showToast({
|
|
|
|
title: '清除成功!',
|
|
|
|
icon: 'none',
|
|
|
|
success() {
|
|
|
|
self.cacheSize = '0B'
|
|
|
|
}
|
|
|
|
})
|
|
|
|
});
|
|
|
|
// #endif
|
|
|
|
},
|
|
|
|
// 检测版本事件
|
|
|
|
checkEdition(){
|
|
|
|
console.log('检测版本事件');
|
|
|
|
}
|
2022-03-17 07:49:07 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
|
|
|
</style>
|