]> BookStack Code Mirror - bookstack/commitdiff
Played around with a new app structure
authorDan Brown <redacted>
Wed, 17 May 2023 16:56:55 +0000 (17:56 +0100)
committerDan Brown <redacted>
Wed, 17 May 2023 16:56:55 +0000 (17:56 +0100)
280 files changed:
app/Access/Controllers/ConfirmEmailController.php [moved from app/Http/Controllers/Auth/ConfirmEmailController.php with 95% similarity]
app/Access/Controllers/ForgotPasswordController.php [moved from app/Http/Controllers/Auth/ForgotPasswordController.php with 96% similarity]
app/Access/Controllers/HandlesPartialLogins.php [moved from app/Http/Controllers/Auth/HandlesPartialLogins.php with 81% similarity]
app/Access/Controllers/LoginController.php [moved from app/Http/Controllers/Auth/LoginController.php with 98% similarity]
app/Access/Controllers/MfaBackupCodesController.php [moved from app/Http/Controllers/Auth/MfaBackupCodesController.php with 92% similarity]
app/Access/Controllers/MfaController.php [moved from app/Http/Controllers/Auth/MfaController.php with 94% similarity]
app/Access/Controllers/MfaTotpController.php [moved from app/Http/Controllers/Auth/MfaTotpController.php with 90% similarity]
app/Access/Controllers/OidcController.php [moved from app/Http/Controllers/Auth/OidcController.php with 92% similarity]
app/Access/Controllers/RegisterController.php [moved from app/Http/Controllers/Auth/RegisterController.php with 93% similarity]
app/Access/Controllers/ResetPasswordController.php [moved from app/Http/Controllers/Auth/ResetPasswordController.php with 95% similarity]
app/Access/Controllers/Saml2Controller.php [moved from app/Http/Controllers/Auth/Saml2Controller.php with 97% similarity]
app/Access/Controllers/SocialController.php [moved from app/Http/Controllers/Auth/SocialController.php with 96% similarity]
app/Access/Controllers/ThrottlesLogins.php [moved from app/Http/Controllers/Auth/ThrottlesLogins.php with 98% similarity]
app/Access/Controllers/UserInviteController.php [moved from app/Http/Controllers/Auth/UserInviteController.php with 95% similarity]
app/Access/EmailConfirmationService.php [moved from app/Auth/Access/EmailConfirmationService.php with 94% similarity]
app/Access/ExternalBaseUserProvider.php [moved from app/Auth/Access/ExternalBaseUserProvider.php with 98% similarity]
app/Access/GroupSyncService.php [moved from app/Auth/Access/GroupSyncService.php with 96% similarity]
app/Access/Guards/AsyncExternalBaseSessionGuard.php [moved from app/Auth/Access/Guards/AsyncExternalBaseSessionGuard.php with 95% similarity]
app/Access/Guards/ExternalBaseSessionGuard.php [moved from app/Auth/Access/Guards/ExternalBaseSessionGuard.php with 98% similarity]
app/Access/Guards/LdapSessionGuard.php [moved from app/Auth/Access/Guards/LdapSessionGuard.php with 96% similarity]
app/Access/Ldap.php [moved from app/Auth/Access/Ldap.php with 99% similarity]
app/Access/LdapService.php [moved from app/Auth/Access/LdapService.php with 99% similarity]
app/Access/LoginService.php [moved from app/Auth/Access/LoginService.php with 97% similarity]
app/Access/Mfa/BackupCodeService.php [moved from app/Auth/Access/Mfa/BackupCodeService.php with 97% similarity]
app/Access/Mfa/MfaSession.php [moved from app/Auth/Access/Mfa/MfaSession.php with 95% similarity]
app/Access/Mfa/MfaValue.php [moved from app/Auth/Access/Mfa/MfaValue.php with 96% similarity]
app/Access/Mfa/TotpService.php [moved from app/Auth/Access/Mfa/TotpService.php with 96% similarity]
app/Access/Mfa/TotpValidationRule.php [moved from app/Auth/Access/Mfa/TotpValidationRule.php with 95% similarity]
app/Access/Oidc/OidcAccessToken.php [moved from app/Auth/Access/Oidc/OidcAccessToken.php with 97% similarity]
app/Access/Oidc/OidcException.php [moved from app/Auth/Access/Oidc/OidcException.php with 63% similarity]
app/Access/Oidc/OidcIdToken.php [moved from app/Auth/Access/Oidc/OidcIdToken.php with 99% similarity]
app/Access/Oidc/OidcInvalidKeyException.php [moved from app/Auth/Access/Oidc/OidcInvalidKeyException.php with 61% similarity]
app/Access/Oidc/OidcInvalidTokenException.php [moved from app/Auth/Access/Oidc/OidcInvalidTokenException.php with 67% similarity]
app/Access/Oidc/OidcIssuerDiscoveryException.php [moved from app/Auth/Access/Oidc/OidcIssuerDiscoveryException.php with 68% similarity]
app/Access/Oidc/OidcJwtSigningKey.php [moved from app/Auth/Access/Oidc/OidcJwtSigningKey.php with 99% similarity]
app/Access/Oidc/OidcOAuthProvider.php [moved from app/Auth/Access/Oidc/OidcOAuthProvider.php with 99% similarity]
app/Access/Oidc/OidcProviderSettings.php [moved from app/Auth/Access/Oidc/OidcProviderSettings.php with 99% similarity]
app/Access/Oidc/OidcService.php [moved from app/Auth/Access/Oidc/OidcService.php with 97% similarity]
app/Access/RegistrationService.php [moved from app/Auth/Access/RegistrationService.php with 96% similarity]
app/Access/Saml2Service.php [moved from app/Auth/Access/Saml2Service.php with 99% similarity]
app/Access/SocialAccount.php [moved from app/Auth/SocialAccount.php with 79% similarity]
app/Access/SocialAuthService.php [moved from app/Auth/Access/SocialAuthService.php with 99% similarity]
app/Access/UserInviteService.php [moved from app/Auth/Access/UserInviteService.php with 89% similarity]
app/Access/UserTokenService.php [moved from app/Auth/Access/UserTokenService.php with 97% similarity]
app/Activity/ActivityQueries.php [moved from app/Actions/ActivityQueries.php with 95% similarity]
app/Activity/ActivityType.php [moved from app/Actions/ActivityType.php with 98% similarity]
app/Activity/CommentRepo.php [moved from app/Actions/CommentRepo.php with 97% similarity]
app/Activity/Controllers/AuditLogController.php [moved from app/Http/Controllers/AuditLogController.php with 92% similarity]
app/Activity/Controllers/CommentController.php [moved from app/Http/Controllers/CommentController.php with 94% similarity]
app/Activity/Controllers/FavouriteController.php [moved from app/Http/Controllers/FavouriteController.php with 94% similarity]
app/Activity/Controllers/TagController.php [moved from app/Http/Controllers/TagController.php with 93% similarity]
app/Activity/Controllers/WebhookController.php [moved from app/Http/Controllers/WebhookController.php with 94% similarity]
app/Activity/DispatchWebhookJob.php [moved from app/Actions/DispatchWebhookJob.php with 92% similarity]
app/Activity/Models/Activity.php [moved from app/Actions/Activity.php with 92% similarity]
app/Activity/Models/Comment.php [moved from app/Actions/Comment.php with 91% similarity]
app/Activity/Models/Favouritable.php [moved from app/Interfaces/Favouritable.php with 84% similarity]
app/Activity/Models/Favourite.php [moved from app/Actions/Favourite.php with 84% similarity]
app/Activity/Models/Loggable.php [moved from app/Interfaces/Loggable.php with 79% similarity]
app/Activity/Models/Tag.php [moved from app/Actions/Tag.php with 92% similarity]
app/Activity/Models/View.php [moved from app/Actions/View.php with 92% similarity]
app/Activity/Models/Viewable.php [moved from app/Interfaces/Viewable.php with 84% similarity]
app/Activity/Models/Webhook.php [moved from app/Actions/Webhook.php with 97% similarity]
app/Activity/Models/WebhookTrackedEvent.php [moved from app/Actions/WebhookTrackedEvent.php with 88% similarity]
app/Activity/Queries/WebhooksAllPaginatedAndSorted.php [moved from app/Actions/Queries/WebhooksAllPaginatedAndSorted.php with 91% similarity]
app/Activity/TagRepo.php [moved from app/Actions/TagRepo.php with 97% similarity]
app/Activity/Tools/ActivityLogger.php [moved from app/Actions/ActivityLogger.php with 95% similarity]
app/Activity/Tools/IpFormatter.php [moved from app/Actions/IpFormatter.php with 98% similarity]
app/Activity/Tools/TagClassGenerator.php [moved from app/Actions/TagClassGenerator.php with 93% similarity]
app/Activity/Tools/WebhookFormatter.php [moved from app/Actions/WebhookFormatter.php with 94% similarity]
app/Api/ApiDocsController.php [moved from app/Http/Controllers/Api/ApiDocsController.php with 88% similarity]
app/Api/ApiDocsGenerator.php
app/Api/ApiToken.php
app/Api/ApiTokenGuard.php
app/Api/UserApiTokenController.php [moved from app/Http/Controllers/UserApiTokenController.php with 97% similarity]
app/App/Application.php [moved from app/Application.php with 95% similarity]
app/App/Model.php [moved from app/Model.php with 94% similarity]
app/App/Providers/AppServiceProvider.php [moved from app/Providers/AppServiceProvider.php with 94% similarity]
app/App/Providers/AuthServiceProvider.php [moved from app/Providers/AuthServiceProvider.php with 84% similarity]
app/App/Providers/EventServiceProvider.php [moved from app/Providers/EventServiceProvider.php with 97% similarity]
app/App/Providers/RouteServiceProvider.php [moved from app/Providers/RouteServiceProvider.php with 98% similarity]
app/App/Providers/ThemeServiceProvider.php [moved from app/Providers/ThemeServiceProvider.php with 95% similarity]
app/App/Providers/TranslationServiceProvider.php [moved from app/Providers/TranslationServiceProvider.php with 97% similarity]
app/App/Providers/ValidationRuleServiceProvider.php [moved from app/Providers/ValidationRuleServiceProvider.php with 96% similarity]
app/App/Providers/ViewTweaksServiceProvider.php [moved from app/Providers/ViewTweaksServiceProvider.php with 95% similarity]
app/App/Sluggable.php [moved from app/Interfaces/Sluggable.php with 89% similarity]
app/App/helpers.php [moved from app/helpers.php with 97% similarity]
app/Config/app.php
app/Config/auth.php
app/Console/Commands/ClearActivity.php
app/Console/Commands/ClearViews.php
app/Console/Commands/CreateAdmin.php
app/Console/Commands/DeleteUsers.php
app/Console/Commands/RegenerateCommentContent.php
app/Console/Commands/RegeneratePermissions.php
app/Console/Commands/ResetMfa.php
app/Entities/Controllers/BookApiController.php [moved from app/Http/Controllers/Api/BookApiController.php with 97% similarity]
app/Entities/Controllers/BookController.php [moved from app/Http/Controllers/BookController.php with 97% similarity]
app/Entities/Controllers/BookExportApiController.php [moved from app/Http/Controllers/Api/BookExportApiController.php with 95% similarity]
app/Entities/Controllers/BookExportController.php [moved from app/Http/Controllers/BookExportController.php with 95% similarity]
app/Entities/Controllers/BookSortController.php [moved from app/Http/Controllers/BookSortController.php with 94% similarity]
app/Entities/Controllers/BookshelfApiController.php [moved from app/Http/Controllers/Api/BookshelfApiController.php with 97% similarity]
app/Entities/Controllers/BookshelfController.php [moved from app/Http/Controllers/BookshelfController.php with 97% similarity]
app/Entities/Controllers/ChapterApiController.php [moved from app/Http/Controllers/Api/ChapterApiController.php with 97% similarity]
app/Entities/Controllers/ChapterController.php [moved from app/Http/Controllers/ChapterController.php with 98% similarity]
app/Entities/Controllers/ChapterExportApiController.php [moved from app/Http/Controllers/Api/ChapterExportApiController.php with 95% similarity]
app/Entities/Controllers/ChapterExportController.php [moved from app/Http/Controllers/ChapterExportController.php with 96% similarity]
app/Entities/Controllers/PageApiController.php [moved from app/Http/Controllers/Api/PageApiController.php with 98% similarity]
app/Entities/Controllers/PageController.php [moved from app/Http/Controllers/PageController.php with 99% similarity]
app/Entities/Controllers/PageExportApiController.php [moved from app/Http/Controllers/Api/PageExportApiController.php with 95% similarity]
app/Entities/Controllers/PageExportController.php [moved from app/Http/Controllers/PageExportController.php with 96% similarity]
app/Entities/Controllers/PageRevisionController.php [moved from app/Http/Controllers/PageRevisionController.php with 97% similarity]
app/Entities/Controllers/PageTemplateController.php [moved from app/Http/Controllers/PageTemplateController.php with 93% similarity]
app/Entities/Controllers/RecycleBinApiController.php [moved from app/Http/Controllers/Api/RecycleBinApiController.php with 97% similarity]
app/Entities/Controllers/RecycleBinController.php [moved from app/Http/Controllers/RecycleBinController.php with 96% similarity]
app/Entities/Models/Deletable.php [moved from app/Interfaces/Deletable.php with 87% similarity]
app/Entities/Models/Deletion.php
app/Entities/Models/Entity.php
app/Entities/Models/Page.php
app/Entities/Models/PageRevision.php
app/Entities/Queries/EntityQuery.php
app/Entities/Queries/Popular.php
app/Entities/Queries/RecentlyViewed.php
app/Entities/Queries/TopFavourites.php
app/Entities/Repos/BaseRepo.php
app/Entities/Repos/BookRepo.php
app/Entities/Repos/BookshelfRepo.php
app/Entities/Repos/ChapterRepo.php
app/Entities/Repos/DeletionRepo.php
app/Entities/Repos/PageRepo.php
app/Entities/Tools/Cloner.php
app/Entities/Tools/HierarchyTransformer.php
app/Entities/Tools/PermissionsUpdater.php
app/Entities/Tools/SlugGenerator.php
app/Exceptions/StoppedAuthenticationException.php
app/Facades/Activity.php
app/Http/Controllers/ApiController.php [moved from app/Http/Controllers/Api/ApiController.php with 93% similarity]
app/Http/Controllers/Controller.php
app/Http/Controllers/HomeController.php
app/Http/Middleware/AuthenticatedOrPendingMfa.php
app/Http/Middleware/CheckEmailConfirmed.php
app/Http/Middleware/Localization.php
app/Http/Middleware/RedirectIfAuthenticated.php
app/Http/Requests/Request.php [deleted file]
app/Notifications/UserInvite.php
app/Permissions/ContentPermissionApiController.php [moved from app/Http/Controllers/Api/ContentPermissionApiController.php with 98% similarity]
app/Permissions/EntityPermissionEvaluator.php [moved from app/Auth/Permissions/EntityPermissionEvaluator.php with 97% similarity]
app/Permissions/JointPermissionBuilder.php [moved from app/Auth/Permissions/JointPermissionBuilder.php with 98% similarity]
app/Permissions/MassEntityPermissionEvaluator.php [moved from app/Auth/Permissions/MassEntityPermissionEvaluator.php with 96% similarity]
app/Permissions/Models/EntityPermission.php [moved from app/Auth/Permissions/EntityPermission.php with 90% similarity]
app/Permissions/Models/JointPermission.php [moved from app/Auth/Permissions/JointPermission.php with 85% similarity]
app/Permissions/Models/RolePermission.php [moved from app/Auth/Permissions/RolePermission.php with 86% similarity]
app/Permissions/PermissionApplicator.php [moved from app/Auth/Permissions/PermissionApplicator.php with 96% similarity]
app/Permissions/PermissionFormData.php [moved from app/Auth/Permissions/PermissionFormData.php with 93% similarity]
app/Permissions/PermissionStatus.php [moved from app/Auth/Permissions/PermissionStatus.php with 80% similarity]
app/Permissions/PermissionsController.php [moved from app/Http/Controllers/PermissionsController.php with 97% similarity]
app/Permissions/PermissionsRepo.php [moved from app/Auth/Permissions/PermissionsRepo.php with 96% similarity]
app/Permissions/SimpleEntityData.php [moved from app/Auth/Permissions/SimpleEntityData.php with 94% similarity]
app/References/CrossLinkParser.php
app/References/ModelResolvers/BookLinkModelResolver.php
app/References/ModelResolvers/BookshelfLinkModelResolver.php
app/References/ModelResolvers/ChapterLinkModelResolver.php
app/References/ModelResolvers/CrossLinkModelResolver.php
app/References/ModelResolvers/PageLinkModelResolver.php
app/References/ModelResolvers/PagePermalinkModelResolver.php
app/References/Reference.php
app/References/ReferenceController.php [moved from app/Http/Controllers/ReferenceController.php with 96% similarity]
app/References/ReferenceFetcher.php
app/Search/SearchApiController.php [moved from app/Http/Controllers/Api/SearchApiController.php with 93% similarity]
app/Search/SearchController.php [moved from app/Http/Controllers/SearchController.php with 96% similarity]
app/Search/SearchIndex.php
app/Search/SearchResultsFormatter.php
app/Search/SearchRunner.php
app/Search/SearchTerm.php
app/Settings/MaintenanceController.php [moved from app/Http/Controllers/MaintenanceController.php with 96% similarity]
app/Settings/Setting.php
app/Settings/SettingController.php [moved from app/Http/Controllers/SettingController.php with 91% similarity]
app/Settings/SettingService.php
app/Settings/StatusController.php [moved from app/Http/Controllers/StatusController.php with 94% similarity]
app/Theming/ThemeEvents.php
app/Theming/ThemeService.php
app/Translation/LanguageManager.php [moved from app/Util/LanguageManager.php with 99% similarity]
app/Uploads/Attachment.php
app/Uploads/Controllers/AttachmentApiController.php [moved from app/Http/Controllers/Api/AttachmentApiController.php with 98% similarity]
app/Uploads/Controllers/AttachmentController.php [moved from app/Http/Controllers/AttachmentController.php with 99% similarity]
app/Uploads/Controllers/DrawioImageController.php [moved from app/Http/Controllers/Images/DrawioImageController.php with 98% similarity]
app/Uploads/Controllers/GalleryImageController.php [moved from app/Http/Controllers/Images/GalleryImageController.php with 97% similarity]
app/Uploads/Controllers/ImageController.php [moved from app/Http/Controllers/Images/ImageController.php with 98% similarity]
app/Uploads/Controllers/ImageGalleryApiController.php [moved from app/Http/Controllers/Api/ImageGalleryApiController.php with 98% similarity]
app/Uploads/Image.php
app/Uploads/ImageRepo.php
app/Uploads/UserAvatars.php
app/Users/Controllers/RoleApiController.php [moved from app/Http/Controllers/Api/RoleApiController.php with 96% similarity]
app/Users/Controllers/RoleController.php [moved from app/Http/Controllers/RoleController.php with 95% similarity]
app/Users/Controllers/UserApiController.php [moved from app/Http/Controllers/Api/UserApiController.php with 97% similarity]
app/Users/Controllers/UserController.php [moved from app/Http/Controllers/UserController.php with 96% similarity]
app/Users/Controllers/UserPreferencesController.php [moved from app/Http/Controllers/UserPreferencesController.php with 97% similarity]
app/Users/Controllers/UserProfileController.php [moved from app/Http/Controllers/UserProfileController.php with 74% similarity]
app/Users/Controllers/UserSearchController.php [moved from app/Http/Controllers/UserSearchController.php with 88% similarity]
app/Users/Models/HasCreatorAndUpdater.php [moved from app/Traits/HasCreatorAndUpdater.php with 90% similarity]
app/Users/Models/HasOwner.php [moved from app/Traits/HasOwner.php with 84% similarity]
app/Users/Models/Role.php [moved from app/Auth/Role.php with 92% similarity]
app/Users/Models/User.php [moved from app/Auth/User.php with 97% similarity]
app/Users/Queries/RolesAllPaginatedAndSorted.php [moved from app/Auth/Queries/RolesAllPaginatedAndSorted.php with 93% similarity]
app/Users/Queries/UserContentCounts.php [moved from app/Auth/Queries/UserContentCounts.php with 91% similarity]
app/Users/Queries/UserRecentlyCreatedContent.php [moved from app/Auth/Queries/UserRecentlyCreatedContent.php with 93% similarity]
app/Users/Queries/UsersAllPaginatedAndSorted.php [moved from app/Auth/Queries/UsersAllPaginatedAndSorted.php with 94% similarity]
app/Users/UserRepo.php [moved from app/Auth/UserRepo.php with 97% similarity]
bootstrap/app.php
composer.json
database/factories/Actions/CommentFactory.php
database/factories/Actions/TagFactory.php
database/factories/Actions/WebhookFactory.php
database/factories/Actions/WebhookTrackedEventFactory.php
database/factories/Auth/RoleFactory.php
database/factories/Auth/UserFactory.php
database/factories/Uploads/AttachmentFactory.php
database/migrations/2023_01_24_104625_refactor_joint_permissions_storage.php
database/seeders/DummyContentSeeder.php
database/seeders/LargeContentSeeder.php
resources/views/entities/body-tag-classes.blade.php
resources/views/form/entity-permissions.blade.php
resources/views/settings/audit.blade.php
resources/views/settings/registration.blade.php
resources/views/settings/webhooks/parts/form.blade.php
resources/views/tags/index.blade.php
routes/api.php
routes/web.php
tests/Actions/AuditLogTest.php
tests/Actions/WebhookCallTest.php
tests/Actions/WebhookFormatTesting.php
tests/Actions/WebhookManagementTest.php
tests/Api/ApiAuthTest.php
tests/Api/RolesApiTest.php
tests/Api/TestsApi.php
tests/Api/UsersApiTest.php
tests/Auth/AuthTest.php
tests/Auth/GroupSyncServiceTest.php
tests/Auth/LdapTest.php
tests/Auth/MfaConfigurationTest.php
tests/Auth/MfaVerificationTest.php
tests/Auth/OidcTest.php
tests/Auth/RegistrationTest.php
tests/Auth/ResetPasswordTest.php
tests/Auth/Saml2Test.php
tests/Auth/SocialAuthTest.php
tests/Auth/UserInviteTest.php
tests/Commands/ClearActivityCommandTest.php
tests/Commands/CreateAdminCommandTest.php
tests/Commands/RegenerateCommentContentCommandTest.php
tests/Commands/RegeneratePermissionsCommandTest.php
tests/Commands/ResetMfaCommandTest.php
tests/DebugViewTest.php
tests/Entity/BookShelfTest.php
tests/Entity/CommentTest.php
tests/Entity/ConvertTest.php
tests/Entity/EntityAccessTest.php
tests/Entity/EntitySearchTest.php
tests/Entity/ExportTest.php
tests/Entity/PageRevisionTest.php
tests/Entity/TagTest.php
tests/FavouriteTest.php
tests/Helpers/EntityProvider.php
tests/Helpers/PermissionsProvider.php
tests/Helpers/UserRoleProvider.php
tests/HomepageTest.php
tests/Permissions/EntityOwnerChangeTest.php
tests/Permissions/EntityPermissionsTest.php
tests/Permissions/RolesTest.php
tests/Permissions/Scenarios/PermissionScenarioTestCase.php
tests/PublicActionTest.php
tests/References/ReferencesTest.php
tests/Settings/RegenerateReferencesTest.php
tests/ThemeTest.php
tests/Unit/IpFormatterTest.php
tests/Unit/OidcIdTokenTest.php
tests/Uploads/AvatarTest.php
tests/User/UserApiTokenTest.php
tests/User/UserManagementTest.php
tests/User/UserProfileTest.php
tests/User/UserSearchTest.php

