This commit is contained in:
2025-04-05 23:47:00 +08:00
commit 8001f8eaeb
215 changed files with 14655 additions and 0 deletions

60
pages/user/user.js Normal file
View File

@@ -0,0 +1,60 @@
var t = getApp(), e = require("../../utils/login.js");
Page({
data: {
showLoding: !0,
urlList: [],
user: {}
},
onLoad: function(n) {
var o = this;
e.pageStart(t).then(function(t) {
o.getContent();
});
},
onShow: function() {
this.refresh && this.getContent();
},
onPullDownRefresh: function() {},
onShareAppMessage: function() {},
getContent: function() {
var n = this;
wx.showLoading({
title: ""
}), e.request(t.globalData.config.user.log, {}, !0).then(function(t) {
if (wx.hideLoading(), 200 != t.code) return wx.showModal({
title: "提示",
content: t.message
}), !1;
n.setData({
showLoding: !1,
user: t.data.user,
urlList: t.data.menu
}, function() {});
}).catch(function(t) {
wx.hideLoading();
});
},
islogin: function() {
wx.showLoading({
title: "加载中"
});
},
refresh: 0,
toPage: function(t) {
var e = t.currentTarget.dataset, n = (e.refresh, e.url);
n ? wx.navigateTo({
url: "/pages/".concat(n)
}) : wx.showToast({
title: "页面开发中~",
icon: "none",
duration: 2e3
}), this.refresh = 1;
},
callUs: function() {
if (!t.globalData.servicetel) return !1;
wx.makePhoneCall({
phoneNumber: "" + t.globalData.servicetel
});
}
});

8
pages/user/user.json Normal file
View File

@@ -0,0 +1,8 @@
{
"navigationBarTitleText": "聚美汽服",
"usingComponents": {
"service-tel": "../../template/serviceTel/serviceTel",
"my-money": "../../template/myMoney/myMoney",
"page-loding": "../../template/pageLoding/pageLoding"
}
}

75
pages/user/user.wxml Normal file
View File

@@ -0,0 +1,75 @@
<view class="container">
<page-loding wx:if="{{showLoding}}"></page-loding>
<view class="page-top">
<view class="user-info">
<view class="avatar">
<image src="{{user.avatar}}"></image>
</view>
<view class="info">
<view class="left">
<view class="username">{{user.nickname}}</view>
<view class="tel">{{user.mobile}}</view>
</view>
<view class="right">
<image class="xunzhang" mode="widthFix" src="http://jm.v0750.com/image/xunzhang.png" wx:if="{{user.groupid==6}}"></image>
<image class="zhe" mode="widthFix" src="http://jm.v0750.com/image/zhe.png" wx:if="{{user.isdiscount}}"></image>
</view>
</view>
<view class="my-capital shadow">
<view class="title">
<view class="text">我的资产</view>
<view bindtap="toPage" class="btn" data-refresh="1" data-url="voucher/voucher">立即充值 ></view>
</view>
<view class="money-box">
<view class="item">
<view class="num">{{user.money}}</view>
<view class="name">合计</view>
</view>
<view class="item">
<view class="num">{{user.principal}}</view>
<view class="name">洗车金</view>
</view>
<view class="item">
<view class="num">{{user.givenamount}}</view>
<view class="name">赠送</view>
</view>
</view>
</view>
</view>
</view>
<view class="order-manager shadow">
<view class="title">
<view>订单管理</view>
<navigator class="btn" url="/pages/orderList/orderList?tab=all">全部订单 ></navigator>
</view>
<view class="list">
<navigator class="item" url="/pages/orderList/orderList?tab=0">
<text class="iconfont icon-31hongbao"></text>
<view class="name ">待付款</view>
</navigator>
<navigator class="item" url="/pages/orderList/orderList?tab=1">
<text class="iconfont icon-31daifukuan"></text>
<view class="name ">待使用</view>
</navigator>
<navigator class="item" url="/pages/orderList/orderList?tab=4">
<text class="iconfont icon-31daifahuo"></text>
<view class="name ">已完成</view>
</navigator>
</view>
</view>
<view class="url-list shadow">
<view bindtap="toPage" class="item" data-url="{{item.url}}" wx:for="{{urlList}}" wx:key="index">
<text class="iconfont icon-{{item.img}}"></text>
<view class="name">{{item.name}}</view>
</view>
<view bindtap="callUs" class="item" openType="contact">
<text class="iconfont icon-10"></text>
<view class="name">联系客服</view>
</view>
</view>
<view class="footer-btn">
<navigator class="btn" hoverClass="hover" url="/pages/index/index">首页</navigator>
<view class="btn">扫一扫</view>
<navigator class="btn" hoverClass="hover" url="/pages/voucher/voucher">充值</navigator>
</view>
</view>

