panhui 6 лет назад
Родитель
Сommit
5a226f55c7
75 измененных файлов с 4363 добавлено и 134 удалено
  1. 35 0
      css/main.css
  2. 1 1
      css/main.css.map
  3. 59 3
      project.config.json
  4. 12 2
      src/App.vue
  5. 15 18
      src/Constants.js
  6. 37 21
      src/app.json
  7. 530 0
      src/components/OrderItem.vue
  8. 122 12
      src/components/ShoppingCart.vue
  9. 1 1
      src/components/SpecificationsContent.vue
  10. 172 0
      src/components/SubOrder copy.vue
  11. 172 0
      src/components/SubOrder.vue
  12. 87 0
      src/components/UserOrderItem.vue
  13. 47 4
      src/main.less
  14. 5 0
      src/pages/caseDetail/caseDetail.js
  15. 3 0
      src/pages/caseDetail/caseDetail.json
  16. 46 0
      src/pages/caseDetail/caseDetail.vue
  17. 5 0
      src/pages/caseList/caseList.js
  18. 0 0
      src/pages/caseList/caseList.json
  19. 97 0
      src/pages/caseList/caseList.vue
  20. 5 0
      src/pages/changeUser/changeUser.js
  21. 3 0
      src/pages/changeUser/changeUser.json
  22. 156 0
      src/pages/changeUser/changeUser.vue
  23. 5 0
      src/pages/evaluate/evaluate.js
  24. 4 0
      src/pages/evaluate/evaluate.json
  25. 307 0
      src/pages/evaluate/evaluate.vue
  26. 15 23
      src/pages/home/home.vue
  27. 5 0
      src/pages/orderDetail/orderDetail.js
  28. 7 0
      src/pages/orderDetail/orderDetail.json
  29. 263 0
      src/pages/orderDetail/orderDetail.vue
  30. 5 0
      src/pages/orderList/orderList.js
  31. 5 0
      src/pages/orderList/orderList.json
  32. 233 0
      src/pages/orderList/orderList.vue
  33. 145 5
      src/pages/product/product.vue
  34. 5 0
      src/pages/productList/productList.js
  35. 4 0
      src/pages/productList/productList.json
  36. 196 0
      src/pages/productList/productList.vue
  37. 5 0
      src/pages/search/search.js
  38. 3 0
      src/pages/search/search.json
  39. 293 0
      src/pages/search/search.vue
  40. 5 0
      src/pages/serviceDetail/serviceDetail.js
  41. 3 0
      src/pages/serviceDetail/serviceDetail.json
  42. 122 0
      src/pages/serviceDetail/serviceDetail.vue
  43. 5 0
      src/pages/serviceList/serviceList.js
  44. 3 0
      src/pages/serviceList/serviceList.json
  45. 97 0
      src/pages/serviceList/serviceList.vue
  46. 44 4
      src/pages/setting/setting.vue
  47. 224 13
      src/pages/shoppingCart/shoppingCart.vue
  48. 138 11
      src/pages/storeInfo/storeInfo.vue
  49. 5 0
      src/pages/submit/submit.js
  50. 4 0
      src/pages/submit/submit.json
  51. 414 0
      src/pages/submit/submit.vue
  52. 5 0
      src/pages/successPage/successPage.js
  53. 3 0
      src/pages/successPage/successPage.json
  54. 99 0
      src/pages/successPage/successPage.vue
  55. 0 0
      src/pages/user copy 2/user.js
  56. 3 0
      src/pages/user copy 2/user.json
  57. 0 0
      src/pages/user copy 2/user.vue
  58. 25 15
      src/pages/user/user.vue
  59. 54 1
      src/utils/http.js
  60. BIN
      static/images/Rectangle 29.png
  61. BIN
      static/images/dingdan_icon_shenpian.png
  62. BIN
      static/images/dingdan_icon_xuanpian.png
  63. BIN
      static/images/icon_shangchuantupian.png
  64. BIN
      static/images/icon_weizhi (1).png
  65. BIN
      static/images/icon_weizhi (2).png
  66. BIN
      static/images/icon_weizhi_1.png
  67. BIN
      static/images/kong_icon_dingdan.png
  68. BIN
      static/images/kong_icon_gouwuche.png
  69. BIN
      static/images/kong_icon_sousuo.png
  70. BIN
      static/images/nav_icon_return.png
  71. BIN
      static/images/popup_icon_success_colour.png
  72. BIN
      static/images/search_iocn_lishi.png
  73. BIN
      static/images/search_iocn_remen.png
  74. BIN
      static/images/xiangqing_icon_kefu(1).png
  75. BIN
      static/images/xiangqing_icon_kefu@3x.png

+ 35 - 0
css/main.css

@@ -7,4 +7,39 @@
   font-size: 24rpx;
   font-size: 24rpx;
   color: #999999;
   color: #999999;
 }
 }
+.price::before {
+  content: '¥';
+}
+.nothing {
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  padding: 53px 0 20px;
+}
+.nothing img {
+  width: 110px;
+  height: 110px;
+}
+.nothing .title {
+  font-size: 16px;
+  color: #000000;
+  line-height: 22px;
+  margin-top: 25px;
+}
+.nothing .sub {
+  font-size: 13px;
+  color: #999999;
+  line-height: 18px;
+  margin-top: 6px;
+}
+.nothing button {
+  width: 110px;
+  height: 36px;
+  line-height: 36px;
+  font-size: 14px;
+  color: #00c5f2;
+  border-radius: 22px;
+  border: 1px solid #00c5f2;
+  margin-top: 20px;
+}
 /*# sourceMappingURL=./main.css.map */
 /*# sourceMappingURL=./main.css.map */

+ 1 - 1
css/main.css.map

@@ -1 +1 @@
-{"version":3,"sources":["../src/main.less"],"names":[],"mappings":"AAAA;EACI,gBAAA;EACA,iBAAA;EACA,cAAA;;AAGJ;EACI,gBAAA;EACA,cAAA"}
+{"version":3,"sources":["../src/main.less"],"names":[],"mappings":"AAAA;EACE,gBAAA;EACA,iBAAA;EACA,cAAA;;AAGF;EACE,gBAAA;EACA,cAAA;;AAIA,MAAC;EACC,SAAS,GAAT;;AAIJ;EACE,aAAA;EACA,sBAAA;EACA,mBAAA;EACA,oBAAA;;AAJF,QAME;EACE,YAAA;EACA,aAAA;;AARJ,QAWE;EACE,eAAA;EACA,cAAA;EACA,iBAAA;EACA,gBAAA;;AAfJ,QAkBE;EACE,eAAA;EACA,cAAA;EACA,iBAAA;EACA,eAAA;;AAtBJ,QAyBE;EACE,YAAA;EACA,YAAA;EACA,iBAAA;EACA,eAAA;EACA,cAAA;EACA,mBAAA;EACA,yBAAA;EACA,gBAAA"}

+ 59 - 3
project.config.json

@@ -33,13 +33,13 @@
 			"list": []
 			"list": []
 		},
 		},
 		"miniprogram": {
 		"miniprogram": {
-			"current": 0,
+			"current": 9,
 			"list": [
 			"list": [
 				{
 				{
 					"id": 0,
 					"id": 0,
 					"name": "商品详情",
 					"name": "商品详情",
-					"pathName": "pages/storeInfo/storeInfo",
-					"query": "",
+					"pathName": "pages/product/product",
+					"query": "id=9",
 					"scene": null
 					"scene": null
 				},
 				},
 				{
 				{
@@ -48,6 +48,62 @@
 					"pathName": "pages/setting/setting",
 					"pathName": "pages/setting/setting",
 					"query": "",
 					"query": "",
 					"scene": null
 					"scene": null
+				},
+				{
+					"id": 2,
+					"name": "摄影师详情",
+					"pathName": "pages/caseDetail/caseDetail",
+					"query": "id=1",
+					"scene": null
+				},
+				{
+					"id": 3,
+					"name": "购物车",
+					"pathName": "pages/shoppingCart/shoppingCart",
+					"query": "",
+					"scene": null
+				},
+				{
+					"id": 4,
+					"name": "摄影师详情",
+					"pathName": "pages/submit/submit",
+					"query": "submitPage=shoppingCart&chooseList=9,5",
+					"scene": null
+				},
+				{
+					"id": -1,
+					"name": "搜索",
+					"pathName": "pages/search/search",
+					"query": "",
+					"scene": null
+				},
+				{
+					"id": -1,
+					"name": "搜索",
+					"pathName": "pages/successPage/successPage",
+					"query": "pageType=paySuccess",
+					"scene": null
+				},
+				{
+					"id": -1,
+					"name": "订单列表",
+					"pathName": "pages/orderList/orderList",
+					"query": "",
+					"scene": null
+				},
+				{
+					"id": -1,
+					"name": "评价",
+					"pathName": "pages/evaluate/evaluate",
+					"query": "orderId=19",
+					"scene": null
+				},
+				{
+					"id": 9,
+					"name": "订单详情",
+					"pathName": "pages/orderDetail/orderDetail",
+					"query": "orderId=26&index=3",
+					"scene": null
 				}
 				}
 			]
 			]
 		}
 		}

+ 12 - 2
src/App.vue

@@ -8,9 +8,20 @@ export default {
         });
         });
         try {
         try {
             var token = wx.getStorageSync('token');
             var token = wx.getStorageSync('token');
-            console.log(token)
+            console.log(token);
             if (token) {
             if (token) {
                 this.$http.setToken(token);
                 this.$http.setToken(token);
+
+                this.$http
+                    .get('/userInfo/getUserInfo')
+                    .then(res => {
+                        if (res.success) {
+                            this.$store.commit('updateUserInfo', res.data);
+                        }
+                    })
+                    .catch(e => {
+                        console.log(e);
+                    });
             } else {
             } else {
                 // this.$http
                 // this.$http
                 //     .post('/auth/login', {
                 //     .post('/auth/login', {
@@ -36,7 +47,6 @@ export default {
                 url: '/pages/login/login',
                 url: '/pages/login/login',
             });
             });
         }
         }
-
     },
     },
     created() {
     created() {
         // 调用API从本地缓存中获取数据
         // 调用API从本地缓存中获取数据

+ 15 - 18
src/Constants.js

@@ -1,24 +1,21 @@
-exports.UploadStatus = {
-    PREPARING: -1,
-    WAITING: 1,
-    UPLOADING: 2,
-    PAUSE: 3,
-    FINISHED: 4,
-    ERROR: 5,
-};
-
-exports.DownloadStatus = {
-    PREPARING: -1,
-    WAITING: 1,
-    DOWNLOADING: 2,
-    PAUSE: 3,
-    FINISHED: 4,
-    ERROR: 5,
-};
-
 exports.PayMode = {
 exports.PayMode = {
     ALIPAY: 0,
     ALIPAY: 0,
     WEI_XIN: 1,
     WEI_XIN: 1,
     COIN: 2,
     COIN: 2,
     CLIENT: 3,
     CLIENT: 3,
+};
+
+exports.OrderStatus = {
+    NOPAY: 0, //下单,待付款
+    PAYOVER: 1, //支付完成,待预约拍照
+    BOOKPHOTO: 2, //预约完成,待拍照
+    PHOTOOVER: 3, //拍照完成
+    BOOKSELECT: 4, //预约选片
+    SELECTOVER: 5, //选片完成
+    BOOKCHECK: 6, //审片预约
+    CHECKOVER: 7, //审片完成
+    BOOKACCESS: 8, //预约取件
+    ACCESSOVER: 9, //取件完成
+    FINISH: 10, //成功
+    CANCEL: 11, //取消
 };
 };

+ 37 - 21
src/app.json

@@ -8,7 +8,19 @@
         "pages/setting/setting",
         "pages/setting/setting",
         "pages/product/product",
         "pages/product/product",
         "pages/storeInfo/storeInfo",
         "pages/storeInfo/storeInfo",
-        "pages/webView/webView"
+        "pages/webView/webView",
+        "pages/serviceDetail/serviceDetail",
+        "pages/caseDetail/caseDetail",
+        "pages/serviceList/serviceList",
+        "pages/caseList/caseList",
+        "pages/submit/submit",
+        "pages/search/search",
+        "pages/productList/productList",
+        "pages/successPage/successPage",
+        "pages/changeUser/changeUser",
+        "pages/orderList/orderList",
+        "pages/evaluate/evaluate",
+        "pages/orderDetail/orderDetail"
     ],
     ],
     "window": {
     "window": {
         "backgroundTextStyle": "light",
         "backgroundTextStyle": "light",
@@ -22,26 +34,30 @@
         "borderStyle": "white",
         "borderStyle": "white",
 
 
         "list": [{
         "list": [{
-            "text": "首页",
-            "pagePath": "pages/home/home",
-            "iconPath": "static/tabs/tabbar_icon_01.png",
-            "selectedIconPath": "static/tabs/tabbar_icon_01_pre.png"
-        }, {
-            "text": "商品",
-            "pagePath": "pages/classify/classify",
-            "iconPath": "static/tabs/tabbar_icon_02.png",
-            "selectedIconPath": "static/tabs/tabbar_icon_02_pre.png"
-        }, {
-            "text": "购物车",
-            "pagePath": "pages/shoppingCart/shoppingCart",
-            "iconPath": "static/tabs/tabbar_icon_03.png",
-            "selectedIconPath": "static/tabs/tabbar_icon_03_pre.png"
-        }, {
-            "text": "我的",
-            "pagePath": "pages/user/user",
-            "iconPath": "static/tabs/tabbar_icon_04.png",
-            "selectedIconPath": "static/tabs/tabbar_icon_04_pre.png"
-        }],
+                "text": "首页",
+                "pagePath": "pages/home/home",
+                "iconPath": "static/tabs/tabbar_icon_01.png",
+                "selectedIconPath": "static/tabs/tabbar_icon_01_pre.png"
+            },
+            {
+                "text": "商品",
+                "pagePath": "pages/classify/classify",
+                "iconPath": "static/tabs/tabbar_icon_02.png",
+                "selectedIconPath": "static/tabs/tabbar_icon_02_pre.png"
+            },
+            {
+                "text": "购物车",
+                "pagePath": "pages/shoppingCart/shoppingCart",
+                "iconPath": "static/tabs/tabbar_icon_03.png",
+                "selectedIconPath": "static/tabs/tabbar_icon_03_pre.png"
+            },
+            {
+                "text": "我的",
+                "pagePath": "pages/user/user",
+                "iconPath": "static/tabs/tabbar_icon_04.png",
+                "selectedIconPath": "static/tabs/tabbar_icon_04_pre.png"
+            }
+        ],
         "position": "bottom"
         "position": "bottom"
     }
     }
 }
 }

+ 530 - 0
src/components/OrderItem.vue

