@voplus/morpho-workspace 6.0.67 → 6.0.69
Sign up to get free protection for your applications and to get access to all the features.
- package/es/controls/filters/AssigneeViewFilter/index.js +3 -4
- package/es/controls/filters/AssigneeViewFilter/index.js.map +1 -1
- package/es/controls/filters/AssigneeViewFilter/state.d.ts +2 -2
- package/es/controls/filters/AssigneeViewFilter/state.js +3 -1
- package/es/controls/filters/AssigneeViewFilter/state.js.map +1 -1
- package/es/controls/filters/DueDateFilter/state.d.ts +2 -2
- package/es/controls/filters/DueDateFilter/state.js +3 -1
- package/es/controls/filters/DueDateFilter/state.js.map +1 -1
- package/es/controls/filters/EventsFilter/state.d.ts +2 -2
- package/es/controls/filters/EventsFilter/state.js +3 -1
- package/es/controls/filters/EventsFilter/state.js.map +1 -1
- package/es/controls/filters/MemberTaskDueDateFilter/state.d.ts +2 -2
- package/es/controls/filters/MemberTaskDueDateFilter/state.js +3 -1
- package/es/controls/filters/MemberTaskDueDateFilter/state.js.map +1 -1
- package/es/controls/filters/StartDateFilter/state.d.ts +2 -2
- package/es/controls/filters/StartDateFilter/state.js +3 -1
- package/es/controls/filters/StartDateFilter/state.js.map +1 -1
- package/es/controls/filters/TaskFilter/state.d.ts +2 -2
- package/es/controls/filters/TaskFilter/state.js +3 -1
- package/es/controls/filters/TaskFilter/state.js.map +1 -1
- package/es/controls/filters/TaskStatusFilter/state.d.ts +2 -2
- package/es/controls/filters/TaskStatusFilter/state.js +3 -1
- package/es/controls/filters/TaskStatusFilter/state.js.map +1 -1
- package/es/controls/filters/WorkStatusFilter/state.d.ts +2 -2
- package/es/controls/filters/WorkStatusFilter/state.js +3 -1
- package/es/controls/filters/WorkStatusFilter/state.js.map +1 -1
- package/es/controls/filters/WorkTypeStatusFilter/state.d.ts +2 -2
- package/es/controls/filters/WorkTypeStatusFilter/state.js +3 -1
- package/es/controls/filters/WorkTypeStatusFilter/state.js.map +1 -1
- package/es/controls/filters/WorkTypesFilter/state.d.ts +4 -2
- package/es/controls/filters/WorkTypesFilter/state.js +18 -4
- package/es/controls/filters/WorkTypesFilter/state.js.map +1 -1
- package/es/data/notification/NotificationStore.d.ts +14 -8
- package/es/data/notification/NotificationStore.js +23 -5
- package/es/data/notification/NotificationStore.js.map +1 -1
- package/es/data/notification/hooks.d.ts +3 -3
- package/es/data/notification/hooks.js +3 -3
- package/es/data/notification/hooks.js.map +1 -1
- package/es/data/notification/interfaces.d.ts +11 -0
- package/es/data/notification/notification-events/useAutoUpdateListData.d.ts +2 -2
- package/es/data/notification/notification-events/useAutoUpdateListData.js.map +1 -1
- package/es/data/notification/notification-events/useOnDeleteNotification.d.ts +2 -2
- package/es/data/notification/notification-events/useOnDeleteNotification.js.map +1 -1
- package/es/data/notification/notification-events/useOnNewNotification.d.ts +2 -2
- package/es/data/notification/notification-events/useOnNewNotification.js.map +1 -1
- package/es/data/notification/types.d.ts +6 -1
- package/es/modules/calendar/pages/CalendarMonth/index.js +5 -4
- package/es/modules/calendar/pages/CalendarMonth/index.js.map +1 -1
- package/es/modules/meeting/components/NewMeetingForm/index.js.map +1 -1
- package/es/modules/menus/components/Access/index.js +5 -4
- package/es/modules/menus/components/Access/index.js.map +1 -1
- package/es/modules/menus/components/Account/index.js +5 -4
- package/es/modules/menus/components/Account/index.js.map +1 -1
- package/es/modules/menus/components/Status/index.js +5 -4
- package/es/modules/menus/components/Status/index.js.map +1 -1
- package/es/modules/menus/pages/ListOptions/Company/index.js +7 -5
- package/es/modules/menus/pages/ListOptions/Company/index.js.map +1 -1
- package/es/modules/notification/components/NotificationHeader/index.js +3 -3
- package/es/modules/notification/components/NotificationHeader/index.js.map +1 -1
- package/es/modules/notification/components/NotificationItem/index.js +5 -3
- package/es/modules/notification/components/NotificationItem/index.js.map +1 -1
- package/es/modules/notification/components/NotificationList2/index.js +7 -2
- package/es/modules/notification/components/NotificationList2/index.js.map +1 -1
- package/es/modules/notification/components/NotificationProperties/index.d.ts +1 -1
- package/es/modules/notification/components/NotificationProperties/index.js +12 -5
- package/es/modules/notification/components/NotificationProperties/index.js.map +1 -1
- package/es/modules/notification/components/NotificationRecipients/index.js +2 -2
- package/es/modules/notification/components/NotificationRecipients/index.js.map +1 -1
- package/es/modules/notification/components/NotificationTabs/index.js +9 -6
- package/es/modules/notification/components/NotificationTabs/index.js.map +1 -1
- package/es/modules/notification/controls/NotificationMenu/index.js +6 -4
- package/es/modules/notification/controls/NotificationMenu/index.js.map +1 -1
- package/es/modules/notification/controls/NotificationMenu/item/Send.d.ts +9 -0
- package/es/modules/notification/controls/NotificationMenu/item/Send.js +33 -0
- package/es/modules/notification/controls/NotificationMenu/item/Send.js.map +1 -0
- package/es/modules/notification/controls/NotificationMenu/item/index.d.ts +1 -0
- package/es/modules/notification/controls/NotificationMenu/item/index.js +2 -0
- package/es/modules/notification/controls/NotificationMenu/item/index.js.map +1 -0
- package/es/modules/notification/controls/NotificationStatusLabel/index.d.ts +6 -0
- package/es/modules/notification/controls/NotificationStatusLabel/index.js +7 -0
- package/es/modules/notification/controls/NotificationStatusLabel/index.js.map +1 -0
- package/es/modules/notification/controls/NotificationStatusLabel/index.less +14 -0
- package/es/modules/notification/pages/NotificationDefaultView/index.js +1 -1
- package/es/modules/notification/pages/NotificationDefaultView/index.js.map +1 -1
- package/es/modules/tasks/reports/TaskSummaryCard/index.js +1 -1
- package/es/modules/tasks/reports/TaskSummaryCard/index.js.map +1 -1
- package/es/modules/user/pages/Positions/index.js +6 -5
- package/es/modules/user/pages/Positions/index.js.map +1 -1
- package/es/modules/work/components/RejectWorkDialog/index.js +5 -4
- package/es/modules/work/components/RejectWorkDialog/index.js.map +1 -1
- package/es/modules/work/components/RejectWorkDialog/index.less +5 -0
- package/es/modules/work/components/RelatedWorkList/RelatedWorkList.js +1 -1
- package/es/modules/work/components/RelatedWorkList/RelatedWorkList.js.map +1 -1
- package/es/modules/work/components/WorkList/index.js +3 -1
- package/es/modules/work/components/WorkList/index.js.map +1 -1
- package/es/modules/work/controls/SeveritySelect/index.js +10 -10
- package/es/modules/work/controls/SeveritySelect/index.js.map +1 -1
- package/es/modules/work/controls/WorkErrorSelect/index.js +3 -2
- package/es/modules/work/controls/WorkErrorSelect/index.js.map +1 -1
- package/es/modules/work/work-schedule/controls/WorkScheduleFilter/state.d.ts +2 -2
- package/es/modules/work/work-schedule/controls/WorkScheduleFilter/state.js +3 -1
- package/es/modules/work/work-schedule/controls/WorkScheduleFilter/state.js.map +1 -1
- package/es/modules/work/work-type/components/RepeatTab/index.js +5 -4
- package/es/modules/work/work-type/components/RepeatTab/index.js.map +1 -1
- package/es/modules/work/work-type/components/WorkTypeSelect/index.js +11 -6
- package/es/modules/work/work-type/components/WorkTypeSelect/index.js.map +1 -1
- package/es/modules/work/work-type/controls/SelectedFilterLabel/index.d.ts +4 -0
- package/es/modules/work/work-type/controls/SelectedFilterLabel/index.js +23 -0
- package/es/modules/work/work-type/controls/SelectedFilterLabel/index.js.map +1 -0
- package/es/modules/work/work-type/controls/SelectedFilterLabel/index.less +31 -0
- package/es/modules/work/work-type/controls/WorktypeCompleteWorksChart/index.js +1 -1
- package/es/modules/work/work-type/controls/WorktypeCompleteWorksChart/index.js.map +1 -1
- package/es/modules/workspace/controls/WorkspaceCompletedWorksChart/index.js +1 -1
- package/es/modules/workspace/controls/WorkspaceCompletedWorksChart/index.js.map +1 -1
- package/es/obsolete/member/components/MemberSelect.js +3 -2
- package/es/obsolete/member/components/MemberSelect.js.map +1 -1
- package/package.json +1 -1
- package/es/components/AssignPeople/index.d.ts +0 -3
- package/es/components/AssignPeople/index.js +0 -24
- package/es/components/AssignPeople/index.js.map +0 -1
- package/es/modules/work/components/WorkList/state.d.ts +0 -10
- package/es/modules/work/components/WorkList/state.js +0 -51
- package/es/modules/work/components/WorkList/state.js.map +0 -1
@@ -21,15 +21,14 @@ const AssigneeView = () => {
|
|
21
21
|
});
|
22
22
|
return observe(() => (React.createElement("div", { className: "assignee-view" },
|
23
23
|
React.createElement("div", { className: "menu-item-title" }, "AssigneeView"),
|
24
|
-
React.createElement(Select, { loading: list.loading, value: Array.from(state.members.keys()), showSearch: true, placeholder: "Input or select contact.",
|
24
|
+
React.createElement(Select, { loading: list.loading, value: Array.from(state.members.keys()), showSearch: true, placeholder: "Input or select contact.", optionFilterProp: "label", onSelect: onSelectMember, style: { width: 160 }, options: list.data.map((i) => {
|
25
|
+
return { value: i.id, label: i.name };
|
26
|
+
}) }),
|
25
27
|
state.memberList.map((item, index) => (React.createElement("div", { key: item.id, className: classnames("assignee-view-item", {
|
26
28
|
bold: state.members.has(item.id),
|
27
29
|
}) },
|
28
30
|
React.createElement(AvatarItem, { id: item.id, index: index, inline: true }),
|
29
31
|
React.createElement(CloseOutlined, { onClick: () => onCancel(item.id) })))))));
|
30
|
-
function filterItems(input, option) {
|
31
|
-
return option.title.toLowerCase().includes(input.toLowerCase());
|
32
|
-
}
|
33
32
|
/** cancel select member */
|
34
33
|
function onCancel(id) {
|
35
34
|
state.memberList = state.memberList.filter((m) => m.id !== id);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/controls/filters/AssigneeViewFilter/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAS,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAC9D,OAAO,EAAE,sBAAsB,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AAE5F,OAAO,UAAU,MAAM,wDAAwD,CAAC;AAChF,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAC9B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,UAAU,MAAM,YAAY,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAE5D,MAAM,YAAY,GAAG,GAAG,EAA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CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAU,CAAC;QACzD,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;YACpB,CAAC,CAAC,CAAC,KAAK,CAAC,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;YAC3D,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC/B,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IAChF,CAAC;AACF,CAAC,CAAC;AACF,eAAe,YAAY,CAAC"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data/DefaultFilterState";
|
3
3
|
import { IUnit } from "@voplus/morpho-org";
|
4
|
-
export declare class State
|
4
|
+
export declare class State extends DefaultFilterState {
|
5
5
|
/** Members of filter */
|
6
6
|
memberList: IUnit[];
|
7
7
|
/** Ids of member of filter */
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data/DefaultFilterState";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor() {
|
6
|
+
super();
|
5
7
|
/** Members of filter */
|
6
8
|
Object.defineProperty(this, "memberList", {
|
7
9
|
enumerable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/AssigneeViewFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/AssigneeViewFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,OAAO,EAAE,kBAAkB,EAAE,MAAM,8CAA8C,CAAC;AAGlF,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAM5C;QACC,KAAK,EAAE,CAAC;QANT,wBAAwB;QACL;;;;mBAAsB,EAAE;WAAC;QAC5C,8BAA8B;QACX;;;;mBAAgC,IAAI,GAAG,EAAE;WAAC;QAI5D,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;IAED,6FAA6F;IAC7F,IAAW,OAAO;QACjB,0CAA0C;QAC1C,OAAO;YACN;gBACC,CAAC,EAAE,SAAS;gBACZ,CAAC,EAAE,UAAU;gBACb,EAAE,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;gBACnD,CAAC,EAAE,KAAK;aACQ;SACjB,CAAC;IACH,CAAC;IAEM,KAAK;QACX,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;QACrB,IAAI,CAAC,UAAU,GAAG,EAAE,CAAC;IACtB,CAAC;CACD;AA1BmB;IAAlB,UAAU;yCAAiC;AAEzB;IAAlB,UAAU;sCAAkD"}
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
3
|
import { RangeValue } from "rc-picker/es/interface";
|
4
4
|
import dayjs from "dayjs";
|
5
|
-
export declare class State
|
5
|
+
export declare class State extends DefaultFilterState {
|
6
6
|
dueDate: RangeValue<dayjs.Dayjs>;
|
7
7
|
constructor();
|
8
8
|
/** 视乎State内容,返回正确的FilterOption[]. 在Filter时,Context 会使用此属性replace Context内FilterOption的资料。 */
|
@@ -1,8 +1,10 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { makeObservable, observable } from "mobx";
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
4
|
import dayjs from "dayjs";
|
4
|
-
export class State {
|
5
|
+
export class State extends DefaultFilterState {
|
5
6
|
constructor() {
|
7
|
+
super();
|
6
8
|
Object.defineProperty(this, "dueDate", {
|
7
9
|
enumerable: true,
|
8
10
|
configurable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/DueDateFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/DueDateFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAE/D,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAG5C;QACC,KAAK,EAAE,CAAC;QAHU;;;;;WAAiC;QAInD,cAAc,CAAC,IAAI,CAAC,CAAC;QACrB,IAAI,CAAC,KAAK,EAAE,CAAC;IACd,CAAC;IAED,6FAA6F;IAC7F,IAAW,OAAO;;QACjB,IAAI,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAG,CAAC,CAAC,MAAK,IAAI,IAAI,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAG,CAAC,CAAC,MAAK,IAAI;YAAE,OAAO,EAAE,CAAC;QACxE,MAAM,KAAK,GAAG,MAAA,MAAA,IAAI,CAAC,OAAO,0CAAG,CAAC,CAAC,mCAAI,KAAK,CAAC,YAAY,CAAC,CAAC;QACvD,MAAM,GAAG,GAAG,MAAA,MAAA,IAAI,CAAC,OAAO,0CAAG,CAAC,CAAC,mCAAI,KAAK,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QACvD,OAAO;YACN;gBACC,CAAC,EAAE,SAAS;gBACZ,CAAC,EAAE,SAAS;gBACZ,CAAC,EAAE,KAAK;gBACR,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,qBAAqB,CAAC;gBACvD,EAAE,EAAE,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,qBAAqB,CAAC;aACnC;SACjB,CAAC;IACH,CAAC;IAEM,KAAK;QACX,IAAI,CAAC,OAAO,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IAC7B,CAAC;CACD;AA3BmB;IAAlB,UAAU;sCAAyC"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
3
|
-
export declare class State
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
|
+
export declare class State extends DefaultFilterState {
|
4
4
|
/** events of filter */
|
5
5
|
events: Map<string, boolean>;
|
6
6
|
constructor();
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor() {
|
6
|
+
super();
|
5
7
|
/** events of filter */
|
6
8
|
Object.defineProperty(this, "events", {
|
7
9
|
enumerable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/EventsFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EA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I,EAAE,CAAC,CAAC;gBAClD,CAAC,EAAE,KAAK;aACQ;SACjB,CAAC;IACH,CAAC;IACM,KAAK;QACX,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;IACrB,CAAC;CACD;AAjCmB;IAAlB,UAAU;qCAAiD;AASrD;IADN,MAAM;2CAGN"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
3
|
import { RangeValue } from "rc-picker/es/interface";
|
4
4
|
import dayjs from "dayjs";
|
5
5
|
export declare const dateMenus: ({
|
@@ -26,7 +26,7 @@ export declare const dateMenus: ({
|
|
26
26
|
style?: undefined;
|
27
27
|
badge?: undefined;
|
28
28
|
})[];
|
29
|
-
export declare class State
|
29
|
+
export declare class State extends DefaultFilterState {
|
30
30
|
dueDate: RangeValue<dayjs.Dayjs>;
|
31
31
|
unscheduled: boolean;
|
32
32
|
constructor();
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { makeObservable, observable } from "mobx";
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
4
|
import dayjs from "dayjs";
|
4
5
|
export const dateMenus = [
|
5
6
|
{
|
@@ -30,8 +31,9 @@ export const dateMenus = [
|
|
30
31
|
counts: 5,
|
31
32
|
},
|
32
33
|
];
|
33
|
-
export class State {
|
34
|
+
export class State extends DefaultFilterState {
|
34
35
|
constructor() {
|
36
|
+
super();
|
35
37
|
Object.defineProperty(this, "dueDate", {
|
36
38
|
enumerable: true,
|
37
39
|
configurable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/MemberTaskDueDateFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":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E,IAAI,CAAC,CAAC;IAC7B,CAAC;CACD;AAhCmB;IAAlB,UAAU;sCAAyC;AAEjC;IAAlB,UAAU;0CAAqC"}
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
3
|
import { RangeValue } from "rc-picker/es/interface";
|
4
4
|
import dayjs from "dayjs";
|
5
|
-
export declare class State
|
5
|
+
export declare class State extends DefaultFilterState {
|
6
6
|
stateDate: RangeValue<dayjs.Dayjs>;
|
7
7
|
constructor();
|
8
8
|
/** 视乎State内容,返回正确的FilterOption[]. 在Filter时,Context 会使用此属性replace Context内FilterOption的资料。 */
|
@@ -1,8 +1,10 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { makeObservable, observable } from "mobx";
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
4
|
import dayjs from "dayjs";
|
4
|
-
export class State {
|
5
|
+
export class State extends DefaultFilterState {
|
5
6
|
constructor() {
|
7
|
+
super();
|
6
8
|
Object.defineProperty(this, "stateDate", {
|
7
9
|
enumerable: true,
|
8
10
|
configurable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/StartDateFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/StartDateFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAE/D,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAG5C;QACC,KAAK,EAAE,CAAC;QAHU;;;;;WAAmC;QAIrD,cAAc,CAAC,IAAI,CAAC,CAAC;QACrB,IAAI,CAAC,KAAK,EAAE,CAAC;IACd,CAAC;IAED,6FAA6F;IAC7F,IAAW,OAAO;;QACjB,IAAI,CAAA,MAAA,IAAI,CAAC,SAAS,0CAAG,CAAC,CAAC,MAAK,IAAI,IAAI,CAAA,MAAA,IAAI,CAAC,SAAS,0CAAG,CAAC,CAAC,MAAK,IAAI;YAAE,OAAO,EAAE,CAAC;QAC5E,MAAM,KAAK,GAAG,MAAA,MAAA,IAAI,CAAC,SAAS,0CAAG,CAAC,CAAC,mCAAI,KAAK,CAAC,YAAY,CAAC,CAAC;QACzD,MAAM,GAAG,GAAG,MAAA,MAAA,IAAI,CAAC,SAAS,0CAAG,CAAC,CAAC,mCAAI,KAAK,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QACzD,OAAO;YACN;gBACC,CAAC,EAAE,WAAW;gBACd,CAAC,EAAE,SAAS;gBACZ,CAAC,EAAE,KAAK;gBACR,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,qBAAqB,CAAC;gBACvD,EAAE,EAAE,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,qBAAqB,CAAC;aACnC;SACjB,CAAC;IACH,CAAC;IAEM,KAAK;QACX,IAAI,CAAC,SAAS,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IAC/B,CAAC;CACD;AA3BmB;IAAlB,UAAU;wCAA2C"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
3
|
-
export declare class State
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
|
+
export declare class State extends DefaultFilterState {
|
4
4
|
private id;
|
5
5
|
members: Map<string, boolean>;
|
6
6
|
constructor(id: string);
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor(id) {
|
6
|
+
super();
|
5
7
|
Object.defineProperty(this, "id", {
|
6
8
|
enumerable: true,
|
7
9
|
configurable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/TaskFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/TaskFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAG1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAE/D,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAG5C,YAAoB,EAAU;QAC7B,KAAK,EAAE,CAAC;QADG;;;;mBAAQ,EAAE;WAAQ;QAFX;;;;mBAAgC,IAAI,GAAG,EAAE;WAAC;QAI5D,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;IAED,qBAAqB;IAEd,eAAe,CAAC,KAAa;QACnC,wFAAwF;QACxF,IAAI,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;YAC7B,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QAC5B,CAAC;aAAM,CAAC;YACP,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;YACrB,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;QAC/B,CAAC;IACF,CAAC;IAED,IAAW,KAAK;QACf,OAAO;YACN,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;YACvE,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;SACxE,CAAC;IACH,CAAC;IACD,IAAW,OAAO;QACjB,OAAO;YACN;gBACC,CAAC,EAAE,SAAS;gBACZ,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,UAAU;gBACnD,CAAC,EAAE,KAAK;gBACR,EAAE,EAAE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;aACvE;SACjB,CAAC;IACH,CAAC;IACM,KAAK;QACX,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;IACtB,CAAC;CACD;AAtCmB;IAAlB,UAAU;sCAAkD;AAStD;IADN,MAAM;4CASN"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
3
|
-
export declare class State
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
|
+
export declare class State extends DefaultFilterState {
|
4
4
|
/** Status of filter */
|
5
5
|
status: Map<string, boolean>;
|
6
6
|
constructor();
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor() {
|
6
|
+
super();
|
5
7
|
/** Status of filter */
|
6
8
|
Object.defineProperty(this, "status", {
|
7
9
|
enumerable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/TaskStatusFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/TaskStatusFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAG1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAE/D,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAI5C;QACC,KAAK,EAAE,CAAC;QAJT,uBAAuB;QACJ;;;;mBAA+B,IAAI,GAAG,EAAE;WAAC;QAI3D,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;IAED,oBAAoB;IAEb,cAAc,CAAC,KAAa;QAClC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;IACnF,CAAC;IAED,IAAW,KAAK;QACf,OAAO;YACN,iFAAiF;YACjF,EAAE,IAAI,EAAE,aAAa,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;YAC3E,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;YACtE,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;YAC9D,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;SAClE,CAAC;IACH,CAAC;IACD,IAAW,OAAO;QACjB,yCAAyC;QACzC,OAAO;YACN;gBACC,CAAC,EAAE,YAAY;gBACf,CAAC,EAAE,UAAU;gBACb,EAAE,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC;gBAClD,CAAC,EAAE,KAAK;aACQ;SACjB,CAAC;IACH,CAAC;IACM,KAAK;QACX,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;IACrB,CAAC;CACD;AApCmB;IAAlB,UAAU;qCAAiD;AASrD;IADN,MAAM;2CAGN"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
3
|
-
export declare class State
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
|
+
export declare class State extends DefaultFilterState {
|
4
4
|
/** Status of filter */
|
5
5
|
status: Map<string, boolean>;
|
6
6
|
constructor();
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor() {
|
6
|
+
super();
|
5
7
|
/** Status of filter */
|
6
8
|
Object.defineProperty(this, "status", {
|
7
9
|
enumerable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/WorkStatusFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"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MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;SAC9D,CAAC;IACH,CAAC;IACD,IAAW,OAAO;QACjB,OAAO;YACN;gBACC,CAAC,EAAE,YAAY;gBACf,CAAC,EAAE,UAAU;gBACb,EAAE,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC;gBAClD,CAAC,EAAE,KAAK;aACQ;SACjB,CAAC;IACH,CAAC;IACM,KAAK;QACX,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;IACrB,CAAC;CACD;AApCmB;IAAlB,UAAU;qCAAiD;AASrD;IADN,MAAM;2CAGN"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
3
|
/** DocumentStatusFilter的 State, 实现 IFilterState 接口 */
|
4
|
-
export declare class State
|
4
|
+
export declare class State extends DefaultFilterState {
|
5
5
|
/** Status of document of filter */
|
6
6
|
status: Map<string, boolean>;
|
7
7
|
constructor();
|
@@ -1,8 +1,10 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
3
4
|
/** DocumentStatusFilter的 State, 实现 IFilterState 接口 */
|
4
|
-
export class State {
|
5
|
+
export class State extends DefaultFilterState {
|
5
6
|
constructor() {
|
7
|
+
super();
|
6
8
|
/** Status of document of filter */
|
7
9
|
Object.defineProperty(this, "status", {
|
8
10
|
enumerable: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/WorkTypeStatusFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAA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,KAAK;QACX,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;IACrB,CAAC;CACD;AAlCmB;IAAlB,UAAU;qCAAiD;AASrD;IADN,MAAM;yCAGN"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { FilterOption } from "@voplus/morpho-data";
|
2
|
-
import {
|
2
|
+
import { DefaultFilterState, ISelectedLabel } from "@voplus/morpho-ui/es/data";
|
3
3
|
import { IWorkType } from "../../../data/worktype";
|
4
|
-
export declare class State
|
4
|
+
export declare class State extends DefaultFilterState {
|
5
5
|
private initial;
|
6
6
|
/** types of filter */
|
7
7
|
types: Map<string, boolean>;
|
@@ -16,5 +16,7 @@ export declare class State implements IFilterState {
|
|
16
16
|
onChangeTypes(value: string): void;
|
17
17
|
get menus(): any[];
|
18
18
|
get filters(): FilterOption[];
|
19
|
+
getSelectedLabels(): ISelectedLabel[];
|
20
|
+
removeSelected(value: string): ISelectedLabel[];
|
19
21
|
reset(): void;
|
20
22
|
}
|
@@ -1,7 +1,9 @@
|
|
1
1
|
import { __decorate } from "tslib";
|
2
2
|
import { action, makeObservable, observable } from "mobx";
|
3
|
-
|
3
|
+
import { DefaultFilterState } from "@voplus/morpho-ui/es/data";
|
4
|
+
export class State extends DefaultFilterState {
|
4
5
|
constructor(initial) {
|
6
|
+
super();
|
5
7
|
Object.defineProperty(this, "initial", {
|
6
8
|
enumerable: true,
|
7
9
|
configurable: true,
|
@@ -58,13 +60,25 @@ export class State {
|
|
58
60
|
return [
|
59
61
|
{
|
60
62
|
c: "WorkType",
|
61
|
-
o: "
|
62
|
-
v1: Array.from(this.types.keys())
|
63
|
+
o: "contains",
|
64
|
+
v1: JSON.stringify(Array.from(this.types.keys())),
|
63
65
|
l: "And",
|
64
|
-
labels: this.selectedLabels,
|
65
66
|
},
|
66
67
|
];
|
67
68
|
}
|
69
|
+
getSelectedLabels() {
|
70
|
+
return [
|
71
|
+
{
|
72
|
+
state: this,
|
73
|
+
key: "WorkTypes",
|
74
|
+
label: this.selectedLabels,
|
75
|
+
},
|
76
|
+
];
|
77
|
+
}
|
78
|
+
removeSelected(value) {
|
79
|
+
this.onChangeTypes(value);
|
80
|
+
return this.getSelectedLabels();
|
81
|
+
}
|
68
82
|
reset() {
|
69
83
|
this.types.clear();
|
70
84
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/WorkTypesFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/controls/filters/WorkTypesFilter/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAE1D,OAAO,EAAE,kBAAkB,EAAkB,MAAM,2BAA2B,CAAC;AAG/E,MAAM,OAAO,KAAM,SAAQ,kBAAkB;IAM5C,YAAoB,OAAoB;QACvC,KAAK,EAAE,CAAC;QADG;;;;mBAAQ,OAAO;WAAa;QALxC,sBAAsB;QACH;;;;mBAA8B,IAAI,GAAG,EAAE;WAAC;QACxC;;;;;WAA+C;QAC/C;;;;;WAA0B;QAI5C,cAAc,CAAC,IAAI,CAAC,CAAC;QAErB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,OAAO,CAAC;IAClC,CAAC;IAGM,cAAc,CAAC,KAAc;QACnC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,OAAO,CAAC;QAEjC,IAAI,KAAK,EAAE,CAAC;YACX,uBAAuB;YACvB,MAAM,KAAK,GAAG,IAAI,MAAM,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;YACrC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,IAAK,CAAC,C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AI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;gBACjD,CAAC,EAAE,KAAK;aACQ;SACjB,CAAC;IACH,CAAC;IAEM,iBAAiB;QACvB,OAAO;YACN;gBACC,KAAK,EAAE,IAAI;gBACX,GAAG,EAAE,WAAW;gBAChB,KAAK,EAAE,IAAI,CAAC,cAAc;aAC1B;SACD,CAAC;IACH,CAAC;IAEM,cAAc,CAAC,KAAa;QAClC,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAE1B,OAAO,IAAI,CAAC,iBAAiB,EAAE,CAAC;IACjC,CAAC;IAEM,KAAK;QACX,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC;IACpB,CAAC;CACD;AA1EmB;IAAlB,UAAU;oCAAgD;AACxC;IAAlB,UAAU;6CAAuD;AAC/C;IAAlB,UAAU;2CAAkC;AAUtC;IADN,MAAM;2CAWN;AAIM;IADN,MAAM;0CASN"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ApiEndPoint } from "@voplus/api";
|
2
|
-
import { CountedMap, Store } from "@voplus/morpho-data";
|
3
|
-
import { INotification, LoadNotificationOptions, NotificationEditOptions, CreateNotificationOptions, DeleteNotificationOptions } from ".";
|
2
|
+
import { CountedMap, Store, StoreActionOptions } from "@voplus/morpho-data";
|
3
|
+
import { INotification, INewNotification, LoadNotificationOptions, LoadNewNotificationOptions, NotificationEditOptions, CreateNotificationOptions, DeleteNotificationOptions } from ".";
|
4
4
|
import { LoadDocumentListOptions } from "@voplus/morpho-document-core";
|
5
5
|
/** Notificaiton store supply backend functions. */
|
6
6
|
export declare class NotificationStore extends Store {
|
@@ -12,13 +12,15 @@ export declare class NotificationStore extends Store {
|
|
12
12
|
private readonly _deleted;
|
13
13
|
constructor(endpoint: ApiEndPoint);
|
14
14
|
/** Event fires when a new notification has been created. */
|
15
|
-
get NotificationCreatedEvent(): import("strongly-typed-events").IEvent<NotificationStore,
|
15
|
+
get NotificationCreatedEvent(): import("strongly-typed-events").IEvent<NotificationStore, INewNotification>;
|
16
16
|
/** Event fires when a delete contact has been deleted. */
|
17
|
-
get NotificationDeletedEvent(): import("strongly-typed-events").IEvent<NotificationStore,
|
17
|
+
get NotificationDeletedEvent(): import("strongly-typed-events").IEvent<NotificationStore, INewNotification>;
|
18
18
|
/** All currently used notificaiton. */
|
19
19
|
readonly items: CountedMap<string, INotification>;
|
20
|
+
/** All currently used notificaiton. */
|
21
|
+
readonly nItems: CountedMap<string, INewNotification>;
|
20
22
|
/** Create a new contact base on type. */
|
21
|
-
create(options: CreateNotificationOptions): Promise<
|
23
|
+
create(options: CreateNotificationOptions): Promise<INewNotification>;
|
22
24
|
/** Load a notificaiton from server.
|
23
25
|
* @param {string} id - id of the notificaiton.
|
24
26
|
* @param {LoadNotificationOptions} options - Optional load options.
|
@@ -30,15 +32,19 @@ export declare class NotificationStore extends Store {
|
|
30
32
|
loadList(options?: LoadDocumentListOptions): Promise<INotification[]>;
|
31
33
|
/** Load a notificaiton from server.
|
32
34
|
* @param {string} id - id of the notificaiton.
|
33
|
-
* @param {
|
35
|
+
* @param {LoadNewNotificationOptions} options - Optional load options.
|
34
36
|
*/
|
35
|
-
newLoad(id: string, options?:
|
37
|
+
newLoad(id: string, options?: LoadNewNotificationOptions): Promise<INewNotification>;
|
36
38
|
/** Load a list of documents from server.
|
37
39
|
* @param {LoadDocumentListOptions}
|
38
40
|
*/
|
39
|
-
newLoadList(options?: LoadDocumentListOptions): Promise<
|
41
|
+
newLoadList(options?: LoadDocumentListOptions): Promise<INewNotification[]>;
|
40
42
|
/** Edit an existing item on server. */
|
41
43
|
edit(id: string, options: NotificationEditOptions): Promise<any>;
|
44
|
+
/** send work.
|
45
|
+
* @param {string} id - id of the work.
|
46
|
+
*/
|
47
|
+
send(id: string, options: StoreActionOptions): Promise<any>;
|
42
48
|
delete(ids: string[], options?: DeleteNotificationOptions): Promise<any>;
|
43
49
|
}
|
44
50
|
/** React hook to retrieve NotificaitonStore */
|
@@ -41,6 +41,13 @@ export class NotificationStore extends Store {
|
|
41
41
|
writable: true,
|
42
42
|
value: new CountedMap((key) => ({ id: key, loaded: false }), observable.map([], { deep: true }))
|
43
43
|
});
|
44
|
+
/** All currently used notificaiton. */
|
45
|
+
Object.defineProperty(this, "nItems", {
|
46
|
+
enumerable: true,
|
47
|
+
configurable: true,
|
48
|
+
writable: true,
|
49
|
+
value: new CountedMap((key) => ({ id: key, loaded: false }), observable.map([], { deep: true }))
|
50
|
+
});
|
44
51
|
}
|
45
52
|
/** Event fires when a new notification has been created. */
|
46
53
|
get NotificationCreatedEvent() {
|
@@ -89,7 +96,7 @@ export class NotificationStore extends Store {
|
|
89
96
|
}
|
90
97
|
/** Load a notificaiton from server.
|
91
98
|
* @param {string} id - id of the notificaiton.
|
92
|
-
* @param {
|
99
|
+
* @param {LoadNewNotificationOptions} options - Optional load options.
|
93
100
|
*/
|
94
101
|
async newLoad(id, options) {
|
95
102
|
options = options !== null && options !== void 0 ? options : {};
|
@@ -117,18 +124,29 @@ export class NotificationStore extends Store {
|
|
117
124
|
/** Edit an existing item on server. */
|
118
125
|
async edit(id, options) {
|
119
126
|
return this.action(async () => {
|
120
|
-
const r = await this.endpoint.post(`/api/
|
127
|
+
const r = await this.endpoint.post(`/api/notifications/${id}`, new RequestBuilder().json(options.data));
|
128
|
+
const t = (await r.json());
|
129
|
+
this.nItems.overwrite(t.id, t);
|
130
|
+
return t;
|
131
|
+
}, options);
|
132
|
+
}
|
133
|
+
/** send work.
|
134
|
+
* @param {string} id - id of the work.
|
135
|
+
*/
|
136
|
+
async send(id, options) {
|
137
|
+
return this.action(async () => {
|
138
|
+
const r = await this.endpoint.post(`/api/notifications/${id}/send`);
|
121
139
|
const t = (await r.json());
|
122
|
-
this.
|
140
|
+
this.nItems.overwrite(t.id, t);
|
123
141
|
return t;
|
124
142
|
}, options);
|
125
143
|
}
|
126
144
|
async delete(ids, options) {
|
127
145
|
return await this.action(async () => {
|
128
|
-
await this.endpoint.delete(`/api/
|
146
|
+
await this.endpoint.delete(`/api/notifications/delete`, new RequestBuilder().json({ Ids: ids, Options: options === null || options === void 0 ? void 0 : options.data }));
|
129
147
|
const deleted = [];
|
130
148
|
for (const id of ids) {
|
131
|
-
const item = this.
|
149
|
+
const item = this.nItems.peek(id);
|
132
150
|
if (item) {
|
133
151
|
deleted.push(item);
|
134
152
|
this._deleted.dispatch(this, item);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"NotificationStore.js","sourceRoot":"","sources":["../../../src/data/notification/NotificationStore.ts"],"names":[],"mappings":";AAAA,OAAO,EAAe,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1D,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,qBAAqB,
|
1
|
+
{"version":3,"file":"NotificationStore.js","sourceRoot":"","sources":["../../../src/data/notification/NotificationStore.ts"],"names":[],"mappings":";AAAA,OAAO,EAAe,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1D,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,qBAAqB,EAAsB,MAAM,qBAAqB,CAAC;AAWnG,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE1C,MAAM,SAAS,GAAG,mBAAmB,CAAC;AAEtC,mDAAmD;AACnD,MAAM,OAAO,iBAAkB,SAAQ,KAAK;IAO3C,YAAmC,QAAqB;QACvD,KAAK,EAAE,CAAC;QADU;;;;mBAAgB,QAAQ;WAAa;QANxD,wBAAwB;QACR;;;;mBAAe,SAAS;WAAC;QACzC,sCAAsC;QACrB;;;;mBAAW,IAAI,eAAe,EAAuC;WAAC;QACtE;;;;mBAAW,IAAI,eAAe,EAAuC;WAAC;QAgBvF,uCAAuC;QACvB;;;;mBAA2C,IAAI,UAAU,CACxE,CAAC,GAAW,EAAE,EAAE,CAAC,CAAC,EAAE,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,CAAC,IAAI,CAAC,CAAC;oBACnB,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;gBACpC,CAAC;YACF,CAAC;YACD,OAAO,OAAO,CAAC;QAChB,CAAC,EAAE,OAAQ,CAAC,CAAC;IACd,CAAC;CACD;AAjBa;IADZ,MAAM;+CAiBN;AAGF,+CAA+C;AAC/C,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,EAAE;IACxC,MAAM,OAAO,GAAG,qBAAqB,EAAE,CAAC;IACxC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,CAAC;QACpC,OAAO,CAAC,eAAe,CAAC,IAAI,iBAAiB,CAAC,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC,CAAC;IAC7E,CAAC;IACD,OAAO,OAAO,CAAC,UAAU,CAAC,SAAS,CAAuB,CAAC;AAC5D,CAAC,CAAC"}
|
@@ -1,11 +1,11 @@
|
|
1
|
-
import { INotification, LoadNotificationOptions } from ".";
|
1
|
+
import { INotification, INewNotification, LoadNotificationOptions, LoadNewNotificationOptions } from ".";
|
2
2
|
import { ListDataContextState } from "@voplus/morpho-ui/es/data";
|
3
3
|
import { LoadDocumentListOptions } from "@voplus/morpho-document-core";
|
4
4
|
/** notification card */
|
5
5
|
export declare const useNotification: (id: string, options?: LoadNotificationOptions) => INotification;
|
6
6
|
/** 新的 notification */
|
7
|
-
export declare const useNotifications: (id: string, options?:
|
7
|
+
export declare const useNotifications: (id: string, options?: LoadNewNotificationOptions) => INewNotification;
|
8
8
|
/** notification card list */
|
9
9
|
export declare const useNotificationListEffect: (list: ListDataContextState<INotification> | null, effect: (list: INotification[], total?: number) => void, options?: LoadDocumentListOptions) => void;
|
10
10
|
/** 新的 notification */
|
11
|
-
export declare const useNotificationsListEffect: (list: ListDataContextState<
|
11
|
+
export declare const useNotificationsListEffect: (list: ListDataContextState<INewNotification> | null, effect: (list: INewNotification[], total?: number) => void, options?: LoadDocumentListOptions) => void;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { useNotificationStore } from ".";
|
1
|
+
import { useNotificationStore, } from ".";
|
2
2
|
import { useListLoaderEffect } from "@voplus/morpho-ui/es/hooks";
|
3
3
|
import { useLoadCountedMapItem } from "@voplus/morpho-data";
|
4
4
|
/** notification card */
|
@@ -11,7 +11,7 @@ export const useNotification = (id, options) => {
|
|
11
11
|
export const useNotifications = (id, options) => {
|
12
12
|
options = options ? options : {};
|
13
13
|
const store = useNotificationStore();
|
14
|
-
return useLoadCountedMapItem(id, store.
|
14
|
+
return useLoadCountedMapItem(id, store.nItems, (calculatedOptions) => store.newLoad(id, calculatedOptions), options);
|
15
15
|
};
|
16
16
|
/** notification card list */
|
17
17
|
export const useNotificationListEffect = (list, effect, options) => {
|
@@ -25,6 +25,6 @@ export const useNotificationsListEffect = (list, effect, options) => {
|
|
25
25
|
const deps = options ? options : {};
|
26
26
|
const store = useNotificationStore();
|
27
27
|
// Call useListLoaderEffect and ensure won't load twice for same loading options.
|
28
|
-
return useListLoaderEffect(list, store.
|
28
|
+
return useListLoaderEffect(list, store.nItems, effect, () => store.newLoadList(options), [deps]);
|
29
29
|
};
|
30
30
|
//# sourceMappingURL=hooks.js.map
|