@voplus/morpho-workspace 1.0.0-dev73 → 1.0.0-mobx01
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.
- package/changelog.md +68 -0
- package/es/Modules.js +16 -7
- package/es/Modules.js.map +1 -1
- package/es/components/AssignPeople/index.js +7 -6
- package/es/components/AssignPeople/index.js.map +1 -1
- package/es/components/TimeLog/index.d.ts +1 -1
- package/es/components/TimeLog/index.js +7 -6
- package/es/components/TimeLog/index.js.map +1 -1
- package/es/controls/AssignButton/index.d.ts +9 -0
- package/es/controls/AssignButton/index.js +19 -0
- package/es/controls/AssignButton/index.js.map +1 -0
- package/es/controls/Corner/index.d.ts +9 -0
- package/es/controls/Corner/index.js +10 -0
- package/es/controls/Corner/index.js.map +1 -0
- package/es/controls/Corner/index.less +7 -0
- package/es/controls/MoreOperateDropdown/index.d.ts +1 -1
- package/es/controls/MoreOperateDropdown/index.js +14 -13
- package/es/controls/MoreOperateDropdown/index.js.map +1 -1
- package/es/controls/StickyAddButton/index.d.ts +10 -0
- package/es/controls/StickyAddButton/index.js +14 -0
- package/es/controls/StickyAddButton/index.js.map +1 -0
- package/es/controls/StickyAddButton/index.less +21 -0
- package/es/controls/filters/AssigneeViewFilter/index.d.ts +4 -0
- package/es/controls/filters/AssigneeViewFilter/index.js +48 -0
- package/es/controls/filters/AssigneeViewFilter/index.js.map +1 -0
- package/es/controls/filters/AssigneeViewFilter/index.less +24 -0
- package/es/controls/filters/AssigneeViewFilter/state.d.ts +13 -0
- package/es/controls/filters/AssigneeViewFilter/state.js +44 -0
- package/es/controls/filters/AssigneeViewFilter/state.js.map +1 -0
- package/es/controls/filters/DueDateFilter/index.d.ts +3 -0
- package/es/controls/filters/DueDateFilter/index.js +22 -0
- package/es/controls/filters/DueDateFilter/index.js.map +1 -0
- package/es/controls/filters/DueDateFilter/state.d.ts +11 -0
- package/es/controls/filters/DueDateFilter/state.js +39 -0
- package/es/controls/filters/DueDateFilter/state.js.map +1 -0
- package/es/controls/filters/StartDateFilter/index.d.ts +10 -0
- package/es/controls/filters/StartDateFilter/index.js +25 -0
- package/es/controls/filters/StartDateFilter/index.js.map +1 -0
- package/es/controls/filters/StartDateFilter/state.d.ts +11 -0
- package/es/controls/filters/StartDateFilter/state.js +39 -0
- package/es/controls/filters/StartDateFilter/state.js.map +1 -0
- package/es/controls/filters/TaskStatusFilter/index.d.ts +3 -0
- package/es/controls/filters/TaskStatusFilter/index.js +21 -0
- package/es/controls/filters/TaskStatusFilter/index.js.map +1 -0
- package/es/controls/filters/TaskStatusFilter/state.d.ts +17 -0
- package/es/controls/filters/TaskStatusFilter/state.js +47 -0
- package/es/controls/filters/TaskStatusFilter/state.js.map +1 -0
- package/es/controls/filters/index.d.ts +4 -0
- package/es/controls/filters/index.js +5 -0
- package/es/controls/filters/index.js.map +1 -0
- package/es/data/board/BoardColumnStore.d.ts +3 -13
- package/es/data/board/BoardColumnStore.js +9 -26
- package/es/data/board/BoardColumnStore.js.map +1 -1
- package/es/data/board/BoardStore.d.ts +2 -12
- package/es/data/board/BoardStore.js +8 -25
- package/es/data/board/BoardStore.js.map +1 -1
- package/es/data/board/contexts/BoardListContextState/index.d.ts +17 -0
- package/es/data/board/contexts/BoardListContextState/index.js +38 -0
- package/es/data/board/contexts/BoardListContextState/index.js.map +1 -0
- package/es/data/board/hooks.d.ts +2 -2
- package/es/data/board/hooks.js +4 -4
- package/es/data/board/hooks.js.map +1 -1
- package/es/data/board/index.d.ts +1 -1
- package/es/data/board/index.js +3 -1
- package/es/data/board/index.js.map +1 -1
- package/es/data/board/interfaces.d.ts +2 -2
- package/es/data/board/interfaces.js +1 -0
- package/es/data/board/metas.d.ts +3 -1
- package/es/data/board/metas.js +11 -3
- package/es/data/board/metas.js.map +1 -1
- package/es/data/board/mock.js +8 -29
- package/es/data/board/mock.js.map +1 -1
- package/es/data/board/types.js +1 -0
- package/es/data/calendar/CalendarStore.d.ts +47 -0
- package/es/data/calendar/CalendarStore.js +98 -0
- package/es/data/calendar/CalendarStore.js.map +1 -0
- package/es/data/calendar/hooks.d.ts +11 -0
- package/es/data/calendar/hooks.js +22 -0
- package/es/data/calendar/hooks.js.map +1 -0
- package/es/data/calendar/index.d.ts +3 -0
- package/es/data/calendar/index.js +4 -0
- package/es/data/calendar/index.js.map +1 -0
- package/es/data/calendar/interfaces.d.ts +11 -0
- package/es/data/calendar/interfaces.js +2 -0
- package/es/data/calendar/interfaces.js.map +1 -0
- package/es/data/calendar/mock.d.ts +2 -0
- package/es/data/calendar/mock.js +26 -0
- package/es/data/calendar/mock.js.map +1 -0
- package/es/data/meeting/AgendaStore.d.ts +2 -5
- package/es/data/meeting/AgendaStore.js +8 -15
- package/es/data/meeting/AgendaStore.js.map +1 -1
- package/es/data/meeting/MeetingStore.d.ts +5 -5
- package/es/data/meeting/MeetingStore.js +24 -11
- package/es/data/meeting/MeetingStore.js.map +1 -1
- package/es/data/meeting/hooks.d.ts +7 -4
- package/es/data/meeting/hooks.js +11 -6
- package/es/data/meeting/hooks.js.map +1 -1
- package/es/data/meeting/index.js +2 -0
- package/es/data/meeting/index.js.map +1 -1
- package/es/data/meeting/interfaces.d.ts +15 -1
- package/es/data/meeting/interfaces.js +1 -0
- package/es/data/meeting/metas.d.ts +11 -2
- package/es/data/meeting/metas.js +38 -7
- package/es/data/meeting/metas.js.map +1 -1
- package/es/data/meeting/types.d.ts +1 -1
- package/es/data/meeting/types.js +1 -0
- package/es/data/reports/useEstimatedTimeEffect.d.ts +13 -0
- package/es/data/reports/useEstimatedTimeEffect.js +16 -0
- package/es/data/reports/useEstimatedTimeEffect.js.map +1 -0
- package/es/data/reports/useTaskSummaryEffect.d.ts +12 -0
- package/es/data/reports/useTaskSummaryEffect.js +26 -0
- package/es/data/reports/useTaskSummaryEffect.js.map +1 -0
- package/es/data/task/TaskStore.d.ts +2 -12
- package/es/data/task/TaskStore.js +8 -25
- package/es/data/task/TaskStore.js.map +1 -1
- package/es/data/task/hooks.d.ts +3 -2
- package/es/data/task/hooks.js +5 -5
- package/es/data/task/hooks.js.map +1 -1
- package/es/data/task/index.js +2 -0
- package/es/data/task/index.js.map +1 -1
- package/es/data/task/interfaces.d.ts +4 -2
- package/es/data/task/interfaces.js +1 -0
- package/es/data/task/metas.d.ts +3 -1
- package/es/data/task/metas.js +12 -4
- package/es/data/task/metas.js.map +1 -1
- package/es/data/task/types.js +1 -0
- package/es/modules/board/BoardRouets.js +5 -5
- package/es/modules/board/components/Board/index.js +54 -54
- package/es/modules/board/components/Board/index.js.map +1 -1
- package/es/modules/board/components/Board/index.less +83 -51
- package/es/modules/board/components/Board/state.d.ts +25 -5
- package/es/modules/board/components/Board/state.js +249 -50
- package/es/modules/board/components/Board/state.js.map +1 -1
- package/es/modules/board/components/BoardColumn/index.js +27 -43
- package/es/modules/board/components/BoardColumn/index.js.map +1 -1
- package/es/modules/board/components/BoardColumn/index.less +26 -16
- package/es/modules/board/components/BoardColumn/state.d.ts +26 -18
- package/es/modules/board/components/BoardColumn/state.js +202 -65
- package/es/modules/board/components/BoardColumn/state.js.map +1 -1
- package/es/modules/board/components/BoardPropertiesView/index.d.ts +7 -0
- package/es/modules/board/components/BoardPropertiesView/index.js +35 -0
- package/es/modules/board/components/BoardPropertiesView/index.js.map +1 -0
- package/es/modules/board/components/BoardPropertiesView/index.less +12 -0
- package/es/modules/board/components/SubDocument/index.d.ts +13 -0
- package/es/modules/board/components/SubDocument/index.js +13 -0
- package/es/modules/board/components/SubDocument/index.js.map +1 -0
- package/es/modules/board/components/SubDocumentList/index.d.ts +6 -0
- package/es/modules/board/components/SubDocumentList/index.js +161 -0
- package/es/modules/board/components/SubDocumentList/index.js.map +1 -0
- package/es/modules/board/components/SubDocumentList/index.less +28 -0
- package/es/modules/board/components/SubDocumentList/state.d.ts +25 -0
- package/es/modules/board/components/SubDocumentList/state.js +68 -0
- package/es/modules/board/components/SubDocumentList/state.js.map +1 -0
- package/es/modules/board/pages/BoardViewList/index.js +25 -14
- package/es/modules/board/pages/BoardViewList/index.js.map +1 -1
- package/es/modules/board/pages/BoardViewList/state.d.ts +1 -1
- package/es/modules/board/pages/BoardViewList/state.js +8 -5
- package/es/modules/board/pages/BoardViewList/state.js.map +1 -1
- package/es/modules/calendar/CalendarRoutes.js +5 -5
- package/es/modules/calendar/CalendarRoutes.js.map +1 -1
- package/es/modules/calendar/components/ActionCard/index.d.ts +7 -0
- package/es/modules/calendar/components/ActionCard/index.js +12 -0
- package/es/modules/calendar/components/ActionCard/index.js.map +1 -0
- package/es/modules/calendar/components/CalendarEventContent/index.d.ts +7 -0
- package/es/modules/calendar/components/CalendarEventContent/index.js +10 -0
- package/es/modules/calendar/components/CalendarEventContent/index.js.map +1 -0
- package/es/modules/calendar/components/CalendarMenu/index.d.ts +1 -1
- package/es/modules/calendar/components/CalendarMenu/index.js +4 -3
- package/es/modules/calendar/components/CalendarMenu/index.js.map +1 -1
- package/es/modules/calendar/pages/CalendarMonth/index.d.ts +0 -4
- package/es/modules/calendar/pages/CalendarMonth/index.js +86 -165
- package/es/modules/calendar/pages/CalendarMonth/index.js.map +1 -1
- package/es/modules/calendar/pages/CalendarMonth/index.less +194 -142
- package/es/modules/calendar/pages/CalendarMonth/state.d.ts +10 -1
- package/es/modules/calendar/pages/CalendarMonth/state.js +46 -4
- package/es/modules/calendar/pages/CalendarMonth/state.js.map +1 -1
- package/es/modules/meeting/MeetingRoutes.d.ts +4 -2
- package/es/modules/meeting/MeetingRoutes.js +17 -17
- package/es/modules/meeting/MeetingRoutes.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaHeader/index.d.ts +2 -2
- package/es/modules/meeting/components/AgendaList/AgendaHeader/index.js +3 -2
- package/es/modules/meeting/components/AgendaList/AgendaHeader/index.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskList/index.js +20 -23
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskList/index.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskList/state.d.ts +7 -5
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskList/state.js +97 -31
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskList/state.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/index.js +38 -76
- package/es/modules/meeting/components/AgendaList/AgendaItem/index.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/index.less +35 -69
- package/es/modules/meeting/components/AgendaList/AgendaItem/state.d.ts +3 -2
- package/es/modules/meeting/components/AgendaList/AgendaItem/state.js +72 -16
- package/es/modules/meeting/components/AgendaList/AgendaItem/state.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/index.js +14 -31
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/index.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/index.less +2 -2
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/state.d.ts +7 -0
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/state.js +84 -5
- package/es/modules/meeting/components/AgendaList/AgendaNewForm/state.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/index.js +52 -48
- package/es/modules/meeting/components/AgendaList/index.js.map +1 -1
- package/es/modules/meeting/components/AgendaList/state.d.ts +3 -21
- package/es/modules/meeting/components/AgendaList/state.js +22 -71
- package/es/modules/meeting/components/AgendaList/state.js.map +1 -1
- package/es/modules/meeting/components/MeetingDescription/index.d.ts +0 -1
- package/es/modules/meeting/components/MeetingDescription/index.js +10 -21
- package/es/modules/meeting/components/MeetingDescription/index.js.map +1 -1
- package/es/modules/meeting/components/MeetingHeader/index.d.ts +2 -4
- package/es/modules/meeting/components/MeetingHeader/index.js +70 -88
- package/es/modules/meeting/components/MeetingHeader/index.js.map +1 -1
- package/es/modules/meeting/components/MeetingHeader/index.less +5 -22
- package/es/modules/meeting/components/MeetingItem/index.d.ts +4 -1
- package/es/modules/meeting/components/MeetingItem/index.js +50 -30
- package/es/modules/meeting/components/MeetingItem/index.js.map +1 -1
- package/es/modules/meeting/components/MeetingItem/index.less +48 -41
- package/es/modules/meeting/components/MeetingItem/state.d.ts +5 -2
- package/es/modules/meeting/components/MeetingItem/state.js +40 -7
- package/es/modules/meeting/components/MeetingItem/state.js.map +1 -1
- package/es/modules/meeting/components/MeetingList/index.d.ts +11 -0
- package/es/modules/meeting/components/MeetingList/index.js +53 -0
- package/es/modules/meeting/components/MeetingList/index.js.map +1 -0
- package/es/modules/meeting/components/MeetingPropertiesView/index.js +4 -8
- package/es/modules/meeting/components/MeetingPropertiesView/index.js.map +1 -1
- package/es/modules/meeting/components/MeetingPropertiesView/index.less +1 -1
- package/es/modules/meeting/components/MeetingQuickViewDialog/index.d.ts +3 -2
- package/es/modules/meeting/components/MeetingQuickViewDialog/index.js +11 -4
- package/es/modules/meeting/components/MeetingQuickViewDialog/index.js.map +1 -1
- package/es/modules/meeting/components/MeetingQuickViewDialog/index.less +7 -0
- package/es/modules/meeting/components/MeetingTaskList/index.d.ts +6 -0
- package/es/modules/meeting/components/MeetingTaskList/index.js +22 -0
- package/es/modules/meeting/components/MeetingTaskList/index.js.map +1 -0
- package/es/modules/meeting/components/MeetingTaskList/index.less +30 -0
- package/es/modules/meeting/components/MeetingsFolderProperitesView/index.d.ts +6 -0
- package/es/modules/meeting/components/MeetingsFolderProperitesView/index.js +34 -0
- package/es/modules/meeting/components/MeetingsFolderProperitesView/index.js.map +1 -0
- package/es/modules/meeting/components/MeetingsFolderProperitesView/index.less +8 -0
- package/es/modules/meeting/components/MeetingsFolderQuickViewDialog/index.d.ts +8 -0
- package/es/modules/meeting/components/MeetingsFolderQuickViewDialog/index.js +31 -0
- package/es/modules/meeting/components/MeetingsFolderQuickViewDialog/index.js.map +1 -0
- package/es/modules/meeting/components/MeetingsFolderQuickViewDialog/index.less +7 -0
- package/es/modules/meeting/components/NewMeetingForm/index.d.ts +7 -1
- package/es/modules/meeting/components/NewMeetingForm/index.js +66 -90
- package/es/modules/meeting/components/NewMeetingForm/index.js.map +1 -1
- package/es/modules/meeting/components/NewMeetingForm/index.less +9 -0
- package/es/modules/meeting/components/NewMeetingForm/state.d.ts +3 -0
- package/es/modules/meeting/components/NewMeetingForm/state.js +46 -13
- package/es/modules/meeting/components/NewMeetingForm/state.js.map +1 -1
- package/es/modules/meeting/controls/MeetingTasksProgressDataIcon/index.d.ts +17 -0
- package/es/modules/meeting/controls/MeetingTasksProgressDataIcon/index.js +24 -0
- package/es/modules/meeting/controls/MeetingTasksProgressDataIcon/index.js.map +1 -0
- package/es/modules/meeting/controls/MeetingTasksProgressDataIcon/index.less +7 -0
- package/es/modules/meeting/pages/MeetingListView/index.d.ts +5 -0
- package/es/modules/meeting/pages/MeetingListView/index.js +19 -0
- package/es/modules/meeting/pages/MeetingListView/index.js.map +1 -0
- package/es/modules/meeting/pages/MeetingPrintView/index.js +19 -18
- package/es/modules/meeting/pages/MeetingPrintView/index.js.map +1 -1
- package/es/modules/meeting/pages/MeetingTabView/index.js +16 -21
- package/es/modules/meeting/pages/MeetingTabView/index.js.map +1 -1
- package/es/modules/member/components/MemberDropdown.js +3 -2
- package/es/modules/member/components/MemberDropdown.js.map +1 -1
- package/es/modules/member/components/MemberList.js +4 -4
- package/es/modules/member/components/MemberList.js.map +1 -1
- package/es/modules/member/pages/MemberListView/index.js +29 -28
- package/es/modules/member/pages/MemberListView/index.js.map +1 -1
- package/es/modules/menus/components/Access/index.d.ts +2 -2
- 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.d.ts +2 -2
- 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/AddUsers/index.js +11 -15
- package/es/modules/menus/components/AddUsers/index.js.map +1 -1
- package/es/modules/menus/components/Status/index.d.ts +2 -2
- 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/components/UsersList/index.js +22 -21
- package/es/modules/menus/components/UsersList/index.js.map +1 -1
- package/es/modules/menus/pages/ListOptions/Company/index.d.ts +2 -2
- package/es/modules/menus/pages/ListOptions/Company/index.js +52 -54
- package/es/modules/menus/pages/ListOptions/Company/index.js.map +1 -1
- package/es/modules/menus/pages/ListOptions/Teams/index.js +18 -15
- package/es/modules/menus/pages/ListOptions/Teams/index.js.map +1 -1
- package/es/modules/menus/pages/ListOptions/Users/index.js +4 -3
- package/es/modules/menus/pages/ListOptions/Users/index.js.map +1 -1
- package/es/modules/menus/pages/ListOptions/index.js +16 -15
- package/es/modules/menus/pages/ListOptions/index.js.map +1 -1
- package/es/modules/tasks/TasksRoutes.d.ts +3 -1
- package/es/modules/tasks/TasksRoutes.js +6 -6
- package/es/modules/tasks/TasksRoutes.js.map +1 -1
- package/es/modules/tasks/components/NewTaskForm/index.js +64 -60
- package/es/modules/tasks/components/NewTaskForm/index.js.map +1 -1
- package/es/modules/tasks/components/NewTaskForm/index.less +24 -39
- package/es/modules/tasks/components/NewTaskForm/state.js +41 -15
- package/es/modules/tasks/components/NewTaskForm/state.js.map +1 -1
- package/es/modules/tasks/components/SubTaskList/index.d.ts +1 -0
- package/es/modules/tasks/components/SubTaskList/index.js +113 -61
- package/es/modules/tasks/components/SubTaskList/index.js.map +1 -1
- package/es/modules/tasks/components/SubTaskList/index.less +16 -0
- package/es/modules/tasks/components/SubTaskList/state.d.ts +12 -17
- package/es/modules/tasks/components/SubTaskList/state.js +58 -54
- package/es/modules/tasks/components/SubTaskList/state.js.map +1 -1
- package/es/modules/tasks/components/TaskDescription/index.d.ts +1 -1
- package/es/modules/tasks/components/TaskDescription/index.js +8 -11
- package/es/modules/tasks/components/TaskDescription/index.js.map +1 -1
- package/es/modules/tasks/components/TaskEstimatedTime/index.d.ts +12 -0
- package/es/modules/tasks/components/TaskEstimatedTime/index.js +74 -0
- package/es/modules/tasks/components/TaskEstimatedTime/index.js.map +1 -0
- package/es/modules/tasks/components/{TaskTimeBox → TaskEstimatedTime}/state.d.ts +18 -6
- package/es/modules/tasks/components/TaskEstimatedTime/state.js +159 -0
- package/es/modules/tasks/components/TaskEstimatedTime/state.js.map +1 -0
- package/es/modules/tasks/components/TaskItem/DefaultTaskItem.js +47 -29
- package/es/modules/tasks/components/TaskItem/DefaultTaskItem.js.map +1 -1
- package/es/modules/tasks/components/TaskItem/SubTaskItem.js +47 -41
- package/es/modules/tasks/components/TaskItem/SubTaskItem.js.map +1 -1
- package/es/modules/tasks/components/TaskItem/defaultTaskItem.less +30 -33
- package/es/modules/tasks/components/TaskItem/state.d.ts +20 -17
- package/es/modules/tasks/components/TaskItem/state.js +160 -88
- package/es/modules/tasks/components/TaskItem/state.js.map +1 -1
- package/es/modules/tasks/components/TaskItem/subTaskItem.less +48 -106
- package/es/modules/tasks/components/TaskPropertiesView/index.d.ts +1 -1
- package/es/modules/tasks/components/TaskPropertiesView/index.js +61 -16
- package/es/modules/tasks/components/TaskPropertiesView/index.js.map +1 -1
- package/es/modules/tasks/components/TaskPropertiesView/index.less +6 -0
- package/es/modules/tasks/components/TaskQuickViewDialog/index.d.ts +2 -2
- package/es/modules/tasks/components/TaskQuickViewDialog/index.js +68 -5
- package/es/modules/tasks/components/TaskQuickViewDialog/index.js.map +1 -1
- package/es/modules/tasks/components/TaskQuickViewDialog/index.less +12 -6
- package/es/modules/tasks/pages/TaskList/index.d.ts +3 -1
- package/es/modules/tasks/pages/TaskList/index.js +55 -97
- package/es/modules/tasks/pages/TaskList/index.js.map +1 -1
- package/es/modules/tasks/pages/TaskTabView/index.js +82 -25
- package/es/modules/tasks/pages/TaskTabView/index.js.map +1 -1
- package/es/modules/tasks/pages/TaskTabView/index.less +22 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/index.d.ts +6 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/index.js +41 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/index.js.map +1 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/index.less +21 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/state.d.ts +22 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/state.js +148 -0
- package/es/modules/tasks/reports/MemberEstimatedDurationCard/state.js.map +1 -0
- package/es/modules/tasks/reports/TaskAnalyticsDataIcon/index.d.ts +7 -0
- package/es/modules/tasks/reports/TaskAnalyticsDataIcon/index.js +17 -0
- package/es/modules/tasks/reports/TaskAnalyticsDataIcon/index.js.map +1 -0
- package/es/modules/tasks/reports/TaskAnalyticsDataIcon/index.less +8 -0
- package/es/modules/tasks/reports/TaskSummaryCard/index.d.ts +17 -0
- package/es/modules/tasks/reports/TaskSummaryCard/index.js +67 -0
- package/es/modules/tasks/reports/TaskSummaryCard/index.js.map +1 -0
- package/es/modules/tasks/reports/TaskSummaryCard/index.less +20 -0
- package/es/modules/tasks/reports/TaskSummaryCard/state.d.ts +11 -0
- package/es/modules/tasks/reports/TaskSummaryCard/state.js +54 -0
- package/es/modules/tasks/reports/TaskSummaryCard/state.js.map +1 -0
- package/es/modules/user/pages/Positions/index.js +19 -18
- package/es/modules/user/pages/Positions/index.js.map +1 -1
- package/es/modules/workspaces/components/Access/index.d.ts +2 -2
- package/es/modules/workspaces/components/Access/index.js +5 -4
- package/es/modules/workspaces/components/Access/index.js.map +1 -1
- package/es/modules/workspaces/components/Account/index.d.ts +2 -2
- package/es/modules/workspaces/components/Account/index.js +5 -4
- package/es/modules/workspaces/components/Account/index.js.map +1 -1
- package/es/modules/workspaces/components/AddUsers/index.js +11 -15
- package/es/modules/workspaces/components/AddUsers/index.js.map +1 -1
- package/es/modules/workspaces/components/ListHeard/index.d.ts +1 -1
- package/es/modules/workspaces/components/ListHeard/index.js +5 -4
- package/es/modules/workspaces/components/ListHeard/index.js.map +1 -1
- package/es/modules/workspaces/components/Status/index.d.ts +2 -2
- package/es/modules/workspaces/components/Status/index.js +5 -4
- package/es/modules/workspaces/components/Status/index.js.map +1 -1
- package/es/modules/workspaces/components/UsersList/index.js +22 -21
- package/es/modules/workspaces/components/UsersList/index.js.map +1 -1
- package/es/modules/workspaces/pages/BoardView/index.js +20 -17
- package/es/modules/workspaces/pages/BoardView/index.js.map +1 -1
- package/es/modules/workspaces/pages/ListView/index.js +17 -14
- package/es/modules/workspaces/pages/ListView/index.js.map +1 -1
- package/es/modules/workspaces/pages/Users/index.js +5 -4
- package/es/modules/workspaces/pages/Users/index.js.map +1 -1
- package/es/pages/Project/ProjectDefaultView/index.d.ts +3 -0
- package/es/pages/Project/ProjectDefaultView/index.js +65 -0
- package/es/pages/Project/ProjectDefaultView/index.js.map +1 -0
- package/es/pages/Project/ProjectDefaultView/index.less +22 -0
- package/es/pages/Project/data/ProjectStore.d.ts +10 -0
- package/es/pages/Project/data/ProjectStore.js +21 -0
- package/es/pages/Project/data/ProjectStore.js.map +1 -0
- package/es/pages/Project/data/hook.d.ts +9 -0
- package/es/pages/Project/data/hook.js +20 -0
- package/es/pages/Project/data/hook.js.map +1 -0
- package/es/pages/Project/data/index.d.ts +3 -0
- package/es/pages/Project/data/index.js +4 -0
- package/es/pages/Project/data/index.js.map +1 -0
- package/es/pages/Project/data/interfaces.d.ts +2 -0
- package/es/pages/Project/data/interfaces.js +2 -0
- package/es/pages/Project/data/interfaces.js.map +1 -0
- package/es/pages/Routes.d.ts +29 -0
- package/es/pages/Routes.js +64 -0
- package/es/pages/Routes.js.map +1 -0
- package/es/pages/Space/components/Documents/index.d.ts +6 -0
- package/es/pages/Space/components/Documents/index.js +41 -0
- package/es/pages/Space/components/Documents/index.js.map +1 -0
- package/es/pages/Space/components/Documents/index.less +9 -0
- package/es/pages/Space/components/Notes/ColorSelect/index.d.ts +10 -0
- package/es/pages/Space/components/Notes/ColorSelect/index.js +30 -0
- package/es/pages/Space/components/Notes/ColorSelect/index.js.map +1 -0
- package/es/pages/Space/components/Notes/ColorSelect/index.less +17 -0
- package/es/pages/Space/components/Notes/NewNoteDialog/index.d.ts +10 -0
- package/es/pages/Space/components/Notes/NewNoteDialog/index.js +41 -0
- package/es/pages/Space/components/Notes/NewNoteDialog/index.js.map +1 -0
- package/es/pages/Space/components/Notes/NewNoteDialog/index.less +63 -0
- package/es/pages/Space/components/Notes/TextNoteCard/index.d.ts +6 -0
- package/es/pages/Space/components/Notes/TextNoteCard/index.js +34 -0
- package/es/pages/Space/components/Notes/TextNoteCard/index.js.map +1 -0
- package/es/pages/Space/components/Notes/TextNoteCard/index.less +56 -0
- package/es/pages/Space/components/Notes/TextNoteCard/state.d.ts +6 -0
- package/es/pages/Space/components/Notes/TextNoteCard/state.js +35 -0
- package/es/pages/Space/components/Notes/TextNoteCard/state.js.map +1 -0
- package/es/pages/Space/components/Notes/index.d.ts +5 -0
- package/es/pages/Space/components/Notes/index.js +51 -0
- package/es/pages/Space/components/Notes/index.js.map +1 -0
- package/es/pages/Space/components/Projects/index.d.ts +5 -0
- package/es/pages/Space/components/Projects/index.js +35 -0
- package/es/pages/Space/components/Projects/index.js.map +1 -0
- package/es/pages/Space/components/Tasks/index.d.ts +7 -0
- package/es/pages/Space/components/Tasks/index.js +43 -0
- package/es/pages/Space/components/Tasks/index.js.map +1 -0
- package/es/pages/Space/components/Tasks/index.less +17 -0
- package/es/pages/Space/components/Works/index.d.ts +6 -0
- package/es/pages/Space/components/Works/index.js +43 -0
- package/es/pages/Space/components/Works/index.js.map +1 -0
- package/es/pages/Space/components/Works/index.less +18 -0
- package/es/pages/Space/pages/MySpace/index.d.ts +4 -0
- package/es/pages/Space/pages/MySpace/index.js +47 -0
- package/es/pages/Space/pages/MySpace/index.js.map +1 -0
- package/es/pages/Space/pages/MySpace/index.less +60 -0
- package/es/pages/Space/pages/MySpace/state.d.ts +12 -0
- package/es/pages/Space/pages/MySpace/state.js +61 -0
- package/es/pages/Space/pages/MySpace/state.js.map +1 -0
- package/es/pages/Work/components/NewWorkDialog/index.d.ts +11 -0
- package/es/pages/Work/components/NewWorkDialog/index.js +45 -0
- package/es/pages/Work/components/NewWorkDialog/index.js.map +1 -0
- package/es/pages/Work/components/NewWorkDialog/index.less +11 -0
- package/es/pages/Work/components/WorkCheckList/index.d.ts +5 -0
- package/es/pages/Work/components/WorkCheckList/index.js +38 -0
- package/es/pages/Work/components/WorkCheckList/index.js.map +1 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkActionsCard/index.d.ts +6 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkActionsCard/index.js +21 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkActionsCard/index.js.map +1 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkBlockingsCard/index.d.ts +5 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkBlockingsCard/index.js +11 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkBlockingsCard/index.js.map +1 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkDueCard/index.d.ts +7 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkDueCard/index.js +16 -0
- package/es/pages/Work/components/WorkSummaryCards/WorkDueCard/index.js.map +1 -0
- package/es/pages/Work/components/WorkSummaryCards/index.d.ts +5 -0
- package/es/pages/Work/components/WorkSummaryCards/index.js +69 -0
- package/es/pages/Work/components/WorkSummaryCards/index.js.map +1 -0
- package/es/pages/Work/components/WorkSummaryCards/index.less +35 -0
- package/es/pages/Work/components/WorkSummaryCards/state.d.ts +11 -0
- package/es/pages/Work/components/WorkSummaryCards/state.js +47 -0
- package/es/pages/Work/components/WorkSummaryCards/state.js.map +1 -0
- package/es/pages/Work/components/WorkTrail/index.d.ts +5 -0
- package/es/pages/Work/components/WorkTrail/index.js +14 -0
- package/es/pages/Work/components/WorkTrail/index.js.map +1 -0
- package/es/pages/Work/components/WorkTrail/index.less +20 -0
- package/es/pages/Work/data/WorkStore.d.ts +10 -0
- package/es/pages/Work/data/WorkStore.js +21 -0
- package/es/pages/Work/data/WorkStore.js.map +1 -0
- package/es/pages/Work/data/hook.d.ts +3 -0
- package/es/pages/Work/data/hook.js +10 -0
- package/es/pages/Work/data/hook.js.map +1 -0
- package/es/pages/Work/data/index.d.ts +3 -0
- package/es/pages/Work/data/index.js +4 -0
- package/es/pages/Work/data/index.js.map +1 -0
- package/es/pages/Work/data/interfaces.d.ts +14 -0
- package/es/pages/Work/data/interfaces.js +2 -0
- package/es/pages/Work/data/interfaces.js.map +1 -0
- package/es/pages/Work/pages/WorkDefaultView/index.d.ts +3 -0
- package/es/pages/Work/pages/WorkDefaultView/index.js +58 -0
- package/es/pages/Work/pages/WorkDefaultView/index.js.map +1 -0
- package/es/pages/Work/pages/WorkDefaultView/index.less +12 -0
- package/es/pages/Work/pages/WorkDefaultView/state.d.ts +5 -0
- package/es/pages/Work/pages/WorkDefaultView/state.js +18 -0
- package/es/pages/Work/pages/WorkDefaultView/state.js.map +1 -0
- package/es/pages/WorkType/WorkTypeCheckList/index.d.ts +5 -0
- package/es/pages/WorkType/WorkTypeCheckList/index.js +38 -0
- package/es/pages/WorkType/WorkTypeCheckList/index.js.map +1 -0
- package/es/pages/WorkType/WorkTypeDefaultView/index.d.ts +3 -0
- package/es/pages/WorkType/WorkTypeDefaultView/index.js +19 -0
- package/es/pages/WorkType/WorkTypeDefaultView/index.js.map +1 -0
- package/es/pages/WorkType/WorkTypeDetail/index.d.ts +6 -0
- package/es/pages/WorkType/WorkTypeDetail/index.js +88 -0
- package/es/pages/WorkType/WorkTypeDetail/index.js.map +1 -0
- package/es/pages/WorkType/WorkTypeDetail/index.less +35 -0
- package/es/pages/WorkType/WorkTypeDetail/state.d.ts +9 -0
- package/es/pages/WorkType/WorkTypeDetail/state.js +38 -0
- package/es/pages/WorkType/WorkTypeDetail/state.js.map +1 -0
- package/es/pages/WorkType/WorkTypePropertiesView/index.d.ts +5 -0
- package/es/pages/WorkType/WorkTypePropertiesView/index.js +32 -0
- package/es/pages/WorkType/WorkTypePropertiesView/index.js.map +1 -0
- package/es/pages/WorkType/WorkTypePropertiesView/index.less +31 -0
- package/es/pages/WorkType/WorkTypeSelect/index.d.ts +7 -0
- package/es/pages/WorkType/WorkTypeSelect/index.js +18 -0
- package/es/pages/WorkType/WorkTypeSelect/index.js.map +1 -0
- package/es/pages/WorkType/data/WorkTypeStore.d.ts +21 -0
- package/es/pages/WorkType/data/WorkTypeStore.js +75 -0
- package/es/pages/WorkType/data/WorkTypeStore.js.map +1 -0
- package/es/pages/WorkType/data/hook.d.ts +9 -0
- package/es/pages/WorkType/data/hook.js +19 -0
- package/es/pages/WorkType/data/hook.js.map +1 -0
- package/es/pages/WorkType/data/index.d.ts +4 -0
- package/es/pages/WorkType/data/index.js +5 -0
- package/es/pages/WorkType/data/index.js.map +1 -0
- package/es/pages/WorkType/data/interfaces.d.ts +35 -0
- package/es/pages/WorkType/data/interfaces.js +2 -0
- package/es/pages/WorkType/data/interfaces.js.map +1 -0
- package/es/pages/WorkType/data/types.d.ts +41 -0
- package/es/pages/WorkType/data/types.js +2 -0
- package/es/pages/WorkType/data/types.js.map +1 -0
- package/es/routes.js +6 -2
- package/es/routes.js.map +1 -1
- package/es/style/common.less +3 -0
- package/package.json +27 -32
- package/es/components/AssignPeople/index.less +0 -0
- package/es/components/AvatarList/index.d.ts +0 -19
- package/es/components/AvatarList/index.js +0 -124
- package/es/components/AvatarList/index.js.map +0 -1
- package/es/components/AvatarList/index.less +0 -72
- package/es/components/AvatarList/state.d.ts +0 -25
- package/es/components/AvatarList/state.js +0 -52
- package/es/components/AvatarList/state.js.map +0 -1
- package/es/components/PermissionModal/index.d.ts +0 -7
- package/es/components/PermissionModal/index.js +0 -18
- package/es/components/PermissionModal/index.js.map +0 -1
- package/es/components/PermissionModal/index.less +0 -7
- package/es/components/ToolBar/index.d.ts +0 -46
- package/es/components/ToolBar/index.js +0 -72
- package/es/components/ToolBar/index.js.map +0 -1
- package/es/components/ToolBar/index.less +0 -18
- package/es/components/ToolBar/state.d.ts +0 -9
- package/es/components/ToolBar/state.js +0 -23
- package/es/components/ToolBar/state.js.map +0 -1
- package/es/components/VersionsModal/index.d.ts +0 -5
- package/es/components/VersionsModal/index.js +0 -20
- package/es/components/VersionsModal/index.js.map +0 -1
- package/es/components/VersionsModal/index.less +0 -19
- package/es/components/VersionsModal/state.d.ts +0 -4
- package/es/components/VersionsModal/state.js +0 -12
- package/es/components/VersionsModal/state.js.map +0 -1
- package/es/controls/DocumentStatusLabel/index.d.ts +0 -14
- package/es/controls/DocumentStatusLabel/index.js +0 -41
- package/es/controls/DocumentStatusLabel/index.js.map +0 -1
- package/es/controls/DocumentStatusLabel/index.less +0 -45
- package/es/controls/FlagIcon/index.d.ts +0 -17
- package/es/controls/FlagIcon/index.js +0 -58
- package/es/controls/FlagIcon/index.js.map +0 -1
- package/es/controls/FlagIcon/index.less +0 -21
- package/es/controls/IconNumbers/index.d.ts +0 -18
- package/es/controls/IconNumbers/index.js +0 -31
- package/es/controls/IconNumbers/index.js.map +0 -1
- package/es/controls/IconNumbers/index.less +0 -10
- package/es/data/board/LinkStore.d.ts +0 -11
- package/es/data/board/LinkStore.js +0 -40
- package/es/data/board/LinkStore.js.map +0 -1
- package/es/modules/board/components/DocumentCard/index.d.ts +0 -10
- package/es/modules/board/components/DocumentCard/index.js +0 -111
- package/es/modules/board/components/DocumentCard/index.js.map +0 -1
- package/es/modules/board/components/DocumentCard/index.less +0 -116
- package/es/modules/board/components/DocumentCard/state.d.ts +0 -15
- package/es/modules/board/components/DocumentCard/state.js +0 -54
- package/es/modules/board/components/DocumentCard/state.js.map +0 -1
- package/es/modules/board/components/LinkList/index.d.ts +0 -4
- package/es/modules/board/components/LinkList/index.js +0 -38
- package/es/modules/board/components/LinkList/index.js.map +0 -1
- package/es/modules/board/components/LinkList/state.d.ts +0 -15
- package/es/modules/board/components/LinkList/state.js +0 -33
- package/es/modules/board/components/LinkList/state.js.map +0 -1
- package/es/modules/board/components/NewTaskForm/index.d.ts +0 -11
- package/es/modules/board/components/NewTaskForm/index.js +0 -85
- package/es/modules/board/components/NewTaskForm/index.js.map +0 -1
- package/es/modules/board/components/NewTaskForm/index.less +0 -102
- package/es/modules/board/components/NewTaskForm/state.d.ts +0 -25
- package/es/modules/board/components/NewTaskForm/state.js +0 -41
- package/es/modules/board/components/NewTaskForm/state.js.map +0 -1
- package/es/modules/board/components/TaskCard/index.d.ts +0 -4
- package/es/modules/board/components/TaskCard/index.js +0 -97
- package/es/modules/board/components/TaskCard/index.js.map +0 -1
- package/es/modules/board/components/TaskCard/index.less +0 -115
- package/es/modules/board/components/TaskCard/state.d.ts +0 -44
- package/es/modules/board/components/TaskCard/state.js +0 -119
- package/es/modules/board/components/TaskCard/state.js.map +0 -1
- package/es/modules/board/components/links/index.d.ts +0 -12
- package/es/modules/board/components/links/index.js +0 -26
- package/es/modules/board/components/links/index.js.map +0 -1
- package/es/modules/calendar/components/TaskCard/index.d.ts +0 -7
- package/es/modules/calendar/components/TaskCard/index.js +0 -25
- package/es/modules/calendar/components/TaskCard/index.js.map +0 -1
- package/es/modules/calendar/components/TaskCard/index.less +0 -64
- package/es/modules/calendar/components/TaskCard/state.d.ts +0 -16
- package/es/modules/calendar/components/TaskCard/state.js +0 -58
- package/es/modules/calendar/components/TaskCard/state.js.map +0 -1
- package/es/modules/calendar/pages/CalendarWeek/index.d.ts +0 -0
- package/es/modules/calendar/pages/CalendarWeek/index.js +0 -1
- package/es/modules/calendar/pages/CalendarWeek/index.js.map +0 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskItem/index.d.ts +0 -7
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskItem/index.js +0 -37
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskItem/index.js.map +0 -1
- package/es/modules/meeting/components/AgendaList/AgendaItem/components/TaskItem/index.less +0 -57
- package/es/modules/meeting/pages/MeetingList/index.d.ts +0 -3
- package/es/modules/meeting/pages/MeetingList/index.js +0 -40
- package/es/modules/meeting/pages/MeetingList/index.js.map +0 -1
- package/es/modules/meeting/pages/MeetingList/state.d.ts +0 -14
- package/es/modules/meeting/pages/MeetingList/state.js +0 -44
- package/es/modules/meeting/pages/MeetingList/state.js.map +0 -1
- package/es/modules/tasks/components/TaskHeader/index.d.ts +0 -13
- package/es/modules/tasks/components/TaskHeader/index.js +0 -43
- package/es/modules/tasks/components/TaskHeader/index.js.map +0 -1
- package/es/modules/tasks/components/TaskHeader/index.less +0 -51
- package/es/modules/tasks/components/TaskTimeBox/index.d.ts +0 -16
- package/es/modules/tasks/components/TaskTimeBox/index.js +0 -62
- package/es/modules/tasks/components/TaskTimeBox/index.js.map +0 -1
- package/es/modules/tasks/components/TaskTimeBox/state.js +0 -76
- package/es/modules/tasks/components/TaskTimeBox/state.js.map +0 -1
- package/es/modules/tasks/pages/TaskList/state.d.ts +0 -10
- package/es/modules/tasks/pages/TaskList/state.js +0 -31
- package/es/modules/tasks/pages/TaskList/state.js.map +0 -1
- /package/es/modules/tasks/components/{TaskTimeBox → TaskEstimatedTime}/index.less +0 -0
@@ -0,0 +1,18 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable } from "mobx";
|
3
|
+
export class State {
|
4
|
+
constructor() {
|
5
|
+
/** Enable of new Text */
|
6
|
+
Object.defineProperty(this, "reload", {
|
7
|
+
enumerable: true,
|
8
|
+
configurable: true,
|
9
|
+
writable: true,
|
10
|
+
value: true
|
11
|
+
});
|
12
|
+
makeObservable(this);
|
13
|
+
}
|
14
|
+
}
|
15
|
+
__decorate([
|
16
|
+
observable
|
17
|
+
], State.prototype, "reload", void 0);
|
18
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../../src/pages/Work/pages/WorkDefaultView/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,MAAM,OAAO,KAAK;IAIjB;QAHA,0BAA0B;QACd;;;;mBAAgB,IAAI;WAAC;QAGhC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;CACD;AALY;IAAX,UAAU;qCAAsB"}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import { useWorkType, useWorkTypeStore } from "../data";
|
2
|
+
import CheckList from "@voplus/morpho-ui/es/controls/CheckList";
|
3
|
+
import React from "react";
|
4
|
+
import { observe } from "@voplus/morpho-ui";
|
5
|
+
const WorkTypeCheckList = (props) => {
|
6
|
+
const { id } = props;
|
7
|
+
const workType = useWorkType(id);
|
8
|
+
const workTypeStore = useWorkTypeStore();
|
9
|
+
return observe(() => (React.createElement(CheckList, { list: workType.checkList || [], allowAdd: true, moveAfter: moveAfter, onChange: onChange, onCreate: onCreate, onDelete: onDelete })));
|
10
|
+
/** Add a check item */
|
11
|
+
function onCreate(item) {
|
12
|
+
onSave([{ item, checked: false }, ...(workType.checkList || [])]);
|
13
|
+
}
|
14
|
+
/** change check item */
|
15
|
+
function onChange(checkItem) {
|
16
|
+
const { id, item, checked } = checkItem;
|
17
|
+
const checkList = workType.checkList || [];
|
18
|
+
checkList.splice(id, 1, { item, checked });
|
19
|
+
onSave(checkList);
|
20
|
+
}
|
21
|
+
/** delete check item */
|
22
|
+
function onDelete(checkItem) {
|
23
|
+
const checkList = workType.checkList || [];
|
24
|
+
checkList.splice(checkItem.id, 1);
|
25
|
+
onSave(checkList);
|
26
|
+
}
|
27
|
+
/** sort checkList */
|
28
|
+
function moveAfter(id, afterId, checkList) {
|
29
|
+
onSave(checkList);
|
30
|
+
}
|
31
|
+
/** update WorkTypeCheckList */
|
32
|
+
async function onSave(checkList) {
|
33
|
+
const CheckList = checkList.map((c) => ({ Item: c.item, Checked: c.checked }));
|
34
|
+
await workTypeStore.edit(id, { data: { CheckList }, error: "message" });
|
35
|
+
}
|
36
|
+
};
|
37
|
+
export default WorkTypeCheckList;
|
38
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypeCheckList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,gBAAgB,E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C;QAC3C,SAAS,CAAC,MAAM,CAAC,SAAS,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC;QAClC,MAAM,CAAC,SAAS,CAAC,CAAC;IACnB,CAAC;IACD,qBAAqB;IACrB,SAAS,SAAS,CACjB,EAAU,EACV,OAAe,EACf,SAA2D;QAE3D,MAAM,CAAC,SAAS,CAAC,CAAC;IACnB,CAAC;IACD,+BAA+B;IAC/B,KAAK,UAAU,MAAM,CAAC,SAA+C;QACpE,MAAM,SAAS,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;QAC/E,MAAM,aAAa,CAAC,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;IACzE,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import React, { useEffect } from "react";
|
2
|
+
import WorkTypePropertiesView from "../WorkTypePropertiesView";
|
3
|
+
import { observe } from "@voplus/morpho-ui";
|
4
|
+
import { runInAction } from "mobx";
|
5
|
+
import { useRouteMatch } from "react-router";
|
6
|
+
import { useTabItem } from "@voplus/morpho-data";
|
7
|
+
import { useWorkType } from "../data";
|
8
|
+
const WorkTypeDefaultView = () => {
|
9
|
+
const match = useRouteMatch();
|
10
|
+
const id = match.params.id;
|
11
|
+
const serviceType = useWorkType(id);
|
12
|
+
const tab = useTabItem();
|
13
|
+
useEffect(() => {
|
14
|
+
runInAction(() => (tab.title = serviceType.name));
|
15
|
+
}, [serviceType === null || serviceType === void 0 ? void 0 : serviceType.name]);
|
16
|
+
return observe(() => React.createElement(WorkTypePropertiesView, { id: id }));
|
17
|
+
};
|
18
|
+
export default WorkTypeDefaultView;
|
19
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypeDefaultView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzC,OAAO,sBAAsB,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEtC,MAAM,mBAAmB,GAAG,GAAG,EAAE;IAChC,MAAM,KAAK,GAAG,aAAa,EAAkB,CAAC;IAC9C,MAAM,EAAE,GAAG,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC;IAE3B,MAAM,WAAW,GAAG,WAAW,CAAC,EAAE,CAAC,CAAC;IACpC,MAAM,GAAG,GAAG,UAAU,EAAE,CAAC;IAEzB,SAAS,CAAC,GAAG,EAAE;QACd,WAAW,CAAC,GAAG,EAAE,CAAC,CAAC,GAAG,CAAC,KAAK,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;IACnD,CAAC,EAAE,CAAC,WAAW,aAAX,WAAW,uBAAX,WAAW,CAAE,IAAI,CAAC,CAAC,CAAC;IAExB,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,oBAAC,sBAAsB,IAAC,EAAE,EAAE,EAAE,GAAI,CAAC,CAAC;AAC1D,CAAC,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
@@ -0,0 +1,88 @@
|
|
1
|
+
import "./index.less";
|
2
|
+
import { Button, Checkbox, InputNumber, Skeleton } from "@voplus/antd";
|
3
|
+
import React, { useState } from "react";
|
4
|
+
import { useApplicationContext, useLayout } from "@voplus/morpho-data";
|
5
|
+
import { useWorkType, useWorkTypeStore } from "../data";
|
6
|
+
import ActionPlan from "@voplus/morpho-collaboration-action/es/components/Action/ActionPlan";
|
7
|
+
import AvatarList from "@voplus/morpho-document/es/components/AvatarList";
|
8
|
+
import DescriptionEditor from "@voplus/morpho-document/es/controls/DescriptionEditor";
|
9
|
+
import { State } from "./state";
|
10
|
+
import WorkTypeCheckList from "../WorkTypeCheckList";
|
11
|
+
import { observe } from "@voplus/morpho-ui";
|
12
|
+
import { runInAction } from "mobx";
|
13
|
+
const WorkTypeDetail = (props) => {
|
14
|
+
const id = props.id;
|
15
|
+
const layout = useLayout();
|
16
|
+
const { user } = useApplicationContext();
|
17
|
+
const workTypeStore = useWorkTypeStore();
|
18
|
+
const [state] = useState(new State());
|
19
|
+
const workType = useWorkType(id);
|
20
|
+
runInAction(() => {
|
21
|
+
var _a, _b, _c, _d;
|
22
|
+
state.audit = ((_a = workType.audit) === null || _a === void 0 ? void 0 : _a.audit) || false;
|
23
|
+
state.auditRate = ((_b = workType.audit) === null || _b === void 0 ? void 0 : _b.auditRate) || 0;
|
24
|
+
state.auditorIds = [];
|
25
|
+
(_d = (_c = workType.audit) === null || _c === void 0 ? void 0 : _c.auditors) === null || _d === void 0 ? void 0 : _d.map((i) => state.auditorIds.push(i.id));
|
26
|
+
});
|
27
|
+
return observe(() => {
|
28
|
+
var _a;
|
29
|
+
return (React.createElement("div", { className: "work-type-detail" }, workType.loading ? (React.createElement("div", { className: "document-description" },
|
30
|
+
React.createElement(Skeleton, { active: true }))) : (React.createElement(React.Fragment, null,
|
31
|
+
React.createElement(DescriptionEditor, { id: id, description: workType.description, padding: "0 0 10px 0", onSave: editDescription }),
|
32
|
+
React.createElement("div", { className: "work-perSon" },
|
33
|
+
React.createElement("div", { className: "work-perSon-title" }, "PerSon in charge"),
|
34
|
+
React.createElement(AvatarList, { organizationId: user.info.organizationId, list: workType.members || [], onChange: editMemberIds })),
|
35
|
+
React.createElement("div", { className: "work-request-form" },
|
36
|
+
React.createElement("div", { className: "work-title" }, workType.newFormSchemaId ? (React.createElement(React.Fragment, null, "Request Form")) : (React.createElement(Checkbox, { onChange: editRequestForm }, "Request Form"))),
|
37
|
+
workType.newFormSchemaId && (React.createElement(Button, { size: "middle", block: true, className: "work-btn", onClick: () => runInAction(() => layout.history.push(`/design/${workType.newFormSchemaId}`)) }, "Design Request Form"))),
|
38
|
+
React.createElement("div", { className: "work-audit" },
|
39
|
+
React.createElement("div", { className: "work-title" },
|
40
|
+
React.createElement(Checkbox, { checked: state.audit, onChange: (e) => {
|
41
|
+
runInAction(() => (state.audit = e.target.checked));
|
42
|
+
editAudit();
|
43
|
+
} }, "Audit")),
|
44
|
+
state.audit && (React.createElement("div", { className: "work-audit-content" },
|
45
|
+
React.createElement("div", { className: "work-audit-info" },
|
46
|
+
React.createElement("span", { className: "label" }, "Audit Rate"),
|
47
|
+
React.createElement(InputNumber, { value: state.auditRate, min: 0, max: 100, formatter: (value) => `${value}%`, parser: (value) => value.replace("%", ""), onChange: (value) => {
|
48
|
+
runInAction(() => (state.auditRate = value));
|
49
|
+
editAudit();
|
50
|
+
} })),
|
51
|
+
React.createElement("div", { className: "work-audit-info" },
|
52
|
+
React.createElement("span", { className: "label" }, "Auditor"),
|
53
|
+
React.createElement(AvatarList, { organizationId: user.info.organizationId, list: ((_a = workType.audit) === null || _a === void 0 ? void 0 : _a.auditors) || [], onChange: async (ids) => {
|
54
|
+
runInAction(() => (state.auditorIds = ids));
|
55
|
+
await editAudit();
|
56
|
+
} }))))),
|
57
|
+
React.createElement(WorkTypeCheckList, { id: id }),
|
58
|
+
React.createElement(ActionPlan, { id: id })))));
|
59
|
+
});
|
60
|
+
/** edit description */
|
61
|
+
function editDescription(description) {
|
62
|
+
workTypeStore.edit(id, {
|
63
|
+
data: {
|
64
|
+
Description: description || "",
|
65
|
+
},
|
66
|
+
error: "message",
|
67
|
+
});
|
68
|
+
}
|
69
|
+
/** edit Audit */
|
70
|
+
async function editAudit() {
|
71
|
+
await workTypeStore.edit(id, {
|
72
|
+
data: {
|
73
|
+
Audit: { Audit: state.audit, AuditRate: state.auditRate, AuditorIds: state.auditorIds },
|
74
|
+
},
|
75
|
+
error: "message",
|
76
|
+
});
|
77
|
+
}
|
78
|
+
/** edit MemberIds */
|
79
|
+
async function editMemberIds(ids) {
|
80
|
+
await workTypeStore.edit(id, { data: { MemberIds: ids }, error: "message" });
|
81
|
+
}
|
82
|
+
/** edit Request Form */
|
83
|
+
function editRequestForm(e) {
|
84
|
+
workTypeStore.edit(id, { data: { CreateForm: e.target.checked }, error: "message" });
|
85
|
+
}
|
86
|
+
};
|
87
|
+
export default WorkTypeDetail;
|
88
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypeDetail/index.tsx"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAC;AAEtB,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACvE,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AACvE,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAExD,OAAO,UAAU,MAAM,qEAAqE,CAAC;AAC7F,OAAO,UAAU,MAAM,kDAAkD,CAAC;AAC1E,OAAO,iBAAiB,MAAM,uDAAuD,CAAC;AACtF,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,iBAAiB,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AAEnC,MAAM,cAAc,GAAG,CAAC,KAAqB,EA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AE;gBACL,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,SAAS,EAAE,KAAK,CAAC,SAAS,EAAE,UAAU,EAAE,KAAK,CAAC,UAAU,EAAE;aACvF;YACD,KAAK,EAAE,SAAS;SAChB,CAAC,CAAC;IACJ,CAAC;IACD,qBAAqB;IACrB,KAAK,UAAU,aAAa,CAAC,GAAa;QACzC,MAAM,aAAa,CAAC,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;IAC9E,CAAC;IACD,wBAAwB;IACxB,SAAS,eAAe,CAAC,CAAM;QAC9B,aAAa,CAAC,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,UAAU,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;IACtF,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
:global {
|
2
|
+
.work-type-detail {
|
3
|
+
height: 100%;
|
4
|
+
.work-title {
|
5
|
+
padding: 10px 0;
|
6
|
+
border-bottom: 1px solid #f2f2f2;
|
7
|
+
}
|
8
|
+
.work-perSon {
|
9
|
+
padding: 0 20px;
|
10
|
+
.work-perSon-title {
|
11
|
+
padding: 10px 0;
|
12
|
+
}
|
13
|
+
}
|
14
|
+
.work-request-form {
|
15
|
+
padding: 0 20px;
|
16
|
+
.work-btn {
|
17
|
+
margin-top: 10px;
|
18
|
+
}
|
19
|
+
}
|
20
|
+
.work-audit {
|
21
|
+
padding: 0 20px;
|
22
|
+
.work-audit-content {
|
23
|
+
margin-top: 10px;
|
24
|
+
.work-audit-info {
|
25
|
+
display: flex;
|
26
|
+
padding-bottom: 20px;
|
27
|
+
.label {
|
28
|
+
display: inline-block;
|
29
|
+
width: 200px;
|
30
|
+
}
|
31
|
+
}
|
32
|
+
}
|
33
|
+
}
|
34
|
+
}
|
35
|
+
}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import { __decorate } from "tslib";
|
2
|
+
import { makeObservable, observable } from "mobx";
|
3
|
+
export class State {
|
4
|
+
constructor() {
|
5
|
+
/** Audit Audit of the work type */
|
6
|
+
Object.defineProperty(this, "audit", {
|
7
|
+
enumerable: true,
|
8
|
+
configurable: true,
|
9
|
+
writable: true,
|
10
|
+
value: false
|
11
|
+
});
|
12
|
+
/** Audit AuditRate of the work type */
|
13
|
+
Object.defineProperty(this, "auditRate", {
|
14
|
+
enumerable: true,
|
15
|
+
configurable: true,
|
16
|
+
writable: true,
|
17
|
+
value: 0
|
18
|
+
});
|
19
|
+
/** Audit AuditorIds of the work type */
|
20
|
+
Object.defineProperty(this, "auditorIds", {
|
21
|
+
enumerable: true,
|
22
|
+
configurable: true,
|
23
|
+
writable: true,
|
24
|
+
value: void 0
|
25
|
+
});
|
26
|
+
makeObservable(this);
|
27
|
+
}
|
28
|
+
}
|
29
|
+
__decorate([
|
30
|
+
observable
|
31
|
+
], State.prototype, "audit", void 0);
|
32
|
+
__decorate([
|
33
|
+
observable
|
34
|
+
], State.prototype, "auditRate", void 0);
|
35
|
+
__decorate([
|
36
|
+
observable
|
37
|
+
], State.prototype, "auditorIds", void 0);
|
38
|
+
//# sourceMappingURL=state.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"state.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypeDetail/state.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAElD,MAAM,OAAO,KAAK;IAUjB;QATA,mCAAmC;QACvB;;;;mBAAe,KAAK;WAAC;QAEjC,uCAAuC;QAC3B;;;;mBAAmB,CAAC;WAAC;QAEjC,wCAAwC;QAC5B;;;;;WAA4B;QAGvC,cAAc,CAAC,IAAI,CAAC,CAAC;IACtB,CAAC;CACD;AAXY;IAAX,UAAU;oCAAsB;AAGrB;IAAX,UAAU;wCAAsB;AAGrB;IAAX,UAAU;yCAA6B"}
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import React, { useRef } from "react";
|
2
|
+
import { useWorkType, useWorkTypeStore } from "../data";
|
3
|
+
import { InlineEdit } from "@voplus/morpho-ui";
|
4
|
+
import { Scrollbars } from "react-custom-scrollbars";
|
5
|
+
import WorkTypeDetail from "../WorkTypeDetail";
|
6
|
+
import classnames from "classnames";
|
7
|
+
import { observe } from "@voplus/morpho-ui";
|
8
|
+
import styles from "./index.less";
|
9
|
+
import { useIsStickyActive } from "@voplus/morpho-ui";
|
10
|
+
const WorkTypePropertiesView = (props) => {
|
11
|
+
const id = props.id;
|
12
|
+
const workType = useWorkType(id, { reload: true });
|
13
|
+
const workTypeStore = useWorkTypeStore();
|
14
|
+
/** Document Head Sticky Top
|
15
|
+
Sticky 时显示shadow */
|
16
|
+
const element = useRef(null);
|
17
|
+
useIsStickyActive({ stickyOn: true, element });
|
18
|
+
return observe(() => (React.createElement("div", { className: styles["work-type-default-view"] },
|
19
|
+
React.createElement(Scrollbars, { autoHide: true, className: "scroll-bars" },
|
20
|
+
React.createElement("div", { className: classnames("work-type-header", { sticky: true }), ref: element },
|
21
|
+
React.createElement(InlineEdit, { defaultValue: workType.name, content: (v) => React.createElement(React.Fragment, null, v.store.value || workType.name), onSave: (v) => v &&
|
22
|
+
v !== workType.name &&
|
23
|
+
workTypeStore.edit(id, {
|
24
|
+
data: {
|
25
|
+
Name: v,
|
26
|
+
},
|
27
|
+
error: "message",
|
28
|
+
}) })),
|
29
|
+
React.createElement(WorkTypeDetail, { id: id })))));
|
30
|
+
};
|
31
|
+
export default WorkTypePropertiesView;
|
32
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypePropertiesView/index.tsx"],"names":[],"mappings":"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AAC,CAAC,KAAK,CAAC,KAAK,IAAI,QAAQ,CAAC,IAAI,CAAkB,EACjF,MAAM,EAAE,CAAC,CAAC,EAAE,EAAE,CACb,CAAC;wBACD,CAAC,KAAK,QAAQ,CAAC,IAAI;wBACnB,aAAa,CAAC,IAAI,CAAC,EAAE,EAAE;4BACtB,IAAI,EAAE;gCACL,IAAI,EAAE,CAAC;6BACP;4BACD,KAAK,EAAE,SAAS;yBAChB,CAAC,GAEF,CACG;YAcN,oBAAC,cAAc,IAAC,EAAE,EAAE,EAAE,GAAI,CACd,CACR,CACN,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
|
2
|
+
|
3
|
+
.work-type-default-view {
|
4
|
+
position: relative;
|
5
|
+
height: 100%;
|
6
|
+
background: #ffffff;
|
7
|
+
:global {
|
8
|
+
.scroll-bars {
|
9
|
+
> div:last-child {
|
10
|
+
z-index: 12;
|
11
|
+
}
|
12
|
+
}
|
13
|
+
.work-type-header {
|
14
|
+
font-size: 30px;
|
15
|
+
color: #000;
|
16
|
+
font-weight: 500;
|
17
|
+
word-break: break-all;
|
18
|
+
padding: 10px 20px;
|
19
|
+
background: #ffffff;
|
20
|
+
&.sticky {
|
21
|
+
position: sticky;
|
22
|
+
top: -1px;
|
23
|
+
left: 0;
|
24
|
+
z-index: 10;
|
25
|
+
&.sticky-active {
|
26
|
+
box-shadow: 0 8px 6px -6px lightgray;
|
27
|
+
}
|
28
|
+
}
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|
@@ -0,0 +1,7 @@
|
|
1
|
+
import { IWorkType } from "../data";
|
2
|
+
import React, { CSSProperties } from "react";
|
3
|
+
declare const WorkTypeSelect: (props: {
|
4
|
+
onChange?: ((id: string, workType: IWorkType) => void) | undefined;
|
5
|
+
style?: React.CSSProperties | undefined;
|
6
|
+
}) => JSX.Element;
|
7
|
+
export default WorkTypeSelect;
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import { useWorkTypeListEffect } from "../data";
|
2
|
+
import React from "react";
|
3
|
+
import { Select } from "@voplus/antd";
|
4
|
+
import { observe } from "@voplus/morpho-ui";
|
5
|
+
import { useCreateListDataState } from "@voplus/morpho-ui/es/data";
|
6
|
+
const WorkTypeSelect = (props) => {
|
7
|
+
const { onChange, style } = props;
|
8
|
+
const list = useCreateListDataState({}, []);
|
9
|
+
useWorkTypeListEffect(null, (result) => list.union(result), list.filters.options);
|
10
|
+
return observe(() => (React.createElement(Select, { style: { width: "100%", ...style }, loading: list.loading, placeholder: "Select WorkType", onChange: handleChange }, list.data.map((item) => (React.createElement(Select.Option, { key: item.id, value: item.id }, item.name))))));
|
11
|
+
function handleChange(id) {
|
12
|
+
const workType = list.data.find((d) => d.id === id);
|
13
|
+
if (workType)
|
14
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(id, workType);
|
15
|
+
}
|
16
|
+
};
|
17
|
+
export default WorkTypeSelect;
|
18
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/WorkTypeSelect/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAa,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAC3D,OAAO,KAAwB,MAAM,OAAO,CAAC;AAE7C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAEnE,MAAM,cAAc,GAAG,CAAC,KAGvB,EAAE,EAAE;IACJ,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC;IAElC,MAAM,IAAI,GAAG,sBAAsB,CAAY,EAAE,EAAE,EAAE,CAAC,CAAC;IAEvD,qBAAqB,CAAC,IAAI,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;IAElF,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,MAAM,IACN,KAAK,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,KAAK,EAAE,EAClC,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,WAAW,EAAC,iBAAiB,EAC7B,QAAQ,EAAE,YAAY,IAErB,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CACxB,oBAAC,MAAM,CAAC,MAAM,IAAC,GAAG,EAAE,IAAI,CAAC,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,EAAE,IACzC,IAAI,CAAC,IAAI,CACK,CAChB,CAAC,CACM,CACT,CAAC,CAAC;IAEH,SAAS,YAAY,CAAC,EAAU;QAC/B,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;QACpD,IAAI,QAAQ;YAAE,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAG,EAAE,EAAE,QAAQ,EAAE;IACxC,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
import { ApiEndPoint } from "@voplus/api";
|
2
|
+
import { CountedMap, Store } from "@voplus/morpho-data";
|
3
|
+
import { IWorkType, LoadWorkTypeOptions, WorkTypeCreateOptions, WorkTypeEditOptions } from ".";
|
4
|
+
import { LoadDocumentListOptions } from "@voplus/morpho-document-core";
|
5
|
+
/** Corporate store supply backend functions. */
|
6
|
+
export declare class WorkTypeStore extends Store {
|
7
|
+
readonly endpoint: ApiEndPoint;
|
8
|
+
/** Name of the store */
|
9
|
+
readonly name: string;
|
10
|
+
constructor(endpoint: ApiEndPoint);
|
11
|
+
/** All currently used workType. */
|
12
|
+
readonly items: CountedMap<string, IWorkType>;
|
13
|
+
/** Create a new WorkType. */
|
14
|
+
create(options: WorkTypeCreateOptions): Promise<IWorkType>;
|
15
|
+
/** Edit an existing item on server. */
|
16
|
+
edit(id: string, options: WorkTypeEditOptions): Promise<void>;
|
17
|
+
loadList(options?: LoadDocumentListOptions): Promise<IWorkType[]>;
|
18
|
+
load(id: string, options: LoadWorkTypeOptions): Promise<IWorkType>;
|
19
|
+
}
|
20
|
+
/** 响应钩子检索 WorkTypeStore */
|
21
|
+
export declare const useWorkTypeStore: () => WorkTypeStore;
|
@@ -0,0 +1,75 @@
|
|
1
|
+
import { RequestBuilder } from "@voplus/api";
|
2
|
+
import { CountedMap, Store, useApplicationContext } from "@voplus/morpho-data";
|
3
|
+
import { observable } from "mobx";
|
4
|
+
const StoreName = "WorkTypeStore";
|
5
|
+
/** Corporate store supply backend functions. */
|
6
|
+
export class WorkTypeStore extends Store {
|
7
|
+
constructor(endpoint) {
|
8
|
+
super();
|
9
|
+
Object.defineProperty(this, "endpoint", {
|
10
|
+
enumerable: true,
|
11
|
+
configurable: true,
|
12
|
+
writable: true,
|
13
|
+
value: endpoint
|
14
|
+
});
|
15
|
+
/** Name of the store */
|
16
|
+
Object.defineProperty(this, "name", {
|
17
|
+
enumerable: true,
|
18
|
+
configurable: true,
|
19
|
+
writable: true,
|
20
|
+
value: StoreName
|
21
|
+
});
|
22
|
+
/** All currently used workType. */
|
23
|
+
Object.defineProperty(this, "items", {
|
24
|
+
enumerable: true,
|
25
|
+
configurable: true,
|
26
|
+
writable: true,
|
27
|
+
value: new CountedMap((key) => ({ id: key, loaded: false }), observable.map([], { deep: true }))
|
28
|
+
});
|
29
|
+
}
|
30
|
+
/** Create a new WorkType. */
|
31
|
+
async create(options) {
|
32
|
+
// invariant(options.name, "Name cannot be empty.");
|
33
|
+
return await this.action(async () => {
|
34
|
+
const r = await this.endpoint.post(`/api/works/types/create`, new RequestBuilder().json(options.data));
|
35
|
+
const t = (await r.json());
|
36
|
+
return t;
|
37
|
+
}, options);
|
38
|
+
}
|
39
|
+
/** Edit an existing item on server. */
|
40
|
+
async edit(id, options) {
|
41
|
+
await this.action(async () => {
|
42
|
+
const r = await this.endpoint.post(`/api/works/types/${id}/info`, new RequestBuilder().json(options.data));
|
43
|
+
const t = await r.json();
|
44
|
+
this.items.overwrite(t.id, t);
|
45
|
+
}, options);
|
46
|
+
}
|
47
|
+
async loadList(options) {
|
48
|
+
let query = "";
|
49
|
+
if (options === null || options === void 0 ? void 0 : options.Includes) {
|
50
|
+
query = query.concat(`includes=${options.Includes}`);
|
51
|
+
}
|
52
|
+
if (query)
|
53
|
+
query = "?".concat(query);
|
54
|
+
const r = await this.endpoint.post(`/api/works/types${query}`, new RequestBuilder().json(options ? options : { Filters: [] }));
|
55
|
+
return (await r.json());
|
56
|
+
}
|
57
|
+
async load(id, options) {
|
58
|
+
let query = "";
|
59
|
+
if (options.includes)
|
60
|
+
query = query.concat(`includes=${options.includes}`);
|
61
|
+
if (query)
|
62
|
+
query = "?".concat(query);
|
63
|
+
const r = await this.endpoint.get(`/api/works/types/${id}${query}`);
|
64
|
+
return (await r.json());
|
65
|
+
}
|
66
|
+
}
|
67
|
+
/** 响应钩子检索 WorkTypeStore */
|
68
|
+
export const useWorkTypeStore = () => {
|
69
|
+
const context = useApplicationContext();
|
70
|
+
if (!context.getStore(StoreName)) {
|
71
|
+
context.addStore(new WorkTypeStore(context.api.currentEndPoint));
|
72
|
+
}
|
73
|
+
return context.getStore(StoreName);
|
74
|
+
};
|
75
|
+
//# sourceMappingURL=WorkTypeStore.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"WorkTypeStore.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/data/WorkTypeStore.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1D,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,qBAAqB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,CAAc,CAAC;IACtC,CAAC;CACD;AAED,2BAA2B;AAC3B,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,EAAE;IACpC,MAAM,OAAO,GAAG,qBAAqB,EAAE,CAAC;IACxC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE;QACjC,OAAO,CAAC,QAAQ,CAAC,IAAI,aAAa,CAAC,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC,CAAC;KACjE;IACD,OAAO,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAmB,CAAC;AACtD,CAAC,CAAC"}
|
@@ -0,0 +1,9 @@
|
|
1
|
+
import { IWorkType, LoadWorkTypeOptions } from ".";
|
2
|
+
import { LoadDocumentListOptions } from "@voplus/morpho-document-core";
|
3
|
+
import { ListDataContextState } from "@voplus/morpho-ui/es/data";
|
4
|
+
/** React hook to retrieve a WorkType
|
5
|
+
* @param {string} id - id of the WorkType
|
6
|
+
* @param {LoadWorkTypeOptions} options - options
|
7
|
+
*/
|
8
|
+
export declare const useWorkType: (id: string, options?: LoadWorkTypeOptions | undefined) => IWorkType;
|
9
|
+
export declare const useWorkTypeListEffect: (list: ListDataContextState<IWorkType> | null, effect: (list: any[]) => void, options?: LoadDocumentListOptions | undefined) => void;
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import { useWorkTypeStore } from ".";
|
2
|
+
import { useDocumentListLoaderEffect, } from "@voplus/morpho-document-core";
|
3
|
+
import { useLoadCountedMapItem } from "@voplus/morpho-data";
|
4
|
+
/** React hook to retrieve a WorkType
|
5
|
+
* @param {string} id - id of the WorkType
|
6
|
+
* @param {LoadWorkTypeOptions} options - options
|
7
|
+
*/
|
8
|
+
export const useWorkType = (id, options) => {
|
9
|
+
options = options ? options : {};
|
10
|
+
const store = useWorkTypeStore();
|
11
|
+
return useLoadCountedMapItem(id, store.items, () => store.load(id, options), options);
|
12
|
+
};
|
13
|
+
export const useWorkTypeListEffect = (list, effect, options) => {
|
14
|
+
const deps = options ? options : {};
|
15
|
+
const workType = useWorkTypeStore();
|
16
|
+
// Call useDocumentListEffect and ensure won't load twice for same loading options.
|
17
|
+
return useDocumentListLoaderEffect(list, effect, () => workType.loadList(options), [deps]);
|
18
|
+
};
|
19
|
+
//# sourceMappingURL=hook.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"hook.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/data/hook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkC,gBAAgB,EAAE,MAAM,GAAG,CAAC;AACrE,OAAO,EAGN,2BAA2B,GAE3B,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAE5D;;;GAGG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,EAAU,EAAE,OAA6B,EAAE,EAAE;IACxE,OAAO,GAAG,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAE,EAA0B,CAAC;IAC1D,MAAM,KAAK,GAAG,gBAAgB,EAAE,CAAC;IAEjC,OAAO,qBAAqB,CAAC,EAAE,EAAE,KAAK,CAAC,KAAK,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,OAAQ,CAAC,EAAE,OAAO,CAAC,CAAC;AACxF,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,qBAAqB,GAAG,CACpC,IAA4C,EAC5C,MAA6B,EAC7B,OAAiC,EAChC,EAAE;IACH,MAAM,IAAI,GAAG,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAE,EAA8B,CAAC;IACjE,MAAM,QAAQ,GAAG,gBAAgB,EAAE,CAAC;IAEpC,mFAAmF;IACnF,OAAO,2BAA2B,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;AAC5F,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/data/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC"}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
import { ILoadable } from "@voplus/morpho-data";
|
2
|
+
export interface ICheckListItem {
|
3
|
+
key?: string;
|
4
|
+
/** checked of the CheckListItem. */
|
5
|
+
checked: boolean;
|
6
|
+
/** item name of the CheckListItem. */
|
7
|
+
item: string;
|
8
|
+
}
|
9
|
+
export interface IAuditAuditorInfo {
|
10
|
+
/** a value indicating whether audit is enabled */
|
11
|
+
audit?: boolean;
|
12
|
+
/** the rate in percentage audit shall be performed */
|
13
|
+
auditRate?: number;
|
14
|
+
/** list of default work member */
|
15
|
+
auditors?: {
|
16
|
+
id: string;
|
17
|
+
name: string;
|
18
|
+
}[];
|
19
|
+
}
|
20
|
+
export interface IWorkType extends ILoadable {
|
21
|
+
/** id of the workType */
|
22
|
+
id: string;
|
23
|
+
/** name of the workType */
|
24
|
+
name?: string;
|
25
|
+
/** description of the workType */
|
26
|
+
description?: string;
|
27
|
+
/** audit info of the workType */
|
28
|
+
audit?: IAuditAuditorInfo;
|
29
|
+
/** list of default work member */
|
30
|
+
members?: string[];
|
31
|
+
/** checklist of the workType. */
|
32
|
+
checkList?: ICheckListItem[];
|
33
|
+
/** new form schema id the work type */
|
34
|
+
newFormSchemaId?: string;
|
35
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../../src/pages/WorkType/data/interfaces.ts"],"names":[],"mappings":""}
|