@voplus/morpho-workspace 6.0.33 → 6.0.35
Sign up to get free protection for your applications and to get access to all the features.
- package/es/modules/tasks/components/TaskCheckActiveTab/index.d.ts +8 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/index.js +98 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/index.less +10 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/state.d.ts +15 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/state.js +128 -0
- package/es/modules/tasks/components/TaskCheckActiveTab/state.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/index.d.ts +7 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/index.js +60 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/state.d.ts +4 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/state.js +17 -0
- package/es/modules/tasks/components/TaskCheckDoneTab/state.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckItem/index.d.ts +6 -0
- package/es/modules/tasks/components/TaskCheckItem/index.js +26 -0
- package/es/modules/tasks/components/TaskCheckItem/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckItem/index.less +8 -0
- package/es/modules/tasks/components/TaskCheckList/index.d.ts +6 -0
- package/es/modules/tasks/components/TaskCheckList/index.js +72 -0
- package/es/modules/tasks/components/TaskCheckList/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckList/index.less +43 -0
- package/es/modules/tasks/components/TaskCheckList/state.d.ts +10 -0
- package/es/modules/tasks/components/TaskCheckList/state.js +65 -0
- package/es/modules/tasks/components/TaskCheckList/state.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckListCard/index.d.ts +12 -0
- package/es/modules/tasks/components/TaskCheckListCard/index.js +14 -0
- package/es/modules/tasks/components/TaskCheckListCard/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckNewForm/index.d.ts +9 -0
- package/es/modules/tasks/components/TaskCheckNewForm/index.js +57 -0
- package/es/modules/tasks/components/TaskCheckNewForm/index.js.map +1 -0
- package/es/modules/tasks/components/TaskCheckNewForm/index.less +8 -0
- package/es/modules/tasks/components/TaskCheckNewForm/state.d.ts +15 -0
- package/es/modules/tasks/components/TaskCheckNewForm/state.js +45 -0
- package/es/modules/tasks/components/TaskCheckNewForm/state.js.map +1 -0
- package/es/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.d.ts +1 -0
- package/es/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.js +25 -22
- package/es/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.js.map +1 -1
- package/es/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.less +7 -0
- package/package.json +1 -1
@@ -0,0 +1,8 @@
|
|
1
|
+
import React from "react";
|
2
|
+
import { State as TaskCheckState } from "../TaskCheckList/state";
|
3
|
+
import "./index.less";
|
4
|
+
declare const TaskCheckActiveTab: (props: {
|
5
|
+
parentId: string;
|
6
|
+
taskCheckState: TaskCheckState;
|
7
|
+
}) => React.JSX.Element;
|
8
|
+
export default TaskCheckActiveTab;
|
@@ -0,0 +1,98 @@
|
|
1
|
+
import React, { useState } from "react";
|
2
|
+
import { observe } from "@voplus/morpho-ui";
|
3
|
+
import { Skeleton, Collapse, Empty } from "antd";
|
4
|
+
import { useOnNewDocument, useOnDeleteDocument } from "@voplus/morpho-document-core";
|
5
|
+
import { CaretRightOutlined } from "@ant-design/icons";
|
6
|
+
import TaskCheckItem from "../TaskCheckItem";
|
7
|
+
import DocumentItemFrame from "@voplus/morpho-document/es/controls/DocumentItemFrame";
|
8
|
+
import { useRenderOnChange } from "@voplus/morpho-ui";
|
9
|
+
import { State } from "./state";
|
10
|
+
import { runInAction } from "mobx";
|
11
|
+
import { ListDataContext, useCreateListDataState } from "@voplus/morpho-ui/es/data";
|
12
|
+
import { useTaskListEffect } from "@voplus/morpho-document-core";
|
13
|
+
import "./index.less";
|
14
|
+
const TaskCheckActiveTab = (props) => {
|
15
|
+
const { parentId, taskCheckState } = props;
|
16
|
+
const [state] = useState(new State());
|
17
|
+
const list = useCreateListDataState({
|
18
|
+
filterDefaults: {
|
19
|
+
includes: "tags",
|
20
|
+
filters: [
|
21
|
+
{ c: "ParentNodeId", o: "=", l: "And", v1: parentId },
|
22
|
+
{ c: "TaskStatus", o: "!=", l: "And", v1: "Done" },
|
23
|
+
/** 必須提供parent node id或assignee filter */
|
24
|
+
// {
|
25
|
+
// c: "Members",
|
26
|
+
// o: "contains",
|
27
|
+
// v1: JSON.stringify(Array.from(this.members.keys())),
|
28
|
+
// l: "And",
|
29
|
+
// },
|
30
|
+
],
|
31
|
+
page: { Page: 1, PageSize: 500 },
|
32
|
+
},
|
33
|
+
}, [parentId]);
|
34
|
+
/** 如果 list.filters.options变更了就重渲染,使下一行的useTaskListEffect 可以接收新参数*/
|
35
|
+
useRenderOnChange(() => list.filters.options);
|
36
|
+
/** 把ListDataState传给useTaskListEffect,使之可以自動更新loading, hasmore. */
|
37
|
+
useTaskListEffect(list, (result, total) => {
|
38
|
+
list.union(result);
|
39
|
+
state.update(result, "new");
|
40
|
+
runInAction(() => {
|
41
|
+
state.total = total;
|
42
|
+
taskCheckState.updateActiveTotals(total);
|
43
|
+
});
|
44
|
+
}, { ...list.filters.options, Total: true });
|
45
|
+
/** 新增task */
|
46
|
+
useOnNewDocument((s, doc) => {
|
47
|
+
if (doc.parentId === props.parentId && doc.type === "Task") {
|
48
|
+
state.total += 1;
|
49
|
+
taskCheckState.updateActiveTotals(state.total);
|
50
|
+
state.update([doc], "new");
|
51
|
+
}
|
52
|
+
});
|
53
|
+
/** 删除task */
|
54
|
+
useOnDeleteDocument((s, doc) => {
|
55
|
+
if (doc.parentId === props.parentId && doc.type === "Task") {
|
56
|
+
state.total -= 1;
|
57
|
+
taskCheckState.updateActiveTotals(state.total);
|
58
|
+
state.update([doc], "del");
|
59
|
+
}
|
60
|
+
});
|
61
|
+
return observe(() => (React.createElement(ListDataContext.Provider, { value: list },
|
62
|
+
React.createElement("div", { className: "active-tab-task-list" },
|
63
|
+
React.createElement(Skeleton, { loading: list.loading },
|
64
|
+
React.createElement(Collapse, { className: "active-task-collapse", bordered: false, defaultActiveKey: ["Due", "Today", "Tomorrow", "This Week", "Upcoming"], expandIcon: ({ isActive }) => React.createElement(CaretRightOutlined, { rotate: isActive ? 90 : 0 }), items: [
|
65
|
+
{
|
66
|
+
key: "Due",
|
67
|
+
label: "Due",
|
68
|
+
children: (React.createElement(React.Fragment, null, state.dueList.length ? (state.dueList.map((item) => (React.createElement(DocumentItemFrame, { key: item.id },
|
69
|
+
React.createElement(TaskCheckItem, { id: item.id }))))) : (React.createElement(Empty, null)))),
|
70
|
+
},
|
71
|
+
{
|
72
|
+
key: "Today",
|
73
|
+
label: "Today",
|
74
|
+
children: (React.createElement(React.Fragment, null, state.todayList.length ? (state.todayList.map((item) => (React.createElement(DocumentItemFrame, { key: item.id },
|
75
|
+
React.createElement(TaskCheckItem, { id: item.id }))))) : (React.createElement(Empty, null)))),
|
76
|
+
},
|
77
|
+
{
|
78
|
+
key: "Tomorrow",
|
79
|
+
label: "Tomorrow",
|
80
|
+
children: (React.createElement(React.Fragment, null, state.tomorrowList.length ? (state.tomorrowList.map((item) => (React.createElement(DocumentItemFrame, { key: item.id },
|
81
|
+
React.createElement(TaskCheckItem, { id: item.id }))))) : (React.createElement(Empty, null)))),
|
82
|
+
},
|
83
|
+
{
|
84
|
+
key: "This Week",
|
85
|
+
label: "This Week",
|
86
|
+
children: (React.createElement(React.Fragment, null, state.thisWeekList.length ? (state.thisWeekList.map((item) => (React.createElement(DocumentItemFrame, { key: item.id },
|
87
|
+
React.createElement(TaskCheckItem, { id: item.id }))))) : (React.createElement(Empty, null)))),
|
88
|
+
},
|
89
|
+
{
|
90
|
+
key: "Upcoming",
|
91
|
+
label: "Upcoming",
|
92
|
+
children: (React.createElement(React.Fragment, null, state.upcomingList.length ? (state.upcomingList.map((item) => (React.createElement(DocumentItemFrame, { key: item.id },
|
93
|
+
React.createElement(TaskCheckItem, { id: item.id }))))) : (React.createElement(Empty, null)))),
|
94
|
+
},
|
95
|
+
] }))))));
|
96
|
+
};
|
97
|
+
export default TaskCheckActiveTab;
|
98
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckActiveTab/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,MAAM,CAAC;AACjD,OAAO,EAAiB,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACpG,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,iBAAiB,MAAM,uDAAuD,CAAC;AACtF,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,eAAe,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AACpF,OAAO,EAAS,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACxE,OAAO,cAAc,CAAC;AAEtB,MAAM,kBAAkB,GAAG,CAAC,KAA2D,EAAE,EAAE;IAC1F,MAAM,EAAE,QAAQ,EAAE,cAAc,EAAE,GAAG,KAAK,CAAC;IAC3C,MAAM,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC,IAAI,KAAK,EAAE,CAAC,CAAC;IACtC,MAAM,IAAI,GAAG,sBAAsB,CAClC;QACC,cAAc,EAAE;YAC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C5B,KAAK,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAChC,oBAAC,iBAAiB,IAAC,GAAG,EAAE,IAAI,CAAC,EAAE;gCAC9B,oBAAC,aAAa,IAAC,EAAE,EAAE,IAAI,CAAC,EAAE,GAAI,CACX,CACpB,CAAC,CACF,CAAC,CAAC,CAAC,CACH,oBAAC,KAAK,OAAG,CACT,CACC,CACH;yBACD;wBACD;4BACC,GAAG,EAAE,UAAU;4BACf,KAAK,EAAE,UAAU;4BACjB,QAAQ,EAAE,CACT,0CACE,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CAC5B,KAAK,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAChC,oBAAC,iBAAiB,IAAC,GAAG,EAAE,IAAI,CAAC,EAAE;gCAC9B,oBAAC,aAAa,IAAC,EAAE,EAAE,IAAI,CAAC,EAAE,GAAI,CACX,CACpB,CAAC,CACF,CAAC,CAAC,CAAC,CACH,oBAAC,KAAK,OAAG,CACT,CACC,CACH;yBACD;qBACD,GACA,CACQ,CACN,CACoB,CAC3B,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
import { ITask } from "@voplus/morpho-document-core";
|
2
|
+
import { Dayjs } from "dayjs";
|
3
|
+
export declare class State {
|
4
|
+
constructor();
|
5
|
+
total: number;
|
6
|
+
/** Due, Today, Tomorrow, This Week, Upcoming */
|
7
|
+
dueList: ITask[];
|
8
|
+
todayList: ITask[];
|
9
|
+
tomorrowList: ITask[];
|
10
|
+
thisWeekList: ITask[];
|
11
|
+
upcomingList: ITask[];
|
12
|
+
update(list: ITask[], type?: "new" | "del"): void;
|
13
|
+
/** 检查特定日期是否在本周内 */
|
14
|
+
isDateInThisWeek(dateToCheck: Dayjs): boolean;
|
15
|
+
}
|
@@ -0,0 +1,128 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable, action } from "mobx";
|
3
|
+
import dayjs from "dayjs";
|
4
|
+
export class State {
|
5
|
+
constructor() {
|
6
|
+
Object.defineProperty(this, "total", {
|
7
|
+
enumerable: true,
|
8
|
+
configurable: true,
|
9
|
+
writable: true,
|
10
|
+
value: 0
|
11
|
+
});
|
12
|
+
/** Due, Today, Tomorrow, This Week, Upcoming */
|
13
|
+
Object.defineProperty(this, "dueList", {
|
14
|
+
enumerable: true,
|
15
|
+
configurable: true,
|
16
|
+
writable: true,
|
17
|
+
value: []
|
18
|
+
});
|
19
|
+
Object.defineProperty(this, "todayList", {
|
20
|
+
enumerable: true,
|
21
|
+
configurable: true,
|
22
|
+
writable: true,
|
23
|
+
value: []
|
24
|
+
});
|
25
|
+
Object.defineProperty(this, "tomorrowList", {
|
26
|
+
enumerable: true,
|
27
|
+
configurable: true,
|
28
|
+
writable: true,
|
29
|
+
value: []
|
30
|
+
});
|
31
|
+
Object.defineProperty(this, "thisWeekList", {
|
32
|
+
enumerable: true,
|
33
|
+
configurable: true,
|
34
|
+
writable: true,
|
35
|
+
value: []
|
36
|
+
});
|
37
|
+
Object.defineProperty(this, "upcomingList", {
|
38
|
+
enumerable: true,
|
39
|
+
configurable: true,
|
40
|
+
writable: true,
|
41
|
+
value: []
|
42
|
+
});
|
43
|
+
makeObservable(this);
|
44
|
+
}
|
45
|
+
update(list, type) {
|
46
|
+
list.map((i) => {
|
47
|
+
if (i.dueDate) {
|
48
|
+
const dueDate = dayjs(i.dueDate);
|
49
|
+
// 获取当前日期
|
50
|
+
const today = dayjs();
|
51
|
+
/** 获取明天的日期 */
|
52
|
+
const tomorrow = today.add(1, "day");
|
53
|
+
if (dueDate.isSame(today, "day")) {
|
54
|
+
if (type === "new")
|
55
|
+
this.todayList.push(i);
|
56
|
+
else
|
57
|
+
this.todayList = this.todayList.filter((item) => item.id !== i.id);
|
58
|
+
}
|
59
|
+
else if (dueDate.isSame(tomorrow, "day")) {
|
60
|
+
if (type === "new")
|
61
|
+
this.tomorrowList.push(i);
|
62
|
+
else
|
63
|
+
this.tomorrowList = this.tomorrowList.filter((item) => item.id !== i.id);
|
64
|
+
}
|
65
|
+
else if (dueDate.isBefore(today)) {
|
66
|
+
if (type === "new")
|
67
|
+
this.dueList.push(i);
|
68
|
+
else
|
69
|
+
this.dueList = this.dueList.filter((item) => item.id !== i.id);
|
70
|
+
}
|
71
|
+
else if (this.isDateInThisWeek(dueDate)) {
|
72
|
+
if (type === "new")
|
73
|
+
this.thisWeekList.push(i);
|
74
|
+
else
|
75
|
+
this.thisWeekList = this.thisWeekList.filter((item) => item.id !== i.id);
|
76
|
+
}
|
77
|
+
else {
|
78
|
+
if (type === "new")
|
79
|
+
this.upcomingList.push(i);
|
80
|
+
else
|
81
|
+
this.upcomingList = this.upcomingList.filter((item) => item.id !== i.id);
|
82
|
+
}
|
83
|
+
}
|
84
|
+
else {
|
85
|
+
if (type === "new")
|
86
|
+
this.upcomingList.push(i);
|
87
|
+
else
|
88
|
+
this.upcomingList = this.upcomingList.filter((item) => item.id !== i.id);
|
89
|
+
}
|
90
|
+
});
|
91
|
+
}
|
92
|
+
/** 检查特定日期是否在本周内 */
|
93
|
+
isDateInThisWeek(dateToCheck) {
|
94
|
+
// 获取当前日期
|
95
|
+
const now = dayjs();
|
96
|
+
// 本周区间
|
97
|
+
const startOfWeek = now.startOf("week");
|
98
|
+
const endOfWeek = now.endOf("week");
|
99
|
+
return (dateToCheck.isSame(startOfWeek, "day") ||
|
100
|
+
dateToCheck.isSame(endOfWeek, "day") ||
|
101
|
+
(dateToCheck.isAfter(startOfWeek) && dateToCheck.isBefore(endOfWeek)));
|
102
|
+
}
|
103
|
+
}
|
104
|
+
__decorate([
|
105
|
+
observable
|
106
|
+
], State.prototype, "total", void 0);
|
107
|
+
__decorate([
|
108
|
+
observable
|
109
|
+
], State.prototype, "dueList", void 0);
|
110
|
+
__decorate([
|
111
|
+
observable
|
112
|
+
], State.prototype, "todayList", void 0);
|
113
|
+
__decorate([
|
114
|
+
observable
|
115
|
+
], State.prototype, "tomorrowList", void 0);
|
116
|
+
__decorate([
|
117
|
+
observable
|
118
|
+
], State.prototype, "thisWeekList", void 0);
|
119
|
+
__decorate([
|
120
|
+
observable
|
121
|
+
], State.prototype, "upcomingList", void 0);
|
122
|
+
__decorate([
|
123
|
+
action
|
124
|
+
], State.prototype, "update", null);
|
125
|
+
__decorate([
|
126
|
+
action
|
127
|
+
], State.prototype, "isDateInThisWeek", null);
|
128
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckActiveTab/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE1D,OAAO,KAAgB,MAAM,OAAO,CAAC;AAErC,MAAM,OAAO,KAAK;IACjB;QAImB;;;;mBAAgB,CAAC;WAAC;QACrC,gDAAgD;QAC7B;;;;mBAAmB,EAAE;WAAC;QACtB;;;;mBAAqB,EAAE;WAAC;QACxB;;;;mBAAwB,EAAE;WAAC;QAC3B;;;;mBAAwB,EAAE;WAAC;QAC3B;;;;mBAAwB,EAAE;WAAC;QAT7C,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;IAUc,MAAM,CAAC,IAAa,EAAE,IAAoB;QACxD,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE;YACd,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;gBACf,MAAM,OAAO,GAAG,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;gBACjC,SAAS;gBACT,MAAM,KAAK,GAAG,KAAK,EAAE,CAAC;gBACtB,cAAc;gBACd,MAAM,QAAQ,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC;gBAErC,IAAI,OAAO,CAAC,M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AmC;AAC3B;IAAlB,UAAU;2CAAmC;AAC3B;IAAlB,UAAU;2CAAmC;AAE/B;IAAd,MAAM;mCA8BN;AAGc;IAAd,MAAM;6CAWN"}
|
@@ -0,0 +1,60 @@
|
|
1
|
+
import React, { useState } from "react";
|
2
|
+
import { observe } from "@voplus/morpho-ui";
|
3
|
+
import { useOnNewDocument, useOnDeleteDocument } from "@voplus/morpho-document-core";
|
4
|
+
import TaskCheckItem from "../TaskCheckItem";
|
5
|
+
import DocumentItemFrame from "@voplus/morpho-document/es/controls/DocumentItemFrame";
|
6
|
+
import { useRenderOnChange } from "@voplus/morpho-ui";
|
7
|
+
import ListView from "@voplus/morpho-ui/es/components/layout/ListView/ListView2";
|
8
|
+
import { runInAction } from "mobx";
|
9
|
+
import { State } from "./state";
|
10
|
+
import { ListDataContext, useCreateListDataState } from "@voplus/morpho-ui/es/data";
|
11
|
+
import { useTaskListEffect } from "@voplus/morpho-document-core";
|
12
|
+
const TaskCheckDoneTab = (props) => {
|
13
|
+
const { parentId, taskCheckState } = props;
|
14
|
+
const [state] = useState(new State());
|
15
|
+
const list = useCreateListDataState({
|
16
|
+
filterDefaults: {
|
17
|
+
includes: "tags",
|
18
|
+
filters: [
|
19
|
+
{ c: "ParentNodeId", o: "=", l: "And", v1: parentId },
|
20
|
+
{ c: "TaskStatus", o: "contains", l: "And", v1: "['Done']" },
|
21
|
+
/** 必須提供parent node id或assignee filter */
|
22
|
+
// {
|
23
|
+
// c: "Members",
|
24
|
+
// o: "contains",
|
25
|
+
// v1: JSON.stringify(Array.from(this.members.keys())),
|
26
|
+
// l: "And",
|
27
|
+
// },
|
28
|
+
],
|
29
|
+
},
|
30
|
+
}, [parentId]);
|
31
|
+
/** 如果 list.filters.options变更了就重渲染,使下一行的useTaskListEffect 可以接收新参数*/
|
32
|
+
useRenderOnChange(() => list.filters.options);
|
33
|
+
/** 把ListDataState传给useTaskListEffect,使之可以自動更新loading, hasmore. */
|
34
|
+
useTaskListEffect(list, (result, total) => {
|
35
|
+
list.union(result);
|
36
|
+
runInAction(() => {
|
37
|
+
state.total = total;
|
38
|
+
taskCheckState.updateDoneTotals(total);
|
39
|
+
});
|
40
|
+
}, { ...list.filters.options, Total: true });
|
41
|
+
/** 新增task */
|
42
|
+
useOnNewDocument((s, doc) => {
|
43
|
+
if (doc.parentId === props.parentId && doc.type === "Task") {
|
44
|
+
state.total += 1;
|
45
|
+
taskCheckState.updateDoneTotals(state.total);
|
46
|
+
}
|
47
|
+
});
|
48
|
+
/** 删除task */
|
49
|
+
useOnDeleteDocument((s, doc) => {
|
50
|
+
if (doc.parentId === props.parentId && doc.type === "Task") {
|
51
|
+
state.total -= 1;
|
52
|
+
taskCheckState.updateDoneTotals(state.total);
|
53
|
+
}
|
54
|
+
});
|
55
|
+
return observe(() => (React.createElement(ListDataContext.Provider, { value: list },
|
56
|
+
React.createElement(ListView, { renderId: props.parentId, asideable: false, headerProps: { visible: false }, renderItem: ({ item }) => (React.createElement(DocumentItemFrame, { key: item.id },
|
57
|
+
React.createElement(TaskCheckItem, { id: item.id }))) }))));
|
58
|
+
};
|
59
|
+
export default TaskCheckDoneTab;
|
60
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckDoneTab/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAiB,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACpG,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,iBAAiB,MAAM,uDAAuD,CAAC;AACtF,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,QAAQ,MAAM,2DAA2D,CAAC;AACjF,OAAO,EAAE,WAAW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 -0,0 +1,17 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable } from "mobx";
|
3
|
+
export class State {
|
4
|
+
constructor() {
|
5
|
+
Object.defineProperty(this, "total", {
|
6
|
+
enumerable: true,
|
7
|
+
configurable: true,
|
8
|
+
writable: true,
|
9
|
+
value: 0
|
10
|
+
});
|
11
|
+
makeObservable(this);
|
12
|
+
}
|
13
|
+
}
|
14
|
+
__decorate([
|
15
|
+
observable
|
16
|
+
], State.prototype, "total", void 0);
|
17
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckDoneTab/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAU,MAAM,MAAM,CAAC;AAE1D,MAAM,OAAO,KAAK;IACjB;QAImB;;;;mBAAgB,CAAC;WAAC;QAHpC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;CAGD;AADmB;IAAlB,UAAU;oCAA0B"}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
import React, { useState, useEffect } from "react";
|
2
|
+
import { observe } from "@voplus/morpho-ui";
|
3
|
+
import { autorun } from "mobx";
|
4
|
+
import { message } from "antd";
|
5
|
+
import TaskStatusLabel from "../../controls/TaskStatusLabel";
|
6
|
+
import FlagIcon from "@voplus/morpho-document/es/controls/data-icons/FlagIcon";
|
7
|
+
import { useTask, useTaskStore } from "@voplus/morpho-document-core";
|
8
|
+
import DocumentHeader from "@voplus/morpho-document/es/components/DocumentHeader";
|
9
|
+
import "./index.less";
|
10
|
+
const TaskCheckItem = (props) => {
|
11
|
+
const { id } = props;
|
12
|
+
const task = useTask(id);
|
13
|
+
const taskStore = useTaskStore();
|
14
|
+
const [taskStatus, setTaskStatus] = useState(task.taskStatus);
|
15
|
+
useEffect(() => autorun(() => setTaskStatus(task.taskStatus)), [task.taskStatus]);
|
16
|
+
return observe(() => (React.createElement(DocumentHeader, { id: id, flagVisible: false, tagsVisible: false, quickDataBarVisible: false, className: "task-check-item", clickNameEffect: "default", pre: React.createElement(FlagIcon, { id: task.id, flag: task.flag, editable: !task.readonly }), tools: React.createElement(TaskStatusLabel, { status: taskStatus, editable: !task.readonly, onChange: async (TaskStatus) => {
|
17
|
+
setTaskStatus(TaskStatus);
|
18
|
+
await taskStore.edit(task.id, {
|
19
|
+
data: { TaskStatus },
|
20
|
+
error: (error) => message.error(error.message),
|
21
|
+
});
|
22
|
+
setTaskStatus(task.taskStatus);
|
23
|
+
} }) })));
|
24
|
+
};
|
25
|
+
export default TaskCheckItem;
|
26
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckItem/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,eAAe,MAAM,gCAAgC,CAAC;AAC7D,OAAO,QAAQ,MAAM,yDAAyD,CAAC;AAC/E,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,cAAc,MAAM,sDAAsD,CAAC;AAClF,OAAO,cAAc,CAAC;AAEtB,MAAM,aAAa,GAAG,CAAC,KAAqB,EAAE,EAAE;IAC/C,MAAM,EAAE,EAAE,EAAE,GAAG,KAAK,CAAC;IACrB,MAAM,IAAI,GAAG,OAAO,CAAC,EAAE,CAAC,CAAC;IACzB,MAAM,SAAS,GAAG,YAAY,EAAE,CAAC;IACjC,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QA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|
4
|
+
import TaskCheckDoneTab from "../TaskCheckDoneTab";
|
5
|
+
import { Button, Tabs, Badge } from "antd";
|
6
|
+
import { Scrollbars } from "react-custom-scrollbars-2";
|
7
|
+
import { FontAwesomeIcon as FAIcon } from "@fortawesome/react-fontawesome";
|
8
|
+
import { faEllipsis } from "@fortawesome/pro-solid-svg-icons";
|
9
|
+
import TaskCheckNewForm from "../TaskCheckNewForm";
|
10
|
+
import { State } from "./state";
|
11
|
+
import classnames from "classnames";
|
12
|
+
import { useTaskListEffect } from "@voplus/morpho-document-core";
|
13
|
+
import { ViewContext, ViewContextData, } from "@voplus/morpho-document-core/es/data/context/ViewContext";
|
14
|
+
import "./index.less";
|
15
|
+
const TaskCheckList = (props) => {
|
16
|
+
const { id } = props;
|
17
|
+
const [state] = useState(new State());
|
18
|
+
const view = useMemo(() => new ViewContextData("PropertiesView"), []);
|
19
|
+
useTaskListEffect(null, (result, total) => state.updateActiveTotals(total), {
|
20
|
+
Total: true,
|
21
|
+
List: false,
|
22
|
+
Filters: [
|
23
|
+
{ c: "ParentNodeId", o: "=", l: "And", v1: id },
|
24
|
+
{ c: "TaskStatus", o: "!=", l: "And", v1: "Done" },
|
25
|
+
],
|
26
|
+
});
|
27
|
+
useTaskListEffect(null, (result, total) => state.updateDoneTotals(total), {
|
28
|
+
Total: true,
|
29
|
+
List: false,
|
30
|
+
Filters: [
|
31
|
+
{ c: "ParentNodeId", o: "=", l: "And", v1: id },
|
32
|
+
{ c: "TaskStatus", o: "contains", l: "And", v1: "['Done']" },
|
33
|
+
],
|
34
|
+
});
|
35
|
+
return observe(() => (React.createElement(ViewContext.Provider, { value: view },
|
36
|
+
React.createElement("div", { className: "task-check-list" },
|
37
|
+
React.createElement("div", { className: "task-check-header" },
|
38
|
+
React.createElement("h3", { className: "text-lg font-medium leading-6 text-gray-900" }, "Tasks"),
|
39
|
+
React.createElement("div", null,
|
40
|
+
React.createElement(Button, { type: "primary", onClick: onMore },
|
41
|
+
React.createElement(FAIcon, { icon: faEllipsis })))),
|
42
|
+
React.createElement(Tabs, { className: classnames("task-check-tabs", { "show-tabbar": state.showTabbar }), tabBarExtraContent: React.createElement(Button, { onClick: onCreate }, "Create"), activeKey: state.activeKey, onChange: (activeKey) => (state.activeKey = activeKey), items: [
|
43
|
+
{
|
44
|
+
key: "Active",
|
45
|
+
label: (React.createElement(React.Fragment, null,
|
46
|
+
"Active",
|
47
|
+
React.createElement(Badge, { overflowCount: 9999, count: state.activeTotals }))),
|
48
|
+
children: (React.createElement(Scrollbars, { autoHide: true },
|
49
|
+
React.createElement(TaskCheckActiveTab, { parentId: props.id, taskCheckState: state }))),
|
50
|
+
},
|
51
|
+
{
|
52
|
+
key: "Done",
|
53
|
+
label: (React.createElement(React.Fragment, null,
|
54
|
+
"Done",
|
55
|
+
React.createElement(Badge, { overflowCount: 9999, count: state.doneTotals }))),
|
56
|
+
children: (React.createElement(Scrollbars, { autoHide: true },
|
57
|
+
React.createElement(TaskCheckDoneTab, { parentId: props.id, taskCheckState: state }))),
|
58
|
+
},
|
59
|
+
] }),
|
60
|
+
state.addAble && (React.createElement(TaskCheckNewForm, { parentId: props.id, onCancel: () => (state.addAble = false), onSave: () => (state.addAble = false) }))))));
|
61
|
+
function onCreate() {
|
62
|
+
state.addAble = true;
|
63
|
+
state.activeKey = "Active";
|
64
|
+
}
|
65
|
+
function onMore() {
|
66
|
+
state.showTabbar = !state.showTabbar;
|
67
|
+
if (!state.showTabbar)
|
68
|
+
state.activeKey = "Active";
|
69
|
+
}
|
70
|
+
};
|
71
|
+
export default TaskCheckList;
|
72
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAm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
+
.task-check-list {
|
3
|
+
height: 100%;
|
4
|
+
display: flex;
|
5
|
+
flex-direction: column;
|
6
|
+
.task-check-header {
|
7
|
+
display: flex;
|
8
|
+
align-items: center;
|
9
|
+
justify-content: space-between;
|
10
|
+
padding: 10px 20px 10px 20px;
|
11
|
+
border-bottom: 1px solid #e6e6e6;
|
12
|
+
}
|
13
|
+
.task-check-tabs {
|
14
|
+
flex: 1;
|
15
|
+
|
16
|
+
&.show-tabbar {
|
17
|
+
.ant-tabs-nav-wrap {
|
18
|
+
display: flex;
|
19
|
+
}
|
20
|
+
.ant-tabs-extra-content {
|
21
|
+
display: block;
|
22
|
+
}
|
23
|
+
}
|
24
|
+
.ant-tabs-nav-wrap {
|
25
|
+
display: none;
|
26
|
+
}
|
27
|
+
.ant-tabs-extra-content {
|
28
|
+
display: none;
|
29
|
+
}
|
30
|
+
.ant-tabs-tab-btn {
|
31
|
+
.ant-badge {
|
32
|
+
margin-left: 5px;
|
33
|
+
}
|
34
|
+
}
|
35
|
+
.ant-tabs-extra-content {
|
36
|
+
padding-right: 20px;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
.ant-tabs-nav-wrap {
|
40
|
+
padding-left: 20px;
|
41
|
+
}
|
42
|
+
}
|
43
|
+
}
|
@@ -0,0 +1,65 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable, action } from "mobx";
|
3
|
+
export class State {
|
4
|
+
constructor() {
|
5
|
+
Object.defineProperty(this, "addAble", {
|
6
|
+
enumerable: true,
|
7
|
+
configurable: true,
|
8
|
+
writable: true,
|
9
|
+
value: false
|
10
|
+
});
|
11
|
+
Object.defineProperty(this, "showTabbar", {
|
12
|
+
enumerable: true,
|
13
|
+
configurable: true,
|
14
|
+
writable: true,
|
15
|
+
value: false
|
16
|
+
});
|
17
|
+
Object.defineProperty(this, "activeKey", {
|
18
|
+
enumerable: true,
|
19
|
+
configurable: true,
|
20
|
+
writable: true,
|
21
|
+
value: "Active"
|
22
|
+
});
|
23
|
+
Object.defineProperty(this, "activeTotals", {
|
24
|
+
enumerable: true,
|
25
|
+
configurable: true,
|
26
|
+
writable: true,
|
27
|
+
value: void 0
|
28
|
+
});
|
29
|
+
Object.defineProperty(this, "doneTotals", {
|
30
|
+
enumerable: true,
|
31
|
+
configurable: true,
|
32
|
+
writable: true,
|
33
|
+
value: void 0
|
34
|
+
});
|
35
|
+
makeObservable(this);
|
36
|
+
}
|
37
|
+
updateActiveTotals(total) {
|
38
|
+
this.activeTotals = total;
|
39
|
+
}
|
40
|
+
updateDoneTotals(total) {
|
41
|
+
this.doneTotals = total;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
__decorate([
|
45
|
+
observable
|
46
|
+
], State.prototype, "addAble", void 0);
|
47
|
+
__decorate([
|
48
|
+
observable
|
49
|
+
], State.prototype, "showTabbar", void 0);
|
50
|
+
__decorate([
|
51
|
+
observable
|
52
|
+
], State.prototype, "activeKey", void 0);
|
53
|
+
__decorate([
|
54
|
+
observable
|
55
|
+
], State.prototype, "activeTotals", void 0);
|
56
|
+
__decorate([
|
57
|
+
observable
|
58
|
+
], State.prototype, "doneTotals", void 0);
|
59
|
+
__decorate([
|
60
|
+
action
|
61
|
+
], State.prototype, "updateActiveTotals", null);
|
62
|
+
__decorate([
|
63
|
+
action
|
64
|
+
], State.prototype, "updateDoneTotals", null);
|
65
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckList/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE1D,MAAM,OAAO,KAAK;IACjB;QAImB;;;;mBAAU,KAAK;WAAC;QAChB;;;;mBAAa,KAAK;WAAC;QACnB;;;;mBAAY,QAAQ;WAAC;QACrB;;;;;WAAsB;QACtB;;;;;WAAoB;QAPtC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;IAQc,kBAAkB,CAAC,KAAa;QAC9C,IAAI,CAAC,YAAY,GAAG,KAAK,CAAC;IAC3B,CAAC;IAEc,gBAAgB,CAAC,KAAa;QAC5C,IAAI,CAAC,UAAU,GAAG,KAAK,CAAC;IACzB,CAAC;CACD;AAbmB;IAAlB,UAAU;sCAAwB;AAChB;IAAlB,UAAU;yCAA2B;AACnB;IAAlB,UAAU;wCAA6B;AACrB;IAAlB,UAAU;2CAA8B;AACtB;IAAlB,UAAU;yCAA4B;AAExB;IAAd,MAAM;+CAEN;AAEc;IAAd,MAAM;6CAEN"}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import React from "react";
|
2
|
+
declare const TaskCheckListCard: {
|
3
|
+
(props: {
|
4
|
+
style?: React.CSSProperties;
|
5
|
+
id: string;
|
6
|
+
}): React.JSX.Element;
|
7
|
+
defaultProps: {
|
8
|
+
openNewFormMode: string;
|
9
|
+
total: boolean;
|
10
|
+
};
|
11
|
+
};
|
12
|
+
export default TaskCheckListCard;
|
@@ -0,0 +1,14 @@
|
|
1
|
+
import React from "react";
|
2
|
+
import { observe } from "@voplus/morpho-ui";
|
3
|
+
import ListCard from "@voplus/morpho-ui/es/controls/ListCard";
|
4
|
+
import TaskCheckList from "../TaskCheckList";
|
5
|
+
const TaskCheckListCard = (props) => {
|
6
|
+
return observe(() => (React.createElement(ListCard, { style: props.style },
|
7
|
+
React.createElement(TaskCheckList, { id: props.id }))));
|
8
|
+
};
|
9
|
+
TaskCheckListCard.defaultProps = {
|
10
|
+
openNewFormMode: "openDialog",
|
11
|
+
total: true,
|
12
|
+
};
|
13
|
+
export default TaskCheckListCard;
|
14
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckListCard/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,QAAQ,MAAM,wCAAwC,CAAC;AAC9D,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAE7C,MAAM,iBAAiB,GAAG,CAAC,KAAkD,EAAE,EAAE;IAChF,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,CAAC,KAAK;QAC3B,oBAAC,aAAa,IAAC,EAAE,EAAE,KAAK,CAAC,EAAE,GAAI,CACrB,CACX,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,iBAAiB,CAAC,YAAY,GAAG;IAChC,eAAe,EAAE,YAAY;IAC7B,KAAK,EAAE,IAAI;CACX,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
@@ -0,0 +1,9 @@
|
|
1
|
+
import React from "react";
|
2
|
+
import "./index.less";
|
3
|
+
declare const TaskCheckNewForm: (props: {
|
4
|
+
parentId?: string | undefined;
|
5
|
+
className?: string | undefined;
|
6
|
+
onSave?: ((params?: any) => void) | undefined;
|
7
|
+
onCancel?: (() => void) | undefined;
|
8
|
+
}) => React.JSX.Element;
|
9
|
+
export default TaskCheckNewForm;
|
@@ -0,0 +1,57 @@
|
|
1
|
+
import React, { useState } from "react";
|
2
|
+
import { Space, Col, Button, Form, Input, Row, Select, message } from "antd";
|
3
|
+
import { State } from "./state";
|
4
|
+
import { observe } from "@voplus/morpho-ui";
|
5
|
+
import { runInAction } from "mobx";
|
6
|
+
import { useTaskStore } from "@voplus/morpho-document-core";
|
7
|
+
import classnames from "classnames";
|
8
|
+
import "./index.less";
|
9
|
+
const TaskCheckNewForm = (props) => {
|
10
|
+
const tasks = useTaskStore();
|
11
|
+
const [state] = useState(new State());
|
12
|
+
return observe(() => (React.createElement("div", { className: classnames("new-task-check-form", props.className) },
|
13
|
+
React.createElement(Form, { layout: "vertical" },
|
14
|
+
React.createElement(Row, { gutter: 20 },
|
15
|
+
React.createElement(Col, { span: 12 },
|
16
|
+
React.createElement(Form.Item, null,
|
17
|
+
React.createElement(Input, { autoFocus: true, value: state.params.Name, placeholder: `Enter a title for this task`, onChange: (e) => runInAction(() => (state.params.Name = e.target.value)) }))),
|
18
|
+
React.createElement(Col, { span: 12 },
|
19
|
+
React.createElement(Form.Item, null,
|
20
|
+
React.createElement(Select, { placeholder: "Due preset", options: [
|
21
|
+
{ value: "Today", label: "Today" },
|
22
|
+
{ value: "Tomorrow", label: "Tomorrow" },
|
23
|
+
{ value: "UpcomingMonday", label: "Upcoming Monday" },
|
24
|
+
{ value: "UpcomingTuesday", label: "Upcoming Tuesday" },
|
25
|
+
{ value: "UpcomingWednesday", label: "Upcoming Wednesday" },
|
26
|
+
{ value: "UpcomingThursday", label: "Upcoming Thursday" },
|
27
|
+
{ value: "UpcomingFriday", label: "Upcoming Friday" },
|
28
|
+
], onChange: (val) => runInAction(() => (state.params.DueDate = val)) })))),
|
29
|
+
React.createElement(Row, { className: "case-form-btn", justify: "end" },
|
30
|
+
React.createElement(Space, null,
|
31
|
+
React.createElement(Button, { onClick: onCancel }, "Cancel"),
|
32
|
+
React.createElement(Button, { type: "primary", loading: state.loading, onClick: onSubmit }, "Submit")))))));
|
33
|
+
async function onSubmit() {
|
34
|
+
var _a;
|
35
|
+
if (!state.params.Name)
|
36
|
+
return message.warning("Title is required");
|
37
|
+
runInAction(() => (state.loading = true));
|
38
|
+
await tasks.create({
|
39
|
+
data: { ...state.params, ParentId: props.parentId },
|
40
|
+
error: "message",
|
41
|
+
});
|
42
|
+
runInAction(() => {
|
43
|
+
state.loading = false;
|
44
|
+
state.params = state.Params;
|
45
|
+
});
|
46
|
+
(_a = props.onSave) === null || _a === void 0 ? void 0 : _a.call(props);
|
47
|
+
return;
|
48
|
+
}
|
49
|
+
// cancel add task
|
50
|
+
function onCancel() {
|
51
|
+
var _a;
|
52
|
+
state.params = state.Params;
|
53
|
+
(_a = props.onCancel) === null || _a === void 0 ? void 0 : _a.call(props);
|
54
|
+
}
|
55
|
+
};
|
56
|
+
export default TaskCheckNewForm;
|
57
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckNewForm/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC7E,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,OAAO,UAAU,MAAM,YAAY,CAAC;AACpC,OAAO,cAAc,CAAC;AAEtB,MAAM,gBAAgB,GAAG,CAAC,KAKzB,EAAE,EAAE;IACJ,MAAM,KAAK,GAAG,YAAY,EAAE,CAAC;IAC7B,MAAM,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC,IAAI,KAAK,EAAE,CAAC,CAAC;IAEtC,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,6BAAK,SAAS,EAAE,UAAU,CAAC,qBAAqB,EAAE,KAAK,CAAC,SAAS,CAAC;QAEjE,oBAAC,IAAI,IAAC,MAAM,EAAC,UAAU;YACtB,oBAAC,GAAG,IAAC,MAAM,EAAE,EAAE;gBACd,oBAAC,GAAG,IAAC,IAAI,EAAE,EAAE;oBACZ,oBAAC,IAAI,CAAC,IAAI;wBACT,oBAAC,KAAK,IACL,SAAS,QACT,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,IAAI,EACxB,WAAW,EAAE,6BAA6B,EAC1C,QAAQ,EAAE,CAA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,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI;YAAE,OAAO,OAAO,CAAC,OAAO,CAAC,mBAAmB,CAAC,CAAC;QACpE,WAAW,CAAC,GAAG,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,GAAG,IAAI,CAAC,CAAC,CAAC;QAC1C,MAAM,KAAK,CAAC,MAAM,CAAC;YAClB,IAAI,EAAE,EAAE,GAAG,KAAK,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAK,CAAC,QAAQ,EAAS;YAC1D,KAAK,EAAE,SAAS;SAChB,CAAC,CAAC;QACH,WAAW,CAAC,GAAG,EAAE;YAChB,KAAK,CAAC,OAAO,GAAG,KAAK,CAAC;YACtB,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;QAC7B,CAAC,CAAC,CAAC;QACH,MAAA,KAAK,CAAC,MAAM,qDAAI,CAAC;QACjB,OAAO;IACR,CAAC;IACD,kBAAkB;IAClB,SAAS,QAAQ;;QAChB,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;QAC5B,MAAA,KAAK,CAAC,QAAQ,qDAAI,CAAC;IACpB,CAAC;AACF,CAAC,CAAC;AACF,eAAe,gBAAgB,CAAC"}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
export declare class State {
|
2
|
+
constructor();
|
3
|
+
Params: {
|
4
|
+
Name: string;
|
5
|
+
DueDate: string;
|
6
|
+
InheritMembers: boolean;
|
7
|
+
};
|
8
|
+
params: {
|
9
|
+
Name: string;
|
10
|
+
DueDate: string;
|
11
|
+
InheritMembers: boolean;
|
12
|
+
};
|
13
|
+
showMore: boolean;
|
14
|
+
loading: boolean;
|
15
|
+
}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable } from "mobx";
|
3
|
+
export class State {
|
4
|
+
constructor() {
|
5
|
+
Object.defineProperty(this, "Params", {
|
6
|
+
enumerable: true,
|
7
|
+
configurable: true,
|
8
|
+
writable: true,
|
9
|
+
value: {
|
10
|
+
Name: "",
|
11
|
+
DueDate: "",
|
12
|
+
InheritMembers: false,
|
13
|
+
}
|
14
|
+
});
|
15
|
+
Object.defineProperty(this, "params", {
|
16
|
+
enumerable: true,
|
17
|
+
configurable: true,
|
18
|
+
writable: true,
|
19
|
+
value: this.Params
|
20
|
+
});
|
21
|
+
Object.defineProperty(this, "showMore", {
|
22
|
+
enumerable: true,
|
23
|
+
configurable: true,
|
24
|
+
writable: true,
|
25
|
+
value: false
|
26
|
+
});
|
27
|
+
Object.defineProperty(this, "loading", {
|
28
|
+
enumerable: true,
|
29
|
+
configurable: true,
|
30
|
+
writable: true,
|
31
|
+
value: false
|
32
|
+
});
|
33
|
+
makeObservable(this);
|
34
|
+
}
|
35
|
+
}
|
36
|
+
__decorate([
|
37
|
+
observable
|
38
|
+
], State.prototype, "params", void 0);
|
39
|
+
__decorate([
|
40
|
+
observable
|
41
|
+
], State.prototype, "showMore", void 0);
|
42
|
+
__decorate([
|
43
|
+
observable
|
44
|
+
], State.prototype, "loading", void 0);
|
45
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/modules/tasks/components/TaskCheckNewForm/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,MAAM,OAAO,KAAK;IACjB;QAGO;;;;mBAAS;gBACf,IAAI,EAAE,EAAE;gBACR,OAAO,EAAE,EAAE;gBACX,cAAc,EAAE,KAAK;aACrB;WAAC;QACiB;;;;mBAAS,IAAI,CAAC,MAAM;WAAC;QACrB;;;;mBAAW,KAAK;WAAC;QACjB;;;;mBAAU,KAAK;WAAC;QATlC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;CASD;AAHmB;IAAlB,UAAU;qCAA6B;AACrB;IAAlB,UAAU;uCAAyB;AACjB;IAAlB,UAAU;sCAAwB"}
|
@@ -3,6 +3,7 @@ import { useWorkScheduleListEffect } from "../../../../../data/work-schedule";
|
|
3
3
|
import React, { useState } from "react";
|
4
4
|
import { faCalendarCheck, faThumbsUp, faUser } from "@fortawesome/pro-light-svg-icons";
|
5
5
|
import { observe, useRenderOnChange } from "@voplus/morpho-ui";
|
6
|
+
import { Scrollbars } from "react-custom-scrollbars-2";
|
6
7
|
import { Empty } from "antd";
|
7
8
|
import { FontAwesomeIcon as FAIcon } from "@fortawesome/react-fontawesome";
|
8
9
|
import FilterView from "@voplus/morpho-ui/es/controls/FilterView";
|
@@ -10,6 +11,7 @@ import WorkScheduleFilter from "../../controls/WorkScheduleFilter";
|
|
10
11
|
import WorkScheduleQuickViewDialog from "../WorkScheduleQuickViewDialog";
|
11
12
|
import classnames from "classnames";
|
12
13
|
import dayjs from "dayjs";
|
14
|
+
import "./index.less";
|
13
15
|
import { useAutoUpdateListData } from "../../../../../data/work-schedule/work-schedule-events";
|
14
16
|
const WorkScheduleTimeLineView = (props) => {
|
15
17
|
const { contact } = props;
|
@@ -35,33 +37,34 @@ const WorkScheduleTimeLineView = (props) => {
|
|
35
37
|
...list.filters.options,
|
36
38
|
});
|
37
39
|
return observe(() => (React.createElement(ListDataContext.Provider, { value: list },
|
38
|
-
React.createElement("div", { className: "mt-5 overflow-hidden bg-white shadow sm:rounded-lg" },
|
40
|
+
React.createElement("div", { className: "mt-5 overflow-hidden bg-white shadow sm:rounded-lg workschedule-time-line" },
|
39
41
|
React.createElement(FilterOptionsContext.Provider, { value: list.filters },
|
40
42
|
React.createElement("div", { className: "px-4 py-4 sm:px-6 flex justify-between" },
|
41
43
|
React.createElement("h3", { className: "text-lg font-medium leading-6 text-gray-900" }, "Work Schedule Time Line"),
|
42
44
|
React.createElement(FilterView, { columns: [React.createElement(WorkScheduleFilter, { key: "WorkScheduleFilter", defaultValue: "Empty" })] }))),
|
43
|
-
React.createElement(
|
44
|
-
React.createElement("div", { className: "
|
45
|
-
|
46
|
-
React.createElement(
|
47
|
-
React.createElement("
|
48
|
-
|
49
|
-
|
50
|
-
React.createElement("div",
|
51
|
-
React.createElement("span", { className: classnames("h-8 w-8 rounded-full flex items-center justify-center ring-8 ring-white", {
|
52
|
-
"bg-gray-400": !event.schedule,
|
53
|
-
"bg-blue-500": !!event.schedule,
|
54
|
-
"bg-green-500": event.schedule && !event.status,
|
55
|
-
}) }, showIcon(event.status))),
|
56
|
-
React.createElement("div", { className: "flex min-w-0 flex-1 justify-between space-x-4 pt-1.5", onClick: () => onQuickView(event.id) },
|
45
|
+
React.createElement(Scrollbars, { autoHide: true },
|
46
|
+
React.createElement("div", { className: "border-t border-gray-200 p-4" },
|
47
|
+
React.createElement("div", { className: "work-schedule-time-line" },
|
48
|
+
!list.data.length ? (React.createElement(Empty, { image: Empty.PRESENTED_IMAGE_SIMPLE })) : (React.createElement("div", { className: "flow-root" },
|
49
|
+
React.createElement("ul", { role: "list", className: "-mb-8" }, list.data.map((event, eventIdx) => (React.createElement("li", { className: "cursor-pointer", key: event.id },
|
50
|
+
React.createElement("div", { className: "relative pb-8" },
|
51
|
+
eventIdx !== list.data.length - 1 ? (React.createElement("span", { className: "absolute top-4 left-4 -ml-px h-full w-0.5 bg-gray-200", "aria-hidden": "true" })) : null,
|
52
|
+
React.createElement("div", { className: "relative flex space-x-3" },
|
57
53
|
React.createElement("div", null,
|
58
|
-
React.createElement("
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
54
|
+
React.createElement("span", { className: classnames("h-8 w-8 rounded-full flex items-center justify-center ring-8 ring-white", {
|
55
|
+
"bg-gray-400": !event.schedule,
|
56
|
+
"bg-blue-500": !!event.schedule,
|
57
|
+
"bg-green-500": event.schedule && !event.status,
|
58
|
+
}) }, showIcon(event.status))),
|
59
|
+
React.createElement("div", { className: "flex min-w-0 flex-1 justify-between space-x-4 pt-1.5", onClick: () => onQuickView(event.id) },
|
60
|
+
React.createElement("div", null,
|
61
|
+
React.createElement("div", { className: "text-sm" },
|
62
|
+
React.createElement("div", { className: "text-sm" }, event.workType.name),
|
63
|
+
React.createElement("div", { className: "font-medium text-gray-500" }, event === null || event === void 0 ? void 0 : event.status))),
|
64
|
+
React.createElement("div", { className: "whitespace-nowrap text-right text-sm text-gray-500" }, event.schedule
|
65
|
+
? dayjs(event.schedule).format("YYYY-MM-DD")
|
66
|
+
: "unscheduled")))))))))),
|
67
|
+
visibleQuickView.visible && visibleQuickView.id && (React.createElement(WorkScheduleQuickViewDialog, { id: visibleQuickView.id, visible: true, onCancel: onQuickView })))))))));
|
65
68
|
function filters() {
|
66
69
|
const filter = [{ c: "Work", o: "=", v1: "null", l: "And" }];
|
67
70
|
if (contact) {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EACN,oBAAoB,EACpB,eAAe,EACf,sBAAsB,GACtB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAiB,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAC7F,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,kCAAkC,CAAC;AACvF,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-schedule/components/WorkScheduleTimeLineView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EACN,oBAAoB,EACpB,eAAe,EACf,sBAAsB,GACtB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAiB,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAC7F,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,eAAe,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