|
@@ -4,7 +4,7 @@ import { useRequest, useModel } from '@umijs/max';
|
|
|
import { queryContractCode } from '@/services/contract';
|
|
|
|
|
|
function CodeField(props) {
|
|
|
- const { depId } = props;
|
|
|
+ const { depId, onChange } = props;
|
|
|
const { depList, run } = useModel('depList');
|
|
|
const [value, setValue] = useState('');
|
|
|
|
|
@@ -13,6 +13,7 @@ function CodeField(props) {
|
|
|
manual: true,
|
|
|
onSuccess: (data) => {
|
|
|
setValue(data?.code);
|
|
|
+ onChange?.(data?.code);
|
|
|
},
|
|
|
});
|
|
|
useEffect(() => {
|