Commit 3c8dd2e1 by zhaochengxiang

资产编辑内容丢失的问题

parent 27024f93
......@@ -31,9 +31,7 @@ const AssetAction = (props) => {
getElements();
} else if ((id||'')!=='') {
setCurrentAction('detail');
getElements(() => {
getAsset();
});
getAsset();
}
//eslint-disable-next-line react-hooks/exhaustive-deps
}, [id])
......@@ -84,6 +82,9 @@ const AssetAction = (props) => {
},
callback: data => {
setLoading(false);
setElements(data?.elements||[]);
onElementsChange && onElementsChange(data?.elements||[]);
setMetadataId(data?.mid||'');
onMetadataChange && onMetadataChange(data?.mid||'');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment