diff --git a/app.js b/app.js index 26d04a1..1d3c6e2 100644 --- a/app.js +++ b/app.js @@ -1,6 +1,6 @@ const { checkLogin } = require('./utils/logcheck'); App({ onLaunch() { - checkLogin(); + // checkLogin(); } }); diff --git a/app.json b/app.json index 32cd4e6..2ce557d 100644 --- a/app.json +++ b/app.json @@ -1,5 +1,12 @@ { "pages": [ + "pages/loginModule/pwdLogin/pwdLogin", + "pages/loginModule/register/register", + "pages/projectModule/applyCode/applyCode", + "pages/projectModule/userProject/userProject", + "pages/projectModule/projectDetail/projectDetail", + "pages/projectModule/projectList/projectList", + "pages/loginModule/forgetPwd/forgetPwd", "pages/jiedan/jiedan", "pages/logain/logain", "pages/logs/logs", diff --git a/app.wxss b/app.wxss index cc59e77..8bc1875 100644 --- a/app.wxss +++ b/app.wxss @@ -1,13 +1,8 @@ -/**app.wxss**/ -.container { - height: 100%; - display: flex; - flex-direction: column; - align-items: center; - justify-content: space-between; - padding: 200rpx 0; - box-sizing: border-box; -} +/************************************************************ +** 请将全局样式拷贝到项目的全局 CSS 文件或者当前页面的顶部 ** +** 否则页面将无法正常显示 ** +************************************************************/ + page { width: 100vw; height: 100vh; @@ -125,401 +120,464 @@ text { } .ml-2 { - margin-left: 3.85rpx; + margin-left: 3.75rpx; } .mt-2 { - margin-top: 3.85rpx; + margin-top: 3.75rpx; } .ml-4 { - margin-left: 7.69rpx; + margin-left: 7.5rpx; } .mt-4 { - margin-top: 7.69rpx; + margin-top: 7.5rpx; } .ml-6 { - margin-left: 11.54rpx; + margin-left: 11.25rpx; } .mt-6 { - margin-top: 11.54rpx; + margin-top: 11.25rpx; } .ml-8 { - margin-left: 15.38rpx; + margin-left: 15rpx; } .mt-8 { - margin-top: 15.38rpx; + margin-top: 15rpx; } .ml-10 { - margin-left: 19.23rpx; + margin-left: 18.75rpx; } .mt-10 { - margin-top: 19.23rpx; + margin-top: 18.75rpx; } .ml-12 { - margin-left: 23.08rpx; + margin-left: 22.5rpx; } .mt-12 { - margin-top: 23.08rpx; + margin-top: 22.5rpx; } .ml-14 { - margin-left: 26.92rpx; + margin-left: 26.25rpx; } .mt-14 { - margin-top: 26.92rpx; + margin-top: 26.25rpx; } .ml-16 { - margin-left: 30.77rpx; + margin-left: 30rpx; } .mt-16 { - margin-top: 30.77rpx; + margin-top: 30rpx; } .ml-18 { - margin-left: 34.62rpx; + margin-left: 33.75rpx; } .mt-18 { - margin-top: 34.62rpx; + margin-top: 33.75rpx; } .ml-20 { - margin-left: 38.46rpx; + margin-left: 37.5rpx; } .mt-20 { - margin-top: 38.46rpx; + margin-top: 37.5rpx; } .ml-22 { - margin-left: 42.31rpx; + margin-left: 41.25rpx; } .mt-22 { - margin-top: 42.31rpx; + margin-top: 41.25rpx; } .ml-24 { - margin-left: 46.15rpx; + margin-left: 45rpx; } .mt-24 { - margin-top: 46.15rpx; + margin-top: 45rpx; } .ml-26 { - margin-left: 50rpx; + margin-left: 48.75rpx; } .mt-26 { - margin-top: 50rpx; + margin-top: 48.75rpx; } .ml-28 { - margin-left: 53.85rpx; + margin-left: 52.5rpx; } .mt-28 { - margin-top: 53.85rpx; + margin-top: 52.5rpx; } .ml-30 { - margin-left: 57.69rpx; + margin-left: 56.25rpx; } .mt-30 { - margin-top: 57.69rpx; + margin-top: 56.25rpx; } .ml-32 { - margin-left: 61.54rpx; + margin-left: 60rpx; } .mt-32 { - margin-top: 61.54rpx; + margin-top: 60rpx; } .ml-34 { - margin-left: 65.38rpx; + margin-left: 63.75rpx; } .mt-34 { - margin-top: 65.38rpx; + margin-top: 63.75rpx; } .ml-36 { - margin-left: 69.23rpx; + margin-left: 67.5rpx; } .mt-36 { - margin-top: 69.23rpx; + margin-top: 67.5rpx; } .ml-38 { - margin-left: 73.08rpx; + margin-left: 71.25rpx; } .mt-38 { - margin-top: 73.08rpx; + margin-top: 71.25rpx; } .ml-40 { - margin-left: 76.92rpx; + margin-left: 75rpx; } .mt-40 { - margin-top: 76.92rpx; + margin-top: 75rpx; } .ml-42 { - margin-left: 80.77rpx; + margin-left: 78.75rpx; } .mt-42 { - margin-top: 80.77rpx; + margin-top: 78.75rpx; } .ml-44 { - margin-left: 84.62rpx; + margin-left: 82.5rpx; } .mt-44 { - margin-top: 84.62rpx; + margin-top: 82.5rpx; } .ml-46 { - margin-left: 88.46rpx; + margin-left: 86.25rpx; } .mt-46 { - margin-top: 88.46rpx; + margin-top: 86.25rpx; } .ml-48 { - margin-left: 92.31rpx; + margin-left: 90rpx; } .mt-48 { - margin-top: 92.31rpx; + margin-top: 90rpx; } .ml-50 { - margin-left: 96.15rpx; + margin-left: 93.75rpx; } .mt-50 { - margin-top: 96.15rpx; + margin-top: 93.75rpx; } .ml-52 { - margin-left: 100rpx; + margin-left: 97.5rpx; } .mt-52 { - margin-top: 100rpx; + margin-top: 97.5rpx; } .ml-54 { - margin-left: 103.85rpx; + margin-left: 101.25rpx; } .mt-54 { - margin-top: 103.85rpx; + margin-top: 101.25rpx; } .ml-56 { - margin-left: 107.69rpx; + margin-left: 105rpx; } .mt-56 { - margin-top: 107.69rpx; + margin-top: 105rpx; } .ml-58 { - margin-left: 111.54rpx; + margin-left: 108.75rpx; } .mt-58 { - margin-top: 111.54rpx; + margin-top: 108.75rpx; } .ml-60 { - margin-left: 115.38rpx; + margin-left: 112.5rpx; } .mt-60 { - margin-top: 115.38rpx; + margin-top: 112.5rpx; } .ml-62 { - margin-left: 119.23rpx; + margin-left: 116.25rpx; } .mt-62 { - margin-top: 119.23rpx; + margin-top: 116.25rpx; } .ml-64 { - margin-left: 123.08rpx; + margin-left: 120rpx; } .mt-64 { - margin-top: 123.08rpx; + margin-top: 120rpx; } .ml-66 { - margin-left: 126.92rpx; + margin-left: 123.75rpx; } .mt-66 { - margin-top: 126.92rpx; + margin-top: 123.75rpx; } .ml-68 { - margin-left: 130.77rpx; + margin-left: 127.5rpx; } .mt-68 { - margin-top: 130.77rpx; + margin-top: 127.5rpx; } .ml-70 { - margin-left: 134.62rpx; + margin-left: 131.25rpx; } .mt-70 { - margin-top: 134.62rpx; + margin-top: 131.25rpx; } .ml-72 { - margin-left: 138.46rpx; + margin-left: 135rpx; } .mt-72 { - margin-top: 138.46rpx; + margin-top: 135rpx; } .ml-74 { - margin-left: 142.31rpx; + margin-left: 138.75rpx; } .mt-74 { - margin-top: 142.31rpx; + margin-top: 138.75rpx; } .ml-76 { - margin-left: 146.15rpx; + margin-left: 142.5rpx; } .mt-76 { - margin-top: 146.15rpx; + margin-top: 142.5rpx; } .ml-78 { - margin-left: 150rpx; + margin-left: 146.25rpx; } .mt-78 { - margin-top: 150rpx; + margin-top: 146.25rpx; } .ml-80 { - margin-left: 153.85rpx; + margin-left: 150rpx; } .mt-80 { - margin-top: 153.85rpx; + margin-top: 150rpx; } .ml-82 { - margin-left: 157.69rpx; + margin-left: 153.75rpx; } .mt-82 { - margin-top: 157.69rpx; + margin-top: 153.75rpx; } .ml-84 { - margin-left: 161.54rpx; + margin-left: 157.5rpx; } .mt-84 { - margin-top: 161.54rpx; + margin-top: 157.5rpx; } .ml-86 { - margin-left: 165.38rpx; + margin-left: 161.25rpx; } .mt-86 { - margin-top: 165.38rpx; + margin-top: 161.25rpx; } .ml-88 { - margin-left: 169.23rpx; + margin-left: 165rpx; } .mt-88 { - margin-top: 169.23rpx; + margin-top: 165rpx; } .ml-90 { - margin-left: 173.08rpx; + margin-left: 168.75rpx; } .mt-90 { - margin-top: 173.08rpx; + margin-top: 168.75rpx; } .ml-92 { - margin-left: 176.92rpx; + margin-left: 172.5rpx; } .mt-92 { - margin-top: 176.92rpx; + margin-top: 172.5rpx; } .ml-94 { - margin-left: 180.77rpx; + margin-left: 176.25rpx; } .mt-94 { - margin-top: 180.77rpx; + margin-top: 176.25rpx; } .ml-96 { - margin-left: 184.62rpx; + margin-left: 180rpx; } .mt-96 { - margin-top: 184.62rpx; + margin-top: 180rpx; } .ml-98 { - margin-left: 188.46rpx; + margin-left: 183.75rpx; } .mt-98 { - margin-top: 188.46rpx; + margin-top: 183.75rpx; } .ml-100 { - margin-left: 192.31rpx; + margin-left: 187.5rpx; } .mt-100 { - margin-top: 192.31rpx; + margin-top: 187.5rpx; +} + +/** 清理默认样式 **/ + +wx-scroll-view, +wx-swiper, +wx-icon, +wx-progress, +wx-rich-text, +wx-button, +wx-checkbox, +wx-checkbox-group, +wx-form, +wx-input, +wx-label, +wx-picker, +wx-radio, +wx-radio-group, +wx-slider, +wx-switch, +wx-textarea { + box-sizing: border-box; + flex-shrink: 0; +} + +wx-button { + padding: unset; + border-radius: unset; + background-color: unset; +} + +wx-button::after { + border: unset; +} + +wx-input { + height: unset; +} + +wx-checkbox .wx-checkbox-wrapper, +wx-radio .wx-radio-wrapper { + vertical-align: top; +} + +wx-checkbox .wx-checkbox-input, +wx-radio .wx-radio-input, +wx-switch .wx-switch-input, +wx-switch .wx-checkbox-input { + margin-right: unset; +} + +wx-switch .wx-switch-input::after { + border-radius: 50%; +} + +.cf_sidebar_wrapper { + display: flex; + flex-direction: row; + height: 100%; +} + +.cf_sidebar_content_wrapper { + flex: 1; } \ No newline at end of file diff --git a/pages/logain/logain.wxml b/pages/logain/logain.wxml index 14fcf33..95ea1da 100644 --- a/pages/logain/logain.wxml +++ b/pages/logain/logain.wxml @@ -6,7 +6,7 @@ 密码登录 + style="color: {{currentTab == 'password' ? '#ff8d1a' : '#383838'}}; font-weight: {{currentTab == 'password' ? 'bold' : 'normal'}};">密码登录 验证码登录 @@ -21,10 +21,12 @@ - + - + 忘记密码 diff --git a/pages/loginModule/forgetPwd/forgetPwd.js b/pages/loginModule/forgetPwd/forgetPwd.js new file mode 100644 index 0000000..e3d1ec3 --- /dev/null +++ b/pages/loginModule/forgetPwd/forgetPwd.js @@ -0,0 +1,142 @@ +// pages/loginModule/forgetPwd/forgetPwd.js +const { baseUrl } = require('../../../request'); +const { validate } = require('../../../utils/validate'); + +Page({ + data: { + phone: '', + code: '', + newPwd: '', + confirmPwd: '', + countdown: 0, + codeButtonText: '发送验证码', + _timer: null + }, + + // 手机号输入 + onPhoneInput(e) { + this.setData({ phone: e.detail.value }); + }, + // 验证码输入 + onCodeInput(e) { + this.setData({ code: e.detail.value }); + }, + // 新密码输入 + onNewPwdInput(e) { + this.setData({ newPwd: e.detail.value }); + }, + // 确认密码输入 + onConfirmPwdInput(e) { + this.setData({ confirmPwd: e.detail.value }); + }, + + // 发送验证码 + getSmsCode() { + const { phone } = this.data; + // 1. 非空 + if (!validate(this.data, { phone: '请输入手机号' })) return; + // 2. 格式 + if (!/^1\d{10}$/.test(phone)) { + return wx.showToast({ title: '手机号格式不正确', icon: 'none' }); + } + // 3. 请求验证码 + wx.request({ + url: baseUrl + '/userInfo/code', + method: 'POST', + data: { templateString: phone }, + success: () => { + wx.showToast({ title: '验证码已发送', icon: 'none' }); + this._startCountdown(60); + }, + fail: () => { + wx.showToast({ title: '发送失败,请重试', icon: 'none' }); + } + }); + }, + + // 开始倒计时 + _startCountdown(seconds) { + this.setData({ + countdown: seconds, + codeButtonText: `${seconds}s后重试` + }); + if (this.data._timer) return; // 已在倒计时中 + this.data._timer = setInterval(() => { + let cd = this.data.countdown - 1; + if (cd <= 0) { + this._clearTimer(); + this.setData({ + countdown: 0, + codeButtonText: '发送验证码' + }); + } else { + this.setData({ + countdown: cd, + codeButtonText: `${cd}s后重试` + }); + } + }, 1000); + }, + + // 清除定时器 + _clearTimer() { + if (this.data._timer) { + clearInterval(this.data._timer); + this.data._timer = null; + } + }, + + // 重置密码 + resetPassword() { + const { phone, code, newPwd, confirmPwd } = this.data; + // 1. 非空校验 + if (!validate(this.data, { + phone: '请输入手机号', + code: '请输入验证码', + newPwd: '请输入新密码', + confirmPwd: '请再次输入新密码' + })) return; + // 2. 密码一致 + if (newPwd !== confirmPwd) { + return wx.showToast({ title: '两次密码不一致', icon: 'none' }); + } + // 3. 格式校验手机号 + if (!/^1\d{10}$/.test(phone)) { + return wx.showToast({ title: '手机号格式不正确', icon: 'none' }); + } + // 4. 发起重置请求 + wx.request({ + url: baseUrl + '/userInfo/mini/forgetPwd', + method: 'POST', + data: { + phoneNumber: phone, + verificationCode: code, + newPassword: newPwd + }, + success: res => { + if (res.data.code === 1) { + wx.showToast({ title: '重置成功', icon: 'success' }); + // 清理并跳登录 + this._clearTimer(); + setTimeout(() => { + wx.navigateTo({ url: '/pages/login/login' }); + }, 800); + } else { + wx.showToast({ title: res.data.message||'重置失败', icon: 'none' }); + } + }, + fail: () => { + wx.showToast({ title: '网络错误,请重试', icon: 'none' }); + } + }); + }, + + // 点击“登录账号”回登录页 + gotoLogin() { + wx.navigateTo({ url: '/pages/loginModule/pwdLogin/pwdLogin' }); + }, + + onUnload() { + this._clearTimer(); + } +}); diff --git a/pages/loginModule/forgetPwd/forgetPwd.json b/pages/loginModule/forgetPwd/forgetPwd.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/loginModule/forgetPwd/forgetPwd.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/loginModule/forgetPwd/forgetPwd.wxml b/pages/loginModule/forgetPwd/forgetPwd.wxml new file mode 100644 index 0000000..b5b912d --- /dev/null +++ b/pages/loginModule/forgetPwd/forgetPwd.wxml @@ -0,0 +1,75 @@ + + + 欢迎登陆—青橙校园 + + + 忘记密码 + + + + + + + + + + + {{ codeButtonText }} + + + + + + + + + + + + + + 登录账号 + + + + 重置密码 + + + + diff --git a/pages/loginModule/forgetPwd/forgetPwd.wxss b/pages/loginModule/forgetPwd/forgetPwd.wxss new file mode 100644 index 0000000..48c97ec --- /dev/null +++ b/pages/loginModule/forgetPwd/forgetPwd.wxss @@ -0,0 +1,131 @@ +.page { + padding: 86.25rpx 46.2rpx 326.25rpx 49.89rpx; + background-color: #ffffff; + width: 100%; + overflow: hidden; + height: 100%; +} +.image { + width: 232.5rpx; + height: 232.5rpx; +} +.text { + margin-top: 37.8rpx; + color: #1c2023; + font-size: 37.5rpx; + font-family: SourceHanSansCN; + line-height: 35.18rpx; +} +.group { + margin-top: 86.14rpx; +} +.font { + font-size: 30rpx; + font-family: SourceHanSansCN; + line-height: 27.79rpx; + color: #b3b3b3; +} +.text_2 { + color: #1c2023; + line-height: 28.09rpx; +} +.section { + margin-left: 2.61rpx; + margin-right: 4.42rpx; + padding: 20.63rpx 0 18.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 11.25rpx #00000040; +} +.text-wrapper { + margin-left: 16.88rpx; + margin-right: 16.88rpx; +} +.view { + padding: 15.92rpx 0 12.64rpx; + background-color: #ffffff00; +} +.group_2 { + padding-left: 2.61rpx; +} +.section_2 { + margin-right: 4.42rpx; + padding: 20.16rpx 16.88rpx 19.22rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_2 { + flex: 1 1 0; +} +.view_2 { + padding: 12.51rpx 0 15.96rpx; + background-color: #ffffff00; + height: 66.25rpx; +} +.text-wrapper_3 { + margin-right: 18.77rpx; + padding: 13.16rpx 0 10.93rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; + width: 157.5rpx; + height: 45rpx; +} +.text_6 { + color: #ffffff; + font-size: 22.5rpx; + font-family: AlibabaPuHuiTi; + line-height: 20.91rpx; +} +.section_1 { + margin-right: 4.42rpx; + padding: 21.56rpx 0 17.81rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_1 { + padding: 13.84rpx 0 14.55rpx; + background-color: #ffffff00; +} +.section_3 { + margin-right: 4.42rpx; + padding: 19.22rpx 0 20.16rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_5 { + padding: 13.37rpx 0 14.87rpx; + background-color: #ffffff00; +} +.text_9 { + color: #1c2023; + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 24.23rpx; +} +.text-wrapper_4 { + margin-right: 4.42rpx; + padding: 36.04rpx 0 34.01rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; +} +.text_10 { + color: #ffffff; + font-size: 30rpx; + font-family: AlibabaPuHuiTi; + line-height: 27.45rpx; +} +.input { + padding: 15rpx 16.26rpx 13.13rpx 16.26rpx; +} +.input_1 { + padding: 13.13rpx 16.26rpx 16.88rpx 16.26rpx; +} +.input_2 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.input_3 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} \ No newline at end of file diff --git a/pages/loginModule/pwdLogin/pwdLogin.js b/pages/loginModule/pwdLogin/pwdLogin.js new file mode 100644 index 0000000..5b15fe0 --- /dev/null +++ b/pages/loginModule/pwdLogin/pwdLogin.js @@ -0,0 +1,181 @@ +// pages/login/login.js +const { baseUrl } = require('../../../request'); +const { validate } = require('../../../utils/validate'); + +Page({ + data: { + loginType: 'password', // 'password' 或 'sms' + phone: '', + credential: '', + isAgree: false, // 用户协议是否勾选 + countdown: 0, // 剩余秒数 + codeButtonText: '获取验证码', + _timer: null + }, + + // 切换到“密码登录”,只清空表单字段 + switchToPassword() { + this.setData({ + loginType: 'password', + phone: '', + credential: '' + // 不清除 countdown、codeButtonText、_timer + }); + }, + + // 切换到“验证码登录”,只清空表单字段 + switchToSms() { + this.setData({ + loginType: 'sms', + phone: '', + credential: '' + // 不清除 countdown、codeButtonText、_timer + }); + }, + + // 手机号输入 + onPhoneInput(e) { + this.setData({ phone: e.detail.value }); + }, + + // 密码/验证码输入 + onCredentialInput(e) { + this.setData({ credential: e.detail.value }); + }, + + // 协议勾选 + onAgreeChange(e) { + this.setData({ isAgree: e.detail.value.includes('agree') }); + }, + + // 获取验证码(仅校验手机号) + getSmsCode() { + const { phone } = this.data; + + // 1. 非空校验 + if (!validate(this.data, { phone: '请输入手机号' })) { + return; + } + // 2. 格式校验 + if (!/^1\d{10}$/.test(phone)) { + return wx.showToast({ title: '手机号格式不正确', icon: 'none' }); + } + + // 3. 发送验证码请求 + wx.request({ + url: baseUrl + '/userInfo/code', + method: 'POST', + data: { templateString: phone }, + success: () => { + wx.showToast({ title: '验证码已发送', icon: 'none' }); + this._startCountdown(60); + }, + fail: () => { + wx.showToast({ title: '发送失败,请重试', icon: 'none' }); + } + }); + }, + + // 开始倒计时 + _startCountdown(seconds) { + this.setData({ + countdown: seconds, + codeButtonText: `${seconds}s后重试` + }); + // 如果已有定时器,不重复创建 + if (this.data._timer) return; + this.data._timer = setInterval(() => { + const cd = this.data.countdown - 1; + if (cd <= 0) { + this._clearTimer(); + this.setData({ + countdown: 0, + codeButtonText: '获取验证码' + }); + } else { + this.setData({ + countdown: cd, + codeButtonText: `${cd}s后重试` + }); + } + }, 1000); + }, + + // 清除倒计时定时器 + _clearTimer() { + if (this.data._timer) { + clearInterval(this.data._timer); + this.data._timer = null; + } + }, + + // 登录 + onLogin() { + const { loginType, phone, credential, isAgree } = this.data; + + // 非空校验(手机号、密码/验证码、协议) + if (!validate(this.data, { + phone: '请输入手机号', + credential: loginType === 'password' ? '请输入密码' : '请输入验证码', + isAgree: '请先同意用户协议' + })) { + return; + } + // 手机号格式校验 + if (!/^1\d{10}$/.test(phone)) { + return wx.showToast({ title: '手机号格式不正确', icon: 'none' }); + } + + // 组装请求 + const url = loginType === 'password' + ? baseUrl + '/userInfo/mini/pwd/login' + : baseUrl + '/userInfo/mini/vcd/login'; + const payload = loginType === 'password' + ? { phoneNumber: phone, userPassword: credential } + : { phoneNumber: phone, verificationCode: credential }; + + wx.request({ + url, + method: 'POST', + data: payload, + success: res => { + if (res.data.code === 1) { + // ← 新增:从返回数据中取出 token + const token = res.data.data.token || res.data.data; + // ← 新增:将 token 存到本地缓存 + wx.setStorageSync('token', token); + + wx.showToast({ title: '登录成功', icon: 'success' }); + wx.navigateTo({ + url: '/pages/projectModule/projectList/projectList' + }); + } else { + wx.showToast({ + title: res.data.message || '登录失败', + icon: 'none' + }); + } + }, + fail: () => { + wx.showToast({ title: '网络错误,请重试', icon: 'none' }); + } + }); + }, + + gotoForgetPwd() { + wx.navigateTo({ + url: '/pages/loginModule/forgetPwd/forgetPwd', + }) + }, + + gotoRegister() { + wx.navigateTo({ + url: '/pages/loginModule/register/register', + }) + }, + + // 页面卸载时清理定时器 + onUnload() { + this._clearTimer(); + } +}); diff --git a/pages/loginModule/pwdLogin/pwdLogin.json b/pages/loginModule/pwdLogin/pwdLogin.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/loginModule/pwdLogin/pwdLogin.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/loginModule/pwdLogin/pwdLogin.wxml b/pages/loginModule/pwdLogin/pwdLogin.wxml new file mode 100644 index 0000000..31687e5 --- /dev/null +++ b/pages/loginModule/pwdLogin/pwdLogin.wxml @@ -0,0 +1,87 @@ + + + 欢迎登陆—青橙校园 + + + + + 密码登录 + 验证码登录 + + + + + + + + + + + + + + {{ codeButtonText }} + + + + 忘记密码 + + + + + + + + + + + 登录代表您已同意 + 《用户协议》 + & + 《隐私协议》 + + + + + 没有账号? + 去注册→ + + + + diff --git a/pages/loginModule/pwdLogin/pwdLogin.wxss b/pages/loginModule/pwdLogin/pwdLogin.wxss new file mode 100644 index 0000000..782ca79 --- /dev/null +++ b/pages/loginModule/pwdLogin/pwdLogin.wxss @@ -0,0 +1,163 @@ +/* 切换按钮样式 */ +.switch { + font-size: 30rpx; /* 基础字体大小 */ + font-family: SourceHanSansCN; +} +.switch.active { + font-size: 36rpx; /* 激活时更大 */ + font-weight: bold; /* 加粗 */ + color: #1c2023; +} +.switch.inactive { + color: #888888; /* 不活跃时灰色 */ +} + +/* 其它原来样式保持不变 */ +.mt-21 { + margin-top: 39.38rpx; +} +.page { + padding: 105rpx 45.69rpx 381.68rpx 49.76rpx; + background-color: #ffffff; + width: 100%; + overflow: hidden; + height: 100%; +} +.image { + width: 232.5rpx; + height: 232.5rpx; +} +.text { + margin-top: 35.14rpx; + color: #1c2023; + font-size: 37.5rpx; + font-family: AlibabaPuHuiTi; + line-height: 35.21rpx; +} +.group { + margin-top: 145.01rpx; +} +.font { + font-size: 30rpx; + font-family: SourceHanSansCN; + line-height: 27.69rpx; + color: #1c2023; +} +.text_2 { + line-height: 28.29rpx; +} +.text_3 { + line-height: 28.2rpx; +} +.group_1 { + padding-left: 2.74rpx; +} +.section { + margin-right: 4.93rpx; + padding: 20.63rpx 0 18.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 11.25rpx #00000040; +} +.text-wrapper { + margin-left: 16.88rpx; + margin-right: 16.88rpx; +} +.view { + padding: 15.92rpx 0 12.64rpx; + background-color: #ffffff00; +} +.section_2 { + margin-right: 4.93rpx; + padding: 20.63rpx 16.88rpx 18.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_2 { + flex: 1 1 0; +} +.view_2 { + padding: 11.96rpx 0 16.43rpx; + background-color: #ffffff00; + height: 76.25rpx; +} +.text_6 { + margin-right: 14.72rpx; + color: #f7810a; + font-size: 26.25rpx; + font-family: AlibabaPuHuiTi; + line-height: 23.94rpx; +} +.get-code { + /* 可根据需求再调样式 */ +} +.font_3 { + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 24.49rpx; + color: #383838; +} +.text_7 { + margin-top: 28.76rpx; + line-height: 24.36rpx; +} +.text-wrapper_3 { + margin-right: 4.93rpx; + margin-top: 46.26rpx; + padding: 36.73rpx 0 34.16rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; +} +.text_8 { + color: #ffffff; + font-size: 30rpx; + font-family: AlibabaPuHuiTi; + line-height: 26.61rpx; +} +.group_2 { + margin-top: 48.75rpx; +} +.group_3 { + line-height: 24.49rpx; + height: 24.56rpx; +} +.font_4 { + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 24.49rpx; + color: #ff5e00; +} +.text_9 { + color: #1c2023; + line-height: 24.43rpx; +} +.text_10 { + color: #1c2023; + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 19.93rpx; +} +.group_4 { + margin-top: 43.91rpx; + line-height: 24.41rpx; +} +.text_11 { + line-height: 24.28rpx; +} +.text_12 { + line-height: 24.41rpx; +} +.input { + padding: 15rpx 16.26rpx 13.13rpx 16.26rpx; +} +.input_1 { + padding: 15rpx 16.26rpx 13.13rpx 16.26rpx; +} +.checkbox { + flex-shrink: 0; +} +.checkbox .wx-checkbox-input { + width: 37.5rpx; + height: 37.5rpx; +} \ No newline at end of file diff --git a/pages/loginModule/register/register.js b/pages/loginModule/register/register.js new file mode 100644 index 0000000..ab53ba5 --- /dev/null +++ b/pages/loginModule/register/register.js @@ -0,0 +1,194 @@ +import { url } from "../../../request"; +import { requestAsync } from "../../../utils/request"; +import { validate } from "../../../utils/validate"; + +// pages/loginModule/register/register.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + nickname: 'cxz', + phone: '13888610253', + captcha: '111111', + inviteCode: '123456', + password: '123456', + agree: false, + sending: false, + count: 60, + }, + + sendSmsCode() { + const { phone } = this.data; + if (!/^1\d{10}$/.test(phone)) { + wx.showToast({ title: '请输入有效的手机号', icon: 'none' }); + return; + } + wx.request({ + url: url + '/userInfo/code', + method: 'POST', + header: { 'content-type': 'application/json' }, + data: { + templateString: phone + }, + success: res => { + // 假设后端返回 { success: true, ... } + if (res.data.code === 1) { + wx.showToast({ title: '验证码已发送' }); + this.startCountdown(); + } else { + wx.showToast({ + title: res.data.message || '发送失败', + icon: 'none' + }); + } + } + }); + }, + + startCountdown() { + this.setData({ sending: true, count: 60 }); + const timer = setInterval(() => { + let { count } = this.data; + if (count <= 1) { + clearInterval(timer); + this.setData({ sending: false }); + } else { + this.setData({ count: count - 1 }); + } + }, 1000); + }, + + // 通用输入事件处理函数 + onInput(e) { + const field = e.currentTarget.dataset.field; // 获取字段名 + const value = e.detail.value; // 获取输入内容 + this.setData({ + [field]: value // 动态更新对应字段 + }); + }, + + // 复选框事件处理(如果使用 checkbox-group 推荐用 change) + onCheckboxChange(e) { + this.setData({ + agree: e.detail.value.length > 0 + }); + }, + + // 注册按钮点击 + async onRegister() { + if (!this.data.agree) { + wx.showToast({ + title: '请先勾选同意协议', + icon: 'none' + }); + return; + } + // 调用通用校验,失败时已提示并 return + if (!validate(this.data, { + agree: '请先勾选同意协议', + nickname: '请输入昵称', + phone: '请输入手机号', + captcha: '请输入验证码', + inviteCode: '请输入邀请码', + password: '请输入密码' + })) { + return; + } + const { nickname, phone, captcha, inviteCode, password } = this.data; + const res = await requestAsync({ + url: url + '/userInfo/register', + method: 'POST', + header: { 'content-type': 'application/json' }, + data: { + nickName: nickname, + phoneNumber: phone, + verificationCode: captcha, + invitationCode: inviteCode, + userPassword: password + } + }); + if (res.data.code === 1) { + wx.showToast({ + title: '注册成功', + icon: 'success', + duration: 1000 + }); + setTimeout(() => { + wx.navigateTo({ + url: '/pages/loginModule/pwdLogin/pwdLogin', + success: () => { + this.setData({ nickname:'', phone:'', captcha:'', inviteCode:'', password:'', agree:false }); + } + }); + }, 1000); + } else { + wx.showToast({ + title: res.data.message || '注册失败', + icon: 'none' + }); + } + }, + + gotoLogin() { + wx.navigateTo({ + url: '/pages/loginModule/pwdLogin/pwdLogin', + }) + }, + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/pages/loginModule/register/register.json b/pages/loginModule/register/register.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/loginModule/register/register.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/loginModule/register/register.wxml b/pages/loginModule/register/register.wxml new file mode 100644 index 0000000..fa8b33e --- /dev/null +++ b/pages/loginModule/register/register.wxml @@ -0,0 +1,74 @@ + + + 欢迎登陆—青橙校园 + + + 账号注册 + + + + + + + + + + + + + {{ sending ? count + 's后重发' : '发送验证码' }} + + + + + + + + + + + + + + + + + + + 我已阅读并同意 + 《用户协议》 + & + 《隐私协议》 + + + 注册 + + + 已有账号? + 立即登录→ + + \ No newline at end of file diff --git a/pages/loginModule/register/register.wxss b/pages/loginModule/register/register.wxss new file mode 100644 index 0000000..258645e --- /dev/null +++ b/pages/loginModule/register/register.wxss @@ -0,0 +1,172 @@ +.ml-13 { + margin-left: 24.38rpx; +} +.page { + padding: 0rpx 49.74rpx 79.82rpx 49.74rpx; + background-color: #ffffff; + width: 100%; + overflow: hidden; + height: 100%; +} +.register { + margin-top: -30rpx; +} +.image { + width: 232.5rpx; + height: 232.5rpx; +} +.text { + margin-top: 37.8rpx; + color: #1c2023; + font-size: 37.5rpx; + font-family: SourceHanSansCN; + line-height: 35.18rpx; +} +.group { + margin-top: 86.36rpx; +} +.font { + font-size: 30rpx; + font-family: SourceHanSansCN; + line-height: 27.79rpx; + color: #b3b3b3; +} +.text_2 { + color: #1c2023; + line-height: 28.2rpx; +} +.group_6 { + padding-left: 2.76rpx; +} +.section { + padding: 20.63rpx 0 18.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 11.25rpx #00000040; +} +.text-wrapper_5 { + margin-left: 16.88rpx; + margin-right: 16.88rpx; +} +.view { + padding: 15.92rpx 0 12.62rpx; + background-color: #ffffff00; +} +.section_1 { + padding: 20.16rpx 0 19.22rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_1 { + padding: 12.64rpx 0 15.92rpx; + background-color: #ffffff00; +} +.section_3 { + padding: 25.63rpx 16.88rpx 28.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.text-wrapper_2 { + flex: 1 1 0; +} +.view_6 { + padding: 16.73rpx 0 11.74rpx; + background-color: #ffffff00; + height: 66.25rpx; +} +.text-wrapper_3 { + margin-right: 15rpx; + padding: 13.16rpx 0 10.93rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; + width: 157.5rpx; + height: 45rpx; +} +.text_7 { + color: #ffffff; + font-size: 22.5rpx; + font-family: AlibabaPuHuiTi; + line-height: 20.91rpx; +} +.section_2 { + padding: 20.63rpx 0 18.75rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + box-shadow: 0rpx 3.75rpx 7.5rpx #00000040; +} +.view_1 { + padding: 11.7rpx 0 16.89rpx; + background-color: #ffffff00; +} +.view_3 { + padding: 11.96rpx 0 16.29rpx; + background-color: #ffffff00; +} +.group_1 { + padding: 0 2.76rpx; +} +.group_2 { + line-height: 24.56rpx; + height: 24.56rpx; +} +.font_2 { + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 24.49rpx; + color: #ff5e00; +} +.text_10 { + color: #1c2023; + line-height: 24.56rpx; +} +.text_11 { + color: #1c2023; + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 19.93rpx; +} +.text-wrapper_6 { + margin-left: 2.76rpx; + padding: 37.63rpx 0 32.27rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; +} +.text_12 { + color: #ffffff; + line-height: 27.6rpx; +} +.group_3 { + margin-top: 37rpx; + line-height: 24.36rpx; +} +.text_13 { + color: #383838; + line-height: 24.28rpx; +} +.text_14 { + line-height: 24.36rpx; +} +.input { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.input_1 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.input_2 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.input_3 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.input_4 { + padding: 13.13rpx 16.26rpx 15rpx 16.26rpx; +} +.checkbox { + flex-shrink: 0; +} +.checkbox .wx-checkbox-input { + width: 37.5rpx; + height: 37.5rpx; +} \ No newline at end of file diff --git a/pages/projectModule/applyCode/applyCode.js b/pages/projectModule/applyCode/applyCode.js new file mode 100644 index 0000000..4fcfdcd --- /dev/null +++ b/pages/projectModule/applyCode/applyCode.js @@ -0,0 +1,65 @@ +// pages/projectModule/applyCode/applyCode.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + + }, + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/pages/projectModule/applyCode/applyCode.json b/pages/projectModule/applyCode/applyCode.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/projectModule/applyCode/applyCode.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/projectModule/applyCode/applyCode.wxml b/pages/projectModule/applyCode/applyCode.wxml new file mode 100644 index 0000000..66c580a --- /dev/null +++ b/pages/projectModule/applyCode/applyCode.wxml @@ -0,0 +1,18 @@ + + + + 业务员姓名 + + + 业务员手机号 + + + + + + 申请资料报备 + + + + + \ No newline at end of file diff --git a/pages/projectModule/applyCode/applyCode.wxss b/pages/projectModule/applyCode/applyCode.wxss new file mode 100644 index 0000000..744b14d --- /dev/null +++ b/pages/projectModule/applyCode/applyCode.wxss @@ -0,0 +1,78 @@ +.mt-27 { + margin-top: 50.63rpx; +} +.page { + background-color: #f5f5f5; + width: 100%; + position: fixed; + bottom: 0; + overflow: auto; + height: calc(100vh - 1rpx); +} +.section { + padding: 121.88rpx 33.75rpx 0 35.63rpx; + background-image: linear-gradient(180deg, #ff8d1a -20.4%, #ff8d1a00 29.6%); +} +.section_2 { + margin-left: 5.63rpx; + margin-right: 7.5rpx; + padding: 35.46rpx 18.75rpx 22.5rpx 24.38rpx; + background-color: #ffffff; + border-radius: 18.75rpx; +} +.font { + font-size: 30rpx; + font-family: Times New Roman; + line-height: 27.75rpx; + color: #000000; +} +.text { + line-height: 27.81rpx; +} +.view { + align-self: stretch; + margin-top: 13.61rpx; +} +.text-wrapper { + padding: 12.96rpx 0 15.64rpx; + background-color: #ffffff00; +} +.divider { + margin-top: 11.25rpx; + background-color: #d9d9d9; + height: 1.88rpx; +} +.text_3 { + margin-top: 37.39rpx; +} +.group { + padding: 80.63rpx 0 63.75rpx; +} +.text-wrapper_2 { + margin-left: 5.63rpx; + margin-right: 7.5rpx; + padding: 27.96rpx 0 28.67rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; +} +.text_4 { + color: #ffffff; +} +.section_3 { + padding: 70.76rpx 0 65.66rpx; + background-color: #ffffff; + border-radius: 56.25rpx; +} +.section_4 { + margin-left: 42.19rpx; + margin-right: 44.06rpx; + background-color: #ffffff00; + height: 808.58rpx; + border: solid 1.88rpx #000000; +} +.input { + padding: 13.13rpx 18.75rpx 15rpx 18.75rpx; +} +.input_1 { + padding: 13.13rpx 18.75rpx 15rpx 18.75rpx; +} \ No newline at end of file diff --git a/pages/projectModule/projectDetail/projectDetail.js b/pages/projectModule/projectDetail/projectDetail.js new file mode 100644 index 0000000..fe5fba4 --- /dev/null +++ b/pages/projectModule/projectDetail/projectDetail.js @@ -0,0 +1,68 @@ +// pages/projectModule/projectDetail/projectDetail.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + items: [null, null, null], + items_1: [null, null, null], + items_2: [null, null, null], + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/pages/projectModule/projectDetail/projectDetail.json b/pages/projectModule/projectDetail/projectDetail.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/projectModule/projectDetail/projectDetail.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/projectModule/projectDetail/projectDetail.wxml b/pages/projectModule/projectDetail/projectDetail.wxml new file mode 100644 index 0000000..84f3900 --- /dev/null +++ b/pages/projectModule/projectDetail/projectDetail.wxml @@ -0,0 +1,159 @@ + + + + + + 美团省钱包 + + 不限制推广方式、不限美团新老用户,要求美团闪购新用户或... + + + 结算明细 + + + + 最高价 + ¥7 + + + + + + + 项目详情 + 我的推广码 + + + + + + + + + + + 项目通知 + + + + + 最新 + + 美团省钱包-春季活动价格上调通知~ + + + + + + + 项目政策 + + + + 结算标准 + 结算价 + + + + 3.6元购买30元券包 + 0.30 + + + + + + + 结算说明 + + + + + 项目说明 + + + + + 项目说明 + + + + + + + + 审核通过 + + + + + 业务员:陈新知 15888610253 + 绑定日期:2025-05-16 19:09 + + 推广码id:ykhlshy118 + 复制 + + + + + 查看推广码 + + + 结算明细 + + + 查看资料 + + + + + + + + + + 开码记录 + 新增推广码 + + \ No newline at end of file diff --git a/pages/projectModule/projectDetail/projectDetail.wxss b/pages/projectModule/projectDetail/projectDetail.wxss new file mode 100644 index 0000000..af6e4ff --- /dev/null +++ b/pages/projectModule/projectDetail/projectDetail.wxss @@ -0,0 +1,412 @@ +.ml-13 { + margin-left: 24.38rpx; +} +.mt-7 { + margin-top: 13.13rpx; +} +.mt-35 { + margin-top: 65.63rpx; +} +.mt-13 { + margin-top: 24.38rpx; +} +.mt-15 { + margin-top: 28.13rpx; +} +.mt-21 { + margin-top: 39.38rpx; +} +.ml-5 { + margin-left: 9.38rpx; +} +.mt-57 { + margin-top: 106.88rpx; +} +.page { + padding: 74.92rpx 0 213.75rpx; + background-color: #ffffff; + width: 100%; + overflow-y: auto; + overflow-x: hidden; + height: 100%; +} +.group { + padding-left: 33.75rpx; + padding-right: 32.81rpx; +} +.image { + width: 123.75rpx; + height: 123.75rpx; +} +.group_1 { + margin-right: 2.81rpx; +} +.font { + font-size: 30rpx; + font-family: SourceHanSansCN; + line-height: 26.04rpx; + color: #000000; +} +.text { + line-height: 27.75rpx; +} +.font_2 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + color: #666666; +} +.text_2 { + line-height: 30rpx; +} +.section { + padding: 13.13rpx 7.71rpx 11.25rpx 9.38rpx; + background-color: #a5d63f; + border-radius: 9.38rpx; + height: 54.38rpx; +} +.image_2 { + width: 30rpx; + height: 30rpx; +} +.font_3 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 20.79rpx; + color: #ffffff; +} +.text_3 { + line-height: 22.72rpx; +} +.group_2 { + line-height: 22.69rpx; +} +.text_4 { + line-height: 22.69rpx; +} +.font_4 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 18.09rpx; + color: #d43030; +} +.text_5 { + color: #ff2b2b; + font-size: 26.25rpx; + line-height: 19.29rpx; +} +.group_3 { + padding-left: 100.24rpx; + padding-right: 82.2rpx; +} +.group_4 { + padding-bottom: 26.42rpx; +} +.text_6 { + line-height: 27.66rpx; +} +.text_7 { + line-height: 28.01rpx; +} +.group_5 { + padding: 0 21.64rpx; +} +.section_2 { + background-color: #000000; + width: 73.35rpx; + height: 5.63rpx; +} +.view { + margin-right: 16.88rpx; +} +.group_6 { + padding-top: 38.44rpx; +} +.section_3 { + padding: 32.68rpx 25.2rpx 31.07rpx 28.93rpx; + background-image: linear-gradient(180deg, #ff8d1a -75.6%, #ff8d1a00 42.2%); + border-radius: 18.75rpx; + border: solid 1.88rpx #ffbd7a; +} +.image_3 { + width: 45rpx; + height: 43.13rpx; +} +.font_5 { + font-size: 28.13rpx; + font-family: SourceHanSansCN; + line-height: 26.04rpx; + color: #000000; +} +.text_8 { + line-height: 25.88rpx; +} +.list-item_1 { + padding: 7.07rpx 0 5.94rpx; +} +.list-item_1:first-child { + margin-top: 0; +} +.text-wrapper { + padding: 9.56rpx 0 7.14rpx; + background-color: #ff5733; + border-radius: 37.5rpx; + width: 75rpx; +} +.pos { + position: absolute; + left: 1.88rpx; + top: 50%; + transform: translateY(-50%); +} +.text_9 { + font-size: 22.5rpx; +} +.font_6 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 26.04rpx; + color: #000000; +} +.text_10 { + font-size: 26.25rpx; + line-height: 24.49rpx; +} +.section_4 { + margin-top: 41.25rpx; + padding: 42.06rpx 27.07rpx 30.13rpx 30.81rpx; + background-image: linear-gradient(180deg, #ff8d1a -75.6%, #ff8d1a00 23.5%); + border-radius: 24.77rpx; + border: solid 1.88rpx #ffbd7a; +} +.image_4 { + width: 43.13rpx; + height: 43.13rpx; +} +.section_5 { + margin-right: 6.81rpx; + padding: 22.11rpx 80.4rpx 17.29rpx; + background-color: #ebebeb; + border-radius: 9.38rpx 9.38rpx 0rpx 0rpx; + border: solid 1.88rpx #e6e6e6; +} +.text_11 { + margin-right: 8.89rpx; + line-height: 26.25rpx; +} +.group_8 { + margin-right: 6.81rpx; +} +.section_6 { + padding: 21.24rpx 37.18rpx 21.79rpx; + background-color: #ffffff; + border: solid 1.88rpx #d1d1d1; +} +.font_7 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #636363; +} +.text_12 { + line-height: 22.59rpx; +} +.text_13 { + margin-right: 71.21rpx; + font-size: 26.25rpx; +} +.list { + margin-top: 46.88rpx; +} +.section_7 { + padding: 40.86rpx 41.12rpx 46.99rpx; + background-image: linear-gradient(180deg, #ff800099 -75.6%, #ff8d1a00 72.6%); + border-radius: 41.18rpx; + border: solid 1.88rpx #ffbd7a; +} +.text_15 { + margin-left: 50.55rpx; + line-height: 26.21rpx; +} +.section_8 { + margin-right: 2.14rpx; + margin-top: 35.92rpx; + background-color: #ffffff00; + height: 538.13rpx; + border: solid 1.88rpx #000000; +} +.view_2 { + margin-top: 35.94rpx; +} +.image_5 { + width: 52.5rpx; + height: 52.5rpx; +} +.pos_4 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} +.section_1 { + padding: 41.04rpx 41.12rpx 46.99rpx; + background-image: linear-gradient(180deg, #ff800099 -75.6%, #ff8d1a00 72.6%); + border-radius: 41.18rpx; + border: solid 1.88rpx #ffbd7a; +} +.text_1 { + margin-left: 50.49rpx; +} +.pos_5 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} +.pos_6 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} +.list_2 { + margin-top: 92.81rpx; +} +.list-item_2 { + background-color: #ffffff; + border-radius: 18.75rpx; + box-shadow: 0rpx 0rpx 11.25rpx #00000040; +} +.list-item_2:first-child { + margin-top: 0; +} +.text-wrapper_2 { + padding: 32.57rpx 0 33.08rpx; + background-color: #ffd1034d; + border-radius: 18.75rpx 18.75rpx 0rpx 0rpx; +} +.font_8 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #ff9d00; +} +.text_16 { + margin-left: 34.99rpx; + font-size: 26.25rpx; + line-height: 24.36rpx; +} +.group_13 { + padding: 38.17rpx 26.25rpx 24.38rpx 26.27rpx; +} +.group_9 { + width: 310.05rpx; +} +.font_9 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 30rpx; + color: #000000; +} +.font_10 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 30rpx; + color: #757575; +} +.text_17 { + margin-top: 20.66rpx; + width: 279.38rpx; +} +.group_11 { + margin-top: 8.55rpx; +} +.font_11 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 26.04rpx; + color: #757575; +} +.text_18 { + line-height: 25.76rpx; +} +.font_12 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #ff8000; +} +.text_19 { + line-height: 22.43rpx; +} +.image_6 { + margin-right: 33.73rpx; + width: 99.38rpx; + height: 99.38rpx; +} +.font_13 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #737373; +} +.text_27 { + margin-right: 25.74rpx; +} +.group_12 { + margin-top: 4.59rpx; +} +.text-wrapper_3 { + padding: 0; + background-color: #ffebeb; + border-radius: 9.38rpx; + width: 129.38rpx; + height: 48.75rpx; +} +.font_14 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #ff3f3f; +} +.text_21 { + line-height: 48.75rpx; +} +.text-wrapper_4 { + padding: 0; + background-color: #fff6de; + border-radius: 9.38rpx; + width: 129.38rpx; + height: 48.75rpx; +} +.font_15 { + font-size: 24.38rpx; + font-family: Times New Roman; + line-height: 22.69rpx; + color: #ffad29; +} +.text_22 { + line-height: 48.75rpx; +} +.text-wrapper_5 { + padding: 39.02rpx 0 35.06rpx; + flex: 1 1 375rpx; + background-color: #FFE4C9; + height: 99.38rpx; +} +.text_23 { + color: #ff8000; + line-height: 25.28rpx; +} +.text-wrapper_6 { + padding: 39.02rpx 0 35.06rpx; + flex: 1 1 375rpx; + background-color: #ff8d1a; + height: 99.38rpx; +} +.text_24 { + color: #ffffff; + line-height: 25.28rpx; +} +.foot-bottom { + position: fixed; + bottom: 0; + left: 0; + right: 0; +} \ No newline at end of file diff --git a/pages/projectModule/projectList/projectList.js b/pages/projectModule/projectList/projectList.js new file mode 100644 index 0000000..6c29e47 --- /dev/null +++ b/pages/projectModule/projectList/projectList.js @@ -0,0 +1,66 @@ +// pages/projectModule/projectList/projectList.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + items: [null, null, null], + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/pages/projectModule/projectList/projectList.json b/pages/projectModule/projectList/projectList.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/projectModule/projectList/projectList.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/projectModule/projectList/projectList.wxml b/pages/projectModule/projectList/projectList.wxml new file mode 100644 index 0000000..506d95c --- /dev/null +++ b/pages/projectModule/projectList/projectList.wxml @@ -0,0 +1,115 @@ + + + + + 美团省钱包 + + 不限制推广方式、不限美团新老用户,要求美团闪购新用户或... + + + 结算明细 + + + + 最高价 + ¥7 + + + + + + + 项目详情 + 我的推广码 + + + + + + + + + + + 项目通知 + + + + + 最新 + + 美团省钱包-春季活动价格上调通知~ + + + + + + + 项目政策 + + + + 结算标准 + 结算价 + + + + 3.6元购买30元券包 + 0.30 + + + + + + + 结算说明 + + + + + 项目说明 + + + + + 项目说明 + + + + + + + \ No newline at end of file diff --git a/pages/projectModule/projectList/projectList.wxss b/pages/projectModule/projectList/projectList.wxss new file mode 100644 index 0000000..a25fc75 --- /dev/null +++ b/pages/projectModule/projectList/projectList.wxss @@ -0,0 +1,252 @@ +.ml-13 { + margin-left: 24.38rpx; +} +.mt-7 { + margin-top: 13.13rpx; +} +.mt-35 { + margin-top: 65.63rpx; +} +.mt-13 { + margin-top: 24.38rpx; +} +.mt-15 { + margin-top: 28.13rpx; +} +.mt-21 { + margin-top: 39.38rpx; +} +.page { + padding: 74.92rpx 32.81rpx 201.56rpx 33.75rpx; + background-color: #ffffff; + width: 100%; + overflow-y: auto; + overflow-x: hidden; + height: 100%; +} +.image { + width: 123.75rpx; + height: 123.75rpx; +} +.group_1 { + margin-right: 2.81rpx; +} +.font { + font-size: 28.13rpx; + font-family: SourceHanSansCN; + line-height: 26.04rpx; + color: #000000; +} +.text { + font-size: 30rpx; + line-height: 27.75rpx; +} +.font_2 { + font-size: 26.25rpx; + font-family: SourceHanSansCN; + color: #666666; +} +.text_2 { + font-size: 24.38rpx; + line-height: 30rpx; +} +.section { + padding: 13.13rpx 7.71rpx 11.25rpx 9.38rpx; + background-color: #a5d63f; + border-radius: 9.38rpx; + height: 54.38rpx; +} +.image_2 { + width: 30rpx; + height: 30rpx; +} +.text_3 { + color: #ffffff; + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 22.72rpx; +} +.group { + line-height: 22.69rpx; +} +.text_4 { + font-size: 24.38rpx; + line-height: 22.69rpx; +} +.font_3 { + font-size: 26.25rpx; + font-family: Times New Roman; + line-height: 18.09rpx; + color: #d43030; +} +.text_5 { + color: #ff2b2b; + line-height: 19.29rpx; +} +.group_2 { + padding-left: 100.24rpx; + padding-right: 82.2rpx; +} +.group_3 { + padding-bottom: 26.42rpx; +} +.text_6 { + font-size: 30rpx; + line-height: 27.66rpx; +} +.text_7 { + font-size: 30rpx; + line-height: 28.01rpx; +} +.group_4 { + padding: 0 21.64rpx; +} +.section_2 { + background-color: #000000; + width: 73.35rpx; + height: 5.63rpx; +} +.view { + margin-right: 16.88rpx; +} +.group_5 { + padding-top: 38.44rpx; +} +.section_3 { + padding: 32.68rpx 25.2rpx 31.07rpx 28.93rpx; + background-image: linear-gradient(180deg, #ff8d1a -75.6%, #ff8d1a00 42.2%); + border-radius: 18.75rpx; + border: solid 1.88rpx #ffbd7a; +} +.image_3 { + width: 45rpx; + height: 43.13rpx; +} +.text_8 { + line-height: 25.88rpx; +} +.list-item_1 { + padding: 7.07rpx 0 5.94rpx; +} +.list-item_1:first-child { + margin-top: 0; +} +.text-wrapper { + padding: 9.56rpx 0 7.14rpx; + background-color: #ff5733; + border-radius: 37.5rpx; + width: 75rpx; +} +.pos { + position: absolute; + left: 1.88rpx; + top: 50%; + transform: translateY(-50%); +} +.font_4 { + font-size: 22.5rpx; + font-family: SourceHanSansCN; + line-height: 22.59rpx; + color: #ffffff; +} +.text_9 { + line-height: 20.79rpx; +} +.font_5 { + font-size: 26.25rpx; + font-family: SourceHanSansCN; + line-height: 26.04rpx; + color: #000000; +} +.text_10 { + line-height: 24.49rpx; +} +.section_4 { + padding: 42.06rpx 27.07rpx 30.13rpx 30.81rpx; + background-image: linear-gradient(180deg, #ff8d1a -75.6%, #ff8d1a00 23.5%); + border-radius: 24.77rpx; + border: solid 1.88rpx #ffbd7a; +} +.image_4 { + width: 43.13rpx; + height: 43.13rpx; +} +.section_5 { + margin-right: 6.81rpx; + padding: 22.11rpx 80.4rpx 17.29rpx; + background-color: #ebebeb; + border-radius: 9.38rpx 9.38rpx 0rpx 0rpx; + border: solid 1.88rpx #e6e6e6; +} +.text_11 { + margin-right: 8.89rpx; + line-height: 26.25rpx; +} +.group_7 { + margin-right: 6.81rpx; +} +.section_6 { + padding: 21.24rpx 37.18rpx 21.79rpx; + background-color: #ffffff; + border: solid 1.88rpx #d1d1d1; +} +.font_6 { + font-size: 26.25rpx; + font-family: Times New Roman; + line-height: 22.59rpx; + color: #636363; +} +.text_12 { + font-size: 24.38rpx; +} +.text_13 { + margin-right: 71.21rpx; +} +.section_7 { + padding: 40.86rpx 41.12rpx 46.99rpx; + background-image: linear-gradient(180deg, #ff800099 -75.6%, #ff8d1a00 72.6%); + border-radius: 41.18rpx; + border: solid 1.88rpx #ffbd7a; +} +.text_15 { + margin-left: 50.55rpx; + line-height: 26.21rpx; +} +.section_8 { + margin-right: 2.14rpx; + margin-top: 35.92rpx; + background-color: #ffffff00; + height: 538.13rpx; + border: solid 1.88rpx #000000; +} +.view_2 { + margin-top: 35.94rpx; +} +.image_5 { + width: 52.5rpx; + height: 52.5rpx; +} +.pos_4 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} +.section_9 { + padding: 41.04rpx 41.12rpx 46.99rpx; + background-image: linear-gradient(180deg, #ff800099 -75.6%, #ff8d1a00 72.6%); + border-radius: 41.18rpx; + border: solid 1.88rpx #ffbd7a; +} +.text_1 { + margin-left: 50.49rpx; +} +.pos_5 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} +.pos_6 { + position: absolute; + left: 34.69rpx; + top: 29.06rpx; +} \ No newline at end of file diff --git a/pages/projectModule/userProject/userProject.js b/pages/projectModule/userProject/userProject.js new file mode 100644 index 0000000..ab213e9 --- /dev/null +++ b/pages/projectModule/userProject/userProject.js @@ -0,0 +1,66 @@ +// pages/projectModule/userProject/userProject.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + items: [null, null, null, null], + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad(options) { + + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady() { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow() { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide() { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload() { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh() { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom() { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage() { + + } +}) \ No newline at end of file diff --git a/pages/projectModule/userProject/userProject.json b/pages/projectModule/userProject/userProject.json new file mode 100644 index 0000000..8835af0 --- /dev/null +++ b/pages/projectModule/userProject/userProject.json @@ -0,0 +1,3 @@ +{ + "usingComponents": {} +} \ No newline at end of file diff --git a/pages/projectModule/userProject/userProject.wxml b/pages/projectModule/userProject/userProject.wxml new file mode 100644 index 0000000..d3fe283 --- /dev/null +++ b/pages/projectModule/userProject/userProject.wxml @@ -0,0 +1,38 @@ + + + + + + + + 美团省钱包 + 结算T+1 实时数据 + + + + + + + + 推广码 + + + + 结算明细 + + + + + \ No newline at end of file diff --git a/pages/projectModule/userProject/userProject.wxss b/pages/projectModule/userProject/userProject.wxss new file mode 100644 index 0000000..9de8eb7 --- /dev/null +++ b/pages/projectModule/userProject/userProject.wxss @@ -0,0 +1,99 @@ +.mt-15 { + margin-top: 28.13rpx; +} +.ml-3 { + margin-left: 5.63rpx; +} +.page { + background-color: #f5f5f5; + width: 100%; + overflow-y: auto; + overflow-x: hidden; + height: 100%; +} +.list { + padding: 54.38rpx 37.5rpx 200.63rpx; + background-image: linear-gradient(180deg, #ff8d1a -24.5%, #ff8d1a00 57.4%); +} +.list-item { + padding: 30rpx 26.25rpx; + background-color: #ffffff; + border-radius: 18.75rpx; +} +.list-item:first-child { + margin-top: 0; +} +.image { + width: 105rpx; + height: 105rpx; +} +.group { + width: 261.25rpx; +} +.font { + font-size: 30rpx; + font-family: SourceHanSansCN; + line-height: 27.75rpx; + color: #000000; +} +.font_2 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 31.88rpx; + color: #9c9c9c; +} +.text { + font-size: 26.25rpx; +} +.image_2 { + width: 41.25rpx; + height: 41.25rpx; +} +.group_2 { + align-self: flex-end; +} +.equal-division { + width: 336.56rpx; +} +.image_3 { + width: 33.75rpx; + height: 33.75rpx; +} +.font_3 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 22.69rpx; + color: #ff8d1a; +} +.section { + flex: 1 1 155.63rpx; +} +.equal-division-item { + padding: 11.25rpx; + background-color: #ffffff; + border-radius: 9.38rpx; + height: 56.25rpx; + border-left: solid 1.88rpx #ff8d1a; + border-right: solid 1.88rpx #ff8d1a; + border-top: solid 1.88rpx #ff8d1a; + border-bottom: solid 1.88rpx #ff8d1a; +} +.equal-division-item_2 { + padding: 11.25rpx; + background-color: #ff8d1a; + border-radius: 9.38rpx; + height: 54.38rpx; +} +.image_4 { + width: 30rpx; + height: 30rpx; +} +.font_4 { + font-size: 24.38rpx; + font-family: SourceHanSansCN; + line-height: 22.69rpx; + color: #ffffff; +} +.text_2 { + line-height: 22.72rpx; +} \ No newline at end of file diff --git a/request.js b/request.js index 298dcad..2aa9897 100644 --- a/request.js +++ b/request.js @@ -1 +1,3 @@ -export const url='http://1.94.237.210:3457'; \ No newline at end of file +export const url='http://localhost:3456'; + +export const baseUrl = 'http://localhost:3456' \ No newline at end of file