作者 lihongjuan

团购

正在显示 100 个修改的文件 包含 3901 行增加0 行删除

要显示太多修改。

为保证性能只显示 100 of 100+ 个文件。

  1 +//app.js
  2 +App({
  3 + onLaunch: function () {
  4 +
  5 + wx.getSystemInfo({
  6 + success: res => {
  7 + //导航高度
  8 + this.globalData.navHeight = res.statusBarHeight + 46;
  9 + }, fail(err) {
  10 + console.log(err);
  11 + }
  12 + })
  13 +
  14 + // 展示本地存储能力
  15 + var logs = wx.getStorageSync('logs') || []
  16 + logs.unshift(Date.now())
  17 + wx.setStorageSync('logs', logs)
  18 +
  19 + //自动更新版本
  20 + const updateManager = wx.getUpdateManager()
  21 + updateManager.onCheckForUpdate(function (res) {
  22 + // 请求完新版本信息的回调
  23 + })
  24 +
  25 + updateManager.onUpdateReady(function () {
  26 + wx.showModal({
  27 + title: '更新提示',
  28 + content: '新版本已经准备好,是否重启应用?',
  29 + success: function (res) {
  30 + if (res.confirm) {
  31 + // 新的版本已经下载好,调用 applyUpdate 应用新版本并重启
  32 + updateManager.applyUpdate()
  33 + }
  34 + }
  35 + })
  36 +
  37 + })
  38 +
  39 + updateManager.onUpdateFailed(function () {
  40 + // 新的版本下载失败
  41 + wx.showModal({
  42 + title: '更新提示',
  43 + content: '新版本下载失败',
  44 + showCancel: false
  45 + })
  46 + })
  47 + },
  48 + post: function (url, data, headerParams, showLoad) {
  49 + wx.showNavigationBarLoading()
  50 + var promise = new Promise((resolve, reject) => {
  51 + //init
  52 + let that = this;
  53 + let postData = data;
  54 + let baseUrl = 'https://ygzyshop.cn/api/';
  55 + //网络请求
  56 + let header = {
  57 + 'content-type': 'application/x-www-form-urlencoded'
  58 + }
  59 + header = Object.assign(header, headerParams)
  60 + //网络请求
  61 + wx.request({
  62 + url: baseUrl + url,
  63 + data: postData,
  64 + method: 'POST',
  65 + header: header,
  66 +
  67 + success: function (res) { //返回取得的数据
  68 + if (res.data.code == '20000') {
  69 + resolve(res.data);
  70 + } else if (res.data.code == '201') {
  71 + resolve(res.data);
  72 + }
  73 +
  74 + // else if (res.data.code == '10001') {
  75 + // wx.showToast({
  76 + // title: res.data.msg,
  77 + // icon: 'none',
  78 + // duration: 1000,
  79 + // success: function (res) {
  80 + // let t = setInterval(function () {
  81 + // clearInterval(t)
  82 + // wx.navigateTo({
  83 + // url: '/pages/index/index',
  84 + // })
  85 + // }, 1000)
  86 + // }
  87 + // })
  88 + // }
  89 +
  90 + else {
  91 + // wx.showModal({
  92 + // title: '提示',
  93 + // content: res.data.msg,
  94 + // showCancel: false
  95 + // })
  96 + reject(res.data)
  97 + }
  98 + setTimeout(function () {
  99 + // if (show||show==undefined){
  100 + // wx.hideLoading()
  101 + // }
  102 + wx.hideNavigationBarLoading()
  103 + }, 600)
  104 + },
  105 + fail: function (e) {
  106 + reject('网络出错');
  107 + // wx.hideLoading()
  108 + wx.hideNavigationBarLoading()
  109 + }
  110 + })
  111 + });
  112 + return promise;
  113 + },
  114 + pay(res, successData) {
  115 + wx.requestPayment({
  116 + "timeStamp": res.pay.timeStamp,
  117 + "nonceStr": res.pay.nonceStr,
  118 + "package": res.pay.package,
  119 + "signType": "MD5",
  120 + "paySign": res.pay.paySign,
  121 + "success": function (res) {
  122 + wx.showToast({
  123 + title: '支付完成',
  124 + icon: "success",
  125 + duration: 1500,
  126 + success: function (data) {
  127 + successData(data)
  128 + }
  129 + })
  130 + },
  131 + "fail": function (res) {
  132 + wx.showToast({
  133 + title: '取消支付成功!',
  134 + icon: "icon",
  135 + duration: 1500,
  136 + })
  137 + }
  138 + })
  139 + },
  140 +
  141 + // 上传图片
  142 + upload(filetype, file) {
  143 +
  144 + var promise = new Promise((resolve, reject) => {
  145 + wx.showNavigationBarLoading()
  146 + wx.showLoading({
  147 + title: '上传中',
  148 + })
  149 + let url = 'https://ygzyshop.cn/api/user/upload/one';
  150 + let head = {
  151 + 'XX-Token': wx.getStorageSync('token'),
  152 + 'XX-Device-Type': 'wxapp'
  153 + }
  154 + let typename = {
  155 + filetype: filetype
  156 + }
  157 + wx.uploadFile({
  158 + url: url, //仅为示例,非真实的接口地址
  159 + filePath: file,
  160 + name: 'file',
  161 + header: head,
  162 + formData: typename,
  163 + success: function (res) {
  164 + console.log('上传文件后', res)
  165 + let temdata = JSON.parse(res.data);
  166 + console.log(temdata)
  167 + let urlobj = {
  168 + url: temdata.data.url
  169 + //url: temdata.data.filepath
  170 + }
  171 + resolve(urlobj);
  172 + wx.hideNavigationBarLoading();
  173 + wx.hideLoading();
  174 + },
  175 + fail: function (res) {
  176 + reject('网络出错');
  177 + wx.hideNavigationBarLoading()
  178 + wx.hideLoading()
  179 + },
  180 + complete: () => {
  181 + wx.hideNavigationBarLoading()
  182 + wx.hideLoading()
  183 + },
  184 + })
  185 + });
  186 + return promise;
  187 + },
  188 +
  189 + nowDate() {
  190 + let date = new Date();
  191 + let month = date.getMonth() + 1;
  192 + let day = date.getDate();
  193 + return date.getFullYear() + '-' + (month > 9 ? month : ('0' + month)) + '-' + (day > 9 ? day : ('0' + day));
  194 + },
  195 + minDate() {
  196 + let date = new Date();
  197 + date.setDate(date.getDate() - 287);
  198 + let m = date.getMonth() + 1;
  199 + return date.getFullYear() + '-' + m + '-' + date.getDate();
  200 + },
  201 + timeFormate(timestamp, timeType) {
  202 + var timeStamp = timestamp.length == 13 ? timestamp : timestamp * 1000
  203 + var date = new Date(timeStamp); //时间戳为10位需*1000,时间戳为13位的话不需乘1000
  204 + var Y = date.getFullYear() + '-';
  205 + var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
  206 + var D = date.getDate() + ' ';
  207 + var h = date.getHours() + ':';
  208 + var m = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
  209 + var s = date.getSeconds();
  210 + if (timeType == 'YYMMDD') {
  211 + return Y + M + D;
  212 + } else {
  213 + return h + m;
  214 + }
  215 + },
  216 +
  217 + //接口管理
  218 + interface: {
  219 + historyDelete:'/home/index/historyDelete',//删除
  220 + shopClass:'/home/index/shopClass',//分类
  221 + shopPage:'/home/index/shopPage',//分页
  222 + history:'/home/index/history',//检索
  223 + index: '/home/index/index', //首页
  224 + login: '/wxapp/public/login', //小程序登录注册
  225 + getSessionKey: '/wxapp/public/getSessionKey', //获取sessionKey和openid
  226 + },
  227 + //全局变量
  228 + globalData: {
  229 + userInfo: null,
  230 + cid: null,
  231 + class_id: null,
  232 + navHeight: 0
  233 + }
  234 +})
  1 +{
  2 + "pages": [
  3 + "pages/index/index",
  4 + "pages/mine/eOrder/eOrder",
  5 + "pages/homeindex/homeindex",
  6 + "pages/kind/kind",
  7 + "pages/homeindex/search/search",
  8 + "pages/mine/mine",
  9 + "pages/kind/detail_1/detail_1",
  10 + "pages/kind/firm_order2/firm_order2",
  11 + "pages/kind/firm_order1/firm_order1",
  12 + "pages/kind/success/success",
  13 + "pages/mine/contactUs/contactUs",
  14 + "pages/mine/myOrder/myOrder",
  15 + "pages/mine/addr_2/addr_2",
  16 + "pages/mine/addr_1/addr_1",
  17 + "pages/logs/logs",
  18 + "pages/mine/collect/collect",
  19 + "pages/mine/addr_3/addr_3"
  20 + ],
  21 + "window": {
  22 + "backgroundTextStyle": "light",
  23 + "navigationBarBackgroundColor": "#fff",
  24 + "navigationBarTitleText": "壹万商城",
  25 + "navigationBarTextStyle": "black"
  26 + },
  27 + "tabBar": {
  28 + "selectedColor": "#6EAC3D",
  29 + "list": [
  30 + {
  31 + "pagePath": "pages/homeindex/homeindex",
  32 + "text": "首页",
  33 + "selectedColor": "#6EAC3D",
  34 + "iconPath": "img/01_nav@2x.png",
  35 + "selectedIconPath": "img/01_nav_fill@2x.png"
  36 + },
  37 + {
  38 + "pagePath": "pages/kind/kind",
  39 + "text": "分类",
  40 + "selectedColor": "#6EAC3D",
  41 + "iconPath": "img/02_nav@2x.png",
  42 + "selectedIconPath": "img/02_nav_fill@2x.png"
  43 + },
  44 + {
  45 + "pagePath": "pages/mine/mine",
  46 + "text": "我的",
  47 + "selectedColor": "#6EAC3D",
  48 + "iconPath": "img/03_nav@2x.png",
  49 + "selectedIconPath": "img/03_nav_fill@2x.png"
  50 + }
  51 + ]
  52 + },
  53 + "sitemapLocation": "sitemap.json"
  54 +}
  1 +/**app.wxss**/
  2 +/* .container {
  3 + height: 100%;
  4 + display: flex;
  5 + flex-direction: column;
  6 + align-items: center;
  7 + justify-content: space-between;
  8 + padding: 200rpx 0;
  9 + box-sizing: border-box;
  10 +} */
  11 +@font-face {font-family: "iconfont";
  12 + src: url('//at.alicdn.com/t/font_1185528_wr32c54axab.eot?t=1557483201237'); /* IE9 */
  13 + src: url('//at.alicdn.com/t/font_1185528_wr32c54axab.eot?t=1557483201237#iefix') format('embedded-opentype'), /* IE6-IE8 */
  14 + url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAO0AAsAAAAAB2wAAANlAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCCcAqCeIJVATYCJAMICwYABCAFhG0HLht5BsguMXZtEDOglrGa6sBqKxf3MTmw4ckjgmqs7NndJwB19eUJA+higVWi0EYRqjcmispHxUUo1q9vUpfKYRyjIIPk9z/LChJOuaxl2NoJeMKxDRDMVXBqmxCiSYlfwRtH1AiJzFwSddq1ml3XiJS6Pp1cW0FbINcAqC3RyNuahymXGyOHDeCgau1/Lqc3xecHymmOjUe9AOOtge6BUUCBFkhgHjeMXdASbxNoNMoFsxmXkgM0FOaiQNzk2EqgkTErDbWhXqit2FnEM1OfnqQvPA0+H/+pRD1JTWY2nL4cWwMifrlWgXKn2uEeQjKdE2wfGcuAQpyvdJ+kHKWXKWtU0yomgW3VBr/c/++JN/vDI4haZnUzGIbia5I40kutTqDA8fuAo0GvS+k9Z6B8Z9h8/Wxofq57fL05o3X6FJNXPfMHV4aYdPt1bO6c8H5npvt92zd75vPzPau3F9duzeXfA/MWU+2ohzp8M/EmNpjR4x5Cu+97BhZtB9y2dNS4+Pz4y8z6eCjLnP3zgD98PT+acc6s8JffJNZMTWdnbqp5v9Aqo2koqP6H3hqVuzZfuM6lgMYe3zk6RemZYc+x0g2e//bjrcLSG1/Eg2naLNfRPXPeHJrXiKNN1fKkoArbqqaZCcKBYc0E5YlLaWXB/w54q5Foeh/wCUtgORHxye/Rvj3vq/oT81Hdcpm9ddkGzwGBjbQu9fY2VRxM3lMqMptnvaHv1RpWAVTjydKP+Y61F76Pcn3+WK2An/8oCFYT6uYF6k/fE/wGSce2oslMXXoeMfIk91NBCSjkPlWmv9P7ofqee86Hej137q0zkkBWbxot5DLUaLISqVXvWNU0WhIP9zfpQiiL0oBFvQBCu3NIWn2DrN0TtJDvoEavn1CrPTI0uhjYiU1m45qWRlAlRTWwqhFy1TIptm1UK6zNQmytuJKkZQGVhwjPxaCnm0c+F4+kiEyxhq9jvSjFEBOZBMaB+5BYLINyIhOiauomoFQe5O6Oq57kVi2TAC0bCKQShdSAqjSCONVkpLDXndIqvD8LwqolVok08KqCeRCCx00OeXLj0QGNV0s78W7lEV4dlheKwiCMkJGA4oATEVtpGUhePU0IqUa5EQxIygVxR51wV7Xb8lrJ2+2BRqYhhdWalRsI1wIAAAAA') format('woff2'),
  15 + url('//at.alicdn.com/t/font_1185528_wr32c54axab.woff?t=1557483201237') format('woff'),
  16 + url('//at.alicdn.com/t/font_1185528_wr32c54axab.ttf?t=1557483201237') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
  17 + url('//at.alicdn.com/t/font_1185528_wr32c54axab.svg?t=1557483201237#iconfont') format('svg'); /* iOS 4.1- */
  18 +}
  19 +
  20 +.iconfont {
  21 + font-family: "iconfont" !important;
  22 + font-size: 16px;
  23 + font-style: normal;
  24 + -webkit-font-smoothing: antialiased;
  25 + -moz-osx-font-smoothing: grayscale;
  26 +}
  27 +
  28 +.icon-kefu:before {
  29 + content: "\e658";
  30 +}
  31 +
  32 +
  33 +.ping{
  34 + display:flex;
  35 + justify-content: center
  36 +}
  37 +.noorder{
  38 + width:270rpx;
  39 + height:270rpx;
  40 + font-size: 0;
  41 + margin:0 auto;
  42 +
  43 +
  44 +}
  45 +.noorder image{
  46 + width:100%;
  47 + height:100%;
  48 +}
  49 +.noordertitle{
  50 + color:#999999;
  51 + font-size: 26rpx;
  52 + text-align: center;
  53 + margin-top:20rpx
  54 +}
  1 +@font-face {font-family: "iconfont";
  2 + src: url('//at.alicdn.com/t/font_1179697_fbyb0ah1aok.eot?t=1557278553716'); /* IE9 */
  3 + src: url('//at.alicdn.com/t/font_1179697_fbyb0ah1aok.eot?t=1557278553716#iefix') format('embedded-opentype'), /* IE6-IE8 */
  4 + url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAKAAAsAAAAABigAAAI0AAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCCcAosRwE2AiQDCAsGAAQgBYRtBzYbcwUR1Yshsj9AJre6AwBJRxHkIEu13DMydnmg7MP5ASaFryABAAAAAOLhv/1Y9/0ZVJNq4lBNmmgik/DQNUFqhEgo0PEIq3GTJiDPRIKDAPTZwif+zWnqv0UmSIBkwuedk3vIK0M+R+lgqADB5lfWewAkApRyMQz5PJfTu10cyPxAue5BY02aNIB6cUCB7YlRZAUSesPYBS/wMYFKHcbEwuX9O5TL7FWB2E9BQ3khLMssVy6UNhzM4gZKlBdXx3tcR9+P78ajnEJJYjes7V04mPngFCT/dgMCIgR0vAQJY8jEVmN6RRJMlFSmsx6OVRt8+P8/cImj2gX76+zqatAGM8EHb6UABTwWpb960nSi9MCHF0d/nbOFmw8z4L+jtPpVMPl76v6lDB5f0ZL/zktdKF/PE7y/cmBPNtS2s8iasnG4ULrfpkqV+B/2N3qfamk5WT6Ua5ngLdOeISnXR2Z2DCWqTKBUuWlUGrV8vEqTU0nkCow4Awj1blGodYek3gOZ2TeUaPUTpeojodJOdGGVgTCTWkkLOTS/mCyv3nWLimtfKeyzrnl1JP6kuqUYDm1fzl3RSnWJLdtXGEU8+soLXoLnaJ4ZS+VMVtooUk5d55ve1FpeQMFKWsih+cVkefXBaFGVz79S2GddO7rqip9UtzQ5Dm0/gLwyrIO6HuWV7SuMIh595QUvwTyaZ8bSPC+TlTZOSJZT5wzyQw3t9qbl744BoMC2Hg/O7kROehXeG8vlFwAAAA==') format('woff2'),
  5 + url('//at.alicdn.com/t/font_1179697_fbyb0ah1aok.woff?t=1557278553716') format('woff'),
  6 + url('//at.alicdn.com/t/font_1179697_fbyb0ah1aok.ttf?t=1557278553716') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
  7 + url('//at.alicdn.com/t/font_1179697_fbyb0ah1aok.svg?t=1557278553716#iconfont') format('svg'); /* iOS 4.1- */
  8 +}
  9 +
  10 +.iconfont {
  11 + font-family: "iconfont" !important;
  12 + font-size: 16px;
  13 + font-style: normal;
  14 + -webkit-font-smoothing: antialiased;
  15 + -moz-osx-font-smoothing: grayscale;
  16 +}
  17 +
  18 +.icon-jiantou-copy:before {
  19 + content: "\e667";
  20 +}
  21 +
  22 +
  23 +
  24 +
  25 +
  26 +
  27 +
  28 +
  29 +
  30 +
  31 +
  32 +
  33 +
  34 +
  35 +
  36 +
  37 +
  38 +
  39 +
  40 +
  41 +
  42 +
  43 +
  44 +
  45 +
  46 +
  47 +
  48 +
  49 +
  50 +
  51 +
  52 +
  53 +
  54 +
  55 +
  56 +
  57 +/* 按钮样式 */
  58 +.clearshop{
  59 + width:212rpx;
  60 + height:61rpx;
  61 + background:rgba(21,39,109,1);
  62 + box-shadow:0rpx 0rpx 20rpx 0rpx rgba(4,0,0,0.2);
  63 + color:#fff;
  64 + font-size: 28rpx;
  65 + line-height:61rpx;
  66 + text-align: center;
  67 + border-top-left-radius: 16rpx;
  68 + border-bottom-right-radius: 16rpx;
  69 + margin:60rpx auto 0;
  70 +}
  71 +
  72 +/* 客服弹层 */
  73 +
  74 +.kefuregister{
  75 + width: 100%;
  76 + height: 100%;
  77 + background-color: rgba(0,0,0,0.5);
  78 + position:fixed;
  79 + left:0;
  80 + right:0;
  81 + z-index: 5;
  82 + }
  83 +.kefuwrap{
  84 + width:465rpx;
  85 + height:195rpx;
  86 + background: #ffffff;
  87 + border-radius: 10rpx;
  88 + position: absolute;
  89 + z-index: 6;
  90 + /*left:0.4rem;*/
  91 + /*top: 3rem;*/
  92 + top:50%;
  93 + left:50%;
  94 + transform: translate(-50%,-50%);
  95 +
  96 +
  97 +}
  98 +
  99 +.pohone{
  100 + width:300rpx;
  101 + margin:65rpx auto;
  102 + color:#15276D;
  103 + font-size: 36rpx;
  104 + text-align: center;
  105 + border-bottom:1rpx solid #15276D;
  106 +
  107 +}
  108 +.kefucancel{
  109 + text-align: center;
  110 + position: absolute;
  111 + top:112%;
  112 + left:0;
  113 + right:0;
  114 + /* transform: translate(112%,-50%); */
  115 + margin:0 auto;
  116 + z-index: 999;
  117 + color:#fff;
  118 + font-size: 60rpx !important;
  119 +}
  120 +/* 暂无数据 */
  121 +.nodata{
  122 + color:#999;
  123 + font-size: 26rpx;
  124 + text-align: center;
  125 + margin-top: 20rpx;
  126 +}
  127 +
  128 +/* 没有产品的提示 */
  129 +.quewrap{
  130 + width:465rpx;
  131 + height:245rpx;
  132 + background: #4c4c4c;
  133 + border-radius: 10rpx;
  134 + position: absolute;
  135 +
  136 + /*left:0.4rem;*/
  137 + /*top: 3rem;*/
  138 + top:50%;
  139 + left:50%;
  140 + transform: translate(-50%,-50%);
  141 + /* opacity: 0.8; */
  142 + z-index:999;
  143 + padding: 20rpx 30rpx;
  144 + box-sizing: border-box
  145 +
  146 +
  147 +}
  148 +.tishi{
  149 + color:#82a7f5;
  150 + font-size: 36rpx;
  151 + margin-left:14rpx;
  152 + margin-top:15rpx;
  153 +}
  154 +.product{
  155 + margin-left:14rpx;
  156 + color:#fff;
  157 + font-size: 30rpx;
  158 + margin-top:22rpx;
  159 +}

