From 075a082f60ae3089bbca9e49ad49cf6ddf7bee31 Mon Sep 17 00:00:00 2001
From: liukangdong <898885815@qq.com>
Date: 星期五, 26 七月 2024 16:12:28 +0800
Subject: [PATCH] ‘’
---
wechat_staff/pages/login/index.less | 34 ++++++++++
wechat_staff/pages/login/index.wxml | 8 ++
wechat_staff/pages/login/index.wxss | 38 +++++++++++-
wechat_staff/pages/sets/index.wxss | 19 ++++++
wechat_staff/pages/sets/index.wxml | 5 -
wechat_staff/pages/login/index.js | 8 ++
wechat_staff/pages/sets/index.less | 20 ++++++
wechat_staff/pages/sets/index.js | 44 +++++++++-----
8 files changed, 149 insertions(+), 27 deletions(-)
diff --git a/wechat_staff/pages/login/index.js b/wechat_staff/pages/login/index.js
index 2d85c94..8182f8c 100644
--- a/wechat_staff/pages/login/index.js
+++ b/wechat_staff/pages/login/index.js
@@ -54,6 +54,11 @@
}, 1000)
})
},
+ handleJudge(e) {
+ const flag = e.currentTarget.dataset.flag
+ console.log(e);
+ this.setData({ agreementFalg: flag, showModal: false })
+ },
loginPhone() {
const {
code,
@@ -111,7 +116,8 @@
onLoad(options) {
var app = getApp().globalData
this.setData({
- primary: app.primary
+ primary: app.primary,
+ bottomLift: app.bottomLift
})
this.initData()
},
diff --git a/wechat_staff/pages/login/index.less b/wechat_staff/pages/login/index.less
index a63107c..b5818dc 100644
--- a/wechat_staff/pages/login/index.less
+++ b/wechat_staff/pages/login/index.less
@@ -61,7 +61,37 @@
}
.modal{
width: 100%;
- max-height: 1120rpx;
- min-height: 600rpx;
+ height: calc( 100vh - 200rpx );
padding: 40rpx;
+ position: relative;
+ .content{
+ height: calc( 100vh - 460rpx );
+ overflow: auto;
+ margin-bottom: 20rpx;
+ }
+ .btns{
+ position: fixed;
+ padding: 20rpx 0rpx;
+ width: 100%;
+ z-index: 999;
+ border-top: 1px solid #e5e5e5;
+ .reject{
+ width: 670rpx;
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #999999;
+ text-align: center;
+ margin-top: 30rpx;
+ }
+ .agree{
+ width: 670rpx;
+ height: 88rpx;
+ background: #B08771;
+ border-radius: 8rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ color: #fff;
+ }
+ }
}
\ No newline at end of file
diff --git a/wechat_staff/pages/login/index.wxml b/wechat_staff/pages/login/index.wxml
index 0ad9d90..db321a5 100644
--- a/wechat_staff/pages/login/index.wxml
+++ b/wechat_staff/pages/login/index.wxml
@@ -35,7 +35,13 @@
<!-- -->
<van-popup position="bottom" show="{{ showModal }}" round bind:close="onClose">
<view class="modal">
- <mp-html content="{{activeHtml}}"></mp-html>
+ <view class="content">
+ <mp-html content="{{activeHtml}}"></mp-html>
+ </view>
+ <view style="bottom: {{ bottomLift }}px" class="btns">
+ <view data-flag="{{true}}" bindtap="handleJudge" class="agree">鍚屾剰</view>
+ <view data-flag="{{false}}" bindtap="handleJudge" class="reject">涓嶅悓鎰忓苟閫�鍑�</view>
+ </view>
</view>
</van-popup>
</view>
\ No newline at end of file
diff --git a/wechat_staff/pages/login/index.wxss b/wechat_staff/pages/login/index.wxss
index 3aa86a0..cd3c013 100644
--- a/wechat_staff/pages/login/index.wxss
+++ b/wechat_staff/pages/login/index.wxss
@@ -4,7 +4,6 @@
border-radius: 50%;
margin: 130rpx auto 30rpx;
}
-
.home_title {
font-weight: 500;
font-size: 40rpx;
@@ -61,7 +60,38 @@
flex: 1;
}
.modal {
- width: 600rpx;
- min-height: 600rpx;
- padding: 30rpx;
+ width: 100%;
+ height: calc(100vh - 200rpx);
+ padding: 40rpx;
+ position: relative;
+}
+.modal .content {
+ height: calc(100vh - 460rpx);
+ overflow: auto;
+ margin-bottom: 20rpx;
+}
+.modal .btns {
+ position: fixed;
+ padding: 20rpx 0rpx;
+ width: 100%;
+ z-index: 999;
+ border-top: 1px solid #e5e5e5;
+}
+.modal .btns .reject {
+ width: 670rpx;
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #999999;
+ text-align: center;
+ margin-top: 30rpx;
+}
+.modal .btns .agree {
+ width: 670rpx;
+ height: 88rpx;
+ background: #B08771;
+ border-radius: 8rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ color: #fff;
}
diff --git a/wechat_staff/pages/sets/index.js b/wechat_staff/pages/sets/index.js
index d232609..1da5c40 100644
--- a/wechat_staff/pages/sets/index.js
+++ b/wechat_staff/pages/sets/index.js
@@ -1,6 +1,8 @@
// pages/sets/index.js
-import { logout } from '../../api/index'
+import {
+ logout
+} from '../../api/index'
Page({
/**
@@ -17,25 +19,35 @@
},
showLogout() {
- this.setData({show: true})
+ wx.showModal({
+ title: '鎻愮ず',
+ content: '纭閫�鍑虹櫥褰�',
+ success(res) {
+ if (res.confirm) {
+ logout({}).then(res => {
+ wx.setStorageSync('member', null)
+ wx.setStorageSync('token', '')
+ wx.navigateTo({
+ url: '/pages/login/index',
+ })
+ })
+ }
+ }
+ })
+
},
onClose() {
- this.setData({show: false})
- },
- changeDeal(e){
- wx.navigateTo({
- url: '/pages/sets/protocol?type='+e.currentTarget.dataset.index,
+ this.setData({
+ show: false
})
},
- logout(){
- logout({
- }).then(res => {
- wx.setStorageSync('member', null)
- wx.setStorageSync('token', '')
- wx.navigateTo({
- url: '/pages/login/index',
- })
- })
+ changeDeal(e) {
+ wx.navigateTo({
+ url: '/pages/sets/protocol?type=' + e.currentTarget.dataset.index,
+ })
+ },
+ logout() {
+
},
/**
* 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍒濇娓叉煋瀹屾垚
diff --git a/wechat_staff/pages/sets/index.less b/wechat_staff/pages/sets/index.less
index c60da15..259efa2 100644
--- a/wechat_staff/pages/sets/index.less
+++ b/wechat_staff/pages/sets/index.less
@@ -11,9 +11,29 @@
}
.icon{
width: 40rpx;
+ height: 40rpx;
}
}
}
+.logout{
+ width: 670rpx;
+ height: 88rpx;
+ line-height: 86rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border-radius: 8rpx;
+ border: 1rpx solid #B08771;
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #B08771;
+ display: flex;
+ margin-top: 100rpx;
+ .icon{
+ width: 40rpx;
+ height: 40rpx;
+ }
+}
.modal{
width: 610rpx;
height: 450rpx;
diff --git a/wechat_staff/pages/sets/index.wxml b/wechat_staff/pages/sets/index.wxml
index 2765015..bae6cd6 100644
--- a/wechat_staff/pages/sets/index.wxml
+++ b/wechat_staff/pages/sets/index.wxml
@@ -8,9 +8,8 @@
<view class="name">銆奪BOM鐢ㄦ埛闅愮鍗忚銆�</view>
<image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image>
</view>
- <view class="line" bindtap="showLogout">
- <view class="name">娉ㄩ攢璐﹀彿</view>
- <image class="icon" src="../../static/icon/home_ar@2x.png" mode="widthFix"></image>
+ <view class="logout" bindtap="showLogout">
+ <view class="name">閫�鍑虹櫥褰�</view>
</view>
</view>
<!-- -->
diff --git a/wechat_staff/pages/sets/index.wxss b/wechat_staff/pages/sets/index.wxss
index d59ed0d..ef9e711 100644
--- a/wechat_staff/pages/sets/index.wxss
+++ b/wechat_staff/pages/sets/index.wxss
@@ -13,6 +13,25 @@
}
.list .line .icon {
width: 40rpx;
+ height: 40rpx;
+}
+.logout {
+ width: 670rpx;
+ height: 88rpx;
+ line-height: 86rpx;
+ align-items: center;
+ justify-content: center;
+ border-radius: 8rpx;
+ border: 1rpx solid #B08771;
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #B08771;
+ display: flex;
+ margin-top: 100rpx;
+}
+.logout .icon {
+ width: 40rpx;
+ height: 40rpx;
}
.modal {
width: 610rpx;
--
Gitblit v1.9.3