@@ -0,0 +1,530 @@
+<template>
+    <div class='order'>
+        <div class="orderTop">
+            <span>{{info.statusFlag==0?'支付单号:':'订单号:'}}{{info.orderCode}}</span>
+
+            <span>{{statusName}}</span>
+        </div>
+        <div @click="goDetail" class="orderInfo" v-for="(item,index) in productList" :key="index">
+            <img class="image" v-if="item.productInfo.image" :src="item.productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
+            <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
+            <div class="content">
+                <div class="title">{{item.productInfo.title}}</div>
+                <div class="sub">{{item.typeFlag==0?"全款支付":"定金支付"}}</div>
+                <div class="moeny">
+                    <span class="price">{{item.typeFlag==0?item.productInfo.price:item.productInfo.downPayment}}</span>
+                    <span class="num">{{item.quantity}}</span>
+                </div>
+            </div>
+        </div>
+
+        <div class="total">
+            <span>实际支付:</span>
+            <span class="price">{{info.dealPrice}}</span>
+        </div>
+
+        <div class="btnList">
+            <div class="btn-item" v-for="(item,index) in btnList" :key="index">
+                <button :class="[item.type]" :open-type='item.openType' @click="clickEvent(item.name)">{{item.name}}</button>
+                <picker class="picker" v-if="item.name=='立即预约'" mode="date" :start="nowDate" @change="bindDateChange">
+                    <view class="picker">
+                        当前选择: {{date}}
+                    </view>
+                </picker>
+            </div>
+        </div>
+    </div>
+</template>
+<script>
+import { mapState } from 'vuex';
+import { OrderStatus } from '../Constants';
+export default {
+    name: 'orderItem',
+    props: {
+        info: {
+            type: Object,
+            default: () => {
+                return {};
+            },
+        },
+        index: {
+            type: Number,
+            default: 0,
+        },
+        orderIndex: {
+            type: String,
+            default: '',
+        },
+    },
+    computed: {
+        ...mapState(['userInfo']),
+        productList() {
+            if (this.info.productList) {
+                return this.info.productList;
+            } else {
+                return [this.info];
+            }
+        },
+        statusName() {
+            var name = '';
+            if (this.info.statusFlag == OrderStatus.NOPAY) {
+                name = '待支付';
+            } else if (this.info.statusFlag == OrderStatus.PAYOVER) {
+                name = '待预约拍照';
+            } else if (this.info.statusFlag == OrderStatus.BOOKPHOTO) {
+                name = '待拍照';
+            } else if (this.info.statusFlag == OrderStatus.PHOTOOVER) {
+                name = '待预约选片';
+            } else if (this.info.statusFlag == OrderStatus.BOOKSELECT) {
+                name = '待选片';
+            } else if (this.info.statusFlag == OrderStatus.SELECTOVER) {
+                name = '待预约审片';
+            } else if (this.info.statusFlag == OrderStatus.BOOKCHECK) {
+                name = '待审片';
+            } else if (this.info.statusFlag == OrderStatus.CHECKOVER) {
+                name = '待预约取件';
+            } else if (this.info.statusFlag == OrderStatus.BOOKACCESS) {
+                name = '待取件';
+            } else if (this.info.statusFlag == OrderStatus.ACCESSOVER) {
+                name = '待评价';
+            } else if (this.info.statusFlag == OrderStatus.FINISH) {
+                name = '已完成';
+            } else if (this.info.statusFlag == OrderStatus.CANCEL) {
+                name = '取消';
+            }
+
+            return name;
+        },
+        btnList() {
+            var list = [];
+
+            if (this.info.statusFlag == OrderStatus.NOPAY) {
+                list = [
+                    {
+                        name: '取消订单',
+                    },
+                    {
+                        name: '立即支付',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.PAYOVER) {
+                list = [
+                    {
+                        name: '联系客服',
+                        openType: 'contact',
+                    },
+                    {
+                        name: '立即预约',
+                        now: '拍照',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.BOOKPHOTO) {
+                list = [
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.PHOTOOVER) {
+                list = [
+                    {
+                        name: '联系客服',
+                        openType: 'contact',
+                    },
+                    {
+                        name: '立即预约',
+                        now: '选片',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.BOOKSELECT) {
+                list = [
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.SELECTOVER) {
+                list = [
+                    {
+                        name: '联系客服',
+                        openType: 'contact',
+                    },
+                    {
+                        name: '立即预约',
+                        now: '审片',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.BOOKCHECK) {
+                list = [
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.CHECKOVER) {
+                list = [
+                    {
+                        name: '联系客服',
+                        openType: 'contact',
+                    },
+                    {
+                        name: '立即预约',
+                        now: '取件',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.BOOKACCESS) {
+                list = [
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.ACCESSOVER) {
+                list = [
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                    {
+                        name: '立即评价',
+                        type: 'primary',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.FINISH) {
+                list = [
+                    {
+                        name: '删除订单',
+                    },
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            } else if (this.info.statusFlag == OrderStatus.CANCEL) {
+                list = [
+                    {
+                        name: '删除订单',
+                    },
+                    {
+                        name: '查看订单',
+                        type: 'line',
+                    },
+                ];
+            }
+
+            return list;
+        },
+        nowDate() {
+            const date = new Date();
+            const year = date.getFullYear();
+            const month = date.getMonth() + 1;
+            const day = date.getDate() + 1;
+
+            return year + '-' + month + '-' + day;
+        },
+    },
+    data() {
+        return {};
+    },
+    methods: {
+        goDetail() {
+            wx.navigateTo({
+                url:
+                    '/pages/orderDetail/orderDetail?orderId=' +
+                    this.info.id +
+                    '&index=' +
+                    (this.orderIndex || this.index),
+            });
+        },
+        clickEvent(name) {
+            if (name == '立即支付') {
+                wx.navigateTo({
+                    url: '/pages/submit/submit?orderId=' + this.info.id,
+                });
+            } else if (name == '取消订单') {
+                var ref = this;
+                wx.showModal({
+                    title: '提示',
+                    content: '确定要取消该订单吗?',
+                    confirmColor: '#00C5F2',
+                    success(res) {
+                        if (res.confirm) {
+                            ref.$emit('cancelOrder');
+                        } else if (res.cancel) {
+                        }
+                    },
+                });
+            } else if (name == '立即评价') {
+                wx.navigateTo({
+                    url:
+                        '/pages/evaluate/evaluate?orderId=' +
+                        this.info.id +
+                        '&index=' +
+                        (this.orderIndex || this.index),
+                });
+            }
+            else if(name=='查看订单'){
+                this.goDetail()
+            }
+        },
+        bindDateChange(e) {
+            var ref = this;
+            wx.showModal({
+                title: '已选择:' + e.mp.detail.value,
+                content: ' 确定要预约当前日期吗?',
+                confirmColor: '#00C5F2',
+                success(res) {
+                    if (res.confirm) {
+                        var data = {
+                            id: ref.info.id,
+                        };
+                        if (ref.statusName == '待预约拍照') {
+                            data.bookPhotoTime = Date.parse(
+                                new Date(e.mp.detail.value),
+                            );
+                            data.statusFlag = OrderStatus.BOOKPHOTO;
+                        } else if (ref.statusName == '待预约选片') {
+                            data.bookSelectTime = Date.parse(
+                                new Date(e.mp.detail.value),
+                            );
+                            data.statusFlag = OrderStatus.BOOKSELECT;
+                        } else if (ref.statusName == '待预约审片') {
+                            data.bookCheckTime = Date.parse(
+                                new Date(e.mp.detail.value),
+                            );
+                            data.statusFlag = OrderStatus.BOOKCHECK;
+                        } else if (ref.statusName == '待预约取件') {
+                            data.bookAccessTime = Date.parse(
+                                new Date(e.mp.detail.value),
+                            );
+                            data.statusFlag = OrderStatus.BOOKACCESS;
+                        }
+
+                        wx.showLoading({
+                            title: '加载中',
+                            mask: true,
+                        });
+                        ref.$http
+                            .post('/userOrderDetail/update', data)
+                            .then(res => {
+                                wx.hideLoading();
+                                if (res.success) {
+                                    ref.$emit('update', ref.index);
+                                    wx.showToast({
+                                        title: '预约成功',
+                                        icon: 'success',
+                                        duration: 1500,
+                                    });
+                                } else {
+                                    wx.showToast({
+                                        title: res.error,
+                                        icon: 'none',
+                                        duration: 1500,
+                                    });
+                                }
+                            });
+                    } else if (res.cancel) {
+                    }
+                },
+            });
+        },
+    },
+};
+</script>
+<style lang='less' scoped>
+.order {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 8px;
+    padding: 0 15px;
+    margin: 15px 15px 0;
+}
+
+.hr {
+    height: 1px;
+    background-color: #f2f4f5;
+}
+
+.orderInfo {
+    display: flex;
+    // border-bottom: 1px solid #f2f4f5;
+    padding: 15px 0 0;
+
+    .image {
+        width: 80px;
+        height: 80px;
+        border-radius: 4px;
+    }
+
+    .content {
+        flex-grow: 1;
+        margin-left: 10px;
+
+        .title {
+            font-size: 14px;
+            color: rgba(0, 0, 0, 1);
+            line-height: 20px;
+        }
+
+        .sub {
+            font-size: 12px;
+            color: rgba(170, 172, 173, 1);
+            line-height: 17px;
+            margin-top: 5px;
+        }
+
+        .moeny {
+            display: flex;
+            justify-content: space-between;
+            margin-top: 18px;
+
+            .price {
+                font-size: 14px;
+                font-weight: bold;
+                color: rgba(0, 0, 0, 1);
+                line-height: 20px;
+            }
+
+            .num {
+                font-size: 14px;
+                color: rgba(170, 172, 173, 1);
+                line-height: 20px;
+                &::before {
+                    content: 'x';
+                }
+            }
+        }
+    }
+}
+
+.order-item {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    height: 40px;
+
+    .name {
+        font-size: 13px;
+        color: rgba(56, 56, 56, 1);
+    }
+
+    .val {
+        font-size: 14px;
+        color: rgba(0, 0, 0, 1);
+        flex-grow: 1;
+        text-align: right;
+
+        &.notSet {
+            color: #999;
+        }
+    }
+
+    .placeholder {
+        font-size: 12px;
+        color: rgba(170, 172, 173, 1);
+    }
+}
+
+.submit {
+    line-height: 40px;
+    text-align: right;
+    font-size: 12px;
+    color: rgba(56, 56, 56, 1);
+
+    .price {
+        color: rgba(255, 59, 48, 1);
+    }
+}
+
+.orderTop {
+    height: 44px;
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    border-bottom: 1px solid #f2f4f5;
+
+    span {
+        &:first-child {
+            font-size: 13px;
+            color: rgba(0, 0, 0, 1);
+            line-height: 18px;
+        }
+
+        &:last-child {
+            font-size: 13px;
+            font-weight: bold;
+            color: rgba(0, 197, 242, 1);
+            line-height: 18px;
+        }
+    }
+}
+
+.total {
+    height: 50px;
+    display: flex;
+    align-items: center;
+    justify-content: flex-end;
+    span {
+        &:first-child {
+            font-size: 12px;
+            color: rgba(102, 102, 102, 1);
+            line-height: 17px;
+        }
+
+        &:last-child {
+            font-size: 16px;
+            font-weight: bold;
+            color: #ff3b30;
+            line-height: 22px;
+        }
+    }
+}
+
+.btnList {
+    display: flex;
+    align-items: center;
+    justify-content: flex-end;
+    height: 58px;
+    border-top: 1px solid #f2f4f5;
+
+    button {
+        width: 76px;
+        height: 28px;
+        border-radius: 18px;
+        font-size: 12px;
+        line-height: 28px;
+        border: 1px solid rgba(170, 172, 173, 1);
+        color: #aaacad;
+        padding: 0;
+        margin: 0 0 0 10px;
+        background-color: #fff;
+
+        &.line {
+            border: 1px solid rgba(0, 197, 242, 1);
+            color: #00c5f2;
+        }
+
+        &.primary {
+            background: rgba(0, 197, 242, 1);
+            border: 1px solid rgba(0, 197, 242, 1);
+            color: #fff;
+        }
+    }
+
+    .btn-item {
+        position: relative;
+        .picker {
+            position: absolute;
+            left: 0;
+            top: 0;
+            right: 0;
+            bottom: 0;
+            opacity: 0;
+        }
+    }
+}
+</style>

+ 122 - 12
src/components/ShoppingCart.vue

@@ -1,55 +1,164 @@
 <template>
 <template>
     <div class='shoopingCart'>
     <div class='shoopingCart'>
-        <img v-if="isChoose" src="/static/images/gouwuche_icon_xuanzhong.png" class="leftIcon" alt="">
-        <img v-else src="/static/images/gouwuche_icon_weixuanzhong.png" class="leftIcon" alt="">
+        <div @click="choose">
+            <img v-if="isChoose" src="/static/images/gouwuche_icon_xuanzhong.png" class="leftIcon" alt="">
+            <img v-else src="/static/images/gouwuche_icon_weixuanzhong.png" class="leftIcon" alt="">
+        </div>
 
 
-        <img src="/static/images/home_banner_01.png" class="productImg" background-size="cover" alt="">
+        <img class="productImg" v-if="productInfo.image" :src="productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
+        <img class="productImg" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
 
 
         <div class="content">
         <div class="content">
-            <div class="title">告白系列高端修图套餐</div>
+            <div class="title">{{productInfo.title}}</div>
 
 
-            <div class="lable">
-                <span>定金支付</span>
+            <div class="lable" @click="showSpecifications=true">
+                <span>{{info.typeFlag==0?'全款支付':'定金支付'}}</span>
                 <img src="/static/images/gouwuche_icon_zhankai.png" alt="">
                 <img src="/static/images/gouwuche_icon_zhankai.png" alt="">
             </div>
             </div>
 
 
             <div class="money">
             <div class="money">
-                <div class="price">1200</div>
+                <div class="price">{{info.typeFlag==0?productInfo.price:productInfo.downPayment}}</div>
                 <div class="num">
                 <div class="num">
                     <img v-if="num>1" @click="subNum" src="/static/images/icon_jianqu.png" alt="">
                     <img v-if="num>1" @click="subNum" src="/static/images/icon_jianqu.png" alt="">
                     <img v-else src="/static/images/icon_jianqu_dis.png" alt="">
                     <img v-else src="/static/images/icon_jianqu_dis.png" alt="">
-                    <input type="number" v-model="num" confirm-type='done' @input="checkNum" />
+                    <input type="number" v-model="num" confirm-type='done' @blur="checkNum" />
                     <img v-if="num<100" @click="addNum" src="/static/images/icon_zengjia.png" alt="">
                     <img v-if="num<100" @click="addNum" src="/static/images/icon_zengjia.png" alt="">
                     <img v-else src="/static/images/icon_zengjia_dis.png" alt="">
                     <img v-else src="/static/images/icon_zengjia_dis.png" alt="">
                 </div>
                 </div>
             </div>
             </div>
         </div>
         </div>
 
 
+        <specificationsContent :visible='showSpecifications' :productInfo='productInfo' @close='showSpecifications=false' :totalMoney='totalMoney' :chooseType='chooseType' :chooseNum='num' @changeType='changeType' @changeNum='changeNum' @changeChoose='goWaiting'></specificationsContent>
+
     </div>
     </div>
 </template>
 </template>
 <script>
 <script>
 import { mapState } from 'vuex';
 import { mapState } from 'vuex';
+import specificationsContent from './SpecificationsContent';
+import calc from '../calc';
 export default {
 export default {
     name: '',
     name: '',
     data() {
     data() {
         return {
         return {
-            isChoose: false,
             num: 1,
             num: 1,
+            showSpecifications: false,
+            chooseType: 'all',
         };
         };
     },
     },
+    props: {
+        info: {
+            type: Object,
+            default: () => {
+                return {};
+            },
+        },
+        index: {
+            type: Number,
+            default: 0,
+        },
+        chooseList: {
+            type: Array,
+            default: () => {
+                return [];
+            },
+        },
+    },
     computed: {
     computed: {
         ...mapState(['userInfo']),
         ...mapState(['userInfo']),
+        productInfo() {
+            return this.info.productInfo || {};
+        },
+        totalMoney() {
+            var money = 0;
+            if (this.info.typeFlag == 'all') {
+                money = calc.Mul(this.info.amount, this.productInfo.price);
+            } else if (this.productInfo.downPayment) {
+                money = calc.Mul(
+                    this.info.amount,
+                    this.productInfo.downPayment,
+                );
+            }
+            return money;
+        },
+        isChoose() {
+            var result = false;
+            if (this.chooseList.indexOf(this.info.id) != -1) {
+                result = true;
+            }
+            return result;
+        },
+    },
+    watch: {
+        'info.amount'() {
+            this.num = Number(this.info.amount);
+        },
+        'info.typeFlag'() {
+            this.chooseType = this.info.typeFlag == 0 ? 'all' : 'down';
+        },
+    },
+    onLoad() {
+        console.log('aaaaa');
+        this.num = Number(this.info.amount);
+        this.chooseType = this.info.typeFlag == 0 ? 'all' : 'down';
     },
     },
     methods: {
     methods: {
         addNum() {
         addNum() {
-            this.num = Number(this.num) + 1;
+            this.updateCart(Number(this.num) + 1);
         },
         },
         subNum() {
         subNum() {
-            this.num = Number(this.num) - 1;
+            this.updateCart(Number(this.num) - 1);
         },
         },
         checkNum() {
         checkNum() {
-            this.num = Number(this.num);
+            if (!this.num) {
+                this.num = 1;
+            }
+            this.updateCart(Number(this.num));
+        },
+        updateCart(amount, typeFlag) {
+            var data = {
+                id: this.info.id,
+                amount: amount,
+            };
+            if (typeFlag || typeFlag == 0) {
+                data.typeFlag = typeFlag;
+            }
+            wx.showLoading({
+                title: '加载中',
+            });
+            this.$http
+                .post('/shoppingCart/update', data)
+                .then(res => {
+                    wx.hideLoading();
+                    if (res.success) {
+                        this.$emit('updateAmount', {
+                            index: this.index,
+                            amount,
+                            typeFlag:
+                                typeFlag || typeFlag == 0
+                                    ? typeFlag
+                                    : this.info.typeFlag,
+                        });
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
         },
         },
+        changeType(type) {
+            this.chooseType = type;
+        },
+        changeNum(num) {
+            this.num = num;
+        },
+        goWaiting() {
+            this.updateCart(Number(this.num), this.chooseType == 'all' ? 0 : 1);
+        },
+        choose() {
+            this.$emit('choose', this.info.id);
+        },
+    },
+    components: {
+        specificationsContent,
     },
     },
 };
 };
 </script>
 </script>
@@ -75,6 +184,7 @@ export default {
         height: 160rpx;
         height: 160rpx;
         background: rgba(242, 244, 245, 1);
         background: rgba(242, 244, 245, 1);
         border-radius: 4px;
         border-radius: 4px;
+        margin-left: 15px;
     }
     }
 }
 }
 
 

+ 1 - 1
src/components/SpecificationsContent.vue

@@ -4,7 +4,7 @@
             <img class="image" v-if="productInfo.image" :src="productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
             <img class="image" v-if="productInfo.image" :src="productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
             <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
             <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
             <div class="price">
             <div class="price">
-                {{totalMoney}}
+                {{chooseType=='all'?productInfo.price:productInfo.downPayment}}
             </div>
             </div>
 
 
             <div class="chosse">
             <div class="chosse">

+ 172 - 0
src/components/SubOrder copy.vue

@@ -0,0 +1,172 @@
+<template>
+    <div class='order'>
+        <div class="orderInfo" v-for="(item,index) in list" :key="index">
+            <img class="image" v-if="item.productInfo.image" :src="item.productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
+            <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
+            <div class="content">
+                <div class="title">{{item.productInfo.title}}</div>
+                <div class="sub">{{item.typeFlag==0?"全款支付":"定金支付"}}</div>
+                <div class="moeny">
+                    <span class="price">{{item.typeFlag==0?item.productInfo.price:item.productInfo.downPayment}}</span>
+                    <span class="num">{{item.quantity}}</span>
+                </div>
+            </div>
+        </div>
+
+        <div class="hr"></div>
+
+        <div class="order-item">
+            <div class="name">消费方式</div>
+            <div class="val">到店消费</div>
+        </div>
+
+        <div class="order-item" v-if="type=='submit'">
+            <div class="name">订单留言</div>
+            <input class="val" placeholder="选填,备注对本次交易的说明" v-model="message" placeholder-class=".placeholder" />
+        </div>
+
+        <div class="order-item" v-else-if='list.length>0'>
+            <div class="name">订单留言</div>
+            <div class="val" :class="{notSet:!list[0].message}">{{list[0].message||'无'}}</div>
+        </div>
+
+        <div class="submit" v-if="type=='submit'">
+            <span>小计:</span>
+            <span class="price">{{productMoney}}</span>
+        </div>
+    </div>
+</template>
+<script>
+export default {
+    name: 'subOrder',
+    props: {
+        list: {
+            type: Object,
+            default: () => {
+                return [];
+            },
+        },
+        type: {
+            type: String,
+            default: 'submit',
+        },
+        productMoney: {
+            type: Number,
+            default: 0,
+        },
+    },
+    data() {
+        return {
+            message: '',
+        };
+    },
+    watch: {
+        message() {
+            this.$emit('changeMessage', this.message);
+        },
+    },
+};
+</script>
+<style lang='less' scoped>
+.order {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 8px;
+    padding: 15px;
+}
+
+.hr {
+    height: 1px;
+    background-color: #f2f4f5;
+}
+
+.orderInfo {
+    display: flex;
+    // border-bottom: 1px solid #f2f4f5;
+    margin-bottom: 10px;
+
+    .image {
+        width: 80px;
+        height: 80px;
+        border-radius: 4px;
+    }
+
+    .content {
+        flex-grow: 1;
+        margin-left: 10px;
+
+        .title {
+            font-size: 14px;
+            color: rgba(0, 0, 0, 1);
+            line-height: 20px;
+        }
+
+        .sub {
+            font-size: 12px;
+            color: rgba(170, 172, 173, 1);
+            line-height: 17px;
+            margin-top: 5px;
+        }
+
+        .moeny {
+            display: flex;
+            justify-content: space-between;
+            margin-top: 18px;
+
+            .price {
+                font-size: 14px;
+                font-weight: bold;
+                color: rgba(0, 0, 0, 1);
+                line-height: 20px;
+            }
+
+            .num {
+                font-size: 14px;
+                color: rgba(170, 172, 173, 1);
+                line-height: 20px;
+                &::before {
+                    content: 'x';
+                }
+            }
+        }
+    }
+}
+
+.order-item {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    height: 40px;
+
+    .name {
+        font-size: 13px;
+        color: rgba(56, 56, 56, 1);
+    }
+
+    .val {
+        font-size: 14px;
+        color: rgba(0, 0, 0, 1);
+        flex-grow: 1;
+        text-align: right;
+
+        &.notSet{
+            color: #999;
+        }
+    }
+
+    .placeholder {
+        font-size: 12px;
+        color: rgba(170, 172, 173, 1);
+    }
+}
+
+.submit {
+    line-height: 40px;
+    text-align: right;
+    font-size: 12px;
+    color: rgba(56, 56, 56, 1);
+
+    .price {
+        color: rgba(255, 59, 48, 1);
+    }
+}
+</style>

+ 172 - 0
src/components/SubOrder.vue

@@ -0,0 +1,172 @@
+<template>
+    <div class='order'>
+        <div class="orderInfo" v-for="(item,index) in list" :key="index">
+            <img class="image" v-if="item.productInfo.image" :src="item.productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
+            <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
+            <div class="content">
+                <div class="title">{{item.productInfo.title}}</div>
+                <div class="sub">{{item.typeFlag==0?"全款支付":"定金支付"}}</div>
+                <div class="moeny">
+                    <span class="price">{{item.typeFlag==0?item.productInfo.price:item.productInfo.downPayment}}</span>
+                    <span class="num">{{item.quantity}}</span>
+                </div>
+            </div>
+        </div>
+
+        <div class="hr"></div>
+
+        <div class="order-item">
+            <div class="name">消费方式</div>
+            <div class="val">到店消费</div>
+        </div>
+
+        <div class="order-item" v-if="type=='submit'">
+            <div class="name">订单留言</div>
+            <input class="val" placeholder="选填,备注对本次交易的说明" v-model="message" placeholder-class=".placeholder" />
+        </div>
+
+        <div class="order-item" v-else-if='list.length>0'>
+            <div class="name">订单留言</div>
+            <div class="val" :class="{notSet:!list[0].message}">{{list[0].message||'无'}}</div>
+        </div>
+
+        <div class="submit" v-if="type=='submit'">
+            <span>小计:</span>
+            <span class="price">{{productMoney}}</span>
+        </div>
+    </div>
+</template>
+<script>
+export default {
+    name: 'subOrder',
+    props: {
+        list: {
+            type: Object,
+            default: () => {
+                return [];
+            },
+        },
+        type: {
+            type: String,
+            default: 'submit',
+        },
+        productMoney: {
+            type: Number,
+            default: 0,
+        },
+    },
+    data() {
+        return {
+            message: '',
+        };
+    },
+    watch: {
+        message() {
+            this.$emit('changeMessage', this.message);
+        },
+    },
+};
+</script>
+<style lang='less' scoped>
+.order {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 8px;
+    padding: 15px;
+}
+
+.hr {
+    height: 1px;
+    background-color: #f2f4f5;
+}
+
+.orderInfo {
+    display: flex;
+    // border-bottom: 1px solid #f2f4f5;
+    margin-bottom: 10px;
+
+    .image {
+        width: 80px;
+        height: 80px;
+        border-radius: 4px;
+    }
+
+    .content {
+        flex-grow: 1;
+        margin-left: 10px;
+
+        .title {
+            font-size: 14px;
+            color: rgba(0, 0, 0, 1);
+            line-height: 20px;
+        }
+
+        .sub {
+            font-size: 12px;
+            color: rgba(170, 172, 173, 1);
+            line-height: 17px;
+            margin-top: 5px;
+        }
+
+        .moeny {
+            display: flex;
+            justify-content: space-between;
+            margin-top: 18px;
+
+            .price {
+                font-size: 14px;
+                font-weight: bold;
+                color: rgba(0, 0, 0, 1);
+                line-height: 20px;
+            }
+
+            .num {
+                font-size: 14px;
+                color: rgba(170, 172, 173, 1);
+                line-height: 20px;
+                &::before {
+                    content: 'x';
+                }
+            }
+        }
+    }
+}
+
+.order-item {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    height: 40px;
+
+    .name {
+        font-size: 13px;
+        color: rgba(56, 56, 56, 1);
+    }
+
+    .val {
+        font-size: 14px;
+        color: rgba(0, 0, 0, 1);
+        flex-grow: 1;
+        text-align: right;
+
+        &.notSet{
+            color: #999;
+        }
+    }
+
+    .placeholder {
+        font-size: 12px;
+        color: rgba(170, 172, 173, 1);
+    }
+}
+
+.submit {
+    line-height: 40px;
+    text-align: right;
+    font-size: 12px;
+    color: rgba(56, 56, 56, 1);
+
+    .price {
+        color: rgba(255, 59, 48, 1);
+    }
+}
+</style>

+ 87 - 0
src/components/UserOrderItem.vue

@@ -0,0 +1,87 @@
+<template>
+    <div class='userOrder'>
+        <orderItem v-for="(item,itemIndex) in userOrderDetailList" :orderIndex='index' :index='itemIndex' @update='update' @cancelOrder='cancelOrder' :key="itemIndex" :info='item'></orderItem>
+    </div>
+</template>
+<script>
+import { mapState } from 'vuex';
+import orderItem from './OrderItem';
+import { all } from 'q';
+export default {
+    name: 'userOrder',
+    props: {
+        info: {
+            type: Object,
+            default: () => {
+                return {};
+            },
+        },
+        index: {
+            type: Number,
+            default: 0,
+        },
+    },
+    data() {
+        return {};
+    },
+    computed: {
+        ...mapState(['userInfo']),
+        userOrderDetailList() {
+            var list = [];
+            var allList = [...this.info.userOrderDetailList];
+            if (this.info.statusFlag != 0) {
+                list = allList;
+            } else if (allList.length > 0) {
+                var jsonp = { ...this.info };
+                jsonp.productList = [];
+                allList.forEach(item => {
+                    jsonp.productList.push(item);
+                });
+                list.push(jsonp);
+            }
+            return list;
+        },
+    },
+    components: {
+        orderItem,
+    },
+    methods: {
+        update() {
+            console.log(this.index);
+            this.$emit('update', this.index);
+        },
+        cancelOrder() {
+            wx.showLoading({
+                title: '加载中',
+                mask: true,
+            });
+            this.$http
+                .post('/userOrder/cancel', {
+                    id: this.info.id,
+                })
+                .then(res => {
+                    wx.hideLoading();
+                    if (res.success) {
+                        wx.showToast({
+                            title: '取消成功',
+                            icon: 'success',
+                            duration: 1500,
+                        });
+                        this.$emit('update', this.index);
+                    } else {
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+    },
+};
+</script>
+<style lang='less' scoped>
+</style>

+ 47 - 4
src/main.less

@@ -1,10 +1,53 @@
 .weui-cell__bd {
 .weui-cell__bd {
-    font-size: 40rpx;
-    font-weight: bold;
-    color: rgba(0, 0, 0, 1);
+  font-size: 40rpx;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
 }
 }
 
 
 .weui-cell__ft {
 .weui-cell__ft {
-    font-size: 24rpx;
+  font-size: 24rpx;
+  color: rgba(153, 153, 153, 1);
+}
+
+.price {
+  &::before {
+    content: '¥';
+  }
+}
+
+.nothing {
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  padding: 53px 0 20px;
+
+  img {
+    width: 110px;
+    height: 110px;
+  }
+
+  .title {
+    font-size: 16px;
+    color: rgba(0, 0, 0, 1);
+    line-height: 22px;
+    margin-top: 25px;
+  }
+
+  .sub {
+    font-size: 13px;
     color: rgba(153, 153, 153, 1);
     color: rgba(153, 153, 153, 1);
+    line-height: 18px;
+    margin-top: 6px;
+  }
+
+  button {
+    width: 110px;
+    height: 36px;
+    line-height: 36px;
+    font-size: 14px;
+    color: rgba(0, 197, 242, 1);
+    border-radius: 22px;
+    border: 1px solid rgba(0, 197, 242, 1);
+    margin-top: 20px;
+  }
 }
 }

+ 5 - 0
src/pages/caseDetail/caseDetail.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './caseDetail.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/caseDetail/caseDetail.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": "案例详情"
+}

+ 46 - 0
src/pages/caseDetail/caseDetail.vue

@@ -0,0 +1,46 @@
+<template>
+    <div class="container">
+        <div v-html="detail">
+
+        </div>
+    </div>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            detail:''
+        };
+    },
+    onLoad(options) {
+        this.$http
+            .get('/storeCase/getOne', {
+                id: options.id,
+            })
+            .then(res => {
+                if (res.success) {
+                    res.data.remark = res.data.remark.replace(
+                        /\<img/g,
+                        '<img style="width:100%;height:auto;display:block;margin-bottom:15px;border-radius:4px;"',
+                    );
+                    res.data.remark = res.data.remark.replace(
+                        /\<p/g,
+                        '<p style=" font-size: 14px; color: rgba(0, 0, 0, 1);line-height: 22px;;margin-bottom:20px"',
+                    );
+                    console.log(res.data.remark);
+                    this.detail = res.data.remark;
+                }
+            })
+            .catch(e => {
+                console.log(e);
+            });
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container{
+    padding: 15px;
+}
+</style>

+ 5 - 0
src/pages/caseList/caseList.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './caseList.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 0 - 0
src/pages/user copy/user.json → src/pages/caseList/caseList.json


+ 97 - 0
src/pages/caseList/caseList.vue

@@ -0,0 +1,97 @@
+<template>
+    <div class="container">
+     
+        <div class="storeCaseList">
+            <navigator class="storeCaseItem" :url="'/pages/caseDetail/caseDetail?id='+item.id" v-for="(item,index) in storeCaseList" :key="index">
+                <img :src="item.image" background-size="cover">
+            </navigator>
+        </div>
+
+
+        <view class="weui-loadmore" v-if="isFinish">
+           
+        </view>
+        <view class="weui-loadmore" v-else>
+            <view class="weui-loading"></view>
+            <view class="weui-loadmore__tips">正在加载</view>
+        </view>
+
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+export default {
+    data() {
+        return {
+            storeCaseList: [],
+            currentPage: 1,
+            serviceFlag: false,
+            isFinish: false,
+        };
+    },
+    computed: {
+        ...mapState(['storeInfo']),
+    },
+    onLoad() {
+        this.getList()
+    },
+    onReachBottom() {
+        if (this.serviceFlag) {
+            this.currentPage++;
+            this.getList();
+        }
+    },
+    methods: {
+        getList() {
+            if (this.currentPage == 1) {
+                this.storeCaseList = [];
+            }
+            this.$http
+                .get('/storeCase/page', {
+                    storeId: this.storeInfo.id || 13,
+                    currentPage: this.currentPage,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.storeCaseList = this.storeCaseList.concat(
+                            res.data.pp,
+                        );
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.serviceFlag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    padding: 15px;
+
+   .storeCaseList {
+    .storeCaseItem {
+        margin-bottom:16px;
+        width: 100%;
+        height:190px;
+
+        img {
+            width: 100%;
+            height: 100%;
+            border-radius: 8px;
+        }
+
+    }
+}
+}
+</style>

+ 5 - 0
src/pages/changeUser/changeUser.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './changeUser.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/changeUser/changeUser.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": "个人设置"
+}

+ 156 - 0
src/pages/changeUser/changeUser.vue

@@ -0,0 +1,156 @@
+<template>
+    <div class="container">
+        <div class="card">
+            <div class="card-item">
+                <div class="name">昵称</div>
+                <input type="text" confirm-type='done' :focus='focusInput' v-model="val" class="val" @focus='focusInput=true' @blur='blurInput' @confirm='inputConfirm' placeholder="请输入昵称">
+                <img src="/static/images/icon_weizhi (1).png" v-if="focusInput&&val" @click="searchVal=''" class="more" alt="">
+
+            </div>
+
+        </div>
+
+        <button class="submit" @click='inputConfirm'>
+            确定
+        </button>
+
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+export default {
+    data() {
+        return {
+            val: '',
+            key: '',
+            focusInput: false,
+        };
+    },
+    computed: {
+        ...mapState(['userInfo']),
+    },
+    onLoad(options) {
+        console.log(options);
+        this.val = options.val;
+        this.key = options.key;
+        this.focusInput = true;
+    },
+    methods: {
+        blurInput() {
+            setTimeout(() => {
+                this.focusInput = false;
+            }, 500);
+        },
+        updateUser(key, val) {
+            console.log(key, val);
+            wx.showLoading({
+                title: '加载中',
+                mask: true,
+            });
+            this.$http
+                .post('/userInfo/update', {
+                    id: this.userInfo.id,
+                    [key]: val,
+                })
+                .then(res => {
+                    wx.hideLoading();
+                    if (res.success) {
+                        wx.showToast({
+                            title: '更新成功',
+                            icon: 'success',
+                            duration: 1500,
+                        });
+                        setTimeout(() => {
+                            wx.navigateBack();
+                        }, 1500);
+                    } else {
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        inputConfirm() {
+            this.updateUser(this.key, this.val);
+        },
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    background-color: #f2f4f5;
+    box-sizing: border-box;
+    padding: 15px;
+}
+
+.card-item {
+    display: flex;
+    height: 60px;
+    align-items: center;
+    position: relative;
+
+    .name {
+        font-size: 14px;
+        font-weight: bold;
+        color: rgba(0, 0, 0, 1);
+        line-height: 20px;
+    }
+    .icon {
+        width: 36px;
+        height: 36px;
+        border-radius: 100%;
+    }
+
+    .more {
+        width: 24px;
+        height: 24px;
+        // margin-left: 10px;
+    }
+
+    .val {
+        font-size: 16px;
+        color: rgba(0, 0, 0, 1);
+        line-height: 22px;
+        flex-grow: 1;
+        margin-left: 30px;
+    }
+
+    &:not(:last-child) {
+        border-bottom: 1px solid #f2f4f5;
+    }
+
+    .picker {
+        position: absolute;
+        left: 0;
+        right: 0;
+        top: 0;
+        bottom: 0;
+        opacity: 0;
+    }
+}
+
+.card {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 6px;
+    padding: 0 15px;
+}
+
+.submit {
+    margin: 28px 15px;
+    height: 40px;
+    background: rgba(0, 197, 242, 1);
+    border-radius: 22px;
+    font-size: 15px;
+    font-weight: bold;
+    color: rgba(255, 255, 255, 1);
+    line-height: 40px;
+}
+</style>

+ 5 - 0
src/pages/evaluate/evaluate.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './evaluate.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 4 - 0
src/pages/evaluate/evaluate.json

@@ -0,0 +1,4 @@
+{
+    "navigationBarTitleText": "商品评价",
+    "backgroundColor": "#f2f4f5"
+}

+ 307 - 0
src/pages/evaluate/evaluate.vue

@@ -0,0 +1,307 @@
+<template>
+    <div class="container">
+        <div class="product">
+            <img class="image" v-if="productInfo.image" :src="productInfo.image+'?x-oss-process=image/resize,m_fill,h_120,w_120'" background-size="cover" alt="">
+            <img class="image" v-else src="/static/images/icon_sirendingzhi.png" background-size="cover" alt="">
+
+            <div class="imgList">
+                <img :src="item" v-for="(item,index) in imgList" @click="scroe=index+1" :key="index" alt="">
+            </div>
+
+            <div class="name">{{scroeName}}</div>
+        </div>
+
+        <div class="content">
+            <textarea name="text" auto-height class="textarea" v-model="context" id="text" placeholder="分享你的体验吧"></textarea>
+
+            <div class="commentList">
+                <img class="comment-item" :src="item" background-size="cover" @click="haschooseImg(index)" v-for="(item,index) in commentList" :key="index" alt="">
+                <div class="comment-item" v-if="commentList.length<4" @click="chooseImg">
+                    <img src="/static/images/icon_shangchuantupian.png" alt="">
+                    <span>添加图片</span>
+                </div>
+            </div>
+        </div>
+
+        <button class="submit" @click="submit">提交</button>
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+import { OrderStatus } from '../../Constants';
+export default {
+    data() {
+        return {
+            orderId: 0,
+            orderInfo: {},
+            scroe: 5,
+            commentList: [],
+            chooseIndex: null,
+        };
+    },
+    computed: {
+        ...mapState(['userInfo']),
+        imgList() {
+            var list = [
+                require('../../../static/images/icon_pingjia.png'),
+                require('../../../static/images/icon_pingjia_yiban.png'),
+                require('../../../static/images/icon_pingjia_pre.png'),
+            ];
+            var img = [list[0], list[0], list[0], list[0], list[0]];
+            if (this.scroe) {
+                var starLevel = Number(this.scroe);
+                img = [];
+                for (var i = 0; i < 5; i++) {
+                    if (
+                        Math.floor(starLevel) == i &&
+                        Math.ceil(starLevel) > i
+                    ) {
+                        img.push(list[1]);
+                    } else if (starLevel <= i) {
+                        img.push(list[0]);
+                    } else if (starLevel > i) {
+                        img.push(list[2]);
+                    }
+                }
+            }
+            return img;
+        },
+        productInfo() {
+            return this.orderInfo.productInfo || {};
+        },
+        scroeName() {
+            var list = ['特别差', '很差', '一般', '很好', '非常好'];
+            return list[Number(this.scroe) - 1];
+        },
+    },
+    onLoad(options) {
+        console.log(options);
+        this.orderId = options.orderId;
+        if(options.index){
+            this.index=options.index;
+        }
+        this.$http
+            .get('/userOrderDetail/getOne', {
+                id: this.orderId,
+            })
+            .then(res => {
+                if (res.success) {
+                    this.orderInfo = res.data;
+                }
+            });
+    },
+    methods: {
+        haschooseImg(chooseIndex) {
+            this.chooseIndex = chooseIndex;
+            this.chooseImg();
+        },
+        chooseImg() {
+            var ref = this;
+            wx.chooseImage({
+                count: 1,
+                sizeType: ['compressed'],
+                sourceType: ['album', 'camera'],
+                success(res) {
+                    console.log(res);
+                    // tempFilePath可以作为img标签的src属性显示图片
+                    const tempFilePaths = res.tempFilePaths;
+                    setTimeout(() => {
+                        ref.icon = tempFilePaths[0];
+                    }, 500);
+                    wx.showLoading({
+                        title: '加载中',
+                        mask: true,
+                    });
+                    ref.$http
+                        .uploadFile('/assets/uploadFile', tempFilePaths[0])
+                        .then(res => {
+                            wx.hideLoading();
+                            res = JSON.parse(res);
+                            if (res.success) {
+                                console.log(ref.chooseIndex);
+                                if (ref.chooseIndex || ref.chooseIndex == 0) {
+                                    ref.$set(
+                                        ref.commentList,
+                                        ref.chooseIndex,
+                                        res.data[0],
+                                    );
+                                    ref.chooseIndex = null;
+                                } else {
+                                    ref.commentList.push(res.data[0]);
+                                }
+                            }
+                        });
+                },
+            });
+        },
+        submit() {
+            this.$http
+                .post('/userOrderDetail/update', {
+                    id: this.orderId,
+                    statusFlag: OrderStatus.FINISH,
+                })
+                .then(res => {
+                    if (this.index || this.index == 0) {
+                        let pages = getCurrentPages();
+                        let prevPage = pages[pages.length - 2];
+                        prevPage.update(this.index);
+                    }
+                });
+            wx.showLoading({
+                title: '加载中',
+                mask: true,
+            });
+            this.$http
+                .post('/productComment/save', {
+                    orderId: this.orderId,
+                    userId: this.userInfo.id,
+                    context: this.context || '系统默认好评',
+                    starLevel: this.scroe,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.saveImg(res.data, 0);
+                    } else {
+                        wx.hideLoading();
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                });
+        },
+        saveImg(id, index) {
+            if (index >= this.commentList.length) {
+                wx.hideLoading();
+                wx.showToast({
+                    title: '评论成功',
+                    icon: 'success',
+                    duration: 1500,
+                });
+                setTimeout(() => {
+                    wx.navigateBack();
+                }, 1500);
+                return;
+            }
+
+            this.$http
+                .post('/productCommentImage/save', {
+                    commentId: id,
+                    imageUrl: this.commentList[index],
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.saveImg(id, index + 1);
+                    } else {
+                        wx.hideLoading();
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                });
+        },
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    background-color: #f2f4f5;
+    padding: 15px;
+    min-height: 100%;
+    .product {
+        background: rgba(255, 255, 255, 1);
+        border-radius: 6px;
+        height: 90px;
+        display: flex;
+        align-items: center;
+        padding: 0 15px;
+
+        .image {
+            width: 60px;
+            height: 60px;
+            border-radius: 4px;
+        }
+
+        .imgList {
+            display: flex;
+            align-items: center;
+            margin-left: 22px;
+            flex-grow: 1;
+            img {
+                width: 22px;
+                height: 22px;
+                margin-right: 8px;
+            }
+        }
+
+        .name {
+            font-size: 13px;
+            color: rgba(170, 172, 173, 1);
+            line-height: 18px;
+        }
+    }
+}
+
+.content {
+    margin: 8px 0 0;
+
+    background: rgba(255, 255, 255, 1);
+    border-radius: 6px;
+    padding: 15px;
+
+    .textarea {
+        min-height: 120px;
+        font-size: 13px;
+        color: #000;
+    }
+
+    .commentList {
+        display: flex;
+        .comment-item {
+            width: 68px;
+            height: 68px;
+            background: rgba(242, 244, 245, 1);
+            border-radius: 6px;
+            margin-right: 10px;
+            display: flex;
+            flex-direction: column;
+            justify-content: center;
+            align-items: center;
+            img {
+                width: 26px;
+                height: 22px;
+            }
+
+            span {
+                font-size: 11px;
+                color: rgba(170, 172, 173, 1);
+                line-height: 16px;
+                margin-top: 6px;
+            }
+        }
+    }
+}
+
+.submit {
+    height: 40px;
+    background: rgba(0, 197, 242, 1);
+    border-radius: 22px;
+    font-size: 15px;
+    font-weight: bold;
+    color: rgba(255, 255, 255, 1);
+    line-height: 40px;
+    position: absolute;
+    width: 345px;
+    left: 15px;
+    bottom: 10px;
+
+    &:active {
+        background: darken(rgba(0, 197, 242, 1), 10);
+    }
+}
+</style>

+ 15 - 23
src/pages/home/home.vue

@@ -4,12 +4,11 @@
         <image class="fixed" src='/static/images/bg.png' background-size="contain"></image>
         <image class="fixed" src='/static/images/bg.png' background-size="contain"></image>
         <view class="main">
         <view class="main">
             <view class="searchContent">
             <view class="searchContent">
-                <view class="search">
+                <navigator class="search" url='/pages/search/search'>
                     <img src="/static/images/icon_weizhi.png" background-size="cover" alt="">
                     <img src="/static/images/icon_weizhi.png" background-size="cover" alt="">
-                    <input type="text" v-model="inputVal" placeholder="搜索商品…"
-                           placeholder-class="placeholder" @keypress.enter="searchGoods()" />
+                    <div class="placeholder">搜索商品...</div>
 
 
-                </view>
+                </navigator>
                 <div class="kefu">
                 <div class="kefu">
                     <img src="/static/images/icon_weizhi2.png" class="weixin" alt="">
                     <img src="/static/images/icon_weizhi2.png" class="weixin" alt="">
                     <button open-type="contact"> 客服</button>
                     <button open-type="contact"> 客服</button>
@@ -33,7 +32,7 @@
                 <homeCoupon></homeCoupon>
                 <homeCoupon></homeCoupon>
 
 
                 <div class="hot">
                 <div class="hot">
-                    <navigator url="" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
+                    <navigator url="/pages/productList/productList?serviceType=1&title=超值热卖" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
                         <view class="weui-cell__bd">超值热卖</view>
                         <view class="weui-cell__bd">超值热卖</view>
                         <view class="weui-cell__ft weui-cell__ft_in-access">查看更多</view>
                         <view class="weui-cell__ft weui-cell__ft_in-access">查看更多</view>
                     </navigator>
                     </navigator>
@@ -47,7 +46,7 @@
                 </div>
                 </div>
 
 
                 <div class="classics">
                 <div class="classics">
-                    <navigator url="" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
+                    <navigator url="/pages/productList/productList?serviceType=5&title=经典套餐" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
                         <view class="weui-cell__bd">经典套餐</view>
                         <view class="weui-cell__bd">经典套餐</view>
                         <view class="weui-cell__ft weui-cell__ft_in-access">查看更多</view>
                         <view class="weui-cell__ft weui-cell__ft_in-access">查看更多</view>
                     </navigator>
                     </navigator>
@@ -56,7 +55,7 @@
                         <productItem v-for="(item,index) in homeList" :key="index" :info='item'></productItem>
                         <productItem v-for="(item,index) in homeList" :key="index" :info='item'></productItem>
                     </div>
                     </div>
                     <view class="weui-loadmore" v-if="isFinish">
                     <view class="weui-loadmore" v-if="isFinish">
-                        <view class="weui-loadmore__tips">没有更多数据了</view>
+                        <!-- <view class="weui-loadmore__tips">没有更多数据了</view> -->
                     </view>
                     </view>
                     <view class="weui-loadmore" v-else>
                     <view class="weui-loadmore" v-else>
                         <view class="weui-loading"></view>
                         <view class="weui-loading"></view>
@@ -121,10 +120,10 @@ export default {
         this.getHome();
         this.getHome();
     },
     },
     onReachBottom() {
     onReachBottom() {
-        if (this.homeFlag) {
-            this.currentHome++;
-            this.getHome();
-        }
+        // if (this.homeFlag) {
+        //     this.currentHome++;
+        //     this.getHome();
+        // }
     },
     },
     methods: {
     methods: {
         clearInput() {},
         clearInput() {},
@@ -132,8 +131,8 @@ export default {
             this.hotFlag = false;
             this.hotFlag = false;
             var data = {
             var data = {
                 currentPage: this.currentHot,
                 currentPage: this.currentHot,
-                pageNumber: 10,
-                hotFlag: 1,
+                pageNumber: 6,
+                serviceType: 1,
             };
             };
             if (this.currentHot == 1) {
             if (this.currentHot == 1) {
                 this.hotList = [];
                 this.hotList = [];
@@ -158,8 +157,8 @@ export default {
             this.homeFlag = false;
             this.homeFlag = false;
             var data = {
             var data = {
                 currentPage: this.currentHome,
                 currentPage: this.currentHome,
-                pageNumber: 10,
-                homeFlag: 1,
+                pageNumber: 8,
+                serviceType: 5,
             };
             };
             if (this.currentHome == 1) {
             if (this.currentHome == 1) {
                 this.homeList = [];
                 this.homeList = [];
@@ -169,14 +168,7 @@ export default {
                 .then(res => {
                 .then(res => {
                     if (res.success) {
                     if (res.success) {
                         this.homeList = this.homeList.concat(res.data.pp);
                         this.homeList = this.homeList.concat(res.data.pp);
-                        if (
-                            res.data.page.currentPage < res.data.page.totalPage
-                        ) {
-                            // console.log('aaaaaa')
-                            this.homeFlag = true;
-                        } else {
-                            this.isFinish = true;
-                        }
+                         this.isFinish = true;
                     }
                     }
                 })
                 })
                 .catch(e => {
                 .catch(e => {

+ 5 - 0
src/pages/orderDetail/orderDetail.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './orderDetail.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 7 - 0
src/pages/orderDetail/orderDetail.json

@@ -0,0 +1,7 @@
+{
+    "navigationBarTitleText": "订单详情",
+    "navigationBarTextStyle": "white",
+    "navigationBarBackgroundColor": "#00C5F2",
+    "backgroundColorTop": "#00C5F2",
+    "backgroundColorBottom": "#f2f4f5"
+}

+ 263 - 0
src/pages/orderDetail/orderDetail.vue

@@ -0,0 +1,263 @@
+<template>
+    <div class="container">
+        <div class="top">
+            <div class="statusList" :style="{transform:'translateX('+(0-2*transFormLeft)+'rpx)'}">
+                <div class="statusItem" :class="{select:statusFlag==item.type}" v-for="(item,index) in statusList" :key="index">
+                    <div class="img">
+                        <img :src="item.img" alt="">
+                        <div class="line"></div>
+                    </div>
+                    <div class="title">{{item.name}}</div>
+
+                </div>
+            </div>
+        </div>
+
+        <div class="messageInfo">
+            <div class="text">订单支付成功,请联系客服确定好档期后点击下方预约按钮进行拍照时间预约</div>
+            <div class="btnList">
+                <div class="btn-item">
+                    <img src="/static/images/xiangqing_icon_kefu(1).png" alt="">
+                    <span>在线咨询</span>
+                </div>
+
+                <div class="btn-item">
+                    <img src="/static/images/xiangqing_icon_kefu.png" alt="">
+                    <span>拨打电话</span>
+                </div>
+            </div>
+        </div>
+
+        <subOrder :list='userOrderDetailList' :productMoney='productMoney' @changeMessage='changeMessage'></subOrder>
+
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+import subOrder from '../../components/SubOrder';
+import { OrderStatus } from '../../Constants';
+export default {
+    data() {
+        return {
+            orderId: 0,
+            orderInfo: {},
+            statusList: [
+                {
+                    name: '支付',
+                    type: OrderStatus.NOPAY,
+                    img: require('../../../static/images/dingdan_icon_yuyue(1).png'),
+                },
+                {
+                    name: '预约拍照',
+                    type: OrderStatus.PAYOVER,
+                    img: require('../../../static/images/dingdan_icon_yuyue.png'),
+                },
+                {
+                    name: '拍照',
+                    type: OrderStatus.BOOKPHOTO,
+                    img: require('../../../static/images/dingdan_icon_paizhao.png'),
+                },
+                {
+                    name: '预约选片',
+                    type: OrderStatus.PHOTOOVER,
+                    img: require('../../../static/images/dingdan_icon_yuyue.png'),
+                },
+                {
+                    name: '选片',
+                    type: OrderStatus.BOOKSELECT,
+                    img: require('../../../static/images/dingdan_icon_xuanpian.png'),
+                },
+                {
+                    name: '预约审片',
+                    type: OrderStatus.SELECTOVER,
+                    img: require('../../../static/images/dingdan_icon_yuyue.png'),
+                },
+                {
+                    name: '审片',
+                    type: OrderStatus.BOOKCHECK,
+                    img: require('../../../static/images/dingdan_icon_shenpian.png'),
+                },
+                {
+                    name: '预约取件',
+                    type: OrderStatus.CHECKOVER,
+                    img: require('../../../static/images/dingdan_icon_yuyue.png'),
+                },
+                {
+                    name: '取件',
+                    type: OrderStatus.BOOKACCESS,
+                    img: require('../../../static/images/dingdan_icon_paizhao(2).png'),
+                },
+                {
+                    name: '评价',
+                    type: OrderStatus.ACCESSOVER,
+                    img: require('../../../static/images/dingdan_icon_paizhao(1).png'),
+                },
+            ],
+        };
+    },
+    computed: {
+        ...mapState(['userInfo']),
+        transFormLeft() {
+            var left = this.statusFlag * 66;
+            var allLength = this.statusList.length * 66 - 30;
+            var moveLeft = 0;
+            if (this.statusFlag >= 3) {
+                if (this.statusFlag > 6) {
+                    moveLeft = 3 * 66 + 90;
+                } else {
+                    moveLeft = (this.statusFlag - 3) * 66 + 45;
+                }
+            }
+            return moveLeft;
+        },
+        statusFlag() {
+            return this.orderInfo.statusFlag || 0;
+        },
+    },
+    onLoad(options) {
+        console.log(options);
+        this.orderId = options.orderId;
+        this.getOrder();
+    },
+    methods: {
+        getOrder() {
+            this.$http
+                .get('/userOrderDetail/getOne', {
+                    id: this.orderId,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.orderInfo = res.data;
+                    }
+                });
+        },
+    },
+    components: {
+        subOrder,
+        OrderStatus,
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    background-image: linear-gradient(#00c5f2 232rpx, #f2f4f5 232rpx, #f2f4f5);
+}
+
+.top {
+    position: relative;
+
+    .statusList {
+        display: flex;
+        align-items: center;
+        height: 87px;
+        margin-left: 15px;
+
+        .statusItem {
+            display: flex;
+            flex-direction: column;
+            align-items: center;
+            justify-content: center;
+            padding-bottom: 21px;
+            position: relative;
+            margin-right: 30px;
+
+            .img {
+                width: 36px;
+                height: 36px;
+                background: rgba(127, 231, 255, 1);
+                border-radius: 30px;
+                display: flex;
+                align-items: center;
+                justify-content: center;
+                position: relative;
+                img {
+                    width: 24px;
+                    height: 24px;
+                }
+
+                .line {
+                    height: 1px;
+                    background: rgba(127, 231, 255, 1);
+                    position: absolute;
+                    width: 30px;
+                    right: -30px;
+                    top: 50%;
+                    transform: translateY(-50%);
+                }
+            }
+
+            .title {
+                font-size: 13px;
+                font-weight: bold;
+                color: rgba(127, 231, 255, 1);
+                line-height: 18px;
+                position: absolute;
+                bottom: 0;
+                left: 50%;
+                transform: translateX(-50%);
+                white-space: nowrap;
+            }
+
+            &.select {
+                .img {
+                    background-color: #fff;
+                }
+
+                .title {
+                    color: #fff;
+                }
+            }
+
+            &:last-child {
+                .img {
+                    .line {
+                        width: 0;
+                    }
+                }
+            }
+        }
+    }
+}
+
+.messageInfo {
+    width: 345px;
+    height: 121px;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 8px;
+    margin: 0 15px;
+    padding: 0 15px;
+
+    .text {
+        font-size: 13px;
+        font-weight: bold;
+        color: rgba(0, 0, 0, 1);
+        line-height: 20px;
+        padding: 15px;
+    }
+
+    .btnList {
+        display: flex;
+            border-top:1px solid #F2F4F5;
+        .btn-item {
+            width: 50%;
+            display: flex;
+            align-items: center;
+            justify-content: center;
+            img {
+                width: 24px;
+                height: 24px;
+            }
+
+            span {
+                font-size: 13px;
+                color: rgba(102, 102, 102, 1);
+                line-height: 18px;
+                margin-left: 5px;
+            }
+        }
+    }
+}
+</style>

+ 5 - 0
src/pages/orderList/orderList.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './orderList.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 5 - 0
src/pages/orderList/orderList.json

@@ -0,0 +1,5 @@
+{
+    "navigationBarTitleText": "订单列表",
+    "backgroundColorTop": "#fff",
+    "backgroundColorBottom": "#f2f4f5"
+}

+ 233 - 0
src/pages/orderList/orderList.vue

@@ -0,0 +1,233 @@
+<template>
+    <div class="container">
+        <div class="top" id='top'>
+            <div class="tabItem" :class="{select:item.orderStatus==chooseOrderStatus}" v-for='(item,index) in tabList' :key="index">
+                <div class="name">{{item.name}}</div>
+                <div class="line"></div>
+            </div>
+        </div>
+
+        <div class="orderList">
+
+            <div v-if='chooseOrderStatus==-1||chooseOrderStatus==0'>
+                <userOrder v-for="(item,index) in orderList" :index='index' @update='update' :key="index" :info='item'></userOrder>
+            </div>
+            <div v-else>
+                <orderItem v-for="(item,index) in orderList" :key="index" :info='item'></orderItem>
+            </div>
+
+            <view class="weui-loadmore" v-if="isFinish">
+                <view class="weui-loadmore__tips"></view>
+            </view>
+            <view class="weui-loadmore" v-else>
+                <view class="weui-loading"></view>
+                <view class="weui-loadmore__tips">正在加载</view>
+            </view>
+        </div>
+
+        <div class="nothing" v-if="isFinish && orderList.length==0">
+            <img src="/static/images/kong_icon_dingdan.png" alt="">
+            <div class="title">订单空空如也</div>
+            <div class="sub">快去寻找喜欢的商品下单吧</div>
+            <button @click="goHome">去逛逛</button>
+        </div>
+
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+import { OrderStatus } from '../../Constants';
+import orderItem from '../../components/OrderItem';
+import userOrder from '../../components/UserOrderItem';
+export default {
+    data() {
+        return {
+            tabList: [
+                {
+                    name: '全部',
+                    orderStatus: -1,
+                },
+                {
+                    name: '待支付',
+                    orderStatus: OrderStatus.NOPAY,
+                },
+                {
+                    name: '待预约',
+                    orderStatus: OrderStatus.PAYOVER,
+                },
+                {
+                    name: '进行中',
+                    orderStatus: OrderStatus.BOOKPHOTO,
+                },
+                {
+                    name: '待取件',
+                    orderStatus: OrderStatus.BOOKACCESS,
+                },
+                {
+                    name: '待评价',
+                    orderStatus: OrderStatus.ACCESSOVER,
+                },
+            ],
+            chooseOrderStatus: -1,
+            orderList: [],
+            currentPage: 1,
+            isFinish: false,
+            flag: false,
+        };
+    },
+    computed: {
+        ...mapState(['userInfo', 'storeInfo']),
+    },
+    onLoad(options) {
+        if (options.orderStatus) {
+        }
+
+        this.getOrderList();
+    },
+    methods: {
+        update(index) {
+            console.log(index);
+            if (this.chooseOrderStatus == -1 || this.chooseOrderStatus == 0) {
+                this.$http
+                    .get('/userOrder/getOne', {
+                        id: this.orderList[index].id,
+                    })
+                    .then(res => {
+                        if (res.success) {
+                            this.$set(this.orderList, index, res.data);
+                        }
+                    });
+            }
+        },
+        getOrderList() {
+            this.flag = false;
+            if (this.currentPage == 1) {
+                this.orderList = [];
+                wx.pageScrollTo({
+                    scrollTop: 0,
+                });
+            }
+
+            var data = {
+                // userId: this.userInfo.id,
+                currentPage: this.currentPage,
+            };
+            data.userId=84727
+
+            if (this.chooseOrderStatus == OrderStatus.PAYOVER) {
+                //未付款
+                data.statusStr = OrderStatus.PAYOVER;
+            } else if (this.chooseOrderStatus == OrderStatus.BOOKPHOTO) {
+                //待预约
+                data.statusStr =
+                    OrderStatus.BOOKPHOTO +
+                    ',' +
+                    OrderStatus.BOOKSELECT +
+                    ',' +
+                    OrderStatus.BOOKCHECK;
+            } else if (this.chooseOrderStatus == OrderStatus.PHOTOOVER) {
+                data.statusStr =
+                    OrderStatus.PHOTOOVER +
+                    ',' +
+                    OrderStatus.SELECTOVER +
+                    ',' +
+                    OrderStatus.CHECKOVER;
+            } else if (this.chooseOrderStatus == OrderStatus.BOOKACCESS) {
+                data.statusStr = orderStatus.BOOKACCESS;
+            } else if (this.chooseOrderStatus == OrderStatus.ACCESSOVER) {
+                data.statusStr = orderStatus.ACCESSOVER;
+            }
+
+            this.$http
+                .get(
+                    this.chooseOrderStatus == -1 ||
+                    this.chooseOrderStatus == OrderStatus.PAYOVER
+                        ? '/userOrder/page'
+                        : '/userOrderDetail/page',
+                    data
+                )
+                .then(res => {
+                    if (res.success) {
+                        this.orderList = this.orderList.concat(res.data.pp);
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.flag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        goHome() {
+            wx.navigateTo({
+                url: '/pages/home/home',
+            });
+        },
+    },
+    components: {
+        orderItem,
+        userOrder,
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    background-color: #f2f4f5;
+
+    .top {
+        height: 44px;
+        background: rgba(255, 255, 255, 1);
+        position: sticky;
+        top: 0;
+        display: flex;
+        z-index: 20;
+
+        .tabItem {
+            flex-grow: 1;
+            position: relative;
+
+            .name {
+                font-size: 13px;
+                color: #000000;
+                line-height: 44px;
+                text-align: center;
+            }
+
+            .line {
+                width: 0;
+                height: 4px;
+                background: rgba(0, 197, 242, 1);
+                border-radius: 2px;
+                transition: ease-in-out 0.3s;
+                position: absolute;
+                bottom: 4px;
+                left: 50%;
+                transform: translateX(-50%);
+            }
+
+            &.select {
+                .name {
+                    font-weight: bold;
+                    color: rgba(0, 197, 242, 1);
+                }
+
+                .line {
+                    width: 16px;
+                }
+            }
+        }
+    }
+}
+
+.orderList {
+    padding-bottom: 10px;
+}
+</style>

+ 145 - 5
src/pages/product/product.vue

@@ -19,8 +19,8 @@
             </div>
             </div>
 
 
             <div class="btnList">
             <div class="btnList">
-                <div>加入购物车</div>
-                <div>立即下单</div>
+                <div @click="addCar">加入购物车</div>
+                <div @click="goSubmit">立即下单</div>
             </div>
             </div>
         </div>
         </div>
 
 
@@ -114,11 +114,12 @@
 
 
         </div>
         </div>
 
 
-        <specificationsContent :visible='showSpecifications' :productInfo='productInfo' @close='showSpecifications=false' :totalMoney='totalMoney' :chooseType='chooseType' :chooseNum='chooseNum' @changeType='changeType' @changeNum='changeNum' @changeChoose='hasChoose=true'></specificationsContent>
+        <specificationsContent :visible='showSpecifications' :productInfo='productInfo' @close='showSpecifications=false' :totalMoney='totalMoney' :chooseType='chooseType' :chooseNum='chooseNum' @changeType='changeType' @changeNum='changeNum' @changeChoose='goWaiting'></specificationsContent>
     </div>
     </div>
 </template>
 </template>
 
 
 <script>
 <script>
+import { mapState } from 'vuex';
 import specificationsContent from '../../components/SpecificationsContent';
 import specificationsContent from '../../components/SpecificationsContent';
 import productComment from '../../components/ProductComment';
 import productComment from '../../components/ProductComment';
 import calc from '../../calc';
 import calc from '../../calc';
@@ -141,9 +142,11 @@ export default {
             productComments: [],
             productComments: [],
             commentFlag: false,
             commentFlag: false,
             commentFinish: false,
             commentFinish: false,
+            isWaiting: '',
         };
         };
     },
     },
     computed: {
     computed: {
+        ...mapState(['userInfo']),
         totalMoney() {
         totalMoney() {
             var money = 0;
             var money = 0;
             if (this.chooseType == 'all') {
             if (this.chooseType == 'all') {
@@ -180,7 +183,7 @@ export default {
         },
         },
     },
     },
     onLoad(options) {
     onLoad(options) {
-        console.log(options);
+        this.refreash();
         this.productId = options.id;
         this.productId = options.id;
         this.$http
         this.$http
             .get('/productInfo/getOne', { id: this.productId })
             .get('/productInfo/getOne', { id: this.productId })
@@ -199,7 +202,8 @@ export default {
         });
         });
     },
     },
     onReachBottom() {
     onReachBottom() {
-        if (!this.isLoading) {
+        console.log(this.isLoading)
+        if (!this.loading) {
             this.chooseTab(this.nowSelectTab);
             this.chooseTab(this.nowSelectTab);
         }
         }
 
 
@@ -210,6 +214,25 @@ export default {
         }
         }
     },
     },
     methods: {
     methods: {
+        refreash() {
+            this.productId = 0;
+            this.productInfo = {};
+            this.bannerList = [];
+            this.showSpecifications = false;
+            this.chooseType = 'all';
+            this.chooseNum = 1;
+            this.hasChoose = false;
+            this.nowSelectTab = 0;
+            this.loading = false;
+            this.loadingFinish = false;
+            this.detailList = [];
+            this.productParameters = [];
+            this.currentPage = 1;
+            this.productComments = [];
+            this.commentFlag = false;
+            this.ommentFinish = false;
+            this.isWaiting = '';
+        },
         getImage(type) {
         getImage(type) {
             return new Promise((resolve, reject) => {
             return new Promise((resolve, reject) => {
                 this.$http
                 this.$http
@@ -305,6 +328,123 @@ export default {
             }
             }
             this.nowSelectTab = tab;
             this.nowSelectTab = tab;
         },
         },
+        goSubmit() {
+            if (!this.hasChoose) {
+                //打开选项卡
+                this.showSpecifications = true;
+                // 保留正在等待加购物车状态
+                this.isWaiting = 'submit';
+
+                return;
+            }
+
+            wx.navigateTo({
+                url:
+                    '/pages/submit/submit?submitPage=product&productId=' +
+                    this.productId +
+                    '&amount=' +
+                    this.chooseNum +
+                    '&typeFlag=' +
+                    (this.chooseType == 'all' ? 0 : 1),
+            });
+        },
+        getCarInfo() {
+            return new Promise((resolve, reject) => {
+                console.log(this.productId, this.chooseType == 'all' ? 0 : 1);
+                console.log(this.userInfo.id);
+                this.$http
+                    .get('/shoppingCart/getOne', {
+                        productId: this.productId,
+                        userId: this.userInfo.id,
+                        typeFlag: this.chooseType == 'all' ? 0 : 1,
+                    })
+                    .then(res => {
+                        if (res.success) {
+                            if (res.data.id) {
+                                resolve(res.data);
+                            } else {
+                                reject();
+                            }
+                        }
+                    })
+                    .catch(e => {
+                        reject();
+                    });
+            });
+        },
+        addCar() {
+            if (!this.hasChoose) {
+                //打开选项卡
+                this.showSpecifications = true;
+                // 保留正在等待加购物车状态
+                this.isWaiting = 'car';
+
+                return;
+            }
+
+            wx.showLoading({
+                title: '加载中',
+            });
+            this.getCarInfo()
+                .then(res => {
+                    //购物车存在该商品,增加商品数量
+                    var data = res;
+                    data.amount = data.amount + this.chooseNum;
+                    this.$http
+                        .post('/shoppingCart/update', data)
+                        .then(res => {
+                            wx.hideLoading();
+                            if (res.success) {
+                                wx.showToast({
+                                    title: '添加成功',
+                                    icon: 'success',
+                                    duration: 1500,
+                                });
+                            }
+                        })
+                        .catch(e => {
+                            console.log(e);
+                        });
+                })
+                .catch(() => {
+                    console.log('购物车中不存在');
+                    //购物车不存在该商品,添加商品至购物车
+                    var data = {
+                        amount: this.chooseNum,
+                        typeFlag: this.chooseType == 'all' ? 0 : 1,
+                        userId: this.$store.state.userInfo.id,
+                        productId: this.productId,
+                        storeId: this.productInfo.storeId,
+                    };
+
+                    this.$http
+                        .post('/shoppingCart/save', data)
+                        .then(res => {
+                            wx.hideLoading();
+                            if (res.success) {
+                                wx.showToast({
+                                    title: '添加成功',
+                                    icon: 'success',
+                                    duration: 1500,
+                                });
+                            }
+                        })
+                        .catch(e => {
+                            console.log(e);
+                        });
+                });
+        },
+        goWaiting() {
+            this.hasChoose = true;
+            console.log(this.isWaiting);
+            if (this.isWaiting == 'car') {
+                this.addCar();
+            } else if (this.isWaiting == 'submit') {
+                this.goSubmit();
+            }
+
+            this.isWaiting = '';
+        },
     },
     },
     components: {
     components: {
         specificationsContent,
         specificationsContent,

+ 5 - 0
src/pages/productList/productList.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './productList.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 4 - 0
src/pages/productList/productList.json

@@ -0,0 +1,4 @@
+{
+    "navigationBarTitleText": "搜索",
+    "backgroundColor": "#f2f4f5"
+}

+ 196 - 0
src/pages/productList/productList.vue

@@ -0,0 +1,196 @@
+<template>
+    <div class="container">
+
+        <div class="searchContent">
+
+            <div class="productList">
+                <productItem v-for="(item,index) in productList" :key="index" :info='item'></productItem>
+            </div>
+
+            <div class="nothing" v-if="isFinish &&productList.length==0">
+                <img src="/static/images/kong_icon_sousuo.png" alt="">
+                <div class="title">没有找到你要的商品</div>
+                <div class="sub">换个关键词,说不定找到喜欢的哦</div>
+            </div>
+
+            <view class="weui-loadmore" v-if="isFinish">
+                <view class="weui-loadmore__tips"></view>
+            </view>
+            <view class="weui-loadmore" v-else>
+                <view class="weui-loading"></view>
+                <view class="weui-loadmore__tips">正在加载</view>
+            </view>
+        </div>
+    </div>
+</template>
+
+<script>
+import productItem from '../../components/ProductItem';
+export default {
+    data() {
+        return {
+            currentPage: 1,
+            productList: [],
+            isFinish: false,
+            flag: false,
+            serviceType: 0,
+        };
+    },
+    onLoad(options) {
+        this.serviceType = options.serviceType;
+        wx.setNavigationBarTitle({
+            title: options.title || '',
+        });
+        this.currentPage = 1;
+        this.isFinish = false;
+        this.getProduct();
+    },
+    onReachBottom() {
+        if (this.flag) {
+            this.currentPage++;
+            this.getProduct();
+        }
+    },
+    methods: {
+        getProduct() {
+            if (this.currentPage == 1) {
+                this.productList = [];
+            }
+            this.flag = false;
+            var data = {
+                currentPage: this.currentPage,
+                pageNumber: 20,
+                serviceType: this.serviceType,
+            };
+            this.$http
+                .get('/productInfo/page', data)
+                .then(res => {
+                    if (res.success) {
+                        this.productList = this.productList.concat(res.data.pp);
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.flag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+    },
+    components: {
+        productItem,
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    padding-bottom: 10px;
+    box-sizing: border-box;
+    background-color: #f2f4f5;
+}
+.top {
+    position: sticky;
+    top: 0;
+    display: flex;
+    padding: 10px 0 10px 15px;
+    z-index: 20;
+    background-color: #fff;
+
+    .search {
+        display: flex;
+        background: rgba(242, 244, 245, 1);
+        border-radius: 22px;
+        flex-grow: 1;
+        height: 38px;
+        align-items: center;
+        padding: 0 10px 0 12px;
+        img {
+            width: 24px;
+            height: 24px;
+        }
+
+        input {
+            flex-grow: 1;
+            font-size: 14px;
+            color: #000;
+            min-width: 0;
+            font-weight: bold;
+        }
+
+        .pla {
+            font-size: 13px;
+            color: rgba(153, 153, 153, 1);
+            font-weight: normal;
+        }
+    }
+
+    .calcel {
+        text-align: center;
+        width: 55px;
+        font-size: 14px;
+        color: rgba(102, 102, 102, 1);
+        line-height: 38px;
+    }
+}
+.hot {
+    padding: 0 15px;
+}
+.hotTitle {
+    display: flex;
+    align-items: center;
+    height: 40px;
+    .hotIcon {
+        width: 14px;
+        height: 14px;
+    }
+
+    span {
+        font-size: 12px;
+        font-weight: bold;
+        color: rgba(0, 197, 242, 1);
+        line-height: 17px;
+        flex-grow: 1;
+    }
+
+    .clear {
+        width: 24px;
+        height: 24px;
+    }
+    border-bottom: 1px solid #f2f4f5;
+}
+
+.hotList {
+    display: flex;
+    flex-wrap: wrap;
+    padding: 10px 0;
+    .hotItem {
+        font-size: 13px;
+        color: rgba(102, 102, 102, 1);
+        line-height: 28px;
+        padding: 0 10px;
+        background: rgba(242, 244, 245, 1);
+        border-radius: 4px;
+        margin-right: 10px;
+        margin-bottom: 10px;
+    }
+}
+
+.historyItem {
+    font-size: 14px;
+    color: rgba(0, 0, 0, 1);
+    line-height: 35px;
+}
+
+.productList {
+    display: flex;
+    flex-wrap: wrap;
+    padding: 20rpx;
+}
+</style>

+ 5 - 0
src/pages/search/search.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './search.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/search/search.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": "搜索"
+}

+ 293 - 0
src/pages/search/search.vue

@@ -0,0 +1,293 @@
+<template>
+    <div class="container" :style="{backgroundColor:isSearch?'#f2f4f5':'#fff'}">
+        <div class="top">
+            <div class="search">
+                <img src="/static/images/icon_weizhi_1.png" alt="">
+                <input confirm-type='search' type="text" placeholder-class='pla' @focus='focusInput=true' @blur='blurInput' @confirm='inputConfirm' placeholder="搜索商品…" v-model="searchVal">
+                <img src="/static/images/icon_weizhi (1).png" v-if="focusInput&&searchVal" @click="searchVal=''" alt="">
+
+            </div>
+            <div class="calcel" @click="cancel">{{isSearch?'取消':'返回'}}</div>
+        </div>
+
+        <div class="hot" v-if="!isSearch">
+            <div class="hotTitle">
+                <img src="/static/images/search_iocn_remen.png" alt="" class="hotIcon">
+
+                <span>热门搜索</span>
+            </div>
+
+            <div class="hotList">
+                <div class="hotItem" v-for="(item,index) in hotList" :key="index" @click="search(item.keyword)">{{item.keyword}}</div>
+            </div>
+
+            <div class="histroy" v-if="historyList.length>0">
+                <div class="hotTitle">
+                    <img src="/static/images/search_iocn_lishi.png" alt="" class="hotIcon">
+                    <span>历史记录</span>
+                    <img src="/static/images/icon_weizhi (2).png" alt="" class="clear" @click="clear">
+
+                </div>
+
+                <div class="historyList">
+                    <div class="historyItem" v-for="(item,index) in historyList" :key="index" @click="search(item)">{{item}}</div>
+                </div>
+            </div>
+        </div>
+
+        <div class="searchContent" v-else>
+
+            <div class="searchList">
+                <productItem v-for="(item,index) in searchList" :key="index" :info='item'></productItem>
+            </div>
+
+            <div class="nothing" v-if="isFinish &&searchList.length==0">
+                <img src="/static/images/kong_icon_sousuo.png" alt="">
+                <div class="title">没有找到你要的商品</div>
+                <div class="sub">换个关键词,说不定找到喜欢的哦</div>
+            </div>
+
+            <view class="weui-loadmore" v-if="isFinish">
+                <view class="weui-loadmore__tips"></view>
+            </view>
+            <view class="weui-loadmore" v-else>
+                <view class="weui-loading"></view>
+                <view class="weui-loadmore__tips">正在加载</view>
+            </view>
+        </div>
+    </div>
+</template>
+
+<script>
+import productItem from '../../components/ProductItem';
+export default {
+    data() {
+        return {
+            searchVal: '',
+            focusInput: false,
+            isSearch: false,
+            hotList: [],
+            historyList: [],
+            nowSearchVal: '',
+            currentPage: 1,
+            searchList: [],
+            isFinish: false,
+            flag: false,
+        };
+    },
+    onLoad() {
+        this.isSearch = false;
+        this.$http.get('/hotSearch/all').then(res => {
+            if (res.success) {
+                this.hotList = res.data;
+            }
+        });
+        this.getHistory();
+    },
+    onReachBottom() {
+        if (this.flag &&this.isSearch) {
+            this.currentPage++;
+            this.getSearchList();
+        }
+    },
+    methods: {
+        blurInput() {
+            setTimeout(() => {
+                this.focusInput = false;
+            }, 500);
+        },
+        cancel() {
+            if (this.isSearch) {
+                this.isSearch = false;
+                this.searchVal = '';
+                this.nowSearchVal = '';
+            } else {
+                wx.navigateBack();
+            }
+        },
+        getHistory() {
+            this.historyList = wx.getStorageSync('searchHistory')
+                ? JSON.parse(wx.getStorageSync('searchHistory'))
+                : [];
+        },
+        inputConfirm(e) {
+            if (!this.searchVal) {
+                wx.showToast({
+                    title: '搜索内容不能为空',
+                    icon: 'none',
+                    duration: 1500,
+                });
+                return;
+            }
+            this.search(this.searchVal);
+        },
+        search(val) {
+            this.isFinish = false;
+            this.searchVal = val;
+            var historyList = [...this.historyList];
+            if (historyList.indexOf(val) == -1) {
+                historyList.push(val);
+                wx.setStorageSync('searchHistory', JSON.stringify(historyList));
+                this.getHistory();
+            }
+            this.isSearch = true;
+            this.nowSearchVal = val;
+            this.currentPage = 1;
+            this.getSearchList();
+        },
+        getSearchList() {
+            if (this.currentPage == 1) {
+                this.searchList = [];
+            }
+            this.flag = false;
+            var data = {
+                currentPage: this.currentPage,
+                pageNumber: 20,
+                searchKey: this.nowSearchVal,
+            };
+            this.$http
+                .get('/productInfo/page', data)
+                .then(res => {
+                    if (res.success) {
+                        this.searchList = this.searchList.concat(res.data.pp);
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.flag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        clear() {
+            var ref = this;
+            wx.showModal({
+                title: '提示',
+                content: '确定要清除搜索历史吗?',
+                confirmColor: '#00C5F2',
+                success(res) {
+                    if (res.confirm) {
+                        wx.removeStorageSync('searchHistory');
+                        ref.getHistory();
+                    } else if (res.cancel) {
+                    }
+                },
+            });
+        },
+    },
+    components: {
+        productItem,
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    padding-bottom: 10px;
+    box-sizing: border-box;
+}
+.top {
+    position: sticky;
+    top: 0;
+    display: flex;
+    padding: 10px 0 10px 15px;
+    z-index: 20;
+    background-color: #fff;
+
+    .search {
+        display: flex;
+        background: rgba(242, 244, 245, 1);
+        border-radius: 22px;
+        flex-grow: 1;
+        height: 38px;
+        align-items: center;
+        padding: 0 10px 0 12px;
+        img {
+            width: 24px;
+            height: 24px;
+        }
+
+        input {
+            flex-grow: 1;
+            font-size: 14px;
+            color: #000;
+            min-width: 0;
+            font-weight: bold;
+        }
+
+        .pla {
+            font-size: 13px;
+            color: rgba(153, 153, 153, 1);
+            font-weight: normal;
+        }
+    }
+
+    .calcel {
+        text-align: center;
+        width: 55px;
+        font-size: 14px;
+        color: rgba(102, 102, 102, 1);
+        line-height: 38px;
+    }
+}
+.hot {
+    padding: 0 15px;
+}
+.hotTitle {
+    display: flex;
+    align-items: center;
+    height: 40px;
+    .hotIcon {
+        width: 14px;
+        height: 14px;
+    }
+
+    span {
+        font-size: 12px;
+        font-weight: bold;
+        color: rgba(0, 197, 242, 1);
+        line-height: 17px;
+        flex-grow: 1;
+    }
+
+    .clear {
+        width: 24px;
+        height: 24px;
+    }
+    border-bottom: 1px solid #f2f4f5;
+}
+
+.hotList {
+    display: flex;
+    flex-wrap: wrap;
+    padding: 10px 0;
+    .hotItem {
+        font-size: 13px;
+        color: rgba(102, 102, 102, 1);
+        line-height: 28px;
+        padding: 0 10px;
+        background: rgba(242, 244, 245, 1);
+        border-radius: 4px;
+        margin-right: 10px;
+        margin-bottom: 10px;
+    }
+}
+
+.historyItem {
+    font-size: 14px;
+    color: rgba(0, 0, 0, 1);
+    line-height: 35px;
+}
+
+.searchList {
+    display: flex;
+    flex-wrap: wrap;
+    padding: 20rpx;
+}
+</style>

+ 5 - 0
src/pages/serviceDetail/serviceDetail.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './serviceDetail.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/serviceDetail/serviceDetail.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": "摄影师详情"
+}

+ 122 - 0
src/pages/serviceDetail/serviceDetail.vue

@@ -0,0 +1,122 @@
+<template>
+    <div class="container">
+        <swiper indicator-dots autoplay circular class="swiper">
+            <block v-for="(item,index) in swiperList" :key="index">
+                <swiper-item>
+                    <image mode="aspectFill" :src="item"></image>
+                </swiper-item>
+            </block>
+        </swiper>
+
+        <div class="name">
+            <span>{{detail.serviceName}}</span>
+            <span>{{levelName}}</span>
+        </div>
+
+        <div v-html="detail.introduction">
+        </div>
+    </div>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            detail: {},
+            storeServiceLevel: [],
+        };
+    },
+    computed: {
+        swiperList() {
+            var list = [];
+            if (this.detail.banner) {
+                list = this.detail.banner.split(',');
+            }
+            return list;
+        },
+        levelName() {
+            var list = [...this.storeServiceLevel];
+            var name = '';
+            list.forEach(item => {
+                if (this.detail.typeFlag == item.typeFlag) {
+                    name = item.levelName;
+                }
+            });
+            return name;
+        },
+    },
+    onLoad(options) {
+        console.log(options);
+
+        this.$http
+            .get('/storeServiceLevel/all')
+            .then(res => {
+                if (res.success) {
+                    this.storeServiceLevel = res.data;
+                }
+            })
+            .catch(e => {
+                console.log(e);
+            });
+
+        this.$http
+            .get('/storeService/getOne', {
+                id: options.id,
+            })
+            .then(res => {
+                if (res.success) {
+                    res.data.introduction = res.data.introduction.replace(
+                        /\<img/g,
+                        '<img style="width:100%;height:auto;display:block;margin-bottom:15px;border-radius:4px;"',
+                    );
+                    res.data.introduction = res.data.introduction.replace(
+                        /\<p/g,
+                        '<p style=" font-size: 14px; color: rgba(0, 0, 0, 1);line-height: 22px;;margin-bottom:20px"',
+                    );
+                    console.log(res.data.introduction);
+                    this.detail = res.data;
+                }
+            })
+            .catch(e => {
+                console.log(e);
+            });
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    padding: 15px;
+    .swiper {
+        width: 100%;
+        height: 345px;
+
+        image {
+            width: 100%;
+            height: 345px;
+            border-radius: 8px;
+        }
+    }
+
+    .name {
+        display: flex;
+        align-items: flex-end;
+        padding: 20px 0 10px;
+
+        span {
+            font-size: 24px;
+            font-weight: bold;
+            color: rgba(0, 0, 0, 1);
+            line-height: 33px;
+
+            &:last-child {
+                font-size: 14px;
+                font-weight: normal;
+                color: rgba(102, 102, 102, 1);
+                line-height: 20px;
+                margin-left: 9px;
+            }
+        }
+    }
+}
+</style>

+ 5 - 0
src/pages/serviceList/serviceList.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './serviceList.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/serviceList/serviceList.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": "资深摄影师"
+}

+ 97 - 0
src/pages/serviceList/serviceList.vue

@@ -0,0 +1,97 @@
+<template>
+    <div class="container">
+        <div class="serviceList">
+            <navigator class="serviceItem" :url="'/pages/serviceDetail/serviceDetail?id='+item.id" v-for="(item,index) in storeServiceList" :key="index">
+                <img :src="item.storeImage" background-size="cover">
+            </navigator>
+        </div>
+
+        <view class="weui-loadmore" v-if="isFinish">
+        </view>
+        <view class="weui-loadmore" v-else>
+            <view class="weui-loading"></view>
+            <view class="weui-loadmore__tips">正在加载</view>
+        </view>
+
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+export default {
+    data() {
+        return {
+            storeServiceList: [],
+            currentPage: 1,
+            serviceFlag: false,
+            isFinish: false,
+        };
+    },
+    computed: {
+        ...mapState(['storeInfo']),
+    },
+    onLoad() {
+        this.getList()
+    },
+    onReachBottom() {
+        if (this.serviceFlag) {
+            this.currentPage++;
+            this.getList();
+        }
+    },
+    methods: {
+        getList() {
+            if (this.currentPage == 1) {
+                this.storeServiceList = [];
+            }
+            this.$http
+                .get('/storeService/page', {
+                    storeId: this.storeInfo.id || 13,
+                    typeFlag: 'photographer',
+                    currentPage: this.currentPage,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.storeServiceList = this.storeServiceList.concat(
+                            res.data.pp,
+                        );
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.serviceFlag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    padding: 15px;
+
+    .serviceList {
+        display: flex;
+        justify-content: space-between;
+        flex-wrap: wrap;
+
+        .serviceItem {
+            margin-bottom: 9px;
+            width: 168px;
+            height: 86px;
+            img {
+                width: 100%;
+                height: 100%;
+                border-radius: 8px;
+            }
+        }
+    }
+}
+</style>

+ 44 - 4
src/pages/setting/setting.vue

@@ -3,13 +3,13 @@
         <div class="card">
         <div class="card">
             <div class="card-item">
             <div class="card-item">
                 <div class="name">头像</div>
                 <div class="name">头像</div>
-                <img :src="userInfo.icon" class="icon" background-size="cover" alt="">
-                <img src="/static/images/icon_inter.png" class="more" alt="">
+                <img @click="chooseImg" :src="icon" class="icon" background-size="cover" alt="">
+                <img @click="chooseImg" src="/static/images/icon_inter.png" class="more" alt="">
             </div>
             </div>
             <div class="card-item">
             <div class="card-item">
                 <div class="name">昵称</div>
                 <div class="name">昵称</div>
-                <div class="val">{{userInfo.nickname}}</div>
-                <img src="/static/images/icon_inter.png" class="more" alt="">
+                <div class="val" @click="goChangeNick">{{userInfo.nickname}}</div>
+                <img src="/static/images/icon_inter.png" @click="goChangeNick" class="more" alt="">
             </div>
             </div>
             <div class="card-item">
             <div class="card-item">
                 <div class="name">性别</div>
                 <div class="name">性别</div>
@@ -41,6 +41,7 @@ export default {
             noticeFlag: false,
             noticeFlag: false,
             sexList: ['男', '女'],
             sexList: ['男', '女'],
             sexIndex: 0,
             sexIndex: 0,
+            icon: '',
         };
         };
     },
     },
     computed: {
     computed: {
@@ -54,6 +55,7 @@ export default {
                     this.$store.commit('updateUserInfo', res.data);
                     this.$store.commit('updateUserInfo', res.data);
                     this.noticeFlag = res.data.noticeFlag == 'Y';
                     this.noticeFlag = res.data.noticeFlag == 'Y';
                     this.sexIndex = this.sexList.indexOf(res.data.sex);
                     this.sexIndex = this.sexList.indexOf(res.data.sex);
+                    this.icon = res.data.icon;
                 }
                 }
             })
             })
             .catch(e => {
             .catch(e => {
@@ -61,6 +63,13 @@ export default {
             });
             });
     },
     },
     methods: {
     methods: {
+        goChangeNick() {
+            wx.navigateTo({
+                url:
+                    '/pages/changeUser/changeUser?key=nickname&val=' +
+                    this.userInfo.nickname,
+            });
+        },
         switch1Change() {
         switch1Change() {
             this.noticeFlag = !this.noticeFlag;
             this.noticeFlag = !this.noticeFlag;
             this.updateUser('noticeFlag', this.noticeFlag ? 'Y' : 'N');
             this.updateUser('noticeFlag', this.noticeFlag ? 'Y' : 'N');
@@ -76,6 +85,7 @@ export default {
             this.updateUser('sex', sex);
             this.updateUser('sex', sex);
         },
         },
         updateUser(key, val) {
         updateUser(key, val) {
+            console.log(key, val);
             this.$http
             this.$http
                 .post('/userInfo/update', {
                 .post('/userInfo/update', {
                     id: this.userInfo.id,
                     id: this.userInfo.id,
@@ -94,6 +104,36 @@ export default {
                     console.log(e);
                     console.log(e);
                 });
                 });
         },
         },
+        chooseImg() {
+            var ref = this;
+            wx.chooseImage({
+                count: 1,
+                sizeType: ['compressed'],
+                sourceType: ['album', 'camera'],
+                success(res) {
+                    console.log(res);
+                    // tempFilePath可以作为img标签的src属性显示图片
+                    const tempFilePaths = res.tempFilePaths;
+                    setTimeout(() => {
+                        ref.icon = tempFilePaths[0];
+                    }, 500);
+                    wx.showLoading({
+                        title: '加载中',
+                        mask: true,
+                    });
+                    ref.$http
+                        .uploadFile('/assets/uploadFile', tempFilePaths[0])
+                        .then(res => {
+                            wx.hideLoading();
+                            res = JSON.parse(res);
+                            if (res.success) {
+                                console.log('aaaaaaaaaa');
+                                ref.updateUser('icon', res.data[0]);
+                            }
+                        });
+                },
+            });
+        },
     },
     },
 };
 };
 </script>
 </script>

+ 224 - 13
src/pages/shoppingCart/shoppingCart.vue

@@ -1,41 +1,243 @@
 <template>
 <template>
-    <div class="main">
+    <div class="main" :style="{ background:isFinish&&cartList.length!=0?'linear-gradient(#00c5f2 232rpx, #f2f4f5 232rpx, #f2f4f5)':'#f2f4f5' }">
         <div class="config">
         <div class="config">
-            <span>共5件商品</span>
-            <span>管理</span>
+            <span>共{{chooseList.length}}件商品</span>
+            <span @click="isConfig=!isConfig">{{isConfig?'结算':'管理'}}</span>
         </div>
         </div>
 
 
         <div class="cartList">
         <div class="cartList">
-            <shoppingCart v-for="i in 10" :key="i"></shoppingCart>
+            <shoppingCart v-for="(item,index) in cartList" @choose='choose' :chooseList='chooseList' :info="item" :index='index' :key="index" @updateAmount='updateAmount'></shoppingCart>
+            <view class="weui-loadmore" v-if="isFinish">
+            </view>
+            <view class="weui-loadmore" v-else>
+                <view class="weui-loading"></view>
+                <view class="weui-loadmore__tips">正在加载</view>
+            </view>
         </div>
         </div>
 
 
-        <div class="fixedBottom">
-            <img v-if="isChooseAll" src="/static/images/gouwuche_icon_xuanzhong.png" class="leftIcon" alt="">
-            <img v-else src="/static/images/gouwuche_icon_weixuanzhong.png" class="leftIcon" alt="">
+        <div class="nothing" v-if="isFinish&&cartList.length==0">
+            <img src="/static/images/kong_icon_gouwuche.png" alt="">
+            <div class="title">购物车还没东西哦</div>
+            <div class="sub">还没找到自己喜欢的东西吗</div>
+            <button  @click="goHome">去逛逛</button>
+        </div>
+
+        <div class="fixedBottom" v-if="!isConfig">
+            <div @click="ChangeChoose">
+                <img v-if="isChooseAll" src="/static/images/gouwuche_icon_xuanzhong.png" class="leftIcon" alt="">
+                <img v-else src="/static/images/gouwuche_icon_weixuanzhong.png" class="leftIcon" alt="">
+            </div>
             <span>全选</span>
             <span>全选</span>
             <span class="zhan"></span>
             <span class="zhan"></span>
             <span>合计:</span>
             <span>合计:</span>
 
 
-            <span class="price">368</span>
+            <span class="price">{{totalMoney}}</span>
 
 
-            <button>结算</button>
+            <button @click="submit">结算</button>
+        </div>
+
+        <div class="fixedBottom" v-else>
+            <div @click="ChangeChoose">
+                <img v-if="isChooseAll" src="/static/images/gouwuche_icon_xuanzhong.png" class="leftIcon" alt="">
+                <img v-else src="/static/images/gouwuche_icon_weixuanzhong.png" class="leftIcon" alt="">
+            </div>
+            <span style="flex-grow:1">全选</span>
+
+            <button class="del" @click="del">删除</button>
         </div>
         </div>
     </div>
     </div>
 </template>
 </template>
 
 
 <script>
 <script>
+import { mapState } from 'vuex';
 import shoppingCart from '../../components/ShoppingCart';
 import shoppingCart from '../../components/ShoppingCart';
+import calc from '../../calc';
 export default {
 export default {
     data() {
     data() {
         return {
         return {
-            isChooseAll: false,
+            currentPage: 1,
+            flag: false,
+            isFinish: false,
+            cartList: [],
+            chooseList: [],
+            isConfig: false,
         };
         };
     },
     },
+    computed: {
+        ...mapState(['userInfo', 'storeInfo']),
+        isChooseAll() {
+            var result = false;
+            if (
+                this.chooseList.length == this.cartList.length &&
+                this.cartList.length != 0
+            ) {
+                result = true;
+            }
+            return result;
+        },
+        chooseInfoList() {
+            var list = [];
+            var allList = [...this.cartList];
+            allList.forEach(item => {
+                if (this.chooseList.indexOf(item.id) != -1) {
+                    list.push(item);
+                }
+            });
+            return list;
+        },
+        totalMoney() {
+            var money = 0;
+            var list = [...this.chooseInfoList];
+            list.forEach(item => {
+                var total = this.getTotal(item);
+                money += total;
+            });
+            return money;
+        },
+    },
     onShow() {
     onShow() {
-        wx.setNavigationBarTitle({ title: '美瑞莉娜工作室' });
+        this.isFinish = false;
+        this.isConfig = false;
+        this.chooseList = [];
+        wx.setNavigationBarTitle({ title: this.storeInfo.storeName });
+        this.currentPage = 1;
+        this.getList();
+    },
+    onReachBottom() {
+        if (this.flag) {
+            this.currentPage++;
+            this.getList();
+        }
+    },
+    methods: {
+        getTotal(info) {
+            var money = 0;
+            if (info.typeFlag == 0) {
+                money = calc.Mul(info.amount, info.productInfo.price);
+            } else if (info.productInfo.downPayment) {
+                money = calc.Mul(info.amount, info.productInfo.downPayment);
+            }
+            return money;
+        },
+        goHome(){
+                wx.navigateTo({
+                url: '/pages/home/home',
+            });
+        },
+        getList() {
+            this.flag = false;
+            if (this.currentPage == 1) {
+                this.cartList = [];
+                wx.pageScrollTo({
+                    scrollTop: 0,
+                });
+            }
+            this.$http
+                .get('/shoppingCart/page', {
+                    userId: this.userInfo.id,
+                    currentPage: this.currentPage,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.cartList = this.cartList.concat(res.data.pp);
+                        if (
+                            res.data.page.currentPage < res.data.page.totalPage
+                        ) {
+                            // console.log('aaaaaa')
+                            this.flag = true;
+                        } else {
+                            this.isFinish = true;
+                        }
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        updateAmount(info) {
+            console.log(info);
+            this.cartList[info.index].amount = info.amount;
+            this.cartList[info.index].typeFlag = info.typeFlag;
+        },
+        choose(id) {
+            if (this.chooseList.indexOf(id) == -1) {
+                this.chooseList.push(id);
+            } else {
+                this.chooseList.splice(this.chooseList.indexOf(id), 1);
+            }
+        },
+        ChangeChoose() {
+            if (this.isChooseAll) {
+                this.chooseList = [];
+            } else {
+                var list = [...this.cartList];
+                list.forEach(item => {
+                    this.chooseList.push(item.id);
+                });
+            }
+        },
+        delList(index) {
+            if (index >= this.chooseList.length) {
+                wx.showToast({
+                    title: '删除成功',
+                    icon: 'success',
+                    duration: 1500,
+                });
+                this.currentPage = 1;
+                this.getList();
+                this.chooseList = [];
+                return;
+            }
+            this.$http
+                .post('/shoppingCart/del', {
+                    id: this.chooseList[index],
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.delList(index + 1);
+                    } else {
+                        wx.hideLoading();
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                });
+        },
+        submit() {
+            if (this.chooseList.length == 0) {
+                wx.showToast({
+                    title: '请选择商品',
+                    icon: 'none',
+                    duration: 1500,
+                });
+                return;
+            }
+
+            wx.navigateTo({
+                url:
+                    '/pages/submit/submit?submitPage=shoppingCart&chooseList=' +
+                    this.chooseList.join(','),
+            });
+        },
+        del() {
+            if (this.chooseList.length == 0) {
+                wx.showToast({
+                    title: '请选择商品',
+                    icon: 'none',
+                    duration: 1500,
+                });
+                return;
+            }
+            wx.showLoading({
+                title: '加载中',
+            });
+            this.delList(0);
+        },
     },
     },
     components: {
     components: {
-        shoppingCart
+        shoppingCart,
     },
     },
 };
 };
 </script>
 </script>
@@ -43,7 +245,7 @@ export default {
 <style lang='less' scoped>
 <style lang='less' scoped>
 .main {
 .main {
     min-height: 100%;
     min-height: 100%;
-    background-image: linear-gradient(#00c5f2 232rpx, #f2f4f5 232rpx, #f2f4f5);
+
     /* padding: 0 30rpx; */
     /* padding: 0 30rpx; */
     padding-bottom: 150rpx;
     padding-bottom: 150rpx;
 }
 }
@@ -118,6 +320,15 @@ export default {
         &:active {
         &:active {
             background-color: darken(rgba(0, 197, 242, 1), 10);
             background-color: darken(rgba(0, 197, 242, 1), 10);
         }
         }
+
+        &.del {
+            border: 1px solid rgba(0, 197, 242, 1);
+            color: #00c5f2;
+            background-color: #fff;
+            &:active {
+                background-color: darken(#fff, 10);
+            }
+        }
     }
     }
 }
 }
 </style>
 </style>

+ 138 - 11
src/pages/storeInfo/storeInfo.vue

@@ -21,6 +21,31 @@
             <img src="/static/images/icon_dizhi.png" alt="">
             <img src="/static/images/icon_dizhi.png" alt="">
             <span>地址:{{storeIntroduction.address}}</span>
             <span>地址:{{storeIntroduction.address}}</span>
         </div>
         </div>
+
+        <navigator class="cell" url="/pages/serviceList/serviceList">
+            <div class="name">资深摄影师</div>
+            <div class="sub">更多</div>
+            <img src="/static/images/icon_inter.png" alt="">
+        </navigator>
+
+        <div class="serviceList">
+            <navigator class="serviceItem" :url="'/pages/serviceDetail/serviceDetail?id='+item.id" v-for="(item,index) in storeServiceList" :key="index">
+                <img :src="item.storeImage" background-size="cover">
+            </navigator>
+        </div>
+
+        <navigator class="cell" url="/pages/caseList/caseList">
+            <div class="name">案例图集</div>
+            <div class="sub">更多</div>
+            <img src="/static/images/icon_inter.png" alt="">
+        </navigator>
+
+        <div class="storeCaseList">
+            <navigator class="storeCaseItem" :url="'/pages/caseDetail/caseDetail?id='+item.id" v-for="(item,index) in storeCaseList" :key="index">
+                <img :src="item.image" background-size="cover">
+            </navigator>
+        </div>
+
     </div>
     </div>
 </template>
 </template>
 
 
@@ -33,6 +58,8 @@ export default {
             longitude: 113.32452,
             longitude: 113.32452,
             latitude: 23.099994,
             latitude: 23.099994,
             markers: [],
             markers: [],
+            storeServiceList: [],
+            storeCaseList: [],
         };
         };
     },
     },
     computed: {
     computed: {
@@ -72,21 +99,60 @@ export default {
             .catch(e => {
             .catch(e => {
                 console.log(e);
                 console.log(e);
             });
             });
+
+        this.$http
+            .get('/storeService/all', {
+                storeId: this.storeInfo.id || 13,
+                storeFlag: 'Y',
+                typeFlag: 'photographer',
+            })
+            .then(res => {
+                if (res.success) {
+                    this.storeServiceList = res.data;
+                }
+            })
+            .catch(e => {
+                console.log(e);
+            });
+
+        this.$http
+            .get('/storeCase/page', {
+                storeId: this.storeInfo.id || 13,
+                typeFlag: 'case',
+                currentPage: 1,
+                pageNumber: 3,
+            })
+            .then(res => {
+                if (res.success) {
+                    this.storeCaseList = res.data.pp;
+                }
+            })
+            .catch(e => {
+                console.log(e);
+            });
     },
     },
     methods: {
     methods: {
         goWeb() {
         goWeb() {
             console.log('aaaaaaa');
             console.log('aaaaaaa');
-            wx.navigateTo({
-                url:
-                    '/pages/webView/webView?type=map&marker=coord:' +
-                    this.latitude +
-                    ',' +
-                    this.longitude +
-                    ';title:' +
-                    this.storeIntroduction.title +
-                    ';addr:' +
-                    this.storeIntroduction.address +
-                    '&referer=DSNBZ-UJHKK-F7TJS-A5XQY-3YGOF-SVFVB',
+            // wx.navigateTo({
+            //     url:
+            //         '/pages/webView/webView?type=map&marker=coord:' +
+            //         this.latitude +
+            //         ',' +
+            //         this.longitude +
+            //         ';title:' +
+            //         this.storeIntroduction.title +
+            //         ';addr:' +
+            //         this.storeIntroduction.address +
+            //         '&referer=DSNBZ-UJHKK-F7TJS-A5XQY-3YGOF-SVFVB',
+            // });
+
+            wx.openLocation({
+                latitude: Number(this.latitude),
+                longitude: Number(this.longitude),
+                name: this.storeIntroduction.title,
+                address: this.storeIntroduction.address,
+                scale: 14,
             });
             });
         },
         },
     },
     },
@@ -166,4 +232,65 @@ export default {
         margin-left: 5px;
         margin-left: 5px;
     }
     }
 }
 }
+
+.cell {
+    display: flex;
+    align-items: center;
+    height: 55px;
+    .name {
+        font-size: 20px;
+        font-weight: bold;
+        color: rgba(0, 0, 0, 1);
+        line-height: 28px;
+        flex-grow: 1;
+    }
+
+    .sub {
+        font-size: 12px;
+        color: rgba(153, 153, 153, 1);
+        line-height: 17px;
+    }
+
+    img {
+        width: 24px;
+        height: 24px;
+    }
+}
+.serviceList {
+    display: flex;
+    justify-content: space-between;
+    flex-wrap: wrap;
+
+    .serviceItem {
+        margin-bottom: 9px;
+        width: 168px;
+        height: 86px;
+        img {
+            width: 100%;
+            height: 100%;
+            border-radius: 8px;
+        }
+    }
+}
+.storeCaseList {
+    display: flex;
+    justify-content: space-between;
+    flex-wrap: wrap;
+    .storeCaseItem {
+        margin-bottom: 9px;
+        width: 168px;
+        height: 86px;
+
+        img {
+            width: 100%;
+            height: 100%;
+            border-radius: 8px;
+        }
+
+        &:last-child {
+            width: 100%;
+            height: 94px;
+        }
+    }
+}
 </style>
 </style>

+ 5 - 0
src/pages/submit/submit.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './submit.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 4 - 0
src/pages/submit/submit.json

@@ -0,0 +1,4 @@
+{
+    "navigationBarTitleText": "确认订单",
+    "backgroundColor": "#f2f4f5"
+}

+ 414 - 0
src/pages/submit/submit.vue

@@ -0,0 +1,414 @@
+<template>
+    <div class="container">
+        <subOrder :list='userOrderDetailList' :productMoney='productMoney' :type="pageType" @changeMessage='changeMessage'></subOrder>
+
+        <div class="card">
+            <div class="cardItem">
+                <div class="name">支付方式</div>
+                <!-- <div class="val">微信支付</div> -->
+                <div class="val">余额支付<small>(测试阶段)</small></div>
+            </div>
+        </div>
+
+        <div class="tip">
+            tips:测试阶段:支付用余额支付先行测试,余额默认无穷
+        </div>
+
+        <div class="fixBottom">
+            <span>总价:</span>
+            <span class="price">{{totalMoney}}</span>
+            <button @click="pay">确认支付</button>
+        </div>
+    </div>
+</template>
+
+<script>
+import { mapState } from 'vuex';
+import subOrder from '../../components/SubOrder';
+import calc from '../../calc';
+export default {
+    data() {
+        return {
+            pageType: 'submit',
+            productIdList: [],
+            amountList: [],
+            typeFlagList: [],
+            submitPage: 'product',
+            productList: [],
+            message: '',
+            orderInfo: {},
+            shoppCartIdList: [],
+            shoppCartInfoList: [],
+        };
+    },
+    computed: {
+        ...mapState(['userInfo']),
+        productMoney() {
+            var money = 0;
+            if (this.pageType == 'submit') {
+                var list = [...this.userOrderDetailList];
+
+                list.forEach(item => {
+                    money += item.productMoney;
+                });
+            }
+
+            return money;
+        },
+        totalMoney() {
+            if (this.pageType == 'submit') {
+                return this.productMoney;
+            } else {
+                return this.orderInfo.dealPrice;
+            }
+        },
+        userOrderDetailList() {
+            var list = [];
+            if (this.submitPage == 'product' && this.productList.length > 0) {
+                list = [
+                    {
+                        productInfo: this.productList[0],
+                        productId: this.productIdList[0],
+                        quantity: this.amountList[0],
+                        typeFlag: this.typeFlagList[0],
+                        message: this.message,
+                        useType: '到店消费',
+                        productMoney: this.getProductMoney(
+                            this.productList[0],
+                            this.amountList[0],
+                            this.typeFlagList[0],
+                        ),
+                    },
+                ];
+            } else if (
+                this.submitPage == 'shoppingCart' &&
+                this.shoppCartInfoList.length > 0
+            ) {
+                var allList = [...this.shoppCartInfoList];
+                allList.forEach(item => {
+                    list.push({
+                        productInfo: item.productInfo,
+                        productId: item.productId,
+                        quantity: item.amount,
+                        typeFlag: item.typeFlag,
+                        message: this.message,
+                        useType: '到店消费',
+                        productMoney: this.getProductMoney(
+                            item.productInfo,
+                            item.amount,
+                            item.typeFlag,
+                        ),
+                    });
+                });
+            } else if (this.pageType == 'pay' && this.orderInfo.id) {
+                list = [...this.orderInfo.userOrderDetailList];
+            }
+
+            return list;
+        },
+    },
+    onLoad(options) {
+        console.log(options);
+        this.refreash();
+        if (options.submitPage) {
+            this.submitPage = options.submitPage;
+            if (this.submitPage == 'product') {
+                this.productIdList = options.productId.split(',');
+                this.amountList = options.amount.split(',');
+                this.typeFlagList = options.typeFlag.split(',');
+                this.getProduct();
+            } else {
+                this.shoppCartIdList = options.chooseList.split(',');
+                var shoppCartIdList = options.chooseList.split(',');
+                shoppCartIdList.forEach(item => {
+                    this.getShoopingCart(item);
+                });
+            }
+        }
+
+        if (options.orderId) {
+            this.orderId = options.orderId;
+            this.pageType = 'pay';
+            this.getOrder();
+            wx.setNavigationBarTitle({
+                title: '支付订单',
+            });
+        } else {
+            wx.setNavigationBarTitle({
+                title: '确认订单',
+            });
+        }
+    },
+    methods: {
+        getShoopingCart(id) {
+            this.$http
+                .get('/shoppingCart/getOne', {
+                    id: id,
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.shoppCartInfoList.push(res.data);
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        refreash() {
+            this.pageType = 'submit';
+            this.productIdList = [];
+            this.amountList = [];
+            this.typeFlagList = [];
+            this.submitPage = 'product';
+            this.productList = [];
+            this.message = '';
+            this.orderInfo = {};
+            this.shoppCartIdList = [];
+            this.shoppCartInfoList = [];
+        },
+        changeMessage(message) {
+            this.message = message;
+        },
+        getProductMoney(info, quantity, typeFlag) {
+            var money = 0;
+
+            if (info.price) {
+                if (Number(typeFlag) == 0) {
+                    money = calc.Mul(Number(info.price), Number(quantity));
+                } else {
+                    money = calc.Mul(
+                        Number(info.downPayment),
+                        Number(quantity),
+                    );
+                }
+            }
+
+            return money;
+        },
+        getOrder() {
+            this.$http
+                .get('/userOrder/getOne', { id: this.orderId })
+                .then(res => {
+                    if (res.success) {
+                        this.orderInfo = res.data;
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        getProduct() {
+            this.productList = [];
+            this.$http
+                .get('/productInfo/getOne', { id: this.productIdList[0] })
+                .then(res => {
+                    if (res.success) {
+                        this.productList.push(res.data);
+                    }
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+        },
+        delCart(index) {
+            if (index >= this.shoppCartIdList.length) {
+                return;
+            }
+            this.$http
+                .post('/shoppingCart/del', {
+                    id: this.shoppCartIdList[index],
+                })
+                .then(res => {
+                    if (res.success) {
+                        this.delCart(index + 1);
+                    } else {
+                    }
+                });
+        },
+        submitOrder() {
+            return new Promise((resolve, reject) => {
+                var data = {
+                    userId: this.userInfo.id,
+                    storeId: this.userOrderDetailList[0].productInfo.storeId,
+                    userOrderDetailList: [...this.userOrderDetailList],
+                };
+                console.log(data);
+
+                data.userOrderDetailList.forEach(item => {
+                    delete item.productInfo;
+                    delete item.productMoney;
+                });
+
+                console.log(data);
+                wx.showLoading({
+                    title: '加载中',
+                    mask: true,
+                });
+                if (this.submitPage == 'shoppingCart') {
+                    this.delCart(0);
+                }
+                this.$http
+                    .postJ('/userOrder/submit', data)
+                    .then(res => {
+                        wx.hideLoading();
+                        if (res.success) {
+                            resolve(res.data);
+                        } else {
+                            wx.showToast({
+                                title: res.error,
+                                icon: 'none',
+                                duration: 1500,
+                            });
+                        }
+                    })
+                    .catch(e => {
+                        console.log(e);
+                    });
+            });
+        },
+        pay() {
+            console.log(this.pageType);
+            if (this.pageType == 'submit') {
+                this.submitOrder().then(id => {
+                    console.log(id);
+                    this.orderId = id;
+                    this.payMoney();
+                });
+            } else {
+                this.payMoney();
+            }
+        },
+        payMoney() {
+            //测试阶段先用余额支付
+            wx.showLoading({
+                title: '加载中',
+                mask: true,
+            });
+            this.$http
+                .post('userOrder/pay', {
+                    orderId: this.orderId,
+                    coin: this.totalMoney,
+                    point: 0,
+                    cash: 0,
+                })
+                .then(res => {
+                    wx.hideLoading();
+                    if (res.success) {
+                        wx.redirectTo({
+                            url:
+                                '/pages/successPage/successPage?pageType=paySuccess&orderId=' +
+                                this.orderId,
+                        });
+                        // wx.showToast({
+                        //     title: '支付成功',
+                        //     icon: 'success',
+                        //     duration: 1500,
+                        // });
+                        // setTimeout(() => {
+                        //     wx.navigateBack();
+                        // }, 1500);
+                    } else {
+                        wx.showToast({
+                            title: res.error,
+                            icon: 'none',
+                            duration: 1500,
+                        });
+                    }
+                });
+        },
+    },
+    components: {
+        subOrder,
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    min-height: 100%;
+    background: rgba(242, 244, 245, 1);
+    padding: 15px;
+    box-sizing: border-box;
+    padding-bottom: 56px;
+}
+
+.card {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 8px;
+    padding: 10px 15px;
+    margin-top: 10px;
+    .cardItem {
+        display: flex;
+        justify-content: space-between;
+        align-items: center;
+        height: 40px;
+
+        .name {
+            font-size: 13px;
+            color: rgba(56, 56, 56, 1);
+            line-height: 18px;
+        }
+
+        .val {
+            text-align: right;
+            font-size: 14px;
+            font-weight: bold;
+            color: rgba(0, 0, 0, 1);
+            line-height: 20px;
+            small {
+                font-size: 12px;
+                color: #999;
+            }
+        }
+    }
+}
+
+.fixBottom {
+    padding: 0 15px;
+    background-color: #fff;
+    position: fixed;
+    width: 100%;
+    left: 0;
+    bottom: 0;
+    box-sizing: border-box;
+    display: flex;
+    align-items: center;
+    height: 56px;
+
+    span {
+        font-size: 12px;
+        color: rgba(56, 56, 56, 1);
+        line-height: 17px;
+
+        &.price {
+            font-size: 22px;
+            font-weight: bold;
+            color: rgba(255, 59, 48, 1);
+            line-height: 30px;
+            flex-grow: 1;
+            margin-left: 3px;
+
+            &::before {
+                font-size: 16px;
+            }
+        }
+    }
+
+    button {
+        width: 136px;
+        height: 40px;
+        background: rgba(0, 197, 242, 1);
+        border-radius: 22px;
+        font-size: 15px;
+        font-weight: bold;
+        color: rgba(255, 255, 255, 1);
+    }
+}
+
+.tip {
+    text-align: center;
+    color: #999;
+    padding: 30px 0;
+    font-size: 12px;
+}
+</style>

+ 5 - 0
src/pages/successPage/successPage.js

@@ -0,0 +1,5 @@
+import Vue from 'vue'
+import App from './successPage.vue'
+
+const app = new Vue(App)
+app.$mount()

+ 3 - 0
src/pages/successPage/successPage.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": ""
+}

+ 99 - 0
src/pages/successPage/successPage.vue

@@ -0,0 +1,99 @@
+<template>
+    <div class="container">
+        <img src="/static/images/popup_icon_success_colour.png" alt="">
+        <div class="title">{{name}}</div>
+        <div class="sub">{{subTitle}}</div>
+        <button class="sure" v-if="sureBtn" @click="btnEvent">{{sureBtn}}</button>
+        <button class="back" @click="back">返回</button>
+    </div>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            pageType: '',
+            name: '',
+            subTitle: '',
+            sureBtn: '',
+            orderId: 0,
+        };
+    },
+    onLoad(options) {
+        this.pageType = options.pageType;
+        this.orderId = options.orderId;
+        this.name = '';
+        this.subTitle = '';
+        this.sureBtn = '';
+        if (this.pageType == 'paySuccess') {
+            this.sureBtn = '查看订单';
+            this.name = '支付成功';
+            this.subTitle = '订单支付成功,请返回订单详情预约排期';
+            wx.setNavigationBarTitle({
+                title: '支付完成',
+            });
+        }
+    },
+    methods: {
+        back() {
+            wx.navigateBack();
+        },
+        btnEvent() {
+            if (this.sureBtn == '查看订单') {
+                wx.redirectTo({
+                    url:
+                        '/pages/orderDetail/orderDetail?orderId=' +
+                        this.orderId,
+                });
+            }
+        },
+    },
+};
+</script>
+
+<style lang='less' scoped>
+.container {
+    display: flex;
+    flex-direction: column;
+    align-items: center;
+    padding: 0 20px;
+
+    img {
+        width: 84px;
+        height: 84px;
+        margin-top: 50px;
+    }
+
+    .title {
+        font-size: 20px;
+        font-weight: bold;
+        color: rgba(0, 0, 0, 1);
+        line-height: 28px;
+        margin-top: 20px;
+    }
+
+    .sub {
+        font-size: 14px;
+        color: rgba(0, 0, 0, 1);
+        line-height: 20px;
+        margin-top: 10px;
+    }
+
+    button {
+        width: 100%;
+        height: 44px;
+        font-size: 16px;
+        font-weight: bold;
+        line-height: 44px;
+        border-radius: 22px;
+        background: rgba(242, 244, 245, 1);
+        color: #656565;
+
+        &:not(:last-child) {
+            background: rgba(0, 197, 242, 1);
+            color: rgba(255, 255, 255, 1);
+            margin: 50px 0 15px;
+        }
+    }
+}
+</style>

+ 0 - 0
src/pages/user copy/user.js → src/pages/user copy 2/user.js


+ 3 - 0
src/pages/user copy 2/user.json

@@ -0,0 +1,3 @@
+{
+    "navigationBarTitleText": ""
+}

+ 0 - 0
src/pages/user copy/user.vue → src/pages/user copy 2/user.vue


+ 25 - 15
src/pages/user/user.vue

@@ -25,31 +25,31 @@
         <div class="order">
         <div class="order">
             <div class="order-top">
             <div class="order-top">
                 <div class="name">我的订单</div>
                 <div class="name">我的订单</div>
-                <div class="sub">查看全部订单</div>
-                <img src="/static/images/icon_inter.png" alt="">
+                <div class="sub" @click="goOrderList">查看全部订单</div>
+                <img src="/static/images/icon_inter.png" @click="goOrderList" alt="">
             </div>
             </div>
 
 
             <div class="orderList">
             <div class="orderList">
-                <div class="order-item">
+                <navigator :url="'/pages/orderList/orderList?orderStatus='+orderStatus.NOPAY" class="order-item">
                     <img src="/static/images/dingdan_icon_yuyue(1).png" alt="">
                     <img src="/static/images/dingdan_icon_yuyue(1).png" alt="">
                     <div class="name">待付款</div>
                     <div class="name">待付款</div>
-                </div>
-                <!-- <div class="order-item">
+                </navigator>
+                <navigator :url="'/pages/orderList/orderList?orderStatus='+orderStatus.PAYOVER" class="order-item">
                     <img src="/static/images/dingdan_icon_yuyue.png" alt="">
                     <img src="/static/images/dingdan_icon_yuyue.png" alt="">
                     <div class="name">待预约</div>
                     <div class="name">待预约</div>
-                </div> -->
-                <div class="order-item">
+                </navigator>
+                <navigator :url="'/pages/orderList/orderList?orderStatus='+orderStatus.BOOKPHOTO" class="order-item">
                     <img src="/static/images/dingdan_icon_paizhao.png" alt="">
                     <img src="/static/images/dingdan_icon_paizhao.png" alt="">
                     <div class="name">进行中</div>
                     <div class="name">进行中</div>
-                </div>
-                <div class="order-item">
+                </navigator>
+                <navigator :url="'/pages/orderList/orderList?orderStatus='+orderStatus.BOOKACCESS" class="order-item">
                     <img src="/static/images/dingdan_icon_paizhao(2).png" alt="">
                     <img src="/static/images/dingdan_icon_paizhao(2).png" alt="">
                     <div class="name">待取件</div>
                     <div class="name">待取件</div>
-                </div>
-                <div class="order-item">
+                </navigator>
+                <navigator :url="'/pages/orderList/orderList?orderStatus='+orderStatus.ACCESSOVER" class="order-item">
                     <img src="/static/images/dingdan_icon_paizhao(1).png" alt="">
                     <img src="/static/images/dingdan_icon_paizhao(1).png" alt="">
                     <div class="name">待评价</div>
                     <div class="name">待评价</div>
-                </div>
+                </navigator>
             </div>
             </div>
         </div>
         </div>
 
 
@@ -77,9 +77,12 @@
 
 
 <script>
 <script>
 import { mapState } from 'vuex';
 import { mapState } from 'vuex';
+import { OrderStatus } from '../../Constants';
 export default {
 export default {
     data() {
     data() {
-        return {};
+        return {
+            orderStatus: OrderStatus,
+        };
     },
     },
     computed: {
     computed: {
         ...mapState(['userInfo']),
         ...mapState(['userInfo']),
@@ -89,13 +92,20 @@ export default {
             .get('/userInfo/getUserInfo')
             .get('/userInfo/getUserInfo')
             .then(res => {
             .then(res => {
                 if (res.success) {
                 if (res.success) {
-                    this.$store.commit('updateUserInfo',res.data)
+                    this.$store.commit('updateUserInfo', res.data);
                 }
                 }
             })
             })
             .catch(e => {
             .catch(e => {
                 console.log(e);
                 console.log(e);
             });
             });
     },
     },
+    methods: {
+        goOrderList() {
+            wx.navigateTo({
+                url: '/pages/orderList/orderList',
+            });
+        },
+    },
 };
 };
 </script>
 </script>
 
 
@@ -203,7 +213,7 @@ export default {
 
 
     .orderList {
     .orderList {
         display: flex;
         display: flex;
-        justify-content: space-around;
+        justify-content: space-between;
         height: 74px;
         height: 74px;
         align-items: center;
         align-items: center;
 
 

+ 54 - 1
src/utils/http.js

@@ -1,4 +1,5 @@
-const baseUrl = process.env.NODE_ENV === 'development' ? 'http://192.168.50.15:8080' : '';
+// const baseUrl = process.env.NODE_ENV === 'development' ? 'http://192.168.50.15:8080' : '';
+const baseUrl = 'https://xcx.izouma.com'
 
 
 function parseUrl(url) {
 function parseUrl(url) {
     let _baseUrl = baseUrl;
     let _baseUrl = baseUrl;
@@ -72,6 +73,58 @@ export default {
                     });
                     });
                 });
                 });
             },
             },
+            postJ(url, data, options) {
+                options = options || {};
+                return new Promise((resolve, reject) => {
+                    wx.request({
+                        method: 'post',
+                        url: parseUrl(url),
+                        data: data,
+                        dataType: 'json',
+                        header: {
+                            token: this.token,
+                            ...(options.header || {}),
+                        },
+                        success(res) {
+                            if (res && res.statusCode === 200) {
+                                resolve(res.data);
+                            } else {
+                                reject(res);
+                            }
+                        },
+                        fail(err) {
+                            reject(err);
+                        },
+                    });
+                });
+            },
+            uploadFile(url, filePath, options) {
+                options = options || {};
+                return new Promise((resolve, reject) => {
+                    wx.uploadFile({
+                        url: parseUrl(url),
+                        filePath: filePath,
+                        name: 'file',
+                        formData: {
+                            'user': 'test'
+                        },
+                        header: {
+                            token: this.token,
+                            ...(options.header || {}),
+                        },
+                        success(res) {
+                            if (res && res.statusCode === 200) {
+                                resolve(res.data);
+                            } else {
+                                reject(res);
+                            }
+                        },
+                        fail(err) {
+                            reject(err);
+                        },
+                    });
+                });
+            },
         };
         };
         _Vue.prototype.$request = options => {
         _Vue.prototype.$request = options => {
             options = options || {};
             options = options || {};

BIN
static/images/Rectangle 29.png


BIN
static/images/dingdan_icon_shenpian.png


BIN
static/images/dingdan_icon_xuanpian.png


BIN
static/images/icon_shangchuantupian.png


BIN
static/images/icon_weizhi (1).png


BIN
static/images/icon_weizhi (2).png


BIN
static/images/icon_weizhi_1.png


BIN
static/images/kong_icon_dingdan.png


BIN
static/images/kong_icon_gouwuche.png


BIN
static/images/kong_icon_sousuo.png


BIN
static/images/nav_icon_return.png


BIN
static/images/popup_icon_success_colour.png


BIN
static/images/search_iocn_lishi.png


BIN
static/images/search_iocn_remen.png


BIN
static/images/xiangqing_icon_kefu(1).png


BIN
static/images/xiangqing_icon_kefu@3x.png