-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathModule.php
More file actions
executable file
·50 lines (37 loc) · 966 Bytes
/
Module.php
File metadata and controls
executable file
·50 lines (37 loc) · 966 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
namespace humhub\modules\mailinglists;
use yii\base\Event;
use yii\helpers\Url;
use humhub\modules\content\components\ContentContainerModule;
use humhub\modules\content\components\ContentContainerActiveRecord;
use humhub\modules\space\models\Space;
class Module extends ContentContainerModule
{
public function init()
{
parent::init();
}
/**
* @inheritdoc
*/
public function getConfigUrl()
{
return Url::to(['/mailinglists/admin']);
}
public function getContentContainerTypes()
{
return [
Space::className(),
];
}
public function getContentContainerName(ContentContainerActiveRecord $container)
{
return "Mailing-List";
}
public function getContentContainerDescription(ContentContainerActiveRecord $container)
{
if ($container instanceof Space) {
return "Mailing-list to space members";
}
}
}