Commit 9cecc1cf by zhaochengxiang

模型审批详情

parent 86d09ee5
......@@ -96,6 +96,7 @@ export class App extends React.Component {
<Route path={'/center-home/menu/asset-manage'} component={AssetManage} exact />
<Route path={'/center-home/menu/asset-browse'} component={AssetBrowse} exact />
<Route path={'/center-home/menu/asset-recycle'} component={AssetRecycle} exact />
<Route path={'/center-home/data-model-action'} component={EditModel} exact />
</Switch>
</Router>
</AppContext.Provider>
......
......@@ -137,7 +137,7 @@ const AssetEdit = (props) => {
<AppContext.Consumer>
{
value => {
value?.onGlobalStateChange((state, prev) => {
value?.onGlobalStateChange&&value?.onGlobalStateChange((state, prev) => {
if (state.message === 'data-govern-show-metadata-list-callback-message') {
form?.setFieldsValue({ '资产项': state.data });
}
......
......@@ -149,10 +149,10 @@ const init = (ctx) => function (container, data) {
label: fittingString(node.text||'', maxTextWidth, globalFontSize),
labelCfg: {
position: 'bottom',
offset: -5,
offset: 5,
style: {
rotate: Math.PI / 2,
textAlign: 'start',
rotate: 0,
textAlign: 'center',
},
},
};
......
......@@ -106,7 +106,7 @@ const EditModel = (props) => {
title = '新增模型';
} else if (action === 'edit') {
title = '模型编辑';
} else if (action === 'detail') {
} else if (action === 'detail' || action === 'flow') {
title = '模型详情';
}
......
......@@ -26,7 +26,7 @@ const ImportAction = (props) => {
if ((action||'')==='') return;
//初始化form状态
if (action==='add'||action==='edit') {
if (action==='add'||action==='edit'||action==='flow') {
form.setFieldsValue({
cnName: '',
name: '',
......@@ -58,7 +58,7 @@ const ImportAction = (props) => {
} else {
getDraft((data.constraints||[]).length>0?data.constraints[0]:{}, {} ,[]);
}
} else if(action === 'edit' || action === 'detail') {
} else if(action === 'edit' || action === 'detail' || action ==='flow') {
getCurrentDataModel();
}
},
......@@ -252,7 +252,7 @@ const ImportAction = (props) => {
dispatch({
type: 'datamodel.validateDataModel',
payload: {
data: action==='detail'?data:{ ...data, name: row.name||'', cnName: row.cnName||'' },
data: (action==='detail'||action==='flow')?data:{ ...data, name: row.name||'', cnName: row.cnName||'' },
},
callback: _data => {
setValidateReports(_data||[]);
......@@ -307,7 +307,7 @@ const ImportAction = (props) => {
const container = (<React.Fragment>
<ImportActionHeader
form={form}
editable={action!=='detail'}
editable={action!=='detail'&&action!=='flow'}
modelerData={modelerData||{}}
constraints={constraints}
templates={templates}
......@@ -324,7 +324,7 @@ const ImportAction = (props) => {
validateReports={validateReports}
supportedDatatypes={supportedDatatypes}
onChange={onTableChange}
editable={action!=='detail'}
editable={action!=='detail'&&action!=='flow'}
terms={terms}
/>
<ImportActionIndex
......@@ -333,7 +333,7 @@ const ImportAction = (props) => {
template={template}
validateReports={validateReports}
onChange={onIndexChange}
editable={action!=='detail'}
editable={action!=='detail'&&action!=='flow'}
terms={terms}
/>
<ImportActionPartition
......@@ -343,7 +343,7 @@ const ImportAction = (props) => {
validateReports={validateReports}
supportedPartitionTypes={supportedPartitionTypes}
onChange={onPartitionChange}
editable={action!=='detail'}
editable={action!=='detail'&&action!=='flow'}
terms={terms}
/>
</React.Fragment>);
......
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