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 |
class CTasks { //Task statuses: 1 - New, 2 - Pending, 3 - In Progress, 4 - Supposedly completed, 5 - Completed, 6 - Deferred, 7 - Declined const METASTATE_VIRGIN_NEW = -2; const METASTATE_EXPIRED = -1; const STATE_NEW = 1; const STATE_PENDING = 2; // Pending === Accepted const STATE_IN_PROGRESS = 3; const STATE_SUPPOSEDLY_COMPLETED = 4; const STATE_COMPLETED = 5; const STATE_DEFERRED = 6; const STATE_DECLINED = 7; const PRIORITY_LOW = 0; const PRIORITY_AVERAGE = 1; const PRIORITY_HIGH = 2; final class CTaskItem implements CTaskItemInterface { // Actions const ACTION_ACCEPT = 0x01; const ACTION_DECLINE = 0x02; const ACTION_COMPLETE = 0x03; const ACTION_APPROVE = 0x04; // closes task const ACTION_DISAPPROVE = 0x05; // perform ACTION_RENEW const ACTION_START = 0x06; const ACTION_DELEGATE = 0x07; const ACTION_REMOVE = 0x08; const ACTION_EDIT = 0x09; const ACTION_DEFER = 0x0A; const ACTION_RENEW = 0x0B; // switch tasks to new or accepted state (depends on subordination) const ACTION_CREATE = 0x0C; const ACTION_CHANGE_DEADLINE = 0x0D; const ACTION_CHECKLIST_ADD_ITEMS = 0x0E; const ACTION_ELAPSED_TIME_ADD = 0x0F; const ACTION_CHANGE_DIRECTOR = 0x10; const ACTION_PAUSE = 0x11; const ACTION_START_TIME_TRACKING = 0x12; // Roles implemented for managers of users too. // So, if some user is responsible in the task, than his manager has responsible role too. const ROLE_NOT_A_MEMBER = 0x01; // not a member of the task const ROLE_DIRECTOR = 0x02; const ROLE_RESPONSIBLE = 0x04; const ROLE_ACCOMPLICE = 0x08; const ROLE_AUDITOR = 0x10; const DESCR_FORMAT_RAW = 0x01; // give description of task "as is" (HTML or BB-code, depends on task) const DESCR_FORMAT_HTML = 0x02; // always return HTML (even if task in BB-code) const DESCR_FORMAT_PLAIN_TEXT = 0x03; // always return plain text (all HTML/BBCODE tags are stripped) |
Месяц: Сентябрь 2015
Установить значение счетчика бизнес-процессов в Битрикс24
Вручную:
1 |
CUserCounter::Set(1, "bp_tasks", 1, "**"); |
Автоматически в соответствии с количеством задач БП:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
$targetUserId = 2748; CModule::IncludeModule('bizproc'); $currentCounter = (int)CUserCounter::GetValue($targetUserId, 'bp_tasks', '**'); $arBizprocCounter = CBPTaskService::getCounters($targetUserId); if (isset($currentCounter) && $currentCounter != $arBizprocCounter['*']) { echo 'Счетчик неверный: ' . $arBizprocCounter['*'] . ' != ' . $currentCounter . '<br>'; CUserCounter::Set($targetUserId, 'bp_tasks', $arBizprocCounter['*'], '**'); echo 'Установлено новое значение: ' . (int)CUserCounter::GetValue($targetUserId, 'bp_tasks', '**') . '<br>'; } else { echo 'Счетчик корректен: ' . $arBizprocCounter['*'] . ' = ' . $currentCounter . '<br>'; } |
Изменить раскладку клавиатуры по сочетанию Ctrl-Shift в Gnome
Запустить из терминала:
1 |
gnome-tweak-tool |
Выбираем «Typing», «Switching to another layout», «Left Ctrl + Left Shift».