Skip to content

[stable30] feat: add group activity #4792

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 7, 2025
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
2 changes: 1 addition & 1 deletion appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Developed with ❤️ by [LibreCode](https://librecode.coop). Help us transform
</settings>
<activity>
<settings>
<setting>OCA\Libresign\Activity\FileToSign</setting>
<setting>OCA\Libresign\Activity\Settings\FileToSign</setting>
</settings>
<filters>
<filter>OCA\Libresign\Activity\Filter</filter>
Expand Down
34 changes: 34 additions & 0 deletions lib/Activity/Settings/FileToSign.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?php

declare(strict_types=1);
/**
* SPDX-FileCopyrightText: 2025 LibreCode coop and contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Libresign\Activity\Settings;

use OCP\IL10N;

class FileToSign extends LibresignActivitySettings {
public function __construct(
protected IL10N $l,
) {
}

/**
* @return string Lowercase a-z and underscore only identifier. The type of table activity
* @since 20.0.0
*/
public function getIdentifier(): string {
return 'file_to_sign';
}

/**
* @return string A translated string
* @since 11.0.0
*/
public function getName(): string {
return $this->l->t('You have a <strong>file to sign</strong>');
}
}
Original file line number Diff line number Diff line change
@@ -1,50 +1,29 @@
<?php

declare(strict_types=1);

/**
* SPDX-FileCopyrightText: 2020-2024 LibreCode coop and contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

namespace OCA\Libresign\Activity;
namespace OCA\Libresign\Activity\Settings;

use OCP\Activity\ActivitySettings;
use OCP\IL10N;

class FileToSign extends ActivitySettings {
public function __construct(
protected IL10N $l,
) {
}

/**
* @return string Lowercase a-z and underscore only identifier. The type of table activity
* @since 20.0.0
*/
public function getIdentifier(): string {
return 'file_to_sign';
}

/**
* @return string A translated string
* @since 11.0.0
*/
public function getName(): string {
return $this->l->t('You have a <strong>file to sign</strong>');
}
abstract class LibresignActivitySettings extends ActivitySettings {

/**
* {@inheritdoc}
*/
public function getGroupIdentifier(): string {
return 'other';
public function getGroupIdentifier() {
return 'libresign';
}

/**
* {@inheritdoc}
*/
public function getGroupName(): string {
return $this->l->t('Other activities');
public function getGroupName() {
return 'LibreSign';
}

/**
Expand Down
Loading