This commit is contained in:
2024-01-21 20:02:46 +08:00
parent 944a015134
commit ca314defad
6 changed files with 175 additions and 76 deletions

View File

@@ -110,8 +110,8 @@
<view class="bottom">
<view style="display: flex;flex-direction: row;align-items: center; padding-left: 30px;">
<view style="width: 35px;height: 35px;position: relative; visibility: hidden; ">
<view style="display: flex;flex-direction: row;align-items: center; justify-content: center;">
<!-- <view style="width: 35px;height: 35px;position: relative; visibility: hidden; ">
<image style="width: 25px;height: 25px;margin-left: 5px; margin-top: 5px; "
src="../../static/basket_icon.png" mode="aspectFill"></image>
@@ -123,7 +123,7 @@
padding: 2px 5px;
width: auto;">{{page.count}}</view>
</view>
</view> -->
<view id="bomView" style="display: flex;flex-direction: row;align-items: center;">
<view style="color: #888;font-size: 10px;height: 10px;line-height: 10px;margin-top: 5px;">
@@ -135,6 +135,16 @@
<view style="color: #888;font-size: 10px;height: 10px;line-height: 10px;margin-top: 5px;">
{{data.brandVos[selectIndex2].qssl}}起订</view>
<view style="display: flex;flex-direction: row;align-items: center;" @click="showPop2()">
<text
style="color: #6190D8;font-size: 10px;height: 10px;line-height: 10px;margin-top: 5px;text-decoration:underline;font-style:oblique;">
起订协议</text>
<text
style="color: #6190D8;font-size: 10px;height: 10px;line-height: 10px;margin-top: 5px;">
>></text>
</view>
</view>
</view>
@@ -152,7 +162,7 @@
<text
style="font-size: 15px;color: #FF5006;margin-left: 10px;height: 20px;line-height: 20px;margin-top: 5px;font-weight: bold;">{{page.price}}</text>
<text
style="font-size: 10px;color: #666;margin-left: 10px; height: 10px;line-height: 10px;margin-bottom: 5px;">配送费{{page.reduce}}</text>
style="font-size: 10px;color: #666;margin-left: 10px; height: 10px;line-height: 10px;margin-bottom: 5px;">{{page.remarks}}</text>
</view>
</view>
@@ -176,6 +186,12 @@
:content="data.brandVos[selectIndex2].dgxy" :confirm-text="confirmText"></uni-popup-dialog>
</uni-popup>
<uni-popup ref="inputDialog2" type="dialog">
<uni-popup-dialog ref="inputClose" mode="base" title="起订协议" :showConfirm="true"
:beforeClose="dialogBeforeClose2" @confirm="dialogInputConfirm2"
content="1、20斤起订量。\n2、新用户正好20斤5折。\n3、20-100斤加10%附加额。\n4、101斤-200斤加5%附加额。"></uni-popup-dialog>
</uni-popup>
</view>
</template>
@@ -187,6 +203,7 @@
dialogContent: "这里是协议内容,这里是协议内容,这里是协议内容,这里是协议内容,这里是协议内容,这里是协议内容,这里是协议内容,这里是协议内容这里是协议内容,这里是协议内容",
confirmText: "我知道了5s",
dialogBeforeClose: false,
dialogBeforeClose2: false,
countdown: 5,
searchInfo: {
sid: "0",
@@ -212,6 +229,7 @@
reduce: "0",
weight: "0",
count: "0",
remarks: "",
startHeight: 0,
endHeight: 0
},
@@ -312,6 +330,7 @@
_this.page.price = resp.totalPrice
_this.page.weight = resp.totalWeight
_this.page.remarks = resp.remarks
_this.initPrice = resp.totalPrice
_this.initWeight = resp.totalWeight
@@ -474,19 +493,43 @@
},
dialogInputConfirm2(val) {
this.dialogBeforeClose2 = true
},
saveGoods() {
// var params = {
// customerSid: getApp().globalData.sid,
// brandId: this.data.brandVos[this.selectIndex2].id
// }
// // console.log("params", params);
// let _this = this
// _this.$api.saveGoods(params).then((resp) => {
// _this.request()
// }).catch(e => {})
var params = {
customerSid: getApp().globalData.sid,
brandId: this.data.brandVos[this.selectIndex2].id
// cardNumber: 1,
brandId:this.data.brandVos[this.selectIndex2].id,
totalTee: this.page.price,
// ordOrderDetailsVoList: list
}
// console.log("params", params);
console.log("params", params);
let _this = this
_this.$api.saveGoods(params).then((resp) => {
_this.request()
}).catch(e => {})
// _this.$api.createVegeOrder(params).then((resp) => {
// // console.log("resp", resp);
// this.$pay(resp)
// }).catch(e => {
// })
},
itemClick(goodsSid) {
@@ -496,9 +539,16 @@
},
gotoCart() {
uni.navigateTo({
url: '/pages/good/shoppCart?affiliation=' + this.data.brandVos[this.selectIndex2].id
url: '/pages/good/shoppCart?affiliation=' + this.data.brandVos[this.selectIndex2].id +
"&weight=" + this.data.brandVos[this.selectIndex2].qssl
})
},
showPop2() {
this.$refs.inputDialog2.open()
},
onShareAppMessage: function(res) {
console.log("res", res)
console.log("data", res.target.dataset)

View File

@@ -185,7 +185,7 @@
}
this.getUserInfo()
this.myRecommend()
// this.myRecommend()
},
onLoad(options) {
// this.request()