PluginProbe ʕ •ᴥ•ʔ
Booking for Appointments and Events Calendar – Amelia / trunk
Booking for Appointments and Events Calendar – Amelia vtrunk
2.4.4 2.4.3 2.4.2 2.4.1 2.4 trunk 1.2.1 1.2.10 1.2.11 1.2.12 1.2.13 1.2.14 1.2.15 1.2.16 1.2.17 1.2.18 1.2.19 1.2.2 1.2.20 1.2.21 1.2.22 1.2.23 1.2.24 1.2.25 1.2.26 1.2.27 1.2.28 1.2.29 1.2.3 1.2.30 1.2.31 1.2.32 1.2.33 1.2.34 1.2.35 1.2.36 1.2.37 1.2.38 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 2.0 2.0.1 2.0.2 2.1 2.1.1 2.1.2 2.1.3 2.2 2.2.1 2.3
ameliabooking / src / Infrastructure / Licence / Lite / Licence.php
ameliabooking / src / Infrastructure / Licence / Lite Last commit date
ApplicationService.php 8 months ago DataModifier.php 4 months ago DomainService.php 2 years ago EventListener.php 1 year ago InfrastructureService.php 4 months ago Licence.php 3 months ago
Licence.php
229 lines
1 <?php
2
3 namespace AmeliaBooking\Infrastructure\Licence\Lite;
4
5 use AmeliaBooking\Application\Commands;
6 use AmeliaBooking\Infrastructure\Common\Container;
7 use AmeliaBooking\Infrastructure\Licence\LicenceConstants;
8 use AmeliaBooking\Infrastructure\Routes;
9 use Slim\App;
10
11 /**
12 * Class Licence
13 *
14 * @package AmeliaBooking\Infrastructure\Licence\Lite
15 */
16 class Licence
17 {
18 public static $premium = false;
19
20 public static $licence = LicenceConstants::LITE;
21
22 /**
23 * @param Container $c
24 */
25 public static function getCommands($c)
26 {
27 return [
28 // Test
29 Commands\Test\TestCommand::class => new Commands\Test\TestCommandHandler($c),
30 // Stash
31 Commands\Stash\UpdateStashCommand::class => new Commands\Stash\UpdateStashCommandHandler($c),
32 // Bookable/Category
33 Commands\Bookable\Category\AddCategoryCommand::class => new Commands\Bookable\Category\AddCategoryCommandHandler($c),
34 Commands\Bookable\Category\DeleteCategoryCommand::class => new Commands\Bookable\Category\DeleteCategoryCommandHandler($c),
35 Commands\Bookable\Category\GetCategoriesCommand::class => new Commands\Bookable\Category\GetCategoriesCommandHandler($c),
36 Commands\Bookable\Category\GetCategoryCommand::class => new Commands\Bookable\Category\GetCategoryCommandHandler($c),
37 Commands\Bookable\Category\GetCategoryDeleteEffectCommand::class =>
38 new Commands\Bookable\Category\GetCategoryDeleteEffectCommandHandler($c),
39 Commands\Bookable\Category\UpdateCategoriesPositionsCommand::class =>
40 new Commands\Bookable\Category\UpdateCategoriesPositionsCommandHandler($c),
41 Commands\Bookable\Category\UpdateCategoryCommand::class => new Commands\Bookable\Category\UpdateCategoryCommandHandler($c),
42 // Bookable/Service
43 Commands\Bookable\Service\AddServiceCommand::class => new Commands\Bookable\Service\AddServiceCommandHandler($c),
44 Commands\Bookable\Service\DeleteServiceCommand::class => new Commands\Bookable\Service\DeleteServiceCommandHandler($c),
45 Commands\Bookable\Service\GetServiceCommand::class => new Commands\Bookable\Service\GetServiceCommandHandler($c),
46 Commands\Bookable\Service\GetServiceDeleteEffectCommand::class =>
47 new Commands\Bookable\Service\GetServiceDeleteEffectCommandHandler($c),
48 Commands\Bookable\Service\GetServicesCommand::class => new Commands\Bookable\Service\GetServicesCommandHandler($c),
49 Commands\Bookable\Service\UpdateServiceCommand::class =>
50 new Commands\Bookable\Service\UpdateServiceCommandHandler($c),
51 Commands\Bookable\Service\UpdateServiceStatusCommand::class =>
52 new Commands\Bookable\Service\UpdateServiceStatusCommandHandler($c),
53 Commands\Bookable\Service\UpdateServicesPositionsCommand::class =>
54 new Commands\Bookable\Service\UpdateServicesPositionsCommandHandler($c),
55 // Booking/Event
56 Commands\Booking\Event\AddEventCommand::class => new Commands\Booking\Event\AddEventCommandHandler($c),
57 Commands\Booking\Event\GetEventCommand::class => new Commands\Booking\Event\GetEventCommandHandler($c),
58 Commands\Booking\Event\GetEventsCommand::class => new Commands\Booking\Event\GetEventsCommandHandler($c),
59 Commands\Booking\Event\GetEventBookingsCommand::class => new Commands\Booking\Event\GetEventBookingsCommandHandler($c),
60 Commands\Booking\Event\GetEventBookingCommand::class => new Commands\Booking\Event\GetEventBookingCommandHandler($c),
61 Commands\Booking\Event\UpdateEventCommand::class => new Commands\Booking\Event\UpdateEventCommandHandler($c),
62 Commands\Booking\Event\UpdateEventStatusCommand::class => new Commands\Booking\Event\UpdateEventStatusCommandHandler($c),
63 Commands\Booking\Event\UpdateEventVisibilityCommand::class => new Commands\Booking\Event\UpdateEventVisibilityCommandHandler($c),
64 Commands\Booking\Event\DeleteEventBookingCommand::class => new Commands\Booking\Event\DeleteEventBookingCommandHandler($c),
65 Commands\Booking\Event\UpdateEventBookingCommand::class => new Commands\Booking\Event\UpdateEventBookingCommandHandler($c),
66 Commands\Booking\Event\DeleteEventCommand::class => new Commands\Booking\Event\DeleteEventCommandHandler($c),
67 Commands\Booking\Event\DeleteEventsCommand::class => new Commands\Booking\Event\DeleteEventsCommandHandler($c),
68 Commands\Booking\Event\GetCalendarEventsCommand::class => new Commands\Booking\Event\GetCalendarEventsCommandHandler($c),
69 // Booking/Appointment
70 Commands\Booking\Appointment\AddAppointmentCommand::class => new Commands\Booking\Appointment\AddAppointmentCommandHandler($c),
71 Commands\Booking\Appointment\AddBookingCommand::class => new Commands\Booking\Appointment\AddBookingCommandHandler($c),
72 Commands\Booking\Appointment\DeleteBookingCommand::class => new Commands\Booking\Appointment\DeleteBookingCommandHandler($c),
73 Commands\Booking\Appointment\UpdateBookingStatusCommand::class =>
74 new Commands\Booking\Appointment\UpdateBookingStatusCommandHandler($c),
75 Commands\Booking\Appointment\CancelBookingCommand::class => new Commands\Booking\Appointment\CancelBookingCommandHandler($c),
76 Commands\Booking\Appointment\CancelBookingRemotelyCommand::class =>
77 new Commands\Booking\Appointment\CancelBookingRemotelyCommandHandler($c),
78 Commands\Booking\Appointment\RejectBookingRemotelyCommand::class =>
79 new Commands\Booking\Appointment\RejectBookingRemotelyCommandHandler($c),
80 Commands\Booking\Appointment\ApproveBookingRemotelyCommand::class =>
81 new Commands\Booking\Appointment\ApproveBookingRemotelyCommandHandler($c),
82 Commands\Booking\Appointment\DeleteAppointmentCommand::class =>
83 new Commands\Booking\Appointment\DeleteAppointmentCommandHandler($c),
84 Commands\Booking\Appointment\GetAppointmentCommand::class => new Commands\Booking\Appointment\GetAppointmentCommandHandler($c),
85 Commands\Booking\Appointment\GetAppointmentsCommand::class => new Commands\Booking\Appointment\GetAppointmentsCommandHandler($c),
86 Commands\Booking\Appointment\GetIcsCommand::class => new Commands\Booking\Appointment\GetIcsCommandHandler($c),
87 Commands\Booking\Appointment\GetTimeSlotsCommand::class => new Commands\Booking\Appointment\GetTimeSlotsCommandHandler($c),
88 Commands\Booking\Appointment\UpdateAppointmentCommand::class =>
89 new Commands\Booking\Appointment\UpdateAppointmentCommandHandler($c),
90 Commands\Booking\Appointment\UpdateAppointmentNoteCommand::class =>
91 new Commands\Booking\Appointment\UpdateAppointmentNoteCommandHandler($c),
92 Commands\Booking\Appointment\UpdateAppointmentStatusCommand::class =>
93 new Commands\Booking\Appointment\UpdateAppointmentStatusCommandHandler($c),
94 Commands\Booking\Appointment\UpdateAppointmentTimeCommand::class =>
95 new Commands\Booking\Appointment\UpdateAppointmentTimeCommandHandler($c),
96 Commands\Booking\Appointment\ReassignBookingCommand::class => new Commands\Booking\Appointment\ReassignBookingCommandHandler($c),
97 Commands\Booking\Appointment\SuccessfulBookingCommand::class =>
98 new Commands\Booking\Appointment\SuccessfulBookingCommandHandler($c),
99 Commands\Booking\Appointment\GetAppointmentBookingsCommand::class =>
100 new Commands\Booking\Appointment\GetAppointmentBookingsCommandHandler($c),
101 // Entities
102 Commands\Entities\GetEntitiesCommand::class => new Commands\Entities\GetEntitiesCommandHandler($c),
103 // Notification
104 Commands\Notification\GetNotificationsCommand::class => new Commands\Notification\GetNotificationsCommandHandler($c),
105 Commands\Notification\SendUndeliveredNotificationsCommand::class =>
106 new Commands\Notification\SendUndeliveredNotificationsCommandHandler($c),
107 Commands\Notification\SendTestEmailCommand::class => new Commands\Notification\SendTestEmailCommandHandler($c),
108 Commands\Notification\UpdateNotificationCommand::class => new Commands\Notification\UpdateNotificationCommandHandler($c),
109 Commands\Notification\UpdateNotificationStatusCommand::class =>
110 new Commands\Notification\UpdateNotificationStatusCommandHandler($c),
111 Commands\Notification\SendAmeliaSmsApiRequestCommand::class =>
112 new Commands\Notification\SendAmeliaSmsApiRequestCommandHandler($c),
113 Commands\Notification\UpdateSMSNotificationHistoryCommand::class =>
114 new Commands\Notification\UpdateSMSNotificationHistoryCommandHandler($c),
115 Commands\Notification\UpdateSMSNotificationHistoryDirectlyCommand::class =>
116 new Commands\Notification\UpdateSMSNotificationHistoryDirectlyCommandHandler($c),
117 Commands\Notification\GetSMSNotificationsHistoryCommand::class =>
118 new Commands\Notification\GetSMSNotificationsHistoryCommandHandler($c),
119 Commands\Notification\ValidateSMTPCredentialsCommand::class =>
120 new Commands\Notification\ValidateSMTPCredentialsCommandHandler($c),
121 // Payment
122 Commands\Payment\AddPaymentCommand::class => new Commands\Payment\AddPaymentCommandHandler($c),
123 Commands\Payment\DeletePaymentCommand::class => new Commands\Payment\DeletePaymentCommandHandler($c),
124 Commands\Payment\GetPaymentCommand::class => new Commands\Payment\GetPaymentCommandHandler($c),
125 Commands\Payment\GetPaymentsCommand::class => new Commands\Payment\GetPaymentsCommandHandler($c),
126 Commands\Payment\UpdatePaymentCommand::class => new Commands\Payment\UpdatePaymentCommandHandler($c),
127 Commands\Payment\CalculatePaymentAmountCommand::class => new Commands\Payment\CalculatePaymentAmountCommandHandler($c),
128 //Square
129 Commands\Square\DisconnectFromSquareAccountCommand::class => new Commands\Square\DisconnectFromSquareAccountCommandHandler($c),
130 Commands\Square\DisconnectFromSquareAccountDirectlyCommand::class =>
131 new Commands\Square\DisconnectFromSquareAccountDirectlyCommandHandler($c),
132 Commands\Square\FetchAccessTokenSquareCommand::class => new Commands\Square\FetchAccessTokenSquareCommandHandler($c),
133 Commands\Square\GetSquareAuthURLCommand::class => new Commands\Square\GetSquareAuthURLCommandHandler($c),
134 Commands\Square\SquareRefundWebhookCommand::class => new Commands\Square\SquareRefundWebhookCommandHandler($c),
135 // Settings
136 Commands\Settings\GetSettingsCommand::class => new Commands\Settings\GetSettingsCommandHandler($c),
137 Commands\Settings\UpdateSettingsCommand::class => new Commands\Settings\UpdateSettingsCommandHandler($c),
138 Commands\Settings\UpdateSettingsCategoriesCommand::class => new Commands\Settings\UpdateSettingsCategoriesCommandHandler($c),
139 // Features & Integrations
140 Commands\Settings\FeaturesIntegrations\ToggleFeatureIntegrationCommand::class =>
141 new Commands\Settings\FeaturesIntegrations\ToggleFeatureIntegrationCommandHandler($c),
142 // Status
143 Commands\Stats\GetStatsCommand::class => new Commands\Stats\GetStatsCommandHandler($c),
144 // User/Customer
145 Commands\User\Customer\AddCustomerCommand::class => new Commands\User\Customer\AddCustomerCommandHandler($c),
146 Commands\User\Customer\GetCustomerCommand::class => new Commands\User\Customer\GetCustomerCommandHandler($c),
147 Commands\User\Customer\GetCustomersCommand::class => new Commands\User\Customer\GetCustomersCommandHandler($c),
148 Commands\User\Customer\UpdateCustomerCommand::class => new Commands\User\Customer\UpdateCustomerCommandHandler($c),
149 Commands\User\Customer\UpdateCustomerNoteCommand::class => new Commands\User\Customer\UpdateCustomerNoteCommandHandler($c),
150 // User
151 Commands\User\DeleteUserCommand::class => new Commands\User\DeleteUserCommandHandler($c),
152 Commands\User\GetCurrentUserCommand::class => new Commands\User\GetCurrentUserCommandHandler($c),
153 Commands\User\GetUserDeleteEffectCommand::class => new Commands\User\GetUserDeleteEffectCommandHandler($c),
154 Commands\User\GetWPUsersCommand::class => new Commands\User\GetWPUsersCommandHandler($c),
155 // User/Provider
156 Commands\User\Provider\AddProviderCommand::class => new Commands\User\Provider\AddProviderCommandHandler($c),
157 Commands\User\Provider\UpdateProviderCommand::class => new Commands\User\Provider\UpdateProviderCommandHandler($c),
158 Commands\User\Provider\GetProviderCommand::class => new Commands\User\Provider\GetProviderCommandHandler($c),
159 Commands\User\Provider\GetProvidersCommand::class => new Commands\User\Provider\GetProvidersCommandHandler($c),
160 Commands\User\Provider\UpdateProviderStatusCommand::class => new Commands\User\Provider\UpdateProviderStatusCommandHandler($c),
161 // What's new
162 Commands\WhatsNew\GetWhatsNewCommand::class => new Commands\WhatsNew\GetWhatsNewCommandHandler($c),
163 // Calendar
164 Commands\Calendar\GetCalendarSlotsCommand::class => new Commands\Calendar\GetCalendarSlotsCommandHandler($c),
165 Commands\Calendar\GetCalendarEventsCommand::class => new Commands\Calendar\GetCalendarEventsCommandHandler($c),
166 Commands\Calendar\GetCalendarSlotAvailabilityCommand::class => new Commands\Calendar\GetCalendarSlotAvailabilityHandler($c),
167 Commands\Calendar\GetCalendarSlotEntitiesCommand::class => new Commands\Calendar\GetCalendarSlotEntitiesCommandHandler($c),
168 Commands\Calendar\ManageCalendarBlockTimeCommand::class => new Commands\Calendar\ManageCalendarBlockTimeCommandHandler($c),
169 Commands\Calendar\GetBlockTimeCommand::class => new Commands\Calendar\GetBlockTimeCommandHandler($c),
170 Commands\Calendar\DeleteBlockTimeCommand::class => new Commands\Calendar\DeleteBlockTimeCommandHandler($c),
171 // Import customers
172 Commands\Import\ImportCustomersCommand::class => new Commands\Import\ImportCustomersCommandHandler($c),
173 ];
174 }
175
176 /**
177 * @param App $app
178 * @param Container $container
179 */
180 public static function setRoutes(App $app, Container $container)
181 {
182 Routes\Booking\Booking::routes($app);
183
184 Routes\Booking\Appointment\Appointment::routes($app);
185
186 Routes\Booking\Event\Event::routes($app);
187
188 Routes\Bookable\Category::routes($app);
189
190 Routes\Entities\Entities::routes($app);
191
192 Routes\Stash\Stash::routes($app);
193
194 Routes\Notification\Notification::routes($app);
195
196 Routes\Payment\Payment::routes($app);
197
198 Routes\Square\Square::routes($app);
199
200 Routes\Import\Import::routes($app);
201
202 Routes\Bookable\Service::routes($app);
203
204 Routes\Settings\Settings::routes($app);
205
206 Routes\Stats\Stats::routes($app);
207
208 Routes\TimeSlots\TimeSlots::routes($app);
209
210 Routes\User\User::routes($app);
211
212 Routes\WhatsNew\WhatsNew::routes($app);
213
214 Routes\Test\Test::routes($app);
215
216 Routes\Calendar\Calendar::routes($app);
217
218 Routes\Settings\FeaturesIntegrations\FeaturesIntegrations::routes($app);
219 }
220
221 /**
222 * @return string
223 */
224 public static function getPaddleUrl()
225 {
226 return AMELIA_URL . 'public/js/paddle/paddle.js';
227 }
228 }
229