|
@ -20,22 +20,18 @@ |
|
|
<a-input style="width: 200px" v-model="company" /> |
|
|
<a-input style="width: 200px" v-model="company" /> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class="cart-box" v-if="cart.lists && cart.lists.length > 0"> |
|
|
<div class="cart-box" v-if="cart && cart.length > 0"> |
|
|
<div |
|
|
<div :key="list.id" class="d-flex flex-column pa-5 white div-box mb-8" v-for="list in cart"> |
|
|
:key="list.id" |
|
|
<p class="font-bold-20 title-color">服务</p> |
|
|
class="d-flex flex-column pa-5 white div-box mb-8" |
|
|
|
|
|
v-for="list in cart.lists" |
|
|
|
|
|
> |
|
|
|
|
|
<p class="font-bold-20 title-color">{{ list.title }}</p> |
|
|
|
|
|
<div |
|
|
<div |
|
|
:key="index" |
|
|
:key="index" |
|
|
class="d-flex flex-nowrap flex-row mb-8" |
|
|
class="d-flex flex-nowrap flex-row mb-8" |
|
|
v-for="(item, index) in list.list" |
|
|
v-for="(item, index) in list.carDetailList" |
|
|
> |
|
|
> |
|
|
<img :src="item.src" class="cart-pic mr-8" /> |
|
|
<img :src="item.picUrl" class="cart-pic mr-8" /> |
|
|
<div class="flex-1 flex-column"> |
|
|
<div class="flex-1 flex-column"> |
|
|
<p class="font-bold-20 title-color">{{ item.title }}</p> |
|
|
<p class="font-bold-20 title-color">{{ item.name }}</p> |
|
|
<p class="font-14 textColor">{{ item.content }}</p> |
|
|
<p class="font-14 textColor">{{ item.description }}</p> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -104,6 +100,7 @@ export default { |
|
|
const { data, msg, code } = res.data; |
|
|
const { data, msg, code } = res.data; |
|
|
if (code === 200) { |
|
|
if (code === 200) { |
|
|
this.cart = data; |
|
|
this.cart = data; |
|
|
|
|
|
console.log('this.cart: ', this.cart); |
|
|
} |
|
|
} |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
console.log(error); |
|
|
console.log(error); |
|
@ -130,8 +127,7 @@ export default { |
|
|
this.phone = tel; |
|
|
this.phone = tel; |
|
|
} |
|
|
} |
|
|
const { name, phone, company, cart } = this; |
|
|
const { name, phone, company, cart } = this; |
|
|
const ids = []; |
|
|
const ids = cart[0].carId; |
|
|
ids.push(cart.id); |
|
|
|
|
|
const params = { |
|
|
const params = { |
|
|
param: { |
|
|
param: { |
|
|
contactName: company, |
|
|
contactName: company, |
|
@ -140,6 +136,7 @@ export default { |
|
|
ids, |
|
|
ids, |
|
|
}, |
|
|
}, |
|
|
}; |
|
|
}; |
|
|
|
|
|
console.log('params: ', params); |
|
|
const res = await carAndBuy(params); |
|
|
const res = await carAndBuy(params); |
|
|
const { data, msg, code } = res.data; |
|
|
const { data, msg, code } = res.data; |
|
|
if (code === 200) { |
|
|
if (code === 200) { |
|
|