@voplus/morpho-workspace 1.3.2 → 1.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (131) hide show
  1. package/es/data/work/WorkStore.d.ts +12 -0
  2. package/es/data/work/WorkStore.js +21 -0
  3. package/es/data/work/WorkStore.js.map +1 -1
  4. package/es/data/work/interfaces.d.ts +18 -2
  5. package/es/data/workspace/interfaces.d.ts +8 -0
  6. package/es/data/workspace/types.d.ts +1 -0
  7. package/es/data/worktype/WorkTypeStore.d.ts +6 -0
  8. package/es/data/worktype/WorkTypeStore.js +22 -0
  9. package/es/data/worktype/WorkTypeStore.js.map +1 -1
  10. package/es/data/worktype/interfaces.d.ts +4 -0
  11. package/es/data/worktype/types.d.ts +1 -0
  12. package/es/data/worktype/worktype-events/index.d.ts +3 -0
  13. package/es/data/worktype/worktype-events/index.js +4 -0
  14. package/es/data/worktype/worktype-events/index.js.map +1 -0
  15. package/es/data/worktype/worktype-events/useAutoUpdateListData.d.ts +4 -0
  16. package/es/data/worktype/worktype-events/useAutoUpdateListData.js +15 -0
  17. package/es/data/worktype/worktype-events/useAutoUpdateListData.js.map +1 -0
  18. package/es/data/worktype/worktype-events/useOnDeleteWorkType.d.ts +4 -0
  19. package/es/data/worktype/worktype-events/useOnDeleteWorkType.js +16 -0
  20. package/es/data/worktype/worktype-events/useOnDeleteWorkType.js.map +1 -0
  21. package/es/data/worktype/worktype-events/useOnNewWorkType.d.ts +4 -0
  22. package/es/data/worktype/worktype-events/useOnNewWorkType.js +17 -0
  23. package/es/data/worktype/worktype-events/useOnNewWorkType.js.map +1 -0
  24. package/es/modules/work/components/NewWorkForm/index.d.ts +10 -0
  25. package/es/modules/work/components/NewWorkForm/index.js +60 -0
  26. package/es/modules/work/components/NewWorkForm/index.js.map +1 -0
  27. package/es/modules/work/components/NewWorkForm/index.less +17 -0
  28. package/es/modules/work/components/SubWorkList/index.d.ts +4 -0
  29. package/es/modules/work/components/SubWorkList/index.js +42 -0
  30. package/es/modules/work/components/SubWorkList/index.js.map +1 -0
  31. package/es/modules/work/components/SubWorkList/index.less +7 -0
  32. package/es/modules/work/components/WorkErrorList/index.js +7 -6
  33. package/es/modules/work/components/WorkErrorList/index.js.map +1 -1
  34. package/es/modules/work/components/WorkItem/index.d.ts +1 -3
  35. package/es/modules/work/components/WorkItem/index.js +20 -4
  36. package/es/modules/work/components/WorkItem/index.js.map +1 -1
  37. package/es/modules/work/components/WorkItem/index.less +11 -0
  38. package/es/modules/work/components/WorkList/index.js +7 -5
  39. package/es/modules/work/components/WorkList/index.js.map +1 -1
  40. package/es/modules/work/components/WorkPropertiesView/index.js +8 -2
  41. package/es/modules/work/components/WorkPropertiesView/index.js.map +1 -1
  42. package/es/modules/work/components/WorkQATab/index.js +9 -7
  43. package/es/modules/work/components/WorkQATab/index.js.map +1 -1
  44. package/es/modules/work/components/WorkQATab/index.less +8 -8
  45. package/es/modules/work/components/WorkTabs/index.js +10 -1
  46. package/es/modules/work/components/WorkTabs/index.js.map +1 -1
  47. package/es/modules/work/components/WorkTaskList/index.js +8 -6
  48. package/es/modules/work/components/WorkTaskList/index.js.map +1 -1
  49. package/es/modules/work/components/WorkTaskList/index.less +3 -3
  50. package/es/modules/work/components/WorkTasksTab/index.js +4 -2
  51. package/es/modules/work/components/WorkTasksTab/index.js.map +1 -1
  52. package/es/modules/work/components/WorkTasksTab/index.less +2 -2
  53. package/es/modules/work/components/WorksProperties/index.js +5 -3
  54. package/es/modules/work/components/WorksProperties/index.js.map +1 -1
  55. package/es/modules/work/controls/WorkMenu/Accept.d.ts +8 -0
  56. package/es/modules/work/controls/WorkMenu/Accept.js +31 -0
  57. package/es/modules/work/controls/WorkMenu/Accept.js.map +1 -0
  58. package/es/modules/work/controls/WorkMenu/Reject.d.ts +8 -0
  59. package/es/modules/work/controls/WorkMenu/Reject.js +31 -0
  60. package/es/modules/work/controls/WorkMenu/Reject.js.map +1 -0
  61. package/es/modules/work/controls/WorkMenu/Send.d.ts +8 -0
  62. package/es/modules/work/controls/WorkMenu/Send.js +31 -0
  63. package/es/modules/work/controls/WorkMenu/Send.js.map +1 -0
  64. package/es/modules/work/controls/WorkMenu/index.d.ts +7 -0
  65. package/es/modules/work/controls/WorkMenu/index.js +27 -0
  66. package/es/modules/work/controls/WorkMenu/index.js.map +1 -0
  67. package/es/modules/work/pages/WorkDefaultView/index.less +1 -2
  68. package/es/modules/workspace/components/MyWorkspaces/index.js +9 -7
  69. package/es/modules/workspace/components/MyWorkspaces/index.js.map +1 -1
  70. package/es/modules/workspace/components/MyWorkspaces/index.less +2 -2
  71. package/es/modules/workspace/components/WorkspaceCard/index.js +9 -4
  72. package/es/modules/workspace/components/WorkspaceCard/index.js.map +1 -1
  73. package/es/modules/workspace/components/WorkspaceCard/index.less +12 -0
  74. package/es/modules/workspace/components/WorkspaceCardList/index.js +3 -5
  75. package/es/modules/workspace/components/WorkspaceCardList/index.js.map +1 -1
  76. package/es/modules/workspace/components/WorkspacePropertiesView/index.js +11 -5
  77. package/es/modules/workspace/components/WorkspacePropertiesView/index.js.map +1 -1
  78. package/es/modules/workspace/components/WorkspaceTabs/index.d.ts +5 -0
  79. package/es/modules/workspace/components/WorkspaceTabs/index.js +26 -0
  80. package/es/modules/workspace/components/WorkspaceTabs/index.js.map +1 -0
  81. package/es/modules/workspace/controls/WorkspaceMenu/index.js +38 -14
  82. package/es/modules/workspace/controls/WorkspaceMenu/index.js.map +1 -1
  83. package/es/modules/workspace/pages/WorkspaceDefaultView/index.js +1 -1
  84. package/es/modules/workspace/pages/WorkspaceDefaultView/index.js.map +1 -1
  85. package/es/modules/workspace/pages/WorkspacePage/index.js +1 -1
  86. package/es/modules/workspace/pages/WorkspacePage/index.js.map +1 -1
  87. package/es/modules/worktype/components/NewTypeForm/index.d.ts +10 -0
  88. package/es/modules/worktype/components/NewTypeForm/index.js +42 -0
  89. package/es/modules/worktype/components/NewTypeForm/index.js.map +1 -0
  90. package/es/modules/worktype/components/NewTypeForm/index.less +8 -0
  91. package/es/modules/worktype/components/NewTypeForm/state.d.ts +11 -0
  92. package/es/modules/worktype/components/NewTypeForm/state.js +41 -0
  93. package/es/modules/worktype/components/NewTypeForm/state.js.map +1 -0
  94. package/es/modules/worktype/components/WorkTypeCardList/index.d.ts +4 -11
  95. package/es/modules/worktype/components/WorkTypeCardList/index.js +3 -17
  96. package/es/modules/worktype/components/WorkTypeCardList/index.js.map +1 -1
  97. package/es/modules/worktype/components/WorkTypeCardList/index.less +7 -9
  98. package/es/modules/worktype/components/WorkTypeItem/index.d.ts +1 -1
  99. package/es/modules/worktype/components/WorkTypeItem/index.js +14 -2
  100. package/es/modules/worktype/components/WorkTypeItem/index.js.map +1 -1
  101. package/es/modules/worktype/components/WorkTypeItem/index.less +13 -0
  102. package/es/modules/worktype/components/WorkTypeList/index.d.ts +10 -0
  103. package/es/modules/worktype/components/WorkTypeList/index.js +46 -0
  104. package/es/modules/worktype/components/WorkTypeList/index.js.map +1 -0
  105. package/es/modules/worktype/components/WorkTypeList/index.less +7 -0
  106. package/es/modules/worktype/components/WorkTypeProperties/index.js +24 -3
  107. package/es/modules/worktype/components/WorkTypeProperties/index.js.map +1 -1
  108. package/es/modules/worktype/components/WorkTypeProperties/index.less +27 -2
  109. package/es/modules/worktype/components/WorkTypePropertiesView/index.js +13 -8
  110. package/es/modules/worktype/components/WorkTypePropertiesView/index.js.map +1 -1
  111. package/es/modules/worktype/components/WorkTypeQA/index.js +37 -36
  112. package/es/modules/worktype/components/WorkTypeQA/index.js.map +1 -1
  113. package/es/modules/worktype/components/WorkTypeQA/index.less +7 -0
  114. package/es/modules/worktype/components/WorkTypeTabs/index.js +4 -2
  115. package/es/modules/worktype/components/WorkTypeTabs/index.js.map +1 -1
  116. package/es/modules/worktype/controls/WorkTypeMenu/index.d.ts +14 -0
  117. package/es/modules/worktype/controls/WorkTypeMenu/index.js +26 -0
  118. package/es/modules/worktype/controls/WorkTypeMenu/index.js.map +1 -0
  119. package/es/modules/worktype/controls/WorkTypeMenu/index.less +0 -0
  120. package/es/pages/Routes.js +3 -3
  121. package/es/pages/Routes.js.map +1 -1
  122. package/es/pages/Space/components/Tasks/index.js +22 -24
  123. package/es/pages/Space/components/Tasks/index.js.map +1 -1
  124. package/es/pages/Space/pages/MySpace/index.js +5 -5
  125. package/es/pages/Space/pages/MySpace/index.js.map +1 -1
  126. package/es/pages/Space/pages/MySpace/state.d.ts +3 -2
  127. package/es/pages/Space/pages/MySpace/state.js +19 -5
  128. package/es/pages/Space/pages/MySpace/state.js.map +1 -1
  129. package/es/pages/WorkType/WorkTypeSelect/index.js +5 -1
  130. package/es/pages/WorkType/WorkTypeSelect/index.js.map +1 -1
  131. package/package.json +1 -1
