diff --git a/app.json b/app.json index 327b666..c9333c8 100644 --- a/app.json +++ b/app.json @@ -66,6 +66,12 @@ "iconPath": "/static/kc1.png", "selectedIconPath": "/static/kc2.png" }, + { + "pagePath": "pages/projectModule/projectList/projectList", + "text": "接单", + "iconPath": "/static/kc1.png", + "selectedIconPath": "/static/kc2.png" + }, { "pagePath": "pages/personCenter/mine/mine", "text": "我的", diff --git a/pages/personCenter/contactSuper/contactSuper.js b/pages/personCenter/contactSuper/contactSuper.js index 58bad87..3f609a8 100644 --- a/pages/personCenter/contactSuper/contactSuper.js +++ b/pages/personCenter/contactSuper/contactSuper.js @@ -12,12 +12,40 @@ Page({ /** * 生命周期函数--监听页面加载 */ - onLoad(options) { - this.fetchSupervisorInfo(); + onLoad() { + const role = wx.getStorageSync('role') + if (role === 'manager') { + this.getManagerInfo(); + } else { + this.fetchSupervisorInfo(); + } }, /** * 请求后端接口,获取上级联系人信息 */ + + getManagerInfo() { + const token = wx.getStorageSync('token') + wx.request({ + url: baseUrl + '/userInfo/get/jwt', + method: 'GET', + header: { + Authorization: token + }, + success: res => { + console.log('用户信息---->',res.data); + if (res.data.code === 1) { + let result = res.data.data + this.setData({ + nickName: result.nickName, + phoneNumber: result.phoneNumber + }) + } + } + }) + }, + + fetchSupervisorInfo() { const token = wx.getStorageSync('token'); wx.request({ diff --git a/pages/personCenter/contactSuper/contactSuper.wxml b/pages/personCenter/contactSuper/contactSuper.wxml index 99131aa..9122a9e 100644 --- a/pages/personCenter/contactSuper/contactSuper.wxml +++ b/pages/personCenter/contactSuper/contactSuper.wxml @@ -14,7 +14,7 @@ diff --git a/pages/personCenter/contactSuper/contactSuper.wxss b/pages/personCenter/contactSuper/contactSuper.wxss index 2ff15af..d2c2991 100644 --- a/pages/personCenter/contactSuper/contactSuper.wxss +++ b/pages/personCenter/contactSuper/contactSuper.wxss @@ -5,7 +5,7 @@ margin-left: 39.38rpx; } .page { - padding: 43.13rpx 0 1346.25rpx; + padding: 43.13rpx 0 0; background-image: linear-gradient(180deg, #ff8d1a -7.3%, #ffffff00 33.5%); width: 100%; overflow-y: auto; diff --git a/pages/personCenter/mine/mine.js b/pages/personCenter/mine/mine.js index 59cd8b8..e627140 100644 --- a/pages/personCenter/mine/mine.js +++ b/pages/personCenter/mine/mine.js @@ -22,7 +22,11 @@ Page({ title: '查看绩效', id: 0, globalImgUrl, - showNicknamePopup: false + showNicknamePopup: false, + totalIncome: 0, + withdrawaledAmount: 0, + withdrawalingBalance: 0, + currentBalance: 0 }, // 跳转课程订单页面 courseOrder() { @@ -165,11 +169,15 @@ Page({ Authorization: token }, success: res => { + console.log('用户主要信息=====>', res.data) if (res.data.code === 1) { let result = res.data.data - console.log('====fdfs>', res) this.setData({ - qrcode: globalImgUrl + result.inviteQrCode + qrcode: globalImgUrl + result.inviteQrCode, + totalIncome: result.totalIncome, + withdrawaledAmount: result.withdrawaledAmount, + withdrawalingBalance: result.withdrawalingBalance, + currentBalance: result.currentBalance }) } else { notLogin(res.data.message) diff --git a/pages/personCenter/mine/mine.wxml b/pages/personCenter/mine/mine.wxml index 7ccfdce..74a5457 100644 --- a/pages/personCenter/mine/mine.wxml +++ b/pages/personCenter/mine/mine.wxml @@ -1,331 +1,149 @@ - - - - - - + + - - - - {{ nickName }} - 修改 - + + + + {{ nickName }} + 修改 + + - + {{ phoneNumber }} - - 邀请码:{{ invitationCode }} - + + + 邀请码:{{ invitationCode }} + + - + 二维码邀请 - - - - - {{title}} + + + + + + {{title}} + + + + 主管排名 + + + + 员工排名 + + + + + + + + 当前金额: + ¥{{ filters.toFix2(currentBalance) }} - - - 主管排名 - - - - 员工排名 + + 立即提现 - - - - - 我的订单 - - + + + + 提现中 + ¥{{ filters.toFix2(withdrawalingBalance) }} - - - - 仪表盘 - - + + 已提现 + ¥{{ filters.toFix2(withdrawaledAmount) }} - - - - 账号设置 - - + + 累计收入 + ¥{{ filters.toFix2(totalIncome) }} + + + + + + 资金明细 + + + + 提现账户 + + + + 提现记录 + + + + + + + + 我的项目 + + + + 团队管理 + + + + 设置抽佣 + + + + 联系上级 + + + + + + + + + 我的订单 + + + + + + + + 仪表盘 + + + + + + + + 账号设置 + + + + - + - - diff --git a/pages/personCenter/mine/mine.wxss b/pages/personCenter/mine/mine.wxss index 66a826d..846643f 100644 --- a/pages/personCenter/mine/mine.wxss +++ b/pages/personCenter/mine/mine.wxss @@ -1,168 +1,164 @@ -.ml-7 { - margin-left: 13.13rpx; -} -.mt-9 { - margin-top: 16.88rpx; -} -.mt-11 { - margin-top: 20.63rpx; -} -.ml-5 { - margin-left: 9.38rpx; -} +/* ===== 工具类 ===== */ +.ml-7 { margin-left: 13.13rpx; } +.mt-9 { margin-top: 16.88rpx; } +.mt-11 { margin-top: 20.63rpx; } +.mt-22{ margin-top:22rpx; } +.ml-5 { margin-left: 9.38rpx; } +.ml-6{ margin-left:12rpx; } +.ml-8{ margin-left:16rpx; } +.ml-16{ margin-left:32rpx; } +.mt-10{ margin-top:10rpx; } +.mt-15{ margin-top:15rpx; } + +/* 页面容器 */ +page { height: 100vh; } .page { - padding: 65.63rpx 28.13rpx 0; - background-image: linear-gradient(180deg, #ff8d1a -7.3%, #ffffff00 92.1%); + padding: 35.63rpx 28.13rpx 0; + background-image: linear-gradient(180deg, #ff8d1a -7.3%, #ffffff00 120.1%); width: 100%; overflow-y: auto; overflow-x: hidden; height: 100%; + padding-top: calc(35.63rpx + constant(safe-area-inset-top)); + padding-top: calc(35.63rpx + env(safe-area-inset-top)); } -.section { - padding: 15rpx 13.13rpx; - background-color: #ffffff; - border-radius: 8.33rpx; + +/* 顶部卡片 */ +.section { padding: 15rpx 13.13rpx; background-color: #ffffff; border-radius: 8.33rpx; } + +/* 头像与昵称 */ +.image { margin: 20rpx; width: 141.25rpx; height: 141.25rpx; border-radius: 50%; } +.avatar-btn{ + min-width:0!important; width:auto!important; background:transparent!important; + border:none!important; padding:0!important; margin:0!important; } -.image { - margin: 20rpx; - width: 141.25rpx; - height: 141.25rpx; - border-radius: 30rpx; +.font { font-size: 26.25rpx; font-family: SourceHanSansCN; line-height: 24.34rpx; color: #000000; } +.text { line-height: 24.21rpx; } +.nickname-wrap{ + display:block; max-width: 250rpx; white-space: normal; word-break: break-all; line-height:1.4; + display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; } -button { - /* 去掉默认最小宽度 */ - min-width: 0 !important; - /* 确保宽度随内容自适应 */ - width: auto !important; - /* 下面是其他重置,保证“隐形” */ - background: transparent !important; - border: none !important; - padding: 0 !important; - margin: 0 !important; + +/* 电话与邀请码行 */ +.group_2 { padding: 0 7.26rpx; } +.image_3 { width: 22.5rpx; height: 22.5rpx; } +.font_2 { font-size: 22.5rpx; font-family: SourceHanSansCN; line-height: 20.68rpx; color: #ff8d1a; } +.text_2 { color: #808080; line-height: 1.4; } +.section_2{ + display:inline-flex; align-items:center; max-width:100%; + padding: 7.5rpx 13.13rpx 5.63rpx 14.03rpx; background-color: #fff6de; border-radius: 31.26rpx; } -.font { - font-size: 26.25rpx; - font-family: SourceHanSansCN; - line-height: 24.34rpx; - color: #000000; +.image_4 { width: 24.38rpx; height: 24.38rpx; } +.text_3 { margin-right: 10.6rpx; white-space:nowrap; } + +.group { margin-top: 33.75rpx; width: 133.72rpx; } +.image_2 { margin-left: 17.48rpx; width: 76.88rpx; height: 76.88rpx; } +.text_4 { line-height: 20.72rpx; } + +/* 查看绩效 / 排名(等分宫格) */ +.equal-division { display:flex; gap: 12rpx; } +.section_3 { padding: 6.88rpx 0 13.59rpx; background-color: #ffffff; border-radius: 18.75rpx; } +.equal-division-item_1 { margin-left: 8.06rpx; } +.group_3 { padding: 11.76rpx 0 10.01rpx; width: 224.59rpx; } +.image_5 { width: 63.99rpx; height: 63.99rpx; } +.text_5 { line-height: 24.26rpx; } +.equal-division-item_2 { position: static; transform:none; } +.equal-division-item { padding: 11.76rpx 0 10.09rpx; width: 224.59rpx; } +.text_6 { line-height: 24.28rpx; } +.equal-division-item_3 { position: static; transform:none; } +.group_5 { padding: 11.76rpx 0 9.99rpx; width: 224.59rpx; } + +/* 列表卡片(你的原有区) */ +.list { padding-top: 19.38rpx; } +.section_4 { padding: 31.88rpx 31.88rpx 30rpx 33.75rpx; background-color: #ffffff; border-radius: 9.47rpx; min-height:88rpx; } +.image_6 { border-radius: 9.38rpx; width: 41.25rpx; height: 41.25rpx; } +.image_7 { width: 30rpx; height: 30rpx; } +.text_7 { line-height: 24.47rpx; } +.text_8 { line-height: 23.81rpx; } + +/* ===== 当前金额卡片(美化后) ===== */ +.wallet-card { + background: #fff; + border-radius: 20rpx; + padding: 28rpx 24rpx; + box-shadow: 0 6rpx 20rpx rgba(0, 0, 0, 0.06); } -.text { - line-height: 24.21rpx; + +/* 金额行 */ +.wallet-head { + display: flex; + align-items: center; + justify-content: space-between; + margin-bottom: 20rpx; } -.group_2 { - padding: 0 7.26rpx; +.wallet-head-left { display: flex; align-items: baseline; } +.wallet-head-label { font-size: 26rpx; color: #666; } +.wallet-head-amount { margin-left: 8rpx; font-size: 38rpx; color: #ff8d1a; font-weight: 700; } + +/* 立即提现按钮 */ +.wallet-head-right { + background: linear-gradient(135deg, #ffae3d, #ff8d1a); + border-radius: 999rpx; + padding: 12rpx 28rpx; + box-shadow: 0 4rpx 12rpx rgba(255, 141, 26, 0.3); + display: flex; /* 水平+垂直居中 */ + align-items: center; + justify-content: center; } -.image_3 { - width: 22.5rpx; - height: 22.5rpx; +.wallet-withdraw-text { font-size: 26rpx; color: #fff; font-weight: 600; } + +/* 三统计(轻量分隔线风格) */ +.wallet-stats { + display: flex; + justify-content: space-between; + margin-top: 12rpx; + border-top: 1rpx solid #f2f2f2; + padding-top: 20rpx; } -.font_2 { - font-size: 22.5rpx; - font-family: SourceHanSansCN; - line-height: 20.68rpx; - color: #ff8d1a; +.wallet-stat { + flex: 1 0 0; + display: flex; + flex-direction: column; + align-items: center; } -.text_2 { - color: #808080; - line-height: 1.4; +.wallet-stat:not(:last-child) { border-right: 1rpx solid #f2f2f2; } +.wallet-stat-label { font-size: 24rpx; color: #888; } +.wallet-stat-value { margin-top: 6rpx; font-size: 30rpx; color: #333; font-weight: 600; } + +/* ===== 三入口快捷区 ===== */ +.shortcut-row{ + margin-top: 18rpx; background:#fff; border-radius: 16rpx; padding: 18rpx 10rpx; + display:flex; justify-content:space-between; } -.section_2 { - width: 230rpx; +.shortcut-item{ flex:1 0 0; display:flex; flex-direction:column; align-items:center; } +.shortcut-icon{ width: 72rpx; height: 72rpx; } +.shortcut-text{ margin-top: 10rpx; font-size: 24rpx; color: #333; } + +/* ===== 接单四宫格 ===== */ +.grid-row{ + margin-top: 18rpx; background:#fff; border-radius: 16rpx; padding: 18rpx 8rpx 6rpx; + display:flex; flex-wrap:wrap; justify-content:space-between; +} +.grid-item{ width: 25%; display:flex; flex-direction:column; align-items:center; margin-bottom: 18rpx; } +.grid-icon{ width: 64rpx; height: 64rpx; border-radius: 12rpx; } +.grid-text{ margin-top: 8rpx; font-size: 24rpx; color:#333; } + +/* 自适应宽的胶囊 */ +.invite-pill{ + display: inline-flex; /* 关键:让容器只包裹内容 */ + align-items: center; + max-width: 100%; /* 不超过父容器 */ padding: 7.5rpx 13.13rpx 5.63rpx 14.03rpx; background-color: #fff6de; border-radius: 31.26rpx; + /* 可选,让它靠左不被两端对齐挤开 */ + align-self: flex-start; } -.image_4 { - width: 24.38rpx; - height: 24.38rpx; + +/* 文本超长时省略,不把胶囊撑爆 */ +.invite-text{ + max-width: 520rpx; /* 按你页面宽度调,或用 60% 等比例 */ + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; } -.text_3 { - margin-right: 21.6rpx; -} -.group { - margin-top: 33.75rpx; - width: 133.72rpx; -} -.image_2 { - margin-left: 17.48rpx; - width: 76.88rpx; - height: 76.88rpx; -} -.text_4 { - line-height: 20.72rpx; -} -.equal-division { - position: relative; -} -.section_3 { - padding: 6.88rpx 0 13.59rpx; - background-color: #ffffff; - border-radius: 18.75rpx; -} -.equal-division-item_1 { - margin-left: 8.06rpx; -} -.group_3 { - padding: 11.76rpx 0 10.01rpx; - width: 224.59rpx; -} -.image_5 { - width: 63.99rpx; - height: 63.99rpx; -} -.text_5 { - line-height: 24.26rpx; -} -.equal-division-item_2 { - position: absolute; - left: 50%; - top: 50%; - transform: translate(-50%, -50%); -} -.equal-division-item { - padding: 11.76rpx 0 10.09rpx; - width: 224.59rpx; -} -.text_6 { - line-height: 24.28rpx; -} -.equal-division-item_3 { - position: absolute; - right: 10.03rpx; - top: 50%; - transform: translateY(-50%); -} -.group_5 { - padding: 11.76rpx 0 9.99rpx; - width: 224.59rpx; -} -.list { - padding-top: 19.38rpx; -} -.section_4 { - padding: 31.88rpx 31.88rpx 30rpx 33.75rpx; - background-color: #ffffff; - border-radius: 9.47rpx; -} -.image_6 { - border-radius: 9.38rpx; - width: 41.25rpx; - height: 41.25rpx; -} -.image_7 { - width: 30rpx; - height: 30rpx; -} -.text_7 { - line-height: 24.47rpx; -} -.text_8 { - line-height: 23.81rpx; -} -.nickname-wrap { - display: block; /* 让它单独占一行 */ - max-width: 250rpx; /* 不超过容器宽度 */ - white-space: normal; /* 允许正常换行 */ - word-break: break-all; /* 长字符串也能断行 */ - line-height: 1.4; -} \ No newline at end of file diff --git a/pages/projectModule/projectDetail/projectDetail.wxml b/pages/projectModule/projectDetail/projectDetail.wxml index f069770..ea92102 100644 --- a/pages/projectModule/projectDetail/projectDetail.wxml +++ b/pages/projectModule/projectDetail/projectDetail.wxml @@ -51,7 +51,7 @@ 最新 - {{item.notificationTitle}} + {{item.notificationTitle}} diff --git a/pages/projectModule/projectDetail/projectDetail.wxss b/pages/projectModule/projectDetail/projectDetail.wxss index 8bef28b..1822611 100644 --- a/pages/projectModule/projectDetail/projectDetail.wxss +++ b/pages/projectModule/projectDetail/projectDetail.wxss @@ -169,7 +169,6 @@ .text_10 { font-size: 26.25rpx; line-height: 24.49rpx; - margin-left: -30%; } .section_4 { margin-top: 41.25rpx; @@ -435,3 +434,4 @@ .line-active { background-color: #ff8d1a !important; } + diff --git a/pages/projectModule/projectList/projectList.js b/pages/projectModule/projectList/projectList.js index 28f84a2..e6116be 100644 --- a/pages/projectModule/projectList/projectList.js +++ b/pages/projectModule/projectList/projectList.js @@ -8,10 +8,7 @@ Page({ data: { // 四张轮播图(已统一为同一 URL) banners: [ - './images/banner.png', - './images/banner.png', - './images/banner.png', - './images/banner.png' + '/static/logo.jpg' ], // 后端返回的项目列表 items: [], diff --git a/pages/projectModule/projectList/projectList.wxml b/pages/projectModule/projectList/projectList.wxml index 24bd7a1..5167b20 100644 --- a/pages/projectModule/projectList/projectList.wxml +++ b/pages/projectModule/projectList/projectList.wxml @@ -17,7 +17,7 @@ - 参与推广 diff --git a/project.private.config.json b/project.private.config.json index a38d28b..8255393 100644 --- a/project.private.config.json +++ b/project.private.config.json @@ -3,7 +3,7 @@ "projectname": "qingcheng-xiaochengxu", "setting": { "compileHotReLoad": true, - "urlCheck": true, + "urlCheck": false, "bigPackageSizeSupport": false }, "condition": {}, diff --git a/request.js b/request.js index 8ddc958..fafe15e 100644 --- a/request.js +++ b/request.js @@ -4,6 +4,6 @@ export const dev = 'http://160.202.242.36:9091'; export const test = 'http://160.202.242.36:9092'; export const localTest = 'http://localhost:9092'; export const ssl = 'https://www.chenxinzhi.top' -export const baseUrl = ssl; +export const baseUrl = test; export const globalImgUrl = baseUrl + '/file/download/' \ No newline at end of file