Authored by TaoHuang

Merge branch 'deploy_1019_2108' into develop

# Conflicts:
#	apps/pages/order/buyer-ask-order.vue
#	apps/pages/product/product-detail.vue
... ... @@ -6,7 +6,7 @@
<p class="account-name">{{alipayAccount?alipayAccount:nickName}}</p>
</div>
<p class="tip"><i class="cubeic-warn"></i><span>已绑定的支付宝账号暂无法提供系统换绑和解除,如
需要帮助可致电<a class="phone" href="tel:400-8890-9646"> 400-8890-9646 </a>联系电话客服</span></p>
需要帮助可致电<a class="phone" href="tel:400-889-9646"> 400-889-9646 </a>联系电话客服</span></p>
</div>
<div v-else>
<div class="bind-button" @click="bindAccount">设置支付宝账号</div>
... ...
... ... @@ -5,12 +5,13 @@
<div class="topContainer">
<!--<div class="topView">-->
<!--<div class="title"></div>-->
<!--</div>-->
<!--商品信息-->
<!--<div class="title"></div>-->
<!--</div>-->
<!--商品信息-->
<div class="productDetail">
<div class="productImageWrapper">
<ImageFormat class="image" :lazy="lazy" :src="originProductData.image" :width="136" :height="180"></ImageFormat>
<ImageFormat class="image" :lazy="lazy" :src="originProductData.image" :width="136"
:height="180"></ImageFormat>
</div>
<div class="productPrice">
<span class="size">{{sizeInfo}}</span>
... ... @@ -30,7 +31,8 @@
<span class="inputViewIcon">
¥
</span>
<Input ref="myinput" class="wordText" v-model="inputPrice" type="number" placeholder="定价需以9为结尾" @input="onTextChange"></Input>
<Input ref="myinput" class="wordText" v-model="inputPrice" type="number" placeholder="定价需以9为结尾"
@input="onTextChange"></Input>
</div>
<div>
... ... @@ -57,16 +59,16 @@
<div class="line"></div>
<div class="space"></div>
<order-address :data="addressInfo"></order-address>
<order-address :data="addressInfo"></order-address>
<div class="line"></div>
<div class="space"></div>
<!--<day-choose :chooseDay="chooseDay" :options="dayOptions" :choose="BUYER_ASK_SET_CHOOSEDAY"></day-choose>-->
<!--<day-choose :chooseDay="chooseDay" :options="dayOptions" :choose="BUYER_ASK_SET_CHOOSEDAY"></day-choose>-->
<div class="dayChoose" @click="showPicker">
<span class="leftText" >求购期限:</span>
<span class="leftText">求购期限:</span>
<div class="rightWrapper">
<span class="rightText">{{chooseDay || '7天'}}</span>
<i class="cubeic-arrow" ></i>
<i class="cubeic-arrow"></i>
</div>
</div>
... ... @@ -77,9 +79,10 @@
</div>
<div class="bottomContainer">
<OrderAgree :value="isAgreeTerms" @input="isAgreeTerms = !isAgreeTerms" class="agree-wrapper" :desc="agreeDesc" :url="url"></OrderAgree>
<OrderAgree :value="isAgreeTerms" @input="isAgreeTerms = !isAgreeTerms" class="agree-wrapper" :desc="agreeDesc"
:url="url"></OrderAgree>
<div class="btn-wrapper">
<YohoButton class="submit-btn" :txt="submitText" :disable="!isAgreeTerms" @click="submitClick"></YohoButton>
<YohoButton class="submit-btn" :txt="submitText" :disable="!isAgreeTerms" @click="submitClick"></YohoButton>
</div>
</div>
... ... @@ -88,12 +91,13 @@
<script>
import {Input, Button, Scroll} from 'cube-ui';
import { Input, Button, Scroll } from 'cube-ui';
import OrderAddress from './components/confirm/address';
import OrderAgree from './components/confirm/agree';
import { createNamespacedHelpers } from 'vuex';
import {debounce, get} from 'lodash';
const {mapState, mapActions, mapMutations, mapGetters} = createNamespacedHelpers(
import { debounce, get } from 'lodash';
const { mapState, mapActions, mapMutations, mapGetters } = createNamespacedHelpers(
'order/buyerAskOrder'
);
... ... @@ -114,7 +118,7 @@ export default {
url: 'https://activity.yoho.cn/feature/6775.html?nodownload=1',
agreeDesc: '有货买家协议',
submitText: '提交',
options: {pullDownRefresh: false}
options: { pullDownRefresh: false }
};
},
... ... @@ -145,22 +149,26 @@ export default {
},
beforeRouteEnter(to, from, next) {
next(vm => {
// 通过 `vm` 访问组件实例
if (from.name !== 'address') {
vm.inputPrice = '';
vm.BUYER_ASK_RESET_DATA();
}
});
},
activated() {
this.isActive = true;
},
deactivated() {
this.isActive = false;
},
mounted() {
this.BUYER_ASK_SET_STORAGEID(this.storageId);
this.fetchBuyerOrderCount({ tabType: 'buy'});
this.fetchBuyerOrderCount({ tabType: 'buy' });
this.fetchConfig();
this.$on('addressinfo', function(address) {
console.log(address);
... ... @@ -182,6 +190,9 @@ export default {
// },
addressInfo(val) {
if (!this.isActive) {
return;
}
if (this.inputPrice && val) {
this.computePrice();
... ... @@ -217,7 +228,7 @@ export default {
this.computePrice();
// }
}, 500, {leading: false, trailing: true}),
}, 500, { leading: false, trailing: true }),
showToast() {
this.BUYER_ASK_SET_SHOWTOAST(false);
... ... @@ -305,17 +316,26 @@ export default {
this.showBuyDialog();
return;
}
this.buyerPrePublish({price: this.inputPrice, storage_id: this.storageId, address_id: this.addressInfo.address_id})
this.buyerPrePublish({
price: this.inputPrice,
storage_id: this.storageId,
address_id: this.addressInfo.address_id
})
.then((res) => {
if (res && res.code == 200) {
this.showDialog();
}
});
}, 500, {leading: false, trailing: true}),
}, 500, { leading: false, trailing: true }),
publishProduct() {
this.buyerPublish({price: this.inputPrice, storage_id: this.storageId, address_id: this.addressInfo.address_id, time_limit_id: this.chooseDayId}).then((res) => {
this.buyerPublish({
price: this.inputPrice,
storage_id: this.storageId,
address_id: this.addressInfo.address_id,
time_limit_id: this.chooseDayId
}).then((res) => {
if (res && res.code == 200) {
this.payOrder();
}
... ... @@ -328,7 +348,11 @@ export default {
console.log('inputPrice is null');
return;
}
this.buyerCompute({price: this.inputPrice, storage_id: this.storageId, address_id: this.addressInfo.address_id || '' });
this.buyerCompute({
price: this.inputPrice,
storage_id: this.storageId,
address_id: this.addressInfo.address_id || ''
});
},
payOrder() {
... ... @@ -419,6 +443,7 @@ export default {
justify-content: space-between;
flex-direction: row;
}
.body {
height: 100%;
/*position: relative;*/
... ... @@ -455,7 +480,7 @@ export default {
.productDetail {
display: flex;
flex-direction: row;
width: calc(100% - 40*2px);
width: calc(100% - 40 * 2px);
height: 120*2px;
margin-left: 20*2px;
align-items: center;
... ... @@ -480,7 +505,7 @@ export default {
.productPrice {
width: calc(100% - 120*2px - 10*2px);
width: calc(100% - 120 * 2px - 10 * 2px);
height: 120*2px;
margin-left: 10*2px;
justify-content: center;
... ... @@ -534,7 +559,7 @@ export default {
background-color: #f5f5f5;
}
.inputViewIcon{
.inputViewIcon {
line-height: 50*2px;
font-size: 20*2px;
color: #000;
... ... @@ -561,7 +586,7 @@ export default {
.tipHeaderText {
font-family: "PingFang SC";
font-size: 14*2px;
color:#000;
color: #000;
letter-spacing: 0;
//<!--margin-left: 20*2px;-->
margin-top: 15*2px;
... ... @@ -582,7 +607,7 @@ export default {
letter-spacing: 0px;
margin-top: 5*2px;
//<!--margin-left: 20*2px;-->
width: calc(100% - 40*2px);
width: calc(100% - 40 * 2px);
}
.space {
... ... @@ -673,7 +698,8 @@ export default {
border-top-left-radius: 15px !important;
border-top-right-radius: 15px !important;
}
.cube-input_active::after {
border-color: transparent!important; ;
border-color: transparent !important;;
}
</style>
... ...
<template>
<layout-app title="商品列表" class="brand-product-list">
<scroll-view
ref="scroll"
:data="brandProductList"
:options="scrollOption"
@pulling-down="onPullingDown">
<div class="scroll-view" ref="scroll">
<div class="list-wrapper" v-if="brandProductList != null">
<product-list :list="brandProductList" priceKey="price"/>
</div>
</scroll-view>
</div>
</layout-app>
</template>
... ... @@ -50,6 +46,11 @@ export default {
asyncData({store, router}) {
return store.dispatch(`${STORE_PATH}/fetchBrandTop`, {productId: router.params.productId});
},
activated() {
if (this.$refs.scroll) {
this.$refs.scroll.scrollTop = 0;
}
},
methods: {
...mapActions(['fetchBrandTop']),
onPullingDown() {
... ... @@ -60,7 +61,10 @@ export default {
</script>
<style lang="scss" scoped>
.brand-product-list /deep/ .scroll-view {
.brand-product-list .scroll-view {
background: #f5f5f5;
height: 100%;
overflow: auto;
-webkit-overflow-scrolling: touch;
}
</style>
... ...
... ... @@ -8,7 +8,7 @@
:emulateMask="true"
:full="true">
<div class="buy-sheet">
<a class="header" href="https://activity.yoho.cn/feature/6765.html?nodownload=1">求购<i class="cubeic-question"></i></a>
<a class="header" @click.prevent="gotoNewPage">求购<i class="cubeic-question"></i></a>
<div class="title">
<div class="title-thumbnail">
<square-img :src="imageUrl" :width="300" :height="300"/>
... ... @@ -152,6 +152,9 @@ export default {
hide() {
this.$refs.popup.hide();
},
gotoNewPage() {
this.$xianyu.goXianyuNewPage({url: 'https://activity.yoho.cn/feature/6765.html?nodownload=1'});
}
},
};
</script>
... ...
... ... @@ -207,8 +207,6 @@ export default {
ul {
padding-bottom: 1px;
overflow: auto;
border-top: 1px solid #ddd;
border-left: 1px solid #ddd;
}
}
... ... @@ -217,8 +215,8 @@ export default {
width: 25%; // 当前固定为4列
float: left;
border: 1px solid #ddd;
margin-left: -1px;
margin-top: -1px;
margin-right: -1px;
margin-bottom: -1px;
.size-info,
.size-price {
... ...
... ... @@ -26,7 +26,7 @@
</div>
<div class="info-name"><div>{{productDetail.product_name}}</div></div>
</div>
<a class="banner" v-if="resource" :href="resource.url">
<a class="banner" v-if="resource" @click.prevent="gotoNewPage(resource.url)">
<img-size :src="sizeImg(resource.src)"/>
</a>
<div class="info">
... ... @@ -444,6 +444,11 @@ export default {
onBidSheetHide() {
this.showBidSheet = false;
},
// 资源位
gotoNewPage(url) {
this.$xianyu.goXianyuNewPage({url});
},
},
};
</script>
... ... @@ -658,6 +663,7 @@ export default {
.cube-scroll-wrapper {
flex: 1 0 0;
overflow: scroll;
-webkit-overflow-scrolling: touch;
}
.footer {
... ...
... ... @@ -44,7 +44,7 @@ export default function() {
let params = new URLSearchParams();
params.append('pagename', 'productList');
params.append('title', item.linkType);
params.append('title', item.name);
params.append(`${item.linkType}`, item.link);
item.isShow = false;
... ... @@ -63,7 +63,7 @@ export default function() {
let params = new URLSearchParams();
params.append('pagename', 'productList');
params.append('title', item.linkType);
params.append('title', item.name);
params.append(`${item.linkType}`, item.link);
return `${hostUrl}?${params}`
... ...
... ... @@ -121,6 +121,7 @@ export default function() {
state.selectedCouponList = [];
state.selectedPromotion = null;
state.couponList = [];
state.address = null;
},
[Types.UPDATE_ORDER](state, { amount, couponInfo, couponList, promotionFormulaList, promotionList, promotionTips }) {
state.orderDetail.amount = amount;
... ...