xref: /webtrees/app/Http/Routes/WebRoutes.php (revision 8ce3bd7317ecf32f7aa634676ce35ec9b0055a39)
12279b4f3SGreg Roach<?php
22279b4f3SGreg Roach
32279b4f3SGreg Roach/**
42279b4f3SGreg Roach * webtrees: online genealogy
52279b4f3SGreg Roach * Copyright (C) 2019 webtrees development team
62279b4f3SGreg Roach * This program is free software: you can redistribute it and/or modify
72279b4f3SGreg Roach * it under the terms of the GNU General Public License as published by
82279b4f3SGreg Roach * the Free Software Foundation, either version 3 of the License, or
92279b4f3SGreg Roach * (at your option) any later version.
102279b4f3SGreg Roach * This program is distributed in the hope that it will be useful,
112279b4f3SGreg Roach * but WITHOUT ANY WARRANTY; without even the implied warranty of
122279b4f3SGreg Roach * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
132279b4f3SGreg Roach * GNU General Public License for more details.
142279b4f3SGreg Roach * You should have received a copy of the GNU General Public License
152279b4f3SGreg Roach * along with this program. If not, see <http://www.gnu.org/licenses/>.
162279b4f3SGreg Roach */
172279b4f3SGreg Roach
182279b4f3SGreg Roachdeclare(strict_types=1);
192279b4f3SGreg Roach
202279b4f3SGreg Roachnamespace Fisharebest\Webtrees\Http\Routes;
212279b4f3SGreg Roach
222279b4f3SGreg Roachuse Aura\Router\Map;
232279b4f3SGreg Roachuse Fig\Http\Message\RequestMethodInterface;
242279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\Middleware\AuthAdministrator;
252279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\Middleware\AuthEditor;
262279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\Middleware\AuthLoggedIn;
272279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\Middleware\AuthManager;
282279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\Middleware\AuthModerator;
292279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AccountDelete;
302279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AccountEdit;
312279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AccountUpdate;
327c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddChildToFamilyAction;
337c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddChildToFamilyPage;
347c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddChildToIndividualAction;
357c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddChildToIndividualPage;
367c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddName;
372279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddNewFact;
387c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddParentToIndividualAction;
397c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddParentToIndividualPage;
407c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToFamilyAction;
417c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToFamilyPage;
427c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToIndividualAction;
437c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddSpouseToIndividualPage;
447c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddUnlinkedAction;
457c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AddUnlinkedPage;
466577bfc3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AdminMediaFileDownload;
476577bfc3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AdminMediaFileThumbnail;
4846431a62SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AppleTouchIconPng;
4963763244SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AutoCompleteCitation;
5063763244SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AutoCompleteFolder;
5163763244SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AutoCompletePlace;
5263763244SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\AutoCompleteSurname;
53e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\BroadcastAction;
54e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\BroadcastPage;
55b00cb080SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CalendarAction;
56b00cb080SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CalendarEvents;
57b00cb080SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CalendarPage;
5843322877SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ChangeFamilyMembersAction;
5943322877SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ChangeFamilyMembersPage;
606fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CheckTree;
612279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CleanDataFolder;
62e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ContactAction;
63e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ContactPage;
642279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
652279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CopyFact;
662279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateMediaObjectAction;
672279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateMediaObjectModal;
682279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateNoteAction;
692279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateNoteModal;
702279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateRepositoryAction;
712279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateRepositoryModal;
722279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateSourceAction;
732279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateSourceModal;
742279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateSubmitterAction;
752279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateSubmitterModal;
762279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateTreeAction;
772279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\CreateTreePage;
78ce42304aSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixChoose;
7955749c76SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixData;
8055749c76SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixPage;
81ce42304aSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixPreview;
82ce42304aSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixSelect;
8355749c76SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixUpdate;
8455749c76SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DataFixUpdateAll;
852279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DeleteFact;
862279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DeletePath;
872279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DeleteRecord;
882279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DeleteTreeAction;
892279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\DeleteUser;
9055749c76SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditFactAction;
91a53fee79SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditFactPage;
927c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditName;
932279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditRawFactAction;
942279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditRawFactPage;
952279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditRawRecordAction;
962279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EditRawRecordPage;
97901ade19SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EmailPreferencesAction;
98901ade19SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\EmailPreferencesPage;
996d576906SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ExportGedcomClient;
1006d576906SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ExportGedcomPage;
1016d576906SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ExportGedcomServer;
1022279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\FamilyPage;
10346431a62SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\FaviconIco;
1046fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\FindDuplicateRecords;
1056fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\GedcomLoad;
1062279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\GedcomRecordPage;
1071635452cSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\HeaderPage;
1082279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\HelpText;
1092279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\HomePage;
1106fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ImportGedcomAction;
1116fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ImportGedcomPage;
1122279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\IndividualPage;
1137c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LinkChildToFamilyAction;
1147c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LinkChildToFamilyPage;
1157c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LinkSpouseToIndividualAction;
1167c7d1e03SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LinkSpouseToIndividualPage;
1172279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LoginAction;
1182279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\LoginPage;
1192279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Logout;
120*8ce3bd73SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ManageMediaAction;
121*8ce3bd73SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ManageMediaData;
122*8ce3bd73SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ManageMediaPage;
1236fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ManageTrees;
12494e35917SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MapDataDelete;
12594e35917SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MapDataList;
126040e7dbaSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Masquerade;
12746b03695SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MediaFileDownload;
12846b03695SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MediaFileThumbnail;
1292279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MediaPage;
1305bbfbb82SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeFactsAction;
1315bbfbb82SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeFactsPage;
1325bbfbb82SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeRecordsAction;
1335bbfbb82SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeRecordsPage;
1346fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeTreesAction;
1356fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MergeTreesPage;
136e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MessageAction;
137e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MessagePage;
138e381f98dSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\MessageSelect;
1392279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModuleAction;
1409f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModuleDeleteSettings;
1416fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesAllAction;
1426fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesAllPage;
1439f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesAnalyticsAction;
1449f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesAnalyticsPage;
1459f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesBlocksAction;
1469f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesBlocksPage;
1479f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesChartsAction;
1489f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesChartsPage;
1499f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesDataFixesAction;
1509f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesDataFixesPage;
1519f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesFootersAction;
1529f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesFootersPage;
1539f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesHistoricEventsAction;
1549f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesHistoricEventsPage;
1559f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesLanguagesAction;
1569f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesLanguagesPage;
1579f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesListsAction;
1589f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesListsPage;
1599f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesMenusAction;
1609f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesMenusPage;
1619f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesReportsAction;
1629f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesReportsPage;
1639f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesSidebarsAction;
1649f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesSidebarsPage;
1659f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesTabsAction;
1669f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesTabsPage;
1679f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesThemesAction;
1689f667ff2SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ModulesThemesPage;
1692279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\NotePage;
1702279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PasswordRequestAction;
1712279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PasswordRequestPage;
1722279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PasswordResetAction;
1732279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PasswordResetPage;
1742279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PasteFact;
1752279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChanges;
1762279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptChange;
1772279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptRecord;
1782279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesAcceptTree;
1792279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesLogAction;
1802279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesLogData;
1812279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesLogDelete;
1822279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesLogDownload;
1832279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesLogPage;
1842279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectChange;
1852279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectRecord;
1862279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PendingChangesRejectTree;
1872279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\PhpInformation;
1882279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Ping;
1892279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RegisterAction;
1902279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RegisterPage;
1916fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RenumberTreeAction;
1926fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RenumberTreePage;
1932279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderChildrenAction;
1942279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderChildrenPage;
195901ade19SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderFamiliesAction;
196901ade19SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderFamiliesPage;
1972279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderMediaAction;
1982279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderMediaPage;
1992279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderNamesAction;
2002279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReorderNamesPage;
2012279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReportGenerate;
2022279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReportListAction;
2032279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReportListPage;
2042279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReportSetupAction;
2052279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ReportSetupPage;
2062279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RepositoryPage;
2072279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\RobotsTxt;
2082279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchAdvancedAction;
2092279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchAdvancedPage;
2102279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchGeneralAction;
2112279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchGeneralPage;
2122279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchPhoneticAction;
2132279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchPhoneticPage;
2142279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchQuickAction;
2152279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchReplaceAction;
2162279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SearchReplacePage;
2172279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Family;
2182279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Individual;
2192279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2MediaObject;
2202279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Note;
221a60f9d1cSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Place;
2222279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Repository;
2232279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Source;
2242279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\Select2Submitter;
2252279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SelectDefaultTree;
2262279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SelectLanguage;
2272279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SelectNewFact;
2282279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SelectTheme;
2292279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteLogsAction;
2302279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteLogsData;
2312279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteLogsDelete;
2322279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteLogsDownload;
2332279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteLogsPage;
234c7aa856bSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SitePreferencesAction;
235c7aa856bSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SitePreferencesPage;
236c7aa856bSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteRegistrationAction;
237c7aa856bSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SiteRegistrationPage;
2382279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SourcePage;
2391635452cSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SubmissionPage;
240ffc0a61fSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SubmitterPage;
2416fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\SynchronizeTrees;
2428e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePage;
2438e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageBlock;
2448e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageBlockEdit;
2458e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageBlockUpdate;
2468e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageDefaultEdit;
2478e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageDefaultUpdate;
2488e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageEdit;
2498e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePageUpdate;
2506fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePreferencesAction;
2516fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePreferencesPage;
2526fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePrivacyAction;
2536fd01894SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\TreePrivacyPage;
25496716c47SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UnconnectedAction;
25596716c47SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UnconnectedPage;
256*8ce3bd73SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UploadMediaAction;
257*8ce3bd73SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UploadMediaPage;
2588e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPage;
2598e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageBlock;
2608e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageBlockEdit;
2618e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageBlockUpdate;
2628e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageDefaultEdit;
2638e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageDefaultUpdate;
2648e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageEdit;
2658e0e1b25SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UserPageUpdate;
2662474349cSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UsersCleanupAction;
2672474349cSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\UsersCleanupPage;
2682279b4f3SGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\VerifyEmail;
2692279b4f3SGreg Roach
2702279b4f3SGreg Roach/**
2712279b4f3SGreg Roach * Routing table for web requests
2722279b4f3SGreg Roach */
2732279b4f3SGreg Roachclass WebRoutes
2742279b4f3SGreg Roach{
2752279b4f3SGreg Roach    public function load(Map $router): void
2762279b4f3SGreg Roach    {
277901ade19SGreg Roach        $router->attach('', '', static function (Map $router) {
2782279b4f3SGreg Roach            // Admin routes.
2792279b4f3SGreg Roach            $router->attach('', '/admin', static function (Map $router) {
2802279b4f3SGreg Roach                $router->extras([
281901ade19SGreg Roach                    'middleware' => [
282901ade19SGreg Roach                        AuthAdministrator::class,
283901ade19SGreg Roach                    ],
2842279b4f3SGreg Roach                ]);
2852279b4f3SGreg Roach
286451d4d87SGreg Roach                $router->get(ControlPanel::class, '');
287451d4d87SGreg Roach                $router->get(BroadcastPage::class, '/broadcast');
288451d4d87SGreg Roach                $router->post(BroadcastAction::class, '/broadcast');
289451d4d87SGreg Roach                $router->get(CleanDataFolder::class, '/clean');
290451d4d87SGreg Roach                $router->post(DeletePath::class, '/delete-path');
291451d4d87SGreg Roach                $router->get(EmailPreferencesPage::class, '/email');
292451d4d87SGreg Roach                $router->post(EmailPreferencesAction::class, '/email');
293451d4d87SGreg Roach                $router->get(PhpInformation::class, '/information');
294451d4d87SGreg Roach                $router->get(SiteLogsPage::class, '/logs');
295451d4d87SGreg Roach                $router->post(SiteLogsAction::class, '/logs');
296451d4d87SGreg Roach                $router->get(SiteLogsData::class, '/logs-data');
297451d4d87SGreg Roach                $router->post(SiteLogsDelete::class, '/logs-delete');
298451d4d87SGreg Roach                $router->get(SiteLogsDownload::class, '/logs-download');
299451d4d87SGreg Roach                $router->post(Masquerade::class, '/masquerade/{user_id}');
300*8ce3bd73SGreg Roach                $router->get(ManageMediaPage::class, '/media', ManageMediaPage::class);
301*8ce3bd73SGreg Roach                $router->post(ManageMediaAction::class, '/media', ManageMediaAction::class);
302*8ce3bd73SGreg Roach                $router->get(ManageMediaData::class, '/media-data', ManageMediaData::class);
303*8ce3bd73SGreg Roach                $router->get(UploadMediaPage::class, '/media-upload', UploadMediaPage::class);
304*8ce3bd73SGreg Roach                $router->post(UploadMediaAction::class, '/media-upload', UploadMediaAction::class);
30510a93a5fSGreg Roach                $router->get(AdminMediaFileDownload::class, '/media-file');
30610a93a5fSGreg Roach                $router->get(AdminMediaFileThumbnail::class, '/media-thumbnail');
307451d4d87SGreg Roach                $router->get(CreateTreePage::class, '/trees/create');
308451d4d87SGreg Roach                $router->post(CreateTreeAction::class, '/trees/create');
309451d4d87SGreg Roach                $router->post(SelectDefaultTree::class, '/trees/default/{tree}');
310451d4d87SGreg Roach                $router->post(DeleteTreeAction::class, '/trees/delete/{tree}');
3112279b4f3SGreg Roach                $router->get('admin-fix-level-0-media', '/fix-level-0-media', 'Admin\FixLevel0MediaController::fixLevel0Media');
3122279b4f3SGreg Roach                $router->post('admin-fix-level-0-media-action', '/fix-level-0-media', 'Admin\FixLevel0MediaController::fixLevel0MediaAction');
3132279b4f3SGreg Roach                $router->get('admin-fix-level-0-media-data', '/fix-level-0-media-data', 'Admin\FixLevel0MediaController::fixLevel0MediaData');
3142279b4f3SGreg Roach                $router->get('admin-webtrees1-thumbs', '/webtrees1-thumbs', 'Admin\ImportThumbnailsController::webtrees1Thumbnails');
3152279b4f3SGreg Roach                $router->post('admin-webtrees1-thumbs-action', '/webtrees1-thumbs', 'Admin\ImportThumbnailsController::webtrees1ThumbnailsAction');
3162279b4f3SGreg Roach                $router->get('admin-webtrees1-thumbs-data', '/webtrees1-thumbs-data', 'Admin\ImportThumbnailsController::webtrees1ThumbnailsData');
317451d4d87SGreg Roach                $router->get(UsersCleanupPage::class, '/users-cleanup');
318451d4d87SGreg Roach                $router->post(UsersCleanupAction::class, '/users-cleanup');
319451d4d87SGreg Roach                $router->get(MapDataList::class, '/map-data');
3202279b4f3SGreg Roach                $router->get('map-data-edit', '/map-data-edit', 'Admin\LocationController::mapDataEdit');
3212279b4f3SGreg Roach                $router->post('map-data-update', '/map-data-edit', 'Admin\LocationController::mapDataSave');
322451d4d87SGreg Roach                $router->post(MapDataDelete::class, '/map-data-delete');
3232279b4f3SGreg Roach                $router->get('locations-export', '/locations-export', 'Admin\LocationController::exportLocations');
3242279b4f3SGreg Roach                $router->get('locations-import', '/locations-import', 'Admin\LocationController::importLocations');
3252279b4f3SGreg Roach                $router->post('locations-import-action', '/locations-import', 'Admin\LocationController::importLocationsAction');
3262279b4f3SGreg Roach                $router->get('map-provider', '/map-provider', 'Admin\MapProviderController::mapProviderEdit');
3272279b4f3SGreg Roach                $router->post('map-provider-action', '/map-provider', 'Admin\MapProviderController::mapProviderSave');
3289f667ff2SGreg Roach                $router->post(ModuleDeleteSettings::class, '/module-delete-settings');
3299f667ff2SGreg Roach                $router->get(ModulesAllPage::class, '/modules');
3309f667ff2SGreg Roach                $router->post(ModulesAllAction::class, '/modules');
3319f667ff2SGreg Roach                $router->get(ModulesAnalyticsPage::class, '/analytics');
3329f667ff2SGreg Roach                $router->post(ModulesAnalyticsAction::class, '/analytics');
3339f667ff2SGreg Roach                $router->get(ModulesBlocksPage::class, '/blocks');
3349f667ff2SGreg Roach                $router->post(ModulesBlocksAction::class, '/blocks');
3359f667ff2SGreg Roach                $router->get(ModulesChartsPage::class, '/charts');
3369f667ff2SGreg Roach                $router->post(ModulesChartsAction::class, '/charts');
3379f667ff2SGreg Roach                $router->get(ModulesDataFixesPage::class, '/data-fixes');
3389f667ff2SGreg Roach                $router->post(ModulesDataFixesAction::class, '/data-fixes');
3399f667ff2SGreg Roach                $router->get(ModulesFootersPage::class, '/footers');
3409f667ff2SGreg Roach                $router->post(ModulesFootersAction::class, '/footers');
3419f667ff2SGreg Roach                $router->get(ModulesHistoricEventsPage::class, '/historic-events');
3429f667ff2SGreg Roach                $router->post(ModulesHistoricEventsAction::class, '/historic-events');
3439f667ff2SGreg Roach                $router->get(ModulesListsPage::class, '/lists');
3449f667ff2SGreg Roach                $router->post(ModulesListsAction::class, '/lists');
3459f667ff2SGreg Roach                $router->get(ModulesMenusPage::class, '/menus');
3469f667ff2SGreg Roach                $router->post(ModulesMenusAction::class, '/menus');
3479f667ff2SGreg Roach                $router->get(ModulesLanguagesPage::class, '/languages');
3489f667ff2SGreg Roach                $router->post(ModulesLanguagesAction::class, '/languages');
3499f667ff2SGreg Roach                $router->get(ModulesReportsPage::class, '/reports');
3509f667ff2SGreg Roach                $router->post(ModulesReportsAction::class, '/reports');
3519f667ff2SGreg Roach                $router->get(ModulesSidebarsPage::class, '/sidebars');
3529f667ff2SGreg Roach                $router->post(ModulesSidebarsAction::class, '/sidebars');
3539f667ff2SGreg Roach                $router->get(ModulesTabsPage::class, '/tabs');
3549f667ff2SGreg Roach                $router->post(ModulesTabsAction::class, '/tabs');
3559f667ff2SGreg Roach                $router->get(ModulesThemesPage::class, '/themes');
3569f667ff2SGreg Roach                $router->post(ModulesThemesAction::class, '/themes');
3572279b4f3SGreg Roach                $router->get('upgrade', '/upgrade', 'Admin\UpgradeController::wizard');
358c06384d0SGreg Roach                $router->post('upgrade-confirm', '/upgrade-confirm', 'Admin\UpgradeController::confirm');
3592279b4f3SGreg Roach                $router->post('upgrade-action', '/upgrade', 'Admin\UpgradeController::step');
3602279b4f3SGreg Roach                $router->get('admin-users', '/admin-users', 'Admin\UsersController::index');
3612279b4f3SGreg Roach                $router->get('admin-users-data', '/admin-users-data', 'Admin\UsersController::data');
3622279b4f3SGreg Roach                $router->get('admin-users-create', '/admin-users-create', 'Admin\UsersController::create');
3632279b4f3SGreg Roach                $router->post('admin-users-create-action', '/admin-users-create', 'Admin\UsersController::save');
3642279b4f3SGreg Roach                $router->get('admin-users-edit', '/admin-users-edit', 'Admin\UsersController::edit');
3652279b4f3SGreg Roach                $router->post('admin-users-update', '/admin-users-edit', 'Admin\UsersController::update');
366451d4d87SGreg Roach                $router->get(SitePreferencesPage::class, '/site-preferences');
367451d4d87SGreg Roach                $router->post(SitePreferencesAction::class, '/site-preferences');
368451d4d87SGreg Roach                $router->get(SiteRegistrationPage::class, '/site-registration');
369451d4d87SGreg Roach                $router->post(SiteRegistrationAction::class, '/site-registration');
370451d4d87SGreg Roach                $router->get(TreePageDefaultEdit::class, '/trees/default-blocks');
371451d4d87SGreg Roach                $router->post(TreePageDefaultUpdate::class, '/trees/default-blocks');
3726fd01894SGreg Roach                $router->get(MergeTreesPage::class, '/trees/merge');
3736fd01894SGreg Roach                $router->post(MergeTreesAction::class, '/trees/merge');
3746fd01894SGreg Roach                $router->post(SynchronizeTrees::class, '/trees/sync');
3756fd01894SGreg Roach                $router->post(DeleteUser::class, '/users/delete/{user_id}');
376451d4d87SGreg Roach                $router->get(UserPageDefaultEdit::class, '/user-page-default-edit');
377451d4d87SGreg Roach                $router->post(UserPageDefaultUpdate::class, '/user-page-default-update');
378cccedbe5SGreg Roach
379cccedbe5SGreg Roach                // @deprecated since 2.0.8 - will be removed in 2.1.0
380cccedbe5SGreg Roach                $router->get('modules', '/modules', ModulesAllPage::class);
3812279b4f3SGreg Roach            });
3822279b4f3SGreg Roach
38357796b09SGreg Roach            // Manager routes (multiple trees).
3842279b4f3SGreg Roach            $router->attach('', '/admin', static function (Map $router) {
3852279b4f3SGreg Roach                $router->extras([
386901ade19SGreg Roach                    'middleware' => [
387901ade19SGreg Roach                        AuthManager::class,
388901ade19SGreg Roach                    ],
3892279b4f3SGreg Roach                ]);
3902279b4f3SGreg Roach
3916fd01894SGreg Roach                $router->get(ManageTrees::class, '/trees/manage/{tree}');
3922279b4f3SGreg Roach            });
3932279b4f3SGreg Roach
3942279b4f3SGreg Roach            // Manager routes.
3952279b4f3SGreg Roach            $router->attach('', '/tree/{tree}', static function (Map $router) {
3962279b4f3SGreg Roach                $router->extras([
397901ade19SGreg Roach                    'middleware' => [
398901ade19SGreg Roach                        AuthManager::class,
399901ade19SGreg Roach                    ],
4002279b4f3SGreg Roach                ]);
4012279b4f3SGreg Roach
402451d4d87SGreg Roach                $router->get(PendingChangesLogPage::class, '/changes-log');
403451d4d87SGreg Roach                $router->post(PendingChangesLogAction::class, '/changes-log');
404451d4d87SGreg Roach                $router->get(PendingChangesLogData::class, '/changes-data');
405451d4d87SGreg Roach                $router->post(PendingChangesLogDelete::class, '/changes-delete');
406451d4d87SGreg Roach                $router->get(PendingChangesLogDownload::class, '/changes-download');
4076fd01894SGreg Roach                $router->get(CheckTree::class, '/check');
408451d4d87SGreg Roach                $router->get(DataFixChoose::class, '/data-fix');
409451d4d87SGreg Roach                $router->post(DataFixSelect::class, '/data-fix');
410451d4d87SGreg Roach                $router->get(DataFixPage::class, '/data-fix/{data_fix}');
411451d4d87SGreg Roach                $router->post(DataFixUpdate::class, '/data-fix/{data_fix}/update');
412451d4d87SGreg Roach                $router->post(DataFixUpdateAll::class, '/data-fix/{data_fix}/update-all');
413451d4d87SGreg Roach                $router->get(DataFixData::class, '/data-fix/{data_fix}/data');
414451d4d87SGreg Roach                $router->get(DataFixPreview::class, '/data-fix/{data_fix}/preview');
4156fd01894SGreg Roach                $router->get(FindDuplicateRecords::class, '/duplicates');
416451d4d87SGreg Roach                $router->get(ExportGedcomPage::class, '/export');
417451d4d87SGreg Roach                $router->post(ExportGedcomClient::class, '/export-client');
418451d4d87SGreg Roach                $router->post(ExportGedcomServer::class, '/export-server');
4196fd01894SGreg Roach                $router->get(ImportGedcomPage::class, '/import');
4206fd01894SGreg Roach                $router->post(ImportGedcomAction::class, '/import');
421451d4d87SGreg Roach                $router->get(MergeRecordsPage::class, '/merge-step1');
422451d4d87SGreg Roach                $router->post(MergeRecordsAction::class, '/merge-step1');
423451d4d87SGreg Roach                $router->get(MergeFactsPage::class, '/merge-step2');
424451d4d87SGreg Roach                $router->post(MergeFactsAction::class, '/merge-step2');
4256fd01894SGreg Roach                $router->get(TreePreferencesPage::class, '/preferences');
4266fd01894SGreg Roach                $router->post(TreePreferencesAction::class, '/preferences');
4276fd01894SGreg Roach                $router->get(RenumberTreePage::class, '/renumber');
4286fd01894SGreg Roach                $router->post(RenumberTreeAction::class, '/renumber');
429451d4d87SGreg Roach                $router->get(TreePageEdit::class, '/tree-page-edit');
4306fd01894SGreg Roach                $router->post(GedcomLoad::class, '/load');
431451d4d87SGreg Roach                $router->post(TreePageUpdate::class, '/tree-page-update');
432451d4d87SGreg Roach                $router->get(TreePageBlockEdit::class, '/tree-page-block-edit');
433451d4d87SGreg Roach                $router->post(TreePageBlockUpdate::class, '/tree-page-block-edit');
4346fd01894SGreg Roach                $router->get(TreePrivacyPage::class, '/privacy');
4356fd01894SGreg Roach                $router->post(TreePrivacyAction::class, '/privacy');
436451d4d87SGreg Roach                $router->get(UnconnectedPage::class, '/unconnected');
437451d4d87SGreg Roach                $router->post(UnconnectedAction::class, '/unconnected');
4382279b4f3SGreg Roach            });
4392279b4f3SGreg Roach
4402279b4f3SGreg Roach            // Moderator routes.
4412279b4f3SGreg Roach            $router->attach('', '/tree/{tree}', static function (Map $router) {
4422279b4f3SGreg Roach                $router->extras([
443901ade19SGreg Roach                    'middleware' => [
444901ade19SGreg Roach                        AuthModerator::class,
445901ade19SGreg Roach                    ],
4462279b4f3SGreg Roach                ]);
447451d4d87SGreg Roach                $router->post(PendingChangesAcceptTree::class, '/accept');
448451d4d87SGreg Roach                $router->post(PendingChangesAcceptRecord::class, '/accept/{xref}');
449451d4d87SGreg Roach                $router->post(PendingChangesAcceptChange::class, '/accept/{xref}/{change}');
450451d4d87SGreg Roach                $router->get(PendingChanges::class, '/pending');
451451d4d87SGreg Roach                $router->post(PendingChangesRejectTree::class, '/reject');
452451d4d87SGreg Roach                $router->post(PendingChangesRejectRecord::class, '/reject/{xref}');
453451d4d87SGreg Roach                $router->post(PendingChangesRejectChange::class, '/reject/{xref}/{change}');
4542279b4f3SGreg Roach            });
4552279b4f3SGreg Roach
4562279b4f3SGreg Roach            // Editor routes.
4572279b4f3SGreg Roach            $router->attach('', '/tree/{tree}', static function (Map $router) {
4582279b4f3SGreg Roach                $router->extras([
459901ade19SGreg Roach                    'middleware' => [
460901ade19SGreg Roach                        AuthEditor::class,
461901ade19SGreg Roach                    ],
4622279b4f3SGreg Roach                ]);
4632279b4f3SGreg Roach
46463763244SGreg Roach                $router->get(AutoCompleteCitation::class, '/autocomplete/citation/{query}');
46563763244SGreg Roach                $router->get(AutoCompleteFolder::class, '/autocomplete/folder/{query}');
46663763244SGreg Roach                $router->get(AutoCompletePlace::class, '/autocomplete/place/{query}');
46763763244SGreg Roach                $router->get(AutoCompleteSurname::class, '/autocomplete/surname/{query}');
468451d4d87SGreg Roach                $router->get(AddChildToFamilyPage::class, '/add-child-to-family');
469451d4d87SGreg Roach                $router->post(AddChildToFamilyAction::class, '/add-child-to-family');
470451d4d87SGreg Roach                $router->get(AddNewFact::class, '/add-fact/{xref}/{fact}');
471451d4d87SGreg Roach                $router->post(SelectNewFact::class, '/add-fact/{xref}');
4722279b4f3SGreg Roach                $router->get('add-media-file', '/add-media-file', 'EditMediaController::addMediaFile');
4732279b4f3SGreg Roach                $router->post('add-media-file-update', '/add-media-file', 'EditMediaController::addMediaFileAction');
474451d4d87SGreg Roach                $router->get(AddName::class, '/add-name');
475451d4d87SGreg Roach                $router->get(AddSpouseToFamilyPage::class, '/add-spouse-to-family');
476451d4d87SGreg Roach                $router->post(AddSpouseToFamilyAction::class, '/add-spouse-to-family');
477451d4d87SGreg Roach                $router->get(ChangeFamilyMembersPage::class, '/change-family-members');
478451d4d87SGreg Roach                $router->post(ChangeFamilyMembersAction::class, '/change-family-members');
479451d4d87SGreg Roach                $router->get(CreateMediaObjectModal::class, '/create-media-object');
480451d4d87SGreg Roach                $router->post(CreateMediaObjectAction::class, '/create-media-object');
4812279b4f3SGreg Roach                $router->post('create-media-from-file', '/create-media-from-file', 'EditMediaController::createMediaObjectFromFileAction');
482451d4d87SGreg Roach                $router->post(CopyFact::class, '/copy/{xref}/{fact_id}');
483451d4d87SGreg Roach                $router->get(CreateNoteModal::class, '/create-note-object');
484451d4d87SGreg Roach                $router->post(CreateNoteAction::class, '/create-note-object');
485451d4d87SGreg Roach                $router->get(CreateRepositoryModal::class, '/create-repository');
486451d4d87SGreg Roach                $router->post(CreateRepositoryAction::class, '/create-repository');
487451d4d87SGreg Roach                $router->get(CreateSourceModal::class, '/create-source');
488451d4d87SGreg Roach                $router->post(CreateSourceAction::class, '/create-source');
489451d4d87SGreg Roach                $router->get(CreateSubmitterModal::class, '/create-submitter');
490451d4d87SGreg Roach                $router->post(CreateSubmitterAction::class, '/create-submitter');
491451d4d87SGreg Roach                $router->post(DeleteRecord::class, '/delete/{xref}');
492451d4d87SGreg Roach                $router->post(DeleteFact::class, '/delete/{xref}/{fact_id}');
493451d4d87SGreg Roach                $router->get(EditFactPage::class, '/edit-fact/{xref}/{fact_id}');
494451d4d87SGreg Roach                $router->post(EditFactAction::class, '/update-fact/{xref}{/fact_id}');
4952279b4f3SGreg Roach                $router->get('edit-media-file', '/edit-media-file', 'EditMediaController::editMediaFile');
4962279b4f3SGreg Roach                $router->post('edit-media-file-update', '/edit-media-file', 'EditMediaController::editMediaFileAction');
497316db80eSGreg Roach                $router->get('edit-note-object', '/edit-note-object/{xref}', 'EditNoteController::editNoteObject');
498316db80eSGreg Roach                $router->post('edit-note-object-action', '/edit-note-object/{xref}', 'EditNoteController::updateNoteObject');
499451d4d87SGreg Roach                $router->get(EditRawFactPage::class, '/edit-raw/{xref}/{fact_id}');
500451d4d87SGreg Roach                $router->post(EditRawFactAction::class, '/edit-raw/{xref}/{fact_id}');
501451d4d87SGreg Roach                $router->get(EditRawRecordPage::class, '/edit-raw/{xref}');
502451d4d87SGreg Roach                $router->post(EditRawRecordAction::class, '/edit-raw/{xref}');
5032279b4f3SGreg Roach                $router->get('link-media-to-individual', '/link-media-to-individual', 'EditMediaController::linkMediaToIndividual');
5042279b4f3SGreg Roach                $router->get('link-media-to-family', '/link-media-to-family', 'EditMediaController::linkMediaToFamily');
5052279b4f3SGreg Roach                $router->get('link-media-to-source', '/link-media-to-source', 'EditMediaController::linkMediaToSource');
506814c6707SGreg Roach                $router->post('link-media-to-record', '/link-media-to-record/{xref}', 'EditMediaController::linkMediaToRecordAction');
507451d4d87SGreg Roach                $router->post(PasteFact::class, '/paste-fact/{xref}');
508451d4d87SGreg Roach                $router->get(ReorderChildrenPage::class, '/reorder-children/{xref}');
509451d4d87SGreg Roach                $router->post(ReorderChildrenAction::class, '/reorder-children/{xref}');
510451d4d87SGreg Roach                $router->get(ReorderMediaPage::class, '/reorder-media/{xref}');
511451d4d87SGreg Roach                $router->post(ReorderMediaAction::class, '/reorder-media/{xref}');
512451d4d87SGreg Roach                $router->get(ReorderNamesPage::class, '/reorder-names/{xref}');
513451d4d87SGreg Roach                $router->post(ReorderNamesAction::class, '/reorder-names/{xref}');
514451d4d87SGreg Roach                $router->get(ReorderFamiliesPage::class, '/reorder-spouses/{xref}');
515451d4d87SGreg Roach                $router->post(ReorderFamiliesAction::class, '/reorder-spouses/{xref}');
516451d4d87SGreg Roach                $router->get(SearchReplacePage::class, '/search-replace');
517451d4d87SGreg Roach                $router->post(SearchReplaceAction::class, '/search-replace');
518451d4d87SGreg Roach                $router->get(AddChildToIndividualPage::class, '/add-child-to-individual');
519451d4d87SGreg Roach                $router->post(AddChildToIndividualAction::class, '/add-child-to-individual');
520451d4d87SGreg Roach                $router->get(AddParentToIndividualPage::class, '/add-parent-to-individual');
521451d4d87SGreg Roach                $router->post(AddParentToIndividualAction::class, '/add-parent-to-individual');
522451d4d87SGreg Roach                $router->get(AddSpouseToIndividualPage::class, '/add-spouse-to-individual');
523451d4d87SGreg Roach                $router->post(AddSpouseToIndividualAction::class, '/add-spouse-to-individual');
524451d4d87SGreg Roach                $router->get(AddUnlinkedPage::class, '/add-unlinked-individual');
525451d4d87SGreg Roach                $router->post(AddUnlinkedAction::class, '/add-unlinked-individual');
526451d4d87SGreg Roach                $router->get(LinkChildToFamilyPage::class, '/link-child-to-family');
527451d4d87SGreg Roach                $router->post(LinkChildToFamilyAction::class, '/link-child-to-family');
528451d4d87SGreg Roach                $router->get(LinkSpouseToIndividualPage::class, '/link-spouse-to-individual');
529451d4d87SGreg Roach                $router->post(LinkSpouseToIndividualAction::class, '/link-spouse-to-individual');
530451d4d87SGreg Roach                $router->get(EditName::class, '/edit-name/{xref}/{fact_id}');
5312279b4f3SGreg Roach            });
5322279b4f3SGreg Roach
5338673e6b9SGreg Roach            // User routes with a tree.
5342279b4f3SGreg Roach            $router->attach('', '/tree/{tree}', static function (Map $router) {
5352279b4f3SGreg Roach                $router->extras([
536901ade19SGreg Roach                    'middleware' => [
5378673e6b9SGreg Roach                        AuthLoggedIn::class,
538901ade19SGreg Roach                    ],
5392279b4f3SGreg Roach                ]);
5402279b4f3SGreg Roach
541451d4d87SGreg Roach                $router->post(MessageSelect::class, '/message-select');
542451d4d87SGreg Roach                $router->get(MessagePage::class, '/message-compose');
543451d4d87SGreg Roach                $router->post(MessageAction::class, '/message-send');
544451d4d87SGreg Roach                $router->get(UserPage::class, '/my-page');
545451d4d87SGreg Roach                $router->get(UserPageBlock::class, '/my-page-block');
546451d4d87SGreg Roach                $router->get(UserPageEdit::class, '/my-page-edit');
547451d4d87SGreg Roach                $router->post(UserPageUpdate::class, '/my-page-edit');
548451d4d87SGreg Roach                $router->get(UserPageBlockEdit::class, '/my-page-block-edit');
549451d4d87SGreg Roach                $router->post(UserPageBlockUpdate::class, '/my-page-block-edit');
5502279b4f3SGreg Roach            });
5512279b4f3SGreg Roach
5528673e6b9SGreg Roach            // User routes without a tree.
5532279b4f3SGreg Roach            $router->attach('', '', static function (Map $router) {
5542279b4f3SGreg Roach                $router->extras([
555901ade19SGreg Roach                    'middleware' => [
556901ade19SGreg Roach                        AuthLoggedIn::class,
557901ade19SGreg Roach                    ],
5582279b4f3SGreg Roach                ]);
5592279b4f3SGreg Roach
560451d4d87SGreg Roach                $router->get(AccountEdit::class, '/my-account{/tree}');
561451d4d87SGreg Roach                $router->post(AccountUpdate::class, '/my-account{/tree}');
562451d4d87SGreg Roach                $router->post(AccountDelete::class, '/my-account-delete');
5632279b4f3SGreg Roach            });
5642279b4f3SGreg Roach
565f917a287SGreg Roach            // Visitor routes - with an optional tree (for sites with no public trees).
5662279b4f3SGreg Roach            $router->attach('', '', static function (Map $router) {
567451d4d87SGreg Roach                $router->get(LoginPage::class, '/login{/tree}');
568451d4d87SGreg Roach                $router->post(LoginAction::class, '/login{/tree}');
569451d4d87SGreg Roach                $router->get(PasswordRequestPage::class, '/password-request{/tree}');
570451d4d87SGreg Roach                $router->post(PasswordRequestAction::class, '/password-request{/tree}');
571451d4d87SGreg Roach                $router->get(RegisterPage::class, '/register{/tree}');
572451d4d87SGreg Roach                $router->post(RegisterAction::class, '/register{/tree}');
573451d4d87SGreg Roach                $router->get(PasswordResetPage::class, '/password-reset/{token}{/tree}');
574451d4d87SGreg Roach                $router->post(PasswordResetAction::class, '/password-reset/{token}{/tree}');
575451d4d87SGreg Roach                $router->get(VerifyEmail::class, '/verify/{username}/{token}{/tree}');
5762279b4f3SGreg Roach            });
5772279b4f3SGreg Roach
578b45ccc4fSGreg Roach            // Visitor routes with a tree.
5792279b4f3SGreg Roach            $router->attach('', '/tree/{tree}', static function (Map $router) {
580451d4d87SGreg Roach                $router->get(TreePage::class, '');
581451d4d87SGreg Roach                $router->get(CalendarPage::class, '/calendar/{view}');
582451d4d87SGreg Roach                $router->post(CalendarAction::class, '/calendar/{view}');
583451d4d87SGreg Roach                $router->get(CalendarEvents::class, '/calendar-events/{view}');
584451d4d87SGreg Roach                $router->get(ContactPage::class, '/contact');
585451d4d87SGreg Roach                $router->post(ContactAction::class, '/contact');
586451d4d87SGreg Roach                $router->get(FamilyPage::class, '/family/{xref}{/slug}');
587451d4d87SGreg Roach                $router->get(HeaderPage::class, '/header/{xref}{/slug}');
588451d4d87SGreg Roach                $router->get(IndividualPage::class, '/individual/{xref}{/slug}');
589451d4d87SGreg Roach                $router->get(MediaFileThumbnail::class, '/media-thumbnail');
590451d4d87SGreg Roach                $router->get(MediaFileDownload::class, '/media-download');
591451d4d87SGreg Roach                $router->get(MediaPage::class, '/media/{xref}{/slug}');
592451d4d87SGreg Roach                $router->get(NotePage::class, '/note/{xref}{/slug}');
593451d4d87SGreg Roach                $router->get(GedcomRecordPage::class, '/record/{xref}{/slug}');
594451d4d87SGreg Roach                $router->get(RepositoryPage::class, '/repository/{xref}{/slug}');
595451d4d87SGreg Roach                $router->get(ReportListPage::class, '/report');
596451d4d87SGreg Roach                $router->post(ReportListAction::class, '/report');
597451d4d87SGreg Roach                $router->get(ReportSetupPage::class, '/report/{report}');
598451d4d87SGreg Roach                $router->post(ReportSetupAction::class, '/report/{report}');
599451d4d87SGreg Roach                $router->get(ReportGenerate::class, '/report-run/{report}');
600451d4d87SGreg Roach                $router->get(SearchAdvancedPage::class, '/search-advanced');
601451d4d87SGreg Roach                $router->post(SearchAdvancedAction::class, '/search-advanced');
602451d4d87SGreg Roach                $router->get(SearchGeneralPage::class, '/search-general');
603451d4d87SGreg Roach                $router->post(SearchGeneralAction::class, '/search-general');
604451d4d87SGreg Roach                $router->get(SearchPhoneticPage::class, '/search-phonetic');
605451d4d87SGreg Roach                $router->post(SearchPhoneticAction::class, '/search-phonetic');
606451d4d87SGreg Roach                $router->post(SearchQuickAction::class, '/search-quick');
607451d4d87SGreg Roach                $router->post(Select2Family::class, '/select2-family');
608451d4d87SGreg Roach                $router->post(Select2Individual::class, '/select2-individual');
609451d4d87SGreg Roach                $router->post(Select2MediaObject::class, '/select2-media');
610451d4d87SGreg Roach                $router->post(Select2Note::class, '/select2-note');
611451d4d87SGreg Roach                $router->post(Select2Place::class, '/select2-place');
612451d4d87SGreg Roach                $router->post(Select2Source::class, '/select2-source');
613451d4d87SGreg Roach                $router->post(Select2Submitter::class, '/select2-submitter');
614451d4d87SGreg Roach                $router->post(Select2Repository::class, '/select2-repository');
615451d4d87SGreg Roach                $router->get(SourcePage::class, '/source/{xref}{/slug}');
616451d4d87SGreg Roach                $router->get(SubmissionPage::class, '/submission/{xref}{/slug}');
617451d4d87SGreg Roach                $router->get(SubmitterPage::class, '/submitter/{xref}{/slug}');
618451d4d87SGreg Roach                $router->get(TreePageBlock::class, '/tree-page-block');
619451d4d87SGreg Roach                $router->get('example', '/…')
620451d4d87SGreg Roach                    ->isRoutable(false);
6212279b4f3SGreg Roach            });
6222279b4f3SGreg Roach
623b59ec43dSGreg Roach            // Match module routes, with and without a tree.
624b59ec43dSGreg Roach            $router->get('module-tree', '/module/{module}/{action}/{tree}', ModuleAction::class)
6252279b4f3SGreg Roach                ->allows(RequestMethodInterface::METHOD_POST);
626b59ec43dSGreg Roach            $router->get('module-no-tree', '/module/{module}/{action}', ModuleAction::class)
627b59ec43dSGreg Roach                ->allows(RequestMethodInterface::METHOD_POST);
628b59ec43dSGreg Roach            // Generate module routes only. The router cannot distinguish a private tree from no tree.
629451d4d87SGreg Roach            $router->get('module', '/module/{module}/{action}{/tree}')
630451d4d87SGreg Roach                ->isRoutable(false);
6312279b4f3SGreg Roach
632451d4d87SGreg Roach            $router->get(HelpText::class, '/help/{topic}');
633451d4d87SGreg Roach            $router->post(SelectLanguage::class, '/language/{language}');
634451d4d87SGreg Roach            $router->post(Logout::class, '/logout');
63564c83a78SGreg Roach            $router->get(Ping::class, '/ping', Ping::class)
63664c83a78SGreg Roach                ->allows(RequestMethodInterface::METHOD_HEAD);
637451d4d87SGreg Roach            $router->get(RobotsTxt::class, '/robots.txt');
638451d4d87SGreg Roach            $router->post(SelectTheme::class, '/theme/{theme}');
639451d4d87SGreg Roach            $router->get(HomePage::class, '/');
6402279b4f3SGreg Roach
64146431a62SGreg Roach            // Some URL rewrite configurations will pass everything not in /public to index.php
642451d4d87SGreg Roach            $router->get(AppleTouchIconPng::class, '/apple-touch-icon.png');
643451d4d87SGreg Roach            $router->get(FaviconIco::class, '/favicon.ico');
644901ade19SGreg Roach        });
6452279b4f3SGreg Roach    }
6462279b4f3SGreg Roach}
647