Skip to content

Commit 5f7efb2

Browse files
committed
WFE 11.0.0 (autocommit)
1 parent 4ce7086 commit 5f7efb2

File tree

113 files changed

+3009
-1621
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+3009
-1621
lines changed

Designer/Localization/en_default.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,9 @@
314314
"RootProcess": "Root Process",
315315
"TagsLabel": "Tags",
316316
"GeneralTabLabel": "General",
317-
"ProcessIdLabel": "Process Id"
317+
"ProcessIdLabel": "Process Id",
318+
"WorkCalendar": "Work calendar",
319+
"CalendarPlaceholder": "Start typing a name to find a calendar"
318320
},
319321
"DropdownValues": {
320322
"Name": "Name",

Designer/templates/processinfo.html

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,25 @@ <h4>{{ Name }}</h4>
1414
<el-select v-model="Tags" :disabled="readonly" :placeholder="labels.TagsInputPlaceholder" allow-create filterable multiple
1515
style="width: 100%;"></el-select>
1616
</el-form-item>
17+
<el-form-item :label="labels.WorkCalendar">
18+
<el-select
19+
v-model="CalendarName"
20+
filterable
21+
remote
22+
:placeholder="labels.CalendarPlaceholder"
23+
:remote-method="SearchCalendar"
24+
:CalendarLoading="CalendarLoading"
25+
clearable
26+
:class="CalendarExists(CalendarName) ? '' : 'WorkflowDesignerInputError'"
27+
@clear="CalendarClear">
28+
<el-option
29+
v-for="item in ShownCalendars"
30+
:key="item"
31+
:label="item"
32+
:value="item">
33+
</el-option>
34+
</el-select>
35+
</el-form-item>
1736
<el-form-item>
1837
<el-switch v-model="CanBeInlined" :active-text="InlineLabel" :disabled="readonly"></el-switch>
1938
</el-form-item>
@@ -357,10 +376,15 @@ <h4>{{ Name }}</h4>
357376
Name: '',
358377
Id: undefined,
359378
SubprocessInfo: undefined,
379+
CalendarName: '',
380+
LoadedCalendars: [],
381+
ShownCalendars: [],
382+
CalendarLoading: false
360383
});
361384

362385
me.VueConfig.methods.onUpdate = function () {
363386
var data = me.VueConfig.data;
387+
data.CalendarName = me.graph.data.CalendarName;
364388
data.Tags = WorkflowDesignerCommon.clone(me.graph.data.Tags);
365389
data.CanBeInlined = me.graph.data.CanBeInlined;
366390
data.LogEnabled = me.graph.designer.LogEnabled;
@@ -394,6 +418,7 @@ <h4>{{ Name }}</h4>
394418
data.ProcessId = WorkflowDesignerCommon.clone(additionalParams.ProcessId);
395419
data.ProcessHistoryCount = WorkflowDesignerCommon.clone(additionalParams.ProcessHistoryCount);
396420
data.readonly = me.graph.Settings.readonly;
421+
data.LoadedCalendars = me.VueConfig.methods.LoadCalendars();
397422
};
398423

399424
me.VueConfig.methods.getFormatDate = function (stringDate) {
@@ -436,6 +461,7 @@ <h4>{{ Name }}</h4>
436461

437462
me.VueConfig.methods.onSave = function () {
438463
var data = me.graph.data;
464+
data.CalendarName = me.VueConfig.data.CalendarName;
439465
data.Tags = WorkflowDesignerCommon.clone(me.VueConfig.data.Tags);
440466
data.CanBeInlined = me.VueConfig.data.CanBeInlined;
441467
me.graph.setInlinedFlag(data.CanBeInlined);
@@ -501,5 +527,40 @@ <h4>{{ Name }}</h4>
501527
}
502528
}
503529
};
530+
531+
me.VueConfig.methods.CreateFilter = function (queryString) {
532+
return link => link.toLowerCase().indexOf(queryString.toLowerCase()) > -1
533+
}
534+
535+
me.VueConfig.methods.CalendarClear = function () {
536+
me.VueConfig.data.ShownCalendars = [];
537+
}
538+
539+
me.VueConfig.methods.LoadCalendars = function () {
540+
return me.graph.designer.getcalendars();
541+
}
542+
543+
me.VueConfig.methods.SearchCalendar = function (query) {
544+
const data = me.VueConfig.data;
545+
if (query !== '') {
546+
data.CalendarLoading = true;
547+
const createFilter = me.VueConfig.methods.CreateFilter;
548+
const calendars = data.LoadedCalendars;
549+
data.ShownCalendars = calendars.filter(createFilter(query));
550+
data.CalendarLoading = false;
551+
} else {
552+
data.ShownCalendars = data.LoadedCalendars;
553+
}
554+
}
555+
556+
me.VueConfig.methods.CalendarExists = function (calendarName) {
557+
if (calendarName !== "" && calendarName !== null) {
558+
const data = me.VueConfig.data;
559+
const calendar = data.LoadedCalendars.find(item => item === calendarName);
560+
return !!calendar
561+
}
562+
return true;
563+
}
564+
504565
}
505566
</script>

0 commit comments

Comments
 (0)