-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPlugin.php
executable file
·51 lines (38 loc) · 1.32 KB
/
Plugin.php
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
49
50
51
<?php
namespace Kanboard\Plugin\Seven;
use Kanboard\Core\Plugin\Base;
use Kanboard\Core\Translator;
class Plugin extends Base {
public function initialize(): void {
$this->container['seven'] = static function ($container) {
return new Seven($container);
};
$this->authenticationManager->register(new SmsAuth($this->container));
$hooks = [
'template:config:integrations' => 'Seven:config/integration',
'template:user:integrations' => 'Seven:user/integration',
];
foreach ($hooks as $k => $v) $this->template->hook->attach($k, $v);
}
public function onStartup() {
Translator::load($this->languageModel->getCurrentLanguage(), __DIR__ . '/Locale');
}
public function getPluginName(): string {
return 'seven';
}
public function getPluginDescription(): string {
return t('Use SMS for two-factor authentication');
}
public function getPluginAuthor(): string {
return 'seven communications GmbH & Co. KG';
}
public function getPluginVersion(): string {
return '1.0.0';
}
public function getPluginHomepage(): string {
return 'https://github.com/seven-io/kanboard';
}
public function getCompatibleVersion(): string {
return '>=1.2.13';
}
}