diff --git a/config.js b/config.js index 1dc490e..352e3f4 100644 --- a/config.js +++ b/config.js @@ -3,8 +3,8 @@ module.exports = { // baseUrl: 'https://vue.ruoyi.vip/prod-api', imagesUrl: 'http://122.51.230.86:9000', - // baseUrl: 'https://www.nuoyunr.com', - baseUrl: 'http://192.168.1.27:48080', + baseUrl: 'https://www.nuoyunr.com', + // baseUrl: 'http://192.168.1.27:48080', appId: 'wx684fc832e96cee65', appSecret: 'd1fecac806c5f3cd9aca9f3d5c3759c7', // baseUrl: 'http://192.168.31.54:8016/jx', diff --git a/manifest.json b/manifest.json index 36e480f..262e592 100644 --- a/manifest.json +++ b/manifest.json @@ -1,88 +1,88 @@ { - "name": "驾悦同行", - "appid": "__UNI__7A6878C", - "description": "", - "versionName": "1.0.0", - "versionCode": "100", - "transformPx": false, - /* 5+App特有相关 */ - "app-plus": { - "usingComponents": true, - "nvueStyleCompiler": "uni-app", - "compilerVersion": 3, - "splashscreen": { - "alwaysShowBeforeRender": true, - "waiting": true, - "autoclose": true, - "delay": 0 - }, - /* 模块配置 */ - "modules": {}, - /* 应用发布信息 */ - "distribute": { - /* android打包配置 */ - "android": { - "permissions": [ - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "" - ] - }, - /* ios打包配置 */ - "ios": {}, - /* SDK配置 */ - "sdkConfigs": {} - } - }, - /* 快应用特有相关 */ - "quickapp": {}, - /* 小程序特有相关 */ - "mp-weixin": { - "appid": "wx684fc832e96cee65", - "setting": { - "urlCheck": false, - "es6": true, - "postcss": true, - "minified": true - }, - "usingComponents": true, - "optimization": { - "subPackages": true - }, - "permission": { - "scope.userLocation": { - "desc": "用于展示驾校位置" - } - } - }, - "mp-alipay": { - "usingComponents": true - }, - "mp-baidu": { - "usingComponents": true - }, - "mp-toutiao": { - "usingComponents": true - }, - "uniStatistics": { - "enable": false - }, - "vueVersion": "2", - "h5": { - "sdkConfigs": { - "maps": {} - } - } -} \ No newline at end of file + "name" : "驾悦同行", + "appid" : "__UNI__077A2D3", + "description" : "", + "versionName" : "1.0.0", + "versionCode" : "100", + "transformPx" : false, + /* 5+App特有相关 */ + "app-plus" : { + "usingComponents" : true, + "nvueStyleCompiler" : "uni-app", + "compilerVersion" : 3, + "splashscreen" : { + "alwaysShowBeforeRender" : true, + "waiting" : true, + "autoclose" : true, + "delay" : 0 + }, + /* 模块配置 */ + "modules" : {}, + /* 应用发布信息 */ + "distribute" : { + /* android打包配置 */ + "android" : { + "permissions" : [ + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "" + ] + }, + /* ios打包配置 */ + "ios" : {}, + /* SDK配置 */ + "sdkConfigs" : {} + } + }, + /* 快应用特有相关 */ + "quickapp" : {}, + /* 小程序特有相关 */ + "mp-weixin" : { + "appid" : "wx684fc832e96cee65", + "setting" : { + "urlCheck" : false, + "es6" : true, + "postcss" : true, + "minified" : true + }, + "usingComponents" : true, + "optimization" : { + "subPackages" : true + }, + "permission" : { + "scope.userLocation" : { + "desc" : "用于展示驾校位置" + } + } + }, + "mp-alipay" : { + "usingComponents" : true + }, + "mp-baidu" : { + "usingComponents" : true + }, + "mp-toutiao" : { + "usingComponents" : true + }, + "uniStatistics" : { + "enable" : false + }, + "vueVersion" : "2", + "h5" : { + "sdkConfigs" : { + "maps" : {} + } + } +} diff --git a/newPages/newIndex/index.vue b/newPages/newIndex/index.vue index d456ed4..16b1151 100644 --- a/newPages/newIndex/index.vue +++ b/newPages/newIndex/index.vue @@ -91,10 +91,7 @@ url: '/static/lanhu_shouye2gai/pj.png', text: '评价' }, - { - url: '/static/lanhu_shouye2gai/pj.png', - text: '业务办理指南' - }, + ], swiperList: [], msg: "1", @@ -177,6 +174,10 @@ setCoachId(res.data.userId) setStaffType('01') } + if (res.data.type == 'ywjl') { + setCoachId(res.data.userId) + setStaffType('04') + } console.log('getCoachId', getCoachId()) console.log('getStaffType', getStaffType()) } diff --git a/newPages/orderDetails/index.vue b/newPages/orderDetails/index.vue index 1d400d2..e839777 100644 --- a/newPages/orderDetails/index.vue +++ b/newPages/orderDetails/index.vue @@ -189,6 +189,7 @@ }, onLoad(options) { const order = JSON.parse(decodeURIComponent(options.data)); + console.log('order', order) this.orderData = order; this.getCourseDetails() }, @@ -305,7 +306,7 @@ try { // 1. 获取预支付参数 const prepayRes = await request({ - url: `/small/jxInfo/prepayment?type=jsapi&orderNo=${orderNo}&orderId=${orderId}&payType=${payType}`, + url: `/small/jxInfo/prepayment?type=jsapi&orderNo=${orderNo}&orderId=${orderId}&payType=${payType}&tenantId=${this.orderData.tenantId}`, method: 'get' }); @@ -339,7 +340,7 @@ }, fail: (err) => { resolve(err.errMsg === 'requestPayment:fail cancel' ? 'cancelled' : - 'fail'); + 'fail'); } }); }); @@ -395,7 +396,7 @@ tenantId: this.orderData.tenantId, type: this.orderData.type, carType: this.getLicenseTypeDescription(this.orderData.type), - money: this.orderData.reserveMoney, + money: (this.orderData.reserveMoney * 100 + this.orderData.restMoney * 100) / 100, indent: this.orderData.userNo, phone: this.orderData.userPhone, time: this.getCurrentDateTime(), diff --git a/newPages/orderList/assets/style/index.rpx.scss b/newPages/orderList/assets/style/index.rpx.scss index ffbfa18..a78cfad 100644 --- a/newPages/orderList/assets/style/index.rpx.scss +++ b/newPages/orderList/assets/style/index.rpx.scss @@ -8,6 +8,7 @@ background-color: rgba(255, 255, 255, 1); width: 750rpx; height: 92rpx; + padding-top: 88rpx; .image_1 { width: 64rpx; height: 36rpx; diff --git a/newPages/orderList/index.vue b/newPages/orderList/index.vue index 7374d31..2fc9423 100644 --- a/newPages/orderList/index.vue +++ b/newPages/orderList/index.vue @@ -1,325 +1,341 @@ + @import '../common/common.scss'; + @import './assets/style/index.rpx.scss'; + \ No newline at end of file diff --git a/newPages/schoolDetail/assets/style/index.rpx.scss b/newPages/schoolDetail/assets/style/index.rpx.scss index eafbe26..48652fd 100644 --- a/newPages/schoolDetail/assets/style/index.rpx.scss +++ b/newPages/schoolDetail/assets/style/index.rpx.scss @@ -233,7 +233,7 @@ .group_6 { background-color: rgba(255, 255, 255, 1); border-radius: 8px; - //height: 642rpx; + // height: 942rpx; margin-left: 32rpx; width: 686rpx; justify-content: flex-center; diff --git a/newPages/schoolDetail/index.vue b/newPages/schoolDetail/index.vue index 0f68d9b..4c135da 100644 --- a/newPages/schoolDetail/index.vue +++ b/newPages/schoolDetail/index.vue @@ -267,7 +267,7 @@ method: 'GET', params: { pageNo: 1, - pageSize: 3, + pageSize: 4, tenantId: this.tenantId, }, tenantIdFlag: false diff --git a/pages.json b/pages.json index 9582b5c..7bb9915 100644 --- a/pages.json +++ b/pages.json @@ -188,14 +188,22 @@ "navigationBarTitleText": "通知公告详情", "navigationStyle": "custom" } + }, + { + "path": "guideContent/index", + "style": { + "enablePullDownRefresh": true, + "navigationBarTitleText": "业务办理指南详情", + "navigationStyle": "custom" + } } ] - }, - { + } + /* { "root": "uni_modules", "name": "modules", "pages": [] - } + } */ ], "tabBar": { "color": "#999999", // 未选中时的文字颜色(默认灰色) diff --git a/pagesA/courseDetail/index.vue b/pagesA/courseDetail/index.vue index 1452a0f..0c2db7e 100644 --- a/pagesA/courseDetail/index.vue +++ b/pagesA/courseDetail/index.vue @@ -26,7 +26,7 @@ {{ courseDetails.type }} - 周一至周日 08:00-18:00 + diff --git a/pagesA/register/index.vue b/pagesA/register/index.vue index 099e85a..2874cda 100644 --- a/pagesA/register/index.vue +++ b/pagesA/register/index.vue @@ -105,18 +105,52 @@ --> - - - {{ dname }} - : - - ¥{{ currentPrice }} - + + + + 全款支付:¥{{ rightInfoList.price }} + + + + + + + + + + + 定金支付:¥{{ rightInfoList.reserveMoney }} + + + + + + - - + + + 支付方式 + + + 微信支付 + + + + + + + + 线下支付 + + + + + + + @@ -267,6 +301,7 @@ this.userId = this.userDetails.id, this.userinfo = getLocalUserInfo() this.localStaffType = getStaffType() + console.log('this.localStaffType', this.localStaffType) if (this.localStaffType === '02') { this.localCoachId = getCoachId() } @@ -314,6 +349,32 @@ this.rightInfoList.reserveMoney : this.rightInfoList.price; }, + // 修改支付类型(全款/定金) + changePayType(type) { + this.selectedPayType = type; + this.dname = type === 1 ? '定金' : '全款'; + this.currentPrice = type === 1 ? this.rightInfoList.reserveMoney : this.rightInfoList.price; + if (type == 1) { + this.startPay = 1 + } else if (type == 2) { + this.startPay = 2 + } + console.log('this.selectedPayType', this.selectedPayType) + console.log('this.startPay', this.startPay) + }, + // 修改支付渠道选择按钮(微信/线下) + changeStartPay(channel) { + /* if (this.selectedPayType == 1) { + this.startPay = 1 + } else if (this.selectedPayType == 2 && this.startPay == 1) { + console.log('123', this.selectedPayType == 2 && this.startPay == 1) + this.startPay = 2 + } else { + this.startPay = channel; + } */ + this.startPay = channel; + + }, async getStudentDetail() { const res = await request({ url: '/app-api/small/dl-drive-school-student/getByUserId', @@ -547,6 +608,7 @@ reserveMoney: reserveMoney, payType: payType, restMoney: restMoney, + payChannel: '1', } }); @@ -554,7 +616,7 @@ this.orderNo = res.orderNo; const prepayRes = await request({ - url: `/app-api/small/jxInfo/prepayment?type=jsapi&orderNo=${this.orderNo}&orderId=${this.orderId}&payType=${payType}`, + url: `/app-api/small/jxInfo/prepayment?type=jsapi&orderNo=${this.orderNo}&orderId=${this.orderId}&payType=${payType}&tenantId=${this.tenantId}`, method: 'get' }); @@ -588,6 +650,7 @@ reserveMoney: this.rightInfoList.price, payType: '2', userId: this.userId, + payChannel: '2', } }); @@ -689,15 +752,17 @@ // 4. 处理支付 if (this.startPay === 1) { const res = await request({ - url: `/app-api/small/jxInfo/prepayment?type=jsapi&orderNo=${this.orderNo}&orderId=${this.orderId}&payType=${payType}`, + url: `/app-api/small/jxInfo/prepayment?type=jsapi&orderNo=${this.orderNo}&orderId=${this.orderId}&payType=${payType}&tenantId=${this.tenantId}`, method: 'get' }); - + this.orderTime = this.getCurrentDateTime() const result = await this.handleWxPayment(res); if (result === 'success') { + console.log('ifSuccess', result) await Promise.all([ this.updateOrderStatus(this.orderId, '2'), this.insertSchoolStudent() + ]); this.signContract(); } @@ -933,6 +998,9 @@ this.autoAssignCoach() } + } else if (getCoachId() && this.localStaffType == '04') { + studentData.source = '04'; + studentData.sourceUserId = getCoachId(); // 设置来源用户ID为业务经理ID } else { studentData.source = '03'; // 自来客户 this.sendMessages(this.name, this.rightInfoList.name, this.jlId) @@ -951,8 +1019,9 @@ courseName: this.rightInfoList.name, licenseType: this.rightInfoList.type, price: this.rightInfoList.price, - orderTime: this.orderTime + orderTime: this.getCurrentDateTime() } + console.log('现在是微信支付', dynamicData) this.sendSubscriptionMessage(dynamicData) }, @@ -1021,7 +1090,7 @@ tenantId: this.tenantId, type: this.rightInfoList.type, carType: this.getLicenseTypeDescription(this.rightInfoList.type), - money: this.payPrice, + money: this.rightInfoList.price, indent: this.identity, phone: this.phone, time: this.getCurrentDateTime(), @@ -1113,6 +1182,136 @@ background-color: #fff; border-radius: 20rpx; + .payment-type-container { + margin-bottom: 30rpx; + + .payment-type-item { + display: flex; + justify-content: space-between; + align-items: center; + padding: 25rpx 0; + border-bottom: 1rpx solid #f5f5f5; + + &.active { + .payment-type-name { + color: #2C78F5; + font-weight: bold; + } + + .payment-type-price { + color: #ff4d4f; + } + } + + .payment-type-info { + flex: 1; + + .payment-type-name { + font-size: 30rpx; + color: #333; + } + + .payment-type-price { + font-size: 26rpx; + color: #999; + margin-top: 10rpx; + } + } + + .payment-type-radio { + width: 40rpx; + height: 40rpx; + border-radius: 50%; + border: 1rpx solid #ddd; + display: flex; + align-items: center; + justify-content: center; + + .radio-selected { + width: 24rpx; + height: 24rpx; + border-radius: 50%; + background-color: #2C78F5; + } + + .radio-unselected { + width: 24rpx; + height: 24rpx; + border-radius: 50%; + background-color: transparent; + } + } + } + } + + .payment-channel-container { + margin-top: 20rpx; + padding-top: 20rpx; + border-top: 1rpx solid #eee; + + .payment-channel-title { + font-size: 28rpx; + color: #666; + margin-bottom: 20rpx; + } + + .payment-channel-item { + display: flex; + align-items: center; + padding: 20rpx 0; + + &.active { + .channel-name { + color: #2C78F5; + } + } + + .channel-icon { + width: 40rpx; + height: 40rpx; + margin-right: 20rpx; + } + + .channel-name { + flex: 1; + font-size: 28rpx; + color: #333; + } + + .channel-radio { + width: 40rpx; + height: 40rpx; + border-radius: 50%; + border: 1rpx solid #ddd; + display: flex; + align-items: center; + justify-content: center; + + .radio-selected { + width: 24rpx; + height: 24rpx; + border-radius: 50%; + background-color: #2C78F5; + } + + .radio-unselected { + width: 24rpx; + height: 24rpx; + border-radius: 50%; + background-color: transparent; + } + } + } + } + } + + /* .bm-page-dj { + margin-top: 30rpx; + padding: 30rpx; + background-color: #fff; + border-radius: 20rpx; + + .dj-list { padding: 20rpx 0; display: flex; @@ -1146,7 +1345,7 @@ color: red; } } - } + } */ .bm-page-info { margin-top: 30rpx; diff --git a/pagesA/register/pushService.js b/pagesA/register/pushService.js index 31808fb..b4d84df 100644 --- a/pagesA/register/pushService.js +++ b/pagesA/register/pushService.js @@ -42,6 +42,8 @@ export async function sendSubscriptionMessage(dynamicData) { } } }; + console.log('messageData', messageData) + console.log('微信支付是否进入此方法') // 发送订阅消息 await request({ diff --git a/static/imgs/mapBackground.png b/static/imgs/mapBackground.png deleted file mode 100644 index f49b00e..0000000 Binary files a/static/imgs/mapBackground.png and /dev/null differ diff --git a/static/imgs/qbdd3.png b/static/imgs/qbdd3.png new file mode 100644 index 0000000..a06c2c8 Binary files /dev/null and b/static/imgs/qbdd3.png differ