属性UI(プロパティ)にチェックルール設定追加
This commit is contained in:
@@ -11,7 +11,7 @@ export interface FlowEditorState {
|
||||
activeNode: IActionNode | undefined;
|
||||
eventTree: KintoneEventManager;
|
||||
selectedEvent: IKintoneEvent | undefined;
|
||||
expandedScreen: any[];
|
||||
expandedScreen: string[];
|
||||
}
|
||||
const flowCtrl = new FlowCtrl();
|
||||
const eventTree = new KintoneEventManager();
|
||||
@@ -62,6 +62,10 @@ export const useFlowEditorStore = defineStore('flowEditor', {
|
||||
},
|
||||
selectFlow(flow: IActionFlow | undefined) {
|
||||
this.selectedFlow = flow;
|
||||
if(flow!==undefined){
|
||||
const eventId = flow.getRoot()?.name;
|
||||
this.selectedEvent=this.eventTree.findEventById(eventId) as IKintoneEvent;
|
||||
}
|
||||
},
|
||||
setActiveNode(node: IActionNode) {
|
||||
this.activeNode = node;
|
||||
@@ -84,15 +88,23 @@ export const useFlowEditorStore = defineStore('flowEditor', {
|
||||
if (actionFlows === undefined || actionFlows.length === 0) {
|
||||
this.flows = [];
|
||||
this.selectedFlow = undefined;
|
||||
this.expandedScreen =[];
|
||||
return;
|
||||
}
|
||||
this.setFlows(actionFlows);
|
||||
if (actionFlows && actionFlows.length > 0) {
|
||||
this.selectFlow(actionFlows[0]);
|
||||
}
|
||||
const expandNames = actionFlows.map((flow) => flow.getRoot()?.title);
|
||||
const expandEventIds = actionFlows.map((flow) => flow.getRoot()?.name);
|
||||
const expandScreens:string[]=[];
|
||||
expandEventIds.forEach((eventid)=>{
|
||||
const eventNode=this.eventTree.findEventById(eventid||'');
|
||||
if(eventNode){
|
||||
expandScreens.push(eventNode.parentId);
|
||||
}
|
||||
});
|
||||
// const expandName =actionFlows[0].getRoot()?.title;
|
||||
this.expandedScreen = expandNames;
|
||||
this.expandedScreen = expandScreens;
|
||||
},
|
||||
/**
|
||||
* フローをDBに保存及び更新する
|
||||
|
||||
Reference in New Issue
Block a user