| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,64 @@ |
| 1 |
+<?php |
|
| 2 |
+/** |
|
| 3 |
+ * @copyright 2021 Double Bastion LLC <www.doublebastion.com> |
|
| 4 |
+ * |
|
| 5 |
+ * @author Double Bastion LLC |
|
| 6 |
+ * |
|
| 7 |
+ * @license GNU AGPL version 3 or any later version |
|
| 8 |
+ * |
|
| 9 |
+ * This program is free software; you can redistribute it and/or |
|
| 10 |
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE |
|
| 11 |
+ * License as published by the Free Software Foundation; either |
|
| 12 |
+ * version 3 of the License, or any later version. |
|
| 13 |
+ * |
|
| 14 |
+ * This program is distributed in the hope that it will be useful, |
|
| 15 |
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
| 16 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
| 17 |
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details. |
|
| 18 |
+ * |
|
| 19 |
+ * You should have received a copy of the GNU Affero General Public |
|
| 20 |
+ * License along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
| 21 |
+ * |
|
| 22 |
+ */ |
|
| 23 |
+ |
|
| 24 |
+declare(strict_types=1); |
|
| 25 |
+ |
|
| 26 |
+namespace OCA\SIPTripPhone\Settings; |
|
| 27 |
+ |
|
| 28 |
+use OCP\IConfig; |
|
| 29 |
+use OCP\AppFramework\Http\TemplateResponse; |
|
| 30 |
+use OCP\Settings\ISettings; |
|
| 31 |
+ |
|
| 32 |
+ |
|
| 33 |
+class Personal implements ISettings {
|
|
| 34 |
+ |
|
| 35 |
+ /** @var IConfig */ |
|
| 36 |
+ private IConfig $config; |
|
| 37 |
+ |
|
| 38 |
+ public function __construct(IConfig $config) {
|
|
| 39 |
+ $this->config = $config; |
|
| 40 |
+ } |
|
| 41 |
+ |
|
| 42 |
+ public function getForm(): TemplateResponse {
|
|
| 43 |
+ return new TemplateResponse('sip_trip_phone', 'settings');
|
|
| 44 |
+ } |
|
| 45 |
+ |
|
| 46 |
+ /** |
|
| 47 |
+ * @return string the section ID, e.g. 'sharing' |
|
| 48 |
+ */ |
|
| 49 |
+ public function getSection(): string {
|
|
| 50 |
+ return 'sip_trip_phone'; |
|
| 51 |
+ } |
|
| 52 |
+ |
|
| 53 |
+ /** |
|
| 54 |
+ * @return int whether the form should be rather on the top or bottom of |
|
| 55 |
+ * the admin section. The forms are arranged in ascending order of the |
|
| 56 |
+ * priority values. It is required to return a value between 0 and 100. |
|
| 57 |
+ * |
|
| 58 |
+ * keep the server setting at the top, right after "server settings" |
|
| 59 |
+ */ |
|
| 60 |
+ public function getPriority(): int {
|
|
| 61 |
+ return 10; |
|
| 62 |
+ } |
|
| 63 |
+} |
|
| 64 |
+ |
| 1 | 1 |
deleted file mode 100644 |
| ... | ... |
@@ -1,66 +0,0 @@ |
| 1 |
-<?php |
|
| 2 |
-/** |
|
| 3 |
- * @copyright 2021 Double Bastion LLC <www.doublebastion.com> |
|
| 4 |
- * |
|
| 5 |
- * @author Double Bastion LLC |
|
| 6 |
- * |
|
| 7 |
- * @license GNU AGPL version 3 or any later version |
|
| 8 |
- * |
|
| 9 |
- * This program is free software; you can redistribute it and/or |
|
| 10 |
- * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE |
|
| 11 |
- * License as published by the Free Software Foundation; either |
|
| 12 |
- * version 3 of the License, or any later version. |
|
| 13 |
- * |
|
| 14 |
- * This program is distributed in the hope that it will be useful, |
|
| 15 |
- * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
| 16 |
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
| 17 |
- * GNU AFFERO GENERAL PUBLIC LICENSE for more details. |
|
| 18 |
- * |
|
| 19 |
- * You should have received a copy of the GNU Affero General Public |
|
| 20 |
- * License along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
| 21 |
- * |
|
| 22 |
- */ |
|
| 23 |
- |
|
| 24 |
-declare(strict_types=1); |
|
| 25 |
- |
|
| 26 |
-namespace OCA\SIPTripPhone\Settings; |
|
| 27 |
- |
|
| 28 |
-use OCP\IConfig; |
|
| 29 |
-use OCA\SIPTripPhone\AppConfig; |
|
| 30 |
-use OCP\AppFramework\Http\TemplateResponse; |
|
| 31 |
-use OCP\Settings\ISettings; |
|
| 32 |
- |
|
| 33 |
- |
|
| 34 |
-class Personal implements ISettings {
|
|
| 35 |
- /** @var IConfig */ |
|
| 36 |
- private $config; |
|
| 37 |
- |
|
| 38 |
- public function __construct(AppConfig $config) {
|
|
| 39 |
- $this->config = $config; |
|
| 40 |
- } |
|
| 41 |
- |
|
| 42 |
- public function getForm() {
|
|
| 43 |
- |
|
| 44 |
- $parameters = []; |
|
| 45 |
- return new TemplateResponse('sip_trip_phone', 'settings', $parameters, '');
|
|
| 46 |
- } |
|
| 47 |
- |
|
| 48 |
- |
|
| 49 |
- /** |
|
| 50 |
- * @return string the section ID, e.g. 'sharing' |
|
| 51 |
- */ |
|
| 52 |
- public function getSection() {
|
|
| 53 |
- return 'sip_trip_phone'; |
|
| 54 |
- } |
|
| 55 |
- /** |
|
| 56 |
- * @return int whether the form should be rather on the top or bottom of |
|
| 57 |
- * the admin section. The forms are arranged in ascending order of the |
|
| 58 |
- * priority values. It is required to return a value between 0 and 100. |
|
| 59 |
- * |
|
| 60 |
- * keep the server setting at the top, right after "server settings" |
|
| 61 |
- */ |
|
| 62 |
- public function getPriority() {
|
|
| 63 |
- return 10; |
|
| 64 |
- } |
|
| 65 |
-} |
|
| 66 |
- |
| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,66 @@ |
| 1 |
+<?php |
|
| 2 |
+/** |
|
| 3 |
+ * @copyright 2021 Double Bastion LLC <www.doublebastion.com> |
|
| 4 |
+ * |
|
| 5 |
+ * @author Double Bastion LLC |
|
| 6 |
+ * |
|
| 7 |
+ * @license GNU AGPL version 3 or any later version |
|
| 8 |
+ * |
|
| 9 |
+ * This program is free software; you can redistribute it and/or |
|
| 10 |
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE |
|
| 11 |
+ * License as published by the Free Software Foundation; either |
|
| 12 |
+ * version 3 of the License, or any later version. |
|
| 13 |
+ * |
|
| 14 |
+ * This program is distributed in the hope that it will be useful, |
|
| 15 |
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
| 16 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
| 17 |
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details. |
|
| 18 |
+ * |
|
| 19 |
+ * You should have received a copy of the GNU Affero General Public |
|
| 20 |
+ * License along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
| 21 |
+ * |
|
| 22 |
+ */ |
|
| 23 |
+ |
|
| 24 |
+declare(strict_types=1); |
|
| 25 |
+ |
|
| 26 |
+namespace OCA\SIPTripPhone\Settings; |
|
| 27 |
+ |
|
| 28 |
+use OCP\IConfig; |
|
| 29 |
+use OCA\SIPTripPhone\AppConfig; |
|
| 30 |
+use OCP\AppFramework\Http\TemplateResponse; |
|
| 31 |
+use OCP\Settings\ISettings; |
|
| 32 |
+ |
|
| 33 |
+ |
|
| 34 |
+class Personal implements ISettings {
|
|
| 35 |
+ /** @var IConfig */ |
|
| 36 |
+ private $config; |
|
| 37 |
+ |
|
| 38 |
+ public function __construct(AppConfig $config) {
|
|
| 39 |
+ $this->config = $config; |
|
| 40 |
+ } |
|
| 41 |
+ |
|
| 42 |
+ public function getForm() {
|
|
| 43 |
+ |
|
| 44 |
+ $parameters = []; |
|
| 45 |
+ return new TemplateResponse('sip_trip_phone', 'settings', $parameters, '');
|
|
| 46 |
+ } |
|
| 47 |
+ |
|
| 48 |
+ |
|
| 49 |
+ /** |
|
| 50 |
+ * @return string the section ID, e.g. 'sharing' |
|
| 51 |
+ */ |
|
| 52 |
+ public function getSection() {
|
|
| 53 |
+ return 'sip_trip_phone'; |
|
| 54 |
+ } |
|
| 55 |
+ /** |
|
| 56 |
+ * @return int whether the form should be rather on the top or bottom of |
|
| 57 |
+ * the admin section. The forms are arranged in ascending order of the |
|
| 58 |
+ * priority values. It is required to return a value between 0 and 100. |
|
| 59 |
+ * |
|
| 60 |
+ * keep the server setting at the top, right after "server settings" |
|
| 61 |
+ */ |
|
| 62 |
+ public function getPriority() {
|
|
| 63 |
+ return 10; |
|
| 64 |
+ } |
|
| 65 |
+} |
|
| 66 |
+ |