diff --git a/common/js/data.js b/common/js/data.js
index b3655d9..9264e16 100644
--- a/common/js/data.js
+++ b/common/js/data.js
@@ -48,13 +48,13 @@ const subCategories = [{
cuIcon: 'shopfill',
color: 'red',
name: '空调清洗',
- badge: '69洗'
+ badge: ''
}, {
id: 2,
cuIcon: 'shopfill',
color: 'orange',
name: '家庭维修',
- badge: '新品'
+ badge: ''
}, {
id: 3,
cuIcon: 'shopfill',
@@ -111,25 +111,25 @@ const subCategories = [{
badge: ''
}, {
id: 12,
- cuIcon: 'deliver',
+ cuIcon: 'shopfill',
color: 'green',
name: '手机维修',
badge: ''
}, {
id: 13,
- cuIcon: 'deliver',
+ cuIcon: 'shopfill',
color: 'pink',
name: '洗衣洗鞋',
badge: ''
}, {
id: 14,
- cuIcon: 'deliver',
+ cuIcon: 'shopfill',
color: 'pink',
name: '上门安装',
badge: ''
}, {
id: 15,
- cuIcon: 'deliver',
+ cuIcon: 'shopfill',
color: 'pink',
name: '奢品养护',
badge: ''
@@ -744,21 +744,21 @@ const myInfo = {
isVip: false,
level: 'V3'
},
- balance: '162.83',
+ balance: 0,
integrate: 0,
- cartNum: 3,
+ cartNum: 0,
servCircle: {
id: 1,
name: '保利云景',
- news: [{
+ newBuy: [{
id: 1,
- avatarUrl: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big33000.jpg',
+ avatarUrl: '',
userName: 'tsda9',
action: '购买了家政/修理/门窗/滑轮更换服务',
type: 0 // 0表示立即下单,1表示学家政
}, {
id: 2,
- avatarUrl: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big33001.jpg',
+ avatarUrl: '',
userName: '心da8',
action: '发布了清洗/空调/挂机清洗服务 高温蒸清全拆',
type: 1 // 0表示立即下单,1表示学家政
@@ -1605,83 +1605,83 @@ const servCategory = [{
}]
const categoryList = [{
- id: 1,
- name: '家电清洗',
- children: [{
+ goodsCategoryId: 1,
+ goodsCategoryName: '家电清洗',
+ child: [{
pId: 1,
- id: 2,
- name: '空调',
- children: [{
- id: 3,
- name: '单台清洗'
+ goodsCategoryId: 2,
+ goodsCategoryName: '空调',
+ child: [{
+ goodsCategoryId: 3,
+ goodsCategoryName: '单台清洗'
}, {
- id: 4,
- name: '套餐清洗'
+ goodsCategoryId: 4,
+ goodsCategoryName: '套餐清洗'
}, {
- id: 5,
- name: '空调加氧'
+ goodsCategoryId: 5,
+ goodsCategoryName: '空调加氧'
}]
}, {
pId: 1,
- id: 6,
- name: '烟灶',
- children: [{
- id: 7,
- name: '单台清洗'
+ goodsCategoryId: 6,
+ goodsCategoryName: '烟灶',
+ child: [{
+ goodsCategoryId: 7,
+ goodsCategoryName: '单台清洗'
}, {
- id: 8,
- name: '套餐清洗'
+ goodsCategoryId: 8,
+ goodsCategoryName: '套餐清洗'
}]
}]
}, {
- id: 9,
- name: '衣物洗护',
- children: [{
+ goodsCategoryId: 9,
+ goodsCategoryName: '衣物洗护',
+ child: [{
pId: 9,
- id: 10,
- name: '丝绸服装',
- children: [{
- id: 11,
- name: '单件清洗'
+ goodsCategoryId: 10,
+ goodsCategoryName: '丝绸服装',
+ child: [{
+ goodsCategoryId: 11,
+ goodsCategoryName: '单件清洗'
}, {
- id: 12,
- name: '套餐清洗'
+ goodsCategoryId: 12,
+ goodsCategoryName: '套餐清洗'
}]
}, {
pId: 9,
- id: 14,
- name: '呢绒服装',
- children: [{
- id: 15,
- name: '单件清洗'
+ goodsCategoryId: 14,
+ goodsCategoryName: '呢绒服装',
+ child: [{
+ goodsCategoryId: 15,
+ goodsCategoryName: '单件清洗'
}]
}]
}, {
- id: 16,
- name: 'Tab3',
- children: [{
- id: 17,
- name: 'Tab3-0',
- children: [{
- id: 18,
- name: 'Tab3-0-0'
+ goodsCategoryId: 16,
+ goodsCategoryName: 'Tab3',
+ child: [{
+ goodsCategoryId: 17,
+ goodsCategoryName: 'Tab3-0',
+ child: [{
+ goodsCategoryId: 18,
+ goodsCategoryName: 'Tab3-0-0'
}, {
- id: 19,
- name: 'Tab3-0-1'
+ goodsCategoryId: 19,
+ goodsCategoryName: 'Tab3-0-1'
}]
}]
}, {
- id: 20,
- name: 'Tab4',
- children: [{
- id: 21,
- name: 'Tab4-0',
- children: [{
- id: 22,
- name: 'Tab4-0-0'
+ goodsCategoryId: 20,
+ goodsCategoryName: 'Tab4',
+ child: [{
+ goodsCategoryId: 21,
+ goodsCategoryName: 'Tab4-0',
+ child: [{
+ goodsCategoryId: 22,
+ goodsCategoryName: 'Tab4-0-0'
}, {
- id: 23,
- name: 'Tab4-0-1'
+ goodsCategoryId: 23,
+ goodsCategoryName: 'Tab4-0-1'
}]
}]
}]
diff --git a/common/js/request.js b/common/js/request.js
index dfdcf54..07636e2 100644
--- a/common/js/request.js
+++ b/common/js/request.js
@@ -10,9 +10,9 @@ export default {
title: '加载中'
})
// request 触发前拼接 url
- // args.url = 'https://www.opsoul.com' + args.url;
+ args.url = 'https://www.opsoul.com' + args.url;
// args.url = 'http://192.168.2.42:80' + args.url;
- args.url = 'http://127.0.0.1:80' + args.url;
+ // args.url = 'http://127.0.0.1:80' + args.url;
if (args.data) {
args.data.deptId = globalData.deptId;
args.data.from = globalData.from;
diff --git a/components/default-toast/bg-toast.vue b/components/default-toast/bg-toast.vue
index d33685c..10b3546 100644
--- a/components/default-toast/bg-toast.vue
+++ b/components/default-toast/bg-toast.vue
@@ -2,7 +2,7 @@
- 开发中,敬请期待
+ 功能开发中,暂无法使用
diff --git a/pages/index/home.vue b/pages/index/home.vue
index 4d66647..946acdd 100644
--- a/pages/index/home.vue
+++ b/pages/index/home.vue
@@ -33,13 +33,11 @@
-
-
-
-
- {{item.name}}
-
+
+
+
+ {{item.goodsCategoryName}}
@@ -53,7 +51,7 @@
{{item.badge}}
- {{item.name}}
+ {{item.goodsCategoryName}}
@@ -65,7 +63,7 @@
{{item.badge}}
- {{item.name}}
+ {{item.goodsCategoryName}}
@@ -118,7 +116,8 @@
verticalGoodsCard
},
data() {
- return {
+ return {
+ scrollLeft: 0,
dotStyle: true,
swiperList: [],
tabCur: 0,
@@ -170,11 +169,13 @@
pageNum: 0,
pageSize: 50
});
- this.hotGoods = hotGoodsRes.rows;
+ this.hotGoods = hotGoodsRes.rows;
+ // 加载品类
+ this.loadCategoryList();
this.swiperList = await this.$api.data('swiperList');
- this.categories = await this.$api.data('categories');
- this.subCategories = await this.$api.data('subCategories');
+ // this.categories = await this.$api.data('categories');
+ // this.subCategories = await this.$api.data('subCategories');
this.moduleBarInfos = await this.$api.data('moduleBarInfos');
// this.hotGoods = await this.$api.data('hotGoods');
// this.discountGoods = await this.$api.data('discountGoods');
@@ -184,6 +185,16 @@
},
offBindEvent() {
uni.$off('index_showProductDetail');
+ },
+ async loadCategoryList() {
+ let typeList = await this.$request.listByStep();
+ typeList = typeList.data;
+ let subTypeList = await this.$request.listByStep({
+ goodsCategoryId: typeList[0].goodsCategoryId
+ });
+ subTypeList = subTypeList.data;
+ this.categories = subTypeList;
+ this.tabSelect(null, this.categories[0]);
},
async loadRegionList() {
let regionList = await this.$request.areaListByStep();
@@ -247,13 +258,19 @@
this.areaMultiIndex = [this.areaMultiIndex[0], colObj.value, 0];
}
},
- async tabSelect(e) {
- this.tabCur = e.currentTarget.dataset.id;
- // 获取大类信息
- let categoryId = this.categories[this.tabCur].id;
- console.log("切换细类, 大类id=" + categoryId);
- let allSubCategories = await this.$api.data('subCategories');
- this.subCategories = allSubCategories.slice(0, (4 - categoryId) * 5);
+ async tabSelect(e, item) {
+ this.tabCur = e == null ? 0 : e.currentTarget.dataset.index;
+ this.scrollLeft = (this.tabCur - 1) * 60;
+ let subSubTypeList = await this.$request.listByStep({
+ goodsCategoryId: item.goodsCategoryId
+ });
+ subSubTypeList = subSubTypeList.data;
+ let subCategoryOpt = await this.$api.data('subCategories');
+ for(let i = 0; i < subSubTypeList.length; i++) {
+ subSubTypeList[i]['cuIcon'] = subCategoryOpt[i].cuIcon;
+ subSubTypeList[i]['color'] = subCategoryOpt[i].color;
+ }
+ this.subCategories = subSubTypeList;
},
chooseCategory(item) {
this.searchInfo.category = item;
diff --git a/pages/index/my-home.vue b/pages/index/my-home.vue
index e768fc9..b94f973 100644
--- a/pages/index/my-home.vue
+++ b/pages/index/my-home.vue
@@ -46,7 +46,7 @@
-
+
@@ -287,19 +287,19 @@
}],
servOrderType: 0,
productOrderTabList: [{
- type: 'pdOrdersWait2Pay',
+ // type: -1,
name: '待付款'
}, {
- type: 'pdOrdersBought',
+ type: -1,
name: '买到的'
}, {
- type: 'pdOrdersSaled',
+ type: -1,
name: '卖出的'
}, {
- type: 'pdOrdersAfterServ',
+ type: -1,
name: '售后中'
}, {
- type: 'pdOrdersFinish',
+ type: -1,
name: '已完成'
}],
productOrderType: 1
diff --git a/pages/my/my-cart.vue b/pages/my/my-cart.vue
index 4c9e526..6536d81 100644
--- a/pages/my/my-cart.vue
+++ b/pages/my/my-cart.vue
@@ -79,7 +79,7 @@
},
methods: {
async loadData() {
- this.pickedProductList = await this.$api.data('pickedProductList');
+ // this.pickedProductList = await this.$api.data('pickedProductList');
},
bindEvent() {
uni.$on('changePickedNum', this.changePickedNum);
@@ -140,9 +140,9 @@
this.allChecked = !this.allChecked;
},
submit() {
- uni.navigateTo({
- url: '/pages/order/order-detail'
- })
+ // uni.navigateTo({
+ // url: '/pages/order/order-detail'
+ // })
}
}
}
diff --git a/pages/order/order-detail.vue b/pages/order/order-detail.vue
index 99f8316..002d675 100644
--- a/pages/order/order-detail.vue
+++ b/pages/order/order-detail.vue
@@ -64,7 +64,7 @@
- {{item.shopName}}
+ {{item.name}}
@@ -176,12 +176,18 @@
this.offBindEvent();
},
methods: {
- async loadData(params) {
- console.log(params)
+ async loadData(params) {
// this.pickedProductList = await this.$api.data('pickedProductList');
this.pickedProductList = params.pickedProductList;
+ this.loadTotalPrice();
this.timeRangeList = this.$globalData.timeRangeList;
this.timeRange = this.timeRangeList[0];
+ },
+ loadTotalPrice() {
+ // 计算totalprice
+ this.pickedProductList.forEach((obj) => {
+ this.totalPrice += Number(obj.totalMoney)
+ })
},
bindEvent() {
uni.$on(this.$globalFun.CHOOSE_ADDRESS, this.chooseAddress);
diff --git a/pages/order/pay-result.vue b/pages/order/pay-result.vue
index e831394..8b3ca87 100644
--- a/pages/order/pay-result.vue
+++ b/pages/order/pay-result.vue
@@ -1,9 +1,9 @@
-
- 返回
- 支付结果
+
+
{{customTip}}
diff --git a/pages/product/product-detail.vue b/pages/product/product-detail.vue
index db45c3c..a5c106a 100644
--- a/pages/product/product-detail.vue
+++ b/pages/product/product-detail.vue
@@ -38,21 +38,21 @@
{{curProductSpecs.goodsPrice}}
- 已售:{{curProductSpecs.saledCount}}
+
- 佣金:{{curProductSpecs.groupPrice}}
+
- 距结束:
-
+
+
diff --git a/pages/product/product-pick.vue b/pages/product/product-pick.vue
index df71bc7..b502c23 100644
--- a/pages/product/product-pick.vue
+++ b/pages/product/product-pick.vue
@@ -128,7 +128,8 @@
}
let params = {
pickedProductList: [{
- ...this.shopInfo,
+ ...this.shopInfo,
+ totalMoney: this.totalPrice,
product: [{
...this.productInfo,
discountPrice: this.specsList[0].discountPrice,
diff --git a/pages/product/shop-detail.vue b/pages/product/shop-detail.vue
index 5204ecd..7e0414a 100644
--- a/pages/product/shop-detail.vue
+++ b/pages/product/shop-detail.vue
@@ -236,7 +236,8 @@
searchGoods() {
let params = {
areaId: this.searchInfo.area[2].areaId,
- goodsName: this.searchInfo.goodsName
+ goodsName: this.searchInfo.goodsName,
+ workerId: this.shopInfo.workerId
};
this.loadProductData(params);
},
diff --git a/pages/publish/publish-task.vue b/pages/publish/publish-task.vue
index 965ac7c..e5a6c01 100644
--- a/pages/publish/publish-task.vue
+++ b/pages/publish/publish-task.vue
@@ -232,7 +232,11 @@
async loadData() {
this.categoryList = await this.$api.data('categoryList');
this.areaList = await this.$api.data('areaList');
- this.defaultAddress = await this.$api.data('defaultAddress');
+ this.defaultAddress = await this.$api.data('defaultAddress');
+ uni.showToast({
+ title: '功能开发中,暂无法使用',
+ icon: 'none'
+ })
},
nextStep() {
this.curStep = this.curStep === this.stepList.length - 1 ? this.curStep : ++this.curStep