meraproject/themes/merakomis/project/structure/eStatus.php
keboss-m 5c21d25d45 Initial commit: Merakomis portal, Docker stack and user-reader API.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-24 11:04:05 +03:00

37 lines
784 B
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
namespace themes\merakomis\project\structure;
class eStatus {
const NONE = 0;
const WORKING = 1;
const FINISH = 2;
const PAUSE = 3;
static $arr;
static function getArray(){
return self::$arr ? : self::$arr = [
self::NONE => ['n'=>'Не определён'],
self::WORKING => ['n'=>'В работе'],
self::FINISH => ['n'=>'Завершён'],
self::PAUSE => ['n'=>'Пауза'],
];
}
static function getName($x){
return self::getArray()[$x]['n'];
}
static function getNameList(){
$res = [];
$a = self::getArray();
foreach ($a as $k=>$v){
$res[] = ['id'=>$k,'title'=>$v['n']];
}
return $res;
}
}