244.0 KB

534 字节

631 字节

562 字节

  1 +const app = getApp()
  2 +Page({
  3 +
  4 + /**
  5 + * 页面的初始数据
  6 + */
  7 + data: {
  8 + banner: [],
  9 + shop_class: [],
  10 + middle: '',
  11 + shop: [],
  12 + num: 1,
  13 + showModal: false,
  14 + class_id: '',
  15 + detailCon: {},
  16 + id: '',
  17 + keyword:'',
  18 + page: 2,
  19 + page_type: true
  20 + },
  21 +
  22 + //跳转
  23 + anxin(){
  24 + wx.navigateTo({
  25 + url: '/pages/mine/contactUs/contactUs?status='+2,
  26 + })
  27 + },
  28 +
  29 + youxuan(){
  30 + wx.navigateTo({
  31 + url: '/pages/mine/contactUs/contactUs?status=' + 3,
  32 + })
  33 + },
  34 + baozhang(){
  35 + wx.navigateTo({
  36 + url: '/pages/mine/contactUs/contactUs?status=' + 4,
  37 + })
  38 + },
  39 + look_category(e) {
  40 +
  41 + app.globalData.cid = e.currentTarget.dataset.index
  42 + app.globalData.class_id = e.currentTarget.dataset.class_id
  43 +
  44 + wx.switchTab({
  45 + url: '/pages/kind/kind'
  46 + })
  47 + this.get_info()
  48 + },
  49 + // 跳转页面
  50 + btn_name() {
  51 + wx.navigateTo({
  52 + url: '/pages/homeindex/search/search',
  53 + })
  54 + },
  55 + get_info() {
  56 + let that = this
  57 + let url = app.interface.index;
  58 + let header = {
  59 + 'XX-Device-Type': 'wxapp',
  60 + 'XX-Token': wx.getStorageSync('token')
  61 + }
  62 + let params = {
  63 + class_id: that.data.class_id
  64 + }
  65 +
  66 + app.post(url, params, header).then((res) => {
  67 + let newshop=res.data.shop;
  68 + for (var obj of newshop ){
  69 + obj.over=false
  70 + }
  71 + that.setData({
  72 + banner: res.data.banner,
  73 + shop_class: res.data.shop_class,
  74 + middle: res.data.middle,
  75 + shop: res.data.shop,
  76 + now_time: res.data.now_time,
  77 + // totalpae: res.last_page
  78 + })
  79 + that.countDown()
  80 +
  81 +
  82 +
  83 + }).catch((errMsg) => {})
  84 +
  85 + },
  86 +
  87 + m_close: function() {
  88 + this.setData({
  89 + showModal: false,
  90 + })
  91 + },
  92 + // 点击加减
  93 + bindMinus: function() {
  94 + var num = this.data.num;
  95 + if (num > 1) {
  96 + num--;
  97 + }
  98 + this.setData({
  99 + num: num,
  100 + });
  101 + },
  102 + // 点击加
  103 + bindPlus: function() {
  104 + var num = this.data.num;
  105 + num++;
  106 + this.setData({
  107 + num: num,
  108 + });
  109 + },
  110 +
  111 + shoptail(e) {
  112 + let id = e.currentTarget.dataset.shop_id;
  113 + wx.navigateTo({
  114 + url: '/pages/kind/detail_1/detail_1?id=' + id,
  115 + })
  116 + },
  117 + // 去团购
  118 + goFirm_order1(e) {
  119 + this.setData({
  120 +
  121 + })
  122 + wx.navigateTo({
  123 + url: '/pages/kind/firm_order1/firm_order1?id=' + e.currentTarget.dataset.id + "&&num=" + this.data.num,
  124 + })
  125 + },
  126 +
  127 + timeFormat(param) { //小于10的格式化函数
  128 + return param < 10 ? '0' + param : param;
  129 + },
  130 + //团购倒计时
  131 + countDown() {
  132 + let that = this
  133 + let objs = Object.assign([], that.data.shop)
  134 + let now_time = parseInt(new Date().getTime())
  135 +
  136 +
  137 + for (let obj of objs) {
  138 + let end_time = obj.end_time*1000
  139 + let open_time = obj.open_time*1000
  140 + if (now_time < open_time) {
  141 + //活动未开始
  142 + } else if (now_time > end_time) {
  143 + obj.over=true
  144 + //活动结束
  145 + } else {
  146 + let time = (end_time - now_time) / 1000;
  147 + let day = parseInt(time / (60 * 60 * 24));
  148 + let hou = parseInt(time % (60 * 60 * 24) / 3600);
  149 + let min = parseInt(time % (60 * 60 * 24) % 3600 / 60);
  150 + let sec = parseInt(time % (60 * 60 * 24) % 3600 % 60);
  151 +
  152 + obj.day = that.timeFormat(day),
  153 + obj.hou = that.timeFormat(hou),
  154 + obj.min = that.timeFormat(min),
  155 + obj.sec = that.timeFormat(sec)
  156 +
  157 + }
  158 + }
  159 +
  160 + that.setData({
  161 + shop: objs
  162 + })
  163 + setTimeout(that.countDown, 1000);
  164 + },
  165 + /**
  166 + * 生命周期函数--监听页面加载
  167 + */
  168 + onLoad: function(options) {
  169 + let that = this
  170 + that.get_info();
  171 +
  172 +
  173 + },
  174 +
  175 +
  176 + info() {
  177 + let that = this
  178 + let url = app.interface.shopPage
  179 + let header = {
  180 + 'XX-Device-Type': 'wxapp',
  181 + 'XX-Token': wx.getStorageSync('token')
  182 + }
  183 + let paramer = {
  184 + page: that.data.page,
  185 + type: 1
  186 + }
  187 +
  188 + app.post(url, paramer,header).then((res) => {
  189 + if (res.data.shop.length > 0){
  190 + wx.showLoading({
  191 + title: '加载中',
  192 + })
  193 + let t = setInterval((red)=>{
  194 + wx.hideLoading()
  195 + that.setData({
  196 + shop: that.data.shop.concat(res.data.shop),
  197 + page_type: true
  198 + })
  199 + },1000)
  200 +
  201 + } else{
  202 + that.setData({
  203 + page_type: false
  204 + })
  205 + wx.showToast({
  206 + title: '暂无更多数据',
  207 + icon: 'none',
  208 + duration: 1000
  209 + })
  210 +
  211 +
  212 + }
  213 +
  214 + }).catch((errMsg) => {
  215 +
  216 + })
  217 + },
  218 +
  219 + /**
  220 + * 生命周期函数--监听页面初次渲染完成
  221 + */
  222 + onReady: function() {
  223 +
  224 + },
  225 +
  226 + /**
  227 + * 生命周期函数--监听页面显示
  228 + */
  229 + onShow: function() {
  230 + let that = this
  231 + if (app.globalData.cid != null) {
  232 + that.setData({
  233 + currentTab: app.globalData.cid
  234 + })
  235 + }
  236 + that.get_info()
  237 + that.countDown()
  238 + },
  239 +
  240 + /**
  241 + * 生命周期函数--监听页面隐藏
  242 + */
  243 + onHide: function() {
  244 +
  245 + },
  246 +
  247 + /**
  248 + * 生命周期函数--监听页面卸载
  249 + */
  250 + onUnload: function() {
  251 +
  252 + },
  253 +
  254 + /**
  255 + * 页面相关事件处理函数--监听用户下拉动作
  256 + */
  257 + onPullDownRefresh: function() {
  258 +
  259 + },
  260 +
  261 + /**
  262 + * 页面上拉触底事件的处理函数
  263 + */
  264 + onReachBottom: function() {
  265 + let that=this
  266 + if(that.data.page_type == false){
  267 + return false
  268 + }
  269 + let page=that.data.page;
  270 + page++;
  271 + that.setData({
  272 + page:page
  273 + })
  274 + that.info()
  275 +
  276 + },
  277 +
  278 + /**
  279 + * 用户点击右上角分享
  280 + */
  281 + onShareAppMessage: function() {
  282 +
  283 + }
  284 +})
  1 +{
  2 + "navigationBarTitleText": "壹万商城",
  3 + "navigationBarBackgroundColor": "#6EAC3D",
  4 + "navigationBarTextStyle": "white"
  5 +}
  1 +<!--pages/homeindex/homeindex.wxml-->
  2 +<!-- <text>pages/homeindex/homeindex.wxml</text> -->
  3 +<view class="containerbox">
  4 +
  5 +<view class='search'>
  6 + <view class='search_inp' bindtap="btn_name">
  7 + <!-- <input type='text' bindtap="btn_name" placeholder='请输入商品名称'></input> -->
  8 + 请输入商品名称
  9 + <image src='../../img/search.png'></image>
  10 + </view>
  11 + <view class='search_txt' bindtap="btn_name">
  12 + 搜索
  13 + </view>
  14 +</view>
  15 +<view class='banner'>
  16 + <swiper indicator-dots="true" indicator-active-color="#fff" style="width:100%;height:100%;">
  17 + <swiper-item wx:for='{{banner}}' wx:key="index">
  18 + <image style="width: 688rpx;" mode='widthFix' src='{{item.img}}' />
  19 + </swiper-item>
  20 + </swiper>
  21 + <view class='banner_Mask'></view>
  22 +</view>
  23 +<view class='commodity'>
  24 + <!-- <navigator url=''>
  25 + </navigator> -->
  26 + <view class='jujia' wx:for='{{shop_class}}' wx:key="index" data-class_id="{{item.class_id}}" bindtap='look_category' data-index='{{index}}'>
  27 + <image src='{{item.img}}'></image>
  28 + <text>{{item.class_name}}</text>
  29 + </view>
  30 + <view class='fenlei' bindtap='look_category'>
  31 + <image src='../../img/fenlei@3x.png'></image>
  32 + <text>全部分类</text>
  33 + </view>
  34 +</view>
  35 +<view class='introduce'>
  36 + <view class='introduce_list'>
  37 + <view class='introduce_item' bindtap="anxin">
  38 + <image src='../../img/anquan@3x.png'></image>
  39 + <text>安心检测</text>
  40 + </view>
  41 + <view class='introduce_item' bindtap="youxuan">
  42 + <image src='../../img/youxuan@3x.png'></image>
  43 + <text>优选源头</text>
  44 + </view>
  45 + <view class='introduce_item' bindtap="baozhang">
  46 + <image src='../../img/baozhang@3x.png'></image>
  47 + <text>赔付保障</text>
  48 + </view>
  49 + </view>
  50 + <image src='{{middle}}'></image>
  51 +</view>
  52 +<view class='container'>
  53 + <view class='mid'>
  54 + <view class='ware_box' bindtap="shoptail" wx:for='{{shop}}' data-shop_id='{{item.shop_id}}' wx:key="index">
  55 + <view class='ware_top'>
  56 + <view class='ware_1'>
  57 + <image src='{{item.thumb}}'></image>
  58 + <view class='ware_1_over' wx:if="{{item.over}}">
  59 + 已结束
  60 + </view>
  61 +
  62 + <block wx:else>
  63 + <view class='ware_1_time' wx:if="{{item.percent==100}}">已成团</view>
  64 + <view class='ware_1_time' wx:else>
  65 + 距结束{{item.day}}天{{item.hou}}时{{item.min}}分{{item.sec}}秒
  66 + </view>
  67 +
  68 +
  69 +
  70 + </block>
  71 +
  72 + </view>
  73 + <view class='ware_text'>
  74 + <view class='ware_2'>
  75 + <text class='ware_2Txt1'>{{item.name}}</text>
  76 + <text class='ware_2Txt2'>产地:{{item.origin}}</text>
  77 + </view>
  78 + <view class='ware_3'>
  79 + <progress percent="{{item.percent}}" show-info color="#B5DE96" border-radius="8" font-size="24rpx" stroke-width="16rpx" />
  80 + </view>
  81 + <view class='ware_4'>
  82 + <text>现有{{item.numb}}份,目标{{item.group}}份</text>
  83 + </view>
  84 + <view class='ware_5'>
  85 + <view>
  86 + <text class='ware5_t1'>¥{{item.money_sale}}/</text>
  87 + <text class='ware5_t2'>{{item.shop_type}}</text>
  88 + </view>
  89 + <view class='ware5_box'>
  90 + <view class='ware5_t3'>{{item.text_table}}</view>
  91 + <view class='ware5_t4'>{{item.text_content}}</view>
  92 + </view>
  93 + <view class='ware_over'wx:if="{{item.over}}">
  94 + 已结束
  95 + </view>
  96 +
  97 + <view wx:else>
  98 + <view class='ware_6' wx:if="{{item.percent==100}}">
  99 + 已成团
  100 + </view>
  101 +
  102 + <view class='ware_6' wx:else>
  103 + 立即参团
  104 + </view>
  105 + </view>
  106 +
  107 +
  108 + </view>
  109 + </view>
  110 + </view>
  111 + <view class='ware_bot'>
  112 + <view class='ware_bot_tit'>经典推荐</view>
  113 + <view class='ware_bot_txt'>{{item.recommend}}</view>
  114 + </view>
  115 + </view>
  116 + </view>
  117 +</view>
  118 +<view class='Load'>—— {{page_type?'下拉加载更多':'暂无更多数据'}} ——</view>
  119 +
  120 +</view>
  121 +
  122 +
  123 +
  124 +<!-- 弹窗 -->
  125 +<view class="mask" catchtouchmove="preventTouchMove" wx:if="{{showModal}}"></view>
  126 +<!-- 弹出层 -->
  127 +<view class="modalDlg" wx:if="{{showModal}}">
  128 + <view class='modalDlg_p'>
  129 + <view class='m_top'>
  130 + <view class='m_topImg'>
  131 + <image src='{{shop[index].thumb}}'></image>
  132 + </view>
  133 + <view class='m_topTxt'>
  134 + <view class='m_topTxt1'>
  135 + <view class='m_topName'>{{shop[index].name}}</view>
  136 + <image bindtap='m_close' src='../../img/cha.png'></image>
  137 + </view>
  138 + <view class='m_topTxt2'>
  139 + <view class='m_topPrice'>¥{{shop[index].money_sale}}</view>
  140 + <view class='m_topHelf'>{{shop[index].shop_type}}</view>
  141 + </view>
  142 + </view>
  143 + </view>
  144 + <view class='m_number'>
  145 + <view class='m_numTxt'>购买数量</view>
  146 + <view class='minus_push'>
  147 + <view class='minus' bindtap="bindMinus">-</view>
  148 + <view class='num' bindchange="bindManual">{{num}}</view>
  149 + <view class='push' bindtap="bindPlus">+</view>
  150 + </view>
  151 + </view>
  152 + <button class='m_btn' bindtap='goFirm_order1' data-id="{{shop[index].shop_id}}">确认</button>
  153 + </view>
  154 +</view>
  1 +page{
  2 + overflow-x:hidden;
  3 + padding-bottom: 50rpx;
  4 +}
  5 +.containerbox{
  6 + overflow-x: hidden;
  7 +}
  8 +.search {
  9 + padding: 16rpx 32rpx;
  10 + height: 64rpx;
  11 + background: #6eac3d;
  12 + display: flex;
  13 + justify-content: center;
  14 + align-content: space-between;
  15 +}
  16 +
  17 +.search_inp {
  18 + box-sizing: border-box;
  19 + width: 570rpx;
  20 + height: 64rpx;
  21 + border-radius: 32rpx;
  22 + display: flex;
  23 + align-items: center;
  24 + padding-left: 76rpx;
  25 + padding-right: 32rpx;
  26 + background: #fff;
  27 + border: 0;
  28 + outline: none;
  29 + font-size: 26rpx;
  30 + position: relative;
  31 + color: #666;
  32 +}
  33 +
  34 +.search_inp input {
  35 + width: 100%;
  36 +}
  37 +
  38 +.search_inp image {
  39 + position: absolute;
  40 + left: 32rpx;
  41 + top: 17rpx;
  42 + width: 32rpx;
  43 + height: 32rpx;
  44 +}
  45 +
  46 +.search_txt {
  47 + height: 64rpx;
  48 + font-size: 30rpx;
  49 + color: #fff;
  50 + line-height: 64rpx;
  51 + padding-left: 16rpx;
  52 +}
  53 +
  54 +.banner {
  55 + width: 688rpx;
  56 + height: 336rpx;
  57 + margin: 0 auto;
  58 + margin-top: 48rpx;
  59 + position: relative;
  60 + border-radius: 8rpx;
  61 +}
  62 +
  63 +.swiper {
  64 + height: 100%;
  65 + position: absolute;
  66 + z-index: 99;
  67 +}
  68 +
  69 +.swiper-item {
  70 + width: 688rpx;
  71 + margin: 0 auto;
  72 + height: 336rpx;
  73 + border-radius: 8rpx;
  74 +}
  75 +
  76 +.swiper-item image {
  77 + height: auto;
  78 +}
  79 +
  80 +.banner_Mask {
  81 + width: 656rpx;
  82 + height: 336rpx;
  83 + background: rgba(181, 222, 150, 1);
  84 + box-shadow: 0rpx 6rpx 40rpx rgba(93, 255, 0, 0.44);
  85 + opacity: 0.3;
  86 + position: absolute;
  87 + bottom: 16rpx;
  88 + z-index: -1;
  89 + left: 16rpx;
  90 + border-radius: 8rpx;
  91 +}
  92 +
  93 +.commodity {
  94 + width: 688rpx;
  95 + /* margin: 0 auto; */
  96 + padding: 64rpx 32rpx;
  97 + display: flex;
  98 + justify-content: space-around;
  99 + align-items: center;
  100 + font-size: 24rpx;
  101 + color: #333;
  102 + border-bottom: 8px solid rgba(249, 250, 252, 1);
  103 +}
  104 +
  105 +.commodity view {
  106 +}
  107 +
  108 +.introduce_list {
  109 + display: flex;
  110 + justify-content: space-around;
  111 + align-items: center;
  112 + padding: 36rpx 32rpx 48rpx 32rpx;
  113 +}
  114 +
  115 +.introduce_list .introduce_item {
  116 + display: flex;
  117 + justify-content: space-between;
  118 + align-items: center;
  119 +}
  120 +
  121 +.introduce_list .introduce_item:first-child image {
  122 + width: 32rpx;
  123 + height: 36rpx;
  124 +}
  125 +
  126 +.introduce_list .introduce_item:nth-child(2) image {
  127 + width: 36rpx;
  128 + height: 31rpx;
  129 +}
  130 +
  131 +.introduce_list .introduce_item:nth-child(3) image {
  132 + width: 32rpx;
  133 + height: 29rpx;
  134 +}
  135 +
  136 +.introduce_list .introduce_item text {
  137 + font-size: 28rpx;
  138 + display: flex;
  139 + align-items: center;
  140 + margin-left: 16rpx;
  141 +}
  142 +
  143 +.introduce image {
  144 + width: 668rpx;
  145 + height: 208rpx;
  146 + display: block;
  147 + margin: 0 auto;
  148 +}
  149 +
  150 +.commodity .jujia image, .commodity .fenlei image {
  151 + width: 112rpx;
  152 + height: 112rpx;
  153 + margin: 0 auto;
  154 +}
  155 +
  156 +.commodity text {
  157 + display: flex;
  158 + margin-top: 14rpx;
  159 + text-align: center;
  160 + justify-content: center;
  161 + align-items: center;
  162 +}
  163 +
  164 +.container {
  165 + width: 750rpx;
  166 + display: flex;
  167 + align-items: center;
  168 + flex-flow: column;
  169 +}
  170 +
  171 +.mid {
  172 + margin-top: 16rpx;
  173 + display: flex;
  174 + flex-flow: column;
  175 +}
  176 +
  177 +.ware_box {
  178 + width: 688rpx;
  179 + margin: 32rpx auto;
  180 + background: #f9fafc;
  181 +}
  182 +.ware_box:last-child{
  183 + margin-bottom: 0;
  184 +}
  185 +.ware_top {
  186 + overflow: hidden;
  187 + display: flex;
  188 + padding: 32rpx 18rpx 0;
  189 +}
  190 +
  191 +.ware_1 {
  192 + width: 312rpx;
  193 + height: 208rpx;
  194 + position: relative;
  195 +}
  196 +
  197 +.ware_1 image {
  198 + width: 100%;
  199 + height: 100%;
  200 +}
  201 +
  202 +.ware_1_time {
  203 + position: absolute;
  204 + bottom: 0;
  205 + width: 208rpx;
  206 + height: 48rpx;
  207 + color: white;
  208 + text-align: center;
  209 + line-height: 48rpx;
  210 + font-size: 17rpx;
  211 + background: #fac8c8;
  212 + font-family: PingFang SC;
  213 +}
  214 +.ware_1_over{
  215 + position: absolute;
  216 + bottom: 0;
  217 + width: 208rpx;
  218 + height: 48rpx;
  219 + color: white;
  220 + text-align: center;
  221 + line-height: 48rpx;
  222 + font-size: 17rpx;
  223 + background: #ddd;
  224 + font-family: PingFang SC;
  225 +}
  226 +
  227 +.ware_text {
  228 + margin-left: 14rpx;
  229 + width: 100%;
  230 +}
  231 +
  232 +.ware_2 {
  233 + display: flex;
  234 + justify-content: space-between;
  235 + align-content: center;
  236 +}
  237 +
  238 +.ware_2Txt1 {
  239 + font-size: 32rpx;
  240 + font-family: PingFang SC;
  241 + font-weight: 600;
  242 + line-height: 44rpx;
  243 + color: rgba(51, 51, 51, 1);
  244 +}
  245 +
  246 +.ware_2Txt2 {
  247 + font-size: 22rpx;
  248 + /* margin-left:98rpx; */
  249 + font-family: PingFang SC;
  250 + font-weight: 400;
  251 + line-height: 32rpx;
  252 + color: rgba(204, 204, 204, 1);
  253 +}
  254 +
  255 +.ware_3 progress {
  256 + width: 370rpx;
  257 + color: #b5de96;
  258 + margin-top: 24rpx;
  259 +}
  260 +
  261 +.ware_4 text {
  262 + font-size: 22rpx;
  263 + font-family: PingFang SC;
  264 + font-weight: 400;
  265 + line-height: 32rpx;
  266 + color: rgba(204, 204, 204, 1);
  267 +}
  268 +
  269 +.ware5_t2 {
  270 + overflow: hidden;
  271 + text-overflow: ellipsis;
  272 + white-space: nowrap;
  273 + width: 70rpx;
  274 + display: inline-block;
  275 + font-size: 22rpx;
  276 + font-family: PingFang SC;
  277 + font-weight: 400;
  278 + line-height: 19rpx;
  279 + margin-left: 4rpx;
  280 + color: rgba(204, 204, 204, 1);
  281 +}
  282 +
  283 +.ware_5 {
  284 + display: flex;
  285 + display: -webkit-flex;
  286 + justify-content: space-between;
  287 +}
  288 +
  289 +.ware5_t1 {
  290 + width: 110rpx;
  291 + overflow: hidden;
  292 + text-overflow: ellipsis;
  293 + white-space: nowrap;
  294 + font-size: 26rpx;
  295 + font-family: DIN 1451 Std Mittelschrift;
  296 + font-weight: 400;
  297 + color: rgba(255, 0, 0, 1);
  298 +}
  299 +
  300 +.ware5_t3 {
  301 + width: 104rpx;
  302 + overflow: hidden;
  303 + text-overflow: ellipsis;
  304 + white-space: nowrap;
  305 + font-size: 20rpx;
  306 + font-family: PingFang SC;
  307 + font-weight: 400;
  308 + line-height: 30rpx;
  309 + color: rgba(51, 51, 51, 1);
  310 +}
  311 +
  312 +.ware5_t4 {
  313 + font-size: 18rpx;
  314 + font-family: PingFang SC;
  315 + font-weight: 400;
  316 + color: rgba(153, 153, 153, 1);
  317 +}
  318 +
  319 +.ware_6 {
  320 + width: 144rpx;
  321 + height: 48rpx;
  322 + background: rgba(249, 150, 20, 1);
  323 + box-shadow: 0px 2rpx 12rpx rgba(255, 145, 0, 0.16);
  324 + border-radius: 24rpx;
  325 + font-size: 26rpx;
  326 + font-family: PingFang SC;
  327 + font-weight: 400;
  328 + text-align: center;
  329 + line-height: 48rpx;
  330 + color: rgba(255, 255, 255, 1);
  331 +}
  332 +.ware_over{
  333 + width: 144rpx;
  334 + height: 48rpx;
  335 + background: #999;
  336 + box-shadow: 0px 2rpx 12rpx rgba(255, 145, 0, 0.16);
  337 + border-radius: 24rpx;
  338 + font-size: 26rpx;
  339 + font-family: PingFang SC;
  340 + font-weight: 400;
  341 + text-align: center;
  342 + line-height: 48rpx;
  343 + color: rgba(255, 255, 255, 1);
  344 +}
  345 +
  346 +/* .ware_6 view {
  347 + font-size: 26rpx;
  348 + font-family: PingFang SC;
  349 + font-weight: 400;
  350 + text-align: center;
  351 + line-height: 48rpx;
  352 + color: rgba(255, 255, 255, 1);
  353 +} */
  354 +
  355 +.ware_bot {
  356 + width: 670rpx;
  357 + height: 80rpx;
  358 + margin: auto;
  359 + display: flex;
  360 + line-height: 80rpx;
  361 + margin-top: 32rpx;
  362 + background-color: #f1f7f1;
  363 +}
  364 +
  365 +.ware_bot_tit {
  366 + font-size: 30rpx;
  367 + font-weight: bold;
  368 + margin-left: 32rpx;
  369 + color: rgba(110, 172, 61, 1);
  370 +}
  371 +
  372 +.ware_bot_tit:after {
  373 + content: "";
  374 + margin: 0 38rpx;
  375 + border-right: 1px solid #b5de96;
  376 +}
  377 +
  378 +.ware_bot_txt {
  379 + font-size: 24rpx;
  380 + font-family: PingFang SC;
  381 + font-weight: 400;
  382 + color: rgba(153, 153, 153, 1);
  383 +}
  384 +
  385 +/* 规格 */
  386 +
  387 +.spec {
  388 + width: 100%;
  389 + padding: 0 32rpx;
  390 + line-height: 80rpx;
  391 + display: flex;
  392 + height: 80rpx;
  393 + margin-top: 8rpx;
  394 + background: white;
  395 +}
  396 +
  397 +.spec_txt {
  398 + font-size: 32rpx;
  399 + font-family: PingFang SC;
  400 + font-weight: 400;
  401 + color: rgba(51, 51, 51, 1);
  402 +}
  403 +
  404 +.spec_txt2 {
  405 + font-size: 24rpx;
  406 + font-family: PingFang SC;
  407 + font-weight: 400;
  408 + margin-left: 108rpx;
  409 + color: rgba(153, 153, 153, 1);
  410 +}
  411 +
  412 +/* 商品详情 */
  413 +
  414 +.ware_detail {
  415 + width: 100%;
  416 + margin-top: 8rpx;
  417 + margin-bottom: 96rpx;
  418 + padding-bottom: 66rpx;
  419 + background: white;
  420 +}
  421 +
  422 +.ware_detail_tit {
  423 + width: 688rpx;
  424 + margin: auto;
  425 + display: flex;
  426 + padding: 44rpx 0rpx 42rpx;
  427 + justify-content: space-around;
  428 + border-bottom: 2rpx solid #f5f5f5;
  429 +}
  430 +
  431 +.ware_detail .ware_active {
  432 + color: #6eac3d;
  433 + font-weight: 600;
  434 +}
  435 +
  436 +.ware_active:after {
  437 + content: "";
  438 + width: 16rpx;
  439 + height: 6rpx;
  440 + margin: auto;
  441 + display: block;
  442 + margin-top: 6rpx;
  443 + border-radius: 8rpx;
  444 + background: rgba(110, 172, 61, 1);
  445 +}
  446 +
  447 +.ware_detail_tit view {
  448 + font-size: 28rpx;
  449 + font-family: PingFang SC;
  450 + font-weight: 400;
  451 + color: rgba(153, 153, 153, 1);
  452 +}
  453 +
  454 +.ware_detailC {
  455 + width: 688rpx;
  456 + margin: 26rpx auto 0;
  457 +}
  458 +
  459 +.ware_detailImg {
  460 + width: 688rpx;
  461 + height: 470rpx;
  462 +}
  463 +
  464 +.ware_detailImg image {
  465 + width: 100%;
  466 + height: 100%;
  467 +}
  468 +
  469 +/* 遮罩层 */
  470 +
  471 +.mask {
  472 + width: 100%;
  473 + height: 100%;
  474 + position: fixed;
  475 + top: 0;
  476 + left: 0;
  477 + background: #000;
  478 + z-index: 9000;
  479 + opacity: 0.64;
  480 +}
  481 +
  482 +/* 弹出层 */
  483 +
  484 +.modalDlg {
  485 + width: 100%;
  486 + height: 454rpx;
  487 + bottom: 0;
  488 + position: fixed;
  489 + z-index: 9999;
  490 + background-color: #fff;
  491 +}
  492 +
  493 +.modalDlg_p {
  494 + padding: 0 30rpx;
  495 +}
  496 +
  497 +.m_top {
  498 + display: flex;
  499 +}
  500 +
  501 +.m_topTxt1 {
  502 + display: flex;
  503 + align-self: center;
  504 + justify-content: space-between;
  505 + margin-top: 30rpx;
  506 +}
  507 +
  508 +.m_topTxt {
  509 + width: 100%;
  510 + margin-left: 16rpx;
  511 +}
  512 +
  513 +.m_topImg {
  514 + margin-top: -48rpx;
  515 + display: flex;
  516 +}
  517 +
  518 +.m_topImg image {
  519 + width: 208rpx;
  520 + height: 208rpx;
  521 +}
  522 +
  523 +.m_topTxt1 image {
  524 + width: 32rpx;
  525 + height: 32rpx;
  526 +}
  527 +
  528 +.m_topName {
  529 + font-size: 32rpx;
  530 + font-family: PingFang SC;
  531 + font-weight: 600;
  532 + color: rgba(51, 51, 51, 1);
  533 +}
  534 +
  535 +.m_topTxt2 {
  536 + display: flex;
  537 + margin-top: 16rpx;
  538 + align-items: center;
  539 +}
  540 +
  541 +.m_topPrice {
  542 + width: 120rpx;
  543 + overflow: hidden;
  544 + text-overflow: ellipsis;
  545 + white-space: nowrap;
  546 + font-size: 28rpx;
  547 + font-family: DIN 1451 Std Mittelschrift;
  548 + font-weight: 400;
  549 + color: #f00;
  550 +}
  551 +
  552 +.m_topHelf {
  553 + width: 280rpx;
  554 + overflow: hidden;
  555 + text-overflow: ellipsis;
  556 + white-space: nowrap;
  557 + font-size: 22rpx;
  558 + font-family: PingFang SC;
  559 + font-weight: 400;
  560 + margin-left: 16rpx;
  561 + color: rgba(204, 204, 204, 1);
  562 +}
  563 +
  564 +.m_number {
  565 + display: flex;
  566 + align-items: center;
  567 + margin-top: 18rpx;
  568 +}
  569 +
  570 +.minus_push {
  571 + display: flex;
  572 + margin-left: auto;
  573 + align-items: center;
  574 +}
  575 +
  576 +.m_numTxt {
  577 + font-size: 24rpx;
  578 + font-family: PingFang SC;
  579 + font-weight: 400;
  580 + color: rgba(153, 153, 153, 1);
  581 +}
  582 +
  583 +.minus, .push {
  584 + width: 48rpx;
  585 + height: 48rpx;
  586 + font-size: 40rpx;
  587 + text-align: center;
  588 + line-height: 48rpx;
  589 + border: 2px solid rgba(110, 172, 61, 1);
  590 + border-radius: 50%;
  591 +}
  592 +
  593 +.minus {
  594 + color: #6eac3d;
  595 +}
  596 +
  597 +.num {
  598 + margin: 0 26rpx;
  599 + font-size: 32rpx;
  600 + font-family: PingFang SC;
  601 + font-weight: 400;
  602 + color: rgba(110, 172, 61, 1);
  603 +}
  604 +
  605 +.push {
  606 + color: white;
  607 + background: rgba(110, 172, 61, 1);
  608 +}
  609 +
  610 +.m_btn {
  611 + width: 688rpx;
  612 + height: 80rpx;
  613 + border: 0;
  614 + margin-top: 62rpx;
  615 + font-size: 32rpx;
  616 + font-family: PingFang SC;
  617 + font-weight: 600;
  618 + color: rgba(255, 255, 255, 1);
  619 + background: linear-gradient(170deg, rgba(181, 222, 150, 1) 0%, rgba(169, 209, 33, 1) 100%);
  620 + box-shadow: 0rpx 6rpx 40rpx rgba(162, 255, 0, 0.15);
  621 + border-radius: 48rpx;
  622 +}
  623 +.Load{
  624 + width: 100%;
  625 + text-align: center;
  626 + color: #aaa;
  627 + font-size: 26rpx;
  628 + margin-top: 50rpx;
  629 +}
  1 +// pages/homeindex/search/search.js
  2 +const app = getApp()
  3 +Page({
  4 +
  5 + /**
  6 + * 页面的初始数据
  7 + */
  8 + data: {
  9 + recommend: [],
  10 + history: [],
  11 + keyword: '',
  12 + page: '',
  13 + type: true,
  14 + dis:true
  15 +
  16 + },
  17 +
  18 + /**
  19 + * 生命周期函数--监听页面加载
  20 + */
  21 + onLoad: function(options) {
  22 + let that = this
  23 + that.get_info()
  24 + },
  25 + enter(){
  26 + this.setData({
  27 + type: true
  28 + })
  29 + },
  30 + bindKeyInput:function(e){
  31 + console.log(e.detail.value)
  32 + this.setData({
  33 + keyword: e.detail.value,
  34 +
  35 + })
  36 + },
  37 + get_info() {
  38 + let that = this
  39 + // 接口地址
  40 + let url = app.interface.history
  41 + let header = {
  42 + 'XX-Device-Type': 'wxapp',
  43 + 'XX-Token': wx.getStorageSync('token')
  44 + }
  45 +
  46 + app.post(url, {}, header).then((res) => {
  47 + console.log(res)
  48 + that.setData({
  49 + recommend: res.data.recommend,
  50 + history: res.data.history
  51 + })
  52 + that.countDown()
  53 +
  54 + }).catch((errMsg) => {
  55 +
  56 + })
  57 +
  58 + },
  59 + exchange(e){
  60 + let keyword=this.data.keyword
  61 + console.log(e)
  62 + this.setData({
  63 + keyword: e.currentTarget.dataset.word,
  64 + type:true
  65 + })
  66 +
  67 + this.secobdsearch()
  68 + },
  69 +
  70 + info(event) {
  71 + let that = this
  72 + that.setData({
  73 + type:false
  74 + })
  75 + if (that.data.keyword == '') {
  76 + wx.showToast({
  77 + title: '商品名称不能为空',
  78 + icon: 'none',
  79 + duration: 1000
  80 + })
  81 + return false
  82 + }
  83 + // 接口地址
  84 + let url = app.interface.shopPage
  85 + let header = {
  86 + 'XX-Device-Type': 'wxapp',
  87 + 'XX-Token': wx.getStorageSync('token')
  88 + }
  89 +
  90 +
  91 + let keyword = this.data.keyword
  92 +
  93 + app.post(url, {
  94 + page: 1,
  95 + keyword: keyword
  96 + },header).then((res) => {
  97 + console.log
  98 + that.setData({
  99 + shop: res.data.shop,
  100 + // type:false,
  101 + dis: false,
  102 + // keyword: '',
  103 + shop: that.data.shop.concat(res.data.shop)
  104 + })
  105 + that.get_info()
  106 + }).catch((errMsg) => {
  107 +
  108 + })
  109 + },
  110 + //二次搜索
  111 + secobdsearch(){
  112 + let that=this;
  113 + let url = app.interface.shopPage
  114 + let header = {
  115 + 'XX-Device-Type': 'wxapp',
  116 + 'XX-Token': wx.getStorageSync('token')
  117 + }
  118 +
  119 +
  120 + let keyword = this.data.keyword
  121 +
  122 + app.post(url, {
  123 + page: 1,
  124 + keyword: keyword
  125 + }, header).then((res) => {
  126 + console.log
  127 + that.setData({
  128 + shop: res.data.shop,
  129 + // type: false,
  130 + dis: false,
  131 + // keyword: '',
  132 + shop: that.data.shop.concat(res.data.shop)
  133 + })
  134 + that.get_info()
  135 + }).catch((errMsg) => {
  136 +
  137 + })
  138 + },
  139 + cansle(){
  140 + console.log(111)
  141 + this.setData({
  142 + type:true,
  143 + dis: true
  144 + })
  145 + },
  146 + display() {
  147 + this.setData({
  148 + dis: false
  149 + })
  150 + },
  151 + clear(){
  152 + let that =this
  153 + wx.showModal({
  154 + title: '提示',
  155 + content: '确认删除全部历史记录',
  156 + success(res) {
  157 + if (res.confirm) {
  158 + console.log('用户点击确定')
  159 + let url = app.interface.historyDelete
  160 + let header = {
  161 + 'XX-Device-Type': 'wxapp',
  162 + 'XX-Token': wx.getStorageSync('token')
  163 + }
  164 + app.post(url, {}, header).then((res) => {
  165 +
  166 +
  167 + that.setData({
  168 + history: []
  169 + })
  170 +
  171 +
  172 + console.log(111)
  173 +
  174 + }).catch((errMsg) => {
  175 +
  176 + })
  177 + } else if (res.cancel) {
  178 + console.log('用户点击取消')
  179 + }
  180 + }
  181 + })
  182 +
  183 +
  184 +
  185 +
  186 + },
  187 + timeFormat(param) { //小于10的格式化函数
  188 + return param < 10 ? '0' + param : param;
  189 + },
  190 + shoptail(e) {
  191 + let id = e.currentTarget.dataset.shop_id;
  192 + wx.navigateTo({
  193 + url: '/pages/kind/detail_1/detail_1?id=' + id,
  194 + })
  195 + },
  196 + //团购倒计时
  197 + countDown() {
  198 + let that = this
  199 + let objs = Object.assign([], that.data.shop)
  200 + let now_time = parseInt(new Date().getTime())
  201 + // console.log(now_time)
  202 +
  203 + for (let obj of objs) {
  204 +
  205 + let end_time = obj.end_time*1000
  206 + // console.log(end_time)
  207 + let open_time = obj.open_time*1000
  208 + if (now_time < open_time) {
  209 + // console.log(333)
  210 + //活动未开始
  211 + } else if (now_time > end_time) {
  212 + // console.log(222)
  213 + //活动结束
  214 + } else {
  215 + // console.log(1111)
  216 + let time = (end_time - now_time) / 1000;
  217 + let day = parseInt(time / (60 * 60 * 24));
  218 + let hou = parseInt(time % (60 * 60 * 24) / 3600);
  219 + let min = parseInt(time % (60 * 60 * 24) % 3600 / 60);
  220 + let sec = parseInt(time % (60 * 60 * 24) % 3600 % 60);
  221 +
  222 + obj.day = that.timeFormat(day),
  223 + obj.hou = that.timeFormat(hou),
  224 + obj.min = that.timeFormat(min),
  225 + obj.sec = that.timeFormat(sec)
  226 +
  227 + // console.log(obj.day, obj.hou, obj.min, obj.sec)
  228 + }
  229 + }
  230 + that.setData({
  231 + shop: objs
  232 + })
  233 + // console.log(that.data.shop)
  234 + setTimeout(that.countDown, 1000);
  235 + },
  236 + timeFormat(param) { //小于10的格式化函数
  237 + return param < 10 ? '0' + param : param;
  238 + },
  239 +
  240 + add(){
  241 +
  242 + },
  243 + /**
  244 + * 生命周期函数--监听页面初次渲染完成
  245 + */
  246 + onReady: function() {
  247 +
  248 + },
  249 +
  250 + /**
  251 + * 生命周期函数--监听页面显示
  252 + */
  253 + onShow: function() {
  254 + this.countDown()
  255 +
  256 + },
  257 +
  258 + /**
  259 + * 生命周期函数--监听页面隐藏
  260 + */
  261 + onHide: function() {
  262 +
  263 + },
  264 +
  265 + /**
  266 + * 生命周期函数--监听页面卸载
  267 + */
  268 + onUnload: function() {
  269 +
  270 + },
  271 +
  272 + /**
  273 + * 页面相关事件处理函数--监听用户下拉动作
  274 + */
  275 + onPullDownRefresh: function() {
  276 +
  277 + },
  278 +
  279 + /**
  280 + * 页面上拉触底事件的处理函数
  281 + */
  282 + onReachBottom: function() {
  283 + let that = this;
  284 + let page = that.data.page;
  285 +
  286 + page++;
  287 + that.setData({
  288 + page: page
  289 + })
  290 + that.info()
  291 + },
  292 +
  293 + /**
  294 + * 用户点击右上角分享
  295 + */
  296 + onShareAppMessage: function() {
  297 +
  298 + }
  299 +})
  1 +{
  2 + "navigationBarTitleText": "",
  3 + "navigationBarBackgroundColor": "#6EAC3D",
  4 + "navigationBarTextStyle": "white"
  5 +}
  1 +<!--pages/homeindex/search/search.wxml-->
  2 +<!-- <text>pages/homeindex/search/search.wxml</text> -->
  3 +<view class='search'>
  4 + <view class='search_inp'>
  5 + <input type='text' placeholder='请输入商品名称' maxlength='12' bindinput='bindKeyInput' value='{{keyword}}' bindfocus="enter"></input>
  6 + <image src='../../../img/search.png'></image>
  7 + </view>
  8 + <view class='search_txt' bindtap='info' wx:if='{{type}}'>
  9 + 搜索
  10 + </view>
  11 + <view class='search_txt' bindtap='cansle' wx:else>
  12 + 取消
  13 + </view>
  14 +</view>
  15 +<view class='Popular' wx:if='{{dis}}'>
  16 + <view class='Popular_title'>
  17 + <text>热门搜索</text>
  18 + <image src='../../../img/zuire@3x.png'></image>
  19 + </view>
  20 + <view class='Popular_list' >
  21 + <view class='Popular_item' bindtap='exchange' data-word='{{recommend[index]}}' wx:for='{{recommend}}' wx:key>
  22 + {{recommend[index]}}
  23 + </view>
  24 +
  25 + </view>
  26 + <view class='History' wx:if='{{history.length > 0}}'>
  27 + <view class='History_title'>历史搜索
  28 + <image src='../../../img/del.png' bindtap='clear'></image>
  29 + </view>
  30 + <view class='History_list'>
  31 + <view class='History_item' bindtap='exchange' wx:for='{{history}}' wx:key>{{history[index]}}</view>
  32 + </view>
  33 + </view>
  34 +</view>
  35 +<view class='container' bindtap='display' wx:else>
  36 + <view class='mid'>
  37 + <view class='ware_box' wx:for='{{shop}}' bindtap="shoptail" data-shop_id='{{item.shop_id}}' wx:key="index">
  38 + <view class='ware_top'>
  39 + <view class='ware_1'>
  40 + <image src='{{item.thumb}}'></image>
  41 + <view class='ware_1_time'>
  42 + 据结束{{item.day}}天{{item.hou}}时{{item.min}}分{{item.sec}}秒
  43 + </view>
  44 + </view>
  45 + <view class='ware_text'>
  46 + <view class='ware_2'>
  47 + <text class='ware_2Txt1'>{{item.name}}</text>
  48 + <text class='ware_2Txt2'>{{item.origin}}</text>
  49 + </view>
  50 + <view class='ware_3'>
  51 + <progress percent="{{item.percent}}" show-info color="#B5DE96" border-radius="8" font-size="24rpx" stroke-width="16rpx" />
  52 + </view>
  53 + <view class='ware_4'>
  54 + <text>现有{{item.numb}}份,目标{{item.group}}份</text>
  55 + </view>
  56 + <view class='ware_5'>
  57 + <view>
  58 + <text class='ware5_t1'>{{item.money_sale}}</text>
  59 + <text class='ware5_t2'>{{item.shop_type}}</text>
  60 + </view>
  61 + <view class='ware5_box'>
  62 + <view class='ware5_t3'>{{item.text_table}}</view>
  63 + <view class='ware5_t4'>{{item.text_content}}</view>
  64 + </view>
  65 + <view class='ware_6'>
  66 + <view>立即参团</view>
  67 + </view>
  68 + </view>
  69 + </view>
  70 + </view>
  71 + <view class='ware_bot'>
  72 + <view class='ware_bot_tit'>经典推荐</view>
  73 + <view class='ware_bot_txt'>{{item.recommend}}</view>
  74 + </view>
  75 + </view>
  76 +
  77 + </view>
  78 + <view class='empty' wx:if="{{shop.length == 0}}">暂无更多结果</view>
  79 +
  80 +
  81 +</view>
  82 +<!-- 弹窗 -->
  83 +<view class="mask" catchtouchmove="preventTouchMove" wx:if="{{showModal}}"></view>
  84 +<!-- 弹出层 -->
  85 +<view class="modalDlg" wx:if="{{showModal}}">
  86 + <view class='modalDlg_p'>
  87 + <view class='m_top'>
  88 + <view class='m_topImg'>
  89 + <image src='{{shop[index].thumb}}'></image>
  90 + </view>
  91 + <view class='m_topTxt'>
  92 + <view class='m_topTxt1'>
  93 + <view class='m_topName'>{{shop[index].name}}</view>
  94 + <image bindtap='m_close' src='../../img/cha.png'></image>
  95 + </view>
  96 + <view class='m_topTxt2'>
  97 + <view class='m_topPrice'>¥{{shop[index].money_sale}}</view>
  98 + <view class='m_topHelf'>{{shop[index].shop_type}}</view>
  99 + </view>
  100 + </view>
  101 + </view>
  102 + <view class='m_number'>
  103 + <view class='m_numTxt'>购买数量</view>
  104 + <view class='minus_push'>
  105 + <view class='minus' bindtap="bindMinus">-</view>
  106 + <view class='num' bindchange="bindManual">{{num}}</view>
  107 + <view class='push' bindtap="bindPlus">+</view>
  108 + </view>
  109 + </view>
  110 + <button class='m_btn' bindtap='goFirm_order1' data-id="{{shop[index].shop_id}}">确认</button>
  111 + </view>
  112 +</view>
  1 +/* pages/homeindex/search/search.wxss */
  2 +.search{
  3 + padding: 16rpx 32rpx;
  4 + height: 64rpx;
  5 + background: #6EAC3D;
  6 + display: flex;
  7 + justify-content: center;
  8 + align-content: space-between;
  9 +}
  10 +.search_inp{
  11 + box-sizing: border-box;
  12 + width: 570rpx;
  13 + height: 64rpx;
  14 + border-radius: 32rpx;
  15 + display:flex;
  16 + align-items: center;
  17 + padding-left: 76rpx;
  18 + padding-right: 32rpx;
  19 + background:#fff;
  20 + border: 0;
  21 + outline: none;
  22 + font-size: 26rpx;
  23 + position: relative;
  24 +}
  25 +.search_inp input{
  26 + width: 100%;
  27 +}
  28 +.search_inp image{
  29 + position: absolute;
  30 + left: 32rpx;
  31 + width: 32rpx;
  32 + height: 32rpx;
  33 +}
  34 +.search_txt{
  35 + height: 64rpx;
  36 + font-size: 30rpx;
  37 + color: #fff;
  38 + line-height: 64rpx;
  39 + padding-left: 16rpx;
  40 +}
  41 +.Popular{
  42 + padding: 32rpx;
  43 + padding-bottom: 0rpx;
  44 +
  45 +}
  46 +.Popular_title{
  47 + display: flex;
  48 + align-items: center;
  49 + font-size: 26rpx;
  50 + color: #333;
  51 + font-weight: 400;
  52 +}
  53 +.Popular_title text{
  54 + margin-right: 12rpx;
  55 +}
  56 +.Popular image{
  57 + width: 28rpx;
  58 + height: 32rpx;
  59 +}
  60 +.Popular_list{
  61 + display: flex;
  62 + justify-content: flex-start;
  63 + flex-wrap: wrap;
  64 + align-items: center;
  65 + margin-top: 28rpx;
  66 + padding-bottom: 16rpx;
  67 + border-bottom: 1rpx solid #F5F5F5;
  68 +}
  69 +.Popular_item,.History_item{
  70 + padding: 8rpx 26rpx;
  71 + border-radius: 24rpx;
  72 + background:rgba(247,247,247,1);
  73 + font-size: 26rpx;
  74 + margin-bottom: 16rpx;
  75 + margin-right: 16rpx;
  76 +}
  77 +.History{
  78 + margin-top: 30rpx;
  79 +}
  80 +.History_title{
  81 + font-size: 26rpx;
  82 + display: flex;
  83 + justify-content: space-between;
  84 + align-items: center;
  85 + color: #333;
  86 + font-weight: 400;
  87 + padding-bottom: 28rpx;
  88 +}
  89 +.History_title img{
  90 + width: 32rpx;
  91 + height: 32rpx;
  92 +}
  93 +.History_list{
  94 + display: flex;
  95 + justify-content: flex-start;
  96 + flex-wrap: wrap;
  97 + align-items: center;
  98 +
  99 +}
  100 +.container{
  101 + width: 750rpx;
  102 + display: flex;
  103 + align-items: center;
  104 + flex-flow: column;
  105 +}
  106 +.mid{
  107 + margin-top: 16rpx;
  108 + display: flex;
  109 + flex-flow: column;
  110 +}
  111 +.ware_box{
  112 + width:688rpx;
  113 + height:400rpx;
  114 + margin:32rpx auto;
  115 + background:#F9FAFC;
  116 +}
  117 +.ware_top{
  118 + overflow: hidden;
  119 + display: flex;
  120 + padding:32rpx 18rpx 0;
  121 +}
  122 +.ware_1{
  123 + width:312rpx;
  124 + height:208rpx;
  125 + position: relative;
  126 +}
  127 +.ware_1 image{
  128 + width:100%;
  129 + height:100%;
  130 +}
  131 +.ware_1_time{
  132 + position: absolute;
  133 + bottom:0;
  134 + width:208rpx;
  135 + height:48rpx;
  136 + color: white;
  137 + text-align: center;
  138 + line-height:48rpx;
  139 + font-size:18rpx;
  140 + background:#FAC8C8;
  141 + font-family:PingFang SC;
  142 +}
  143 +.ware_text{
  144 + margin-left:14rpx;
  145 + width:100%;
  146 +}
  147 +.ware_2{
  148 + display: flex;
  149 + justify-content: space-between;
  150 + align-content: center;
  151 +}
  152 +.ware_2Txt1{
  153 + font-size:32rpx;
  154 + font-family:PingFang SC;
  155 + font-weight:600;
  156 + line-height:44rpx;
  157 + color:rgba(51,51,51,1);
  158 +}
  159 +.ware_2Txt2{
  160 + font-size:22rpx;
  161 + /* margin-left:98rpx; */
  162 + font-family:PingFang SC;
  163 + font-weight:400;
  164 + line-height:32rpx;
  165 + color:rgba(204,204,204,1);
  166 +}
  167 +.ware_3 progress{
  168 + width:370rpx;
  169 + color:#B5DE96;
  170 + margin-top:24rpx;
  171 +}
  172 +.ware_4 text,.ware5_t2{
  173 + font-size:18rpx;
  174 + font-family:PingFang SC;
  175 + font-weight:400;
  176 + line-height:32rpx;
  177 + color:rgba(204,204,204,1);
  178 +}
  179 +.ware_5{
  180 + display: flex;
  181 + display: -webkit-flex;
  182 + justify-content: space-between;
  183 +}
  184 +.ware5_t1{
  185 + font-size:30rpx;
  186 + font-family:DIN 1451 Std Mittelschrift;
  187 + font-weight:400;
  188 + color:rgba(255,0,0,1);
  189 +}
  190 +.ware5_t3{
  191 + font-size:22rpx;
  192 + font-family:PingFang SC;
  193 + font-weight:400;
  194 + line-height:30rpx;
  195 + color:rgba(51,51,51,1);
  196 +}
  197 +.ware5_t4{
  198 + font-size:18rpx;
  199 + font-family:PingFang SC;
  200 + font-weight:400;
  201 + color:rgba(153,153,153,1);
  202 +}
  203 +.ware_6{
  204 + width:144rpx;
  205 + height:48rpx;
  206 + background:rgba(249,150,20,1);
  207 + box-shadow:0px 2rpx 12rpx rgba(255,145,0,0.16);
  208 + border-radius:24rpx;
  209 +}
  210 +.ware_6 view{
  211 + font-size:26rpx;
  212 + font-family:PingFang SC;
  213 + font-weight:400;
  214 + text-align: center;
  215 + line-height:48rpx;
  216 + color:rgba(255,255,255,1);
  217 +}
  218 +.ware_bot{
  219 + width:670rpx;
  220 + height:80rpx;
  221 + margin: auto;
  222 + display: flex;
  223 + line-height:80rpx;
  224 + margin-top:32rpx;
  225 + background-color:#F1F7F1;
  226 +}
  227 +.ware_bot_tit{
  228 + font-size:30rpx;
  229 + font-weight:bold;
  230 + margin-left:32rpx;
  231 + color:rgba(110,172,61,1);
  232 +}
  233 +.ware_bot_tit:after{
  234 + content:"";
  235 + margin:0 38rpx;
  236 + border-right:1px solid #B5DE96;
  237 +}
  238 +.ware_bot_txt{
  239 + font-size:24rpx;
  240 + font-family:PingFang SC;
  241 + font-weight:400;
  242 + color:rgba(153,153,153,1);
  243 +}
  244 +/* 规格 */
  245 +.spec{
  246 + width:100%;
  247 + padding:0 32rpx;
  248 + line-height:80rpx;
  249 + display: flex;
  250 + height:80rpx;
  251 + margin-top:8rpx;
  252 + background:white;
  253 +}
  254 +.spec_txt{
  255 + font-size:32rpx;
  256 + font-family:PingFang SC;
  257 + font-weight:400;
  258 + color:rgba(51,51,51,1);
  259 +}
  260 +.spec_txt2{
  261 + font-size:24rpx;
  262 + font-family:PingFang SC;
  263 + font-weight:400;
  264 + margin-left:108rpx;
  265 + color:rgba(153,153,153,1);
  266 +}
  267 +/* 商品详情 */
  268 +.ware_detail{
  269 + width:100%;
  270 + margin-top:8rpx;
  271 + margin-bottom:96rpx;
  272 + padding-bottom:66rpx;
  273 + background: white;
  274 +}
  275 +.ware_detail_tit{
  276 + width:688rpx;
  277 + margin: auto;
  278 + display: flex;
  279 + padding:44rpx 0rpx 42rpx;
  280 + justify-content:space-around;
  281 + border-bottom:2rpx solid #F5F5F5;
  282 +}
  283 +.ware_detail .ware_active{
  284 + color:#6EAC3D;
  285 + font-weight:600;
  286 +}
  287 +.ware_active:after{
  288 + content: "";
  289 + width:16rpx;
  290 + height: 6rpx;
  291 + margin: auto;
  292 + display: block;
  293 + margin-top:6rpx;
  294 + border-radius:8rpx;
  295 + background:rgba(110,172,61,1);
  296 +}
  297 +.ware_detail_tit view{
  298 + font-size:28rpx;
  299 + font-family:PingFang SC;
  300 + font-weight:400;
  301 + color:rgba(153,153,153,1);
  302 +}
  303 +.ware_detailC{
  304 + width:688rpx;
  305 + margin:26rpx auto 0;
  306 +}
  307 +
  308 +.ware_detailImg{
  309 + width:688rpx;
  310 + height:470rpx;
  311 +}
  312 +.ware_detailImg image{
  313 + width:100%;
  314 + height:100%;
  315 +}
  316 +.empty{
  317 + font-size: 32rpx;
  318 + margin-top: 120px;
  319 + text-align: center;
  320 + color: #ccc;
  321 +}
  322 +/* 弹出层 */
  323 +
  324 +.modalDlg {
  325 + width: 100%;
  326 + height: 454rpx;
  327 + bottom: 0;
  328 + position: fixed;
  329 + z-index: 9999;
  330 + background-color: #fff;
  331 +}
  332 +
  333 +.modalDlg_p {
  334 + padding: 0 30rpx;
  335 +}
  336 +
  337 +.m_top {
  338 + display: flex;
  339 +}
  340 +
  341 +.m_topTxt1 {
  342 + display: flex;
  343 + align-self: center;
  344 + justify-content: space-between;
  345 + margin-top: 30rpx;
  346 +}
  347 +
  348 +.m_topTxt {
  349 + width: 100%;
  350 + margin-left: 16rpx;
  351 +}
  352 +
  353 +.m_topImg {
  354 + margin-top: -48rpx;
  355 + display: flex;
  356 +}
  357 +
  358 +.m_topImg image {
  359 + width: 208rpx;
  360 + height: 208rpx;
  361 +}
  362 +
  363 +.m_topTxt1 image {
  364 + width: 32rpx;
  365 + height: 32rpx;
  366 +}
  367 +
  368 +.m_topName {
  369 + font-size: 32rpx;
  370 + font-family: PingFang SC;
  371 + font-weight: 600;
  372 + color: rgba(51, 51, 51, 1);
  373 +}
  374 +
  375 +.m_topTxt2 {
  376 + display: flex;
  377 + margin-top: 16rpx;
  378 + align-items: center;
  379 +}
  380 +
  381 +.m_topPrice {
  382 + width: 120rpx;
  383 + overflow: hidden;
  384 + text-overflow: ellipsis;
  385 + white-space: nowrap;
  386 + font-size: 28rpx;
  387 + font-family: DIN 1451 Std Mittelschrift;
  388 + font-weight: 400;
  389 + color: #f00;
  390 +}
  391 +
  392 +.m_topHelf {
  393 + width: 280rpx;
  394 + overflow: hidden;
  395 + text-overflow: ellipsis;
  396 + white-space: nowrap;
  397 + font-size: 22rpx;
  398 + font-family: PingFang SC;
  399 + font-weight: 400;
  400 + margin-left: 16rpx;
  401 + color: rgba(204, 204, 204, 1);
  402 +}
  403 +
  404 +.m_number {
  405 + display: flex;
  406 + align-items: center;
  407 + margin-top: 18rpx;
  408 +}
  409 +
  410 +.minus_push {
  411 + display: flex;
  412 + margin-left: auto;
  413 + align-items: center;
  414 +}
  415 +
  416 +.m_numTxt {
  417 + font-size: 24rpx;
  418 + font-family: PingFang SC;
  419 + font-weight: 400;
  420 + color: rgba(153, 153, 153, 1);
  421 +}
  422 +
  423 +.minus, .push {
  424 + width: 48rpx;
  425 + height: 48rpx;
  426 + font-size: 40rpx;
  427 + text-align: center;
  428 + line-height: 48rpx;
  429 + border: 2px solid rgba(110, 172, 61, 1);
  430 + border-radius: 50%;
  431 +}
  432 +
  433 +.minus {
  434 + color: #6eac3d;
  435 +}
  436 +
  437 +.num {
  438 + margin: 0 26rpx;
  439 + font-size: 32rpx;
  440 + font-family: PingFang SC;
  441 + font-weight: 400;
  442 + color: rgba(110, 172, 61, 1);
  443 +}
  444 +
  445 +.push {
  446 + color: white;
  447 + background: rgba(110, 172, 61, 1);
  448 +}
  449 +
  450 +.m_btn {
  451 + width: 688rpx;
  452 + height: 80rpx;
  453 + border: 0;
  454 + margin-top: 62rpx;
  455 + font-size: 32rpx;
  456 + font-family: PingFang SC;
  457 + font-weight: 600;
  458 + color: rgba(255, 255, 255, 1);
  459 + background: linear-gradient(170deg, rgba(181, 222, 150, 1) 0%, rgba(169, 209, 33, 1) 100%);
  460 + box-shadow: 0rpx 6rpx 40rpx rgba(162, 255, 0, 0.15);
  461 + border-radius: 48rpx;
  462 +}
  463 +.ware_box:last-child{
  464 + margin-bottom: 0;
  465 +}
  1 +//index.js
  2 +//获取应用实例
  3 +const app = getApp()
  4 +
  5 +Page({
  6 + data: {
  7 +
  8 + },
  9 +
  10 + getOpenId() {
  11 + let that = this
  12 + wx.login({
  13 + success: (res) => {
  14 + let url = 'wxapp/public/getSessionKey'
  15 + let param = {
  16 + code: res.code,
  17 + }
  18 +
  19 + app.post(url, param).then((res) => {
  20 + that.setData({
  21 + openid: res.data.openid,
  22 + session_key: res.data.session_key
  23 + })
  24 + wx.getSetting({
  25 + success: res => {
  26 + if (res.authSetting['scope.userInfo'] === true) {
  27 + wx.getUserInfo({
  28 + success: reg => {
  29 + that.setData({
  30 + encrypted_data: reg.encryptedData,
  31 + iv: reg.iv
  32 + })
  33 + that.login()
  34 + }
  35 + })
  36 + }
  37 +
  38 + }
  39 + })
  40 +
  41 + }).catch((errMsg) => {})
  42 +
  43 +
  44 + }
  45 + });
  46 + },
  47 +
  48 + // 获取用户权限信息
  49 + getUserInfo(e) {
  50 + let that = this;
  51 + if (e.detail.errMsg == "getUserInfo:ok") {
  52 + that.setData({
  53 + encrypted_data: e.detail.encryptedData,
  54 + iv: e.detail.iv
  55 + })
  56 + that.login()
  57 + }
  58 +
  59 +
  60 + },
  61 +
  62 + // 登录
  63 + login() {
  64 + let that = this;
  65 + let url = "wxapp/public/login";
  66 + let data = {
  67 + openid: that.data.openid,
  68 + session_key: that.data.session_key,
  69 + encrypted_data: that.data.encrypted_data,
  70 + iv: that.data.iv,
  71 + }
  72 + app.post(url, data).then((res) => {
  73 + wx.setStorageSync("token", res.data.token);
  74 + wx.showLoading({
  75 + title: '正在进入',
  76 + })
  77 +
  78 + let t = setInterval(function() {
  79 + clearInterval(t)
  80 + wx.switchTab({
  81 + url: '../homeindex/homeindex',
  82 + })
  83 + wx.hideLoading()
  84 + }, 1500)
  85 +
  86 + }).catch((err) => {
  87 +
  88 + })
  89 +
  90 +
  91 +
  92 + // }).catch((errMsg) => { })
  93 +
  94 + },
  95 +
  96 +
  97 +
  98 +
  99 + // 111
  100 + /**
  101 + * 生命周期函数--监听页面加载
  102 + */
  103 + onLoad: function(options) {
  104 + this.getOpenId();
  105 + },
  106 +
  107 +
  108 +
  109 +
  110 +
  111 +
  112 +
  113 +
  114 +})
  1 +{
  2 + "usingComponents": {}
  3 +}
  1 +<view class='box'>
  2 +
  3 + <view class="beginimg">
  4 + <image src="/img/bac.jpg"></image>
  5 + </view>
  6 +
  7 +
  8 +
  9 +
  10 + <!-- <view class='go'> -->
  11 + <button open-type='getUserInfo' bindgetuserinfo="getUserInfo" class="qidong">立即启动</button>
  12 + <!-- </view> -->
  13 +
  14 +</view>
  1 +/**index.wxss**/
  2 +
  3 +page {
  4 + height: 100%;
  5 + width: 750rpx;
  6 + position: relative;
  7 +}
  8 +
  9 +.box {
  10 + height: 100%;
  11 + position: relative
  12 +}
  13 +
  14 +.cover {
  15 + position: relative;
  16 + height: 100vh;
  17 + overflow: hidden;
  18 + box-sizing: border-box;
  19 + padding-top: 200rpx;
  20 +}
  21 +
  22 +.beginimg {
  23 + width: 500rpx;
  24 + height: 500rpx;
  25 + position:absolute;
  26 + top:40%;
  27 + left:50%;
  28 + transform: translate(-50%,-40%)
  29 +
  30 +}
  31 +
  32 +.beginimg image {
  33 + width: 100%;
  34 + height: 100%;
  35 +}
  36 +
  37 +.cover image {
  38 + display: block;
  39 + width: 300rpx;
  40 + height: 300rpx;
  41 + margin: 0 auto;
  42 +}
  43 +
  44 +.cover text {
  45 + display: block;
  46 + width: 500rpx;
  47 + margin: 0 auto;
  48 + text-align: center;
  49 +}
  50 +
  51 +.go {
  52 + position: absolute;
  53 + bottom:134rpx;
  54 + left: 0;
  55 + right: 0;
  56 + margin: auto;
  57 + width:425rpx;
  58 + height:88rpx;
  59 + background:rgba(118,208,82,1);
  60 + box-shadow:0rpx 16rpx 30rpx 0rpx rgba(138,202,103,0.6);
  61 + border-radius:44rpx;
  62 + /* border:1rpx solid #434343; */
  63 +}
  64 +
  65 +.qidong{
  66 + position: absolute;
  67 + bottom:134rpx;
  68 + left: 0;
  69 + right: 0;
  70 + margin: auto;
  71 + width:425rpx;
  72 + height:88rpx;
  73 + background:rgba(118,208,82,1);
  74 + box-shadow:0px 16rpx 30rpx 0rpx rgba(138,202,103,0.6);
  75 + border-radius:44rpx;
  76 + font-size: 30rpx;
  77 + color: #fff;
  78 + text-align: center;
  79 + line-height: 88rpx;
  80 +
  81 +
  82 +}
  83 +button::after{
  84 + border:none;
  85 + outline:none;
  86 +}
  1 +// pages/kind/detail_1/detail_1.js
  2 +const app = getApp();
  3 +var WxParse = require('../../../wxParse/wxParse.js');
  4 +Page({
  5 + /**
  6 + * 页面的初始数据
  7 + */
  8 + data: {
  9 + index: 1,
  10 + showModal: false,
  11 + hide: false,
  12 + num: 1,
  13 + detail_id: null,
  14 + detailCon: {},
  15 + assess: [],
  16 + id: '',
  17 + days: 0,
  18 + hours: 0,
  19 + minutes: 0,
  20 + seconds: 0,
  21 + over: true,
  22 + short: [],
  23 + seemore: true,
  24 + images: []
  25 + },
  26 +
  27 + /**
  28 + * 生命周期函数--监听页面加载
  29 + */
  30 + onLoad: function(options) {
  31 + console.log(options)
  32 + this.setData({
  33 + detail_id: options.id,
  34 + id: options.id
  35 + })
  36 + this.detaiFun(options.id)
  37 +
  38 + },
  39 + slectpic(e) {
  40 + let that = this;
  41 + console.log(e)
  42 + let idx = e.currentTarget.dataset.idx;
  43 + let newassess = that.data.assess;
  44 + for (var i = 0; i < newassess.length; i++) {
  45 + if (i == idx) {
  46 + that.setData({
  47 + images: newassess[i].img
  48 + })
  49 + }
  50 +
  51 + }
  52 +
  53 + console.log(that.data.images)
  54 + },
  55 +
  56 + // 图片预览
  57 + previewImage: function(e) {
  58 +
  59 + let that = this;
  60 + console.log(e)
  61 + let idx = e.currentTarget.dataset.idx;
  62 + let newassess = that.data.assess;
  63 + for (var i = 0; i < newassess.length; i++) {
  64 + if (i == idx) {
  65 + that.setData({
  66 + images: newassess[i].img
  67 + })
  68 + }
  69 +
  70 + }
  71 +
  72 + var current = e.target.dataset.src
  73 + wx.previewImage({
  74 + current: current,
  75 + urls: this.data.images
  76 + })
  77 + },
  78 +
  79 + //已成团
  80 + group() {
  81 + wx.showToast({
  82 + title: '商品已成团,无法继续购买',
  83 + icon: "none"
  84 + })
  85 + },
  86 + //结束
  87 + gameover() {
  88 + wx.showToast({
  89 + title: '活动已结束',
  90 + icon: "none"
  91 + })
  92 + },
  93 + moresee() {
  94 + let that = this;
  95 + that.setData({
  96 + seemore: false
  97 + })
  98 +
  99 +
  100 + let url = "home/index/shopMessage";
  101 + let header = {
  102 + "XX-Token": wx.getStorageSync('token'),
  103 + "XX-Device-Type": 'wxapp'
  104 + }
  105 + let params = {
  106 + shop_id: that.data.detail_id,
  107 + }
  108 + app.post(url, params, header).then((res) => {
  109 + console.log(res)
  110 + let masarr = []
  111 +
  112 + that.setData({
  113 + // short: masarr,
  114 + //assess: res.data
  115 + assess: res.data
  116 + })
  117 + }).catch((err) => {
  118 + console.log(err)
  119 + })
  120 + },
  121 +
  122 +
  123 +
  124 + goFirm_order1(e) {
  125 + let that = this;
  126 + let url = '/user/index/checkNum',
  127 + params = {
  128 + num: that.data.num,
  129 + shop_id: that.data.id
  130 +
  131 + }
  132 + let header = {
  133 + 'XX-Token': wx.getStorageSync("token"),
  134 + 'XX-Device-Type': 'wxapp'
  135 + }
  136 + app.post(url, params).then((res) => {
  137 + console.log(res);
  138 + if (res.msg.msg == "可以购买") {
  139 + wx.navigateTo({
  140 + url: '../firm_order1/firm_order1?id=' + e.currentTarget.dataset.id + "&&num=" + this.data.num,
  141 + })
  142 + }else{
  143 + wx.showToast({
  144 + title: '库存不足',
  145 + icon:"none"
  146 + })
  147 + }
  148 +
  149 +
  150 +
  151 + }).catch((err) => {
  152 +
  153 + })
  154 +
  155 +
  156 + },
  157 +
  158 + // 商品详情数据
  159 + detaiFun(id) {
  160 + let that = this;
  161 + let url = "home/index/shopEdit";
  162 + let params = {
  163 + shop_id: that.data.id
  164 + }
  165 + let header = {
  166 + "XX-Token": wx.getStorageSync('token'),
  167 + "XX-Device-Type": 'wxapp'
  168 + }
  169 + app.post(url, params, header).then((res) => {
  170 + console.log(res.data.content)
  171 + that.setData({
  172 + detailCon: res.data,
  173 + content: res.content
  174 + })
  175 +
  176 +
  177 + // WxParse.wxParse('content', 'html', this.data.content, this, 5);
  178 + WxParse.wxParse('article', 'html', res.data.content, that, 5)
  179 + console.log(that.data.detailCon);
  180 +
  181 + let number = res.data.end_time - res.data.now_time;
  182 + console.log(number)
  183 + // let number = res.over_time;
  184 + // 时间戳处理
  185 + var totalSecond = number;
  186 + console.log(totalSecond)
  187 +
  188 + var interval = setInterval(function() {
  189 + // 秒数
  190 + var second = totalSecond;
  191 + // 天数位
  192 + var day = Math.floor(second / 3600 / 24);
  193 + var dayStr = day.toString();
  194 + if (dayStr.length == 1) dayStr = '0' + dayStr;
  195 + // 小时位
  196 + var hr = Math.floor((second - day * 3600 * 24) / 3600);
  197 + var hrStr = hr.toString();
  198 + if (hrStr.length == 1) hrStr = '0' + hrStr;
  199 + // 分钟位
  200 + var min = Math.floor((second - day * 3600 * 24 - hr * 3600) / 60);
  201 + var minStr = min.toString();
  202 + if (minStr.length == 1) minStr = '0' + minStr;
  203 + // 秒位
  204 + var sec = second - day * 3600 * 24 - hr * 3600 - min * 60;
  205 + var secStr = sec.toString();
  206 + if (secStr.length == 1) secStr = '0' + secStr;
  207 +
  208 + that.setData({
  209 + days: dayStr,
  210 + hours: hrStr,
  211 + minutes: minStr,
  212 + seconds: secStr,
  213 + });
  214 + totalSecond--;
  215 +
  216 + if (totalSecond <= 0) {
  217 + that.setData({
  218 + over: false
  219 + })
  220 + console.log(that.data.over)
  221 + clearInterval(interval);
  222 + // wx.showToast({
  223 + // title: '已结束',
  224 + // icon: 'none'
  225 + // });
  226 + // 倒计时结束
  227 + //that.countDown();
  228 + that.setData({
  229 + days: '00',
  230 + hours: '00',
  231 + minutes: '00',
  232 + seconds: '00',
  233 + });
  234 + }
  235 + }.bind(this), 1000);
  236 +
  237 +
  238 + }).catch((err) => {
  239 + console.log(err)
  240 + })
  241 + },
  242 + // 商品评价页面
  243 + assessFun() {
  244 + let that = this;
  245 + let url = "home/index/shopMessage";
  246 + let header = {
  247 + "XX-Token": wx.getStorageSync('token'),
  248 + "XX-Device-Type": 'wxapp'
  249 + }
  250 + let params = {
  251 + shop_id: that.data.detail_id,
  252 + }
  253 + app.post(url, params, header).then((res) => {
  254 + console.log(res)
  255 + let masarr = []
  256 + for (var i = 0; i < res.data.length; i++) {
  257 + if (i < 5) {
  258 + masarr.push(res.data[i])
  259 + }
  260 +
  261 + }
  262 + that.setData({
  263 + // short: masarr,
  264 + //assess: res.data
  265 + assess: masarr
  266 + })
  267 +
  268 + console.log(that.data.assess)
  269 + }).catch((err) => {
  270 + console.log(err)
  271 + })
  272 + },
  273 + // 加入收藏
  274 + addFun() {
  275 + let that = this;
  276 + let url = "home/index/shopCollect";
  277 + let params = {
  278 + shop_id: that.data.detail_id,
  279 + };
  280 + let header = {
  281 + "XX-Token": wx.getStorageSync('token'),
  282 + "XX-Device-Type": 'wxapp'
  283 + };
  284 + app.post(url, params, header).then((res) => {
  285 + console.log(res)
  286 + // if(res.code == 20000){
  287 + wx.showToast({
  288 + title: '收藏成功',
  289 + icon: "none",
  290 + duration: 1500
  291 + })
  292 +
  293 + setTimeout(function() {
  294 + that.detaiFun()
  295 + }, 1500)
  296 +
  297 + // }
  298 + }).catch((err) => {
  299 + console.log(err)
  300 + wx.showToast({
  301 + title: err.msg,
  302 + icon: 'none'
  303 + })
  304 +
  305 + setTimeout(function() {
  306 + that.detaiFun()
  307 + }, 1500)
  308 + })
  309 + },
  310 + goy(e) {
  311 + this.setData({
  312 + index: e.currentTarget.dataset.id,
  313 + })
  314 + if (e.currentTarget.dataset.id == 2) {
  315 + console.log(9909)
  316 + this.assessFun()
  317 + } else {
  318 + this.detaiFun()
  319 + }
  320 + },
  321 + goConfirm: function() {
  322 + this.setData({
  323 + showModal: true,
  324 + })
  325 + },
  326 + m_close: function() {
  327 + this.setData({
  328 + showModal: false,
  329 + })
  330 + },
  331 + // 点击加减
  332 + bindMinus: function() {
  333 + var num = this.data.num;
  334 + if (num > 1) {
  335 + num--;
  336 + }
  337 + this.setData({
  338 + num: num,
  339 + });
  340 + },
  341 + // 点击加
  342 + bindPlus: function() {
  343 + var num = this.data.num;
  344 + num++;
  345 + this.setData({
  346 + num: num,
  347 + });
  348 + },
  349 + /**
  350 + * 生命周期函数--监听页面初次渲染完成
  351 + */
  352 + onReady: function() {
  353 +
  354 + },
  355 +
  356 + /**
  357 + * 生命周期函数--监听页面显示
  358 + */
  359 + onShow: function() {
  360 +
  361 + },
  362 +
  363 + /**
  364 + * 生命周期函数--监听页面隐藏
  365 + */
  366 + onHide: function() {
  367 +
  368 + },
  369 +
  370 + /**
  371 + * 生命周期函数--监听页面卸载
  372 + */
  373 + onUnload: function() {
  374 +
  375 + },
  376 +
  377 + /**
  378 + * 页面相关事件处理函数--监听用户下拉动作
  379 + */
  380 + onPullDownRefresh: function() {
  381 +
  382 + },
  383 +
  384 + /**
  385 + * 页面上拉触底事件的处理函数
  386 + */
  387 + onReachBottom: function() {
  388 +
  389 + },
  390 +
  391 + /**
  392 + * 用户点击右上角分享
  393 + */
  394 + onShareAppMessage: function() {
  395 +
  396 + }
  397 +})
  1 +{
  2 + "navigationBarTitleText": "商品详情",
  3 + "navigationBarBackgroundColor": "#6EAC3D",
  4 + "navigationBarTextStyle": "white"
  5 +}
  1 +<!--pages/kind/detail_1/detail_1.wxml-->
  2 +<!-- 商品 -->
  3 +
  4 +<view class="pagecontainer">
  5 +
  6 + <import src="../../../wxParse/wxParse.wxml" />
  7 + <view class='container'>
  8 + <view class='ware_box'>
  9 + <view class='ware_top'>
  10 + <view class='ware_1'>
  11 + <image src='{{detailCon.thumb}}'></image>
  12 +
  13 + <view wx:if="{{over}}">
  14 + <view class='ware_1_time' wx:if="{{detailCon.percent!=100}}">
  15 + {{days}}天{{hours}}小时{{minutes}}分{{seconds}}秒
  16 + </view>
  17 +
  18 + <view class='ware_1_time' wx:else>已成团</view>
  19 + </view>
  20 +
  21 + <view class='ware_1_over' wx:else>
  22 + <!-- {{detailCon.open_time}} -->
  23 + 已结束
  24 + </view>
  25 + </view>
  26 + <view class='ware_text'>
  27 + <view class='ware_2'>
  28 + <text class='ware_2Txt1'>{{detailCon.name}}</text>
  29 + <text class='ware_2Txt2'>产地:{{detailCon.origin}}</text>
  30 + </view>
  31 + <view class='ware_3'>
  32 + <progress percent="{{detailCon.percent}}" show-info color="#B5DE96" border-radius="8" font-size="24rpx" stroke-width="16rpx" />
  33 + </view>
  34 + <view class='ware_4'>
  35 + <text>已拼{{detailCon.numb}}份,目标{{detailCon.group}}份</text>
  36 + </view>
  37 + <view class='ware_5'>
  38 + <view>
  39 + <text class='ware5_t1'>¥{{detailCon.money_sale}}/</text>
  40 + <text class='ware5_t2'>{{detailCon.shop_type}}</text>
  41 + </view>
  42 + <view class='ware5_box'>
  43 + <view class='ware5_t3'>{{detailCon.text_table}}</view>
  44 + <view class='ware5_t4'>{{detailCon.text_content}}</view>
  45 + </view>
  46 +
  47 + <view wx:if="{{over}}">
  48 + <view class='ware_6' bindtap='goConfirm' wx:if="{{detailCon.percent!=100}}">
  49 + 立即参团
  50 + </view>
  51 +
  52 + <view class='ware_6' wx:else>已成团</view>
  53 + </view>
  54 +
  55 +
  56 + <view class="waretext" wx:else>活动结束</view>
  57 + </view>
  58 + </view>
  59 + </view>
  60 + <view class='ware_bot'>
  61 + <view class='ware_bot_tit'>经典推荐</view>
  62 + <view class='ware_bot_txt'>{{detailCon.recommend}}</view>
  63 + </view>
  64 + </view>
  65 + </view>
  66 + <!-- 商品规格 -->
  67 + <view class='spec'>
  68 + <view class='spec_txt'>商品规格</view>
  69 + <view class='spec_txt2'>{{detailCon.shop_type1}}</view>
  70 + </view>
  71 + <!-- 商品详情 -->
  72 + <view class='ware_detail'>
  73 + <view class='ware_detail_tit'>
  74 + <view class="ware_detail_box {{index == 1 ? 'ware_active' : ''}}" bindtap='goy' data-id="1">商品详情</view>
  75 + <view class="ware_detail_box {{index == 2 ? 'ware_active' : ''}}" bindtap='goy' data-id="2">用户评价</view>
  76 + </view>
  77 + <view class='ware_detailC'>
  78 + <view class='ware_detailImg' wx:if="{{index == 1}}">
  79 +
  80 + <!-- <template is="wxParse" data="{{wxParseData:content.nodes}}" /> -->
  81 + <template is="wxParse" data="{{wxParseData:article.nodes}}" />
  82 + </view>
  83 + <!-- 用户评价 -->
  84 + <view class='ware_assess' wx:if="{{index == 2}}">
  85 +
  86 + <view class="noping" wx:if="{{assess.length==0}}">
  87 + <view class="noorder">
  88 + <image src="/img/noorder.png" mode="widthFix"></image>
  89 + </view>
  90 +
  91 + <view class="noordertitle">暂无评价</view>
  92 + </view>
  93 +
  94 + <view wx:else>
  95 + <!-- <block wx:if="{{seemore}}">
  96 + <view class='ware_assess_li 345' wx:for="{{short}}" wx:key="index">
  97 + <view class='assess_header'>
  98 + <view class='assess_headerImg'>
  99 + <image src='{{item.avatar}}'></image>
  100 + </view>
  101 + <view class='assess_headerTxt'>{{item.user_nickname}}</view>
  102 + </view>
  103 + <view class='assess_say'>
  104 + {{item.text}}
  105 + </view>
  106 + <block wx:if="{{item.img.length!=0}}">
  107 + <view class='ware_pic'>
  108 + <view class='ware_picBox' wx:for="{{item.img}}" wx:key=''>
  109 + <image src='{{item}}'></image>
  110 + </view>
  111 + </view>
  112 + </block>
  113 + <view class='assess_time'>2019/07/01</view>
  114 + </view>
  115 + </block> -->
  116 + <block>
  117 + <view class='ware_assess_li 123' wx:for="{{assess}}" wx:key="index" wx:for-item="items" wx:for-index="indexs">
  118 + <view class='assess_header'>
  119 + <view class='assess_headerImg'>
  120 + <image src='{{items.avatar}}'></image>
  121 + </view>
  122 + <view class='assess_headerTxt'>{{items.user_nickname}}</view>
  123 + </view>
  124 + <view class='assess_say'>
  125 + {{items.text}}
  126 + </view>
  127 + <block wx:if="{{item.img.length!=0}}">
  128 + <view class='ware_pic' >
  129 + <view class='ware_picBox' wx:for="{{items.img}}" wx:key=''>
  130 + <image src='{{item}}' bindtap="previewImage" data-src="{{item}}" data-idx="{{indexs}}"></image>
  131 + </view>
  132 + </view>
  133 + </block>
  134 + <view class='assess_time'>{{items.create_time}}</view>
  135 + </view>
  136 + </block>
  137 +
  138 +
  139 +
  140 +
  141 +
  142 +
  143 + <block wx:if="{{assess.length==5}}">
  144 + <view class='whole' wx:if="{{seemore}}" bindtap="moresee">
  145 + 查看全部评价
  146 + </view>
  147 +
  148 + </block>
  149 + </view>
  150 +
  151 + </view>
  152 + </view>
  153 + </view>
  154 + <!-- footer底部 -->
  155 + <view class='footer'>
  156 +
  157 + <view class="kefu">
  158 + <view class="iconfont icon-kefu"></view>
  159 + <button class="remaindetail" open-type="contact" style="margin-left: 0"></button>
  160 + </view>
  161 + <view class='footer_add' bindtap='addFun' wx:if="{{detailCon.collect_type==0}}">加入收藏</view>
  162 + <view class='footer_add' bindtap='addFun' wx:if="{{detailCon.collect_type==1}}">取消收藏</view>
  163 +
  164 + <view wx:if="{{over}}">
  165 + <view class='footer_off' bindtap='goConfirm' wx:if='{{detailCon.percent!=100}}'>立即参团</view>
  166 + <view class='footer_off' wx:else bindtap='group'>已成团</view>
  167 + </view>
  168 +
  169 + <view class='footer_over' wx:else bindtap="gameover">活动结束</view>
  170 + </view>
  171 + <!-- 遮罩层 -->
  172 + <view class="mask" catchtouchmove="preventTouchMove" wx:if="{{showModal}}"></view>
  173 + <!-- 弹出层 -->
  174 + <view class="modalDlg" wx:if="{{showModal}}">
  175 + <view class='modalDlg_p'>
  176 + <view class='m_top'>
  177 + <view class='m_topImg'>
  178 + <image src='{{detailCon.thumb}}'></image>
  179 + </view>
  180 + <view class='m_topTxt'>
  181 + <view class='m_topTxt1'>
  182 + <view class='m_topName'>{{detailCon.name}}</view>
  183 + <image bindtap='m_close' src='../../../img/cha.png'></image>
  184 + </view>
  185 + <view class='m_topTxt2'>
  186 + <view class='m_topPrice'>¥{{detailCon.money_sale}}</view>
  187 + <view class='m_topHelf'>{{detailCon.shop_type}}</view>
  188 + </view>
  189 + </view>
  190 + </view>
  191 + <view class='m_number'>
  192 + <view class='m_numTxt'>购买数量</view>
  193 + <view class='minus_push'>
  194 + <view class='minus' bindtap="bindMinus">-</view>
  195 + <view class='num' bindchange="bindManual">{{num}}</view>
  196 + <view class='push' bindtap="bindPlus">+</view>
  197 + </view>
  198 + </view>
  199 + <button class='m_btn' bindtap='goFirm_order1' data-id="{{detailCon.shop_id}}">确认</button>
  200 + </view>
  201 + </view>
  202 +</view>
  1 +/* pages/kind/detail_1/detail_1.wxss */
  2 +@import "../../../wxParse/wxParse.wxss";
  3 +page {
  4 + background: #f7f7f7;
  5 + overflow-x: hidden
  6 +}
  7 +.pagecontainer{
  8 + overflow-x: hidden
  9 +}
  10 +
  11 +.container {
  12 + overflow: hidden;
  13 + background: white;
  14 + padding-bottom: 48rpx;
  15 +}
  16 +
  17 +.ware_box {
  18 + width: 688rpx;
  19 + height: 400rpx;
  20 + overflow: hidden;
  21 + margin:16rpx auto 0;
  22 + background: #f9fafc;
  23 +}
  24 +
  25 +.ware_top {
  26 + margin-top:44rpx;
  27 + display: flex;
  28 + padding:0 16rpx;
  29 + box-sizing: border-box;
  30 +}
  31 +
  32 +.ware_1 {
  33 + width: 208rpx;
  34 + height: 208rpx;
  35 + position: relative;
  36 +}
  37 +
  38 +.ware_1 image {
  39 + width: 100%;
  40 + height: 100%;
  41 +}
  42 +
  43 +.ware_1_time {
  44 + position: absolute;
  45 + bottom: 0;
  46 + width: 208rpx;
  47 + height: 48rpx;
  48 + color: white;
  49 + text-align: center;
  50 + line-height: 48rpx;
  51 + font-size: 20rpx;
  52 + background: #fac8c8;
  53 + font-family: PingFang SC;
  54 +}
  55 +.ware_1_over{
  56 + position: absolute;
  57 + bottom: 0;
  58 + width: 208rpx;
  59 + height: 48rpx;
  60 + color: white;
  61 + text-align: center;
  62 + line-height: 48rpx;
  63 + font-size: 20rpx;
  64 + background: #ddd;
  65 + font-family: PingFang SC;
  66 +}
  67 +
  68 +.ware_text {
  69 + margin-left:14rpx;
  70 +}
  71 +
  72 +.ware_2Txt1 {
  73 + font-size: 32rpx;
  74 + font-family: PingFang SC;
  75 + font-weight: 600;
  76 + line-height: 44rpx;
  77 + color: rgba(51, 51, 51, 1);
  78 +}
  79 +
  80 +.ware_2Txt2 {
  81 + font-size: 22rpx;
  82 + margin-left: 98rpx;
  83 + font-family: PingFang SC;
  84 + font-weight: 400;
  85 + line-height: 32rpx;
  86 + color: rgba(204, 204, 204, 1);
  87 +}
  88 +
  89 +.ware_3 progress {
  90 + width: 370rpx;
  91 + color: #b5de96;
  92 + margin-top: 24rpx;
  93 +}
  94 +
  95 +.ware_4 text{
  96 + font-size: 22rpx;
  97 + font-family: PingFang SC;
  98 + font-weight: 400;
  99 + line-height: 32rpx;
  100 + color: rgba(204, 204, 204, 1);
  101 +}
  102 +.ware5_t2 {
  103 + overflow:hidden;
  104 + text-overflow:ellipsis;
  105 + white-space:nowrap;
  106 + width:70rpx;
  107 + /* display: inline-block; */
  108 + font-size: 22rpx;
  109 + font-family: PingFang SC;
  110 + font-weight: 400;
  111 + line-height: 19rpx;
  112 + margin-left:4rpx;
  113 + color: rgba(204, 204, 204, 1);
  114 +}
  115 +.ware_5 {
  116 + display: flex;
  117 + display: -webkit-flex;
  118 + justify-content: space-between;
  119 +}
  120 +.ware5_t1 {
  121 + width:110rpx;
  122 + overflow:hidden;
  123 + text-overflow:ellipsis;
  124 + white-space:nowrap;
  125 + font-size:26rpx;
  126 + font-family: DIN 1451 Std Mittelschrift;
  127 + font-weight: 400;
  128 + color: rgba(255, 0, 0, 1);
  129 +}
  130 +
  131 +.ware5_t3 {
  132 + width:104rpx;
  133 + overflow:hidden;
  134 + text-overflow:ellipsis;
  135 + white-space:nowrap;
  136 + font-size: 20rpx;
  137 + font-family: PingFang SC;
  138 + font-weight: 400;
  139 + line-height: 30rpx;
  140 + color: rgba(51, 51, 51, 1);
  141 +}
  142 +
  143 +.ware5_t4 {
  144 + width:104rpx;
  145 + overflow:hidden;
  146 + text-overflow:ellipsis;
  147 + white-space:nowrap;
  148 + font-size: 18rpx;
  149 + font-family: PingFang SC;
  150 + font-weight: 400;
  151 + color: rgba(153, 153, 153, 1);
  152 +}
  153 +
  154 +.ware_6 {
  155 + width: 144rpx;
  156 + height: 48rpx;
  157 + margin-left: 14rpx;
  158 + background: rgba(249, 150, 20, 1);
  159 + box-shadow: 0px 2rpx 12rpx rgba(255, 145, 0, 0.16);
  160 + border-radius: 24rpx;
  161 + font-size: 26rpx;
  162 + font-family: PingFang SC;
  163 + font-weight: 400;
  164 + text-align: center;
  165 + line-height: 48rpx;
  166 + color: rgba(255, 255, 255, 1);
  167 +}
  168 +.waretext{
  169 + width: 144rpx;
  170 + height: 48rpx;
  171 + margin-left: 14rpx;
  172 + background: #999;
  173 + box-shadow: 0px 2rpx 12rpx rgba(255, 145, 0, 0.16);
  174 + border-radius: 24rpx;
  175 + font-size: 26rpx;
  176 + font-family: PingFang SC;
  177 + font-weight: 400;
  178 + text-align: center;
  179 + line-height: 48rpx;
  180 + color: rgba(255, 255, 255, 1);
  181 +}
  182 +.ware5_box{
  183 + margin-left:4rpx;
  184 +}
  185 +.ware_6 view {
  186 + font-size: 26rpx;
  187 + font-family: PingFang SC;
  188 + font-weight: 400;
  189 + text-align: center;
  190 + line-height: 48rpx;
  191 + color: rgba(255, 255, 255, 1);
  192 +}
  193 +
  194 +.ware_bot {
  195 + width: 670rpx;
  196 + height: 80rpx;
  197 + margin: auto;
  198 + display: flex;
  199 + line-height: 80rpx;
  200 + margin-top: 32rpx;
  201 + background-color: #f1f7f1;
  202 +}
  203 +
  204 +.ware_bot_tit {
  205 + font-size: 30rpx;
  206 + font-weight: bold;
  207 + margin-left: 32rpx;
  208 + color: rgba(110, 172, 61, 1);
  209 +}
  210 +
  211 +.ware_bot_tit:after {
  212 + content: "";
  213 + margin: 0 38rpx;
  214 + border-right: 1px solid #b5de96;
  215 +}
  216 +
  217 +.ware_bot_txt {
  218 + font-size: 24rpx;
  219 + font-family: PingFang SC;
  220 + font-weight: 400;
  221 + color: rgba(153, 153, 153, 1);
  222 +}
  223 +
  224 +/* 规格 */
  225 +
  226 +.spec {
  227 + width: 100%;
  228 + padding: 0 32rpx;
  229 + line-height: 80rpx;
  230 + display: flex;
  231 + height: 80rpx;
  232 + margin-top: 8rpx;
  233 + background: white;
  234 +}
  235 +
  236 +.spec_txt {
  237 + font-size: 32rpx;
  238 + font-family: PingFang SC;
  239 + font-weight: 400;
  240 + color: rgba(51, 51, 51, 1);
  241 +}
  242 +
  243 +.spec_txt2 {
  244 + font-size: 24rpx;
  245 + font-family: PingFang SC;
  246 + font-weight: 400;
  247 + margin-left: 108rpx;
  248 + color: rgba(153, 153, 153, 1);
  249 +}
  250 +
  251 +/* 商品详情 */
  252 +
  253 +.ware_detail {
  254 + width: 100%;
  255 + margin-top: 8rpx;
  256 + margin-bottom: 96rpx;
  257 + padding-bottom: 66rpx;
  258 + background: white;
  259 +}
  260 +
  261 +.ware_detail_tit {
  262 + width: 688rpx;
  263 + margin: auto;
  264 + display: flex;
  265 + padding: 44rpx 0rpx 42rpx;
  266 + justify-content: space-around;
  267 + border-bottom: 2rpx solid #f5f5f5;
  268 +}
  269 +
  270 +.ware_detail .ware_active {
  271 + color: #6eac3d;
  272 + font-weight: 600;
  273 +}
  274 +
  275 +.ware_active:after {
  276 + content: "";
  277 + width: 16rpx;
  278 + height: 6rpx;
  279 + margin: auto;
  280 + display: block;
  281 + margin-top: 6rpx;
  282 + border-radius: 8rpx;
  283 + background: rgba(110, 172, 61, 1);
  284 +}
  285 +
  286 +.ware_detail_tit view {
  287 + font-size: 28rpx;
  288 + font-family: PingFang SC;
  289 + font-weight: 400;
  290 + color: rgba(153, 153, 153, 1);
  291 +}
  292 +
  293 +.ware_detailC {
  294 + width: 688rpx;
  295 + margin: 26rpx auto 0;
  296 +}
  297 +
  298 +.ware_detailImg {
  299 + width: 688rpx;
  300 + height: 470rpx;
  301 + padding-bottom: 130rpx;
  302 +}
  303 +
  304 +.ware_detailImg image {
  305 + width: 100%;
  306 + height: 100%;
  307 +}
  308 +
  309 +/* 用户评价 */
  310 +
  311 +.ware_assess_li {
  312 + padding-bottom: 24rpx;
  313 + margin-bottom: 32rpx;
  314 + border-bottom: 1px solid #f5f5f5;
  315 +}
  316 +
  317 +.assess_header {
  318 + display: flex;
  319 + justify-content: space-between;
  320 +}
  321 +
  322 +.assess_headerImg {
  323 + width: 64rpx;
  324 + height: 64rpx;
  325 +}
  326 +
  327 +.assess_headerImg image {
  328 + width: 100%;
  329 + height: 100%;
  330 +}
  331 +
  332 +.assess_headerTxt {
  333 + font-size: 24rpx;
  334 + font-family: PingFang SC;
  335 + font-weight: 400;
  336 + color: rgba(153, 153, 153, 1);
  337 +}
  338 +
  339 +.assess_say {
  340 + font-size: 30rpx;
  341 + font-family: PingFang SC;
  342 + font-weight: 400;
  343 + margin-top: 18rpx;
  344 + color: rgba(102, 102, 102, 1);
  345 +}
  346 +
  347 +.assess_time {
  348 + font-size: 22rpx;
  349 + font-family: PingFang SC;
  350 + font-weight: 400;
  351 + margin-top: 12rpx;
  352 + color: rgba(153, 153, 153, 1);
  353 +}
  354 +
  355 +.ware_pic {
  356 + display:flex;
  357 + margin-top: 16rpx;
  358 + flex-wrap: wrap;
  359 +}
  360 +
  361 +.ware_picBox {
  362 + flex:0 0 auto;
  363 + margin-right: 16rpx;
  364 +}
  365 +
  366 +.ware_picBox image {
  367 + width: 112rpx;
  368 + height: 112rpx;
  369 +}
  370 +
  371 +/* 全部评价 */
  372 +
  373 +.whole {
  374 + width: 336rpx;
  375 + height: 64rpx;
  376 + background: rgba(255, 255, 255, 1);
  377 + border: 2rpx solid rgba(230, 230, 230, 1);
  378 + border-radius: 166rpx;
  379 + font-size: 26rpx;
  380 + text-align: center;
  381 + line-height: 64rpx;
  382 + font-family: PingFang SC;
  383 + font-weight: 400;
  384 + margin: auto;
  385 + color: rgba(102, 102, 102, 1);
  386 +}
  387 +
  388 +/* footer */
  389 +
  390 +.footer {
  391 + position: fixed;
  392 + bottom: 0;
  393 + text-align: center;
  394 + width: 750rpx;
  395 + height: 96rpx;
  396 + display: flex;
  397 + line-height: 66rpx;
  398 + align-items: center;
  399 + justify-content: center;
  400 + background: rgba(255, 255, 255, 1);
  401 + box-shadow: 0px -2rpx 12rpx rgba(0, 0, 0, 0.06);
  402 +}
  403 +
  404 +.footer_add, .footer_off {
  405 + width: 272rpx;
  406 + height: 64rpx;
  407 + font-size: 32rpx;
  408 + font-family: PingFang SC;
  409 + font-weight: 600;
  410 + border-radius: 32rpx;
  411 + border: 2rpx solid rgba(172, 212, 66, 1);
  412 +}
  413 +.footer_over{
  414 + width: 272rpx;
  415 + height: 64rpx;
  416 + font-size: 32rpx;
  417 + font-family: PingFang SC;
  418 + font-weight: 600;
  419 + border-radius: 32rpx;
  420 + border: 2rpx solid rgba(172, 212, 66, 1);
  421 +
  422 + color:#999;
  423 +
  424 +}
  425 +.footer_add {
  426 + background: rgba(255, 255, 255, 1);
  427 + margin-right: 32rpx;
  428 + color: rgba(110, 172, 61, 1);
  429 +}
  430 +
  431 +.footer_off {
  432 + background: linear-gradient(159deg, rgba(181, 222, 150, 1) 0%, rgba(169, 209, 33, 1) 100%);
  433 + box-shadow: 0rpx 6rpx 40rpx rgba(136, 255, 0, 0.16);
  434 + color: rgba(255, 255, 255, 1);
  435 +}
  436 +
  437 +/* 遮罩层 */
  438 +
  439 +.mask {
  440 + width: 100%;
  441 + height: 100%;
  442 + position: fixed;
  443 + top: 0;
  444 + left: 0;
  445 + background: #000;
  446 + z-index: 9000;
  447 + opacity: 0.64;
  448 +}
  449 +
  450 +/* 弹出层 */
  451 +
  452 +.modalDlg {
  453 + width: 100%;
  454 + height: 454rpx;
  455 + bottom: 0;
  456 + position: fixed;
  457 + z-index: 9999;
  458 + background-color: #fff;
  459 +}
  460 +
  461 +.modalDlg_p {
  462 + padding: 0 30rpx;
  463 +}
  464 +
  465 +.m_top {
  466 + display: flex;
  467 +}
  468 +
  469 +.m_topTxt1 {
  470 + display: flex;
  471 + align-self: center;
  472 + justify-content: space-between;
  473 + margin-top: 30rpx;
  474 +}
  475 +
  476 +.m_topTxt {
  477 + width: 100%;
  478 + margin-left: 16rpx;
  479 +}
  480 +
  481 +.m_topImg {
  482 + margin-top: -48rpx;
  483 + display: flex;
  484 +}
  485 +
  486 +.m_topImg image {
  487 + width: 208rpx;
  488 + height: 208rpx;
  489 +}
  490 +
  491 +.m_topTxt1 image {
  492 + width: 32rpx;
  493 + height: 32rpx;
  494 +}
  495 +
  496 +.m_topName {
  497 + font-size: 32rpx;
  498 + font-family: PingFang SC;
  499 + font-weight: 600;
  500 + color: rgba(51, 51, 51, 1);
  501 +}
  502 +
  503 +.m_topTxt2 {
  504 + display: flex;
  505 + margin-top: 16rpx;
  506 + align-items: center;
  507 +}
  508 +
  509 +.m_topPrice {
  510 + width:120rpx;
  511 + overflow:hidden;
  512 + text-overflow:ellipsis;
  513 + white-space:nowrap;
  514 + font-size: 28rpx;
  515 + font-family: DIN 1451 Std Mittelschrift;
  516 + font-weight: 400;
  517 + color: #f00;
  518 +}
  519 +
  520 +.m_topHelf {
  521 + width:280rpx;
  522 + overflow:hidden;
  523 + text-overflow:ellipsis;
  524 + white-space:nowrap;
  525 + font-size: 22rpx;
  526 + font-family: PingFang SC;
  527 + font-weight: 400;
  528 + margin-left: 16rpx;
  529 + color: rgba(204, 204, 204, 1);
  530 +
  531 +}
  532 +
  533 +.m_number {
  534 + display: flex;
  535 + align-items: center;
  536 + margin-top: 18rpx;
  537 +}
  538 +
  539 +.minus_push {
  540 + display: flex;
  541 + margin-left: auto;
  542 + align-items: center;
  543 +}
  544 +
  545 +.m_numTxt {
  546 + font-size: 24rpx;
  547 + font-family: PingFang SC;
  548 + font-weight: 400;
  549 + color: rgba(153, 153, 153, 1);
  550 +}
  551 +
  552 +.minus, .push {
  553 + width: 48rpx;
  554 + height: 48rpx;
  555 + font-size: 40rpx;
  556 + text-align: center;
  557 + line-height: 48rpx;
  558 + border: 2px solid rgba(110, 172, 61, 1);
  559 + border-radius: 50%;
  560 +}
  561 +
  562 +.minus {
  563 + color: #6eac3d;
  564 +}
  565 +
  566 +.num {
  567 + margin: 0 26rpx;
  568 + font-size: 32rpx;
  569 + font-family: PingFang SC;
  570 + font-weight: 400;
  571 + color: rgba(110, 172, 61, 1);
  572 +}
  573 +
  574 +.push {
  575 + color: white;
  576 + background: rgba(110, 172, 61, 1);
  577 +}
  578 +
  579 +.m_btn {
  580 + width: 688rpx;
  581 + height: 80rpx;
  582 + border: 0;
  583 + margin-top: 62rpx;
  584 + font-size: 32rpx;
  585 + font-family: PingFang SC;
  586 + font-weight: 600;
  587 + color: rgba(255, 255, 255, 1);
  588 + background: linear-gradient(170deg, rgba(181, 222, 150, 1) 0%, rgba(169, 209, 33, 1) 100%);
  589 + box-shadow: 0rpx 6rpx 40rpx rgba(162, 255, 0, 0.15);
  590 + border-radius: 48rpx;
  591 +}
  592 +.wxParse-inline{
  593 + color:#999;
  594 + font-size: 30rpx;
  595 +}
  596 +.wxParse-p{
  597 + display:flex;
  598 + justify-content: center;
  599 + padding-bottom: 120rpx;
  600 +}
  601 +.wxParse-p image{
  602 + display:block
  603 +}
  604 +.kefu{
  605 + width:70rpx;
  606 + height:70rpx;
  607 + position:relative;
  608 +}
  609 +.icon-kefu{
  610 + font-size: 64rpx;
  611 + color:#6EAC3D;
  612 + margin-right:20rpx;
  613 +}
  614 +.remaindetail{
  615 + position: absolute;
  616 + top:0;
  617 + right:0;
  618 + background: transparent;
  619 + width:70rpx;
  620 + height:70rpx;
  621 +}
  622 +button::after{
  623 + outline:none;
  624 + border:none;
  625 +
  626 +}