similarity index 95%
rename from app/Http/Controllers/Auth/ConfirmEmailController.php
rename to app/Access/Controllers/ConfirmEmailController.php
index fdde8e70c1b9e851cf79fac5261b72b7fa25a723..3fda0586e0cb88540894ee4514e9b82195ba55c4 100644 (file)
@@ -1,14 +1,14 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\EmailConfirmationService;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\UserRepo;
+use BookStack\Access\EmailConfirmationService;
+use BookStack\Access\LoginService;
 use BookStack\Exceptions\ConfirmationEmailException;
 use BookStack\Exceptions\UserTokenExpiredException;
 use BookStack\Exceptions\UserTokenNotFoundException;
 use BookStack\Http\Controllers\Controller;
+use BookStack\Users\UserRepo;
 use Exception;
 use Illuminate\Http\Request;
 
similarity index 96%
rename from app/Http/Controllers/Auth/ForgotPasswordController.php
rename to app/Access/Controllers/ForgotPasswordController.php
index 2bdc31df511435701ab27c21465799de36877702..6edeb6da529f35e8c9acb814e5663f850e1bccc3 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\Password;
similarity index 81%
rename from app/Http/Controllers/Auth/HandlesPartialLogins.php
rename to app/Access/Controllers/HandlesPartialLogins.php
index c7f3621517f58881febe1dc94e425de9d8290082..c5554e47300131855e14ec2894b6943551fb0680 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\User;
+use BookStack\Access\LoginService;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Users\Models\User;
 
 trait HandlesPartialLogins
 {
similarity index 98%
rename from app/Http/Controllers/Auth/LoginController.php
rename to app/Access/Controllers/LoginController.php
index e16feb0790303efb25a044108c2c5203a3c65683..159561a27805ac5c280a2b3db8da5ecc16f49d41 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\LoginService;
+use BookStack\Access\SocialAuthService;
 use BookStack\Exceptions\LoginAttemptEmailNeededException;
 use BookStack\Exceptions\LoginAttemptException;
 use BookStack\Facades\Activity;
similarity index 92%
rename from app/Http/Controllers/Auth/MfaBackupCodesController.php
rename to app/Access/Controllers/MfaBackupCodesController.php
index 4ceb394b0b864297c4aadcf763046f9376d89f3f..0553fef209de164bfc04aa1c7975d2cb3bfa16b7 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\Mfa\BackupCodeService;
-use BookStack\Auth\Access\Mfa\MfaSession;
-use BookStack\Auth\Access\Mfa\MfaValue;
+use BookStack\Access\LoginService;
+use BookStack\Access\Mfa\BackupCodeService;
+use BookStack\Access\Mfa\MfaSession;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Activity\ActivityType;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Http\Controllers\Controller;
 use Exception;
similarity index 94%
rename from app/Http/Controllers/Auth/MfaController.php
rename to app/Access/Controllers/MfaController.php
index 6f6beb873e4911c6a509450694550edbe98cc953..2c6e95f0bc5cd2d2017bcadc049f5493bcc41eb1 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\Mfa\MfaValue;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Activity\ActivityType;
 use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
similarity index 90%
rename from app/Http/Controllers/Auth/MfaTotpController.php
rename to app/Access/Controllers/MfaTotpController.php
index a4cb63155a138f9b172bca736caeaace79ddb030..47be548f977dcfcce8d92fde58392e2b2a25dec9 100644 (file)
@@ -1,13 +1,13 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
-
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\Mfa\MfaSession;
-use BookStack\Auth\Access\Mfa\MfaValue;
-use BookStack\Auth\Access\Mfa\TotpService;
-use BookStack\Auth\Access\Mfa\TotpValidationRule;
+namespace BookStack\Access\Controllers;
+
+use BookStack\Access\LoginService;
+use BookStack\Access\Mfa\MfaSession;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Access\Mfa\TotpService;
+use BookStack\Access\Mfa\TotpValidationRule;
+use BookStack\Activity\ActivityType;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
similarity index 92%
rename from app/Http/Controllers/Auth/OidcController.php
rename to app/Access/Controllers/OidcController.php
index 78a47e4888f55a3eb25232ae13acc7a88dce981c..969f287d643cb21c1c9dab48d108b39cd6e3b7cd 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\Oidc\OidcException;
-use BookStack\Auth\Access\Oidc\OidcService;
+use BookStack\Access\Oidc\OidcException;
+use BookStack\Access\Oidc\OidcService;
 use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
similarity index 93%
rename from app/Http/Controllers/Auth/RegisterController.php
rename to app/Access/Controllers/RegisterController.php
index 262ca540e0b4841c770576f3214c7a85b5c57cec..e54c3e19c0ac12660f0c34b6dbce946da1ef96ac 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\RegistrationService;
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\LoginService;
+use BookStack\Access\RegistrationService;
+use BookStack\Access\SocialAuthService;
 use BookStack\Exceptions\StoppedAuthenticationException;
 use BookStack\Exceptions\UserRegistrationException;
 use BookStack\Http\Controllers\Controller;
similarity index 95%
rename from app/Http/Controllers/Auth/ResetPasswordController.php
rename to app/Access/Controllers/ResetPasswordController.php
index a9914928ee5dfbae7e4d684265ad292b40fa4034..f8a63a8b6afa36dbe364d92b69de4eac55a86bc9 100644 (file)
@@ -1,11 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\User;
+use BookStack\Access\LoginService;
+use BookStack\Activity\ActivityType;
 use BookStack\Http\Controllers\Controller;
+use BookStack\Users\Models\User;
 use Illuminate\Http\RedirectResponse;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\Hash;
similarity index 97%
rename from app/Http/Controllers/Auth/Saml2Controller.php
rename to app/Access/Controllers/Saml2Controller.php
index b3f8e76015bd1b990f79efedeef99c244277d0b0..192ca4fad7ae58b94175bec8aade49f3916ef1cf 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\Saml2Service;
+use BookStack\Access\Saml2Service;
 use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 use Illuminate\Support\Str;
similarity index 96%
rename from app/Http/Controllers/Auth/SocialController.php
rename to app/Access/Controllers/SocialController.php
index 9ba4028ec4e8fef924060a6d4c8b74bef59eee6b..ad8537ce268fb906a94edade7ea5c818b246e4b9 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\RegistrationService;
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\LoginService;
+use BookStack\Access\RegistrationService;
+use BookStack\Access\SocialAuthService;
 use BookStack\Exceptions\SocialDriverNotConfigured;
 use BookStack\Exceptions\SocialSignInAccountNotUsed;
 use BookStack\Exceptions\SocialSignInException;
similarity index 98%
rename from app/Http/Controllers/Auth/ThrottlesLogins.php
rename to app/Access/Controllers/ThrottlesLogins.php
index 7578ba898344225380b1486117ac4a0108d56359..2a066dab502a04a44227d47fdaa4106e77f33a85 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
 use Illuminate\Cache\RateLimiter;
 use Illuminate\Http\Request;
similarity index 95%
rename from app/Http/Controllers/Auth/UserInviteController.php
rename to app/Access/Controllers/UserInviteController.php
index 5b3bba6ff7777fb12080221d565bb613b8fce709..03e045ce147a728d390aea37a4c33aae3c826765 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers\Auth;
+namespace BookStack\Access\Controllers;
 
-use BookStack\Auth\Access\UserInviteService;
-use BookStack\Auth\UserRepo;
+use BookStack\Access\UserInviteService;
 use BookStack\Exceptions\UserTokenExpiredException;
 use BookStack\Exceptions\UserTokenNotFoundException;
 use BookStack\Http\Controllers\Controller;
+use BookStack\Users\UserRepo;
 use Exception;
 use Illuminate\Http\RedirectResponse;
 use Illuminate\Http\Request;
similarity index 94%
rename from app/Auth/Access/EmailConfirmationService.php
rename to app/Access/EmailConfirmationService.php
index 1873cad086ca7fa7f762425f18d9b4a0967a8dfe..79220f996669d67a10d8979f0f50b8387d1125b9 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\ConfirmationEmailException;
 use BookStack\Notifications\ConfirmEmail;
+use BookStack\Users\Models\User;
 
 class EmailConfirmationService extends UserTokenService
 {
similarity index 98%
rename from app/Auth/Access/ExternalBaseUserProvider.php
rename to app/Access/ExternalBaseUserProvider.php
index 122425c1157f33618049b550ca51169a9c9eef98..d3ece983fb80e3dfbe87a3c9292b822b515cf3cd 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
 use Illuminate\Contracts\Auth\Authenticatable;
 use Illuminate\Contracts\Auth\UserProvider;
similarity index 96%
rename from app/Auth/Access/GroupSyncService.php
rename to app/Access/GroupSyncService.php
index 37d4e02d0b12fb980b3376ce2b958c903027cc5b..65e3e8fcd2c46ae479d88dd6329725fe1a5994f0 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Collection;
 
 class GroupSyncService
similarity index 95%
rename from app/Auth/Access/Guards/AsyncExternalBaseSessionGuard.php
rename to app/Access/Guards/AsyncExternalBaseSessionGuard.php
index 6677f5b108393a1b7d1bc68fc6b1605a826cacf1..ab982a6b0886487773e56b232c4aef8e4a8ccf19 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Guards;
+namespace BookStack\Access\Guards;
 
 /**
  * Saml2 Session Guard.
similarity index 98%
rename from app/Auth/Access/Guards/ExternalBaseSessionGuard.php
rename to app/Access/Guards/ExternalBaseSessionGuard.php
index 99bfd2e795ecd4f12198d21ea2ae97d39062af87..2d15422a5ae3e9c8c92f36fa77b34c13340127dd 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Access\Guards;
+namespace BookStack\Access\Guards;
 
-use BookStack\Auth\Access\RegistrationService;
+use BookStack\Access\RegistrationService;
 use Illuminate\Auth\GuardHelpers;
 use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract;
 use Illuminate\Contracts\Auth\StatefulGuard;
similarity index 96%
rename from app/Auth/Access/Guards/LdapSessionGuard.php
rename to app/Access/Guards/LdapSessionGuard.php
index e7ed22704cbd32b2c889b87cf8e6556f7c3eeec1..a417d3e61cb0aeb5e8be23172967c2f76898f633 100644 (file)
@@ -1,15 +1,15 @@
 <?php
 
-namespace BookStack\Auth\Access\Guards;
+namespace BookStack\Access\Guards;
 
-use BookStack\Auth\Access\LdapService;
-use BookStack\Auth\Access\RegistrationService;
-use BookStack\Auth\User;
+use BookStack\Access\LdapService;
+use BookStack\Access\RegistrationService;
 use BookStack\Exceptions\JsonDebugException;
 use BookStack\Exceptions\LdapException;
 use BookStack\Exceptions\LoginAttemptEmailNeededException;
 use BookStack\Exceptions\LoginAttemptException;
 use BookStack\Exceptions\UserRegistrationException;
+use BookStack\Users\Models\User;
 use Illuminate\Contracts\Auth\UserProvider;
 use Illuminate\Contracts\Session\Session;
 use Illuminate\Support\Str;
similarity index 99%
rename from app/Auth/Access/Ldap.php
rename to app/Access/Ldap.php
index 4bf6db474d527d92de5135b7b924aeee969fd73e..d245b3444e392977ff1c660e78496f4ab2af585f 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
 /**
  * Class Ldap
similarity index 99%
rename from app/Auth/Access/LdapService.php
rename to app/Access/LdapService.php
index 359eeca2f5e863ab229c102a15880cce00580823..b127b931a20e51e7065a3048f40bc3034a8721e6 100644 (file)
@@ -1,11 +1,11 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\JsonDebugException;
 use BookStack\Exceptions\LdapException;
 use BookStack\Uploads\UserAvatars;
+use BookStack\Users\Models\User;
 use ErrorException;
 use Illuminate\Support\Facades\Log;
 
similarity index 97%
rename from app/Auth/Access/LoginService.php
rename to app/Access/LoginService.php
index c80943166983f950f372712a597cae7cb7031741..27480ba214ce6d9846f9d32434109c76f2de9c95 100644 (file)
@@ -1,15 +1,15 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\Mfa\MfaSession;
-use BookStack\Auth\User;
+use BookStack\Access\Mfa\MfaSession;
+use BookStack\Activity\ActivityType;
 use BookStack\Exceptions\LoginAttemptException;
 use BookStack\Exceptions\StoppedAuthenticationException;
 use BookStack\Facades\Activity;
 use BookStack\Facades\Theme;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\User;
 use Exception;
 
 class LoginService
similarity index 97%
rename from app/Auth/Access/Mfa/BackupCodeService.php
rename to app/Access/Mfa/BackupCodeService.php
index d58d28ae12f4a115c7cf9d6a5bd92e50dcce66af..7d68d4f92d744296da44db0e7ceb2fa3c5a83036 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Mfa;
+namespace BookStack\Access\Mfa;
 
 use Illuminate\Support\Str;
 
similarity index 95%
rename from app/Auth/Access/Mfa/MfaSession.php
rename to app/Access/Mfa/MfaSession.php
index 72163b58ec4c2f63abce1fe3686f6ad245c41bed..09b9e53b8aeb647d8a70471959e92e37a371336c 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Access\Mfa;
+namespace BookStack\Access\Mfa;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 
 class MfaSession
 {
similarity index 96%
rename from app/Auth/Access/Mfa/MfaValue.php
rename to app/Access/Mfa/MfaValue.php
index 8f07c6657433d9543ea83e42e4228b759bcead2d..64d20eb18f6a3343196174608426e41dfef7066d 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Access\Mfa;
+namespace BookStack\Access\Mfa;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Carbon\Carbon;
 use Illuminate\Database\Eloquent\Model;
 
similarity index 96%
rename from app/Auth/Access/Mfa/TotpService.php
rename to app/Access/Mfa/TotpService.php
index e73c549fe0790230f89cb97334afcdc1ca9079a0..1d1af451ac5d0bb81822ada0ed5f52b0c2297434 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Mfa;
+namespace BookStack\Access\Mfa;
 
 use BaconQrCode\Renderer\Color\Rgb;
 use BaconQrCode\Renderer\Image\SvgImageBackEnd;
@@ -8,7 +8,7 @@ use BaconQrCode\Renderer\ImageRenderer;
 use BaconQrCode\Renderer\RendererStyle\Fill;
 use BaconQrCode\Renderer\RendererStyle\RendererStyle;
 use BaconQrCode\Writer;
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use PragmaRX\Google2FA\Google2FA;
 use PragmaRX\Google2FA\Support\Constants;
 
similarity index 95%
rename from app/Auth/Access/Mfa/TotpValidationRule.php
rename to app/Access/Mfa/TotpValidationRule.php
index 22cb7da9b73a2eda4f0715f94c786f74f50a6bbd..c38bde90b75dc6249d3ec093602d9c721e4377ba 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Mfa;
+namespace BookStack\Access\Mfa;
 
 use Illuminate\Contracts\Validation\Rule;
 
similarity index 97%
rename from app/Auth/Access/Oidc/OidcAccessToken.php
rename to app/Access/Oidc/OidcAccessToken.php
index 520966f6ae420020087bb123b7f488dd69b13486..2ba56de6c0f9a7396eb257c5f03f8b9aab4ff362 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use InvalidArgumentException;
 use League\OAuth2\Client\Token\AccessToken;
similarity index 63%
rename from app/Auth/Access/Oidc/OidcException.php
rename to app/Access/Oidc/OidcException.php
index e39f2c22465cba1b34c8f4c8211496fbde5538f5..095d2f3ffc2e4ea746d2e2797fa64ae1560a92b2 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use Exception;
 
similarity index 99%
rename from app/Auth/Access/Oidc/OidcIdToken.php
rename to app/Access/Oidc/OidcIdToken.php
index ca2c85d098205db5e39ef88fdebda9dcb1748db2..5a395022a4e3049d91fb0759f50a591d9ca5f432 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 class OidcIdToken
 {
similarity index 61%
rename from app/Auth/Access/Oidc/OidcInvalidKeyException.php
rename to app/Access/Oidc/OidcInvalidKeyException.php
index 1b3310e06d915c2672e90a3cd8975954a902f5ff..14c310133ab47f5f45f62ca2b3bcaa6f38743d78 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 class OidcInvalidKeyException extends \Exception
 {
similarity index 67%
rename from app/Auth/Access/Oidc/OidcInvalidTokenException.php
rename to app/Access/Oidc/OidcInvalidTokenException.php
index 4f47eb08fc07d61b7a7d1fd62e0e6da7bac0287e..645f31d7ff8b7814c75b1ad7baf732d0fb25dda9 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use Exception;
 
similarity index 68%
rename from app/Auth/Access/Oidc/OidcIssuerDiscoveryException.php
rename to app/Access/Oidc/OidcIssuerDiscoveryException.php
index 1ca1ed44a62332817f5bf8094c274cf9d9e08cfc..1a453b49dfb479862c89ae58f22e25885ba71cd3 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use Exception;
 
similarity index 99%
rename from app/Auth/Access/Oidc/OidcJwtSigningKey.php
rename to app/Access/Oidc/OidcJwtSigningKey.php
index f003ec93ca1c1df3f2c80ef9a3a940e2d90697fe..3dab3e4427569a54000ad4733fa048a0c4f962c2 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use phpseclib3\Crypt\Common\PublicKey;
 use phpseclib3\Crypt\PublicKeyLoader;
similarity index 99%
rename from app/Auth/Access/Oidc/OidcOAuthProvider.php
rename to app/Access/Oidc/OidcOAuthProvider.php
index d577d8947d68b24a75d39ef26e93756e4bfdef57..2ed8cd5c9726ff40a41f33301b4be508425cfd5b 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use League\OAuth2\Client\Grant\AbstractGrant;
 use League\OAuth2\Client\Provider\AbstractProvider;
similarity index 99%
rename from app/Auth/Access/Oidc/OidcProviderSettings.php
rename to app/Access/Oidc/OidcProviderSettings.php
index 30ec8cac8b8e867438a0630b9097f2ab6eeaf53e..9c8b1b2647241f11830ce46bc8af7a526fd78307 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
 use GuzzleHttp\Psr7\Request;
 use Illuminate\Contracts\Cache\Repository;
similarity index 97%
rename from app/Auth/Access/Oidc/OidcService.php
rename to app/Access/Oidc/OidcService.php
index 3da8b76eb7006f2949b5bf30ee4b6a13e8cd9af5..6d13fe8f1691ac8ef6dddd64e733a5def0e56ffd 100644 (file)
@@ -1,16 +1,16 @@
 <?php
 
-namespace BookStack\Auth\Access\Oidc;
+namespace BookStack\Access\Oidc;
 
-use BookStack\Auth\Access\GroupSyncService;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\RegistrationService;
-use BookStack\Auth\User;
+use BookStack\Access\GroupSyncService;
+use BookStack\Access\LoginService;
+use BookStack\Access\RegistrationService;
 use BookStack\Exceptions\JsonDebugException;
 use BookStack\Exceptions\StoppedAuthenticationException;
 use BookStack\Exceptions\UserRegistrationException;
 use BookStack\Facades\Theme;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Arr;
 use Illuminate\Support\Facades\Cache;
 use League\OAuth2\Client\OptionProvider\HttpBasicAuthOptionProvider;
similarity index 96%
rename from app/Auth/Access/RegistrationService.php
rename to app/Access/RegistrationService.php
index 6fcb404ee83bc5023753c8747b1439a398847b5a..1e40a98445cfe7adbf6db150a2a4580795fb2cd9 100644 (file)
@@ -1,15 +1,14 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\SocialAccount;
-use BookStack\Auth\User;
-use BookStack\Auth\UserRepo;
+use BookStack\Activity\ActivityType;
 use BookStack\Exceptions\UserRegistrationException;
 use BookStack\Facades\Activity;
 use BookStack\Facades\Theme;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\User;
+use BookStack\Users\UserRepo;
 use Exception;
 use Illuminate\Support\Str;
 
similarity index 99%
rename from app/Auth/Access/Saml2Service.php
rename to app/Access/Saml2Service.php
index 24efd7f64aad905c996854c06e153defefa85371..c033bd6a10a3b7d1b41677c01a8bd9bc247b06d4 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\JsonDebugException;
 use BookStack\Exceptions\SamlException;
 use BookStack\Exceptions\StoppedAuthenticationException;
 use BookStack\Exceptions\UserRegistrationException;
+use BookStack\Users\Models\User;
 use Exception;
 use OneLogin\Saml2\Auth;
 use OneLogin\Saml2\Constants;
similarity index 79%
rename from app/Auth/SocialAccount.php
rename to app/Access/SocialAccount.php
index 6cf0224a8d362a2ae6c8bf282f615ad1038e96ad..b76dbb9ec85eb1fd7fa9708647ab925d0c1d047e 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Auth;
+namespace BookStack\Access;
 
-use BookStack\Interfaces\Loggable;
-use BookStack\Model;
+use BookStack\Activity\Models\Loggable;
+use BookStack\App\Model;
+use BookStack\Users\Models\User;
 
 /**
  * Class SocialAccount.
similarity index 99%
rename from app/Auth/Access/SocialAuthService.php
rename to app/Access/SocialAuthService.php
index 0df5ceb5ee679fe655c33a1fafd78f86226ab7af..24a04ef7e0b4147cd0587113f6e6741100d2ea77 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\SocialAccount;
-use BookStack\Auth\User;
+use BookStack\Auth\Access\handler;
 use BookStack\Exceptions\SocialDriverNotConfigured;
 use BookStack\Exceptions\SocialSignInAccountNotUsed;
 use BookStack\Exceptions\UserRegistrationException;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Event;
 use Illuminate\Support\Str;
 use Laravel\Socialite\Contracts\Factory as Socialite;
similarity index 89%
rename from app/Auth/Access/UserInviteService.php
rename to app/Access/UserInviteService.php
index 191a03dd5f1d0502372cfd911a6f25a7f4945f28..00e361e827fe973398c77d99548eb32ad7900663 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\User;
 use BookStack\Notifications\UserInvite;
+use BookStack\Users\Models\User;
 
 class UserInviteService extends UserTokenService
 {
similarity index 97%
rename from app/Auth/Access/UserTokenService.php
rename to app/Access/UserTokenService.php
index 8dfe570f99208d26a05db2942a4b6af1d3edff76..b4fd09c1b64b561b11c1d33f4ca83b2342e3f55b 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Auth\Access;
+namespace BookStack\Access;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\UserTokenExpiredException;
 use BookStack\Exceptions\UserTokenNotFoundException;
+use BookStack\Users\Models\User;
 use Carbon\Carbon;
 use Illuminate\Support\Facades\DB;
 use Illuminate\Support\Str;
similarity index 95%
rename from app/Actions/ActivityQueries.php
rename to app/Activity/ActivityQueries.php
index 0e9cbdebb4b003305bba1045dc59ac4888d764ad..c69cf7a36e70612c226dd6ddf293cf01d6338fd2 100644 (file)
@@ -1,13 +1,14 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
-use BookStack\Auth\User;
+use BookStack\Activity\Models\Activity;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\PermissionApplicator;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Relations\Relation;
 
similarity index 98%
rename from app/Actions/ActivityType.php
rename to app/Activity/ActivityType.php
index 2a9615093e4872a9fb913ae6115f429c3b38b574..3018df1d3d0e1e7c60ee29d52cdbb291f7c84e95 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity;
 
 class ActivityType
 {
similarity index 97%
rename from app/Actions/CommentRepo.php
rename to app/Activity/CommentRepo.php
index 2f2dd658a3c754294e8e45735ba183c5e2cc4d55..f16767fcf1a3922a58c6edbdf04a76e5e22e9cfb 100644 (file)
@@ -1,7 +1,8 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity;
 
+use BookStack\Activity\Models\Comment;
 use BookStack\Entities\Models\Entity;
 use BookStack\Facades\Activity as ActivityService;
 use League\CommonMark\CommonMarkConverter;
similarity index 92%
rename from app/Http/Controllers/AuditLogController.php
rename to app/Activity/Controllers/AuditLogController.php
index da8009d78cb18b9665f84031b69da4e4e5d1fa12..a90f45f3aa8f8615aad156b2b1a7b9dff22f1900 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Activity\Controllers;
 
-use BookStack\Actions\Activity;
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Activity;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Http\Request;
-use Illuminate\Support\Facades\DB;
 
 class AuditLogController extends Controller
 {
similarity index 94%
rename from app/Http/Controllers/CommentController.php
rename to app/Activity/Controllers/CommentController.php
index 9804f6d39a0b077448a84a887b8563c6826a6047..905af9c91341d45a5b4c66e21e1e8f7e4a9438a3 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Activity\Controllers;
 
-use BookStack\Actions\CommentRepo;
+use BookStack\Activity\CommentRepo;
 use BookStack\Entities\Models\Page;
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 use Illuminate\Validation\ValidationException;
 
similarity index 94%
rename from app/Http/Controllers/FavouriteController.php
rename to app/Activity/Controllers/FavouriteController.php
index e46442a643449348ed0f212fee1fb7a00c091b65..0428dced4539b82e3b01f6be27f9c470b3605b69 100644 (file)
@@ -1,11 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Activity\Controllers;
 
+use BookStack\Activity\Models\Favouritable;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Queries\TopFavourites;
-use BookStack\Interfaces\Favouritable;
-use BookStack\Model;
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
 class FavouriteController extends Controller
similarity index 93%
rename from app/Http/Controllers/TagController.php
rename to app/Activity/Controllers/TagController.php
index 00aaf2b7899f775b9db43915b2b50659f7f3ba93..5731dab2a8caeb31845fd8dccac00f5090cf38e2 100644 (file)
@@ -1,8 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Activity\Controllers;
 
-use BookStack\Actions\TagRepo;
+use BookStack\Activity\TagRepo;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Http\Request;
 
similarity index 94%
rename from app/Http/Controllers/WebhookController.php
rename to app/Activity/Controllers/WebhookController.php
index c72dcc51066d4af80bef78c6b2cb9340d1960962..90e70bafc3fd678d4409201d533ea943f92bbeae 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Activity\Controllers;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Queries\WebhooksAllPaginatedAndSorted;
-use BookStack\Actions\Webhook;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Webhook;
+use BookStack\Activity\Queries\WebhooksAllPaginatedAndSorted;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Http\Request;
 
similarity index 92%
rename from app/Actions/DispatchWebhookJob.php
rename to app/Activity/DispatchWebhookJob.php
index 2d805228cd5e54d83526fb7aedda72513c9fdb71..5e6380f439d6f2eb29403e26905b9a4be9e71988 100644 (file)
@@ -1,11 +1,13 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity;
 
-use BookStack\Auth\User;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Activity\Models\Webhook;
+use BookStack\Activity\Tools\WebhookFormatter;
 use BookStack\Facades\Theme;
-use BookStack\Interfaces\Loggable;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\User;
 use Illuminate\Bus\Queueable;
 use Illuminate\Contracts\Queue\ShouldQueue;
 use Illuminate\Foundation\Bus\Dispatchable;
similarity index 92%
rename from app/Actions/Activity.php
rename to app/Activity/Models/Activity.php
index 0789fe123115f0044166fa9ecc7e10b9f0d1d2cd..1fa36e5beaf76e2768b078fe58db64374c4892ea 100644 (file)
@@ -1,11 +1,11 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Auth\User;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
-use BookStack\Model;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
similarity index 91%
rename from app/Actions/Comment.php
rename to app/Activity/Models/Comment.php
index 885ba6ed1ac72d991f7003025ac671ee9d8dd99d..e513bdf3d57cffcb4fd87aa44b1dcfab68a4b32b 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Model;
-use BookStack\Traits\HasCreatorAndUpdater;
+use BookStack\App\Model;
+use BookStack\Users\Models\HasCreatorAndUpdater;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
 
similarity index 84%
rename from app/Interfaces/Favouritable.php
rename to app/Activity/Models/Favouritable.php
index 8a311d1f2d8b54523147bad167a48572deaccb02..7a2b9247a7bcaeda9a4c8c5f182b5a93483d1277 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Interfaces;
+namespace BookStack\Activity\Models;
 
 use Illuminate\Database\Eloquent\Relations\MorphMany;
 
similarity index 84%
rename from app/Actions/Favourite.php
rename to app/Activity/Models/Favourite.php
index c5d12a1514ace68a5b407a9fae2e945f5c228533..6f6079b076663f735ad0bbb01f306fa168238c33 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Permissions\Models\JointPermission;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
 
similarity index 79%
rename from app/Interfaces/Loggable.php
rename to app/Activity/Models/Loggable.php
index 923f64b00359c571134eabeead93f6509a110254..f068b1f2c1c0102a7c6fd60d37339191caca72fb 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Interfaces;
+namespace BookStack\Activity\Models;
 
 interface Loggable
 {
similarity index 92%
rename from app/Actions/Tag.php
rename to app/Activity/Models/Tag.php
index e173faea0c8250db944d0e365d23262667b46be2..0af0a65ac76deda65a1d9d0570304b13333b5d09 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Permissions\Models\JointPermission;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
similarity index 92%
rename from app/Actions/View.php
rename to app/Activity/Models/View.php
index 706467133fa5ecc36ec6aaeaecd9e48f88595f48..a6bc2139ee5685053d66ed14b79abe4dfb7c74a8 100644 (file)
@@ -1,10 +1,9 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Interfaces\Viewable;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Permissions\Models\JointPermission;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
 
similarity index 84%
rename from app/Interfaces/Viewable.php
rename to app/Activity/Models/Viewable.php
index d79ebed997d8a6a91219511c50da4851c61d5e7d..ccb6d52969be1167ecb4f307b3af4f26c65841af 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Interfaces;
+namespace BookStack\Activity\Models;
 
 use Illuminate\Database\Eloquent\Relations\MorphMany;
 
similarity index 97%
rename from app/Actions/Webhook.php
rename to app/Activity/Models/Webhook.php
index 3ed5bb56f54b550650b0abf8e05159be85281419..3b61ae604c9d2dfffe64eb0d504fbfa8a259272d 100644 (file)
@@ -1,8 +1,7 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
-use BookStack\Interfaces\Loggable;
 use Carbon\Carbon;
 use Illuminate\Database\Eloquent\Collection;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
similarity index 88%
rename from app/Actions/WebhookTrackedEvent.php
rename to app/Activity/Models/WebhookTrackedEvent.php
index 28b3a366d69b08e0b4c7ef81c83178d4bb1a881f..ac38849e9e1aebf47ef7a2c62633d80ccfde3a1b 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Models;
 
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Model;
similarity index 91%
rename from app/Actions/Queries/WebhooksAllPaginatedAndSorted.php
rename to app/Activity/Queries/WebhooksAllPaginatedAndSorted.php
index 4958b6070c4cdd221ed02552a29d9b28a3f8e71a..0f23343a48a5f6ee60858e97e624bac85ae227a8 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Actions\Queries;
+namespace BookStack\Activity\Queries;
 
-use BookStack\Actions\Webhook;
+use BookStack\Activity\Models\Webhook;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Pagination\LengthAwarePaginator;
 
similarity index 97%
rename from app/Actions/TagRepo.php
rename to app/Activity/TagRepo.php
index 13d1d957e962f21237e80451fdcffe7cfa448175..4f2dbed5936b5d05214f583f4b7f3d2d26a1ac96 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Entity;
+use BookStack\Permissions\PermissionApplicator;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Support\Collection;
similarity index 95%
rename from app/Actions/ActivityLogger.php
rename to app/Activity/Tools/ActivityLogger.php
index 6ece47fd5ba6058fb24c89d0e891a1d18455c124..1a1dd929b0d4e5dcaaca625f5bd30c82a8d9958b 100644 (file)
@@ -1,10 +1,12 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Tools;
 
+use BookStack\Activity\Models\Activity;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Activity\Models\Webhook;
 use BookStack\Entities\Models\Entity;
 use BookStack\Facades\Theme;
-use BookStack\Interfaces\Loggable;
 use BookStack\Theming\ThemeEvents;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Support\Facades\Log;
similarity index 98%
rename from app/Actions/IpFormatter.php
rename to app/Activity/Tools/IpFormatter.php
index 21616ed29b537d39abccf2170335e8d375bbc3fd..13b56e994851a94fd8250d9a996b0d090ebf70ea 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Tools;
 
 class IpFormatter
 {
similarity index 93%
rename from app/Actions/TagClassGenerator.php
rename to app/Activity/Tools/TagClassGenerator.php
index 7173b30a711f9f255bf29a17c3f71b1b2e05e7ff..1a1bd16c881060d2615ecc99b10c837392dd292f 100644 (file)
@@ -1,6 +1,8 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Tools;
+
+use BookStack\Activity\Models\Tag;
 
 class TagClassGenerator
 {
similarity index 94%
rename from app/Actions/WebhookFormatter.php
rename to app/Activity/Tools/WebhookFormatter.php
index bd0b6853ab62ec6b475b3fca9a40688f7acc3740..4237139780a03f0912b9bb5aae3db56950134bc4 100644 (file)
@@ -1,12 +1,14 @@
 <?php
 
-namespace BookStack\Actions;
+namespace BookStack\Activity\Tools;
 
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Activity\Models\Webhook;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
-use BookStack\Interfaces\Loggable;
-use BookStack\Model;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Carbon;
 
 class WebhookFormatter
similarity index 88%
rename from app/Http/Controllers/Api/ApiDocsController.php
rename to app/Api/ApiDocsController.php
index a1453e7684bb0c4bb7e55534bf1eb2f8e268effe..d6acf05f2b770c6ead22ff0eacaefd02673c6fd6 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Api;
 
-use BookStack\Api\ApiDocsGenerator;
+use BookStack\Http\Controllers\ApiController;
 
 class ApiDocsController extends ApiController
 {
index 671923ab1a21efc678c153f1693fdd8c5ee944ad..473c00ae257eeef805504d5303ab234b43e1a8b3 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Api;
 
-use BookStack\Http\Controllers\Api\ApiController;
+use BookStack\Http\Controllers\ApiController;
 use Exception;
 use Illuminate\Contracts\Container\BindingResolutionException;
 use Illuminate\Support\Collection;
index 70b289ae17e2668159a48b87b792d61a38be4f41..b462eaae956945c703644f7b49e7b30c8bb6e2e5 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Api;
 
-use BookStack\Auth\User;
-use BookStack\Interfaces\Loggable;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Model;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 use Illuminate\Support\Carbon;
index 1bb672556dfa2dec6d008a2078247cd34a7a1d7e..6302884a912a12c913a96925b857a709bc077793 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Api;
 
-use BookStack\Auth\Access\LoginService;
+use BookStack\Access\LoginService;
 use BookStack\Exceptions\ApiAuthException;
 use Illuminate\Auth\GuardHelpers;
 use Illuminate\Contracts\Auth\Authenticatable;
similarity index 97%
rename from app/Http/Controllers/UserApiTokenController.php
rename to app/Api/UserApiTokenController.php
index b1a043cd3c9b27bf26df2655693907fa0e96f046..4a15f89477fff768a491b23cc435b82279ad57e3 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Api;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Api\ApiToken;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Users\Models\User;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\Hash;
 use Illuminate\Support\Str;
similarity index 95%
rename from app/Application.php
rename to app/App/Application.php
index d409d14bc26906dd853d7bcf7f570d2d6b9efd5e..db60d5293749d32050779ade0e97205a49fd360f 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack;
+namespace BookStack\App;
 
 class Application extends \Illuminate\Foundation\Application
 {
similarity index 94%
rename from app/Model.php
rename to app/App/Model.php
index 6fdc250976586386005c37bf3ca333d14373ebb4..8de5a276205ac0aabb75345605cfb80fef78e818 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack;
+namespace BookStack\App;
 
 use Illuminate\Database\Eloquent\Model as EloquentModel;
 
similarity index 94%
rename from app/Providers/AppServiceProvider.php
rename to app/App/Providers/AppServiceProvider.php
index 5d36d2c46a5479ad1df2999cf5de03926b1847e9..0c0895bf45309624c9aedd6d439be1f8eb860aa9 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
-use BookStack\Actions\ActivityLogger;
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\SocialAuthService;
+use BookStack\Activity\Tools\ActivityLogger;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
similarity index 84%
rename from app/Providers/AuthServiceProvider.php
rename to app/App/Providers/AuthServiceProvider.php
index 5e16179ab27c60ff878451f35868a75d9013c662..dc482ce33062725ba05ca2e353273ec5851c9e4f 100644 (file)
@@ -1,14 +1,14 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
+use BookStack\Access\ExternalBaseUserProvider;
+use BookStack\Access\Guards\AsyncExternalBaseSessionGuard;
+use BookStack\Access\Guards\LdapSessionGuard;
+use BookStack\Access\LdapService;
+use BookStack\Access\LoginService;
+use BookStack\Access\RegistrationService;
 use BookStack\Api\ApiTokenGuard;
-use BookStack\Auth\Access\ExternalBaseUserProvider;
-use BookStack\Auth\Access\Guards\AsyncExternalBaseSessionGuard;
-use BookStack\Auth\Access\Guards\LdapSessionGuard;
-use BookStack\Auth\Access\LdapService;
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\RegistrationService;
 use Illuminate\Support\Facades\Auth;
 use Illuminate\Support\ServiceProvider;
 use Illuminate\Validation\Rules\Password;
similarity index 97%
rename from app/Providers/EventServiceProvider.php
rename to app/App/Providers/EventServiceProvider.php
index 97212e1ea5312a500f2886e45e94e64a7e87bfad..bf502d7dab2ea5ace1fff2bbf812ec6755db6430 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
 use SocialiteProviders\Manager\SocialiteWasCalled;
similarity index 98%
rename from app/Providers/RouteServiceProvider.php
rename to app/App/Providers/RouteServiceProvider.php
index 552a41322159e7e7254e21ed0cd7b84e783b4e71..913dfa4353f62739e60691587fb78a557f917051 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use Illuminate\Cache\RateLimiting\Limit;
 use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
similarity index 95%
rename from app/Providers/ThemeServiceProvider.php
rename to app/App/Providers/ThemeServiceProvider.php
index 50c4a5d19659dc8630da2ac995223ca42df2cebc..4c657d9123208dca5f7aaae592e3f1cfc152fb32 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use BookStack\Theming\ThemeEvents;
 use BookStack\Theming\ThemeService;
similarity index 97%
rename from app/Providers/TranslationServiceProvider.php
rename to app/App/Providers/TranslationServiceProvider.php
index 6bf57e02190b766b6f71b52063844b34e12970b4..c1752f38e3efcd2db7b9f256d03f204a9e5b60c7 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use BookStack\Translation\FileLoader;
 use BookStack\Translation\MessageSelector;
similarity index 96%
rename from app/Providers/ValidationRuleServiceProvider.php
rename to app/App/Providers/ValidationRuleServiceProvider.php
index b3c2a4aa796a92a38fba27b2d079d1005936d04b..1adc1ebd85155becaa611ea248761ec544e299d7 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use BookStack\Uploads\ImageService;
 use Illuminate\Support\Facades\Validator;
similarity index 95%
rename from app/Providers/ViewTweaksServiceProvider.php
rename to app/App/Providers/ViewTweaksServiceProvider.php
index f1f1554aebbef6b222a1e25c4927bd9846578568..16b5c1f9751c400d62210d82845f6abcda280365 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Providers;
+namespace BookStack\App\Providers;
 
 use BookStack\Entities\BreadcrumbsViewComposer;
 use Illuminate\Pagination\Paginator;
similarity index 89%
rename from app/Interfaces/Sluggable.php
rename to app/App/Sluggable.php
index 2d56e847e388fcca3993d4ecb35f77f302106d10..f8da2e265173eb90cf7b2a9b6208b1d3409eef00 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Interfaces;
+namespace BookStack\App;
 
 /**
  * Assigned to models that can have slugs.
similarity index 97%
rename from app/helpers.php
rename to app/App/helpers.php
index 837b7fcfdd0bb9c5904726559a68b0d092a99738..00d3e9243d7288096d39f91af5200212bb532316 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-use BookStack\Auth\Permissions\PermissionApplicator;
-use BookStack\Auth\User;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Permissions\PermissionApplicator;
 use BookStack\Settings\SettingService;
+use BookStack\Users\Models\User;
 
 /**
  * Get the path to a versioned file.
index ed73ca6126bcec1ae93a55a6e575f2f69db87c2b..29ab9c6dc9399e46b5337dc678174a921b4806d4 100644 (file)
@@ -139,14 +139,14 @@ return [
         SocialiteProviders\Manager\ServiceProvider::class,
 
         // BookStack custom service providers
-        BookStack\Providers\ThemeServiceProvider::class,
-        BookStack\Providers\AppServiceProvider::class,
-        BookStack\Providers\AuthServiceProvider::class,
-        BookStack\Providers\EventServiceProvider::class,
-        BookStack\Providers\RouteServiceProvider::class,
-        BookStack\Providers\TranslationServiceProvider::class,
-        BookStack\Providers\ValidationRuleServiceProvider::class,
-        BookStack\Providers\ViewTweaksServiceProvider::class,
+        \BookStack\App\Providers\ThemeServiceProvider::class,
+        \BookStack\App\Providers\AppServiceProvider::class,
+        \BookStack\App\Providers\AuthServiceProvider::class,
+        \BookStack\App\Providers\EventServiceProvider::class,
+        \BookStack\App\Providers\RouteServiceProvider::class,
+        \BookStack\App\Providers\TranslationServiceProvider::class,
+        \BookStack\App\Providers\ValidationRuleServiceProvider::class,
+        \BookStack\App\Providers\ViewTweaksServiceProvider::class,
     ],
 
     // Class Aliases
index 37190156a96f13a70e2a3fe2c044797a2ed6f3fd..b1578fdb708f184462a4532eba43e53f276bfd82 100644 (file)
@@ -59,12 +59,12 @@ return [
     'providers' => [
         'users' => [
             'driver' => 'eloquent',
-            'model'  => \BookStack\Auth\User::class,
+            'model'  => \BookStack\Users\Models\User::class,
         ],
 
         'external' => [
             'driver' => 'external-users',
-            'model'  => \BookStack\Auth\User::class,
+            'model'  => \BookStack\Users\Models\User::class,
         ],
 
         // 'users' => [
index 932ba7ddd19538983bab0a142692985e85ce4f56..5ccf6e972b5752b52aa3534c03b797193e89dea1 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Actions\Activity;
+use BookStack\Activity\Models\Activity;
 use Illuminate\Console\Command;
 
 class ClearActivity extends Command
index 0fc6c0195663755e2f1072444ef72452158075c6..c76b78d231d1c2685bbdb0113281955e33b6c133 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Actions\View;
+use BookStack\Activity\Models\View;
 use Illuminate\Console\Command;
 
 class ClearViews extends Command
index e4660314d6e4365676a23049d7b825fa32a95f5b..377207ed7816d53345b1f5e01fa0253ff38aa626 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\UserRepo;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Users\Models\Role;
+use BookStack\Users\UserRepo;
 use Illuminate\Console\Command;
 use Illuminate\Support\Facades\Validator;
 use Illuminate\Support\Str;
index bc7263c774228b13cd7c625c10782baee0ed3df0..c16a5d9a694f30a3f276b871377c87b7de8cc9c4 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Auth\User;
-use BookStack\Auth\UserRepo;
+use BookStack\Users\Models\User;
+use BookStack\Users\UserRepo;
 use Illuminate\Console\Command;
 
 class DeleteUsers extends Command
index 3e25dc8a395566f2291f5f06941e5e5b75b08a3e..3052559e305b1e9a96ae2f453bc0a43e5ac6c33b 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Actions\Comment;
-use BookStack\Actions\CommentRepo;
+use BookStack\Activity\CommentRepo;
+use BookStack\Activity\Models\Comment;
 use Illuminate\Console\Command;
 use Illuminate\Support\Facades\DB;
 
index efb3535d6484ba420fa41e34dc1cf6067f2fc6c5..27dd8ea6530477f7d68ad0688f13413d3af230aa 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Auth\Permissions\JointPermissionBuilder;
+use BookStack\Permissions\JointPermissionBuilder;
 use Illuminate\Console\Command;
 use Illuminate\Support\Facades\DB;
 
index 9074a4a46f2e7bff2ec57dc46869b85c31985d06..4b1813099029485212b2c2f818f5ec476cbc9804 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Console\Commands;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Illuminate\Console\Command;
 
 class ResetMfa extends Command
similarity index 97%
rename from app/Http/Controllers/Api/BookApiController.php
rename to app/Entities/Controllers/BookApiController.php
index d57b48a43fcdbeeccfa7a9b58f5e8bfde9dc9cea..5abac12fbb3a3d2f3c1ff3ecf3c7a2639af1acd1 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Api\ApiEntityListFormatter;
 use BookStack\Entities\Models\Book;
@@ -8,6 +8,7 @@ use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Repos\BookRepo;
 use BookStack\Entities\Tools\BookContents;
+use BookStack\Http\Controllers\ApiController;
 use Illuminate\Http\Request;
 use Illuminate\Validation\ValidationException;
 
similarity index 97%
rename from app/Http/Controllers/BookController.php
rename to app/Entities/Controllers/BookController.php
index 14c3af1cc5cf8f0a8c92d70de7c24d8a1d608c96..45989a80381fbfe0907a9c9328664b173f7288db 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\ActivityQueries;
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\View;
+use BookStack\Activity\ActivityQueries;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\View;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Repos\BookRepo;
 use BookStack\Entities\Tools\BookContents;
@@ -14,6 +14,7 @@ use BookStack\Entities\Tools\ShelfContext;
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Facades\Activity;
+use BookStack\Http\Controllers\Controller;
 use BookStack\References\ReferenceFetcher;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Http\Request;
similarity index 95%
rename from app/Http/Controllers/Api/BookExportApiController.php
rename to app/Entities/Controllers/BookExportApiController.php
index 84090befba53249284e267bf77d767d88888cecb..e3073321fd1758dddf917c463bd501b28ec98442 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Tools\ExportFormatter;
+use BookStack\Http\Controllers\ApiController;
 use Throwable;
 
 class BookExportApiController extends ApiController
similarity index 95%
rename from app/Http/Controllers/BookExportController.php
rename to app/Entities/Controllers/BookExportController.php
index cc8d48a35511e5c6504c69b33512c9164fd22793..97762bd327816486e449c06c61e023244043e8c4 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Repos\BookRepo;
 use BookStack\Entities\Tools\ExportFormatter;
+use BookStack\Http\Controllers\Controller;
 use Throwable;
 
 class BookExportController extends Controller
similarity index 94%
rename from app/Http/Controllers/BookSortController.php
rename to app/Entities/Controllers/BookSortController.php
index 5d0577a74a0a67b04fb641c3002be4ee72932e2a..26ab09f2eba16535eb195aed335a506058ac4c22 100644 (file)
@@ -1,12 +1,13 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Repos\BookRepo;
 use BookStack\Entities\Tools\BookContents;
 use BookStack\Entities\Tools\BookSortMap;
 use BookStack\Facades\Activity;
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
 class BookSortController extends Controller
similarity index 97%
rename from app/Http/Controllers/Api/BookshelfApiController.php
rename to app/Entities/Controllers/BookshelfApiController.php
index b6b78e80ebe762df7719f7f40e93d26713a54ab4..e0c8fa3453a7a831204c4e201054e562bdafb605 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Repos\BookshelfRepo;
+use BookStack\Http\Controllers\ApiController;
 use Exception;
 use Illuminate\Database\Eloquent\Relations\BelongsToMany;
 use Illuminate\Http\Request;
similarity index 97%
rename from app/Http/Controllers/BookshelfController.php
rename to app/Entities/Controllers/BookshelfController.php
index d4642be786d102fb4528131169661450319c2912..271b13a55d15103cc51e09eabe72782b1d8671ce 100644 (file)
@@ -1,14 +1,15 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\ActivityQueries;
-use BookStack\Actions\View;
+use BookStack\Activity\ActivityQueries;
+use BookStack\Activity\Models\View;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Repos\BookshelfRepo;
 use BookStack\Entities\Tools\ShelfContext;
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Http\Controllers\Controller;
 use BookStack\References\ReferenceFetcher;
 use BookStack\Util\SimpleListOptions;
 use Exception;
similarity index 97%
rename from app/Http/Controllers/Api/ChapterApiController.php
rename to app/Entities/Controllers/ChapterApiController.php
index 8459b84499ee362919e87833ad7527b2a7e33928..3f860ba64834556d3f08fe94b2d44083af074d5e 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Repos\ChapterRepo;
+use BookStack\Http\Controllers\ApiController;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Http\Request;
 
similarity index 98%
rename from app/Http/Controllers/ChapterController.php
rename to app/Entities/Controllers/ChapterController.php
index 4d2bcb2f1d444057daf8dff40fd4060bf7cf0fe4..899569a6f7149008ba0a5df904e56fc5efe15e17 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\View;
+use BookStack\Activity\Models\View;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Repos\ChapterRepo;
 use BookStack\Entities\Tools\BookContents;
@@ -12,6 +12,7 @@ use BookStack\Entities\Tools\NextPreviousContentLocator;
 use BookStack\Exceptions\MoveOperationException;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Exceptions\PermissionsException;
+use BookStack\Http\Controllers\Controller;
 use BookStack\References\ReferenceFetcher;
 use Illuminate\Http\Request;
 use Illuminate\Validation\ValidationException;
similarity index 95%
rename from app/Http/Controllers/Api/ChapterExportApiController.php
rename to app/Entities/Controllers/ChapterExportApiController.php
index faf5d812e207c667170fd8c361f4a976ee3d7f11..e334b1350de1475b552eebed8d9c0c872606fcdb 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Tools\ExportFormatter;
+use BookStack\Http\Controllers\ApiController;
 use Throwable;
 
 class ChapterExportApiController extends ApiController
similarity index 96%
rename from app/Http/Controllers/ChapterExportController.php
rename to app/Entities/Controllers/ChapterExportController.php
index fd56d91b3359218b6f1bf0218761132200bb803d..b69a0b10ea412915b7e2f270c57614c9456bc533 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Repos\ChapterRepo;
 use BookStack\Entities\Tools\ExportFormatter;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Http\Controllers\Controller;
 use Throwable;
 
 class ChapterExportController extends Controller
similarity index 98%
rename from app/Http/Controllers/Api/PageApiController.php
rename to app/Entities/Controllers/PageApiController.php
index de729b469b3e7f12f7ee5d7e762d17566366995c..45c858da28cac2843ceb948862e3aa2b1bf0033b 100644 (file)
@@ -1,12 +1,13 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Exceptions\PermissionsException;
+use BookStack\Http\Controllers\ApiController;
 use Exception;
 use Illuminate\Http\Request;
 
similarity index 99%
rename from app/Http/Controllers/PageController.php
rename to app/Entities/Controllers/PageController.php
index 9e09aed16c1a1ee767171cae27fdc29b4c4d6564..0da4bb9006ca4c21b2ef292626896f8f38cfe01d 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\View;
+use BookStack\Activity\Models\View;
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Entities\Tools\BookContents;
@@ -13,6 +13,7 @@ use BookStack\Entities\Tools\PageEditActivity;
 use BookStack\Entities\Tools\PageEditorData;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Exceptions\PermissionsException;
+use BookStack\Http\Controllers\Controller;
 use BookStack\References\ReferenceFetcher;
 use Exception;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
similarity index 95%
rename from app/Http/Controllers/Api/PageExportApiController.php
rename to app/Entities/Controllers/PageExportApiController.php
index f2edffba3d8b8934175705ada9a4327d2d0724b4..dbf6ad4cfc9ffa517dd674a9596d3f47691c66a9 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Tools\ExportFormatter;
+use BookStack\Http\Controllers\ApiController;
 use Throwable;
 
 class PageExportApiController extends ApiController
similarity index 96%
rename from app/Http/Controllers/PageExportController.php
rename to app/Entities/Controllers/PageExportController.php
index 62101d3390fccca880259f76d824cde7deb2396c..b54042667d3ab595711bd3e68be341dda30cbb93 100644 (file)
@@ -1,11 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Entities\Tools\ExportFormatter;
 use BookStack\Entities\Tools\PageContent;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Http\Controllers\Controller;
 use Throwable;
 
 class PageExportController extends Controller
similarity index 97%
rename from app/Http/Controllers/PageRevisionController.php
rename to app/Entities/Controllers/PageRevisionController.php
index 3da5e7c2dd07894c6ed67389d30cc5746b43fe86..fab6ae6653a26caa3980f3b8b1cfde46df2f4d04 100644 (file)
@@ -1,13 +1,14 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\PageRevision;
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Entities\Tools\PageContent;
 use BookStack\Exceptions\NotFoundException;
 use BookStack\Facades\Activity;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Http\Request;
 use Ssddanbrown\HtmlDiff\Diff;
similarity index 93%
rename from app/Http/Controllers/PageTemplateController.php
rename to app/Entities/Controllers/PageTemplateController.php
index 1e24c29eeffd40c27fa63ffbe6168fb27f7ade49..979c9e5abaa762f3daed1937570b38b0a1b13d23 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
 class PageTemplateController extends Controller
similarity index 97%
rename from app/Http/Controllers/Api/RecycleBinApiController.php
rename to app/Entities/Controllers/RecycleBinApiController.php
index f327bae93f4918749a4163132e9320f9e636ad9c..deabf3c4314bbb4f11147820127ae75d9b1a2358 100644 (file)
@@ -1,12 +1,13 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Entities\Controllers;
 
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\BookChild;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Deletion;
 use BookStack\Entities\Repos\DeletionRepo;
+use BookStack\Http\Controllers\ApiController;
 use Closure;
 use Illuminate\Database\Eloquent\Builder;
 
similarity index 96%
rename from app/Http/Controllers/RecycleBinController.php
rename to app/Entities/Controllers/RecycleBinController.php
index 82e3f660bddb92475ee5f79f9cdcbd993b1550f3..334e803dfcf4312f68d9e4027c07136609676752 100644 (file)
@@ -1,12 +1,13 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Entities\Controllers;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Deletion;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Repos\DeletionRepo;
 use BookStack\Entities\Tools\TrashCan;
+use BookStack\Http\Controllers\Controller;
 
 class RecycleBinController extends Controller
 {
similarity index 87%
rename from app/Interfaces/Deletable.php
rename to app/Entities/Models/Deletable.php
index be9b4ac418fc715d2ae57d8e9d913df77900145a..a2c7fad81b5cb95baef5f5a48e8d84a9bb4b2964 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Interfaces;
+namespace BookStack\Entities\Models;
 
 use Illuminate\Database\Eloquent\Relations\MorphMany;
 
index 25f0ea6db7f84478fe2e7d30fe45c1145ab5c55b..a73437c94a4110bee1dd7f0c98501d09e18d4df4 100644 (file)
@@ -2,9 +2,8 @@
 
 namespace BookStack\Entities\Models;
 
-use BookStack\Auth\User;
-use BookStack\Interfaces\Deletable;
-use BookStack\Interfaces\Loggable;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Model;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
index 8bfe69365ef47e529de6178a03f9e3fe72d80781..496ea46b67834ff8cad3d46049b22b6573ef81d9 100644 (file)
@@ -2,27 +2,26 @@
 
 namespace BookStack\Entities\Models;
 
-use BookStack\Actions\Activity;
-use BookStack\Actions\Comment;
-use BookStack\Actions\Favourite;
-use BookStack\Actions\Tag;
-use BookStack\Actions\View;
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Auth\Permissions\JointPermissionBuilder;
-use BookStack\Auth\Permissions\PermissionApplicator;
+use BookStack\Activity\Models\Activity;
+use BookStack\Activity\Models\Comment;
+use BookStack\Activity\Models\Favouritable;
+use BookStack\Activity\Models\Favourite;
+use BookStack\Activity\Models\Loggable;
+use BookStack\Activity\Models\Tag;
+use BookStack\Activity\Models\View;
+use BookStack\Activity\Models\Viewable;
+use BookStack\App\Model;
+use BookStack\App\Sluggable;
 use BookStack\Entities\Tools\SlugGenerator;
-use BookStack\Interfaces\Deletable;
-use BookStack\Interfaces\Favouritable;
-use BookStack\Interfaces\Loggable;
-use BookStack\Interfaces\Sluggable;
-use BookStack\Interfaces\Viewable;
-use BookStack\Model;
+use BookStack\Permissions\JointPermissionBuilder;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Permissions\PermissionApplicator;
 use BookStack\References\Reference;
 use BookStack\Search\SearchIndex;
 use BookStack\Search\SearchTerm;
-use BookStack\Traits\HasCreatorAndUpdater;
-use BookStack\Traits\HasOwner;
+use BookStack\Users\Models\HasCreatorAndUpdater;
+use BookStack\Users\Models\HasOwner;
 use Carbon\Carbon;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Collection;
index a224071ccc144611ceb1befc104d9c421f65210a..40acb9a354b259e648dfb5461fb1fadd06b37528 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Entities\Models;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
 use BookStack\Entities\Tools\PageContent;
+use BookStack\Permissions\PermissionApplicator;
 use BookStack\Uploads\Attachment;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Collection;
index cd22db0c83c19e62441af50bd9488281aac9c503..10ff6d901c438a87d9d3fbb241636d3ec44b1233 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace BookStack\Entities\Models;
 
-use BookStack\Auth\User;
-use BookStack\Interfaces\Loggable;
-use BookStack\Model;
+use BookStack\Activity\Models\Loggable;
+use BookStack\App\Model;
+use BookStack\Users\Models\User;
 use Carbon\Carbon;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 
index 5ab882ca89e957065a6e913ff8037db1139da277..2246e13b179056d8220863f4123e18f3a2eb2fc9 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Entities\Queries;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
 use BookStack\Entities\EntityProvider;
+use BookStack\Permissions\PermissionApplicator;
 
 abstract class EntityQuery
 {
index fafd60c597b404aeb4da40e9c8648cfcdb99c004..9b7049ae3867e278689ac31370c1ee4edc7e8053 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Queries;
 
-use BookStack\Actions\View;
+use BookStack\Activity\Models\View;
 use Illuminate\Support\Facades\DB;
 
 class Popular extends EntityQuery
index 0f5c680414031dba6d4d2f1362bd3acd24c4f9e0..ffa3468882631e10f86ebc90e42ba135cd6d330c 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Queries;
 
-use BookStack\Actions\View;
+use BookStack\Activity\Models\View;
 use Illuminate\Support\Collection;
 
 class RecentlyViewed extends EntityQuery
index 0b9a5ba23c6c1a488b5e0736f5f53bb2ca08ecc3..3f8d2e62e134f2da936c6054cf5f314d79522a3b 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Queries;
 
-use BookStack\Actions\Favourite;
+use BookStack\Activity\Models\Favourite;
 use Illuminate\Database\Query\JoinClause;
 
 class TopFavourites extends EntityQuery
index 815c0bb2ec503522ec9962f959e60e5fad079292..2894a04e36ee6388ea29c41ef133a74466288003 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\TagRepo;
+use BookStack\Activity\TagRepo;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\HasCoverImage;
 use BookStack\Exceptions\ImageUploadException;
index b5944fd460b2f23737e9c3ddcf22be005e72df4e..737caa70bb47c23623fb238c2e70fb9df03280bb 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\TagRepo;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\TagRepo;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Tools\TrashCan;
 use BookStack\Exceptions\ImageUploadException;
index d7759deb43c41a66178e1ffb16e5f16f10422dbf..27333b5b15c131d40b6eb1e6aa354e7a2a7ffaee 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Tools\TrashCan;
index 2b81891af63ce5fd67410bf62517c728e1e1d3bd..588854c7e91c34b05280a3458ed13ff72d5f7fa1 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
index 5d53013dc33deb51fd748fe3f429fb6f0e59bb41..e47192cc2f12266bed38a3f62107ef00a1b7f86a 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Deletion;
 use BookStack\Entities\Tools\TrashCan;
 use BookStack\Facades\Activity;
index c8eddc398ca903a34f40fa2e2e77083cc1d3c3dd..521519dc08d607d8a831015adc55e942f46b47bd 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Repos;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
index 5594c33a605bcfc1069cdd5de60d31010d6d379c..f7ed4b72dcb628263b5ce0395ea29d4bd440ff59 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Tools;
 
-use BookStack\Actions\Tag;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
index 43cf2390e7a5de683399674bc040323866eafa66..cd6c548fe581b1f9179e5332dd3174461ea4dbe1 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Entities\Tools;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
index 36ed7ccde85dd986175bcffa7c8a7fec363e6156..324755e4dbd628138c6c5be3bdb3f9b491d1db44 100644 (file)
@@ -2,14 +2,14 @@
 
 namespace BookStack\Entities\Tools;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Entity;
 use BookStack\Facades\Activity;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Http\Request;
 
 class PermissionsUpdater
index 9fd9036adefdc84661fa28926212edacd8a83021..5df300bb04c8f14c135979f99d0b325272c78806 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace BookStack\Entities\Tools;
 
+use BookStack\App\Model;
+use BookStack\App\Sluggable;
 use BookStack\Entities\Models\BookChild;
-use BookStack\Interfaces\Sluggable;
-use BookStack\Model;
 use Illuminate\Support\Str;
 
 class SlugGenerator
index b9aadb03f33e3aaa4a3a7c03d46916ce511aaade..51e48aa1cf307f7dc211fd2e96f94eadc3dbf583 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Exceptions;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\User;
+use BookStack\Access\LoginService;
+use BookStack\Users\Models\User;
 use Illuminate\Contracts\Support\Responsable;
 use Illuminate\Http\Request;
 
index ec3d28cc0f9e62bbd6b93c4888cce7f8b34caf33..5251d5cbb2160eede9cb14c5556e207b2d9a0221 100644 (file)
@@ -5,7 +5,7 @@ namespace BookStack\Facades;
 use Illuminate\Support\Facades\Facade;
 
 /**
- * @mixin \BookStack\Actions\ActivityLogger
+ * @mixin \BookStack\Activity\Tools\ActivityLogger
  */
 class Activity extends Facade
 {
similarity index 93%
rename from app/Http/Controllers/Api/ApiController.php
rename to app/Http/Controllers/ApiController.php
index 5c448e49f4fbb66594eded24216c4eaa859b12b1..e88f748e4f7f1e19fbb7e4d102ae2f20a87a15ae 100644 (file)
@@ -1,9 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Http\Controllers;
 
 use BookStack\Api\ListingResponseBuilder;
-use BookStack\Http\Controllers\Controller;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Http\JsonResponse;
 
index f6dc1dbca43cb9b46ce60ef9d48105f16a04c575..b3cc81efc9b2b9401142e6a0d86def782e568719 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace BookStack\Http\Controllers;
 
+use BookStack\Activity\Models\Loggable;
+use BookStack\App\Model;
 use BookStack\Exceptions\NotifyException;
 use BookStack\Facades\Activity;
 use BookStack\Http\Responses\DownloadResponseFactory;
-use BookStack\Interfaces\Loggable;
-use BookStack\Model;
 use Illuminate\Foundation\Bus\DispatchesJobs;
 use Illuminate\Foundation\Validation\ValidatesRequests;
 use Illuminate\Http\JsonResponse;
index a82710523846ca252ada0d2cf4db88a4650f6509..efab408184479061505ce748605bf3c602c7cab0 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Http\Controllers;
 
-use BookStack\Actions\ActivityQueries;
+use BookStack\Activity\ActivityQueries;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Queries\RecentlyViewed;
index 0a0588864bb897c6367c8428970717568d34d3b0..24d88c909d230d179e29603c0624be5bfa89586d 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Http\Middleware;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\Mfa\MfaSession;
+use BookStack\Access\LoginService;
+use BookStack\Access\Mfa\MfaSession;
 use Closure;
 
 class AuthenticatedOrPendingMfa
index 7dd970ade1140c61734547321e590aa9c321fda3..4b2737d281365fc4cc39521a6b87ab004bd5c8af 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Http\Middleware;
 
-use BookStack\Auth\Access\EmailConfirmationService;
-use BookStack\Auth\User;
+use BookStack\Access\EmailConfirmationService;
+use BookStack\Users\Models\User;
 use Closure;
 
 /**
index 3a2dd2190cb15f988e9eaddc24f0be83d1d77cf5..47723e242277cde35be724dc3730e57ca5d7b542 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Http\Middleware;
 
-use BookStack\Util\LanguageManager;
+use BookStack\Translation\LanguageManager;
 use Carbon\Carbon;
 use Closure;
 
index ee7fe880c7ad1f0c164531deebc4f82555c91241..069973a95b780cad77070e2b466e141f16db4c78 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Http\Middleware;
 
-use BookStack\Providers\RouteServiceProvider;
+use BookStack\App\Providers\RouteServiceProvider;
 use Closure;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\Auth;
diff --git a/app/Http/Requests/Request.php b/app/Http/Requests/Request.php
deleted file mode 100644 (file)
index cda901e..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<?php
-
-namespace BookStack\Http\Requests;
-
-use Illuminate\Foundation\Http\FormRequest;
-
-abstract class Request extends FormRequest
-{
-    //
-}
index 3bae32721ae69a4295e70395ba79c7a36c178e50..8804df586b7b8b4355b7e9b1dae8e716460da32f 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Notifications;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Illuminate\Notifications\Messages\MailMessage;
 
 class UserInvite extends MailNotification
similarity index 98%
rename from app/Http/Controllers/Api/ContentPermissionApiController.php
rename to app/Permissions/ContentPermissionApiController.php
index 47a0d37827d041d94449dca7195ec570774805d4..f883a292bb7ed4bd07cd1ad8b35dd1152940b216 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Permissions;
 
 use BookStack\Entities\EntityProvider;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Tools\PermissionsUpdater;
+use BookStack\Http\Controllers\ApiController;
 use Illuminate\Http\Request;
 
 class ContentPermissionApiController extends ApiController
similarity index 97%
rename from app/Auth/Permissions/EntityPermissionEvaluator.php
rename to app/Permissions/EntityPermissionEvaluator.php
index 51db45bbc06399ddbf4f65a17c1562cff7fa0ab8..06f0126ad290908ffdc86a2d3c1b73583cc3f89e 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
-use BookStack\Auth\Role;
 use BookStack\Entities\Models\Entity;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Users\Models\Role;
 use Illuminate\Database\Eloquent\Builder;
 
 class EntityPermissionEvaluator
similarity index 98%
rename from app/Auth/Permissions/JointPermissionBuilder.php
rename to app/Permissions/JointPermissionBuilder.php
index 4132a19af807e57c94814c03eb8e09d93a8311f8..945909631b7312934fb8f00ec3c91e0eae82aa91 100644 (file)
@@ -1,14 +1,15 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
-use BookStack\Auth\Role;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\BookChild;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Users\Models\Role;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Collection as EloquentCollection;
 use Illuminate\Support\Facades\DB;
similarity index 96%
rename from app/Auth/Permissions/MassEntityPermissionEvaluator.php
rename to app/Permissions/MassEntityPermissionEvaluator.php
index a9deba16db342ca42e493f172d10cfe5f337928e..4be69808b960965b31e4425285a68b861b4fff15 100644 (file)
@@ -1,6 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
+
+use BookStack\Permissions\Models\EntityPermission;
 
 class MassEntityPermissionEvaluator extends EntityPermissionEvaluator
 {
similarity index 90%
rename from app/Auth/Permissions/EntityPermission.php
rename to app/Permissions/Models/EntityPermission.php
index 603cf61ad64ca1e6252f44b22d6981de3310a1aa..1ef9c2886f5bacb43b5c03dba1f6b958e4017254 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions\Models;
 
-use BookStack\Auth\Role;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Users\Models\Role;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 
 /**
similarity index 85%
rename from app/Auth/Permissions/JointPermission.php
rename to app/Permissions/Models/JointPermission.php
index e10c560d0fdcfee557690939ad23328093689dcc..baf096fca32236b454cfb2509d9a933d7f6be071 100644 (file)
@@ -1,10 +1,10 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions\Models;
 
-use BookStack\Auth\Role;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
-use BookStack\Model;
+use BookStack\Users\Models\Role;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 use Illuminate\Database\Eloquent\Relations\MorphOne;
 
similarity index 86%
rename from app/Auth/Permissions/RolePermission.php
rename to app/Permissions/Models/RolePermission.php
index 467c43ce282c17941ced8d87705878b40de42c01..d43313ea0d8ca274d12623d9af23bd2ff3fa6b89 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions\Models;
 
-use BookStack\Auth\Role;
-use BookStack\Model;
+use BookStack\App\Model;
+use BookStack\Users\Models\Role;
 use Illuminate\Database\Eloquent\Relations\BelongsToMany;
 
 /**
similarity index 96%
rename from app/Auth/Permissions/PermissionApplicator.php
rename to app/Permissions/PermissionApplicator.php
index 84ac27f875ce2c0a632a346592feb0340718c69d..8a02f82e89bef03bd6297add1feeae921a49b5b7 100644 (file)
@@ -1,14 +1,15 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
-use BookStack\Model;
-use BookStack\Traits\HasCreatorAndUpdater;
-use BookStack\Traits\HasOwner;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Users\Models\HasCreatorAndUpdater;
+use BookStack\Users\Models\HasOwner;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Query\Builder as QueryBuilder;
 use InvalidArgumentException;
similarity index 93%
rename from app/Auth/Permissions/PermissionFormData.php
rename to app/Permissions/PermissionFormData.php
index 8044a3c5675847de5467e163ed7dea50c195d29f..eea1230fc9870c813e2339bff63a2f70e02d28f2 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
-use BookStack\Auth\Role;
 use BookStack\Entities\Models\Entity;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Users\Models\Role;
 
 class PermissionFormData
 {
similarity index 80%
rename from app/Auth/Permissions/PermissionStatus.php
rename to app/Permissions/PermissionStatus.php
index f8e55c20b9a246cfc38dc8b0f0d98f54461d7cd9..6cecc8afd1eab4b3ce3f0fc6ab21acbf3798e912 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
 class PermissionStatus
 {
similarity index 97%
rename from app/Http/Controllers/PermissionsController.php
rename to app/Permissions/PermissionsController.php
index 7d908733bc1f439f36036e960a0546222f2a7248..a066ec87cb90c3252c4426310b8c2ff2b5d81849 100644 (file)
@@ -1,15 +1,15 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Permissions;
 
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Permissions\PermissionFormData;
-use BookStack\Auth\Role;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Tools\PermissionsUpdater;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Users\Models\Role;
 use Illuminate\Http\Request;
 
 class PermissionsController extends Controller
similarity index 96%
rename from app/Auth/Permissions/PermissionsRepo.php
rename to app/Permissions/PermissionsRepo.php
index 75354e79bf53d09ba196e26d981ad1e848d45e9c..889a6ea0891133e932c3e8dba98cbc92fef2d2ba 100644 (file)
@@ -1,11 +1,12 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Role;
+use BookStack\Activity\ActivityType;
 use BookStack\Exceptions\PermissionsException;
 use BookStack\Facades\Activity;
+use BookStack\Permissions\Models\RolePermission;
+use BookStack\Users\Models\Role;
 use Exception;
 use Illuminate\Database\Eloquent\Collection;
 
similarity index 94%
rename from app/Auth/Permissions/SimpleEntityData.php
rename to app/Permissions/SimpleEntityData.php
index 2128451fe0d34294bde87034a174aa8dd2b8d07d..0eab5f070f61803ecc95304c819586469a51972e 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Auth\Permissions;
+namespace BookStack\Permissions;
 
 use BookStack\Entities\Models\Entity;
 
index e7afea5f1ffd1d16e03576afd1c5ee61b76a9da0..88ca5d6a7a5a23986c9f4e5a8b0d47891eda29b5 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\References;
 
-use BookStack\Model;
+use BookStack\App\Model;
 use BookStack\References\ModelResolvers\BookLinkModelResolver;
 use BookStack\References\ModelResolvers\BookshelfLinkModelResolver;
 use BookStack\References\ModelResolvers\ChapterLinkModelResolver;
index 12b2c594a746c39f8ac02b73a7536823defb3af4..d404fe2fd84dd9d2596687d70e3f8fa0fe18be43 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\References\ModelResolvers;
 
+use BookStack\App\Model;
 use BookStack\Entities\Models\Book;
-use BookStack\Model;
 
 class BookLinkModelResolver implements CrossLinkModelResolver
 {
index 5d403ac690bc2c54604d9c09d76798e88776183f..cc9df034e6055e001bfffaa01e8db9ace4285f68 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\References\ModelResolvers;
 
+use BookStack\App\Model;
 use BookStack\Entities\Models\Bookshelf;
-use BookStack\Model;
 
 class BookshelfLinkModelResolver implements CrossLinkModelResolver
 {
index b3eb7e7dc5576d8240c41e88a2459b106eccd39a..4733c68eead62c34529683143a4ac88638566038 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\References\ModelResolvers;
 
+use BookStack\App\Model;
 use BookStack\Entities\Models\Chapter;
-use BookStack\Model;
 
 class ChapterLinkModelResolver implements CrossLinkModelResolver
 {
index f2cb49779b7c16cfcc9719fffb82663dec1f1e3c..67d9214c52bc1aff2ef1e2a457297eacaa4a7a7e 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\References\ModelResolvers;
 
-use BookStack\Model;
+use BookStack\App\Model;
 
 interface CrossLinkModelResolver
 {
index bf08d7bfc462e61592d12b916e0b92ce001d3634..736382becdd1cc38b849b973512f9a81c3b54fec 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\References\ModelResolvers;
 
+use BookStack\App\Model;
 use BookStack\Entities\Models\Page;
-use BookStack\Model;
 
 class PageLinkModelResolver implements CrossLinkModelResolver
 {
index 9537ee268c6adfb78fad9802518d673715f3019d..9ed00b36dd4c3326ed928163e2007049ac7151ea 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\References\ModelResolvers;
 
+use BookStack\App\Model;
 use BookStack\Entities\Models\Page;
-use BookStack\Model;
 
 class PagePermalinkModelResolver implements CrossLinkModelResolver
 {
index 0e5b17d0b7a72eb3ea6c5ba978c48befd01f4900..df8a3a78932eac36f6f17f4e7bb2b400c95cbaa9 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\References;
 
-use BookStack\Auth\Permissions\JointPermission;
+use BookStack\Permissions\Models\JointPermission;
 use Illuminate\Database\Eloquent\Model;
 use Illuminate\Database\Eloquent\Relations\HasMany;
 use Illuminate\Database\Eloquent\Relations\MorphTo;
similarity index 96%
rename from app/Http/Controllers/ReferenceController.php
rename to app/References/ReferenceController.php
index b9b3e0eab9613e243a0dd7d67c718c1ef81fd8ec..69da7bd5f6476176b6943cdc90342d3a969b066d 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\References;
 
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
-use BookStack\References\ReferenceFetcher;
+use BookStack\Http\Controllers\Controller;
 
 class ReferenceController extends Controller
 {
index 41579185798ed541d7d8970c5f7cb2023c1fdcb7..c4a7d31b60b451632de5ecdb5756d460da1c08ec 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace BookStack\References;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\PermissionApplicator;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Collection;
 use Illuminate\Database\Eloquent\Relations\Relation;
similarity index 93%
rename from app/Http/Controllers/Api/SearchApiController.php
rename to app/Search/SearchApiController.php
index bf59ec67162f1a264c59a734ba9c33634f5d15bf..14b946abc88ac0a6a6dd878239c3c19a5bb7f915 100644 (file)
@@ -1,12 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Search;
 
 use BookStack\Api\ApiEntityListFormatter;
 use BookStack\Entities\Models\Entity;
-use BookStack\Search\SearchOptions;
-use BookStack\Search\SearchResultsFormatter;
-use BookStack\Search\SearchRunner;
+use BookStack\Http\Controllers\ApiController;
 use Illuminate\Http\Request;
 
 class SearchApiController extends ApiController
similarity index 96%
rename from app/Http/Controllers/SearchController.php
rename to app/Search/SearchController.php
index 8df5cfafb805514ec9daf728c8832255129d42a7..aabc17a41f951f73f64f00fb5614fcb2c6790216 100644 (file)
@@ -1,12 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Search;
 
 use BookStack\Entities\Queries\Popular;
 use BookStack\Entities\Tools\SiblingFetcher;
-use BookStack\Search\SearchOptions;
-use BookStack\Search\SearchResultsFormatter;
-use BookStack\Search\SearchRunner;
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 
 class SearchController extends Controller
index 25389226a1ad5b1817c401fbef64adeb4044b743..e882e987b98866e73e28dfa28cbcd8e5eed11bf4 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Search;
 
-use BookStack\Actions\Tag;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\EntityProvider;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
index 9cbc5ee6862d708457be7ba9b0efe4ef0d0ce335..02a40632e22a0a8c3c37042cfa25bb671cc96a12 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Search;
 
-use BookStack\Actions\Tag;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Entity;
 use Illuminate\Support\HtmlString;
 
index a0fd1fe3dab8264f63ef7ec95088a4db665baa66..fc36cb816c8e90219f57f3cec344b559fe6c2134 100644 (file)
@@ -2,12 +2,12 @@
 
 namespace BookStack\Search;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
-use BookStack\Auth\User;
 use BookStack\Entities\EntityProvider;
 use BookStack\Entities\Models\BookChild;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\PermissionApplicator;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Connection;
 use Illuminate\Database\Eloquent\Builder as EloquentBuilder;
 use Illuminate\Database\Eloquent\Collection as EloquentCollection;
index d416b0059e6bdc0267037eb5784d89a5fc010b98..ba45bb329d566b5de8f6c58f64225aa4423ccabc 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Search;
 
-use BookStack\Model;
+use BookStack\App\Model;
 
 class SearchTerm extends Model
 {
similarity index 96%
rename from app/Http/Controllers/MaintenanceController.php
rename to app/Settings/MaintenanceController.php
index 8bfefb7acb95f1fe4c7d509f4e7084ba14e4da05..7bf4c973c50116a9f70353bf9fe9dd6b90320d3f 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Settings;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Tools\TrashCan;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Notifications\TestEmail;
 use BookStack\References\ReferenceStore;
 use BookStack\Uploads\ImageService;
index c0492e6c1f7ca9133de70ba042b4d0b5823a6038..2bd56408866a92b02ee209d555abde896e453500 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Settings;
 
-use BookStack\Model;
+use BookStack\App\Model;
 
 class Setting extends Model
 {
similarity index 91%
rename from app/Http/Controllers/SettingController.php
rename to app/Settings/SettingController.php
index 1e13d7cb77ed4001598f2cb8a85bbde357e7ea6c..b58d23339a45bf3afa2408a353dae28b31886600 100644 (file)
@@ -1,11 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Settings;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\User;
-use BookStack\Settings\AppSettingsStore;
-use BookStack\Uploads\ImageRepo;
+use BookStack\Activity\ActivityType;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Users\Models\User;
 use Illuminate\Http\Request;
 
 class SettingController extends Controller
index 9bcd6c7ec5ca6c33b4bc5e09395832ca721c6e22..1c5cbdf5af37e12df8c77b9908b76126e90467b4 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Settings;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 
 /**
  * Class SettingService
similarity index 94%
rename from app/Http/Controllers/StatusController.php
rename to app/Settings/StatusController.php
index ab4f67d0a68628b9e60814f2572804d6a34c930a..9559e344ce20ded960212d74d588a0c972e41a59 100644 (file)
@@ -1,7 +1,8 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Settings;
 
+use BookStack\Http\Controllers\Controller;
 use Illuminate\Support\Facades\Cache;
 use Illuminate\Support\Facades\DB;
 use Illuminate\Support\Facades\Session;
index aacef80cfd29117c284398f9d2d695e20db52eef..994c3ec0dbaacfb97524aca906b890e503cc1f70 100644 (file)
@@ -26,7 +26,7 @@ class ThemeEvents
      * the type before making use of this parameter.
      *
      * @param string                                $type
-     * @param string|\BookStack\Interfaces\Loggable $detail
+     * @param string|\BookStack\Activity\Models\Loggable $detail
      */
     const ACTIVITY_LOGGED = 'activity_logged';
 
@@ -34,7 +34,7 @@ class ThemeEvents
      * Application boot-up.
      * After main services are registered.
      *
-     * @param \BookStack\Application $app
+     * @param \BookStack\App\Application $app
      */
     const APP_BOOT = 'app_boot';
 
@@ -45,7 +45,7 @@ class ThemeEvents
      * after registration. This is not emitted upon API usage.
      *
      * @param string               $authSystem
-     * @param \BookStack\Auth\User $user
+     * @param \BookStack\Users\Models\User $user
      */
     const AUTH_LOGIN = 'auth_login';
 
@@ -56,7 +56,7 @@ class ThemeEvents
      * by LDAP, SAML and social systems. It only includes self-registrations.
      *
      * @param string               $authSystem
-     * @param \BookStack\Auth\User $user
+     * @param \BookStack\Users\Models\User $user
      */
     const AUTH_REGISTER = 'auth_register';
 
@@ -133,9 +133,9 @@ class ThemeEvents
      * of the system default.
      *
      * @param string                                $event
-     * @param \BookStack\Actions\Webhook            $webhook
-     * @param string|\BookStack\Interfaces\Loggable $detail
-     * @param \BookStack\Auth\User                  $initiator
+     * @param \BookStack\Activity\Models\Webhook            $webhook
+     * @param string|\BookStack\Activity\Models\Loggable $detail
+     * @param \BookStack\Users\Models\User                  $initiator
      * @param int                                   $initiatedTime
      */
     const WEBHOOK_CALL_BEFORE = 'webhook_call_before';
index 275dc9d8c94d421fa4af8467e98146e73fa4404b..bb91643e308114b567119fed99349b7e6951f98e 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Theming;
 
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\SocialAuthService;
 use Illuminate\Console\Application;
 use Illuminate\Console\Application as Artisan;
 use Symfony\Component\Console\Command\Command;
similarity index 99%
rename from app/Util/LanguageManager.php
rename to app/Translation/LanguageManager.php
index 93c992fcc0871ff24d7e622609d389351ba82a78..39dee8461d5a8f2f302b023840c1e39780229e85 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Util;
+namespace BookStack\Translation;
 
 use Illuminate\Http\Request;
 
index e33b13db449a8f51eca600ff7eb4cb2a10242ae0..4fd6d4cdcb7d6c34ba82baeaca8ef6d04fad6cd8 100644 (file)
@@ -2,13 +2,13 @@
 
 namespace BookStack\Uploads;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Auth\Permissions\PermissionApplicator;
-use BookStack\Auth\User;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
-use BookStack\Model;
-use BookStack\Traits\HasCreatorAndUpdater;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Permissions\PermissionApplicator;
+use BookStack\Users\Models\HasCreatorAndUpdater;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
similarity index 98%
rename from app/Http/Controllers/Api/AttachmentApiController.php
rename to app/Uploads/Controllers/AttachmentApiController.php
index 9fc7f3bdef2c1fdc8539971e1f5438747be213bf..da8956789f17cb9dd084fc3e2e98adfe3b68d239 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Entities\Models\Page;
 use BookStack\Exceptions\FileUploadException;
+use BookStack\Http\Controllers\ApiController;
 use BookStack\Uploads\Attachment;
 use BookStack\Uploads\AttachmentService;
 use Exception;
similarity index 99%
rename from app/Http/Controllers/AttachmentController.php
rename to app/Uploads/Controllers/AttachmentController.php
index b6ce261d481aa6d8aad0bbdd5bb48d81676c3a37..7056f48777e9dc8f952dbfffddcddbd45f023242 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Exceptions\FileUploadException;
 use BookStack\Exceptions\NotFoundException;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Uploads\Attachment;
 use BookStack\Uploads\AttachmentService;
 use Exception;
similarity index 98%
rename from app/Http/Controllers/Images/DrawioImageController.php
rename to app/Uploads/Controllers/DrawioImageController.php
index ce857cf52f07b59b238709cfb47c0fae0efb2c6c..198cae2fe52347fc09d0caa41e58db36b911519e 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Http\Controllers\Images;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Http\Controllers\Controller;
similarity index 97%
rename from app/Http/Controllers/Images/GalleryImageController.php
rename to app/Uploads/Controllers/GalleryImageController.php
index c01eccfee30193a5fc95f85f5a2630e190846569..879f64f0740ad74db37cc1c490d4f2a1dfb47259 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Http\Controllers\Images;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Http\Controllers\Controller;
similarity index 98%
rename from app/Http/Controllers/Images/ImageController.php
rename to app/Uploads/Controllers/ImageController.php
index cd6b2d4063f8287f1e451eecb1ff8c756028c61f..6c2be269ab98959ca876d71d7bbfa57046d2034a 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-namespace BookStack\Http\Controllers\Images;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Exceptions\NotFoundException;
similarity index 98%
rename from app/Http/Controllers/Api/ImageGalleryApiController.php
rename to app/Uploads/Controllers/ImageGalleryApiController.php
index 3dba3d464a66fff8c2203ac2b7f10e2c00a89b93..1684ea21e65e808a72ad7f8e843fa86f40c0bc2b 100644 (file)
@@ -1,8 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Uploads\Controllers;
 
 use BookStack\Entities\Models\Page;
+use BookStack\Http\Controllers\ApiController;
 use BookStack\Uploads\Image;
 use BookStack\Uploads\ImageRepo;
 use Illuminate\Http\Request;
index 0ab0b612a7c10a00b6f074d71e9e4e28f49ee2a9..9f571693a0ab68830faedc90c212d8e47e5d6b47 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace BookStack\Uploads;
 
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Auth\Permissions\PermissionApplicator;
+use BookStack\App\Model;
 use BookStack\Entities\Models\Page;
-use BookStack\Model;
-use BookStack\Traits\HasCreatorAndUpdater;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Permissions\PermissionApplicator;
+use BookStack\Users\Models\HasCreatorAndUpdater;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Relations\HasMany;
index 2c643a58be0f05110f88b0d881452e2b5e4a9289..2d35d96ffa127ca167c3d8ac78af622e51693da2 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace BookStack\Uploads;
 
-use BookStack\Auth\Permissions\PermissionApplicator;
 use BookStack\Entities\Models\Page;
 use BookStack\Exceptions\ImageUploadException;
+use BookStack\Permissions\PermissionApplicator;
 use Exception;
 use Illuminate\Database\Eloquent\Builder;
 use Symfony\Component\HttpFoundation\File\UploadedFile;
index 49a54bbbbb9b387dfa3e964bbe004f62e42e274b..89e88bd19e02d804fa9132754579a2dcc6c21ab0 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace BookStack\Uploads;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\HttpFetchException;
+use BookStack\Users\Models\User;
 use Exception;
 use Illuminate\Support\Facades\Log;
 use Illuminate\Support\Str;
similarity index 96%
rename from app/Http/Controllers/Api/RoleApiController.php
rename to app/Users/Controllers/RoleApiController.php
index 6986c73f78d9befe3465b0fed3ee1b8b3a98b894..a01ff92d02bf66a8cb4dfff82283c18c04e429be 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\Permissions\PermissionsRepo;
-use BookStack\Auth\Role;
+use BookStack\Http\Controllers\ApiController;
+use BookStack\Permissions\PermissionsRepo;
+use BookStack\Users\Models\Role;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\DB;
 
similarity index 95%
rename from app/Http/Controllers/RoleController.php
rename to app/Users/Controllers/RoleController.php
index 6d397bdae61c491f30e183f7c4efd23ecf2c5ca8..c383df39bebf0c858988525d6b41c9eb6d865627 100644 (file)
@@ -1,15 +1,15 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\Permissions\PermissionsRepo;
-use BookStack\Auth\Queries\RolesAllPaginatedAndSorted;
-use BookStack\Auth\Role;
 use BookStack\Exceptions\PermissionsException;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Permissions\PermissionsRepo;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Queries\RolesAllPaginatedAndSorted;
 use BookStack\Util\SimpleListOptions;
 use Exception;
 use Illuminate\Http\Request;
-use Illuminate\Validation\ValidationException;
 
 class RoleController extends Controller
 {
similarity index 97%
rename from app/Http/Controllers/Api/UserApiController.php
rename to app/Users/Controllers/UserApiController.php
index da6ca4321c3eab9c05ed4046efa535bf2ab9640f..750e87f0ef5f1f695a4720525070f26ed578c2f0 100644 (file)
@@ -1,10 +1,11 @@
 <?php
 
-namespace BookStack\Http\Controllers\Api;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\User;
-use BookStack\Auth\UserRepo;
 use BookStack\Exceptions\UserUpdateException;
+use BookStack\Http\Controllers\ApiController;
+use BookStack\Users\Models\User;
+use BookStack\Users\UserRepo;
 use Closure;
 use Illuminate\Http\Request;
 use Illuminate\Support\Facades\DB;
similarity index 96%
rename from app/Http/Controllers/UserController.php
rename to app/Users/Controllers/UserController.php
index cd95f7220766fb6598567afe8ca9d2d7098ac331..5aad03766a7ba52ef24e349e4fca23dd33891b02 100644 (file)
@@ -1,14 +1,15 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\Access\SocialAuthService;
-use BookStack\Auth\Queries\UsersAllPaginatedAndSorted;
-use BookStack\Auth\Role;
-use BookStack\Auth\UserRepo;
+use BookStack\Access\SocialAuthService;
 use BookStack\Exceptions\ImageUploadException;
 use BookStack\Exceptions\UserUpdateException;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Uploads\ImageRepo;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Queries\UsersAllPaginatedAndSorted;
+use BookStack\Users\UserRepo;
 use BookStack\Util\SimpleListOptions;
 use Exception;
 use Illuminate\Http\Request;
similarity index 97%
rename from app/Http/Controllers/UserPreferencesController.php
rename to app/Users/Controllers/UserPreferencesController.php
index 560dd16321589bc1611bf9e5ef52579d194a4caf..57414aefdab7f910d5e831c7c17484c1cf5a7209 100644 (file)
@@ -1,9 +1,10 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\UserRepo;
+use BookStack\Http\Controllers\Controller;
 use BookStack\Settings\UserShortcutMap;
+use BookStack\Users\UserRepo;
 use Illuminate\Http\Request;
 
 class UserPreferencesController extends Controller
similarity index 74%
rename from app/Http/Controllers/UserProfileController.php
rename to app/Users/Controllers/UserProfileController.php
index e75aced126ffbffbd0a76c2363ec9d5d102d6a9e..c1a82dda9e872564c9562e9af9f7e6d0ea94bd3c 100644 (file)
@@ -1,11 +1,12 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Actions\ActivityQueries;
-use BookStack\Auth\Queries\UserContentCounts;
-use BookStack\Auth\Queries\UserRecentlyCreatedContent;
-use BookStack\Auth\UserRepo;
+use BookStack\Activity\ActivityQueries;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Users\Queries\UserContentCounts;
+use BookStack\Users\Queries\UserRecentlyCreatedContent;
+use BookStack\Users\UserRepo;
 
 class UserProfileController extends Controller
 {
similarity index 88%
rename from app/Http/Controllers/UserSearchController.php
rename to app/Users/Controllers/UserSearchController.php
index df234347c5cfd2151c50df84eb49af1385fdc232..6523b2723ab14179c80e97638a5b2ddfa4ebdaa8 100644 (file)
@@ -1,8 +1,9 @@
 <?php
 
-namespace BookStack\Http\Controllers;
+namespace BookStack\Users\Controllers;
 
-use BookStack\Auth\User;
+use BookStack\Http\Controllers\Controller;
+use BookStack\Users\Models\User;
 use Illuminate\Http\Request;
 
 class UserSearchController extends Controller
similarity index 90%
rename from app/Traits/HasCreatorAndUpdater.php
rename to app/Users/Models/HasCreatorAndUpdater.php
index 7c60be750059d048251c6ee41574d3b962e5b7c1..5ff46bc3cb78747b4be997b6d33320e24164094a 100644 (file)
@@ -1,8 +1,7 @@
 <?php
 
-namespace BookStack\Traits;
+namespace BookStack\Users\Models;
 
-use BookStack\Auth\User;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 
 /**
similarity index 84%
rename from app/Traits/HasOwner.php
rename to app/Users/Models/HasOwner.php
index c0fefafa9cb7dc6fa60a6fd325b98e973ab1c669..eb830ef6fda215b18ef3dda405e3475a92356801 100644 (file)
@@ -1,8 +1,7 @@
 <?php
 
-namespace BookStack\Traits;
+namespace BookStack\Users\Models;
 
-use BookStack\Auth\User;
 use Illuminate\Database\Eloquent\Relations\BelongsTo;
 
 /**
similarity index 92%
rename from app/Auth/Role.php
rename to app/Users/Models/Role.php
index 8f9702fa0e39b7bcdd9a105a1fc432853ead4a0c..d1452e66bae026dc67101f50e846fe9bbc8c0dcb 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Auth;
+namespace BookStack\Users\Models;
 
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Permissions\JointPermission;
-use BookStack\Auth\Permissions\RolePermission;
-use BookStack\Interfaces\Loggable;
-use BookStack\Model;
+use BookStack\Activity\Models\Loggable;
+use BookStack\App\Model;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Permissions\Models\JointPermission;
+use BookStack\Permissions\Models\RolePermission;
 use Illuminate\Database\Eloquent\Collection;
 use Illuminate\Database\Eloquent\Factories\HasFactory;
 use Illuminate\Database\Eloquent\Relations\BelongsToMany;
similarity index 97%
rename from app/Auth/User.php
rename to app/Users/Models/User.php
index 90bb3d68e3f74fbc6cb77cabfcbe511912d6925b..08cab69fb9206c793cde08cf08518f345188e5a0 100644 (file)
@@ -1,14 +1,15 @@
 <?php
 
-namespace BookStack\Auth;
+namespace BookStack\Users\Models;
 
-use BookStack\Actions\Favourite;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Access\SocialAccount;
+use BookStack\Activity\Models\Favourite;
+use BookStack\Activity\Models\Loggable;
 use BookStack\Api\ApiToken;
-use BookStack\Auth\Access\Mfa\MfaValue;
+use BookStack\App\Model;
+use BookStack\App\Sluggable;
 use BookStack\Entities\Tools\SlugGenerator;
-use BookStack\Interfaces\Loggable;
-use BookStack\Interfaces\Sluggable;
-use BookStack\Model;
 use BookStack\Notifications\ResetPassword;
 use BookStack\Uploads\Image;
 use Carbon\Carbon;
similarity index 93%
rename from app/Auth/Queries/RolesAllPaginatedAndSorted.php
rename to app/Users/Queries/RolesAllPaginatedAndSorted.php
index 9ee4f6c249c56689849c7cb97add4ee6fbafeb25..7fd4048dfca44f53a4edd47e303db90dd7389c33 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Queries;
+namespace BookStack\Users\Queries;
 
-use BookStack\Auth\Role;
+use BookStack\Users\Models\Role;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Pagination\LengthAwarePaginator;
 
similarity index 91%
rename from app/Auth/Queries/UserContentCounts.php
rename to app/Users/Queries/UserContentCounts.php
index 397719383f73461ed15516ff6ad4128059a7a666..178d8536b1d44441d4dc0ef0950e44947b712992 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Auth\Queries;
+namespace BookStack\Users\Queries;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
+use BookStack\Users\Models\User;
 
 /**
  * Get asset created counts for the given user.
similarity index 93%
rename from app/Auth/Queries/UserRecentlyCreatedContent.php
rename to app/Users/Queries/UserRecentlyCreatedContent.php
index 5060227c07121106af647d0bc2c285e4caf1ccd4..23db2c1f1a2a42ad38254b0237496f904a1537ec 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 
-namespace BookStack\Auth\Queries;
+namespace BookStack\Users\Queries;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Builder;
 use Illuminate\Database\Eloquent\Collection;
 
similarity index 94%
rename from app/Auth/Queries/UsersAllPaginatedAndSorted.php
rename to app/Users/Queries/UsersAllPaginatedAndSorted.php
index 29b6a89697bc880daf0788f66158fe8431b861db..3ef12e07baa9042aa4a785e7e472c34c01d4f9f3 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
-namespace BookStack\Auth\Queries;
+namespace BookStack\Users\Queries;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use BookStack\Util\SimpleListOptions;
 use Illuminate\Pagination\LengthAwarePaginator;
 
similarity index 97%
rename from app/Auth/UserRepo.php
rename to app/Users/UserRepo.php
index 2c27f34a7e84d120f6aad811c4d4750804c08092..408ee6a8e5d21514dc0441f58aaaf49d3d1eb450 100644 (file)
@@ -1,14 +1,16 @@
 <?php
 
-namespace BookStack\Auth;
+namespace BookStack\Users;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\UserInviteService;
+use BookStack\Access\UserInviteService;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\EntityProvider;
 use BookStack\Exceptions\NotifyException;
 use BookStack\Exceptions\UserUpdateException;
 use BookStack\Facades\Activity;
 use BookStack\Uploads\UserAvatars;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Exception;
 use Illuminate\Support\Facades\Hash;
 use Illuminate\Support\Facades\Log;
index 6538aa81c50789b32194f77ddb4e7108dafe407c..12cc2dce2b36bed74d5971207c86a41fb1a78e41 100644 (file)
@@ -11,7 +11,7 @@
 |
 */
 
-$app = new BookStack\Application(
+$app = new \BookStack\App\Application(
     dirname(__DIR__)
 );
 
index 44143e04233a1be8897b8ddfea2edcf3fb3af93a..eba231d44fe862ea8b21d3d095f1450526e2a9f9 100644 (file)
@@ -58,7 +58,7 @@
             "Database\\Seeders\\": "database/seeders/"
         },
         "files": [
-            "app/helpers.php"
+            "app/App/helpers.php"
         ]
     },
     "autoload-dev": {
index e81f3fe2c5475c8f2474d0f27c682a6ede73ae49..d398bf415aebe4ffaf8d01cde12ecc8cf17830d2 100644 (file)
@@ -11,7 +11,7 @@ class CommentFactory extends Factory
      *
      * @var string
      */
-    protected $model = \BookStack\Actions\Comment::class;
+    protected $model = \BookStack\Activity\Models\Comment::class;
 
     /**
      * Define the model's default state.
index 8b9c529f2ee7d69a385b069991a9314894ab8108..4b047eb2a76ef5f7a4d25a69263c2670ac83519e 100644 (file)
@@ -11,7 +11,7 @@ class TagFactory extends Factory
      *
      * @var string
      */
-    protected $model = \BookStack\Actions\Tag::class;
+    protected $model = \BookStack\Activity\Models\Tag::class;
 
     /**
      * Define the model's default state.
index c7393b32c53d01344c7fbbe314223c105f4ff23d..c17cf5a09ebb433bc748def7971f21af01cdc3a6 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Database\Factories\Actions;
 
-use BookStack\Actions\Webhook;
+use BookStack\Activity\Models\Webhook;
 use Illuminate\Database\Eloquent\Factories\Factory;
 
 class WebhookFactory extends Factory
index 71b8774bc7c27df189371296c78630f581703bfb..8e7865ff12b3069b159a8fe08d8c1382e82e9663 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Database\Factories\Actions;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Webhook;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Webhook;
 use Illuminate\Database\Eloquent\Factories\Factory;
 
 class WebhookTrackedEventFactory extends Factory
index 6ab3d710e96f8e61f32288f12dba915f5e26f6a8..60348ff493d532ae7fbb74c6eb6bc6aa8112da4b 100644 (file)
@@ -11,7 +11,7 @@ class RoleFactory extends Factory
      *
      * @var string
      */
-    protected $model = \BookStack\Auth\Role::class;
+    protected $model = \BookStack\Users\Models\Role::class;
 
     /**
      * Define the model's default state.
index 6ff62a97569e5932e09b8da8d827c57e42f04b90..ad1a5629a1fa5d77c28d21881777a56e45ab2619 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Database\Factories\Auth;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Factories\Factory;
 use Illuminate\Support\Str;
 
index 30722265dae57b85e34636187e75549ad2549fb1..83dec65252840d228ce64d92ab0a4d25f68e50ed 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Database\Factories\Uploads;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Page;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Factories\Factory;
 
 /**
index 411868c8e2c28547284cf4f0ad99444355802378..53994c52b57ef5f56f1d63a5ae7ce7c9590011f4 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-use BookStack\Auth\Permissions\JointPermissionBuilder;
+use BookStack\Permissions\JointPermissionBuilder;
 use Illuminate\Database\Migrations\Migration;
 use Illuminate\Database\Schema\Blueprint;
 use Illuminate\Support\Facades\DB;
index f61e4e13df394e20adc51170110cf97feec37890..0f030d671fad8e61c138e6c3846eda9052b8c6a6 100644 (file)
@@ -3,14 +3,14 @@
 namespace Database\Seeders;
 
 use BookStack\Api\ApiToken;
-use BookStack\Auth\Permissions\JointPermissionBuilder;
-use BookStack\Auth\Permissions\RolePermission;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\JointPermissionBuilder;
+use BookStack\Permissions\Models\RolePermission;
 use BookStack\Search\SearchIndex;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Seeder;
 use Illuminate\Support\Facades\Hash;
 use Illuminate\Support\Str;
index d0e65f9749024030436f1907671d0ab3a50df6f9..bb9b087d2951201e871de2f84a14a24bfdc1cde8 100644 (file)
@@ -2,13 +2,13 @@
 
 namespace Database\Seeders;
 
-use BookStack\Auth\Permissions\JointPermissionBuilder;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
+use BookStack\Permissions\JointPermissionBuilder;
 use BookStack\Search\SearchIndex;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Seeder;
 use Illuminate\Support\Str;
 
index 2edb3e040eee6ca4c4ed1ebf3ef906fcdcc2478b..08427f1a5ed293e7c9eae924ea3bdbcfdadf44d0 100644 (file)
@@ -1 +1 @@
-@push('body-class', e((new \BookStack\Actions\TagClassGenerator($entity->tags->all()))->generateAsString() . ' '))
\ No newline at end of file
+@push('body-class', e((new \BookStack\Activity\Tools\TagClassGenerator($entity->tags->all()))->generateAsString() . ' '))
\ No newline at end of file
index 9bf309fb802952f16f9dabee3f076006087cac63..8eddac8dea0e9a1300ea60e941a7b578af4c0cbc 100644 (file)
@@ -1,5 +1,5 @@
 <?php
-  /** @var \BookStack\Auth\Permissions\PermissionFormData $data */
+/** @var \BookStack\Permissions\PermissionFormData $data */
 ?>
 <form component="entity-permissions"
       option:entity-permissions:entity-type="{{ $model->getType() }}"
@@ -48,7 +48,8 @@
 
     <div class="flex-container-row justify-flex-end mb-xl">
         <div class="flex-container-row items-center gap-m">
-            <label for="role_select" class="m-none p-none"><span class="bold">{{ trans('entities.permissions_role_override') }}</span></label>
+            <label for="role_select" class="m-none p-none"><span
+                        class="bold">{{ trans('entities.permissions_role_override') }}</span></label>
             <select name="role_select" id="role_select" refs="entity-permissions@role-select">
                 <option value="">{{ trans('common.select') }}</option>
                 @foreach($data->rolesNotAssigned() as $role)
index abb9c2771116bfe4363b74e6d6ffdee128970855..b575968e21f1fa909acbe8aa4cbea7bc74f35687 100644 (file)
 @extends('layouts.simple')
 
 @section('body')
-<div class="container">
-
-    @include('settings.parts.navbar', ['selected' => 'audit'])
-
-    <div class="card content-wrap auto-height">
-        <h1 class="list-heading">{{ trans('settings.audit') }}</h1>
-        <p class="text-muted">{{ trans('settings.audit_desc') }}</p>
-
-        <form action="{{ url('/settings/audit') }}" method="get" class="flex-container-row wrap justify-flex-start gap-x-m gap-y-xs">
-
-            @foreach(request()->only(['order', 'sort']) as $key => $val)
-                <input type="hidden" name="{{ $key }}" value="{{ $val }}">
-            @endforeach
-
-            <div component="dropdown" class="list-sort-type dropdown-container">
-                <label for="">{{ trans('settings.audit_event_filter') }}</label>
-                <button refs="dropdown@toggle"
-                        type="button"
-                        aria-haspopup="true"
-                        aria-expanded="false"
-                        aria-label="{{ trans('common.sort_options') }}"
-                        class="input-base text-left">{{ $filters['event'] ?: trans('settings.audit_event_filter_no_filter') }}</button>
-                <ul refs="dropdown@menu" class="dropdown-menu">
-                    <li @if($filters['event'] === '') class="active" @endif><a href="{{ sortUrl('/settings/audit', array_filter(request()->except('page')), ['event' => '']) }}" class="text-item">{{ trans('settings.audit_event_filter_no_filter') }}</a></li>
-                    @foreach($activityTypes as $type)
-                        <li @if($type === $filters['event']) class="active" @endif><a href="{{ sortUrl('/settings/audit', array_filter(request()->except('page')), ['event' => $type]) }}" class="text-item">{{ $type }}</a></li>
-                    @endforeach
-                </ul>
-            </div>
-
-            @if(!empty($filters['event']))
-                <input type="hidden" name="event" value="{{ $filters['event'] }}">
-            @endif
-
-            @foreach(['date_from', 'date_to'] as $filterKey)
-                <div class=>
-                    <label for="audit_filter_{{ $filterKey }}">{{ trans('settings.audit_' . $filterKey) }}</label>
-                    <input id="audit_filter_{{ $filterKey }}"
-                           component="submit-on-change"
-                           type="date"
-                           name="{{ $filterKey }}"
-                           value="{{ $filters[$filterKey] ?? '' }}">
+    <div class="container">
+
+        @include('settings.parts.navbar', ['selected' => 'audit'])
+
+        <div class="card content-wrap auto-height">
+            <h1 class="list-heading">{{ trans('settings.audit') }}</h1>
+            <p class="text-muted">{{ trans('settings.audit_desc') }}</p>
+
+            <form action="{{ url('/settings/audit') }}" method="get"
+                  class="flex-container-row wrap justify-flex-start gap-x-m gap-y-xs">
+
+                @foreach(request()->only(['order', 'sort']) as $key => $val)
+                    <input type="hidden" name="{{ $key }}" value="{{ $val }}">
+                @endforeach
+
+                <div component="dropdown" class="list-sort-type dropdown-container">
+                    <label for="">{{ trans('settings.audit_event_filter') }}</label>
+                    <button refs="dropdown@toggle"
+                            type="button"
+                            aria-haspopup="true"
+                            aria-expanded="false"
+                            aria-label="{{ trans('common.sort_options') }}"
+                            class="input-base text-left">{{ $filters['event'] ?: trans('settings.audit_event_filter_no_filter') }}</button>
+                    <ul refs="dropdown@menu" class="dropdown-menu">
+                        <li @if($filters['event'] === '') class="active" @endif><a
+                                    href="{{ sortUrl('/settings/audit', array_filter(request()->except('page')), ['event' => '']) }}"
+                                    class="text-item">{{ trans('settings.audit_event_filter_no_filter') }}</a></li>
+                        @foreach($activityTypes as $type)
+                            <li @if($type === $filters['event']) class="active" @endif><a
+                                        href="{{ sortUrl('/settings/audit', array_filter(request()->except('page')), ['event' => $type]) }}"
+                                        class="text-item">{{ $type }}</a></li>
+                        @endforeach
+                    </ul>
                 </div>
-            @endforeach
 
-            <div class="form-group"
-                 component="submit-on-change"
-                 option:submit-on-change:filter='[name="user"]'>
-                <label for="owner">{{ trans('settings.audit_table_user') }}</label>
-                @include('form.user-select', ['user' => $filters['user'] ? \BookStack\Auth\User::query()->find($filters['user']) : null, 'name' => 'user'])
-            </div>
+                @if(!empty($filters['event']))
+                    <input type="hidden" name="event" value="{{ $filters['event'] }}">
+                @endif
+
+                @foreach(['date_from', 'date_to'] as $filterKey)
+                    <div class=>
+                        <label for="audit_filter_{{ $filterKey }}">{{ trans('settings.audit_' . $filterKey) }}</label>
+                        <input id="audit_filter_{{ $filterKey }}"
+                               component="submit-on-change"
+                               type="date"
+                               name="{{ $filterKey }}"
+                               value="{{ $filters[$filterKey] ?? '' }}">
+                    </div>
+                @endforeach
 
+                <div class="form-group"
+                     component="submit-on-change"
+                     option:submit-on-change:filter='[name="user"]'>
+                    <label for="owner">{{ trans('settings.audit_table_user') }}</label>
+                    @include('form.user-select', ['user' => $filters['user'] ? \BookStack\Users\Models\User::query()->find($filters['user']) : null, 'name' => 'user'])
+                </div>
 
-            <div class="form-group">
-                <label for="ip">{{ trans('settings.audit_table_ip') }}</label>
-                @include('form.text', ['name' => 'ip', 'model' => (object) $filters])
-                <input type="submit" style="display: none">
-            </div>
-        </form>
 
-        <hr class="mt-m mb-s">
+                <div class="form-group">
+                    <label for="ip">{{ trans('settings.audit_table_ip') }}</label>
+                    @include('form.text', ['name' => 'ip', 'model' => (object) $filters])
+                    <input type="submit" style="display: none">
+                </div>
+            </form>
 
-        <div class="flex-container-row justify-space-between items-center wrap">
-            <div class="flex-2 min-width-xl">{{ $activities->links() }}</div>
-            <div class="flex-none min-width-m py-m">
-                @include('common.sort', array_merge($listOptions->getSortControlData(), ['useQuery' => true]))
-            </div>
-        </div>
+            <hr class="mt-m mb-s">
 
-        <div class="item-list">
-            <div class="item-list-row flex-container-row items-center bold hide-under-m">
-                <div class="flex-2 px-m py-xs flex-container-row items-center">{{ trans('settings.audit_table_user') }}</div>
-                <div class="flex-2 px-m py-xs">{{ trans('settings.audit_table_event') }}</div>
-                <div class="flex-3 px-m py-xs">{{ trans('settings.audit_table_related') }}</div>
-                <div class="flex-container-row flex-3">
-                    <div class="flex px-m py-xs">{{ trans('settings.audit_table_ip') }}</div>
-                    <div class="flex-2 px-m py-xs text-right">{{ trans('settings.audit_table_date') }}</div>
+            <div class="flex-container-row justify-space-between items-center wrap">
+                <div class="flex-2 min-width-xl">{{ $activities->links() }}</div>
+                <div class="flex-none min-width-m py-m">
+                    @include('common.sort', array_merge($listOptions->getSortControlData(), ['useQuery' => true]))
                 </div>
             </div>
-            @foreach($activities as $activity)
-                <div class="item-list-row flex-container-row items-center wrap py-xxs">
-                    <div class="flex-2 px-m py-xxs flex-container-row items-center min-width-m">
-                        @include('settings.parts.table-user', ['user' => $activity->user, 'user_id' => $activity->user_id])
-                    </div>
-                    <div class="flex-2 px-m py-xxs min-width-m"><strong class="mr-xs hide-over-m">{{ trans('settings.audit_table_event') }}:</strong> {{ $activity->type }}</div>
-                    <div class="flex-3 px-m py-xxs min-width-l">
-                        @if($activity->entity)
-                            <a href="{{ $activity->entity->getUrl() }}" class="flex-container-row items-center">
-                                <span role="presentation" class="icon flex-none text-{{$activity->entity->getType()}}">@icon($activity->entity->getType())</span>
-                                <div class="flex text-{{ $activity->entity->getType() }}">
-                                    {{ $activity->entity->name }}
-                                </div>
-                            </a>
-                        @elseif($activity->detail && $activity->isForEntity())
-                            <div>
-                                {{ trans('settings.audit_deleted_item') }} <br>
-                                {{ trans('settings.audit_deleted_item_name', ['name' => $activity->detail]) }}
-                            </div>
-                        @elseif($activity->detail)
-                            <div>{{ $activity->detail }}</div>
-                        @endif
-                    </div>
+
+            <div class="item-list">
+                <div class="item-list-row flex-container-row items-center bold hide-under-m">
+                    <div class="flex-2 px-m py-xs flex-container-row items-center">{{ trans('settings.audit_table_user') }}</div>
+                    <div class="flex-2 px-m py-xs">{{ trans('settings.audit_table_event') }}</div>
+                    <div class="flex-3 px-m py-xs">{{ trans('settings.audit_table_related') }}</div>
                     <div class="flex-container-row flex-3">
-                        <div class="flex px-m py-xxs min-width-xs"><strong class="mr-xs hide-over-m">{{ trans('settings.audit_table_ip') }}:<br></strong> {{ $activity->ip }}</div>
-                        <div class="flex-2 px-m py-xxs text-m-right min-width-xs"><strong class="mr-xs hide-over-m">{{ trans('settings.audit_table_date') }}:<br></strong> {{ $activity->created_at }}</div>
+                        <div class="flex px-m py-xs">{{ trans('settings.audit_table_ip') }}</div>
+                        <div class="flex-2 px-m py-xs text-right">{{ trans('settings.audit_table_date') }}</div>
                     </div>
                 </div>
-            @endforeach
-        </div>
+                @foreach($activities as $activity)
+                    <div class="item-list-row flex-container-row items-center wrap py-xxs">
+                        <div class="flex-2 px-m py-xxs flex-container-row items-center min-width-m">
+                            @include('settings.parts.table-user', ['user' => $activity->user, 'user_id' => $activity->user_id])
+                        </div>
+                        <div class="flex-2 px-m py-xxs min-width-m"><strong
+                                    class="mr-xs hide-over-m">{{ trans('settings.audit_table_event') }}
+                                :</strong> {{ $activity->type }}</div>
+                        <div class="flex-3 px-m py-xxs min-width-l">
+                            @if($activity->entity)
+                                <a href="{{ $activity->entity->getUrl() }}" class="flex-container-row items-center">
+                                    <span role="presentation"
+                                          class="icon flex-none text-{{$activity->entity->getType()}}">@icon($activity->entity->getType())</span>
+                                    <div class="flex text-{{ $activity->entity->getType() }}">
+                                        {{ $activity->entity->name }}
+                                    </div>
+                                </a>
+                            @elseif($activity->detail && $activity->isForEntity())
+                                <div>
+                                    {{ trans('settings.audit_deleted_item') }} <br>
+                                    {{ trans('settings.audit_deleted_item_name', ['name' => $activity->detail]) }}
+                                </div>
+                            @elseif($activity->detail)
+                                <div>{{ $activity->detail }}</div>
+                            @endif
+                        </div>
+                        <div class="flex-container-row flex-3">
+                            <div class="flex px-m py-xxs min-width-xs"><strong
+                                        class="mr-xs hide-over-m">{{ trans('settings.audit_table_ip') }}
+                                    :<br></strong> {{ $activity->ip }}</div>
+                            <div class="flex-2 px-m py-xxs text-m-right min-width-xs"><strong
+                                        class="mr-xs hide-over-m">{{ trans('settings.audit_table_date') }}
+                                    :<br></strong> {{ $activity->created_at }}</div>
+                        </div>
+                    </div>
+                @endforeach
+            </div>
 
-        <div class="py-m">
-            {{ $activities->links() }}
+            <div class="py-m">
+                {{ $activities->links() }}
+            </div>
         </div>
-    </div>
 
-</div>
+    </div>
 @stop
index e60704aeb3c6aee14b85046c9b77590323fd9b82..1666cef53cd126c261c7a03cd1bf121e102d856c 100644 (file)
                     @endif
 
                     <label for="setting-registration-role">{{ trans('settings.reg_default_role') }}</label>
-                    <select id="setting-registration-role" name="setting-registration-role" @if($errors->has('setting-registration-role')) class="neg" @endif>
-                        <option value="0" @if(intval(setting('registration-role', '0')) === 0) selected @endif>-- {{ trans('common.none') }} --</option>
-                        @foreach(\BookStack\Auth\Role::all() as $role)
+                    <select id="setting-registration-role" name="setting-registration-role"
+                            @if($errors->has('setting-registration-role')) class="neg" @endif>
+                        <option value="0" @if(intval(setting('registration-role', '0')) === 0) selected @endif>
+                            -- {{ trans('common.none') }} --
+                        </option>
+                        @foreach(\BookStack\Users\Models\Role::all() as $role)
                             <option value="{{$role->id}}"
                                     data-system-role-name="{{ $role->system_name ?? '' }}"
                                     @if(intval(setting('registration-role', '0')) === $role->id) selected @endif
 
             <div class="grid half gap-xl">
                 <div>
-                    <label for="setting-registration-restrict" class="setting-list-label">{{ trans('settings.reg_confirm_restrict_domain') }}</label>
+                    <label for="setting-registration-restrict"
+                           class="setting-list-label">{{ trans('settings.reg_confirm_restrict_domain') }}</label>
                     <p class="small">{!! trans('settings.reg_confirm_restrict_domain_desc') !!}</p>
                 </div>
                 <div class="pt-xs">
-                    <input type="text" id="setting-registration-restrict" name="setting-registration-restrict" placeholder="{{ trans('settings.reg_confirm_restrict_domain_placeholder') }}" value="{{ setting('registration-restrict', '') }}">
+                    <input type="text" id="setting-registration-restrict" name="setting-registration-restrict"
+                           placeholder="{{ trans('settings.reg_confirm_restrict_domain_placeholder') }}"
+                           value="{{ setting('registration-restrict', '') }}">
                 </div>
             </div>
 
index c8592e266258494f9ac378617c90ffcf06566d9b..56929e3cee7b677e5910f7e0c32158c163e0d154 100644 (file)
@@ -48,7 +48,7 @@
         <hr class="my-s">
 
         <div class="dual-column-content toggle-switch-list">
-            @foreach(\BookStack\Actions\ActivityType::all() as $activityType)
+            @foreach(\BookStack\Activity\ActivityType::all() as $activityType)
                 <div>
                     @include('form.custom-checkbox', [
                        'name' => 'events[]',
index b6b3325e0516a15d3c9ab6aabd4ebad5afcdd739..0a853162d1d0a1f293d8e0dd8790dbc4c71abff0 100644 (file)
@@ -27,7 +27,7 @@
             @if($nameFilter)
                 <div class="my-m">
                     <strong class="mr-xs">{{ trans('common.filter_active') }}</strong>
-                    @include('entities.tag', ['tag' => new \BookStack\Actions\Tag(['name' => $nameFilter])])
+                    @include('entities.tag', ['tag' => new \BookStack\Activity\Models\Tag(['name' => $nameFilter])])
                     <form method="get" action="{{ url("/tags") }}" class="inline block">
                         @include('form.request-query-inputs', ['params' => ['search']])
                         <button class="text-button text-warn">@icon('close'){{ trans('common.filter_clear') }}</button>
index c809cdb3af11f7cd5e1aee157d21e60d323c260c..9d27414985fddb87f73c1ea593c46808bd64064e 100644 (file)
@@ -6,21 +6,21 @@
  * Controllers are all within app/Http/Controllers/Api.
  */
 
-use BookStack\Http\Controllers\Api\ApiDocsController;
-use BookStack\Http\Controllers\Api\AttachmentApiController;
-use BookStack\Http\Controllers\Api\BookApiController;
-use BookStack\Http\Controllers\Api\BookExportApiController;
-use BookStack\Http\Controllers\Api\BookshelfApiController;
-use BookStack\Http\Controllers\Api\ChapterApiController;
-use BookStack\Http\Controllers\Api\ChapterExportApiController;
-use BookStack\Http\Controllers\Api\ContentPermissionApiController;
-use BookStack\Http\Controllers\Api\ImageGalleryApiController;
-use BookStack\Http\Controllers\Api\PageApiController;
-use BookStack\Http\Controllers\Api\PageExportApiController;
-use BookStack\Http\Controllers\Api\RecycleBinApiController;
-use BookStack\Http\Controllers\Api\RoleApiController;
-use BookStack\Http\Controllers\Api\SearchApiController;
-use BookStack\Http\Controllers\Api\UserApiController;
+use BookStack\Api\ApiDocsController;
+use BookStack\Entities\Controllers\BookApiController;
+use BookStack\Entities\Controllers\BookExportApiController;
+use BookStack\Entities\Controllers\BookshelfApiController;
+use BookStack\Entities\Controllers\ChapterApiController;
+use BookStack\Entities\Controllers\ChapterExportApiController;
+use BookStack\Entities\Controllers\PageApiController;
+use BookStack\Entities\Controllers\PageExportApiController;
+use BookStack\Entities\Controllers\RecycleBinApiController;
+use BookStack\Permissions\ContentPermissionApiController;
+use BookStack\Search\SearchApiController;
+use BookStack\Uploads\Controllers\AttachmentApiController;
+use BookStack\Uploads\Controllers\ImageGalleryApiController;
+use BookStack\Users\Controllers\RoleApiController;
+use BookStack\Users\Controllers\UserApiController;
 use Illuminate\Support\Facades\Route;
 
 Route::get('docs.json', [ApiDocsController::class, 'json']);
index 937dc0c6c49e685352681bc895bd057d80e60088..5a4dbedd64c8e694d8903ad5fa239d688ba01505 100644 (file)
@@ -1,39 +1,38 @@
 <?php
 
-use BookStack\Http\Controllers\Api;
-use BookStack\Http\Controllers\AttachmentController;
-use BookStack\Http\Controllers\AuditLogController;
+use BookStack\Activity\Controllers\AuditLogController;
+use BookStack\Activity\Controllers\CommentController;
+use BookStack\Activity\Controllers\FavouriteController;
+use BookStack\Activity\Controllers\TagController;
+use BookStack\Activity\Controllers\WebhookController;
+use BookStack\Api\UserApiTokenController;
+use BookStack\Entities\Controllers\BookController;
+use BookStack\Entities\Controllers\BookExportController;
+use BookStack\Entities\Controllers\BookshelfController;
+use BookStack\Entities\Controllers\BookSortController;
+use BookStack\Entities\Controllers\ChapterController;
+use BookStack\Entities\Controllers\ChapterExportController;
+use BookStack\Entities\Controllers\PageController;
+use BookStack\Entities\Controllers\PageExportController;
+use BookStack\Entities\Controllers\PageRevisionController;
+use BookStack\Entities\Controllers\PageTemplateController;
+use BookStack\Entities\Controllers\RecycleBinController;
 use BookStack\Http\Controllers\Auth;
-use BookStack\Http\Controllers\BookController;
-use BookStack\Http\Controllers\BookExportController;
-use BookStack\Http\Controllers\BookshelfController;
-use BookStack\Http\Controllers\BookSortController;
-use BookStack\Http\Controllers\ChapterController;
-use BookStack\Http\Controllers\ChapterExportController;
-use BookStack\Http\Controllers\CommentController;
-use BookStack\Http\Controllers\FavouriteController;
 use BookStack\Http\Controllers\HomeController;
 use BookStack\Http\Controllers\Images;
-use BookStack\Http\Controllers\MaintenanceController;
-use BookStack\Http\Controllers\PageController;
-use BookStack\Http\Controllers\PageExportController;
-use BookStack\Http\Controllers\PageRevisionController;
-use BookStack\Http\Controllers\PageTemplateController;
-use BookStack\Http\Controllers\PermissionsController;
-use BookStack\Http\Controllers\RecycleBinController;
-use BookStack\Http\Controllers\ReferenceController;
-use BookStack\Http\Controllers\RoleController;
-use BookStack\Http\Controllers\SearchController;
-use BookStack\Http\Controllers\SettingController;
-use BookStack\Http\Controllers\StatusController;
-use BookStack\Http\Controllers\TagController;
-use BookStack\Http\Controllers\UserApiTokenController;
-use BookStack\Http\Controllers\UserController;
-use BookStack\Http\Controllers\UserPreferencesController;
-use BookStack\Http\Controllers\UserProfileController;
-use BookStack\Http\Controllers\UserSearchController;
-use BookStack\Http\Controllers\WebhookController;
 use BookStack\Http\Middleware\VerifyCsrfToken;
+use BookStack\Permissions\PermissionsController;
+use BookStack\References\ReferenceController;
+use BookStack\Search\SearchController;
+use BookStack\Settings\MaintenanceController;
+use BookStack\Settings\SettingController;
+use BookStack\Settings\StatusController;
+use BookStack\Uploads\Controllers\AttachmentController;
+use BookStack\Users\Controllers\RoleController;
+use BookStack\Users\Controllers\UserController;
+use BookStack\Users\Controllers\UserPreferencesController;
+use BookStack\Users\Controllers\UserProfileController;
+use BookStack\Users\Controllers\UserSearchController;
 use Illuminate\Session\Middleware\StartSession;
 use Illuminate\Support\Facades\Route;
 use Illuminate\View\Middleware\ShareErrorsFromSession;
@@ -46,12 +45,12 @@ Route::get('/favicon.ico', [HomeController::class, 'favicon']);
 Route::middleware('auth')->group(function () {
 
     // Secure images routing
-    Route::get('/uploads/images/{path}', [Images\ImageController::class, 'showImage'])
+    Route::get('/uploads/images/{path}', [\BookStack\Uploads\Controllers\ImageController::class, 'showImage'])
         ->where('path', '.*$');
 
     // API docs routes
     Route::redirect('/api', '/api/docs');
-    Route::get('/api/docs', [Api\ApiDocsController::class, 'display']);
+    Route::get('/api/docs', [\BookStack\Api\ApiDocsController::class, 'display']);
 
     Route::get('/pages/recently-updated', [PageController::class, 'showRecentlyUpdated']);
 
@@ -155,14 +154,14 @@ Route::middleware('auth')->group(function () {
     Route::get('/user/{slug}', [UserProfileController::class, 'show']);
 
     // Image routes
-    Route::get('/images/gallery', [Images\GalleryImageController::class, 'list']);
-    Route::post('/images/gallery', [Images\GalleryImageController::class, 'create']);
-    Route::get('/images/drawio', [Images\DrawioImageController::class, 'list']);
-    Route::get('/images/drawio/base64/{id}', [Images\DrawioImageController::class, 'getAsBase64']);
-    Route::post('/images/drawio', [Images\DrawioImageController::class, 'create']);
-    Route::get('/images/edit/{id}', [Images\ImageController::class, 'edit']);
-    Route::put('/images/{id}', [Images\ImageController::class, 'update']);
-    Route::delete('/images/{id}', [Images\ImageController::class, 'destroy']);
+    Route::get('/images/gallery', [\BookStack\Uploads\Controllers\GalleryImageController::class, 'list']);
+    Route::post('/images/gallery', [\BookStack\Uploads\Controllers\GalleryImageController::class, 'create']);
+    Route::get('/images/drawio', [\BookStack\Uploads\Controllers\DrawioImageController::class, 'list']);
+    Route::get('/images/drawio/base64/{id}', [\BookStack\Uploads\Controllers\DrawioImageController::class, 'getAsBase64']);
+    Route::post('/images/drawio', [\BookStack\Uploads\Controllers\DrawioImageController::class, 'create']);
+    Route::get('/images/edit/{id}', [\BookStack\Uploads\Controllers\ImageController::class, 'edit']);
+    Route::put('/images/{id}', [\BookStack\Uploads\Controllers\ImageController::class, 'update']);
+    Route::delete('/images/{id}', [\BookStack\Uploads\Controllers\ImageController::class, 'destroy']);
 
     // Attachments routes
     Route::get('/attachments/{id}', [AttachmentController::class, 'get']);
@@ -291,64 +290,64 @@ Route::middleware('auth')->group(function () {
 
 // MFA routes
 Route::middleware('mfa-setup')->group(function () {
-    Route::get('/mfa/setup', [Auth\MfaController::class, 'setup']);
-    Route::get('/mfa/totp/generate', [Auth\MfaTotpController::class, 'generate']);
-    Route::post('/mfa/totp/confirm', [Auth\MfaTotpController::class, 'confirm']);
-    Route::get('/mfa/backup_codes/generate', [Auth\MfaBackupCodesController::class, 'generate']);
-    Route::post('/mfa/backup_codes/confirm', [Auth\MfaBackupCodesController::class, 'confirm']);
+    Route::get('/mfa/setup', [\BookStack\Access\Controllers\MfaController::class, 'setup']);
+    Route::get('/mfa/totp/generate', [\BookStack\Access\Controllers\MfaTotpController::class, 'generate']);
+    Route::post('/mfa/totp/confirm', [\BookStack\Access\Controllers\MfaTotpController::class, 'confirm']);
+    Route::get('/mfa/backup_codes/generate', [\BookStack\Access\Controllers\MfaBackupCodesController::class, 'generate']);
+    Route::post('/mfa/backup_codes/confirm', [\BookStack\Access\Controllers\MfaBackupCodesController::class, 'confirm']);
 });
 Route::middleware('guest')->group(function () {
-    Route::get('/mfa/verify', [Auth\MfaController::class, 'verify']);
-    Route::post('/mfa/totp/verify', [Auth\MfaTotpController::class, 'verify']);
-    Route::post('/mfa/backup_codes/verify', [Auth\MfaBackupCodesController::class, 'verify']);
+    Route::get('/mfa/verify', [\BookStack\Access\Controllers\MfaController::class, 'verify']);
+    Route::post('/mfa/totp/verify', [\BookStack\Access\Controllers\MfaTotpController::class, 'verify']);
+    Route::post('/mfa/backup_codes/verify', [\BookStack\Access\Controllers\MfaBackupCodesController::class, 'verify']);
 });
-Route::delete('/mfa/{method}/remove', [Auth\MfaController::class, 'remove'])->middleware('auth');
+Route::delete('/mfa/{method}/remove', [\BookStack\Access\Controllers\MfaController::class, 'remove'])->middleware('auth');
 
 // Social auth routes
-Route::get('/login/service/{socialDriver}', [Auth\SocialController::class, 'login']);
-Route::get('/login/service/{socialDriver}/callback', [Auth\SocialController::class, 'callback']);
-Route::post('/login/service/{socialDriver}/detach', [Auth\SocialController::class, 'detach'])->middleware('auth');
-Route::get('/register/service/{socialDriver}', [Auth\SocialController::class, 'register']);
+Route::get('/login/service/{socialDriver}', [\BookStack\Access\Controllers\SocialController::class, 'login']);
+Route::get('/login/service/{socialDriver}/callback', [\BookStack\Access\Controllers\SocialController::class, 'callback']);
+Route::post('/login/service/{socialDriver}/detach', [\BookStack\Access\Controllers\SocialController::class, 'detach'])->middleware('auth');
+Route::get('/register/service/{socialDriver}', [\BookStack\Access\Controllers\SocialController::class, 'register']);
 
 // Login/Logout routes
-Route::get('/login', [Auth\LoginController::class, 'getLogin']);
-Route::post('/login', [Auth\LoginController::class, 'login']);
-Route::post('/logout', [Auth\LoginController::class, 'logout']);
-Route::get('/register', [Auth\RegisterController::class, 'getRegister']);
-Route::get('/register/confirm', [Auth\ConfirmEmailController::class, 'show']);
-Route::get('/register/confirm/awaiting', [Auth\ConfirmEmailController::class, 'showAwaiting']);
-Route::post('/register/confirm/resend', [Auth\ConfirmEmailController::class, 'resend']);
-Route::get('/register/confirm/{token}', [Auth\ConfirmEmailController::class, 'showAcceptForm']);
-Route::post('/register/confirm/accept', [Auth\ConfirmEmailController::class, 'confirm']);
-Route::post('/register', [Auth\RegisterController::class, 'postRegister']);
+Route::get('/login', [\BookStack\Access\Controllers\LoginController::class, 'getLogin']);
+Route::post('/login', [\BookStack\Access\Controllers\LoginController::class, 'login']);
+Route::post('/logout', [\BookStack\Access\Controllers\LoginController::class, 'logout']);
+Route::get('/register', [\BookStack\Access\Controllers\RegisterController::class, 'getRegister']);
+Route::get('/register/confirm', [\BookStack\Access\Controllers\ConfirmEmailController::class, 'show']);
+Route::get('/register/confirm/awaiting', [\BookStack\Access\Controllers\ConfirmEmailController::class, 'showAwaiting']);
+Route::post('/register/confirm/resend', [\BookStack\Access\Controllers\ConfirmEmailController::class, 'resend']);
+Route::get('/register/confirm/{token}', [\BookStack\Access\Controllers\ConfirmEmailController::class, 'showAcceptForm']);
+Route::post('/register/confirm/accept', [\BookStack\Access\Controllers\ConfirmEmailController::class, 'confirm']);
+Route::post('/register', [\BookStack\Access\Controllers\RegisterController::class, 'postRegister']);
 
 // SAML routes
-Route::post('/saml2/login', [Auth\Saml2Controller::class, 'login']);
-Route::post('/saml2/logout', [Auth\Saml2Controller::class, 'logout']);
-Route::get('/saml2/metadata', [Auth\Saml2Controller::class, 'metadata']);
-Route::get('/saml2/sls', [Auth\Saml2Controller::class, 'sls']);
-Route::post('/saml2/acs', [Auth\Saml2Controller::class, 'startAcs'])->withoutMiddleware([
+Route::post('/saml2/login', [\BookStack\Access\Controllers\Saml2Controller::class, 'login']);
+Route::post('/saml2/logout', [\BookStack\Access\Controllers\Saml2Controller::class, 'logout']);
+Route::get('/saml2/metadata', [\BookStack\Access\Controllers\Saml2Controller::class, 'metadata']);
+Route::get('/saml2/sls', [\BookStack\Access\Controllers\Saml2Controller::class, 'sls']);
+Route::post('/saml2/acs', [\BookStack\Access\Controllers\Saml2Controller::class, 'startAcs'])->withoutMiddleware([
     StartSession::class,
     ShareErrorsFromSession::class,
     VerifyCsrfToken::class,
 ]);
-Route::get('/saml2/acs', [Auth\Saml2Controller::class, 'processAcs']);
+Route::get('/saml2/acs', [\BookStack\Access\Controllers\Saml2Controller::class, 'processAcs']);
 
 // OIDC routes
-Route::post('/oidc/login', [Auth\OidcController::class, 'login']);
-Route::get('/oidc/callback', [Auth\OidcController::class, 'callback']);
+Route::post('/oidc/login', [\BookStack\Access\Controllers\OidcController::class, 'login']);
+Route::get('/oidc/callback', [\BookStack\Access\Controllers\OidcController::class, 'callback']);
 
 // User invitation routes
-Route::get('/register/invite/{token}', [Auth\UserInviteController::class, 'showSetPassword']);
-Route::post('/register/invite/{token}', [Auth\UserInviteController::class, 'setPassword']);
+Route::get('/register/invite/{token}', [\BookStack\Access\Controllers\UserInviteController::class, 'showSetPassword']);
+Route::post('/register/invite/{token}', [\BookStack\Access\Controllers\UserInviteController::class, 'setPassword']);
 
 // Password reset link request routes
-Route::get('/password/email', [Auth\ForgotPasswordController::class, 'showLinkRequestForm']);
-Route::post('/password/email', [Auth\ForgotPasswordController::class, 'sendResetLinkEmail']);
+Route::get('/password/email', [\BookStack\Access\Controllers\ForgotPasswordController::class, 'showLinkRequestForm']);
+Route::post('/password/email', [\BookStack\Access\Controllers\ForgotPasswordController::class, 'sendResetLinkEmail']);
 
 // Password reset routes
-Route::get('/password/reset/{token}', [Auth\ResetPasswordController::class, 'showResetForm']);
-Route::post('/password/reset', [Auth\ResetPasswordController::class, 'reset']);
+Route::get('/password/reset/{token}', [\BookStack\Access\Controllers\ResetPasswordController::class, 'showResetForm']);
+Route::post('/password/reset', [\BookStack\Access\Controllers\ResetPasswordController::class, 'reset']);
 
 // Metadata routes
 Route::view('/help/wysiwyg', 'help.wysiwyg');
index 52b45e71212f9d90d4bf2f4de1cba6373b56394c..5e355ca096b81914de60a0b2f3aff7859d195b90 100644 (file)
@@ -2,12 +2,12 @@
 
 namespace Tests\Actions;
 
-use BookStack\Actions\Activity;
-use BookStack\Actions\ActivityLogger;
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\UserRepo;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Activity;
+use BookStack\Activity\Tools\ActivityLogger;
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Entities\Tools\TrashCan;
+use BookStack\Users\UserRepo;
 use Carbon\Carbon;
 use Tests\TestCase;
 
index 078b8bdf4beda6a6134e5ff7d673fa8a9de8cd0e..f2def087b0c1b13b7860847f51e968e838ba1609 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests\Actions;
 
-use BookStack\Actions\ActivityLogger;
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\DispatchWebhookJob;
-use BookStack\Actions\Webhook;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\DispatchWebhookJob;
+use BookStack\Activity\Models\Webhook;
+use BookStack\Activity\Tools\ActivityLogger;
+use BookStack\Users\Models\User;
 use Illuminate\Http\Client\Request;
 use Illuminate\Support\Facades\Bus;
 use Illuminate\Support\Facades\Http;
index be67d4d522f63184d779808a5b532e94609fec13..b4fa49532c44f1c2f592588532b4fd645ce3cfb7 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Actions;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Webhook;
-use BookStack\Actions\WebhookFormatter;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Webhook;
+use BookStack\Activity\Tools\WebhookFormatter;
 use Illuminate\Support\Arr;
 use Tests\TestCase;
 
index 52838becab883fe2c24b0fecf9ce7383539b8433..05475b6997c01bf371082eb9769a2cad72445401 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Actions;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Webhook;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Webhook;
 use Tests\TestCase;
 
 class WebhookManagementTest extends TestCase
index 038c4e06717564e59c6212a62b1cc6e85d744e00..93e4b02e423178a514a2ab9fe9b2c52a6eaa474f 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Api;
 
-use BookStack\Auth\Permissions\RolePermission;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Permissions\Models\RolePermission;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Carbon\Carbon;
 use Tests\TestCase;
 
index 515dabe68ff60b0adbd30948841f5adfa10db129..d6ba22ab637896e2f1d29625d46b50441461dae6 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Api;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class RolesApiTest extends TestCase
index c566fd8de337fc2401ad796f5eeab483a5ca5e7c..466acbffbe0b207f77882649ad56bb70a997e3b2 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Api;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 
 trait TestsApi
 {
index fadd2610c9b99581663276181541a319fe71c8d8..6af9c2a7a53b8f7ac453c50c2098d4258a1355c3 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests\Api;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Entity;
 use BookStack\Notifications\UserInvite;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Hash;
 use Illuminate\Support\Facades\Notification;
 use Tests\TestCase;
index fe7e62568cf8d8124b67913e6110e1089d7ecdfe..0164978d85d7d44ba18c021802d4526ba73bb156 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Access\Mfa\MfaSession;
+use BookStack\Access\Mfa\MfaSession;
 use Illuminate\Testing\TestResponse;
 use Tests\TestCase;
 
index dbf4110d8719ce918b4a2f7cb049dfe8ffe8ab8b..fee2ae40686d9763b91a80974544ba251b6f8bdd 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Access\GroupSyncService;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Access\GroupSyncService;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class GroupSyncServiceTest extends TestCase
index cac2ea5e10f1f11a07fb764f7c1fc89be074319d..97a91aba78b4d0ecaa6c245873ada1eb1ae3fcfb 100644 (file)
@@ -2,10 +2,10 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Access\Ldap;
-use BookStack\Auth\Access\LdapService;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Access\Ldap;
+use BookStack\Access\LdapService;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Testing\TestResponse;
 use Mockery\MockInterface;
 use Tests\TestCase;
index fb941f00b7d384f1c3ebae8075a8d877bf7774de..1f359b41a103622ea2e807871ed2b84539f84713 100644 (file)
@@ -2,10 +2,10 @@
 
 namespace Tests\Auth;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\Mfa\MfaValue;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Activity\ActivityType;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use PragmaRX\Google2FA\Google2FA;
 use Tests\TestCase;
 
index e23250314907a1fbd81706ab91823888a1439c49..2fa272e331cd6bd5e56ee7a170456e566231fd25 100644 (file)
@@ -2,12 +2,12 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Access\LoginService;
-use BookStack\Auth\Access\Mfa\MfaValue;
-use BookStack\Auth\Access\Mfa\TotpService;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Access\LoginService;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Access\Mfa\TotpService;
 use BookStack\Exceptions\StoppedAuthenticationException;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Hash;
 use PragmaRX\Google2FA\Google2FA;
 use Tests\TestCase;
index 41727e7b71d7223a00af51f03f0735334875ab35..191a25f8801e732a75a3df5d46d4c19de8389756 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests\Auth;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
 use BookStack\Facades\Theme;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use GuzzleHttp\Psr7\Request;
 use GuzzleHttp\Psr7\Response;
 use Illuminate\Testing\TestResponse;
index 5c3aab6a8ba2cdb0e7a9a33f09a18f4118043f24..bc190afd81f6a6dbfb2b50af92ef5b599c1feecc 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Notifications\ConfirmEmail;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\DB;
 use Illuminate\Support\Facades\Notification;
 use Tests\TestCase;
index 72e26f10ceb54269b53fb3b2ff410fb29be1bc4e..b97a2f2d380fb3b1b72eb69dbaa76b6f3767d621 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\User;
 use BookStack\Notifications\ResetPassword;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Notification;
 use Tests\TestCase;
 
index 1a3e4abbec35000112322c154642752ec103d5f8..801682a003c2a80722efc33d39485a34ca925b23 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class Saml2Test extends TestCase
index 24deedd5f349cc38234b1ce9d105bb2326b8b2c3..5b7071a0779e2c60dd4d99d839e0c00c45d21da8 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Auth;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\SocialAccount;
-use BookStack\Auth\User;
+use BookStack\Access\SocialAccount;
+use BookStack\Activity\ActivityType;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\DB;
 use Laravel\Socialite\Contracts\Factory;
 use Laravel\Socialite\Contracts\Provider;
index e82ce46387661c5f5098bc9ab9d1069e8ffd4edd..7488ac776d43798c8f50a79064ae98e09e1d6d56 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Auth;
 
-use BookStack\Auth\Access\UserInviteService;
-use BookStack\Auth\User;
+use BookStack\Access\UserInviteService;
 use BookStack\Notifications\UserInvite;
+use BookStack\Users\Models\User;
 use Carbon\Carbon;
 use Illuminate\Notifications\Messages\MailMessage;
 use Illuminate\Support\Facades\DB;
index b2624e23df285ca133ed72c6abee140ca4a93ca8..410a39aa870e60209c0712e4826122dd9c42890d 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Commands;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Facades\Activity;
 use Illuminate\Support\Facades\Artisan;
 use Illuminate\Support\Facades\DB;
index 1d8915b3a25d8dca103a9ee64f4b8eae317f6c82..95a39c497e487f99e572c321b57cc5b8e50d777f 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Commands;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Auth;
 use Tests\TestCase;
 
index 08f137777d191af0601e83cbd5e0a011eb06be1e..4940d66c3436478acb655269889bed5b59d43723 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Commands;
 
-use BookStack\Actions\Comment;
+use BookStack\Activity\Models\Comment;
 use Tests\TestCase;
 
 class RegenerateCommentContentCommandTest extends TestCase
index 9cf7dec93d6ae54bd4a5c6ae281fa7abb268cc62..75c6c1b3851e634635c7ed30087fda73964f73d8 100644 (file)
@@ -3,8 +3,7 @@
 namespace Tests\Commands;
 
 use BookStack\Auth\Permissions\CollapsedPermission;
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Permissions\JointPermission;
+use BookStack\Permissions\Models\JointPermission;
 use Illuminate\Support\Facades\Artisan;
 use Illuminate\Support\Facades\DB;
 use Tests\TestCase;
index e65a048ef92887c500a9c8be7149cbb8036b9ccb..85f8f6430a769e77ee9e18ef5ac009526e6ca3d0 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Commands;
 
-use BookStack\Auth\Access\Mfa\MfaValue;
-use BookStack\Auth\User;
+use BookStack\Access\Mfa\MfaValue;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class ResetMfaCommandTest extends TestCase
index ec66de10a505e3f768e4e52a26ceb4be6a9143aa..43de9f175e93065759126da12b68a513114e2fac 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests;
 
-use BookStack\Auth\Access\SocialAuthService;
+use BookStack\Access\SocialAuthService;
 use Illuminate\Testing\TestResponse;
 
 class DebugViewTest extends TestCase
index 2e7d41d643aaf4fa0ff33a96547e6a200870d523..a10a56e9ef338355a8434069e48705fb2e256453 100644 (file)
@@ -2,10 +2,10 @@
 
 namespace Tests\Entity;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Uploads\Image;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Str;
 use Tests\TestCase;
 
index 99e3525a0b977bd076b34bfdaea06e0436793388..1159df79d187ffcaddda330a391f9c58bc3d9d35 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Entity;
 
-use BookStack\Actions\Comment;
+use BookStack\Activity\Models\Comment;
 use BookStack\Entities\Models\Page;
 use Tests\TestCase;
 
index 4beec7fa61dfbfa92d7391499f385cf6b15c10b8..decda52243f7d39d4169a5b0d4fb2a13e08dc726 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Entity;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Tag;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
index ab7587a3b273e3bdd06c7f0e4e4567fa6c9cddc5..2b7e5d5ddac483efd7b863d0601a1ac01cd081dc 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Entity;
 
-use BookStack\Auth\UserRepo;
 use BookStack\Entities\Models\Entity;
+use BookStack\Users\UserRepo;
 use Tests\TestCase;
 
 class EntityAccessTest extends TestCase
index 170269941a2fb35a6d079e170088ff7ca5e69f48..af06ae72af9042d2e9025b3d11ff8cd78f4c6d1e 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Entity;
 
-use BookStack\Actions\Tag;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use Tests\TestCase;
index 6ae8dcde313f27444bfbf3783920913ca4c6946c..2b5244bf010510dde94191ac8dc21c87465218cb 100644 (file)
@@ -2,7 +2,6 @@
 
 namespace Tests\Entity;
 
-use BookStack\Auth\Role;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Page;
index 0df37728e19de8ac220b889a9ea437b12fb09d4c..97d5a6664daef838a9095dbdbeeea242e86ea1a6 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Entity;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Entities\Models\Page;
 use Tests\TestCase;
 
index 7e667495908d2dbf62e862a77952533841c5d056..c1240e955387ee9c037fa78424eed3f48e0754f5 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Entity;
 
-use BookStack\Actions\Tag;
+use BookStack\Activity\Models\Tag;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
 use Tests\TestCase;
index 7778aa8e93584ad5e09dab15b6a0c2d86eac15fc..0e30cbd58cadc608e5150cc47207dbffb606f8ee 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests;
 
-use BookStack\Actions\Favourite;
-use BookStack\Auth\User;
+use BookStack\Activity\Models\Favourite;
+use BookStack\Users\Models\User;
 
 class FavouriteTest extends TestCase
 {
index 8b045db54a2f13eaf312e01e8074788bc41dfae8..ddc854290b17c5a1384561aaf96ed0ccddefe347 100644 (file)
@@ -2,7 +2,6 @@
 
 namespace Tests\Helpers;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
@@ -12,6 +11,7 @@ use BookStack\Entities\Repos\BookRepo;
 use BookStack\Entities\Repos\BookshelfRepo;
 use BookStack\Entities\Repos\ChapterRepo;
 use BookStack\Entities\Repos\PageRepo;
+use BookStack\Users\Models\User;
 use Illuminate\Database\Eloquent\Builder;
 
 /**
index b93c45e25e00c9d44a0df7d1a7279b6ba7837ac9..512f43fb6cc14bb4e854ad9487fcb3abc526b6b4 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests\Helpers;
 
-use BookStack\Auth\Permissions\EntityPermission;
-use BookStack\Auth\Permissions\RolePermission;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Entity;
+use BookStack\Permissions\Models\EntityPermission;
+use BookStack\Permissions\Models\RolePermission;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 
 class PermissionsProvider
 {
index 8c2718bc3e2831ef37663df41d7641a3c2ac3d2f..b86e9039407006d922029c06e0058efb91a88f5b 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Helpers;
 
-use BookStack\Auth\Permissions\PermissionsRepo;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Permissions\PermissionsRepo;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 
 class UserRoleProvider
 {
index c7e8b69bb2c8df3e83fba52381e09994e410d6dd..eb552b2e2095700e8054c9679746620f8cd935d3 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 
 class HomepageTest extends TestCase
 {
index e94759760ce90fd7306314e3fffcb5a8c2996300..f002549220b58558b14b1bfcf0db0f11bc6c22a0 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Permissions;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class EntityOwnerChangeTest extends TestCase
index 99a8bd88c1dd26fa75bf281ac22d303146f6deda..3c4bf4a77311fa4d7b925f5db740b484795d641e 100644 (file)
@@ -2,13 +2,13 @@
 
 namespace Tests\Permissions;
 
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Exception;
 use Illuminate\Support\Str;
 use Tests\TestCase;
index 971479e28aee66d8ed31a33e7c24a71b963d330e..dafa1f2bb10de8ae8031815e8f87498c6f6404db 100644 (file)
@@ -2,16 +2,16 @@
 
 namespace Tests\Permissions;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\Comment;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\Models\Comment;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Bookshelf;
 use BookStack\Entities\Models\Chapter;
 use BookStack\Entities\Models\Entity;
 use BookStack\Entities\Models\Page;
 use BookStack\Uploads\Image;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Testing\TestResponse;
 use Tests\TestCase;
 
index 5352f468a9db211e9a18aa71d3221e2d29fc6f4d..2299fe8787bd26d39857545ab657312d1a688024 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Permissions\Scenarios;
 
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Entity;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 // Cases defined in dev/docs/permission-scenario-testing.md
index e21afdf3322df7f9acc09eb7e997917cf2384d94..97299f7570b5c21fb5149d5edca59acb8df50ac0 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests;
 
-use BookStack\Auth\Permissions\RolePermission;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Chapter;
+use BookStack\Permissions\Models\RolePermission;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Auth;
 use Illuminate\Support\Facades\View;
 
index 4330598baf6378a54ea7cab7b41759b00b955482..a19e1b9015709d6fd8443d6fb83c3c677fc60006 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\References;
 
+use BookStack\App\Model;
 use BookStack\Entities\Repos\PageRepo;
 use BookStack\Entities\Tools\TrashCan;
-use BookStack\Model;
 use BookStack\References\Reference;
 use Tests\TestCase;
 
index 239f50e765f6d4974d7f8d5540749a8dc9067e1e..25832b03e58837f8d813ff4e7ff261eef348d3ef 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Settings;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\References\ReferenceStore;
 use Tests\TestCase;
 
index bc8163056f345bf1dbf25da6a526bf6aafbb9662..6976f23847cf136f257ad9735fa8540cd2ea86eb 100644 (file)
@@ -2,15 +2,15 @@
 
 namespace Tests;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Actions\DispatchWebhookJob;
-use BookStack\Actions\Webhook;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Activity\DispatchWebhookJob;
+use BookStack\Activity\Models\Webhook;
 use BookStack\Entities\Models\Book;
 use BookStack\Entities\Models\Page;
 use BookStack\Entities\Tools\PageContent;
 use BookStack\Facades\Theme;
 use BookStack\Theming\ThemeEvents;
+use BookStack\Users\Models\User;
 use Illuminate\Console\Command;
 use Illuminate\Http\Client\Request as HttpClientRequest;
 use Illuminate\Http\Request;
index 928b1ab10095b2c7ff79b026f69f07fc064dba60..14878257570949cd44afc02fe3d8cf229cb2f0d5 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\Unit;
 
-use BookStack\Actions\IpFormatter;
+use BookStack\Activity\Tools\IpFormatter;
 use Tests\TestCase;
 
 class IpFormatterTest extends TestCase
index ad91eecd8b26e5b7de232b7e948900c2854ad9d6..6302f84c75f93be10f51f74a69dfb4758f0f3ce7 100644 (file)
@@ -2,8 +2,8 @@
 
 namespace Tests\Unit;
 
-use BookStack\Auth\Access\Oidc\OidcIdToken;
-use BookStack\Auth\Access\Oidc\OidcInvalidTokenException;
+use BookStack\Access\Oidc\OidcIdToken;
+use BookStack\Access\Oidc\OidcInvalidTokenException;
 use Tests\Helpers\OidcJwtHelper;
 use Tests\TestCase;
 
index 57f28db429238e203ca8416a65ea8dd03a15b9b8..2217cd2bafffa28a79e36c86e2a37a557b7e6ed5 100644 (file)
@@ -2,9 +2,9 @@
 
 namespace Tests\Uploads;
 
-use BookStack\Auth\User;
 use BookStack\Exceptions\HttpFetchException;
 use BookStack\Uploads\HttpFetcher;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class AvatarTest extends TestCase
index 93070b712188e325f0ddc94a3653d600394702c5..75de49aed9a25342bacb956b1f851cb4070a614b 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\User;
 
-use BookStack\Actions\ActivityType;
+use BookStack\Activity\ActivityType;
 use BookStack\Api\ApiToken;
 use Carbon\Carbon;
 use Tests\TestCase;
index 7ccc5b773a7e88a120c4ee214a11c5c44fa44ea1..df60bede6e1de83d83720ad5ed2608f7a524a9ce 100644 (file)
@@ -2,11 +2,11 @@
 
 namespace Tests\User;
 
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\Access\UserInviteService;
-use BookStack\Auth\Role;
-use BookStack\Auth\User;
+use BookStack\Access\UserInviteService;
+use BookStack\Activity\ActivityType;
 use BookStack\Uploads\Image;
+use BookStack\Users\Models\Role;
+use BookStack\Users\Models\User;
 use Illuminate\Support\Facades\Hash;
 use Illuminate\Support\Str;
 use Mockery\MockInterface;
index c507e8fa63a98d96329e1fad0d435b5021ec32b0..4bfb3c87822a5085fbb0f8c7a862c6177b5821c6 100644 (file)
@@ -3,8 +3,8 @@
 namespace Tests\User;
 
 use Activity;
-use BookStack\Actions\ActivityType;
-use BookStack\Auth\User;
+use BookStack\Activity\ActivityType;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class UserProfileTest extends TestCase
index 1b3ca8a35148e8bd22e3631857663fa4fc5298e6..1387311ce7576d131e6b648197deedf5d9d69612 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace Tests\User;
 
-use BookStack\Auth\User;
+use BookStack\Users\Models\User;
 use Tests\TestCase;
 
 class UserSearchTest extends TestCase