227
pages/user/user.wxss Normal file
View File

@@ -0,0 +1,227 @@
.container {
background: #fafafa;
min-height: 100vh;
padding: 0rpx 0 100rpx;
}
.container,.page-top {
box-sizing: border-box;
}
.page-top {
background-image: linear-gradient(-70deg,#11b393,#4eb9f7);
height: 290rpx;
margin-bottom: 112rpx;
padding: 38rpx 27rpx;
position: relative;
}
.shadow {
background: #fff;
border-radius: 18rpx;
box-shadow: 0 0rpx 9rpx 4rpx hsla(0,0%,80%,.75);
}
.page-top .user-info {
align-items: center;
display: flex;
}
.page-top .user-info .left {
display: inline-flex;
flex-direction: column;
}
.page-top .user-info .avatar {
border: 5rpx solid #fff;
border-radius: 50%;
display: inline-flex;
flex: 0 0 110rpx;
height: 110rpx;
margin-right: 20rpx;
overflow: hidden;
width: 110rpx;
}
.page-top .user-info .avatar image {
height: 100%;
width: 100%;
}
.page-top .user-info .info {
align-items: center;
color: #fff;
display: inline-flex;
flex: 1;
font-size: 26rpx;
justify-content: space-between;
}
.page-top .user-info .info .username {
font-size: 33rpx;
margin-bottom: 20rpx;
}
.page-top .user-info .right {
display: inline-flex;
}
.page-top .user-info .right .zhe {
height: 58rpx;
margin-left: 6px;
width: 58rpx;
}
.page-top .user-info .right .xunzhang {
height: 59rpx;
width: 118rpx;
}
.page-top .my-capital {
background: #fff;
height: 184rpx;
left: 27rpx;
position: absolute;
top: 182rpx;
width: calc(100vw - 54rpx);
z-index: 3;
}
.title {
align-items: center;
color: #000;
display: flex;
font-size: 29rpx;
justify-content: space-between;
padding-left: 34rpx;
padding-top: 10rpx;
}
.title .btn,.title .text {
display: inline-flex;
}
.title .btn {
color: #666;
font-size: 22rpx;
padding: 10rpx 14rpx;
}
.money-box {
display: flex;
padding: 16rpx 0 24rpx;
}
.money-box .item {
align-items: center;
display: inline-flex;
flex: 1;
flex-direction: column;
font-weight: 400;
justify-content: center;
}
.money-box .item .num {
color: #f60;
font-size: 33rpx;
margin-bottom: 4rpx;
}
.money-box .item .name {
color: #666;
font-size: 22rpx;
}
.order-manager {
box-sizing: border-box;
margin: 0 27rpx 36rpx;
}
.order-manager .list {
display: flex;
padding: 18rpx 0 30rpx;
}
.order-manager .list .item {
align-items: center;
background: #fff;
border: none;
color: #666;
display: inline-flex;
flex: 1;
flex-direction: column;
font-size: 50rpx;
height: 97rpx;
justify-content: space-between;
}
button::after {
background: transparent;
border: none;
}
.iconfont {
font-size: 64rpx;
margin: -10rpx;
}
.order-manager .list .item .name {
font-size: 22rpx;
margin-top: 2rpx;
}
.url-list {
align-items: flex-start;
box-sizing: border-box;
display: flex;
flex-wrap: wrap;
font-size: 0rpx;
margin: 0 27rpx 36rpx;
padding-bottom: 12rpx;
}
.url-list .item {
align-items: center;
background: transparent;
color: #666;
display: inline-flex;
flex-direction: column;
font-size: 26rpx;
justify-content: space-between;
line-height: 1;
padding: 50rpx 0 34rpx;
text-align: center;
width: 33.33%;
}
.url-list .item .name {
margin-top: 22rpx;
}
.footer-btn {
background: #fff;
bottom: 0;
box-shadow: 0 0rpx 9rpx 4rpx hsla(0,0%,80%,.75);
color: #666;
display: flex;
font-size: 29rpx;
left: 0;
padding: 12rpx 0;
position: fixed;
width: 100vw;
}
.footer-btn,.footer-btn .btn {
align-items: center;
}
.footer-btn .btn {
display: inline-flex;
flex: 1;
height: 58rpx;
justify-content: center;
}
.footer-btn .btn:not(:last-child) {
border-right: 1px solid #999;
}