routes.php 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2017-2024 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-FileCopyrightText: 2016 ownCloud, Inc.
  6. * SPDX-License-Identifier: AGPL-3.0-only
  7. */
  8. $this->create('user_ldap_ajax_clearMappings', 'apps/user_ldap/ajax/clearMappings.php')
  9. ->actionInclude('user_ldap/ajax/clearMappings.php');
  10. $this->create('user_ldap_ajax_deleteConfiguration', 'apps/user_ldap/ajax/deleteConfiguration.php')
  11. ->actionInclude('user_ldap/ajax/deleteConfiguration.php');
  12. $this->create('user_ldap_ajax_getConfiguration', 'apps/user_ldap/ajax/getConfiguration.php')
  13. ->actionInclude('user_ldap/ajax/getConfiguration.php');
  14. $this->create('user_ldap_ajax_getNewServerConfigPrefix', 'apps/user_ldap/ajax/getNewServerConfigPrefix.php')
  15. ->actionInclude('user_ldap/ajax/getNewServerConfigPrefix.php');
  16. $this->create('user_ldap_ajax_setConfiguration', 'apps/user_ldap/ajax/setConfiguration.php')
  17. ->actionInclude('user_ldap/ajax/setConfiguration.php');
  18. $this->create('user_ldap_ajax_testConfiguration', 'apps/user_ldap/ajax/testConfiguration.php')
  19. ->actionInclude('user_ldap/ajax/testConfiguration.php');
  20. $this->create('user_ldap_ajax_wizard', 'apps/user_ldap/ajax/wizard.php')
  21. ->actionInclude('user_ldap/ajax/wizard.php');
  22. $application = new \OCP\AppFramework\App('user_ldap');
  23. $application->registerRoutes($this, [
  24. 'ocs' => [
  25. ['name' => 'ConfigAPI#create', 'url' => '/api/v1/config', 'verb' => 'POST'],
  26. ['name' => 'ConfigAPI#show', 'url' => '/api/v1/config/{configID}', 'verb' => 'GET'],
  27. ['name' => 'ConfigAPI#modify', 'url' => '/api/v1/config/{configID}', 'verb' => 'PUT'],
  28. ['name' => 'ConfigAPI#delete', 'url' => '/api/v1/config/{configID}', 'verb' => 'DELETE'],
  29. ]
  30. ]);
  31. /** @var \OCA\User_LDAP\AppInfo\Application $application */
  32. $application = \OC::$server->query(\OCA\User_LDAP\AppInfo\Application::class);
  33. $application->registerRoutes($this, [
  34. 'routes' => [
  35. ['name' => 'renewPassword#tryRenewPassword', 'url' => '/renewpassword', 'verb' => 'POST'],
  36. ['name' => 'renewPassword#showRenewPasswordForm', 'url' => '/renewpassword/{user}', 'verb' => 'GET'],
  37. ['name' => 'renewPassword#cancel', 'url' => '/renewpassword/cancel', 'verb' => 'GET'],
  38. ['name' => 'renewPassword#showLoginFormInvalidPassword', 'url' => '/renewpassword/invalidlogin/{user}', 'verb' => 'GET'],
  39. ]
  40. ]);