stanley-king 4 gadi atpakaļ
vecāks
revīzija
d58d93a671

+ 4 - 6
Proxy.js

@@ -1,13 +1,11 @@
-
-let getSummeryGoods = function (goods_id, summery){
+let getSummeryGoods = function (goods_id, summery) {
   for (let i = 0; i < summery.length; i++) {
     let summery_goods = summery[i];
     if (summery_goods['goods_id'] == goods_id) {
-        return summery_goods;
-      }
+      return summery_goods;
     }
   }
+}
 
 
-
-module.exports.getSummeryGoods = getSummeryGoods; 
+module.exports.getSummeryGoods = getSummeryGoods;

+ 30 - 29
app.js

@@ -1,34 +1,35 @@
 //app.js
 import WxAuthor from './utils/WxAuthor'
+
 App({
-  onLaunch: function () {
-    let self = this;
-    // 登录
-    new WxAuthor(self)
- 
-  },
-  globalData: {
-    userId: {
-      openid: '',
-      unionid: ''
+    onLaunch: function () {
+        let self = this;
+        // 登录
+        new WxAuthor(self)
+
     },
-    userInfo: null,
-    defaultAddress: null,
-    fcodeErr: '',
-    backLogin: false,
-    arrayTree: [],
-    fromSource: ''
-  },
-  setFromSource(fromSource) {
-    this.globalData.fromSource = fromSource
-  },
-  checkDefaultAddress(address) {
-    this.globalData.defaultAddress = address
-  },
-  clearAddress() {
-    this.globalData.defaultAddress = null
-  },
-  setArrayTree(tree) {
-    this.globalData.arrayTree = tree
-  }
+    globalData: {
+        userId: {
+            openid: '',
+            unionid: ''
+        },
+        userInfo: null,
+        defaultAddress: null,
+        fcodeErr: '',
+        backLogin: false,
+        arrayTree: [],
+        fromSource: ''
+    },
+    setFromSource(fromSource) {
+        this.globalData.fromSource = fromSource
+    },
+    checkDefaultAddress(address) {
+        this.globalData.defaultAddress = address
+    },
+    clearAddress() {
+        this.globalData.defaultAddress = null
+    },
+    setArrayTree(tree) {
+        this.globalData.arrayTree = tree
+    }
 })

+ 2 - 1
app.json

@@ -54,5 +54,6 @@
   },
   "networkTimeout": {
     "request": 20000
-  }
+  },
+  "sitemapLocation": "sitemap.json"
 }

+ 1 - 5
app.wxss

@@ -1,7 +1,6 @@
 /**app.wxss**/
-
 page {
-  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", 微软雅黑, Arial, sans-serif;
+  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", '微软雅黑', Arial, sans-serif;
   background-color: #f7f7f7;
 }
 .container {
@@ -182,9 +181,6 @@ page {
 .l_height42 {
   line-height: 42rpx;
 }
-
-
-
 .f_left {
   float: left;
 }

+ 3 - 3
config.js

@@ -1,6 +1,6 @@
 
-let api = "https://passport.lrlz.com/mobile/index.php";
-// let api = "http://a.lrlz.com/mobile/index.php";
+// let api = "https://passport.lrlz.com/mobile/index.php";
+let api = "http://192.168.1.200/mobile/index.php";
 function getReq(data, callback, method) {
   let options = {
     client_type: 'mini'
@@ -48,10 +48,10 @@ function getReq(data, callback, method) {
           }
         }
       })
-
     }
   })
 }
