优化:根据板材改颜色自动切换到概念视觉样式

pull/2194/MERGE
ChenX 1 year ago
parent 2d249c1a3e
commit 54f3666ebe

@ -6,9 +6,10 @@ import { begin } from 'xaop';
import { app } from "../../ApplicationServices/Application"; import { app } from "../../ApplicationServices/Application";
import { EBoardKeyList } from "../../Common/BoardKeyList"; import { EBoardKeyList } from "../../Common/BoardKeyList";
import { ColorMaterial } from '../../Common/ColorPalette'; import { ColorMaterial } from '../../Common/ColorPalette';
import { CommandNames } from '../../Common/CommandNames';
import { FixedNotZero } from "../../Common/Utils"; import { FixedNotZero } from "../../Common/Utils";
import { Board } from "../../DatabaseServices/Entity/Board"; import { Board } from "../../DatabaseServices/Entity/Board";
import { Command } from "../../Editor/CommandMachine"; import { Command, commandMachine } from "../../Editor/CommandMachine";
import { PromptSsgetResult, PromptStatus } from '../../Editor/PromptResult'; import { PromptSsgetResult, PromptStatus } from '../../Editor/PromptResult';
import { SelectSetBase } from '../../Editor/SelectBase'; import { SelectSetBase } from '../../Editor/SelectBase';
import { Production } from '../../Production/Product'; import { Production } from '../../Production/Product';
@ -35,17 +36,20 @@ export class ChangeColorByMaterial implements Command
KeyWordList: [{ key: "S", msg: "修改区分板材规则" }], KeyWordList: [{ key: "S", msg: "修改区分板材规则" }],
}); });
if (brRes.Status === PromptStatus.Cancel) if (brRes.Status === PromptStatus.Keyword)
return;
else if (brRes.Status === PromptStatus.Keyword)
{ {
app.Editor.ModalManage.RenderModal(BoardInfoSelectPanel, { store }); app.Editor.ModalManage.RenderModal(BoardInfoSelectPanel, { store });
await app.Editor.ModalManage.Wait(); await app.Editor.ModalManage.Wait();
} }
else if (brRes.Status !== PromptStatus.OK)
return;
else else
break; break;
} }
if (!app.Viewer.isLayout)
commandMachine.ExecCommand(CommandNames.ConceptualTransparent);
let config = new DialogUserConfig(store, BoardModalType.ChangeColorByBoardMaterial); let config = new DialogUserConfig(store, BoardModalType.ChangeColorByBoardMaterial);
await config.LoadAndInitConfig();//载入或者初始化 await config.LoadAndInitConfig();//载入或者初始化

Loading…
Cancel
Save