@@ -2,6 +2,7 @@ import "./index.less";
2
2
  import React, { useState } from "react";
3
3
  import AsideContent from "@voplus/morpho-ui/es/components/layout/AsideContent";
4
4
  import NewWorkspaceDialog from "../NewWorkspaceDialog";
5
+ import { Scrollbars } from "react-custom-scrollbars";
5
6
  import { Typography } from "@voplus/antd";
6
7
  import WorkspaceCardList from "../WorkspaceCardList";
7
8
  import WorkspacePropertiesView from "../WorkspacePropertiesView";
@@ -12,13 +13,14 @@ const MyWorkspaces = (props) => {
12
13
  const [visible, setVisible] = useState(false);
13
14
  return observe(() => (React.createElement(AsideContent, { context: asideContext },
14
15
  React.createElement("div", { className: "my-workSpaces" },
15
- React.createElement("div", { className: "workspace-list" },
16
- React.createElement(Title, { level: 3 }, "My WorkSpaces"),
17
- React.createElement(WorkspaceCardList, { roles: true, addCard: true, onItemClick: onItemClick })),
18
- React.createElement("div", { className: "workspace-list" },
19
- React.createElement(Title, { level: 3 }, "Worksapce I have access"),
20
- React.createElement(WorkspaceCardList, { onItemClick: onItemClick })),
21
- visible && (React.createElement(NewWorkspaceDialog, { onCancel: () => setVisible(false), onSubmitSave: () => setVisible(false) }))))));
16
+ React.createElement(Scrollbars, { autoHide: true },
17
+ React.createElement("div", { className: "workspace-list" },
18
+ React.createElement(Title, { level: 3 }, "My WorkSpaces"),
19
+ React.createElement(WorkspaceCardList, { roles: true, addCard: true, onItemClick: onItemClick })),
20
+ React.createElement("div", { className: "workspace-list" },
21
+ React.createElement(Title, { level: 3 }, "Worksapce I have access"),
22
+ React.createElement(WorkspaceCardList, { onItemClick: onItemClick })),
23
+ visible && (React.createElement(NewWorkspaceDialog, { onCancel: () => setVisible(false), onSubmitSave: () => setVisible(false) })))))));
22
24
  function onItemClick(item) {
23
25
  var _a;
24
26
  if (item.id !== "0") {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/MyWorkspaces/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,YAAY,MAAM,qDAAqD,CAAC;AAE/E,OAAO,kBAAkB,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,iBAAiB,MAAM,sBAAsB,CAAC;AACrD,OAAO,uBAAuB,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,MAAM,EAAE,KAAK,EAAE,GAAG,UAAU,CAAC;AAE7B,MAAM,YAAY,GAAG,CAAC,KAMrB,EAAE,EAAE;IACJ,MAAM,CAAC,YAAY,CAAC,GAAG,QAAQ,CAAC,YAAY,CAAC,aAAa,EAAE,CAAC,CAAC;IAC9D,MAAM,CAAC,OAAO,EAAE,UAAU,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAE9C,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,YAAY,IAAC,OAAO,EAAE,YAAY;QAClC,6BAAK,SAAS,EAAC,eAAe;YAC7B,6BAAK,SAAS,EAAC,gBAAgB;gBAC9B,oBAAC,KAAK,IAAC,KAAK,EAAE,CAAC,oBAAuB;gBACtC,oBAAC,iBAAiB,IAAC,KAAK,QAAC,OAAO,QAAC,WAAW,EAAE,WAAW,GAAI,CACxD;YACN,6BAAK,SAAS,EAAC,gBAAgB;gBAC9B,oBAAC,KAAK,IAAC,KAAK,EAAE,CAAC,8BAAiC;gBAChD,oBAAC,iBAAiB,IAAC,WAAW,EAAE,WAAW,GAAI,CAC1C;YACL,OAAO,IAAI,CACX,oBAAC,kBAAkB,IAClB,QAAQ,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,EACjC,YAAY,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,GACpC,CACF,CACI,CACQ,CACf,CAAC,CAAC;IAEH,SAAS,WAAW,CAAC,IAAgB;;QACpC,IAAI,IAAI,CAAC,EAAE,KAAK,GAAG,EAAE;YACpB,YAAY,CAAC,SAAS,CAAC,oBAAC,uBAAuB,IAAC,EAAE,EAAE,IAAI,CAAC,EAAE,GAAI,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC;SAC/E;aAAM;YACN,UAAU,CAAC,IAAI,CAAC,CAAC;SACjB;QACD,MAAA,KAAK,CAAC,WAAW,+CAAjB,KAAK,EAAe,IAAI,CAAC,CAAC;IAC3B,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/MyWorkspaces/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,YAAY,MAAM,qDAAqD,CAAC;AAE/E,OAAO,kBAAkB,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,iBAAiB,MAAM,sBAAsB,CAAC;AACrD,OA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C,CAAC;SAC/E;aAAM;YACN,UAAU,CAAC,IAAI,CAAC,CAAC;SACjB;QACD,MAAA,KAAK,CAAC,WAAW,+CAAjB,KAAK,EAAe,IAAI,CAAC,CAAC;IAC3B,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -3,8 +3,8 @@
3
3
  :global {
4
4
  .my-workSpaces {
5
5
  height: 100%;
6
- display: flex;
7
- flex-direction: column;
6
+ // display: flex;
7
+ // flex-direction: column;
8
8
  .workspace-list {
9
9
  flex: 1;
10
10
  display: flex;
@@ -1,5 +1,6 @@
1
1
  import "./index.less";
2
2
  import { faAcorn, faPlus } from "@fortawesome/pro-light-svg-icons";
3
+ import { Badge } from "@voplus/antd";
3
4
  import Card from "@voplus/morpho-ui/es/controls/Card";
4
5
  import { FontAwesomeIcon as FAIcon } from "@fortawesome/react-fontawesome";
5
6
  import React from "react";
@@ -9,10 +10,14 @@ import { useWorkspace } from "../../../../data/workspace";
9
10
  const WorkspaceCard = (props) => {
10
11
  const { id, active } = props;
11
12
  const workspace = useWorkspace(id, { reload: false });
12
- return observe(() => React.createElement(Card, { className: classnames("workspace-card", { active: active }), padding: "15px 12px", shadow: false, hoverShadow: false },
13
- React.createElement("div", { className: classnames("workspaces-icon", { "new-workspace-icon": !id }) },
14
- React.createElement(FAIcon, { icon: id ? faAcorn : faPlus })),
15
- React.createElement("div", { className: "workspaces-name" }, (workspace === null || workspace === void 0 ? void 0 : workspace.name) || "New WorkSpace")));
13
+ return observe(() => {
14
+ var _a;
15
+ return React.createElement(Card, { className: classnames("workspace-card", { active: active }), padding: "15px 12px", shadow: false, hoverShadow: false },
16
+ React.createElement(Badge, { count: (_a = workspace === null || workspace === void 0 ? void 0 : workspace.stats) === null || _a === void 0 ? void 0 : _a.activeWorks, className: "site-badge-count" }),
17
+ React.createElement("div", { className: classnames("workspaces-icon", { "new-workspace-icon": !id }) },
18
+ React.createElement(FAIcon, { icon: id ? faAcorn : faPlus })),
19
+ React.createElement("div", { className: "workspaces-name" }, (workspace === null || workspace === void 0 ? void 0 : workspace.name) || "New WorkSpace"));
20
+ });
16
21
  };
17
22
  export default WorkspaceCard;
18
23
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspaceCard/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,kCAAkC,CAAC;AAEnE,OAAO,IAAI,MAAM,oCAAoC,CAAC;AACtD,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,UAAU,MAAM,YAAY,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE1D,MAAM,aAAa,GAAG,CAAC,KAItB,EAAE,EAAE;IACJ,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;IAC7B,MAAM,SAAS,GAAG,YAAY,CAAC,EAAG,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC;IAEvD,OAAO,OAAO,CAAC,GAAG,EAAE,CACnB,oBAAC,IAAI,IACJ,SAAS,EAAE,UAAU,CAAC,gBAAgB,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAE3D,OAAO,EAAC,WAAW,EACnB,MAAM,EAAE,KAAK,EACb,WAAW,EAAE,KAAK;QAElB,6BAAK,SAAS,EAAE,UAAU,CAAC,iBAAiB,EAAE,EAAE,oBAAoB,EAAE,CAAC,EAAE,EAAE,CAAC;YAC3E,oBAAC,MAAM,IAAC,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,GAAI,CAClC;QACN,6BAAK,SAAS,EA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CAAC,iBAAiB,EAAE,EAAE,oBAAoB,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC3E,oBAAC,MAAM,IAAC,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,GAAI,CAClC;YACN,6BAAK,SAAS,EAAC,iBAAiB,IAC9B,CAAA,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,IAAI,KAAI,eAAe,CAC9B,CACC,CAAA;KAAA,CACR,CAAA;AACF,CAAC,CAAA;AAED,eAAe,aAAa,CAAC"}
@@ -7,12 +7,24 @@
7
7
  border-radius: 15px;
8
8
  padding: 15px 8px;
9
9
  background: transparent;
10
+ position: relative;
10
11
  &.active {
11
12
  background: #dedbdb57;
12
13
  }
13
14
  &:hover {
14
15
  background: #dedbdb57;
15
16
  }
17
+ .site-badge-count {
18
+ position: absolute;
19
+ vertical-align: middle;
20
+ right: 10px;
21
+ top: 10px;
22
+ .ant-badge-count {
23
+ background-color: #fff;
24
+ color: #999;
25
+ box-shadow: 0 0 0 1px #d9d9d9 inset;
26
+ }
27
+ }
16
28
  .workspaces-icon {
17
29
  width: 80px;
18
30
  height: 80px;
@@ -2,7 +2,6 @@ import "./index.less";
2
2
  import { useWorkspaceListEffect } from "../../../../data/workspace";
3
3
  import { ListDataContext, useCreateListDataState } from "@voplus/morpho-ui/es/data";
4
4
  import React, { useState } from "react";
5
- import InfiniteScrollView from "@voplus/morpho-ui/es/controls/InfiniteScrollView";
6
5
  import WorkspaceCard from "../WorkspaceCard";
7
6
  import { observe } from "@voplus/morpho-ui";
8
7
  import { useApplicationContext } from "@voplus/morpho-data";
@@ -15,10 +14,10 @@ const WorkspaceCardList = (props) => {
15
14
  /** 建立 ListView 和useWorkspaceListEffect所需的ListDataState. 会根据state.id重建所以不需reset. */
16
15
  const list = useCreateListDataState({
17
16
  filterDefaults: {
18
- includes: "tags",
19
17
  filters: props.roles
20
18
  ? [{ c: "Roles", o: "contains", l: "And", v1: 'Member' }]
21
19
  : [],
20
+ page: { Page: 1, PageSize: 200 }
22
21
  },
23
22
  }, [props.roles]);
24
23
  if (props.addCard) {
@@ -33,9 +32,8 @@ const WorkspaceCardList = (props) => {
33
32
  useAutoUpdateListData(list, (d) => true);
34
33
  return observe(() => (React.createElement(ListDataContext.Provider, { value: list },
35
34
  React.createElement("div", { className: "workspace-list-view" },
36
- React.createElement(InfiniteScrollView, { empty: list.isEmpty, loading: list.loading, hasMore: list.hasMore, loadMore: loadMore },
37
- React.createElement("div", { className: "workspace-card-list" }, list.data.map((i) => (React.createElement("div", { key: i.id, onClick: () => onItemClick(i) },
38
- React.createElement(WorkspaceCard, { id: i.id === "0" ? "" : i.id, active: active === i.id }))))))))));
35
+ React.createElement("div", { className: "workspace-card-list" }, list.data.map((i) => (React.createElement("div", { key: i.id, onClick: () => onItemClick(i) },
36
+ React.createElement(WorkspaceCard, { id: i.id === "0" ? "" : i.id, active: active === i.id })))))))));
39
37
  function loadMore() {
40
38
  list.triggerNextPage();
41
39
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspaceCardList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAc,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,eAAe,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AACpF,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,kBAAkB,MAAM,kDAAkD,CAAC;AAClF,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,qBAAqB,EAAE,MAAM,6CAA6C,CAAC;AACpF,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;A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,KAAK,EAAE,IAAI,CAAC,OAAO,EACnB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,QAAQ,EAAE,QAAQ;gBAElB,6BAAK,SAAS,EAAC,qBAAqB,IAC/B,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAClB,6BAAK,GAAG,EAAE,CAAC,CAAC,EAAE,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,WAAW,CAAC,CAAC,CAAC;oBACzC,oBAAC,aAAa,IACV,EAAE,EAAE,CAAC,CAAC,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAC5B,MAAM,EAAE,MAAM,KAAK,CAAC,CAAC,EAAE,GACzB,CACA,CAET,CAAC,CACA,CACW,CACnB,CACiB,CAE9B,CAAC,CAAC;IAEH,SAAS,QAAQ;QACb,IAAI,CAAC,eAAe,EAAE,CAAC;IAC3B,CAAC;IAED,SAAS,WAAW,CAAC,IAAgB;;QACjC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;QAClB,MAAA,KAAK,CAAC,WAAW,+CAAjB,KAAK,EAAe,IAAI,CAAC,CAAC;IAC9B,CAAC;AACL,CAAC,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspaceCardList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAc,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,eAAe,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AACpF,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAGxC,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,mBAA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,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC;IAEzC,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACjB,oBAAC,eAAe,CAAC,QAAQ,IAAC,KAAK,EAAE,IAAI;QACjC,6BAAK,SAAS,EAAC,qBAAqB;YAO5B,6BAAK,SAAS,EAAC,qBAAqB,IAC/B,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAClB,6BAAK,GAAG,EAAE,CAAC,CAAC,EAAE,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,WAAW,CAAC,CAAC,CAAC;gBACzC,oBAAC,aAAa,IACV,EAAE,EAAE,CAAC,CAAC,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAC5B,MAAM,EAAE,MAAM,KAAK,CAAC,CAAC,EAAE,GACzB,CACA,CAET,CAAC,CACA,CAER,CACiB,CAE9B,CAAC,CAAC;IAEH,SAAS,QAAQ;QACb,IAAI,CAAC,eAAe,EAAE,CAAC;IAC3B,CAAC;IAED,SAAS,WAAW,CAAC,IAAgB;;QACjC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;QAClB,MAAA,KAAK,CAAC,WAAW,+CAAjB,KAAK,EAAe,IAAI,CAAC,CAAC;IAC9B,CAAC;AACL,CAAC,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
@@ -1,13 +1,14 @@
1
1
  import "./index.less";
2
2
  import { InlineEdit, observe } from "@voplus/morpho-ui";
3
+ import { Open } from "@voplus/morpho-document/es/controls/ToolBar/buttons";
3
4
  import React, { useEffect, useState } from "react";
4
5
  import { useWorkspace, useWorkspaceStore } from "../../../../data/workspace";
5
6
  import AvatarList from "@voplus/morpho-document/es/components/AvatarList";
6
- import DocumentTabs from "@voplus/morpho-document/es/components/DocumentTabs";
7
7
  import { State } from "./state";
8
- import WorkTypeCardList from "../../../worktype/components/WorkTypeCardList";
8
+ import ToolBar from "@voplus/morpho-document/es/controls/ToolBar/ToolBar2";
9
9
  import WorkspaceCompletedWorksChart from "../../controls/WorkspaceCompletedWorksChart";
10
10
  import WorkspaceMenu from "../../controls/WorkspaceMenu";
11
+ import WorkspaceTabs from "../WorkspaceTabs";
11
12
  import { runInAction } from "mobx";
12
13
  import { useApplicationContext } from "@voplus/morpho-data";
13
14
  import { useDocumentStore } from "@voplus/morpho-document-core";
@@ -28,13 +29,18 @@ const WorkspacePropertiesView = (props) => {
28
29
  React.createElement("div", { className: "workspace-header" },
29
30
  React.createElement("div", { className: "workspace-name" },
30
31
  React.createElement(InlineEdit, { defaultValue: workspace.name, content: (v) => (React.createElement("div", null, workspace.name)), onSave: (value) => state.save(value, workspace.name, { Name: value }) }),
31
- React.createElement(WorkspaceMenu, { id: id, closeAside: true })),
32
+ React.createElement("div", { className: "tools-bar" },
33
+ React.createElement(ToolBar, { id: id, showMenu: false },
34
+ React.createElement(Open, { url: `/workSpace/${id}` }),
35
+ React.createElement(WorkspaceMenu, { id: id, closeAside: true })))),
32
36
  React.createElement(AvatarList, { organizationId: user.info.organizationId, list: state.members, multiple: true, onChange: onChange })),
33
37
  React.createElement(WorkspaceCompletedWorksChart, { id: props.id }),
34
- React.createElement(DocumentTabs, { id: id, detailTitle: "Work Types", isLinks: false, details: React.createElement(WorkTypeCardList, null) }))))));
38
+ React.createElement(WorkspaceTabs, { id: id }))))));
35
39
  async function onChange(ids, members) {
36
40
  await store.edit(id, { data: { MemberIds: ids }, error: "message" });
37
- runInAction(() => { state.members = members; });
41
+ runInAction(() => {
42
+ state.members = members;
43
+ });
38
44
  }
