Commit b23fe29a by zhaochengxiang

字段属性优化

parent 416f7849
...@@ -27,6 +27,7 @@ const AssetAction = (props) => { ...@@ -27,6 +27,7 @@ const AssetAction = (props) => {
const [ fullScreen, setFullScreen ] = useState(false); const [ fullScreen, setFullScreen ] = useState(false);
const [ assetPaths, setAssetPaths ] = useState([]); const [ assetPaths, setAssetPaths ] = useState([]);
const [ resourceRelations, setResourceRelations ] = useState([]); const [ resourceRelations, setResourceRelations ] = useState([]);
const [ businessColumns, setBusinessColumns ] = useState([]);
const { assets, attributes, attributesFoldMap } = assetParams; const { assets, attributes, attributesFoldMap } = assetParams;
const [ assetTagModalVisible, setAssetTagModalVisible ] = useState(false); const [ assetTagModalVisible, setAssetTagModalVisible ] = useState(false);
const [ selectTag, setSelectTag ] = useState({}); const [ selectTag, setSelectTag ] = useState({});
...@@ -40,6 +41,7 @@ const AssetAction = (props) => { ...@@ -40,6 +41,7 @@ const AssetAction = (props) => {
if ((id||'')!=='') { if ((id||'')!=='') {
getAssetPaths(); getAssetPaths();
getResourceRelations(); getResourceRelations();
getColumnsDetail();
if (readOnly) { if (readOnly) {
getUserElements(); getUserElements();
...@@ -80,6 +82,18 @@ const AssetAction = (props) => { ...@@ -80,6 +82,18 @@ const AssetAction = (props) => {
}); });
} }
const getColumnsDetail = () => {
dispatch({
type: 'assetmanage.getColumnDetail',
payload: {
dataAssetId: id,
},
callback: data => {
setBusinessColumns(data);
}
});
}
const getElements = ( cb = null ) => { const getElements = ( cb = null ) => {
setLoading(true); setLoading(true);
dispatch({ dispatch({
...@@ -456,7 +470,7 @@ const AssetAction = (props) => { ...@@ -456,7 +470,7 @@ const AssetAction = (props) => {
</AppContext.Consumer> </AppContext.Consumer>
</Descriptions.Item> </Descriptions.Item>
<Descriptions.Item label={<div className='title-text' style={{ textAlign: 'right', width: 60 }}>字段属性</div>} style={{ paddingBottom: 0 }}> <Descriptions.Item label={<div className='title-text' style={{ textAlign: 'right', width: 60 }}>字段属性</div>} style={{ paddingBottom: 0 }}>
<a onClick={onBusinessColumnDetailClick}>查看详情</a> { businessColumns?.heading?.length >0 && <a onClick={onBusinessColumnDetailClick}>查看详情</a> }
</Descriptions.Item> </Descriptions.Item>
{/* <Descriptions.Item {/* <Descriptions.Item
label={<div className='title-text' style={{ textAlign: 'right', width: 60 }}>关联关系</div>} label={<div className='title-text' style={{ textAlign: 'right', width: 60 }}>关联关系</div>}
......
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