@webiny/app-scheduler 0.0.0-unstable.81ae05e56b
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/Domain/Models/SchedulerItem/SchedulerItem.d.ts +13 -0
- package/Domain/Models/SchedulerItem/SchedulerItem.js +17 -0
- package/Domain/Models/SchedulerItem/SchedulerItem.js.map +1 -0
- package/Domain/Models/SchedulerItem/index.d.ts +1 -0
- package/Domain/Models/SchedulerItem/index.js +3 -0
- package/Domain/Models/SchedulerItem/index.js.map +1 -0
- package/Domain/Models/index.d.ts +1 -0
- package/Domain/Models/index.js +3 -0
- package/Domain/Models/index.js.map +1 -0
- package/Domain/Repositories/SchedulerItems/ISchedulerItemsRepository.d.ts +14 -0
- package/Domain/Repositories/SchedulerItems/ISchedulerItemsRepository.js +3 -0
- package/Domain/Repositories/SchedulerItems/ISchedulerItemsRepository.js.map +1 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepository.d.ts +36 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepository.js +128 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepository.js.map +1 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryFactory.d.ts +19 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryFactory.js +17 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryFactory.js.map +1 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryWithLoading.d.ts +17 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryWithLoading.js +38 -0
- package/Domain/Repositories/SchedulerItems/SchedulerItemsRepositoryWithLoading.js.map +1 -0
- package/Domain/Repositories/SchedulerItems/index.d.ts +4 -0
- package/Domain/Repositories/SchedulerItems/index.js +5 -0
- package/Domain/Repositories/SchedulerItems/index.js.map +1 -0
- package/Domain/Repositories/Search/ISearchRepository.d.ts +4 -0
- package/Domain/Repositories/Search/ISearchRepository.js +3 -0
- package/Domain/Repositories/Search/ISearchRepository.js.map +1 -0
- package/Domain/Repositories/Search/SearchRepository.d.ts +7 -0
- package/Domain/Repositories/Search/SearchRepository.js +15 -0
- package/Domain/Repositories/Search/SearchRepository.js.map +1 -0
- package/Domain/Repositories/Search/SearchRepositoryFactory.d.ts +7 -0
- package/Domain/Repositories/Search/SearchRepositoryFactory.js +17 -0
- package/Domain/Repositories/Search/SearchRepositoryFactory.js.map +1 -0
- package/Domain/Repositories/Search/index.d.ts +3 -0
- package/Domain/Repositories/Search/index.js +4 -0
- package/Domain/Repositories/Search/index.js.map +1 -0
- package/Domain/Repositories/SelectedItems/ISelectedItemsRepository.d.ts +8 -0
- package/Domain/Repositories/SelectedItems/ISelectedItemsRepository.js +3 -0
- package/Domain/Repositories/SelectedItems/ISelectedItemsRepository.js.map +1 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepository.d.ts +12 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepository.js +27 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepository.js.map +1 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepositoryFactory.d.ts +7 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepositoryFactory.js +17 -0
- package/Domain/Repositories/SelectedItems/SelectedItemsRepositoryFactory.js.map +1 -0
- package/Domain/Repositories/SelectedItems/index.d.ts +3 -0
- package/Domain/Repositories/SelectedItems/index.js +4 -0
- package/Domain/Repositories/SelectedItems/index.js.map +1 -0
- package/Domain/Repositories/Sorting/SortingRepositoryWithDefaults.d.ts +8 -0
- package/Domain/Repositories/Sorting/SortingRepositoryWithDefaults.js +22 -0
- package/Domain/Repositories/Sorting/SortingRepositoryWithDefaults.js.map +1 -0
- package/Domain/Repositories/Sorting/index.d.ts +1 -0
- package/Domain/Repositories/Sorting/index.js +3 -0
- package/Domain/Repositories/Sorting/index.js.map +1 -0
- package/Domain/Repositories/index.d.ts +4 -0
- package/Domain/Repositories/index.js +6 -0
- package/Domain/Repositories/index.js.map +1 -0
- package/Domain/index.d.ts +2 -0
- package/Domain/index.js +4 -0
- package/Domain/index.js.map +1 -0
- package/Gateways/SchedulerCancelGraphQLGateway.d.ts +7 -0
- package/Gateways/SchedulerCancelGraphQLGateway.js +48 -0
- package/Gateways/SchedulerCancelGraphQLGateway.js.map +1 -0
- package/Gateways/SchedulerGetGraphQLGateway.d.ts +21 -0
- package/Gateways/SchedulerGetGraphQLGateway.js +72 -0
- package/Gateways/SchedulerGetGraphQLGateway.js.map +1 -0
- package/Gateways/SchedulerListGraphQLGateway.d.ts +7 -0
- package/Gateways/SchedulerListGraphQLGateway.js +92 -0
- package/Gateways/SchedulerListGraphQLGateway.js.map +1 -0
- package/Gateways/SchedulerPublishGraphQLGateway.d.ts +7 -0
- package/Gateways/SchedulerPublishGraphQLGateway.js +67 -0
- package/Gateways/SchedulerPublishGraphQLGateway.js.map +1 -0
- package/Gateways/SchedulerUnpublishGraphQLGateway.d.ts +23 -0
- package/Gateways/SchedulerUnpublishGraphQLGateway.js +69 -0
- package/Gateways/SchedulerUnpublishGraphQLGateway.js.map +1 -0
- package/Gateways/abstractions/CancelScheduledActionGateway.d.ts +7 -0
- package/Gateways/abstractions/CancelScheduledActionGateway.js +3 -0
- package/Gateways/abstractions/CancelScheduledActionGateway.js.map +1 -0
- package/Gateways/abstractions/GetScheduledActionGateway.d.ts +9 -0
- package/Gateways/abstractions/GetScheduledActionGateway.js +3 -0
- package/Gateways/abstractions/GetScheduledActionGateway.js.map +1 -0
- package/Gateways/abstractions/ListScheduledActionsGateway.d.ts +27 -0
- package/Gateways/abstractions/ListScheduledActionsGateway.js +3 -0
- package/Gateways/abstractions/ListScheduledActionsGateway.js.map +1 -0
- package/Gateways/abstractions/SchedulePublishActionGateway.d.ts +12 -0
- package/Gateways/abstractions/SchedulePublishActionGateway.js +3 -0
- package/Gateways/abstractions/SchedulePublishActionGateway.js.map +1 -0
- package/Gateways/abstractions/ScheduleUnpublishActionGateway.d.ts +12 -0
- package/Gateways/abstractions/ScheduleUnpublishActionGateway.js +3 -0
- package/Gateways/abstractions/ScheduleUnpublishActionGateway.js.map +1 -0
- package/Gateways/graphql/fields.d.ts +1 -0
- package/Gateways/graphql/fields.js +18 -0
- package/Gateways/graphql/fields.js.map +1 -0
- package/Gateways/index.d.ts +5 -0
- package/Gateways/index.js +3 -0
- package/Gateways/index.js.map +1 -0
- package/Gateways/schema/schedulerEntry.d.ts +16 -0
- package/Gateways/schema/schedulerEntry.js +22 -0
- package/Gateways/schema/schedulerEntry.js.map +1 -0
- package/LICENSE +21 -0
- package/Presentation/Scheduler/Scheduler.d.ts +17 -0
- package/Presentation/Scheduler/Scheduler.js +67 -0
- package/Presentation/Scheduler/Scheduler.js.map +1 -0
- package/Presentation/Scheduler/SchedulerControllers.d.ts +30 -0
- package/Presentation/Scheduler/SchedulerControllers.js +72 -0
- package/Presentation/Scheduler/SchedulerControllers.js.map +1 -0
- package/Presentation/Scheduler/SchedulerPresenter.d.ts +32 -0
- package/Presentation/Scheduler/SchedulerPresenter.js +44 -0
- package/Presentation/Scheduler/SchedulerPresenter.js.map +1 -0
- package/Presentation/Scheduler/controllers/CancelItem/CancelItemController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/CancelItem/CancelItemController.js +11 -0
- package/Presentation/Scheduler/controllers/CancelItem/CancelItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/CancelItem/ICancelItemController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/CancelItem/ICancelItemController.js +3 -0
- package/Presentation/Scheduler/controllers/CancelItem/ICancelItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/CancelItem/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/CancelItem/index.js +3 -0
- package/Presentation/Scheduler/controllers/CancelItem/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/GetItem/GetItemController.d.ts +8 -0
- package/Presentation/Scheduler/controllers/GetItem/GetItemController.js +11 -0
- package/Presentation/Scheduler/controllers/GetItem/GetItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/GetItem/IGetItemController.d.ts +4 -0
- package/Presentation/Scheduler/controllers/GetItem/IGetItemController.js +3 -0
- package/Presentation/Scheduler/controllers/GetItem/IGetItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/GetItem/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/GetItem/index.js +3 -0
- package/Presentation/Scheduler/controllers/GetItem/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListItems/IListItemsController.d.ts +4 -0
- package/Presentation/Scheduler/controllers/ListItems/IListItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/ListItems/IListItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListItems/ListItemsController.d.ts +8 -0
- package/Presentation/Scheduler/controllers/ListItems/ListItemsController.js +11 -0
- package/Presentation/Scheduler/controllers/ListItems/ListItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/ListItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/ListItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/IListMoreItemsController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/IListMoreItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/IListMoreItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/ListMoreItemsController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/ListMoreItemsController.js +11 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/ListMoreItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/ListMoreItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/PublishItem/IPublishItemController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/PublishItem/IPublishItemController.js +3 -0
- package/Presentation/Scheduler/controllers/PublishItem/IPublishItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/PublishItem/PublishItemController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/PublishItem/PublishItemController.js +11 -0
- package/Presentation/Scheduler/controllers/PublishItem/PublishItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/PublishItem/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/PublishItem/index.js +3 -0
- package/Presentation/Scheduler/controllers/PublishItem/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/SearchItems/ISearchItemsController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/SearchItems/ISearchItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/SearchItems/ISearchItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SearchItems/SearchItemsController.d.ts +8 -0
- package/Presentation/Scheduler/controllers/SearchItems/SearchItemsController.js +14 -0
- package/Presentation/Scheduler/controllers/SearchItems/SearchItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SearchItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/SearchItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/SearchItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/ISelectAllItemsController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/ISelectAllItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/ISelectAllItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/SelectAllItemsController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/SelectAllItemsController.js +11 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/SelectAllItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/SelectAllItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectItems/ISelectItemsController.d.ts +4 -0
- package/Presentation/Scheduler/controllers/SelectItems/ISelectItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/SelectItems/ISelectItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectItems/SelectItemsController.d.ts +8 -0
- package/Presentation/Scheduler/controllers/SelectItems/SelectItemsController.js +13 -0
- package/Presentation/Scheduler/controllers/SelectItems/SelectItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SelectItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/SelectItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/SelectItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/SortItems/ISortItemsController.d.ts +4 -0
- package/Presentation/Scheduler/controllers/SortItems/ISortItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/SortItems/ISortItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SortItems/SortItemsController.d.ts +9 -0
- package/Presentation/Scheduler/controllers/SortItems/SortItemsController.js +19 -0
- package/Presentation/Scheduler/controllers/SortItems/SortItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/SortItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/SortItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/SortItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/IUnpublishItemController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/IUnpublishItemController.js +3 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/IUnpublishItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/UnpublishItemController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/UnpublishItemController.js +11 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/UnpublishItemController.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/index.js +3 -0
- package/Presentation/Scheduler/controllers/UnpublishItem/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/IUnselectAllItemsController.d.ts +3 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/IUnselectAllItemsController.js +3 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/IUnselectAllItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/UnselectAllItemsController.d.ts +7 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/UnselectAllItemsController.js +11 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/UnselectAllItemsController.js.map +1 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/index.d.ts +2 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/index.js +3 -0
- package/Presentation/Scheduler/controllers/UnselectAllItems/index.js.map +1 -0
- package/Presentation/Scheduler/controllers/index.d.ts +11 -0
- package/Presentation/Scheduler/controllers/index.js +13 -0
- package/Presentation/Scheduler/controllers/index.js.map +1 -0
- package/Presentation/Scheduler/index.d.ts +1 -0
- package/Presentation/Scheduler/index.js +3 -0
- package/Presentation/Scheduler/index.js.map +1 -0
- package/Presentation/SchedulerConfigs/SchedulerConfigs.d.ts +2 -0
- package/Presentation/SchedulerConfigs/SchedulerConfigs.js +55 -0
- package/Presentation/SchedulerConfigs/SchedulerConfigs.js.map +1 -0
- package/Presentation/SchedulerConfigs/index.d.ts +1 -0
- package/Presentation/SchedulerConfigs/index.js +3 -0
- package/Presentation/SchedulerConfigs/index.js.map +1 -0
- package/Presentation/SchedulerRenderer/SchedulerRenderer.d.ts +6 -0
- package/Presentation/SchedulerRenderer/SchedulerRenderer.js +21 -0
- package/Presentation/SchedulerRenderer/SchedulerRenderer.js.map +1 -0
- package/Presentation/SchedulerRenderer/index.d.ts +1 -0
- package/Presentation/SchedulerRenderer/index.js +3 -0
- package/Presentation/SchedulerRenderer/index.js.map +1 -0
- package/Presentation/abstractions/ISchedulerControllers.d.ts +14 -0
- package/Presentation/abstractions/ISchedulerControllers.js +3 -0
- package/Presentation/abstractions/ISchedulerControllers.js.map +1 -0
- package/Presentation/abstractions/ISchedulerPresenter.d.ts +20 -0
- package/Presentation/abstractions/ISchedulerPresenter.js +3 -0
- package/Presentation/abstractions/ISchedulerPresenter.js.map +1 -0
- package/Presentation/abstractions/index.d.ts +2 -0
- package/Presentation/abstractions/index.js +3 -0
- package/Presentation/abstractions/index.js.map +1 -0
- package/Presentation/components/Actions/CancelItem/CancelItem.d.ts +2 -0
- package/Presentation/components/Actions/CancelItem/CancelItem.js +24 -0
- package/Presentation/components/Actions/CancelItem/CancelItem.js.map +1 -0
- package/Presentation/components/Actions/CancelItem/index.d.ts +1 -0
- package/Presentation/components/Actions/CancelItem/index.js +3 -0
- package/Presentation/components/Actions/CancelItem/index.js.map +1 -0
- package/Presentation/components/Actions/index.d.ts +1 -0
- package/Presentation/components/Actions/index.js +3 -0
- package/Presentation/components/Actions/index.js.map +1 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.d.ts +2 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.js +20 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.js.map +1 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.styled.d.ts +20 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.styled.js +69 -0
- package/Presentation/components/BottomInfoBar/BottomInfoBar.styled.js.map +1 -0
- package/Presentation/components/BottomInfoBar/ListMeta.d.ts +7 -0
- package/Presentation/components/BottomInfoBar/ListMeta.js +12 -0
- package/Presentation/components/BottomInfoBar/ListMeta.js.map +1 -0
- package/Presentation/components/BottomInfoBar/ListStatus.d.ts +5 -0
- package/Presentation/components/BottomInfoBar/ListStatus.js +16 -0
- package/Presentation/components/BottomInfoBar/ListStatus.js.map +1 -0
- package/Presentation/components/BottomInfoBar/index.d.ts +1 -0
- package/Presentation/components/BottomInfoBar/index.js +3 -0
- package/Presentation/components/BottomInfoBar/index.js.map +1 -0
- package/Presentation/components/Cells/CellActions/CellActions.d.ts +2 -0
- package/Presentation/components/Cells/CellActions/CellActions.js +23 -0
- package/Presentation/components/Cells/CellActions/CellActions.js.map +1 -0
- package/Presentation/components/Cells/CellActions/index.d.ts +1 -0
- package/Presentation/components/Cells/CellActions/index.js +3 -0
- package/Presentation/components/Cells/CellActions/index.js.map +1 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.d.ts +2 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.js +20 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.js.map +1 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.styled.d.ts +11 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.styled.js +44 -0
- package/Presentation/components/Cells/CellRevision/CellRevision.styled.js.map +1 -0
- package/Presentation/components/Cells/CellRevision/index.d.ts +1 -0
- package/Presentation/components/Cells/CellRevision/index.js +3 -0
- package/Presentation/components/Cells/CellRevision/index.js.map +1 -0
- package/Presentation/components/Cells/CellScheduledBy/CellScheduledBy.d.ts +2 -0
- package/Presentation/components/Cells/CellScheduledBy/CellScheduledBy.js +13 -0
- package/Presentation/components/Cells/CellScheduledBy/CellScheduledBy.js.map +1 -0
- package/Presentation/components/Cells/CellScheduledBy/index.d.ts +1 -0
- package/Presentation/components/Cells/CellScheduledBy/index.js +3 -0
- package/Presentation/components/Cells/CellScheduledBy/index.js.map +1 -0
- package/Presentation/components/Cells/CellScheduledOn/CellScheduledOn.d.ts +24 -0
- package/Presentation/components/Cells/CellScheduledOn/CellScheduledOn.js +24 -0
- package/Presentation/components/Cells/CellScheduledOn/CellScheduledOn.js.map +1 -0
- package/Presentation/components/Cells/CellScheduledOn/index.d.ts +1 -0
- package/Presentation/components/Cells/CellScheduledOn/index.js +3 -0
- package/Presentation/components/Cells/CellScheduledOn/index.js.map +1 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.d.ts +2 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.js +17 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.js.map +1 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.styled.d.ts +11 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.styled.js +44 -0
- package/Presentation/components/Cells/CellTitle/CellTitle.styled.js.map +1 -0
- package/Presentation/components/Cells/CellTitle/index.d.ts +1 -0
- package/Presentation/components/Cells/CellTitle/index.js +3 -0
- package/Presentation/components/Cells/CellTitle/index.js.map +1 -0
- package/Presentation/components/Cells/CellType/CellActionType.d.ts +2 -0
- package/Presentation/components/Cells/CellType/CellActionType.js +18 -0
- package/Presentation/components/Cells/CellType/CellActionType.js.map +1 -0
- package/Presentation/components/Cells/CellType/CellActionType.styled.d.ts +11 -0
- package/Presentation/components/Cells/CellType/CellActionType.styled.js +44 -0
- package/Presentation/components/Cells/CellType/CellActionType.styled.js.map +1 -0
- package/Presentation/components/Cells/CellType/index.d.ts +1 -0
- package/Presentation/components/Cells/CellType/index.js +3 -0
- package/Presentation/components/Cells/CellType/index.js.map +1 -0
- package/Presentation/components/Cells/index.d.ts +6 -0
- package/Presentation/components/Cells/index.js +8 -0
- package/Presentation/components/Cells/index.js.map +1 -0
- package/Presentation/components/Empty/Empty.d.ts +2 -0
- package/Presentation/components/Empty/Empty.js +22 -0
- package/Presentation/components/Empty/Empty.js.map +1 -0
- package/Presentation/components/Empty/Empty.styled.d.ts +8 -0
- package/Presentation/components/Empty/Empty.styled.js +30 -0
- package/Presentation/components/Empty/Empty.styled.js.map +1 -0
- package/Presentation/components/Empty/index.d.ts +1 -0
- package/Presentation/components/Empty/index.js +3 -0
- package/Presentation/components/Empty/index.js.map +1 -0
- package/Presentation/components/ScheduleDialog/ScheduleDialogAction.d.ts +15 -0
- package/Presentation/components/ScheduleDialog/ScheduleDialogAction.js +51 -0
- package/Presentation/components/ScheduleDialog/ScheduleDialogAction.js.map +1 -0
- package/Presentation/components/ScheduleDialog/index.d.ts +2 -0
- package/Presentation/components/ScheduleDialog/index.js +4 -0
- package/Presentation/components/ScheduleDialog/index.js.map +1 -0
- package/Presentation/components/ScheduleDialog/types.d.ts +15 -0
- package/Presentation/components/ScheduleDialog/types.js +3 -0
- package/Presentation/components/ScheduleDialog/types.js.map +1 -0
- package/Presentation/components/ScheduleDialog/useGetScheduledAction.d.ts +7 -0
- package/Presentation/components/ScheduleDialog/useGetScheduledAction.js +31 -0
- package/Presentation/components/ScheduleDialog/useGetScheduledAction.js.map +1 -0
- package/Presentation/components/ScheduleDialog/useScheduleDialog.d.ts +42 -0
- package/Presentation/components/ScheduleDialog/useScheduleDialog.js +239 -0
- package/Presentation/components/ScheduleDialog/useScheduleDialog.js.map +1 -0
- package/Presentation/components/SchedulerOverlay/SchedulerOverlay.d.ts +7 -0
- package/Presentation/components/SchedulerOverlay/SchedulerOverlay.js +36 -0
- package/Presentation/components/SchedulerOverlay/SchedulerOverlay.js.map +1 -0
- package/Presentation/components/SchedulerOverlay/index.d.ts +1 -0
- package/Presentation/components/SchedulerOverlay/index.js +3 -0
- package/Presentation/components/SchedulerOverlay/index.js.map +1 -0
- package/Presentation/components/SearchInput/SearchInput.d.ts +2 -0
- package/Presentation/components/SearchInput/SearchInput.js +37 -0
- package/Presentation/components/SearchInput/SearchInput.js.map +1 -0
- package/Presentation/components/SearchInput/index.d.ts +1 -0
- package/Presentation/components/SearchInput/index.js +3 -0
- package/Presentation/components/SearchInput/index.js.map +1 -0
- package/Presentation/components/Table/Table.d.ts +2 -0
- package/Presentation/components/Table/Table.js +34 -0
- package/Presentation/components/Table/Table.js.map +1 -0
- package/Presentation/components/Table/index.d.ts +1 -0
- package/Presentation/components/Table/index.js +3 -0
- package/Presentation/components/Table/index.js.map +1 -0
- package/Presentation/components/Title/Title.d.ts +5 -0
- package/Presentation/components/Title/Title.js +15 -0
- package/Presentation/components/Title/Title.js.map +1 -0
- package/Presentation/components/Title/Title.styled.d.ts +4 -0
- package/Presentation/components/Title/Title.styled.js +18 -0
- package/Presentation/components/Title/Title.styled.js.map +1 -0
- package/Presentation/components/Title/index.d.ts +1 -0
- package/Presentation/components/Title/index.js +3 -0
- package/Presentation/components/Title/index.js.map +1 -0
- package/Presentation/configs/index.d.ts +1 -0
- package/Presentation/configs/index.js +3 -0
- package/Presentation/configs/index.js.map +1 -0
- package/Presentation/configs/list/Browser/EntryAction.d.ts +7 -0
- package/Presentation/configs/list/Browser/EntryAction.js +16 -0
- package/Presentation/configs/list/Browser/EntryAction.js.map +1 -0
- package/Presentation/configs/list/Browser/Table/Column.d.ts +14 -0
- package/Presentation/configs/list/Browser/Table/Column.js +14 -0
- package/Presentation/configs/list/Browser/Table/Column.js.map +1 -0
- package/Presentation/configs/list/Browser/Table/Sorting.d.ts +5 -0
- package/Presentation/configs/list/Browser/Table/Sorting.js +10 -0
- package/Presentation/configs/list/Browser/Table/Sorting.js.map +1 -0
- package/Presentation/configs/list/Browser/Table/index.d.ts +18 -0
- package/Presentation/configs/list/Browser/Table/index.js +8 -0
- package/Presentation/configs/list/Browser/Table/index.js.map +1 -0
- package/Presentation/configs/list/Browser/index.d.ts +23 -0
- package/Presentation/configs/list/Browser/index.js +8 -0
- package/Presentation/configs/list/Browser/index.js.map +1 -0
- package/Presentation/configs/list/SchedulerListConfig.d.ts +33 -0
- package/Presentation/configs/list/SchedulerListConfig.js +31 -0
- package/Presentation/configs/list/SchedulerListConfig.js.map +1 -0
- package/Presentation/configs/list/index.d.ts +1 -0
- package/Presentation/configs/list/index.js +3 -0
- package/Presentation/configs/list/index.js.map +1 -0
- package/Presentation/hooks/index.d.ts +3 -0
- package/Presentation/hooks/index.js +5 -0
- package/Presentation/hooks/index.js.map +1 -0
- package/Presentation/hooks/useCancelSchedulerItem.d.ts +8 -0
- package/Presentation/hooks/useCancelSchedulerItem.js +32 -0
- package/Presentation/hooks/useCancelSchedulerItem.js.map +1 -0
- package/Presentation/hooks/useScheduler.d.ts +28 -0
- package/Presentation/hooks/useScheduler.js +52 -0
- package/Presentation/hooks/useScheduler.js.map +1 -0
- package/Presentation/hooks/useSchedulerItem.d.ts +11 -0
- package/Presentation/hooks/useSchedulerItem.js +9 -0
- package/Presentation/hooks/useSchedulerItem.js.map +1 -0
- package/Presentation/index.d.ts +25 -0
- package/Presentation/index.js +56 -0
- package/Presentation/index.js.map +1 -0
- package/README.md +11 -0
- package/UseCases/CancelItem/CancelItemUseCase.d.ts +7 -0
- package/UseCases/CancelItem/CancelItemUseCase.js +12 -0
- package/UseCases/CancelItem/CancelItemUseCase.js.map +1 -0
- package/UseCases/CancelItem/ICancelItemUseCase.d.ts +3 -0
- package/UseCases/CancelItem/ICancelItemUseCase.js +3 -0
- package/UseCases/CancelItem/ICancelItemUseCase.js.map +1 -0
- package/UseCases/CancelItem/index.d.ts +2 -0
- package/UseCases/CancelItem/index.js +3 -0
- package/UseCases/CancelItem/index.js.map +1 -0
- package/UseCases/GetItem/GetItemUseCase.d.ts +8 -0
- package/UseCases/GetItem/GetItemUseCase.js +12 -0
- package/UseCases/GetItem/GetItemUseCase.js.map +1 -0
- package/UseCases/GetItem/IGetItemUseCase.d.ts +4 -0
- package/UseCases/GetItem/IGetItemUseCase.js +3 -0
- package/UseCases/GetItem/IGetItemUseCase.js.map +1 -0
- package/UseCases/GetItem/index.d.ts +2 -0
- package/UseCases/GetItem/index.js +3 -0
- package/UseCases/GetItem/index.js.map +1 -0
- package/UseCases/GetScheduledItem/GetScheduledItemUseCase.d.ts +7 -0
- package/UseCases/GetScheduledItem/GetScheduledItemUseCase.js +13 -0
- package/UseCases/GetScheduledItem/GetScheduledItemUseCase.js.map +1 -0
- package/UseCases/GetScheduledItem/IGetScheduledItemUseCase.d.ts +4 -0
- package/UseCases/GetScheduledItem/IGetScheduledItemUseCase.js +3 -0
- package/UseCases/GetScheduledItem/IGetScheduledItemUseCase.js.map +1 -0
- package/UseCases/GetScheduledItem/index.d.ts +2 -0
- package/UseCases/GetScheduledItem/index.js +3 -0
- package/UseCases/GetScheduledItem/index.js.map +1 -0
- package/UseCases/ListItems/IListItemsUseCase.d.ts +4 -0
- package/UseCases/ListItems/IListItemsUseCase.js +3 -0
- package/UseCases/ListItems/IListItemsUseCase.js.map +1 -0
- package/UseCases/ListItems/ListItemsUseCase.d.ts +8 -0
- package/UseCases/ListItems/ListItemsUseCase.js +12 -0
- package/UseCases/ListItems/ListItemsUseCase.js.map +1 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSearch.d.ts +9 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSearch.js +22 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSearch.js.map +1 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSorting.d.ts +9 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSorting.js +22 -0
- package/UseCases/ListItems/ListItemsUseCaseWithSorting.js.map +1 -0
- package/UseCases/ListItems/index.d.ts +4 -0
- package/UseCases/ListItems/index.js +5 -0
- package/UseCases/ListItems/index.js.map +1 -0
- package/UseCases/ListMoreItems/IListMoreItemsUseCase.d.ts +3 -0
- package/UseCases/ListMoreItems/IListMoreItemsUseCase.js +3 -0
- package/UseCases/ListMoreItems/IListMoreItemsUseCase.js.map +1 -0
- package/UseCases/ListMoreItems/ListMoreItemsUseCase.d.ts +7 -0
- package/UseCases/ListMoreItems/ListMoreItemsUseCase.js +12 -0
- package/UseCases/ListMoreItems/ListMoreItemsUseCase.js.map +1 -0
- package/UseCases/ListMoreItems/index.d.ts +2 -0
- package/UseCases/ListMoreItems/index.js +3 -0
- package/UseCases/ListMoreItems/index.js.map +1 -0
- package/UseCases/PublishItem/IPublishItemUseCase.d.ts +3 -0
- package/UseCases/PublishItem/IPublishItemUseCase.js +3 -0
- package/UseCases/PublishItem/IPublishItemUseCase.js.map +1 -0
- package/UseCases/PublishItem/PublishItemUseCase.d.ts +7 -0
- package/UseCases/PublishItem/PublishItemUseCase.js +12 -0
- package/UseCases/PublishItem/PublishItemUseCase.js.map +1 -0
- package/UseCases/PublishItem/index.d.ts +2 -0
- package/UseCases/PublishItem/index.js +3 -0
- package/UseCases/PublishItem/index.js.map +1 -0
- package/UseCases/SearchItems/ISearchItemsUseCase.d.ts +3 -0
- package/UseCases/SearchItems/ISearchItemsUseCase.js +3 -0
- package/UseCases/SearchItems/ISearchItemsUseCase.js.map +1 -0
- package/UseCases/SearchItems/SearchItemsUseCase.d.ts +7 -0
- package/UseCases/SearchItems/SearchItemsUseCase.js +12 -0
- package/UseCases/SearchItems/SearchItemsUseCase.js.map +1 -0
- package/UseCases/SearchItems/index.d.ts +2 -0
- package/UseCases/SearchItems/index.js +3 -0
- package/UseCases/SearchItems/index.js.map +1 -0
- package/UseCases/SelectAllItems/ISelectAllItemsUseCase.d.ts +3 -0
- package/UseCases/SelectAllItems/ISelectAllItemsUseCase.js +3 -0
- package/UseCases/SelectAllItems/ISelectAllItemsUseCase.js.map +1 -0
- package/UseCases/SelectAllItems/SelectAllItemsUseCase.d.ts +7 -0
- package/UseCases/SelectAllItems/SelectAllItemsUseCase.js +12 -0
- package/UseCases/SelectAllItems/SelectAllItemsUseCase.js.map +1 -0
- package/UseCases/SelectAllItems/index.d.ts +2 -0
- package/UseCases/SelectAllItems/index.js +3 -0
- package/UseCases/SelectAllItems/index.js.map +1 -0
- package/UseCases/SelectItems/ISelectItemsUseCase.d.ts +4 -0
- package/UseCases/SelectItems/ISelectItemsUseCase.js +3 -0
- package/UseCases/SelectItems/ISelectItemsUseCase.js.map +1 -0
- package/UseCases/SelectItems/SelectItemsUseCase.d.ts +7 -0
- package/UseCases/SelectItems/SelectItemsUseCase.js +12 -0
- package/UseCases/SelectItems/SelectItemsUseCase.js.map +1 -0
- package/UseCases/SelectItems/index.d.ts +2 -0
- package/UseCases/SelectItems/index.js +3 -0
- package/UseCases/SelectItems/index.js.map +1 -0
- package/UseCases/SortItems/ISortItemsUseCase.d.ts +4 -0
- package/UseCases/SortItems/ISortItemsUseCase.js +3 -0
- package/UseCases/SortItems/ISortItemsUseCase.js.map +1 -0
- package/UseCases/SortItems/SortItemsUseCase.d.ts +7 -0
- package/UseCases/SortItems/SortItemsUseCase.js +12 -0
- package/UseCases/SortItems/SortItemsUseCase.js.map +1 -0
- package/UseCases/SortItems/index.d.ts +2 -0
- package/UseCases/SortItems/index.js +3 -0
- package/UseCases/SortItems/index.js.map +1 -0
- package/UseCases/UnSelectAllItems/IUnselectAllItemsUseCase.d.ts +3 -0
- package/UseCases/UnSelectAllItems/IUnselectAllItemsUseCase.js +3 -0
- package/UseCases/UnSelectAllItems/IUnselectAllItemsUseCase.js.map +1 -0
- package/UseCases/UnSelectAllItems/UnselectAllItemsUseCase.d.ts +7 -0
- package/UseCases/UnSelectAllItems/UnselectAllItemsUseCase.js +12 -0
- package/UseCases/UnSelectAllItems/UnselectAllItemsUseCase.js.map +1 -0
- package/UseCases/UnSelectAllItems/index.d.ts +2 -0
- package/UseCases/UnSelectAllItems/index.js +3 -0
- package/UseCases/UnSelectAllItems/index.js.map +1 -0
- package/UseCases/UnpublishItem/IUnpublishItemUseCase.d.ts +3 -0
- package/UseCases/UnpublishItem/IUnpublishItemUseCase.js +3 -0
- package/UseCases/UnpublishItem/IUnpublishItemUseCase.js.map +1 -0
- package/UseCases/UnpublishItem/UnpublishItemUseCase.d.ts +7 -0
- package/UseCases/UnpublishItem/UnpublishItemUseCase.js +12 -0
- package/UseCases/UnpublishItem/UnpublishItemUseCase.js.map +1 -0
- package/UseCases/UnpublishItem/index.d.ts +2 -0
- package/UseCases/UnpublishItem/index.js +3 -0
- package/UseCases/UnpublishItem/index.js.map +1 -0
- package/UseCases/index.d.ts +11 -0
- package/UseCases/index.js +13 -0
- package/UseCases/index.js.map +1 -0
- package/index.d.ts +1 -0
- package/index.js +3 -0
- package/index.js.map +1 -0
- package/package.json +55 -0
- package/types.d.ts +37 -0
- package/types.js +15 -0
- package/types.js.map +1 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ISortingRepository, Sorting } from "@webiny/app-utils";
|
|
2
|
+
export declare class SortingRepositoryWithDefaults implements ISortingRepository {
|
|
3
|
+
private readonly defaults;
|
|
4
|
+
private readonly repository;
|
|
5
|
+
constructor(defaults: Sorting[], repository: ISortingRepository);
|
|
6
|
+
get(): Sorting[];
|
|
7
|
+
set(sorts: Sorting[]): Promise<void>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { makeAutoObservable, runInAction } from "mobx";
|
|
2
|
+
export class SortingRepositoryWithDefaults {
|
|
3
|
+
constructor(defaults, repository) {
|
|
4
|
+
this.defaults = defaults;
|
|
5
|
+
this.repository = repository;
|
|
6
|
+
makeAutoObservable(this);
|
|
7
|
+
}
|
|
8
|
+
get() {
|
|
9
|
+
const existingSort = this.repository.get();
|
|
10
|
+
if (existingSort.length === 0) {
|
|
11
|
+
runInAction(() => {
|
|
12
|
+
this.set(this.defaults);
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
return this.repository.get();
|
|
16
|
+
}
|
|
17
|
+
set(sorts) {
|
|
18
|
+
return this.repository.set(sorts);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
//# sourceMappingURL=SortingRepositoryWithDefaults.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["makeAutoObservable","runInAction","SortingRepositoryWithDefaults","constructor","defaults","repository","get","existingSort","length","set","sorts"],"sources":["SortingRepositoryWithDefaults.ts"],"sourcesContent":["import { makeAutoObservable, runInAction } from \"mobx\";\nimport type { ISortingRepository, Sorting } from \"@webiny/app-utils\";\n\nexport class SortingRepositoryWithDefaults implements ISortingRepository {\n private readonly defaults: Sorting[];\n private readonly repository: ISortingRepository;\n\n public constructor(defaults: Sorting[], repository: ISortingRepository) {\n this.defaults = defaults;\n this.repository = repository;\n makeAutoObservable(this);\n }\n\n public get() {\n const existingSort = this.repository.get();\n\n if (existingSort.length === 0) {\n runInAction(() => {\n this.set(this.defaults);\n });\n }\n\n return this.repository.get();\n }\n\n public set(sorts: Sorting[]) {\n return this.repository.set(sorts);\n }\n}\n"],"mappings":"AAAA,SAASA,kBAAkB,EAAEC,WAAW,QAAQ,MAAM;AAGtD,OAAO,MAAMC,6BAA6B,CAA+B;EAI9DC,WAAWA,CAACC,QAAmB,EAAEC,UAA8B,EAAE;IACpE,IAAI,CAACD,QAAQ,GAAGA,QAAQ;IACxB,IAAI,CAACC,UAAU,GAAGA,UAAU;IAC5BL,kBAAkB,CAAC,IAAI,CAAC;EAC5B;EAEOM,GAAGA,CAAA,EAAG;IACT,MAAMC,YAAY,GAAG,IAAI,CAACF,UAAU,CAACC,GAAG,CAAC,CAAC;IAE1C,IAAIC,YAAY,CAACC,MAAM,KAAK,CAAC,EAAE;MAC3BP,WAAW,CAAC,MAAM;QACd,IAAI,CAACQ,GAAG,CAAC,IAAI,CAACL,QAAQ,CAAC;MAC3B,CAAC,CAAC;IACN;IAEA,OAAO,IAAI,CAACC,UAAU,CAACC,GAAG,CAAC,CAAC;EAChC;EAEOG,GAAGA,CAACC,KAAgB,EAAE;IACzB,OAAO,IAAI,CAACL,UAAU,CAACI,GAAG,CAACC,KAAK,CAAC;EACrC;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./SortingRepositoryWithDefaults.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./SortingRepositoryWithDefaults.js\";\n"],"mappings":"AAAA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./SelectedItems/index.js\";\nexport * from \"./Sorting/index.js\";\nexport * from \"./Search/index.js\";\nexport * from \"./SchedulerItems/index.js\";\n"],"mappings":"AAAA;AACA;AACA;AACA","ignoreList":[]}
|
package/Domain/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./Models/index.js\";\nexport * from \"./Repositories/index.js\";\n"],"mappings":"AAAA;AACA","ignoreList":[]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ApolloClient } from "apollo-client";
|
|
2
|
+
import type { ICancelScheduledActionGateway, ICancelScheduledActionGatewayParams } from "./abstractions/CancelScheduledActionGateway.js";
|
|
3
|
+
export declare class SchedulerCancelGraphQLGateway implements ICancelScheduledActionGateway {
|
|
4
|
+
private readonly client;
|
|
5
|
+
constructor(client: ApolloClient<object>);
|
|
6
|
+
execute(params: ICancelScheduledActionGatewayParams): Promise<void>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import gql from "graphql-tag";
|
|
2
|
+
const createScheduleCancelActionMutation = () => {
|
|
3
|
+
return gql`
|
|
4
|
+
mutation ScheduleCancelAction($namespace: String!, $id: ID!) {
|
|
5
|
+
scheduler {
|
|
6
|
+
cancelScheduledAction(namespace: $namespace, id: $id) {
|
|
7
|
+
data
|
|
8
|
+
error {
|
|
9
|
+
message
|
|
10
|
+
code
|
|
11
|
+
data
|
|
12
|
+
stack
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
`;
|
|
18
|
+
};
|
|
19
|
+
export class SchedulerCancelGraphQLGateway {
|
|
20
|
+
constructor(client) {
|
|
21
|
+
this.client = client;
|
|
22
|
+
}
|
|
23
|
+
async execute(params) {
|
|
24
|
+
const {
|
|
25
|
+
data: response,
|
|
26
|
+
errors
|
|
27
|
+
} = await this.client.mutate({
|
|
28
|
+
mutation: createScheduleCancelActionMutation(),
|
|
29
|
+
variables: {
|
|
30
|
+
namespace: params.namespace,
|
|
31
|
+
id: params.id
|
|
32
|
+
},
|
|
33
|
+
fetchPolicy: "no-cache"
|
|
34
|
+
});
|
|
35
|
+
const result = response?.scheduler?.cancelScheduledAction;
|
|
36
|
+
if (!result || errors?.length) {
|
|
37
|
+
console.error({
|
|
38
|
+
errors
|
|
39
|
+
});
|
|
40
|
+
throw new Error("Network error while canceling a scheduled action.");
|
|
41
|
+
}
|
|
42
|
+
if (!result.data) {
|
|
43
|
+
throw new Error(result.error?.message || "Could not cancel scheduled action.");
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
//# sourceMappingURL=SchedulerCancelGraphQLGateway.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["gql","createScheduleCancelActionMutation","SchedulerCancelGraphQLGateway","constructor","client","execute","params","data","response","errors","mutate","mutation","variables","namespace","id","fetchPolicy","result","scheduler","cancelScheduledAction","length","console","error","Error","message"],"sources":["SchedulerCancelGraphQLGateway.ts"],"sourcesContent":["import type { ApolloClient } from \"apollo-client\";\nimport gql from \"graphql-tag\";\nimport type { SchedulerErrorResponse } from \"~/types.js\";\nimport type {\n ICancelScheduledActionGateway,\n ICancelScheduledActionGatewayParams\n} from \"./abstractions/CancelScheduledActionGateway.js\";\n\nconst createScheduleCancelActionMutation = () => {\n return gql`\n mutation ScheduleCancelAction($namespace: String!, $id: ID!) {\n scheduler {\n cancelScheduledAction(namespace: $namespace, id: $id) {\n data\n error {\n message\n code\n data\n stack\n }\n }\n }\n }\n `;\n};\n\ninterface SchedulerCancelGraphQLMutationVariables {\n namespace: string;\n id: string;\n}\n\ninterface SchedulerCancelGraphQLMutationResponse {\n scheduler: {\n cancelScheduledAction: {\n data: boolean | null;\n error: SchedulerErrorResponse | null;\n };\n };\n}\n\nexport class SchedulerCancelGraphQLGateway implements ICancelScheduledActionGateway {\n private readonly client: ApolloClient<object>;\n\n public constructor(client: ApolloClient<object>) {\n this.client = client;\n }\n\n public async execute(params: ICancelScheduledActionGatewayParams) {\n const { data: response, errors } = await this.client.mutate<\n SchedulerCancelGraphQLMutationResponse,\n SchedulerCancelGraphQLMutationVariables\n >({\n mutation: createScheduleCancelActionMutation(),\n variables: {\n namespace: params.namespace,\n id: params.id\n },\n fetchPolicy: \"no-cache\"\n });\n\n const result = response?.scheduler?.cancelScheduledAction;\n if (!result || errors?.length) {\n console.error({\n errors\n });\n throw new Error(\"Network error while canceling a scheduled action.\");\n }\n\n if (!result.data) {\n throw new Error(result.error?.message || \"Could not cancel scheduled action.\");\n }\n }\n}\n"],"mappings":"AACA,OAAOA,GAAG,MAAM,aAAa;AAO7B,MAAMC,kCAAkC,GAAGA,CAAA,KAAM;EAC7C,OAAOD,GAAG;AACd;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;AAgBD,OAAO,MAAME,6BAA6B,CAA0C;EAGzEC,WAAWA,CAACC,MAA4B,EAAE;IAC7C,IAAI,CAACA,MAAM,GAAGA,MAAM;EACxB;EAEA,MAAaC,OAAOA,CAACC,MAA2C,EAAE;IAC9D,MAAM;MAAEC,IAAI,EAAEC,QAAQ;MAAEC;IAAO,CAAC,GAAG,MAAM,IAAI,CAACL,MAAM,CAACM,MAAM,CAGzD;MACEC,QAAQ,EAAEV,kCAAkC,CAAC,CAAC;MAC9CW,SAAS,EAAE;QACPC,SAAS,EAAEP,MAAM,CAACO,SAAS;QAC3BC,EAAE,EAAER,MAAM,CAACQ;MACf,CAAC;MACDC,WAAW,EAAE;IACjB,CAAC,CAAC;IAEF,MAAMC,MAAM,GAAGR,QAAQ,EAAES,SAAS,EAAEC,qBAAqB;IACzD,IAAI,CAACF,MAAM,IAAIP,MAAM,EAAEU,MAAM,EAAE;MAC3BC,OAAO,CAACC,KAAK,CAAC;QACVZ;MACJ,CAAC,CAAC;MACF,MAAM,IAAIa,KAAK,CAAC,mDAAmD,CAAC;IACxE;IAEA,IAAI,CAACN,MAAM,CAACT,IAAI,EAAE;MACd,MAAM,IAAIe,KAAK,CAACN,MAAM,CAACK,KAAK,EAAEE,OAAO,IAAI,oCAAoC,CAAC;IAClF;EACJ;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { ApolloClient } from "apollo-client";
|
|
2
|
+
import type { IGetScheduledActionGateway, IGetScheduledActionGatewayExecuteParams } from "./abstractions/GetScheduledActionGateway.js";
|
|
3
|
+
export declare const createGetScheduledActionQuery: () => import("graphql").DocumentNode;
|
|
4
|
+
export declare class SchedulerGetGraphQLGateway implements IGetScheduledActionGateway {
|
|
5
|
+
private readonly client;
|
|
6
|
+
constructor(client: ApolloClient<any>);
|
|
7
|
+
execute(params: IGetScheduledActionGatewayExecuteParams): Promise<{
|
|
8
|
+
id: string;
|
|
9
|
+
targetId: string;
|
|
10
|
+
namespace: string;
|
|
11
|
+
scheduledBy: {
|
|
12
|
+
id: string;
|
|
13
|
+
displayName: string;
|
|
14
|
+
type: string;
|
|
15
|
+
};
|
|
16
|
+
publishOn: Date | undefined;
|
|
17
|
+
unpublishOn: Date | undefined;
|
|
18
|
+
actionType: import("~/types.js").ScheduleActionType;
|
|
19
|
+
title: string;
|
|
20
|
+
} | null>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import gql from "graphql-tag";
|
|
2
|
+
import zod from "zod";
|
|
3
|
+
import { createZodError } from "@webiny/utils/createZodError.js";
|
|
4
|
+
import { schedulerEntrySchema } from "./schema/schedulerEntry.js";
|
|
5
|
+
import { createSchedulerEntryFields } from "./graphql/fields.js";
|
|
6
|
+
export const createGetScheduledActionQuery = () => {
|
|
7
|
+
return gql`
|
|
8
|
+
query GetTargetScheduledActionQuery($namespace: String!, $id: ID!) {
|
|
9
|
+
scheduler {
|
|
10
|
+
getTargetScheduledAction(namespace: $namespace, id: $id) {
|
|
11
|
+
data {
|
|
12
|
+
${createSchedulerEntryFields()}
|
|
13
|
+
}
|
|
14
|
+
error {
|
|
15
|
+
message
|
|
16
|
+
code
|
|
17
|
+
data
|
|
18
|
+
stack
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
`;
|
|
24
|
+
};
|
|
25
|
+
const schema = zod.object({
|
|
26
|
+
data: schedulerEntrySchema
|
|
27
|
+
});
|
|
28
|
+
export class SchedulerGetGraphQLGateway {
|
|
29
|
+
constructor(client) {
|
|
30
|
+
this.client = client;
|
|
31
|
+
}
|
|
32
|
+
async execute(params) {
|
|
33
|
+
const {
|
|
34
|
+
data: response,
|
|
35
|
+
errors
|
|
36
|
+
} = await this.client.query({
|
|
37
|
+
query: createGetScheduledActionQuery(),
|
|
38
|
+
variables: {
|
|
39
|
+
namespace: params.namespace,
|
|
40
|
+
id: params.id
|
|
41
|
+
},
|
|
42
|
+
fetchPolicy: "network-only"
|
|
43
|
+
});
|
|
44
|
+
const result = response?.scheduler?.getTargetScheduledAction;
|
|
45
|
+
if (!result || errors?.length) {
|
|
46
|
+
console.error({
|
|
47
|
+
errors
|
|
48
|
+
});
|
|
49
|
+
throw new Error("Network error while getting scheduled action.");
|
|
50
|
+
} else if (result.error) {
|
|
51
|
+
console.error({
|
|
52
|
+
error: result.error
|
|
53
|
+
});
|
|
54
|
+
throw new Error(result.error.message || "Could not fetch scheduled action.");
|
|
55
|
+
} else if (!result.data) {
|
|
56
|
+
return null;
|
|
57
|
+
}
|
|
58
|
+
const validated = await schema.safeParseAsync(result);
|
|
59
|
+
if (!validated.success) {
|
|
60
|
+
const err = createZodError(validated.error);
|
|
61
|
+
console.error(err);
|
|
62
|
+
console.log(JSON.stringify({
|
|
63
|
+
err,
|
|
64
|
+
ex: validated.error
|
|
65
|
+
}));
|
|
66
|
+
throw err;
|
|
67
|
+
}
|
|
68
|
+
return validated.data.data;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
//# sourceMappingURL=SchedulerGetGraphQLGateway.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["gql","zod","createZodError","schedulerEntrySchema","createSchedulerEntryFields","createGetScheduledActionQuery","schema","object","data","SchedulerGetGraphQLGateway","constructor","client","execute","params","response","errors","query","variables","namespace","id","fetchPolicy","result","scheduler","getTargetScheduledAction","length","console","error","Error","message","validated","safeParseAsync","success","err","log","JSON","stringify","ex"],"sources":["SchedulerGetGraphQLGateway.ts"],"sourcesContent":["import type { ApolloClient } from \"apollo-client\";\nimport gql from \"graphql-tag\";\nimport zod from \"zod\";\nimport { createZodError } from \"@webiny/utils/createZodError.js\";\nimport { schedulerEntrySchema } from \"./schema/schedulerEntry.js\";\nimport { createSchedulerEntryFields } from \"./graphql/fields.js\";\nimport type {\n IGetScheduledActionGateway,\n IGetScheduledActionGatewayExecuteParams\n} from \"./abstractions/GetScheduledActionGateway.js\";\nimport type { SchedulerEntry, SchedulerErrorResponse } from \"~/types.js\";\n\nexport const createGetScheduledActionQuery = () => {\n return gql`\n query GetTargetScheduledActionQuery($namespace: String!, $id: ID!) {\n scheduler {\n getTargetScheduledAction(namespace: $namespace, id: $id) {\n data {\n ${createSchedulerEntryFields()}\n }\n error {\n message\n code\n data\n stack\n }\n }\n }\n }\n `;\n};\n\ninterface SchedulerGetGraphQLQueryResponse {\n scheduler: {\n getTargetScheduledAction: {\n data: SchedulerEntry | null;\n error: SchedulerErrorResponse | null;\n };\n };\n}\n\nconst schema = zod.object({\n data: schedulerEntrySchema\n});\n\nexport class SchedulerGetGraphQLGateway implements IGetScheduledActionGateway {\n private readonly client: ApolloClient<any>;\n\n public constructor(client: ApolloClient<any>) {\n this.client = client;\n }\n\n public async execute(params: IGetScheduledActionGatewayExecuteParams) {\n const { data: response, errors } = await this.client.query<\n SchedulerGetGraphQLQueryResponse,\n IGetScheduledActionGatewayExecuteParams\n >({\n query: createGetScheduledActionQuery(),\n variables: {\n namespace: params.namespace,\n id: params.id\n },\n fetchPolicy: \"network-only\"\n });\n\n const result = response?.scheduler?.getTargetScheduledAction;\n if (!result || errors?.length) {\n console.error({\n errors\n });\n throw new Error(\"Network error while getting scheduled action.\");\n } else if (result.error) {\n console.error({\n error: result.error\n });\n throw new Error(result.error.message || \"Could not fetch scheduled action.\");\n } else if (!result.data) {\n return null;\n }\n\n const validated = await schema.safeParseAsync(result);\n if (!validated.success) {\n const err = createZodError(validated.error);\n console.error(err);\n console.log(\n JSON.stringify({\n err,\n ex: validated.error\n })\n );\n throw err;\n }\n\n return validated.data.data;\n }\n}\n"],"mappings":"AACA,OAAOA,GAAG,MAAM,aAAa;AAC7B,OAAOC,GAAG,MAAM,KAAK;AACrB,SAASC,cAAc,QAAQ,iCAAiC;AAChE,SAASC,oBAAoB;AAC7B,SAASC,0BAA0B;AAOnC,OAAO,MAAMC,6BAA6B,GAAGA,CAAA,KAAM;EAC/C,OAAOL,GAAG;AACd;AACA;AACA;AACA;AACA,0BAA0BI,0BAA0B,CAAC,CAAC;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;AAWD,MAAME,MAAM,GAAGL,GAAG,CAACM,MAAM,CAAC;EACtBC,IAAI,EAAEL;AACV,CAAC,CAAC;AAEF,OAAO,MAAMM,0BAA0B,CAAuC;EAGnEC,WAAWA,CAACC,MAAyB,EAAE;IAC1C,IAAI,CAACA,MAAM,GAAGA,MAAM;EACxB;EAEA,MAAaC,OAAOA,CAACC,MAA+C,EAAE;IAClE,MAAM;MAAEL,IAAI,EAAEM,QAAQ;MAAEC;IAAO,CAAC,GAAG,MAAM,IAAI,CAACJ,MAAM,CAACK,KAAK,CAGxD;MACEA,KAAK,EAAEX,6BAA6B,CAAC,CAAC;MACtCY,SAAS,EAAE;QACPC,SAAS,EAAEL,MAAM,CAACK,SAAS;QAC3BC,EAAE,EAAEN,MAAM,CAACM;MACf,CAAC;MACDC,WAAW,EAAE;IACjB,CAAC,CAAC;IAEF,MAAMC,MAAM,GAAGP,QAAQ,EAAEQ,SAAS,EAAEC,wBAAwB;IAC5D,IAAI,CAACF,MAAM,IAAIN,MAAM,EAAES,MAAM,EAAE;MAC3BC,OAAO,CAACC,KAAK,CAAC;QACVX;MACJ,CAAC,CAAC;MACF,MAAM,IAAIY,KAAK,CAAC,+CAA+C,CAAC;IACpE,CAAC,MAAM,IAAIN,MAAM,CAACK,KAAK,EAAE;MACrBD,OAAO,CAACC,KAAK,CAAC;QACVA,KAAK,EAAEL,MAAM,CAACK;MAClB,CAAC,CAAC;MACF,MAAM,IAAIC,KAAK,CAACN,MAAM,CAACK,KAAK,CAACE,OAAO,IAAI,mCAAmC,CAAC;IAChF,CAAC,MAAM,IAAI,CAACP,MAAM,CAACb,IAAI,EAAE;MACrB,OAAO,IAAI;IACf;IAEA,MAAMqB,SAAS,GAAG,MAAMvB,MAAM,CAACwB,cAAc,CAACT,MAAM,CAAC;IACrD,IAAI,CAACQ,SAAS,CAACE,OAAO,EAAE;MACpB,MAAMC,GAAG,GAAG9B,cAAc,CAAC2B,SAAS,CAACH,KAAK,CAAC;MAC3CD,OAAO,CAACC,KAAK,CAACM,GAAG,CAAC;MAClBP,OAAO,CAACQ,GAAG,CACPC,IAAI,CAACC,SAAS,CAAC;QACXH,GAAG;QACHI,EAAE,EAAEP,SAAS,CAACH;MAClB,CAAC,CACL,CAAC;MACD,MAAMM,GAAG;IACb;IAEA,OAAOH,SAAS,CAACrB,IAAI,CAACA,IAAI;EAC9B;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ApolloClient } from "apollo-client";
|
|
2
|
+
import type { IListScheduledActionsGateway, IListScheduledActionsGatewayExecuteParams, IListScheduledActionsGatewayExecuteResponse } from "./abstractions/ListScheduledActionsGateway.js";
|
|
3
|
+
export declare class SchedulerListGraphQLGateway implements IListScheduledActionsGateway {
|
|
4
|
+
private readonly client;
|
|
5
|
+
constructor(client: ApolloClient<any>);
|
|
6
|
+
execute(params: IListScheduledActionsGatewayExecuteParams): Promise<IListScheduledActionsGatewayExecuteResponse>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import gql from "graphql-tag";
|
|
2
|
+
import zod from "zod";
|
|
3
|
+
import { createZodError } from "@webiny/utils/createZodError.js";
|
|
4
|
+
import { schedulerEntrySchema } from "./schema/schedulerEntry.js";
|
|
5
|
+
import { createSchedulerEntryFields } from "./graphql/fields.js";
|
|
6
|
+
const createListScheduledActionsQuery = () => {
|
|
7
|
+
return gql`
|
|
8
|
+
query ListScheduledActions(
|
|
9
|
+
$namespace: String!
|
|
10
|
+
$where: ListScheduledActionsWhereInput
|
|
11
|
+
$sort: [ListScheduledActionsSorter!]
|
|
12
|
+
$limit: Int
|
|
13
|
+
$after: String
|
|
14
|
+
) {
|
|
15
|
+
scheduler {
|
|
16
|
+
listScheduledActions(
|
|
17
|
+
namespace: $namespace
|
|
18
|
+
where: $where
|
|
19
|
+
sort: $sort
|
|
20
|
+
limit: $limit
|
|
21
|
+
after: $after
|
|
22
|
+
) {
|
|
23
|
+
data {
|
|
24
|
+
${createSchedulerEntryFields()}
|
|
25
|
+
}
|
|
26
|
+
meta {
|
|
27
|
+
totalCount
|
|
28
|
+
cursor
|
|
29
|
+
hasMoreItems
|
|
30
|
+
}
|
|
31
|
+
error {
|
|
32
|
+
message
|
|
33
|
+
code
|
|
34
|
+
data
|
|
35
|
+
stack
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
`;
|
|
41
|
+
};
|
|
42
|
+
const schema = zod.object({
|
|
43
|
+
data: zod.array(schedulerEntrySchema),
|
|
44
|
+
meta: zod.object({
|
|
45
|
+
totalCount: zod.number(),
|
|
46
|
+
cursor: zod.string().nullable(),
|
|
47
|
+
hasMoreItems: zod.boolean()
|
|
48
|
+
})
|
|
49
|
+
});
|
|
50
|
+
export class SchedulerListGraphQLGateway {
|
|
51
|
+
constructor(client) {
|
|
52
|
+
this.client = client;
|
|
53
|
+
}
|
|
54
|
+
async execute(params) {
|
|
55
|
+
const {
|
|
56
|
+
data: response,
|
|
57
|
+
errors
|
|
58
|
+
} = await this.client.query({
|
|
59
|
+
query: createListScheduledActionsQuery(),
|
|
60
|
+
variables: {
|
|
61
|
+
namespace: params.namespace,
|
|
62
|
+
where: params.where,
|
|
63
|
+
limit: params.limit,
|
|
64
|
+
after: params.after,
|
|
65
|
+
sort: params.sort
|
|
66
|
+
},
|
|
67
|
+
fetchPolicy: "network-only"
|
|
68
|
+
});
|
|
69
|
+
const result = response?.scheduler?.listScheduledActions;
|
|
70
|
+
if (!result || errors?.length) {
|
|
71
|
+
console.error({
|
|
72
|
+
errors
|
|
73
|
+
});
|
|
74
|
+
throw new Error("Network error while listing scheduled actions.");
|
|
75
|
+
}
|
|
76
|
+
if (!result.data || !result.meta) {
|
|
77
|
+
throw new Error(result.error?.message || "Could not list schedule actions.");
|
|
78
|
+
}
|
|
79
|
+
const validated = await schema.safeParseAsync(result);
|
|
80
|
+
if (!validated.success) {
|
|
81
|
+
const err = createZodError(validated.error);
|
|
82
|
+
console.error(err);
|
|
83
|
+
throw err;
|
|
84
|
+
}
|
|
85
|
+
return {
|
|
86
|
+
items: validated.data.data,
|
|
87
|
+
meta: validated.data.meta
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
//# sourceMappingURL=SchedulerListGraphQLGateway.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["gql","zod","createZodError","schedulerEntrySchema","createSchedulerEntryFields","createListScheduledActionsQuery","schema","object","data","array","meta","totalCount","number","cursor","string","nullable","hasMoreItems","boolean","SchedulerListGraphQLGateway","constructor","client","execute","params","response","errors","query","variables","namespace","where","limit","after","sort","fetchPolicy","result","scheduler","listScheduledActions","length","console","error","Error","message","validated","safeParseAsync","success","err","items"],"sources":["SchedulerListGraphQLGateway.ts"],"sourcesContent":["import type { ApolloClient } from \"apollo-client\";\nimport gql from \"graphql-tag\";\nimport zod from \"zod\";\nimport { createZodError } from \"@webiny/utils/createZodError.js\";\nimport { schedulerEntrySchema } from \"./schema/schedulerEntry.js\";\nimport { createSchedulerEntryFields } from \"./graphql/fields.js\";\nimport type {\n IListScheduledActionsGateway,\n IListScheduledActionsGatewayExecuteParams,\n IListScheduledActionsGatewayExecuteResponse\n} from \"./abstractions/ListScheduledActionsGateway.js\";\nimport type { SchedulerEntry, SchedulerErrorResponse, SchedulerMetaResponse } from \"~/types.js\";\n\nconst createListScheduledActionsQuery = () => {\n return gql`\n query ListScheduledActions(\n $namespace: String!\n $where: ListScheduledActionsWhereInput\n $sort: [ListScheduledActionsSorter!]\n $limit: Int\n $after: String\n ) {\n scheduler {\n listScheduledActions(\n namespace: $namespace\n where: $where\n sort: $sort\n limit: $limit\n after: $after\n ) {\n data {\n ${createSchedulerEntryFields()}\n }\n meta {\n totalCount\n cursor\n hasMoreItems\n }\n error {\n message\n code\n data\n stack\n }\n }\n }\n }\n `;\n};\n\ninterface SchedulerListGraphQLQueryResponse {\n scheduler: {\n listScheduledActions: {\n data: SchedulerEntry[] | null;\n meta: SchedulerMetaResponse | null;\n error: SchedulerErrorResponse | null;\n };\n };\n}\n\nconst schema = zod.object({\n data: zod.array(schedulerEntrySchema),\n meta: zod.object({\n totalCount: zod.number(),\n cursor: zod.string().nullable(),\n hasMoreItems: zod.boolean()\n })\n});\n\nexport class SchedulerListGraphQLGateway implements IListScheduledActionsGateway {\n private readonly client: ApolloClient<any>;\n\n public constructor(client: ApolloClient<any>) {\n this.client = client;\n }\n\n public async execute(\n params: IListScheduledActionsGatewayExecuteParams\n ): Promise<IListScheduledActionsGatewayExecuteResponse> {\n const { data: response, errors } = await this.client.query<\n SchedulerListGraphQLQueryResponse,\n IListScheduledActionsGatewayExecuteParams\n >({\n query: createListScheduledActionsQuery(),\n variables: {\n namespace: params.namespace,\n where: params.where,\n limit: params.limit,\n after: params.after,\n sort: params.sort\n },\n fetchPolicy: \"network-only\"\n });\n\n const result = response?.scheduler?.listScheduledActions;\n if (!result || errors?.length) {\n console.error({\n errors\n });\n throw new Error(\"Network error while listing scheduled actions.\");\n }\n\n if (!result.data || !result.meta) {\n throw new Error(result.error?.message || \"Could not list schedule actions.\");\n }\n\n const validated = await schema.safeParseAsync(result);\n if (!validated.success) {\n const err = createZodError(validated.error);\n console.error(err);\n throw err;\n }\n\n return {\n items: validated.data.data,\n meta: validated.data.meta\n };\n }\n}\n"],"mappings":"AACA,OAAOA,GAAG,MAAM,aAAa;AAC7B,OAAOC,GAAG,MAAM,KAAK;AACrB,SAASC,cAAc,QAAQ,iCAAiC;AAChE,SAASC,oBAAoB;AAC7B,SAASC,0BAA0B;AAQnC,MAAMC,+BAA+B,GAAGA,CAAA,KAAM;EAC1C,OAAOL,GAAG;AACd;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0BI,0BAA0B,CAAC,CAAC;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;AAYD,MAAME,MAAM,GAAGL,GAAG,CAACM,MAAM,CAAC;EACtBC,IAAI,EAAEP,GAAG,CAACQ,KAAK,CAACN,oBAAoB,CAAC;EACrCO,IAAI,EAAET,GAAG,CAACM,MAAM,CAAC;IACbI,UAAU,EAAEV,GAAG,CAACW,MAAM,CAAC,CAAC;IACxBC,MAAM,EAAEZ,GAAG,CAACa,MAAM,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;IAC/BC,YAAY,EAAEf,GAAG,CAACgB,OAAO,CAAC;EAC9B,CAAC;AACL,CAAC,CAAC;AAEF,OAAO,MAAMC,2BAA2B,CAAyC;EAGtEC,WAAWA,CAACC,MAAyB,EAAE;IAC1C,IAAI,CAACA,MAAM,GAAGA,MAAM;EACxB;EAEA,MAAaC,OAAOA,CAChBC,MAAiD,EACG;IACpD,MAAM;MAAEd,IAAI,EAAEe,QAAQ;MAAEC;IAAO,CAAC,GAAG,MAAM,IAAI,CAACJ,MAAM,CAACK,KAAK,CAGxD;MACEA,KAAK,EAAEpB,+BAA+B,CAAC,CAAC;MACxCqB,SAAS,EAAE;QACPC,SAAS,EAAEL,MAAM,CAACK,SAAS;QAC3BC,KAAK,EAAEN,MAAM,CAACM,KAAK;QACnBC,KAAK,EAAEP,MAAM,CAACO,KAAK;QACnBC,KAAK,EAAER,MAAM,CAACQ,KAAK;QACnBC,IAAI,EAAET,MAAM,CAACS;MACjB,CAAC;MACDC,WAAW,EAAE;IACjB,CAAC,CAAC;IAEF,MAAMC,MAAM,GAAGV,QAAQ,EAAEW,SAAS,EAAEC,oBAAoB;IACxD,IAAI,CAACF,MAAM,IAAIT,MAAM,EAAEY,MAAM,EAAE;MAC3BC,OAAO,CAACC,KAAK,CAAC;QACVd;MACJ,CAAC,CAAC;MACF,MAAM,IAAIe,KAAK,CAAC,gDAAgD,CAAC;IACrE;IAEA,IAAI,CAACN,MAAM,CAACzB,IAAI,IAAI,CAACyB,MAAM,CAACvB,IAAI,EAAE;MAC9B,MAAM,IAAI6B,KAAK,CAACN,MAAM,CAACK,KAAK,EAAEE,OAAO,IAAI,kCAAkC,CAAC;IAChF;IAEA,MAAMC,SAAS,GAAG,MAAMnC,MAAM,CAACoC,cAAc,CAACT,MAAM,CAAC;IACrD,IAAI,CAACQ,SAAS,CAACE,OAAO,EAAE;MACpB,MAAMC,GAAG,GAAG1C,cAAc,CAACuC,SAAS,CAACH,KAAK,CAAC;MAC3CD,OAAO,CAACC,KAAK,CAACM,GAAG,CAAC;MAClB,MAAMA,GAAG;IACb;IAEA,OAAO;MACHC,KAAK,EAAEJ,SAAS,CAACjC,IAAI,CAACA,IAAI;MAC1BE,IAAI,EAAE+B,SAAS,CAACjC,IAAI,CAACE;IACzB,CAAC;EACL;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ApolloClient } from "apollo-client";
|
|
2
|
+
import type { ISchedulePublishActionGateway, ISchedulePublishActionGatewayExecuteParams, ISchedulePublishActionGatewayExecuteResponse } from "./abstractions/SchedulePublishActionGateway.js";
|
|
3
|
+
export declare class SchedulerPublishGraphQLGateway implements ISchedulePublishActionGateway {
|
|
4
|
+
private readonly client;
|
|
5
|
+
constructor(client: ApolloClient<any>);
|
|
6
|
+
execute(params: ISchedulePublishActionGatewayExecuteParams): Promise<ISchedulePublishActionGatewayExecuteResponse>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import zod from "zod";
|
|
2
|
+
import { schedulerEntrySchema } from "./schema/schedulerEntry.js";
|
|
3
|
+
import { createZodError } from "@webiny/utils/createZodError.js";
|
|
4
|
+
import gql from "graphql-tag";
|
|
5
|
+
import { createSchedulerEntryFields } from "./graphql/fields.js";
|
|
6
|
+
import { ScheduleActionType } from "../types.js";
|
|
7
|
+
const createSchedulePublishActionMutation = () => {
|
|
8
|
+
return gql`
|
|
9
|
+
mutation CreateSchedulePublishAction($namespace: String!, $targetId: ID!, $scheduleFor: DateTime, $actionType: ScheduleRecordType!) {
|
|
10
|
+
scheduler {
|
|
11
|
+
scheduleAction(namespace: $namespace, targetId: $targetId, scheduleFor: $scheduleFor, actionType: $actionType) {
|
|
12
|
+
data {
|
|
13
|
+
${createSchedulerEntryFields()}
|
|
14
|
+
}
|
|
15
|
+
error {
|
|
16
|
+
message
|
|
17
|
+
code
|
|
18
|
+
data
|
|
19
|
+
stack
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
`;
|
|
25
|
+
};
|
|
26
|
+
const schema = zod.object({
|
|
27
|
+
data: schedulerEntrySchema
|
|
28
|
+
});
|
|
29
|
+
export class SchedulerPublishGraphQLGateway {
|
|
30
|
+
constructor(client) {
|
|
31
|
+
this.client = client;
|
|
32
|
+
}
|
|
33
|
+
async execute(params) {
|
|
34
|
+
const {
|
|
35
|
+
data: response,
|
|
36
|
+
errors
|
|
37
|
+
} = await this.client.mutate({
|
|
38
|
+
mutation: createSchedulePublishActionMutation(),
|
|
39
|
+
variables: {
|
|
40
|
+
namespace: params.namespace,
|
|
41
|
+
targetId: params.targetId,
|
|
42
|
+
scheduleFor: params.scheduleOn,
|
|
43
|
+
actionType: ScheduleActionType.publish
|
|
44
|
+
},
|
|
45
|
+
fetchPolicy: "no-cache"
|
|
46
|
+
});
|
|
47
|
+
const result = response?.scheduler?.scheduleAction;
|
|
48
|
+
if (!result || errors?.length) {
|
|
49
|
+
console.error({
|
|
50
|
+
errors
|
|
51
|
+
});
|
|
52
|
+
throw new Error("Network error while scheduling an action.");
|
|
53
|
+
}
|
|
54
|
+
if (!result.data) {
|
|
55
|
+
throw new Error(result.error?.message || "Could execute schedule publish action.");
|
|
56
|
+
}
|
|
57
|
+
const validated = await schema.safeParseAsync(result);
|
|
58
|
+
if (!validated.success) {
|
|
59
|
+
throw createZodError(validated.error);
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
item: validated.data.data
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
//# sourceMappingURL=SchedulerPublishGraphQLGateway.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["zod","schedulerEntrySchema","createZodError","gql","createSchedulerEntryFields","ScheduleActionType","createSchedulePublishActionMutation","schema","object","data","SchedulerPublishGraphQLGateway","constructor","client","execute","params","response","errors","mutate","mutation","variables","namespace","targetId","scheduleFor","scheduleOn","actionType","publish","fetchPolicy","result","scheduler","scheduleAction","length","console","error","Error","message","validated","safeParseAsync","success","item"],"sources":["SchedulerPublishGraphQLGateway.ts"],"sourcesContent":["import type { ApolloClient } from \"apollo-client\";\nimport zod from \"zod\";\nimport { schedulerEntrySchema } from \"./schema/schedulerEntry.js\";\nimport { createZodError } from \"@webiny/utils/createZodError.js\";\nimport gql from \"graphql-tag\";\nimport { createSchedulerEntryFields } from \"./graphql/fields.js\";\nimport { type SchedulerEntry, type SchedulerErrorResponse, ScheduleActionType } from \"~/types.js\";\nimport type {\n ISchedulePublishActionGateway,\n ISchedulePublishActionGatewayExecuteParams,\n ISchedulePublishActionGatewayExecuteResponse\n} from \"./abstractions/SchedulePublishActionGateway.js\";\n\nconst createSchedulePublishActionMutation = () => {\n return gql`\n mutation CreateSchedulePublishAction($namespace: String!, $targetId: ID!, $scheduleFor: DateTime, $actionType: ScheduleRecordType!) {\n scheduler {\n scheduleAction(namespace: $namespace, targetId: $targetId, scheduleFor: $scheduleFor, actionType: $actionType) {\n data {\n ${createSchedulerEntryFields()}\n }\n error {\n message\n code\n data\n stack\n }\n }\n }\n }\n `;\n};\n\ninterface SchedulerPublishGraphQLMutationVariables {\n namespace: string;\n targetId: string;\n scheduleFor: Date;\n actionType: ScheduleActionType.publish;\n}\n\ninterface SchedulerPublishGraphQLMutationResponse {\n scheduler: {\n scheduleAction: {\n data: SchedulerEntry | null;\n error: SchedulerErrorResponse | null;\n };\n };\n}\n\nconst schema = zod.object({\n data: schedulerEntrySchema\n});\n\nexport class SchedulerPublishGraphQLGateway implements ISchedulePublishActionGateway {\n private readonly client: ApolloClient<any>;\n\n public constructor(client: ApolloClient<any>) {\n this.client = client;\n }\n\n public async execute(\n params: ISchedulePublishActionGatewayExecuteParams\n ): Promise<ISchedulePublishActionGatewayExecuteResponse> {\n const { data: response, errors } = await this.client.mutate<\n SchedulerPublishGraphQLMutationResponse,\n SchedulerPublishGraphQLMutationVariables\n >({\n mutation: createSchedulePublishActionMutation(),\n variables: {\n namespace: params.namespace,\n targetId: params.targetId,\n scheduleFor: params.scheduleOn,\n actionType: ScheduleActionType.publish\n },\n fetchPolicy: \"no-cache\"\n });\n\n const result = response?.scheduler?.scheduleAction;\n if (!result || errors?.length) {\n console.error({\n errors\n });\n throw new Error(\"Network error while scheduling an action.\");\n }\n\n if (!result.data) {\n throw new Error(result.error?.message || \"Could execute schedule publish action.\");\n }\n\n const validated = await schema.safeParseAsync(result);\n if (!validated.success) {\n throw createZodError(validated.error);\n }\n return {\n item: validated.data.data\n };\n }\n}\n"],"mappings":"AACA,OAAOA,GAAG,MAAM,KAAK;AACrB,SAASC,oBAAoB;AAC7B,SAASC,cAAc,QAAQ,iCAAiC;AAChE,OAAOC,GAAG,MAAM,aAAa;AAC7B,SAASC,0BAA0B;AACnC,SAA2DC,kBAAkB;AAO7E,MAAMC,mCAAmC,GAAGA,CAAA,KAAM;EAC9C,OAAOH,GAAG;AACd;AACA;AACA;AACA;AACA,0BAA0BC,0BAA0B,CAAC,CAAC;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;AAkBD,MAAMG,MAAM,GAAGP,GAAG,CAACQ,MAAM,CAAC;EACtBC,IAAI,EAAER;AACV,CAAC,CAAC;AAEF,OAAO,MAAMS,8BAA8B,CAA0C;EAG1EC,WAAWA,CAACC,MAAyB,EAAE;IAC1C,IAAI,CAACA,MAAM,GAAGA,MAAM;EACxB;EAEA,MAAaC,OAAOA,CAChBC,MAAkD,EACG;IACrD,MAAM;MAAEL,IAAI,EAAEM,QAAQ;MAAEC;IAAO,CAAC,GAAG,MAAM,IAAI,CAACJ,MAAM,CAACK,MAAM,CAGzD;MACEC,QAAQ,EAAEZ,mCAAmC,CAAC,CAAC;MAC/Ca,SAAS,EAAE;QACPC,SAAS,EAAEN,MAAM,CAACM,SAAS;QAC3BC,QAAQ,EAAEP,MAAM,CAACO,QAAQ;QACzBC,WAAW,EAAER,MAAM,CAACS,UAAU;QAC9BC,UAAU,EAAEnB,kBAAkB,CAACoB;MACnC,CAAC;MACDC,WAAW,EAAE;IACjB,CAAC,CAAC;IAEF,MAAMC,MAAM,GAAGZ,QAAQ,EAAEa,SAAS,EAAEC,cAAc;IAClD,IAAI,CAACF,MAAM,IAAIX,MAAM,EAAEc,MAAM,EAAE;MAC3BC,OAAO,CAACC,KAAK,CAAC;QACVhB;MACJ,CAAC,CAAC;MACF,MAAM,IAAIiB,KAAK,CAAC,2CAA2C,CAAC;IAChE;IAEA,IAAI,CAACN,MAAM,CAAClB,IAAI,EAAE;MACd,MAAM,IAAIwB,KAAK,CAACN,MAAM,CAACK,KAAK,EAAEE,OAAO,IAAI,wCAAwC,CAAC;IACtF;IAEA,MAAMC,SAAS,GAAG,MAAM5B,MAAM,CAAC6B,cAAc,CAACT,MAAM,CAAC;IACrD,IAAI,CAACQ,SAAS,CAACE,OAAO,EAAE;MACpB,MAAMnC,cAAc,CAACiC,SAAS,CAACH,KAAK,CAAC;IACzC;IACA,OAAO;MACHM,IAAI,EAAEH,SAAS,CAAC1B,IAAI,CAACA;IACzB,CAAC;EACL;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { ApolloClient } from "apollo-client";
|
|
2
|
+
import { ScheduleActionType } from "../types.js";
|
|
3
|
+
import type { IScheduleUnpublishActionGateway, IScheduleUnpublishActionGatewayExecuteParams } from "./abstractions/ScheduleUnpublishActionGateway.js";
|
|
4
|
+
export declare class SchedulerUnpublishGraphQLGateway implements IScheduleUnpublishActionGateway {
|
|
5
|
+
private readonly client;
|
|
6
|
+
constructor(client: ApolloClient<any>);
|
|
7
|
+
execute(params: IScheduleUnpublishActionGatewayExecuteParams): Promise<{
|
|
8
|
+
item: {
|
|
9
|
+
id: string;
|
|
10
|
+
targetId: string;
|
|
11
|
+
namespace: string;
|
|
12
|
+
scheduledBy: {
|
|
13
|
+
id: string;
|
|
14
|
+
displayName: string;
|
|
15
|
+
type: string;
|
|
16
|
+
};
|
|
17
|
+
publishOn: Date | undefined;
|
|
18
|
+
unpublishOn: Date | undefined;
|
|
19
|
+
actionType: ScheduleActionType;
|
|
20
|
+
title: string;
|
|
21
|
+
};
|
|
22
|
+
}>;
|
|
23
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import zod from "zod";
|
|
2
|
+
import { schedulerEntrySchema } from "./schema/schedulerEntry.js";
|
|
3
|
+
import { createZodError } from "@webiny/utils/createZodError.js";
|
|
4
|
+
import gql from "graphql-tag";
|
|
5
|
+
import { createSchedulerEntryFields } from "./graphql/fields.js";
|
|
6
|
+
import { ScheduleActionType } from "../types.js";
|
|
7
|
+
const createScheduleUnpublishActionMutation = () => {
|
|
8
|
+
return gql`
|
|
9
|
+
mutation ScheduleUnpublishAction($namespace: String!, $targetId: ID!, $scheduleFor: DateTime, $actionType: ScheduleRecordType!) {
|
|
10
|
+
scheduler {
|
|
11
|
+
scheduleAction(namespace: $namespace, targetId: $targetId, scheduleFor: $scheduleFor, actionType: $actionType) {
|
|
12
|
+
data {
|
|
13
|
+
${createSchedulerEntryFields()}
|
|
14
|
+
}
|
|
15
|
+
error {
|
|
16
|
+
message
|
|
17
|
+
code
|
|
18
|
+
data
|
|
19
|
+
stack
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
`;
|
|
25
|
+
};
|
|
26
|
+
const schema = zod.object({
|
|
27
|
+
data: schedulerEntrySchema
|
|
28
|
+
});
|
|
29
|
+
export class SchedulerUnpublishGraphQLGateway {
|
|
30
|
+
constructor(client) {
|
|
31
|
+
this.client = client;
|
|
32
|
+
}
|
|
33
|
+
async execute(params) {
|
|
34
|
+
const {
|
|
35
|
+
data: response,
|
|
36
|
+
errors
|
|
37
|
+
} = await this.client.mutate({
|
|
38
|
+
mutation: createScheduleUnpublishActionMutation(),
|
|
39
|
+
variables: {
|
|
40
|
+
namespace: params.namespace,
|
|
41
|
+
targetId: params.targetId,
|
|
42
|
+
scheduleFor: params.scheduleOn,
|
|
43
|
+
actionType: ScheduleActionType.unpublish
|
|
44
|
+
},
|
|
45
|
+
fetchPolicy: "no-cache"
|
|
46
|
+
});
|
|
47
|
+
const result = response?.scheduler?.scheduleAction;
|
|
48
|
+
if (!result || errors?.length) {
|
|
49
|
+
console.error({
|
|
50
|
+
errors
|
|
51
|
+
});
|
|
52
|
+
throw new Error("Network error while creating a schedule.");
|
|
53
|
+
}
|
|
54
|
+
if (!result.data) {
|
|
55
|
+
throw new Error(result.error?.message || "Could execute schedule unpublish action.");
|
|
56
|
+
}
|
|
57
|
+
const validated = await schema.safeParseAsync(result);
|
|
58
|
+
if (!validated.success) {
|
|
59
|
+
const err = createZodError(validated.error);
|
|
60
|
+
console.error(err);
|
|
61
|
+
throw err;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
item: validated.data.data
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
//# sourceMappingURL=SchedulerUnpublishGraphQLGateway.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["zod","schedulerEntrySchema","createZodError","gql","createSchedulerEntryFields","ScheduleActionType","createScheduleUnpublishActionMutation","schema","object","data","SchedulerUnpublishGraphQLGateway","constructor","client","execute","params","response","errors","mutate","mutation","variables","namespace","targetId","scheduleFor","scheduleOn","actionType","unpublish","fetchPolicy","result","scheduler","scheduleAction","length","console","error","Error","message","validated","safeParseAsync","success","err","item"],"sources":["SchedulerUnpublishGraphQLGateway.ts"],"sourcesContent":["import type { ApolloClient } from \"apollo-client\";\nimport zod from \"zod\";\nimport { schedulerEntrySchema } from \"./schema/schedulerEntry.js\";\nimport { createZodError } from \"@webiny/utils/createZodError.js\";\nimport gql from \"graphql-tag\";\nimport { createSchedulerEntryFields } from \"./graphql/fields.js\";\nimport { type SchedulerEntry, type SchedulerErrorResponse, ScheduleActionType } from \"~/types.js\";\nimport type {\n IScheduleUnpublishActionGateway,\n IScheduleUnpublishActionGatewayExecuteParams\n} from \"./abstractions/ScheduleUnpublishActionGateway.js\";\n\nconst createScheduleUnpublishActionMutation = () => {\n return gql`\n mutation ScheduleUnpublishAction($namespace: String!, $targetId: ID!, $scheduleFor: DateTime, $actionType: ScheduleRecordType!) {\n scheduler {\n scheduleAction(namespace: $namespace, targetId: $targetId, scheduleFor: $scheduleFor, actionType: $actionType) {\n data {\n ${createSchedulerEntryFields()}\n }\n error {\n message\n code\n data\n stack\n }\n }\n }\n }\n `;\n};\n\ninterface SchedulerUnpublishGraphQLMutationVariables {\n namespace: string;\n targetId: string;\n scheduleFor: Date;\n actionType: ScheduleActionType.unpublish;\n}\n\ninterface SchedulerUnpublishGraphQLMutationResponse {\n scheduler: {\n scheduleAction: {\n data: SchedulerEntry | null;\n error: SchedulerErrorResponse | null;\n };\n };\n}\n\nconst schema = zod.object({\n data: schedulerEntrySchema\n});\n\nexport class SchedulerUnpublishGraphQLGateway implements IScheduleUnpublishActionGateway {\n private readonly client: ApolloClient<any>;\n\n public constructor(client: ApolloClient<any>) {\n this.client = client;\n }\n\n public async execute(params: IScheduleUnpublishActionGatewayExecuteParams) {\n const { data: response, errors } = await this.client.mutate<\n SchedulerUnpublishGraphQLMutationResponse,\n SchedulerUnpublishGraphQLMutationVariables\n >({\n mutation: createScheduleUnpublishActionMutation(),\n variables: {\n namespace: params.namespace,\n targetId: params.targetId,\n scheduleFor: params.scheduleOn,\n actionType: ScheduleActionType.unpublish\n },\n fetchPolicy: \"no-cache\"\n });\n\n const result = response?.scheduler?.scheduleAction;\n if (!result || errors?.length) {\n console.error({\n errors\n });\n throw new Error(\"Network error while creating a schedule.\");\n }\n\n if (!result.data) {\n throw new Error(result.error?.message || \"Could execute schedule unpublish action.\");\n }\n\n const validated = await schema.safeParseAsync(result);\n if (!validated.success) {\n const err = createZodError(validated.error);\n console.error(err);\n throw err;\n }\n return {\n item: validated.data.data\n };\n }\n}\n"],"mappings":"AACA,OAAOA,GAAG,MAAM,KAAK;AACrB,SAASC,oBAAoB;AAC7B,SAASC,cAAc,QAAQ,iCAAiC;AAChE,OAAOC,GAAG,MAAM,aAAa;AAC7B,SAASC,0BAA0B;AACnC,SAA2DC,kBAAkB;AAM7E,MAAMC,qCAAqC,GAAGA,CAAA,KAAM;EAChD,OAAOH,GAAG;AACd;AACA;AACA;AACA;AACA,0BAA0BC,0BAA0B,CAAC,CAAC;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;AAkBD,MAAMG,MAAM,GAAGP,GAAG,CAACQ,MAAM,CAAC;EACtBC,IAAI,EAAER;AACV,CAAC,CAAC;AAEF,OAAO,MAAMS,gCAAgC,CAA4C;EAG9EC,WAAWA,CAACC,MAAyB,EAAE;IAC1C,IAAI,CAACA,MAAM,GAAGA,MAAM;EACxB;EAEA,MAAaC,OAAOA,CAACC,MAAoD,EAAE;IACvE,MAAM;MAAEL,IAAI,EAAEM,QAAQ;MAAEC;IAAO,CAAC,GAAG,MAAM,IAAI,CAACJ,MAAM,CAACK,MAAM,CAGzD;MACEC,QAAQ,EAAEZ,qCAAqC,CAAC,CAAC;MACjDa,SAAS,EAAE;QACPC,SAAS,EAAEN,MAAM,CAACM,SAAS;QAC3BC,QAAQ,EAAEP,MAAM,CAACO,QAAQ;QACzBC,WAAW,EAAER,MAAM,CAACS,UAAU;QAC9BC,UAAU,EAAEnB,kBAAkB,CAACoB;MACnC,CAAC;MACDC,WAAW,EAAE;IACjB,CAAC,CAAC;IAEF,MAAMC,MAAM,GAAGZ,QAAQ,EAAEa,SAAS,EAAEC,cAAc;IAClD,IAAI,CAACF,MAAM,IAAIX,MAAM,EAAEc,MAAM,EAAE;MAC3BC,OAAO,CAACC,KAAK,CAAC;QACVhB;MACJ,CAAC,CAAC;MACF,MAAM,IAAIiB,KAAK,CAAC,0CAA0C,CAAC;IAC/D;IAEA,IAAI,CAACN,MAAM,CAAClB,IAAI,EAAE;MACd,MAAM,IAAIwB,KAAK,CAACN,MAAM,CAACK,KAAK,EAAEE,OAAO,IAAI,0CAA0C,CAAC;IACxF;IAEA,MAAMC,SAAS,GAAG,MAAM5B,MAAM,CAAC6B,cAAc,CAACT,MAAM,CAAC;IACrD,IAAI,CAACQ,SAAS,CAACE,OAAO,EAAE;MACpB,MAAMC,GAAG,GAAGpC,cAAc,CAACiC,SAAS,CAACH,KAAK,CAAC;MAC3CD,OAAO,CAACC,KAAK,CAACM,GAAG,CAAC;MAClB,MAAMA,GAAG;IACb;IACA,OAAO;MACHC,IAAI,EAAEJ,SAAS,CAAC1B,IAAI,CAACA;IACzB,CAAC;EACL;AACJ","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["CancelScheduledActionGateway.ts"],"sourcesContent":["export interface ICancelScheduledActionGatewayParams {\n namespace: string;\n id: string;\n}\n\nexport interface ICancelScheduledActionGateway {\n execute(params: ICancelScheduledActionGatewayParams): Promise<void>;\n}\n"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { SchedulerEntry } from "../../types.js";
|
|
2
|
+
export interface IGetScheduledActionGatewayExecuteParams {
|
|
3
|
+
namespace: string;
|
|
4
|
+
id: string;
|
|
5
|
+
}
|
|
6
|
+
export type IGetScheduledActionGatewayResponse = SchedulerEntry | null;
|
|
7
|
+
export interface IGetScheduledActionGateway {
|
|
8
|
+
execute(params: IGetScheduledActionGatewayExecuteParams): Promise<IGetScheduledActionGatewayResponse>;
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["GetScheduledActionGateway.ts"],"sourcesContent":["import type { SchedulerEntry } from \"~/types.js\";\n\nexport interface IGetScheduledActionGatewayExecuteParams {\n namespace: string;\n id: string;\n}\n\nexport type IGetScheduledActionGatewayResponse = SchedulerEntry | null;\n\nexport interface IGetScheduledActionGateway {\n execute(\n params: IGetScheduledActionGatewayExecuteParams\n ): Promise<IGetScheduledActionGatewayResponse>;\n}\n"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { SchedulerEntry, SchedulerMetaResponse } from "../../types.js";
|
|
2
|
+
import type { ScheduleActionType } from "../../types.js";
|
|
3
|
+
export interface IListScheduledActionsExecuteParamsWhere {
|
|
4
|
+
targetId?: string;
|
|
5
|
+
title_contains?: string;
|
|
6
|
+
title_not_contains?: string;
|
|
7
|
+
type?: ScheduleActionType;
|
|
8
|
+
scheduledBy?: string;
|
|
9
|
+
scheduledFor?: Date;
|
|
10
|
+
scheduledFor_gte?: Date;
|
|
11
|
+
scheduledFor_lte?: Date;
|
|
12
|
+
}
|
|
13
|
+
export type IListScheduledActionsExecuteParamsSort = "scheduledFor_ASC" | "scheduledFor_DESC";
|
|
14
|
+
export interface IListScheduledActionsGatewayExecuteParams {
|
|
15
|
+
namespace: string;
|
|
16
|
+
where?: IListScheduledActionsExecuteParamsWhere;
|
|
17
|
+
sort?: IListScheduledActionsExecuteParamsSort[];
|
|
18
|
+
limit?: number;
|
|
19
|
+
after?: string;
|
|
20
|
+
}
|
|
21
|
+
export interface IListScheduledActionsGatewayExecuteResponse {
|
|
22
|
+
items: SchedulerEntry[];
|
|
23
|
+
meta: SchedulerMetaResponse;
|
|
24
|
+
}
|
|
25
|
+
export interface IListScheduledActionsGateway {
|
|
26
|
+
execute(params: IListScheduledActionsGatewayExecuteParams): Promise<IListScheduledActionsGatewayExecuteResponse>;
|
|
27
|
+
}
|