|
|
@ -119,7 +119,7 @@ const Extras = ({ productId, onChange, ...props }) => {
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
const handleNewAddOn = async (item) => {
|
|
|
|
const handleNewAddOn = async (item) => {
|
|
|
|
setExtrasData(prev => [].concat(prev, [item]));
|
|
|
|
// setExtrasData(prev => [].concat(prev, [item]));
|
|
|
|
// todo: 提交后端; 重复绑定同一个
|
|
|
|
// todo: 提交后端; 重复绑定同一个
|
|
|
|
const _item = pick(item, ['id', 'title', 'code']);
|
|
|
|
const _item = pick(item, ['id', 'title', 'code']);
|
|
|
|
const newSuccess = await addProductExtraAction({ travel_agency_id, id: productId, extras: [_item] });
|
|
|
|
const newSuccess = await addProductExtraAction({ travel_agency_id, id: productId, extras: [_item] });
|
|
|
|