Commit 0a90276c by zhaochengxiang

bug fix

parent ea9f2f9b
......@@ -193,10 +193,12 @@ const FC = (props) => {
},
callback: data => {
let tip = '您确定要删除该规则吗?'
if ((data??[]).length < 4) {
tip = `该规则在${(data??[]).map(item=>item.name).join('、')}中被使用,删除后,引用的规范将同步删除该规则,确定删除吗?`
} else {
tip = `该规则在${(data??[]).slice(0, 3).map(item=>item.name).join('、')}${(data??[]).length}个规范中被使用,删除后,引用的规范将同步删除该规则,确定删除吗?`
if ((data??[]).length > 0) {
if ((data??[]).length < 4) {
tip = `该规则在${(data??[]).map(item=>item.name).join('、')}中被使用,删除后,引用的规范将同步删除该规则,确定删除吗?`
} else {
tip = `该规则在${(data??[]).slice(0, 3).map(item=>item.name).join('、')}${(data??[]).length}个规范中被使用,删除后,引用的规范将同步删除该规则,确定删除吗?`
}
}
modal.confirm({
......
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