|
@@ -7,8 +7,6 @@ Component({
|
|
|
},
|
|
|
methods: {
|
|
|
onClick(item) {
|
|
|
- console.log(item)
|
|
|
- console.log(this.data.product)
|
|
|
if (this.data.product != null && item.itemid == this.data.product.itemid) return this.setData({
|
|
|
show: true
|
|
|
})
|
|
@@ -35,9 +33,16 @@ Component({
|
|
|
title: '定制方案获取失败',
|
|
|
icon: "none"
|
|
|
})
|
|
|
- if (item.lengthschemeid) arr.push(s[0].data)
|
|
|
- if (item.widthschemeid) arr.push(s[1].data)
|
|
|
-
|
|
|
+ if (item.lengthschemeid) {
|
|
|
+ let data = s[0].data;
|
|
|
+ if (item.length == 0) item.length = data.type == '可选' ? data.rowsdetail[0].num || 0 : data.min;
|
|
|
+ arr.push(data)
|
|
|
+ }
|
|
|
+ if (item.widthschemeid) {
|
|
|
+ let data = s[1].data;
|
|
|
+ if (item.width == 0) item.width = data.type == '可选' ? data.rowsdetail[0].num || 0 : data.min;
|
|
|
+ arr.push(data)
|
|
|
+ }
|
|
|
this.setData({
|
|
|
show: true,
|
|
|
arr,
|