修改样式
This commit is contained in:
@@ -10,7 +10,10 @@
|
||||
<view style="height:50rpx"></view>
|
||||
<!-- #endif -->
|
||||
<!-- #ifdef APP-PLUS -->
|
||||
<button @click="handleDelete">删除缓存</button>
|
||||
<!-- 删除设备ID--测试用 -->
|
||||
<view class="del-cache" @click="handleDelete">
|
||||
<uni-icons type="minus" size="30" color="#ffffff"></uni-icons>
|
||||
</view>
|
||||
<!-- #endif -->
|
||||
|
||||
<!-- 搜索 @confirm="handleSearch" -->
|
||||
@@ -160,23 +163,24 @@ import {showLoading,hideLoading} from '@/utils/message.js'
|
||||
// #ifdef APP-PLUS
|
||||
// 获取 存储手机的module
|
||||
const safeSave = uni.requireNativePlugin("Tm-TmSafeSaveFileModule");
|
||||
|
||||
const handleDelete=()=>{
|
||||
safeSave.delSafeFile({
|
||||
"key": "app_device_id"
|
||||
}, (res) => {
|
||||
console.log(res);
|
||||
uni.showModal({
|
||||
title: '提示',
|
||||
content: "是否确认删除设备ID?删除之后需重新绑定设备,谨慎操作!!!",
|
||||
cancelText: '取消',
|
||||
confirmText: '确定',
|
||||
success: function (res) {
|
||||
if (res.confirm) {
|
||||
safeSave.delSafeFile({"key": "app_device_id"}, (res) => {
|
||||
if (res.code == 1) {
|
||||
uni.showModal({
|
||||
title: "删除成功",
|
||||
content:"删除成功",
|
||||
})
|
||||
uni.showModal({title: "提示",content:"删除成功"})
|
||||
} else {
|
||||
uni.showModal({
|
||||
title: "读取失败",
|
||||
content: res.msg,
|
||||
|
||||
uni.showModal({title: "删除失败",content: res.msg})
|
||||
}
|
||||
})
|
||||
} else if (res.cancel) {
|
||||
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -370,6 +374,22 @@ const formatDateStr =(times)=>{
|
||||
</script>
|
||||
|
||||
<style scope>
|
||||
.del-cache{
|
||||
position: fixed;
|
||||
right:30rpx;
|
||||
bottom:30%;
|
||||
width:60rpx;
|
||||
height: 60rpx;
|
||||
line-height: 60rpx;
|
||||
border-radius: 50%;
|
||||
background:#579FF9;
|
||||
font-size:12px;
|
||||
padding:5rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.scroll-h{
|
||||
/* #ifdef APP-PLUS */
|
||||
height:calc(100vh - 30px) !important;
|
||||
|
||||
@@ -273,6 +273,8 @@ const submitForm = () => {
|
||||
userStore.login(res);
|
||||
uni.switchTab({ url: '/pages/home/home' })
|
||||
btnLoading.value = false;
|
||||
}).finally(()=>{
|
||||
btnLoading.value = false;
|
||||
})
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user