+
 module.exports = {
   getReq,
   host: api

+ 1 - 1
pages/addAddress/addAddress.js

@@ -1,5 +1,5 @@
 // pages/addAddress/addAddress.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import trees from '../../areas.js'
 let appInstance = getApp()
 Page({

+ 1 - 1
pages/address/address.js

@@ -1,5 +1,5 @@
 // pages/address/address.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 let appInstance = getApp()
 Page({
 

+ 1 - 1
pages/brand/brand.js

@@ -1,4 +1,4 @@
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 import recordSource from '../../utils/recordSource';
 let app = getApp();
 Page({

+ 1 - 1
pages/comments/comments.js

@@ -1,5 +1,5 @@
 // pages/comments/comments.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource'
 let app = getApp()
 Page({

+ 1 - 1
pages/components/blockItem/blockItem.js

@@ -1,5 +1,5 @@
 // pages/components/blockItem/blockItem.js
-const getTypeSn = require('./../../../utils/util.js').getTypeSn;
+const getTypeSn = require('../../../utils/util.js').getTypeSn;
 Component({
   /**
    * 组件的属性列表

+ 1 - 1
pages/confirmOrder/confirmOrder.js

@@ -1,5 +1,5 @@
 // pages/confirmOrder/confirmOrder.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource';
 import Bundle from '../../utils/Bundle'
 let app = getApp()

+ 1 - 1
pages/details/details.js

@@ -1,6 +1,6 @@
 // pages/details/details.js
 
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 const app = getApp();
 import recordSource from '../../utils/recordSource';
 var WxParse = require('../../wxParse/wxParse.js');

+ 1 - 1
pages/discover/discover.js

@@ -1,5 +1,5 @@
 // pages/discover/discover.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 Page({
 
   /**

+ 1 - 1
pages/fcode/fcode.js

@@ -1,5 +1,5 @@
 // pages/fcode/fcode.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource'
 let app = getApp()
 Page({

+ 1 - 1
pages/handOutBonus/handOutBonus.js

@@ -1,5 +1,5 @@
 // pages/handOutBonus/handOutBonus.js
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 const app = getApp();
 import recordSource from '../../utils/recordSource';
 Page({

+ 2 - 2
pages/index/index.js

@@ -1,8 +1,8 @@
 let app = getApp();
 import recordSource from '../../utils/recordSource';
 import bonusUp from '../../utils/bonusUp';
-const getReq = require('./../../config.js').getReq;
-const getTypeSn = require('./../../utils/util.js').getTypeSn;
+const getReq = require('../../config.js').getReq;
+const getTypeSn = require('../../utils/util.js').getTypeSn;
 Page({
   data: {
     tabs: [],

+ 1 - 1
pages/login/login.js

@@ -1,6 +1,6 @@
 // pages/login/login.js
 const api = require('../../config.js');
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 let app = getApp();
 Page({
 

+ 1 - 1
pages/orderPaySn/orderPaySn.js

@@ -1,4 +1,4 @@
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource'
 let app = getApp()
 Page({

+ 1 - 1
pages/order_tabs/orderTabs.js

@@ -1,5 +1,5 @@
 // pages/order_tabs/orderTabs.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource'
 let app = getApp()
 Page({

+ 1 - 1
pages/person/person.js

@@ -1,7 +1,7 @@
 // pages/person/person.js
 const app = getApp();
 import recordSource from '../../utils/recordSource';
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 import bonusUp from '../../utils/bonusUp';
 
 Page({

+ 1 - 1
pages/search/search.js

@@ -1,5 +1,5 @@
 // pages/search/search.js
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import recordSource from '../../utils/recordSource'
 let app = getApp()
 Page({

+ 1 - 1
pages/shareBonus/shareBonus.js

@@ -1,6 +1,6 @@
 // pages/pandaBonus/pandaBonus.js
 const app = getApp();
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 Page({
 
   /**

+ 1 - 1
pages/shopCart/shopCart.js

@@ -1,4 +1,4 @@
-const getReq = require('./../../config.js').getReq
+const getReq = require('../../config.js').getReq
 import Bundle from '../../utils/Bundle'
 import recordSource from '../../utils/recordSource'
 import bonusUp from '../../utils/bonusUp';

+ 1 - 1
pages/special/special.js

@@ -1,5 +1,5 @@
 // pages/special/special.js
-const getReq = require('./../../config.js').getReq;
+const getReq = require('../../config.js').getReq;
 import recordSource from '../../utils/recordSource';
 let app = getApp();
 Page({

+ 25 - 3
project.config.json

@@ -3,15 +3,37 @@
 	"setting": {
 		"urlCheck": false,
 		"es6": true,
+		"enhance": false,
 		"postcss": true,
+		"preloadBackgroundData": false,
 		"minified": true,
-		"newFeature": true
+		"newFeature": true,
+		"coverView": true,
+		"nodeModules": false,
+		"autoAudits": false,
+		"showShadowRootInWxmlPanel": true,
+		"scopeDataCheck": false,
+		"uglifyFileName": false,
+		"checkInvalidKey": true,
+		"checkSiteMap": true,
+		"uploadWithSourceMap": true,
+		"compileHotReLoad": false,
+		"babelSetting": {
+			"ignore": [],
+			"disablePlugins": [],
+			"outputPath": ""
+		},
+		"useIsolateContext": true,
+		"useCompilerModule": false,
+		"userConfirmedUseCompilerModuleSwitch": false
 	},
 	"compileType": "miniprogram",
-	"libVersion": "1.9.91",
-	"appid": "wxfdaeb25e38c4c47e",
+	"libVersion": "2.11.2",
+	"appid": "wx41c4be947a99bc26",
 	"projectname": "panda_small_%20routine",
 	"isGameTourist": false,
+	"simulatorType": "wechat",
+	"simulatorPluginLibVersion": {},
 	"condition": {
 		"search": {
 			"current": -1,

+ 7 - 0
sitemap.json

@@ -0,0 +1,7 @@
+{
+  "desc": "关于本文件的更多信息,请参考文档 https://developers.weixin.qq.com/miniprogram/dev/framework/sitemap.html",
+  "rules": [{
+  "action": "allow",
+  "page": "*"
+  }]
+}

+ 1 - 1
utils/WxAuthor.js

@@ -1,5 +1,5 @@
 const getReq = require('../config.js').getReq
-const api = require('../config.js').host
+const api    = require('../config.js').host
 export default class WxAuthor {
   constructor(app) {
     this.target = app