This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
<nut-checkbox
|
||||
v-model="itm.state.checkbox"
|
||||
:indeterminate="itm.state.indeterminate"
|
||||
@change="(val: boolean) => changeBoxAll(val,idx)"
|
||||
@change="(val: boolean) => changeBoxAll(val, idx)"
|
||||
>{{ itm.StoreName }}
|
||||
</nut-checkbox>
|
||||
</nut-cell>
|
||||
@@ -187,18 +187,19 @@ const isShowPay = ref(false);
|
||||
const orderData = ref<any>([]);
|
||||
|
||||
const sub = async () => {
|
||||
const arr: any = list.value.filter(
|
||||
(item: any) => item.state.checkboxgroup.length > 0,
|
||||
);
|
||||
console.log(arr);
|
||||
if (arr.length === 0) {
|
||||
Taro.showToast({
|
||||
title: '请选择商品',
|
||||
icon: 'none',
|
||||
});
|
||||
return;
|
||||
}
|
||||
try {
|
||||
console.log('sub');
|
||||
const arr: any = list.value.filter(
|
||||
(item: any) => item.state.checkboxgroup.length > 0,
|
||||
);
|
||||
console.log(arr);
|
||||
if (arr.length === 0) {
|
||||
Taro.showToast({
|
||||
title: '请选择商品',
|
||||
icon: 'none',
|
||||
});
|
||||
return;
|
||||
}
|
||||
const {data: res} = await createActiveOrder({
|
||||
Bid: arr.map((item: any) => item.StoreBid),
|
||||
});
|
||||
@@ -212,7 +213,7 @@ const sub = async () => {
|
||||
}
|
||||
} catch (e) {
|
||||
Taro.showToast({
|
||||
title: e.msg,
|
||||
title: e.msg || '订单创建失败',
|
||||
icon: 'none',
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user