Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion lib/Activity/ActivityManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
namespace OCA\Forms\Activity;

use OCA\Forms\Db\Form;

use OCA\Forms\Service\CirclesService;
use OCP\Activity\IManager;
use OCP\IGroupManager;
Expand Down
7 changes: 0 additions & 7 deletions lib/Activity/Provider.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
namespace OCA\Forms\Activity;

use Exception;

use OCA\Forms\Db\FormMapper;
use OCA\Forms\Service\CirclesService;
use OCP\Activity\Exceptions\UnknownActivityException;
Expand Down Expand Up @@ -79,16 +78,12 @@ public function getSubjectString(IL10N $l10n, string $subject): string {
switch ($subject) {
case ActivityConstants::SUBJECT_NEWSHARE:
return $l10n->t('{user} has shared the form {formTitle} with you');

case ActivityConstants::SUBJECT_NEWGROUPSHARE:
return $l10n->t('{user} has shared the form {formTitle} with group {group}');

case ActivityConstants::SUBJECT_NEWCIRCLESHARE:
return $l10n->t('{user} has shared the form {formTitle} with team {circle}');

case ActivityConstants::SUBJECT_NEWSUBMISSION:
return $l10n->t('Your form {formTitle} was answered by {user}');

default:
$this->logger->warning('Some unknown activity has been found: ' . $subject);
throw new UnknownActivityException();
Expand Down Expand Up @@ -269,10 +264,8 @@ public function getEventIcon(string $subject): string {
case ActivityConstants::SUBJECT_NEWSHARE:
case ActivityConstants::SUBJECT_NEWGROUPSHARE:
return $this->urlGenerator->getAbsoluteURL($this->urlGenerator->imagePath('core', 'actions/shared.svg'));

case ActivityConstants::SUBJECT_NEWSUBMISSION:
return $this->urlGenerator->getAbsoluteURL($this->urlGenerator->imagePath('core', 'actions/add.svg'));

default:
return $this->urlGenerator->getAbsoluteURL($this->urlGenerator->imagePath('forms', 'forms-dark.svg'));
}
Expand Down
2 changes: 0 additions & 2 deletions lib/BackgroundJob/SyncSubmissionsWithLinkedFileJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,12 @@
use OCA\Forms\Db\FormMapper;
use OCA\Forms\Service\FormsService;
use OCA\Forms\Service\SubmissionService;

use OCP\AppFramework\Utility\ITimeFactory;
use OCP\BackgroundJob\IJobList;
use OCP\BackgroundJob\QueuedJob;
use OCP\Files\NotFoundException;
use OCP\IUserManager;
use OCP\IUserSession;

use Psr\Log\LoggerInterface;
use Throwable;

Expand Down
1 change: 0 additions & 1 deletion lib/BackgroundJob/UserDeletedJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
use OCA\Forms\Db\FormMapper;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\BackgroundJob\QueuedJob;

use Psr\Log\LoggerInterface;

class UserDeletedJob extends QueuedJob {
Expand Down
1 change: 0 additions & 1 deletion lib/Constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ class Constants {
self::CONFIG_KEY_CONFIRMATIONEMAILRATELIMIT => 'int',
];


/**
* Maximum String lengths, the database is set to store.
*/
Expand Down
4 changes: 0 additions & 4 deletions lib/Controller/ApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
use OCA\Forms\Service\ConfirmationEmailService;
use OCA\Forms\Service\FormsService;
use OCA\Forms\Service\SubmissionService;

use OCP\AppFramework\Db\DoesNotExistException;
use OCP\AppFramework\Db\IMapperException;
use OCP\AppFramework\Http;
Expand All @@ -53,7 +52,6 @@
use OCP\IUser;
use OCP\IUserManager;
use OCP\IUserSession;

use Psr\Log\LoggerInterface;

/**
Expand Down Expand Up @@ -719,7 +717,6 @@ public function deleteQuestion(int $formId, int $questionId): DataResponse {
'questionId' => $questionId,
]);


$form = $this->formsService->getFormIfAllowed($formId, Constants::PERMISSION_EDIT);
$this->formsService->obtainFormLock($form);

Expand Down Expand Up @@ -1245,7 +1242,6 @@ public function getSubmissions(int $formId, ?string $query = null, ?int $limit =
$questions[$question['id']] = $question;
}


// Append Display Names
$submissions = array_map(function (array $submission) use ($questions) {
if (!empty($submission['answers'])) {
Expand Down
1 change: 0 additions & 1 deletion lib/Controller/ConfigController.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Services\IAppConfig;
use OCP\IRequest;

use Psr\Log\LoggerInterface;

#[OpenAPI(scope: OpenAPI::SCOPE_IGNORE)]
Expand Down
1 change: 0 additions & 1 deletion lib/Controller/PageController.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
use OCA\Forms\Db\SubmissionMapper;
use OCA\Forms\Service\ConfigService;
use OCA\Forms\Service\FormsService;

use OCP\Accounts\IAccountManager;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Db\DoesNotExistException;
Expand Down
1 change: 0 additions & 1 deletion lib/Controller/ShareApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
use OCA\Forms\Service\CirclesService;
use OCA\Forms\Service\ConfigService;
use OCA\Forms\Service\FormsService;

use OCP\AppFramework\Db\DoesNotExistException;
use OCP\AppFramework\Db\IMapperException;
use OCP\AppFramework\Http;
Expand Down
1 change: 0 additions & 1 deletion lib/Db/FormMapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ public function __construct(
parent::__construct($db, 'forms_v2_forms', Form::class);
}


/**
* @param Entity $entity
* @psalm-param Form $entity
Expand Down
1 change: 1 addition & 0 deletions lib/Exception/NoSuchFormException.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Exception;

use OCP\AppFramework\Http;
Expand Down
1 change: 1 addition & 0 deletions lib/Middleware/ThrottleFormAccessMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Middleware;

use Exception;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version010102Date20200323120846.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 0 additions & 1 deletion lib/Migration/Version010200Date20200323141300.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
use OCP\DB\Types;
use OCP\IDBConnection;
use OCP\Migration\IOutput;

use OCP\Migration\SimpleMigrationStep;

/**
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version020200Date20210120082018.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version020202Date20210311150843.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version020300Date20210406114130.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version020300Date20210406133704.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
* SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version030000Date20220402151229.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version030000Date20220414203511.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version030000Date20220705192811.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version030000Date20220707130109.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 1 addition & 0 deletions lib/Migration/Version030000Date20220831195000.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Forms\Migration;

use Closure;
Expand Down
1 change: 0 additions & 1 deletion lib/Service/CirclesService.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

declare(strict_types=1);


namespace OCA\Forms\Service;

use OCA\Circles\CirclesManager;
Expand Down
1 change: 0 additions & 1 deletion lib/Service/ConfigService.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
namespace OCA\Forms\Service;

use OCA\Forms\Constants;

use OCP\AppFramework\Services\IAppConfig;
use OCP\IConfig;
use OCP\IGroup;
Expand Down
5 changes: 0 additions & 5 deletions lib/Service/SubmissionService.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,8 @@

use DateTime;
use DateTimeZone;

use OCA\Forms\Constants;
use OCA\Forms\Db\Answer;

use OCA\Forms\Db\AnswerMapper;
use OCA\Forms\Db\Form;
use OCA\Forms\Db\Option;
Expand All @@ -28,20 +26,17 @@
use OCP\Files\IRootFolder;
use OCP\Files\NotPermittedException;
use OCP\IConfig;

use OCP\IL10N;
use OCP\ITempManager;
use OCP\IURLGenerator;
use OCP\IUser;
use OCP\IUserManager;
use OCP\IUserSession;
use OCP\Mail\IMailer;

use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
use PhpOffice\PhpSpreadsheet\Worksheet\Worksheet;
use PhpOffice\PhpSpreadsheet\Writer\Csv;

use Psr\Log\LoggerInterface;

/**
Expand Down
Loading
Loading