39
45
  };
40
46
  export default WorkspacePropertiesView;
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspacePropertiesView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,UAAU,EAAE,OAAO,E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AC,GAAG,EAAE,GAAG,KAAK,CAAC,OAAO,GAAG,OAAO,CAAA,CAAC,CAAC,CAAC,CAAA;IAClD,CAAC;AACL,CAAC,CAAC;AACF,eAAe,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspacePropertiesView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,IAAI,EAAU,MAAM,qDAAqD,CAAC;AACnF,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAE7E,OAAO,UAAU,MAAM,kDAAkD,CAAC;AAG1E,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,OAAO,MAAM,sDAAsD,CAAC;AAE3E,OAAO,4BAA4B,MAAM,6CAA6C,CAAC;AACvF,OAAO,aAAa,MAAM,8BAA8B,CAAC;AACzD,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAEhE,MAAM,uBAAuB,GAAG,CAAC,KAAqB,EAAE,EAAE;IACtD,MAAM,EAAE,GAAG,KAAK,CAAC,EAAE,CAAC;IAEpB,MAAM,KAAK,GAAG,iBAAiB,EAAE,CAAC;IAClC,MAAM,QAAQ,GAAG,gBAAgB,EAAE,CAAC;IACpC,MAAM,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC,IAAI,KAAK,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC,CAAC;IAC/C,MAAM,EAAE,IAAI,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xC,IAAI,EAAE,KAAK,CAAC,OAAO,EACnB,QAAQ,QACR,QAAQ,EAAE,QAAQ,GACpB,CACA;QACN,oBAAC,4BAA4B,IAAC,EAAE,EAAE,KAAK,CAAC,EAAE,GAAI;QAC9C,oBAAC,aAAa,IAAC,EAAE,EAAE,EAAE,GAAI,CACZ,CACpB,CACC,CACT,CAAC,CAAC;IAEH,KAAK,UAAU,QAAQ,CAAC,GAAa,EAAE,OAAgB;QACnD,MAAM,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;QACrE,WAAW,CAAC,GAAG,EAAE;YACb,KAAK,CAAC,OAAO,GAAG,OAAO,CAAC;QAC5B,CAAC,CAAC,CAAC;IACP,CAAC;AACL,CAAC,CAAC;AACF,eAAe,uBAAuB,CAAC"}
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ declare const WorkspaceTabs: (props: {
3
+ id: string;
4
+ }) => JSX.Element;
5
+ export default WorkspaceTabs;
@@ -0,0 +1,26 @@
1
+ import { Tabs } from "@voplus/antd";
2
+ import React, { useEffect, useState } from "react";
3
+ import ActivityLog from "@voplus/morpho-document/es/components/ActivityLog/ActivityLog2";
4
+ import DocumentList from "@voplus/morpho-document/es/components/DocumentList";
5
+ import SubWorkList from "../../../work/components/SubWorkList";
6
+ import WorkTypeList from "../../../worktype/components/WorkTypeList";
7
+ import { observe } from "@voplus/morpho-ui";
8
+ const WorkspaceTabs = (props) => {
9
+ const { id } = props;
10
+ /**Tabs 当前激活 tab 面板的 key */
11
+ const [activeKey, setActiveKey] = useState("WorkTypes");
12
+ useEffect(() => {
13
+ setActiveKey("WorkTypes");
14
+ }, [props.id]);
15
+ return observe(() => (React.createElement(Tabs, { activeKey: activeKey, className: "work-tabs", onChange: onChange },
16
+ React.createElement(Tabs.TabPane, { tab: "Work Types", key: "WorkTypes" }, activeKey === "WorkTypes" && React.createElement(WorkTypeList, { workspaceId: id })),
17
+ React.createElement(Tabs.TabPane, { tab: "Works", key: "Works" }, activeKey === "Works" && React.createElement(SubWorkList, null)),
18
+ React.createElement(Tabs.TabPane, { tab: "Activities", key: "Activities" }, activeKey === "Activities" && React.createElement(ActivityLog, { id: id })),
19
+ React.createElement(Tabs.TabPane, { tab: "Documents", key: "Documents" }, activeKey === "Documents" && React.createElement(DocumentList, { id: id, multiple: true })))));
20
+ /**切换面板的回调*/
21
+ function onChange(activeKey) {
22
+ setActiveKey(activeKey);
23
+ }
24
+ };
25
+ export default WorkspaceTabs;
26
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/components/WorkspaceTabs/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAS,IAAI,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEnD,OAAO,WAAW,MAAM,gEAAgE,CAAC;AACzF,OAAO,YAAY,MAAM,oDAAoD,CAAC;AAC9E,OAAO,WAAW,MAAM,sCAAsC,CAAC;AAC/D,OAAO,YAAY,MAAM,2CAA2C,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAG5C,MAAM,aAAa,GAAG,CAAC,KAAqB,EAAE,EAAE;IAC/C,MAAM,EAAE,EAAE,EAAE,GAAG,KAAK,CAAC;IACrB,2BAA2B;IAC3B,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,CAAC;IAExD,SAAS,CAAC,GAAG,EAAE;QACd,YAAY,CAAC,WAAW,CAAC,CAAC;IAC3B,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC;IAEf,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,IAAI,IAAC,SAAS,EAAE,SAAS,EAAE,SAAS,EAAC,WAAW,EAAC,QAAQ,EAAE,QAAQ;QACnE,oBAAC,IAAI,CAAC,OAAO,IAAC,GAAG,EAAC,YAAY,EAAC,GAAG,EAAC,WAAW,IAC5C,SAAS,KAAK,WAAW,IAAI,oBAAC,YAAY,IAAC,WAAW,EAAE,EAAE,GAAI,CACjD;QACf,oBAAC,IAAI,CAAC,OAAO,IAAC,GAAG,EAAC,OAAO,EAAC,GAAG,EAAC,OAAO,IACnC,SAAS,KAAK,OAAO,IAAI,oBAAC,WAAW,OAAG,CAC3B;QACf,oBAAC,IAAI,CAAC,OAAO,IAAC,GAAG,EAAC,YAAY,EAAC,GAAG,EAAC,YAAY,IAC7C,SAAS,KAAK,YAAY,IAAI,oBAAC,WAAW,IAAC,EAAE,EAAE,EAAE,GAAI,CACxC;QACf,oBAAC,IAAI,CAAC,OAAO,IAAC,GAAG,EAAC,WAAW,EAAC,GAAG,EAAC,WAAW,IAC3C,SAAS,KAAK,WAAW,IAAI,oBAAC,YAAY,IAAC,EAAE,EAAE,EAAE,EAAE,QAAQ,SAAG,CACjD,CACT,CACP,CAAC,CAAC;IAEH,YAAY;IACZ,SAAS,QAAQ,CAAC,SAAiB;QAClC,YAAY,CAAC,SAAS,CAAC,CAAC;IACzB,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,29 +1,49 @@
1
1
  import "./index.less";
