Make wish priorities translateable
This commit is contained in:
parent
7418c6ff9e
commit
719b11aa59
2 changed files with 31 additions and 21 deletions
19
index.php
19
index.php
|
@ -72,13 +72,6 @@ setcookie(
|
|||
$session['httponly']
|
||||
);
|
||||
|
||||
/**
|
||||
* API
|
||||
*/
|
||||
if (isset($api)) {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Language
|
||||
*/
|
||||
|
@ -105,6 +98,18 @@ if (file_exists($translationFilepath)) {
|
|||
$translations = $loader->loadFile($translationFilepath);
|
||||
}
|
||||
|
||||
/**
|
||||
* Wish
|
||||
*/
|
||||
wishthis\Wish::initialize();
|
||||
|
||||
/**
|
||||
* API
|
||||
*/
|
||||
if (isset($api)) {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Install
|
||||
*/
|
||||
|
|
|
@ -13,20 +13,25 @@ class Wish
|
|||
/**
|
||||
* Static
|
||||
*/
|
||||
public static array $priorities = array(
|
||||
public static array $priorities;
|
||||
|
||||
public static function initialize()
|
||||
{
|
||||
self::$priorities = array(
|
||||
'' => array(
|
||||
'name' => 'Default',
|
||||
'name' => __('Default'),
|
||||
'color' => '',
|
||||
),
|
||||
'1' => array(
|
||||
'name' => 'Nice to have',
|
||||
'name' => __('Nice to have'),
|
||||
'color' => 'black',
|
||||
),
|
||||
'3' => array(
|
||||
'name' => 'Would love it',
|
||||
'name' => __('Would love it'),
|
||||
'color' => 'orange',
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Non-Static
|
||||
|
|
Loading…
Reference in a new issue