routes.php 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <?php
  2. /**
  3. * @copyright Copyright (c) 2016, ownCloud, Inc.
  4. * @copyright Copyright (c) 2016, Roeland Jago Douma <roeland@famdouma.nl>
  5. *
  6. * @author Lukas Reschke <lukas@statuscode.ch>
  7. * @author Morris Jobke <hey@morrisjobke.de>
  8. * @author Roeland Jago Douma <roeland@famdouma.nl>
  9. * @author Tom Needham <tom@owncloud.com>
  10. *
  11. * @license AGPL-3.0
  12. *
  13. * This code is free software: you can redistribute it and/or modify
  14. * it under the terms of the GNU Affero General Public License, version 3,
  15. * as published by the Free Software Foundation.
  16. *
  17. * This program is distributed in the hope that it will be useful,
  18. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  19. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  20. * GNU Affero General Public License for more details.
  21. *
  22. * You should have received a copy of the GNU Affero General Public License, version 3,
  23. * along with this program. If not, see <http://www.gnu.org/licenses/>
  24. *
  25. */
  26. namespace OCA\Files_Versions\AppInfo;
  27. $application = new Application();
  28. $application->registerRoutes($this, [
  29. 'routes' => [
  30. [
  31. 'name' => 'Preview#getPreview',
  32. 'url' => '/preview',
  33. 'verb' => 'GET',
  34. ],
  35. ],
  36. ]);
  37. /** @var $this \OCP\Route\IRouter */
  38. $this->create('files_versions_download', 'download.php')
  39. ->actionInclude('files_versions/download.php');
  40. $this->create('files_versions_ajax_getVersions', 'ajax/getVersions.php')
  41. ->actionInclude('files_versions/ajax/getVersions.php');
  42. $this->create('files_versions_ajax_rollbackVersion', 'ajax/rollbackVersion.php')
  43. ->actionInclude('files_versions/ajax/rollbackVersion.php');