diff --git a/components/banner/index.js b/components/banner/index.js index 07c650c..713f85b 100644 --- a/components/banner/index.js +++ b/components/banner/index.js @@ -53,6 +53,7 @@ Component({ }) } } else if (e.currentTarget.dataset.data.type == 2) { + console.log('freeBannerDetail'); // 自由图文 tt.navigateTo({ url: `/pages/freeBannerDetail/index?id=${e.currentTarget.dataset.id}` diff --git a/components/banner/index.ttml b/components/banner/index.ttml index 50edf4b..589e89a 100644 --- a/components/banner/index.ttml +++ b/components/banner/index.ttml @@ -1,19 +1,23 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pages/main/index.js b/pages/main/index.js index 915e65f..35357b5 100644 --- a/pages/main/index.js +++ b/pages/main/index.js @@ -93,6 +93,9 @@ Page({ options.id = this.data.newArr[2]; } else if (options.type == 'scanIn') { options.tenantId = this.data.newArr[2] || ""; + } else if (options.type == 'scanInAu') { + console.log(options, 'scanInAu'); + tt.setStorageSync('mallTenantId', this.data.newArr[2] || ""); } } } @@ -417,6 +420,13 @@ Page({ tt.navigateTo({ url: `/index/index?type=in&tenantId=${options.tenantId}` }) + } + // 通过扫码进入关于我们 + else if (app.globalData.type == 'scanInAu') { + console.log('scanInAu!!!!!!!'); + tt.navigateTo({ + url: `/pages/mallInfo/mallInfo` + }) } else { console.log('/index/index'); // 主页 @@ -601,6 +611,11 @@ Page({ tt.navigateTo({ url: `/index/index?type=in&tenantId=${options.tenantId}` }) + } // 首页 + else if (app.globalData.type == 'scanInAu') { + tt.navigateTo({ + url: `/pages/mallInfo/mallInfo` + }) } else { tt.reLaunch({ url: '/index/index', diff --git a/pages/mallInfo/mallInfo.js b/pages/mallInfo/mallInfo.js index 1006438..214ec1f 100644 --- a/pages/mallInfo/mallInfo.js +++ b/pages/mallInfo/mallInfo.js @@ -11,44 +11,69 @@ Page({ */ data: { navigationBarHeight, - weekName:[], - times:[], - dateArr:[ - { name: "星期一", value: "0" }, - { name: "星期二", value: "1" }, - { name: "星期三", value: "2" }, - { name: "星期四", value: "3" }, - { name: "星期五", value: "4" }, - { name: "星期六", value: "5" }, - { name: "星期天", value: "6" } + weekName: [], + times: [], + dateArr: [{ + name: "星期一", + value: "0" + }, + { + name: "星期二", + value: "1" + }, + { + name: "星期三", + value: "2" + }, + { + name: "星期四", + value: "3" + }, + { + name: "星期五", + value: "4" + }, + { + name: "星期六", + value: "5" + }, + { + name: "星期天", + value: "6" + } ], + mallTenantId: "" }, /** * 生命周期函数--监听页面显示 */ - onShow: function () { + onShow: function (options) { let that = this; + const mallTenantId = tt.getStorageSync('mallTenantId'); console.log("渲染开始") Http.get({ - url: config.api.getMallInfo, - }) + url: config.api.getMallInfo, + data: { + mallTenantId: mallTenantId + } + }) .then(res => { - if (res.data.businessHours){ + if (res.data.businessHours) { let businessHours = JSON.parse(res.data.businessHours) - businessHours.map((item, index) => { - item.weekName = [that.data.dateArr.filter(e => e.value == item.week[0])[0].name, that.data.dateArr.filter(e => e.value == item.week[1])[0].name].toString().replace(/\,/g, ' -- '), - item.time = [util.convertUTCTimeToLocalTime(item.time[0]), util.convertUTCTimeToLocalTime(item.time[1])].toString().replace(/\,/g, ' -') - }) - console.log(businessHours, 222) - that.setData({ - name: res.data.name, - servicePhone: res.data.servicePhone, - img: res.data.img, - introduction: res.data.introduction, - parkPlaceNumber: res.data.parkPlaceNumber, - businessHoursH: businessHours, - }) - } + businessHours.map((item, index) => { + item.weekName = [that.data.dateArr.filter(e => e.value == item.week[0])[0].name, that.data.dateArr.filter(e => e.value == item.week[1])[0].name].toString().replace(/\,/g, ' -- '), + item.time = [util.convertUTCTimeToLocalTime(item.time[0]), util.convertUTCTimeToLocalTime(item.time[1])].toString().replace(/\,/g, ' -') + }) + console.log(businessHours, 222) + that.setData({ + name: res.data.name, + servicePhone: res.data.servicePhone, + img: res.data.img, + introduction: res.data.introduction, + parkPlaceNumber: res.data.parkPlaceNumber, + businessHoursH: businessHours, + }) + } }) .catch(err => { tt.showModal({ diff --git a/pages/order/detail/index.ttml b/pages/order/detail/index.ttml index 85ffcd5..92de3f7 100644 --- a/pages/order/detail/index.ttml +++ b/pages/order/detail/index.ttml @@ -10,193 +10,263 @@ + - - - - - 交易成功 - - - - 付款成功 - - + + + + 交易成功 + + + 付款成功 + + + - - - {{order.title}} + + + {{order.title}} + + + + - - - - - - - - - - - - - - - - - - - 点一点刷新二维码 - - 二维码在 - {{expiredSeconds}}s - 后失效 - - + + + + + + + + + + + + - + + + + 点一点刷新二维码 + + 二维码在 + {{expiredSeconds}}s + 后失效 + + + - - - - - - - 兑换码: - {{showIdFalg?order.couponOrderId:order.couponOrderIdS}} - - - - + + + 兑换码: + {{showIdFalg?order.couponOrderId:order.couponOrderIdS}} + + + + - + - - - 交易快照:可作为交易争执的判断依据 + + + 交易快照:可作为交易争执的判断依据 - - - - - - - 订单编号: - {{order.id}} - - - 物流状态: - {{(order.shippingStatus==10||order.shippingStatus==14)?"待自提":order.shippingStatus==15?"已自提":order.shippingStatus==20?"待发货":order.shippingStatus==24?"待收货":order.shippingStatus==25?"已收货":""}} - - - 物流公司: - {{order.deliveryInfo.courierInput}} - - - 快递单号: + + 订单编号: + {{order.id}} + + + 物流状态: + {{(order.shippingStatus==10||order.shippingStatus==14)?"待自提":order.shippingStatus==15?"已自提":order.shippingStatus==20?"待发货":order.shippingStatus==24?"待收货":order.shippingStatus==25?"已收货":""}} + + + 物流公司: + {{order.deliveryInfo.courierInput}} + + + 快递单号: - {{order.deliveryInfo.expressageIdInput}} + {{order.deliveryInfo.expressageIdInput}} - 复制 - 查询物流 - + 复制 + 查询物流 + - - - 实付金额: - - ¥ - {{order.payment/100}} - + + 实付金额: + + ¥ + {{order.payment/100}} - - - - - 团购详情 - - - - {{item.group_name}} - - - - {{itemChi.name}}({{itemChi.count}}份) - ¥{{itemChi.price/100}} - + + + + + + 团购详情 + + + + {{item.group_name}} + + + + {{itemChi.name}}({{itemChi.count}}份) + ¥{{itemChi.price/100}} + - - - 购买须知 + + + 购买须知 + + + 有效期 + • {{order.validStartDate}}至{{order.validEndDate}} + 可用时间 + • 商家营业时间内到店使用 + • 周末不支持使用 + • 节假日(元旦、春节、清明、劳动节、端午节、中秋节、国庆节、情人节、圣诞节)不支持使用 + + + 购买限制 + • 每个用户限购{{order.useLimitQuantity}}单 + + 预约消费 + • 无需预约,高峰时段可能等位 + • {{order.subscribeSing}} + + 适用人数 + • 该团购劵最多{{order.rec_person_num_max}}人使用 + + 温馨提示 + • 团购券不支持配送或外卖 + • 该团购商品{{order.pack=='false'?'不支持':'支持'}}打包 + • {{order.besides=="false"?'不可以':'可以'}}外带餐食 + + • + {{order.superimposed_discounts=="false"?'不可以':'可以'}}享受店内其他优惠 + • {{order.private_room=="false"?'不可以使用':'可以使用'}}包间 + + 使用规则 + + + + {{item.title}} + {{item.content}} + + + + + + 礼券: + + + + + + {{item.title}} + 面额:{{item.priceStr}}元 + + + + + + + + + + + + + + 购买须知 有效期 • {{order.validStartDate}}至{{order.validEndDate}} + + + 售卖期 + • {{order.soldStartTime}}至{{order.soldEndTime}} + + 可用时间 • 商家营业时间内到店使用 • 周末不支持使用 @@ -255,106 +325,35 @@ - - - - 购买须知 - 有效期 - • {{order.validStartDate}}至{{order.validEndDate}} - - - 售卖期 - • {{order.soldStartTime}}至{{order.soldEndTime}} - - - 可用时间 - • 商家营业时间内到店使用 - • 周末不支持使用 - • 节假日(元旦、春节、清明、劳动节、端午节、中秋节、国庆节、情人节、圣诞节)不支持使用 - - - 购买限制 - • 每个用户限购{{order.useLimitQuantity}}单 - - 预约消费 - • 无需预约,高峰时段可能等位 - • {{order.subscribeSing}} - - 适用人数 - • 该团购劵最多{{order.rec_person_num_max}}人使用 - - 温馨提示 - • 团购券不支持配送或外卖 - • 该团购商品{{order.pack=='false'?'不支持':'支持'}}打包 - • {{order.besides=="false"?'不可以':'可以'}}外带餐食 - - • - {{order.superimposed_discounts=="false"?'不可以':'可以'}}享受店内其他优惠 - • {{order.private_room=="false"?'不可以使用':'可以使用'}}包间 - - 使用规则 - - - - {{item.title}} - {{item.content}} - - - - - - 礼券: - - - - - - {{item.title}} - 面额:{{item.priceStr}}元 - - - - - - - - - - - - - - - 签收 - - 去评价 - - 对本订单有疑问或纠纷,请点击下方联系抖音官方客服 - - - 抖音官方客服 - + 签收 + 去评价 + + 对本订单有疑问或纠纷,请点击下方联系抖音官方客服 + + + 抖音官方客服 + + - - - 是否确认收到商品? - 签收后将完成订单 - - 确认签收 - 取消 - + + + 是否确认收到商品? + 签收后将完成订单 + + 确认签收 + 取消 - \ No newline at end of file + + \ No newline at end of file diff --git a/project.config.json b/project.config.json index 461d295..62f42c8 100644 --- a/project.config.json +++ b/project.config.json @@ -1,88 +1,70 @@ { - "setting": { - "urlCheck": false, - "es6": true, - "newFeature": false, - "postcss": false, - "mockUpdate": true, - "minified": false, - "autoPush": false, - "scripts": false, - "mockLogin": false, - "autoCompile": true, - "localPlugins": false, - "IDEPreviewHotRestartCache": false - }, - "appid": "ttde7ca8c141425a2301", - "projectname": "tt富茂C", - "condition": { - "miniprogram": { - "current": -1, - "list": [ - { - "id": 1678508631604, - "name": "pages/main/index", - "pathName": "pages/main/index", - "query": "type=uc&tenantId=1033", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1678428610317, - "name": "index/index", - "pathName": "pages/main/index", - "query": "type=scanIn&tenantId=1034", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1676971480642, - "name": "pages/liveLsit/liveLsit", - "pathName": "pages/liveLsit/liveLsit", - "query": "tenantId=1032", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1678330099779, - "name": " index/index(scanIn)", - "pathName": "index/index", - "query": "type=in&tenantId=1032", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1678687102364, - "name": "奥尔良鸡腿(昌东)", - "pathName": "pages/main/index", - "query": "type=cd&couponChannelId=790733288312070144&tenantId=1032", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1679365133968, - "name": "爽口酸萝卜一份(昌西)", - "pathName": "pages/main/index", - "query": "type=cd&couponChannelId=792625127019700224&tenantId=1033", - "scene": "990001", - "launchFrom": "scan", - "location": "qr_code" - }, - { - "id": 1679474738627, - "name": "detail", - "pathName": "pages/coupon/detail/index", - "query": "type=cd&couponChannelId=792625127019700224&tenantId=1033", - "scene": "027005", - "launchFrom": "live", - "location": "live_cart_card" - } - ] + "setting": { + "urlCheck": false, + "es6": true, + "newFeature": false, + "postcss": false, + "mockUpdate": true, + "minified": false, + "autoPush": false, + "scripts": false, + "mockLogin": false, + "autoCompile": true, + "localPlugins": false, + "IDEPreviewHotRestartCache": false + }, + "appid": "ttde7ca8c141425a2301", + "projectname": "tt富茂C", + "condition": { + "miniprogram": { + "current": -1, + "list": [ + { + "id": 1678508631604, + "name": "pages/main/index", + "pathName": "pages/main/index", + "query": "type=uc&tenantId=1033", + "scene": "990001", + "launchFrom": "scan", + "location": "qr_code" + }, + { + "id": 1678428610317, + "name": "index/index", + "pathName": "pages/main/index", + "query": "type=scanIn&tenantId=1034", + "scene": "990001", + "launchFrom": "scan", + "location": "qr_code" + }, + { + "id": 1678330099779, + "name": "scanIn", + "pathName": "pages/main/index", + "query": "scene=t:scanInAu:1034", + "scene": "990001", + "launchFrom": "scan", + "location": "qr_code" + }, + { + "id": 1678687102364, + "name": "奥尔良鸡腿(昌东)", + "pathName": "pages/main/index", + "query": "type=cd&couponChannelId=790733288312070144&tenantId=1032", + "scene": "990001", + "launchFrom": "scan", + "location": "qr_code" + }, + { + "id": 1679365133968, + "name": "爽口酸萝卜一份(昌西)", + "pathName": "pages/main/index", + "query": "type=cd&couponChannelId=792625127019700224&tenantId=1033", + "scene": "990001", + "launchFrom": "scan", + "location": "qr_code" } + ] } + } }