客户,供应商
This commit is contained in:
@@ -16,7 +16,7 @@ const QuotationPage = () => {
|
||||
total,
|
||||
fetchResources: fetchQuotations,
|
||||
deleteResource: deleteQuotation
|
||||
} = useResources(pagination, sorter);
|
||||
} = useResources(pagination, sorter, 'quota');
|
||||
|
||||
useEffect(() => {
|
||||
fetchQuotations();
|
||||
@@ -52,18 +52,12 @@ const QuotationPage = () => {
|
||||
},
|
||||
{
|
||||
title: '客户信息',
|
||||
dataIndex: ['attributes', 'companyName'],
|
||||
key: 'companyName',
|
||||
render: (companyName) => (
|
||||
<Tag color="blue">{companyName}</Tag>
|
||||
),
|
||||
},
|
||||
{
|
||||
title: '供应商',
|
||||
dataIndex: ['attributes', 'supplierName'],
|
||||
key: 'supplierName',
|
||||
render: (supplierName) => (
|
||||
<Tag color="green">{supplierName}</Tag>
|
||||
dataIndex: ['attributes', 'customerName'],
|
||||
key: 'customerName',
|
||||
render: (customerName,record) => (
|
||||
<Tag color="blue" className='cursor-pointer' onClick={() => {
|
||||
navigate(`/company/customerInfo/${record.attributes.customerId}`)
|
||||
}}>{customerName}</Tag>
|
||||
),
|
||||
},
|
||||
{
|
||||
@@ -82,7 +76,7 @@ const QuotationPage = () => {
|
||||
dataIndex: 'created_at',
|
||||
key: 'created_at',
|
||||
sorter: true,
|
||||
width: 180,
|
||||
width: 120,
|
||||
render: (text) => (
|
||||
<span>{new Date(text).toLocaleString('zh-CN', {
|
||||
year: 'numeric',
|
||||
@@ -96,11 +90,11 @@ const QuotationPage = () => {
|
||||
{
|
||||
title: '操作',
|
||||
key: 'action',
|
||||
width:180,
|
||||
width:200,
|
||||
render: (_, record) => (
|
||||
<Space size="mini">
|
||||
<Space size={0}>
|
||||
<Button
|
||||
size='mini'
|
||||
size='small'
|
||||
type="link"
|
||||
icon={<EyeOutlined />}
|
||||
onClick={() => navigate(`/company/quotaInfo/preview/${record.id}`)}
|
||||
@@ -108,7 +102,7 @@ const QuotationPage = () => {
|
||||
查看
|
||||
</Button>
|
||||
<Button
|
||||
size='mini'
|
||||
size='small'
|
||||
type="link"
|
||||
icon={<EditOutlined />}
|
||||
onClick={() => navigate(`/company/quotaInfo/${record.id}?edit=true`)}
|
||||
@@ -123,7 +117,7 @@ const QuotationPage = () => {
|
||||
cancelText="取消"
|
||||
okButtonProps={{ danger: true }}
|
||||
>
|
||||
<Button size='mini' type="link" danger icon={<DeleteOutlined />}>
|
||||
<Button size='small' type="link" danger icon={<DeleteOutlined />}>
|
||||
删除
|
||||
</Button>
|
||||
</Popconfirm>
|
||||
|
||||
Reference in New Issue
Block a user