Commit 1eb100b9 by zhaochengxiang

bug fix

parent 6147c07f
......@@ -145,9 +145,20 @@ class Model extends React.Component {
});
} else {
selectModelerIds?.forEach(id => {
const index = (tableData||[]).findIndex(item => item.id===id);
let index = (tableData||[]).findIndex(item => item.id === id);
if (index === -1) {
index = (tableData||[]).findIndex(item => item.id?.split('-')[0] === id?.split('-')[0]);
}
if (index !== -1 && !tableData[index].supportJoin) {
canBatchJoin = false
const modelItem = tableData[index]
if (modelItem.state?.id !== '1') {
canStartFlow = false
canDelete = false
}
if (!modelItem.supportJoin) {
canBatchJoin = false
}
}
});
}
......@@ -835,10 +846,10 @@ class Model extends React.Component {
{
currentView === 'branch' && <PermissionButton
defaultPermission={true}
defaultPermission={this.state.canBatchJoin}
tip={this.state.canBatchJoin?((selectModelerIds||[]).length===0?'请先选择已发布的分支模型':''):''}
onClick={this.onBatchMerge}
disabled={(selectModelerIds||[]).length===0||!this.state.canBatchJoin}
disabled={(selectModelerIds||[]).length===0}
>
合并到基线
</PermissionButton>
......
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