Commit 9c990fb492ccaea5962a8a68e2a6685d2383b686
1 parent
5638d36da2
Exists in
master
修改购物车
Showing
1 changed file
with
3 additions
and
46 deletions
Show diff stats
src/pages/cart/cart.vue
... | ... | @@ -14,7 +14,7 @@ |
14 | 14 | <text>非常戴镜</text> |
15 | 15 | </view> |
16 | 16 | |
17 | - <view class="cardBody" v-for="(item,index) in cartList" :key="item.cart_id" | |
17 | + <view class="cardBody" v-for="(item,index) in cartList" :key="index" | |
18 | 18 | @longpress="delCart(item.cart_id,index)"> |
19 | 19 | <view v-bind:class="childIsOpen[index]? 'partentChecked':'partentCheck'" |
20 | 20 | @tap="Change(childIsOpen[index],index)"> |
... | ... | @@ -30,9 +30,9 @@ |
30 | 30 | <view class="infoRight"> |
31 | 31 | <view class="goodName" @tap="toGoods(item.pid,item.sk_id)">{{item.p_name}}</view> |
32 | 32 | <!-- <view class="describ"> --> |
33 | - <uni-collapse accordion="true" > | |
33 | + <uni-collapse accordion="true" style="justify-content: space-around;width: 196px;"> | |
34 | 34 | <uni-collapse-item showAnimation='true' |
35 | - :title="item.tag.prod_tag_fun[0].label+'/'+item.tag.prod_tag_fun[1].label+'/'+item.tag.prod_tag_fun[2].label+'...' || '暂无'" > | |
35 | + :title="item.tag.prod_tag_fun[0].label&&item.tag.prod_tag_fun[1].label?item.tag.prod_tag_fun[0].label+'/'+item.tag.prod_tag_fun[1].label+'...':'暂无数据'" > | |
36 | 36 | <text class="describ"> |
37 | 37 | <block v-for="tag in item.tag.prod_tag_fun" :key="tag.value"> |
38 | 38 | {{tag.label+` `}} |
... | ... | @@ -133,49 +133,6 @@ export default { |
133 | 133 | fail: () => {}, |
134 | 134 | complete: () => {} |
135 | 135 | }) |
136 | - // uni.navigateTo({ | |
137 | - // url: '../frameDetail/frameDetail?oderId=' + id, | |
138 | - // success: res => {}, | |
139 | - // fail: () => {}, | |
140 | - // complete: () => {} | |
141 | - // }) | |
142 | - // console.log('toGoods =====> id:' + id + '======>type:' + type) | |
143 | - // switch (type) { | |
144 | - // case 1: | |
145 | - // uni.navigateTo({ | |
146 | - // url: '../frameDetail/frameDetail?oderId=' + id + '&goodType=' + type, | |
147 | - // success: res => {}, | |
148 | - // fail: () => {}, | |
149 | - // complete: () => {} | |
150 | - // }) | |
151 | - // break | |
152 | - // case 2: | |
153 | - // uni.navigateTo({ | |
154 | - // url: '../frameDetail/frameDetail?oderId=' + id + '&goodType=' + type, | |
155 | - // success: res => {}, | |
156 | - // fail: () => {}, | |
157 | - // complete: () => {} | |
158 | - // }) | |
159 | - // break | |
160 | - // case 3: | |
161 | - // uni.navigateTo({ | |
162 | - // url: '../frameDetail/frameDetail?oderId=' + id + '&goodType=' + type, | |
163 | - // success: res => {}, | |
164 | - // fail: () => {}, | |
165 | - // complete: () => {} | |
166 | - // }) | |
167 | - // break | |
168 | - // case 4: | |
169 | - // uni.navigateTo({ | |
170 | - // url: '../frameDetail/frameDetail?oderId=' + id + '&goodType=' + type, | |
171 | - // success: res => {}, | |
172 | - // fail: () => {}, | |
173 | - // complete: () => {} | |
174 | - // }) | |
175 | - // break | |
176 | - // default : | |
177 | - // break | |
178 | - // } | |
179 | 136 | }, |
180 | 137 | |
181 | 138 | counter(index, isadd, item) { | ... | ... |