带录入 供应商名称 点击
This commit is contained in:
@ -2,6 +2,7 @@ import React, { useState, useEffect } from 'react';
|
||||
import { Modal, Input, Button, Form, Table, Tooltip } from 'antd';
|
||||
import { coscoSupplierBase } from '../services';
|
||||
import RegionTypeSelect from '@/components/CommonSelect/RegionTypeSelect'
|
||||
import { useSupplierDetailModal } from '@/components/SupplierDetailModalContext/SupplierDetailModalContext';
|
||||
|
||||
const SupplierSelector: React.FC<{
|
||||
visible: boolean;
|
||||
@ -21,6 +22,7 @@ const SupplierSelector: React.FC<{
|
||||
const [pagination, setPagination] = useState({ current: 1, pageSize: 10, total: 0 });
|
||||
// 加载态
|
||||
const [loading, setLoading] = useState(false);
|
||||
const supplierDetailModal = useSupplierDetailModal();
|
||||
|
||||
// 查询
|
||||
const getTableList = async (values: any = {}, pageNo: number = 1, pageSize: number = 10) => {
|
||||
@ -59,7 +61,7 @@ const SupplierSelector: React.FC<{
|
||||
const name = record.supplierType === "ovs" ? record.nameEn : record.name;
|
||||
return (
|
||||
<Tooltip placement="topLeft" title={name}>
|
||||
{name}
|
||||
<a onClick={() => supplierDetailModal?.(record.id)}>{name || ''}</a>
|
||||
</Tooltip>
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user