绑定项目只显示名称

perf/export-docx
Lei OT 12 months ago
parent 4350f37a6a
commit 67a21477c6

@ -43,19 +43,19 @@ const NewAddonModal = ({ onPick, ...props }) => {
const searchResultColumns = [ const searchResultColumns = [
{ key: 'ptype', dataIndex: ['info', 'product_type_id'], width: '6rem', title: t('products:ProductType'), render: (text, r) => productsTypesMapVal[text].label }, { key: 'ptype', dataIndex: ['info', 'product_type_id'], width: '6rem', title: t('products:ProductType'), render: (text, r) => productsTypesMapVal[text].label },
{ key: 'title', dataIndex: ['info', 'title'], width: '16rem', title: t('products:Title') }, { key: 'title', dataIndex: ['info', 'title'], width: '16rem', title: t('products:Title') },
{ // {
title: t('products:price'), // title: t('products:price'),
dataIndex: ['quotation', '0', 'adult_cost'], // dataIndex: ['quotation', '0', 'adult_cost'],
width: '10rem', // width: '10rem',
render: (_, { quotation }) => `${quotation[0].adult_cost} ${quotation[0].currency} / ${quotation[0].unit_name}`, // render: (_, { quotation }) => `${quotation[0].adult_cost} ${quotation[0].currency} / ${quotation[0].unit_name}`,
}, // },
{ {
key: 'action', key: 'action',
title: '', title: '',
width: 150, width: 150,
render: (_, record) => ( render: (_, record) => (
<Button className='text-primary' onClick={() => handleAddExtras(record)}> <Button className='text-primary' onClick={() => handleAddExtras(record)}>
附加此项目 绑定此项目
</Button> </Button>
), ),
}, },
@ -141,13 +141,13 @@ const Extras = ({ productId, onChange, ...props }) => {
const columns = [ const columns = [
{ title: t('products:Title'), dataIndex: ['info', 'title'], width: '16rem', }, { title: t('products:Title'), dataIndex: ['info', 'title'], width: '16rem', },
{ // {
title: t('products:Offer'), // title: t('products:Offer'),
dataIndex: ['quotation', '0', 'value'], // dataIndex: ['quotation', '0', 'value'],
width: '10rem', // width: '10rem',
render: (_, { quotation }) => `${quotation[0].adult_cost} ${quotation[0].currency} / ${quotation[0].unit_name}`, // todo: // render: (_, { quotation }) => `${quotation[0].adult_cost} ${quotation[0].currency} / ${quotation[0].unit_name}`,
}, // },
// { title: t('products:Types'), dataIndex: 'age_type', width: '40%', }, // { title: t('products:Types'), dataIndex: 'age_type', width: '40%', },
{ {
title: '', title: '',

Loading…
Cancel
Save