Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/polls.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordartcafe <github@dartcafe.de>2021-09-01 22:31:55 +0300
committerdartcafe <github@dartcafe.de>2021-09-03 12:28:14 +0300
commit7ccd1bcadbf7801722fab0c2a4ae1f88d4ff8f37 (patch)
treebcf6d884876a4bdda25baceff284bca609f6b4b2 /appinfo
parentb79c4c2c6759c4e10cc1094690b49e06c04ff283 (diff)
Add admin page for polls
Signed-off-by: dartcafe <github@dartcafe.de>
Diffstat (limited to 'appinfo')
-rw-r--r--appinfo/info.xml37
-rw-r--r--appinfo/routes.php11
2 files changed, 29 insertions, 19 deletions
diff --git a/appinfo/info.xml b/appinfo/info.xml
index af89eebd..f3c90abc 100644
--- a/appinfo/info.xml
+++ b/appinfo/info.xml
@@ -1,6 +1,5 @@
<?xml version="1.0"?>
-<info xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance"
- xsi:noNamespaceSchemaLocation="https://apps.nextcloud.com/schema/apps/info.xsd">
+<info xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://apps.nextcloud.com/schema/apps/info.xsd">
<id>polls</id>
<name>Polls</name>
<summary>A polls app, similar to doodle/dudle with the possibility to restrict access.</summary>
@@ -26,24 +25,30 @@
<php min-version="7.3"/>
<nextcloud min-version="21" max-version="22" />
</dependencies>
- <background-jobs>
- <job>OCA\Polls\Cron\NotificationCron</job>
+ <background-jobs>
+ <job>OCA\Polls\Cron\NotificationCron</job>
<job>OCA\Polls\Cron\JanitorCron</job>
- </background-jobs>
- <commands>
- <command>OCA\Polls\Command\Share\Add</command>
- <command>OCA\Polls\Command\Share\Remove</command>
- </commands>
- <repair-steps>
- <pre-migration>
- <step>OCA\Polls\Migration\RemoveIndices</step>
- <step>OCA\Polls\Migration\DeleteInvalidRecords</step>
+ </background-jobs>
+ <commands>
+ <command>OCA\Polls\Command\Share\Add</command>
+ <command>OCA\Polls\Command\Share\Remove</command>
+ </commands>
+ <settings>
+ <admin-section>OCA\Polls\Settings\AdminSection</admin-section>
+ <personal-section>OCA\Polls\Settings\PersonalSection</personal-section>
+ <admin>OCA\Polls\Settings\AdminSettings</admin>
+ <personal>OCA\Polls\Settings\PersonalSettings</personal>
+ </settings>
+ <repair-steps>
+ <pre-migration>
+ <step>OCA\Polls\Migration\RemoveIndices</step>
+ <step>OCA\Polls\Migration\DeleteInvalidRecords</step>
</pre-migration>
- <post-migration>
- <step>OCA\Polls\Migration\CreateIndices</step>
+ <post-migration>
+ <step>OCA\Polls\Migration\CreateIndices</step>
</post-migration>
</repair-steps>
- <navigations>
+ <navigations>
<navigation>
<name>Polls</name>
<route>polls.page.index</route>
diff --git a/appinfo/routes.php b/appinfo/routes.php
index 533236c7..1f3c9598 100644
--- a/appinfo/routes.php
+++ b/appinfo/routes.php
@@ -87,6 +87,9 @@ return [
['name' => 'share#sendInvitation', 'url' => '/share/{token}/invite', 'verb' => 'POST'],
['name' => 'share#resolveGroup', 'url' => '/share/{token}/resolve', 'verb' => 'GET'],
+ ['name' => 'settings#getAppSettings', 'url' => '/settings/app', 'verb' => 'GET'],
+ ['name' => 'settings#writeAppSettings', 'url' => '/settings/app', 'verb' => 'POST'],
+
['name' => 'subscription#get', 'url' => '/poll/{pollId}/subscription', 'verb' => 'GET'],
['name' => 'subscription#set', 'url' => '/poll/{pollId}/subscription', 'verb' => 'PUT'],
['name' => 'subscription#subscribe', 'url' => '/poll/{pollId}/subscribe', 'verb' => 'PUT'],
@@ -97,11 +100,13 @@ return [
['name' => 'comment#delete', 'url' => '/comment/{commentId}', 'verb' => 'DELETE', 'postfix' => 'auth'],
['name' => 'system#user_search', 'url' => '/search/users/{query}', 'verb' => 'GET'],
- ['name' => 'watch#watch_poll', 'url' => '/poll/{pollId}/watch', 'verb' => 'GET'],
+ ['name' => 'system#group_search', 'url' => '/groups/{query}', 'verb' => 'GET', 'postfix' => 'query'],
+ ['name' => 'system#group_search', 'url' => '/groups', 'verb' => 'GET', 'postfix' => 'all'],
- ['name' => 'preferences#write', 'url' => '/preferences/write', 'verb' => 'POST'],
- ['name' => 'preferences#get', 'url' => '/preferences/get', 'verb' => 'GET'],
+ ['name' => 'watch#watch_poll', 'url' => '/poll/{pollId}/watch', 'verb' => 'GET'],
+ ['name' => 'preferences#write', 'url' => '/preferences', 'verb' => 'POST'],
+ ['name' => 'preferences#get', 'url' => '/preferences', 'verb' => 'GET'],
['name' => 'preferences#get_calendars', 'url' => '/calendars', 'verb' => 'GET'],
// REST-API calls