2
2
  import { Button, Dropdown, Modal } from "@voplus/antd";
3
- import { DocumentMenuContext, DocumentMenuState } from "@voplus/morpho-document-core";
4
- import React, { useMemo } from "react";
5
- import { useAsideContentContext } from "@voplus/morpho-ui";
3
+ import { useWorkspace, useWorkspaceStore } from "../../../../data/workspace";
4
+ import React, { useState } from "react";
5
+ import { faTrashAlt, faUserEdit, faUserLock, faUserUnlock } from "@fortawesome/pro-light-svg-icons";
6
+ import { observe, useAsideContentContext } from "@voplus/morpho-ui";
6
7
  import { FontAwesomeIcon as FAIcon } from "@fortawesome/react-fontawesome";
7
8
  import { MoreOutlined } from "@ant-design/icons";
8
- import { faTrashAlt } from "@fortawesome/pro-light-svg-icons";
9
- import { useWorkspaceStore } from "../../.../../../../data/workspace";
9
+ import PermissionModal from "@voplus/morpho-org/es/controls/PermissionModal";
10
+ import classnames from "classnames";
10
11
  const WorksapceMenu = (props) => {
11
- const context = useMemo(() => new DocumentMenuState(props.id), [props.id]);
12
12
  const store = useWorkspaceStore();
13
13
  const asideContext = useAsideContentContext();
14
- return (React.createElement(Dropdown, { placement: "bottomRight", overlay: React.createElement("div", { className: "workspace-menu" },
15
- React.createElement(DocumentMenuContext.Provider, { value: context },
16
- React.createElement(Button, { type: "link", onClick: onClick },
17
- React.createElement(FAIcon, { icon: faTrashAlt, color: "#f5222d" }),
18
- React.createElement("span", { className: "delete" }, "Delete")))) },
19
- React.createElement(Button, { size: "small", shape: "circle" },
20
- React.createElement(MoreOutlined, null))));
14
+ const [visible, setVisible] = useState(false);
15
+ const workspace = useWorkspace(props.id, {
16
+ reload: (i) => !i.actions,
17
+ includes: "actions"
18
+ });
19
+ return observe(() => {
20
+ var _a, _b, _c;
21
+ return (React.createElement(Dropdown, { placement: "bottomRight", overlay: React.createElement("div", { className: classnames("workspace-menu", props.className) },
22
+ ((_a = workspace.actions) === null || _a === void 0 ? void 0 : _a.canDelete) &&
23
+ React.createElement(Button, { type: "link", onClick: onClick },
24
+ React.createElement(FAIcon, { icon: faTrashAlt, color: "#f5222d" }),
25
+ React.createElement("span", { className: "delete" }, "Delete")),
26
+ !((_b = workspace.actions) === null || _b === void 0 ? void 0 : _b.canDelete) && workspace.status === "Active" &&
27
+ React.createElement(Button, { type: "link", onClick: () => onChangeStatus("Disabled") },
28
+ React.createElement(FAIcon, { icon: faUserLock }),
29
+ React.createElement("span", null, "Disabled")),
30
+ !((_c = workspace.actions) === null || _c === void 0 ? void 0 : _c.canDelete) && workspace.status === "Disabled" &&
31
+ React.createElement(Button, { type: "link", onClick: () => onChangeStatus("Enable") },
32
+ React.createElement(FAIcon, { icon: faUserUnlock }),
33
+ React.createElement("span", null, "Enable")),
34
+ React.createElement(Button, { type: "link", onClick: () => setVisible(!visible) },
35
+ React.createElement(FAIcon, { icon: faUserEdit }),
36
+ React.createElement("span", null, "Access")),
37
+ visible && React.createElement(PermissionModal, { id: props.id || "", onChange: () => setVisible(!visible) })) },
38
+ React.createElement(Button, { size: "small", shape: "circle" },
39
+ React.createElement(MoreOutlined, null))));
40
+ });
21
41
  function onClick() {
22
42
  /** 如果文件下有子文件, 询问是否删除所有子文件 */
23
43
  Modal.confirm({
24
44
  title: "Do you want to delete this item?",
25
45
  async onOk() {
26
- await store.delete([context.id], { DeleteChilds: true });
46
+ await store.delete([props.id], { DeleteChilds: true });
27
47
  /** 删除后是否关闭Aside */
28
48
  if (!!props.closeAside && (asideContext === null || asideContext === void 0 ? void 0 : asideContext.asideContent))
29
49
  asideContext === null || asideContext === void 0 ? void 0 : asideContext.closeAside();
@@ -31,6 +51,10 @@ const WorksapceMenu = (props) => {
31
51
  },
32
52
  });
33
53
  }
54
+ /** Disabled/Enable function */
55
+ function onChangeStatus(status) {
56
+ store.edit(props.id, { data: { Status: status }, error: "message" });
57
+ }
34
58
  };
35
59
  export default WorksapceMenu;
36
60
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/controls/WorkspaceMenu/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAetB,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EAAE,mBAAmB,EAAE,iBAAiB,EAAe,MAAM,8BAA8B,CAAC;AACnG,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EAAW,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAEpE,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,MAAM,gC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C,EAAE,EAAE,KAAK,CAAC,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,GAAI,CACpF;YAGP,oBAAC,MAAM,IAAC,IAAI,EAAC,OAAO,EAAC,KAAK,EAAC,QAAQ;gBAClC,oBAAC,YAAY,OAAG,CACR,CACC,CACX,CAAA;KAAA,CAAC,CAAC;IAEH,SAAS,OAAO;QACf,6BAA6B;QAC7B,KAAK,CAAC,OAAO,CAAC;YACb,KAAK,EAAE,kCAAkC;YACzC,KAAK,CAAC,IAAI;gBACT,MAAM,KAAK,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,CAAC,CAAC;gBACvD,mBAAmB;gBACnB,IAAI,CAAC,CAAC,KAAK,CAAC,UAAU,KAAI,YAAY,aAAZ,YAAY,uBAAZ,YAAY,CAAE,YAAY,CAAA;oBAAE,YAAY,aAAZ,YAAY,uBAAZ,YAAY,CAAE,UAAU,EAAE,CAAC;gBACjF,OAAO;YACR,CAAC;SACD,CAAC,CAAC;IACJ,CAAC;IAED,+BAA+B;IAC/B,SAAS,cAAc,CAAC,MAAe;QACtC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAA;IACrE,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -36,7 +36,7 @@ const WorkspaceDefaultView = () => {
36
36
  React.createElement(WorkspaceCompletedWorksChart, { id: id }),
37
37
  React.createElement("h3", null, "Work Types"),
38
38
  React.createElement("div", { className: "my-workSpaces" },
39
- React.createElement(WorkTypeCardList, { type: "card", onItemClick: onItemClick }))))));
39
+ React.createElement(WorkTypeCardList, { onItemClick: onItemClick }))))));
40
40
  async function onChange(ids, members) {
41
41
  await store.edit(id, { data: { MemberIds: ids }, error: "message" });
42
42
  runInAction(() => {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/pages/WorkspaceDefaultView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,EAAgB,aAAa,EAAE,MAAM,cAAc,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAE7E,OAAO,YAAY,MAAM,qDAAqD,CAAC;AAC/E,OAAO,UAAU,MAAM,kDAAkD,CAAC;AAI1E,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,gBAAgB,MAAM,+CAA+C,CAAC;AAC7E,OAAO,sBAAsB,MAAM,qDAAqD,CAAC;AACzF,OAAO,4BAA4B,MAAM,6CAA6C,CAAC;AACvF,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAEhE,MAAM,oBAAoB,GAAG,GAAG,EAAE;IACjC,MAAM,KAAK,GAAG,aAAa,EAAkB,CAAC;IAC9C,MAAM,EAAE,GAAG,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC;IAE3B,MAAM,KAAK,GAAG,iBAAiB,EAAE,CAAC;IAClC,MAAM,QAAQ,GAAG,gBAAgB,EAAE,CAAC;IACpC,MAAM,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC,IAAI,KAAK,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC,CAAC;IAC/C,MAAM,CAAC,YAAY,CAAC,GAAG,QAAQ,CAAC,YAAY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EAAE,CAAC,iCAAM,SAAS,CAAC,IAAI,CAAO,EAC3C,MAAM,EAAE,CAAC,KAAU,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,EAAE,SAAS,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,GACzE,CACG;gBACN,oBAAC,UAAU,IACV,cAAc,EAAE,IAAI,CAAC,IAAI,CAAC,cAAc,EACxC,IAAI,EAAE,KAAK,CAAC,OAAO,EACnB,QAAQ,QACR,QAAQ,EAAE,QAAQ,GACjB,CACG;YACN,oBAAC,4BAA4B,IAAC,EAAE,EAAE,EAAE,GAAI;YACxC,6CAAmB;YAEnB,6BAAK,SAAS,EAAC,eAAe;gBAC7B,oBAAC,gBAAgB,IAAC,WAAW,EAAE,WAAW,GAAI,CACzC,CACD,CACQ,CACf,CAAC,CAAC;IAEH,KAAK,UAAU,QAAQ,CAAC,GAAa,EAAE,OAAgB;QACtD,MAAM,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;QACrE,WAAW,CAAC,GAAG,EAAE;YAChB,KAAK,CAAC,OAAO,GAAG,OAAO,CAAC;QACzB,CAAC,CAAC,CAAC;IACJ,CAAC;IAED,SAAS,WAAW,CAAC,IAAe;QACnC,YAAY,CAAC,SAAS,CAAC,oBAAC,sBAAsB,IAAC,EAAE,EAAE,IAAI,CAAC,EAAE,GAAI,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC;IAC/E,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
@@ -62,7 +62,7 @@ const WorkspacePage = () => {
62
62
  React.createElement(Route, { path: `${match.path}/home/:id` },
63
63
  React.createElement(WorkspaceDefaultView, null)),
64
64
  React.createElement(Route, { path: `${match.path}/document` },
65
- React.createElement(DocumentPage, { root: user.info.folderId })),
65
+ React.createElement(DocumentPage, null)),
66
66
  React.createElement(Route, { path: `${match.path}/workstatus/:status/:active?` },
67
67
  React.createElement(Works, { state: state })),
68
68
  React.createElement(Route, { path: `${match.path}/worktype/:types/:active?` },
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/workspace/pages/WorkspacePage/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,kCAAkC,CAAC;AACjG,OAAO,EAAE,qBAAqB,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEnF,OAAO,YAAY,MAAM,+CAA+C,CAAC;AACzE,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,WAAW,MAAM,oDAAoD,CAAC;AAE7E,OAAO,UAAU,MAAM,yBAAyB,CAAC;AACjD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,OAAO,MAAM,8BAA8B,CAAC;AACnD,OAAO,KAAK,MAAM,kCAAkC,CAAC;AACrD,OAAO,oBAAoB,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE1D,MAAM,aAAa,GAAG,GAAG,EAAE;IAC1B,MAAM,KAAK,GAAG,aAAa,EAAE,CAAC;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AAW,GAAI,EAAE,KAAK,EAAC,cAAc;wBAChF,oBAAC,IAAI,CAAC,IAAI,IAAC,GAAG,EAAC,iBAAiB;;4BACzB,oBAAC,KAAK,IAAC,KAAK,EAAE,CAAC,EAAE,SAAS,EAAC,kBAAkB,GAAG,CAC3C;wBACZ,oBAAC,IAAI,CAAC,IAAI,IAAC,GAAG,EAAC,iBAAiB;;4BACzB,oBAAC,KAAK,IAAC,KAAK,EAAE,CAAC,EAAE,SAAS,EAAC,kBAAkB,GAAG,CAC3C,CACH,CACJ,CACK,CACI;QAElB,oBAAC,MAAM;YACN,oBAAC,KAAK,IAAC,IAAI,EAAE,GAAG,KAAK,CAAC,IAAI,WAAW;gBAEpC,oBAAC,oBAAoB,OAAG,CACjB;YACR,oBAAC,KAAK,IAAC,IAAI,EAAE,GAAG,KAAK,CAAC,IAAI,WAAW;gBAEpC,oBAAC,YAAY,OAAG,CACT;YACR,oBAAC,KAAK,IAAC,IAAI,EAAE,GAAG,KAAK,CAAC,IAAI,8BAA8B;gBAEvD,oBAAC,KAAK,IAAC,KAAK,EAAE,KAAK,GAAI,CAChB;YACR,oBAAC,KAAK,IAAC,IAAI,EAAE,GAAG,KAAK,CAAC,IAAI,2BAA2B;gBAEpD,oBAAC,KAAK,IAAC,KAAK,EAAE,KAAK,GAAI,CAChB;YACR,oBAAC,QAAQ,IAAC,EAAE,EAAE,GAAG,KAAK,CAAC,IAAI,OAAO,GAAI,CAC9B,CACI,CACd,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ import "./index.less";
3
+ declare const NewTypeForm: (props: {
4
+ workspaceId: string;
5
+ className?: string | undefined;
6
+ block?: boolean | undefined;
7
+ onSave?: ((params?: any) => void) | undefined;
8
+ onCancel?: (() => void) | undefined;
9
+ }) => JSX.Element;
10
+ export default NewTypeForm;
@@ -0,0 +1,42 @@
1
+ import React, { useState } from "react";
2
+ import { observe } from "@voplus/morpho-ui";
3
+ import { runInAction } from "mobx";
4
+ import { Input, Spin, message } from "@voplus/antd";
5
+ import { State } from "./state";
6
+ import { useWorkTypeStore } from "../../../../data/worktype";
7
+ import "./index.less";
8
+ const NewTypeForm = (props) => {
9
+ const worktype = useWorkTypeStore();
10
+ const [state] = useState(new State({ workspaceId: props.workspaceId }));
11
+ return observe(() => (React.createElement("div", { className: "new-work-type" },
12
+ React.createElement(Spin, { spinning: !!state.loading },
13
+ 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)), onPressEnter: () => onSubmit(), onKeyDown: onKeyDown })))));
14
+ async function onSubmit() {
15
+ var _a;
16
+ if (!state.params.Name)
17
+ return message.warning("Title is required");
18
+ runInAction(() => (state.loading = true));
19
+ const res = await worktype.create({
20
+ data: { ...state.params, workspaceId: props.workspaceId },
21
+ error: "message",
22
+ });
23
+ (_a = props.onSave) === null || _a === void 0 ? void 0 : _a.call(props);
24
+ runInAction(() => {
25
+ state.loading = false;
26
+ state.params = state.Params;
27
+ });
28
+ }
29
+ function onKeyDown(e) {
30
+ if (e.keyCode !== 27)
31
+ return;
32
+ onCancel();
33
+ }
34
+ // cancel add task
35
+ function onCancel() {
36
+ state.params = state.Params;
37
+ if (props.onCancel)
38
+ props.onCancel();
39
+ }
40
+ };
41
+ export default NewTypeForm;
42
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/worktype/components/NewTypeForm/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,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAO,KAAK,EAAO,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;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EAAE;YACzD,KAAK,EAAE,SAAS;SAChB,CAAC,CAAC;QACH,MAAA,KAAK,CAAC,MAAM,+CAAZ,KAAK,CAAW,CAAC;QACjB,WAAW,CAAC,GAAG,EAAE;YAChB,KAAK,CAAC,OAAO,GAAG,KAAK,CAAC;YACtB,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;QAC7B,CAAC,CAAC,CAAC;IACJ,CAAC;IACD,SAAS,SAAS,CAAC,CAAM;QACxB,IAAI,CAAC,CAAC,OAAO,KAAK,EAAE;YAAE,OAAO;QAC7B,QAAQ,EAAE,CAAC;IACZ,CAAC;IACD,kBAAkB;IAClB,SAAS,QAAQ;QAChB,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;QAC5B,IAAI,KAAK,CAAC,QAAQ;YAAE,KAAK,CAAC,QAAQ,EAAE,CAAC;IACtC,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -0,0 +1,8 @@
1
+ @import "../../../../style/common.less";
2
+ @import "~@voplus/antd/es/style/themes/default.less";
3
+
4
+ :global {
5
+ .new-work-type {
6
+ padding: 10px 20px;
7
+ }
8
+ }
@@ -0,0 +1,11 @@
1
+ export declare class State {
2
+ private _store;
3
+ constructor(_store: any);
4
+ Params: {
5
+ Name: string;
6
+ };
7
+ params: {
8
+ Name: string;
9
+ };
10
+ loading: boolean;
11
+ }
@@ -0,0 +1,41 @@
1
+ import { __decorate } from "tslib";
2
+ import { makeObservable, observable } from "mobx";
3
+ export class State {
4
+ constructor(_store) {
5
+ Object.defineProperty(this, "_store", {
6
+ enumerable: true,
7
+ configurable: true,
8
+ writable: true,
9
+ value: _store
10
+ });
11
+ Object.defineProperty(this, "Params", {
12
+ enumerable: true,
13
+ configurable: true,
14
+ writable: true,
15
+ value: {
16
+ // workspaceId: "",
17
+ Name: ""
18
+ }
19
+ });
20
+ Object.defineProperty(this, "params", {
21
+ enumerable: true,
22
+ configurable: true,
23
+ writable: true,
24
+ value: this.Params
25
+ });
26
+ Object.defineProperty(this, "loading", {
27
+ enumerable: true,
28
+ configurable: true,
29
+ writable: true,
30
+ value: false
31
+ });
32
+ makeObservable(this);
33
+ }
34
+ }
35
+ __decorate([
36
+ observable
37
+ ], State.prototype, "params", void 0);
38
+ __decorate([
39
+ observable
40
+ ], State.prototype, "loading", void 0);
41
+ //# sourceMappingURL=state.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/modules/worktype/components/NewTypeForm/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,MAAM,OAAO,KAAK;IACjB,YAA2B,MAAW;;;;;mBAAX;;QAG3B;;;;mBAAgB;gBACf,mBAAmB;gBACnB,IAAI,EAAE,EAAE;aACR;WAAC;QACU;;;;mBAAgB,IAAI,CAAC,MAAM;WAAC;QAC5B;;;;mBAAiB,KAAK;WAAC;QAPlC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;CAOD;AAFY;IAAX,UAAU;qCAA6B;AAC5B;IAAX,UAAU;sCAAwB"}
@@ -2,15 +2,8 @@
2
2
  import "./index.less";
3
3
  import { IWorkType } from "../../../../data/worktype";
4
4
  /** A worktype list view shows worktype in card style. */
5
- declare const WorkTypeCardList: {
6
- (props: {
7
- /** 设置work type item类型,默认值default */
8
- type?: "default" | "card" | undefined;
9
- /** item onclick */
10
- onItemClick?: ((item: IWorkType) => void) | undefined;
11
- }): JSX.Element;
12
- defaultProps: {
13
- type: string;
14
- };
15
- };
5
+ declare const WorkTypeCardList: (props: {
6
+ /** item onclick */
7
+ onItemClick?: ((item: IWorkType) => void) | undefined;
8
+ }) => JSX.Element;
16
9
  export default WorkTypeCardList;