# -*- coding: utf-8 -*-
# hub/ticket/domain/ticket_constants.py

"""Константы доменной state-machine Ticket."""

STATE_TODO = 1
STATE_IN_PROGRESS = 2
STATE_CONFIRMATION = 3
STATE_COMPLETED = 0
STATE_REFUSED = 4
STATE_ARCHIVED = 5

HARDWARE_SIGNAL_ADVANCE = frozenset({0, 1, 2, 3})
HARDWARE_SIGNAL_INITIALIZE = 0xFF

TICKET_STATE_NAMES = {
    STATE_TODO: "К выполнению",
    STATE_IN_PROGRESS: "В работе",
    STATE_CONFIRMATION: "Подтверждение",
    STATE_COMPLETED: "Выполненные",
    STATE_REFUSED: "Отказ в обслуживании",
    STATE_ARCHIVED: "Архив",
}

TICKET_STATE_ACTIONS = {
    STATE_TODO: "Инженер направлен",
    STATE_IN_PROGRESS: "Выполняются работы",
    STATE_CONFIRMATION: "Ожидает подтверждения",
    STATE_COMPLETED: "Работа завершена",
    STATE_REFUSED: "Отказ в обслуживании",
    STATE_ARCHIVED: "Перемещено в архив",
}

TICKET_STATE_COLORS = {
    STATE_TODO: "#FF5938",
    STATE_IN_PROGRESS: "#008BFA",
    STATE_CONFIRMATION: "#FFD27A",
    STATE_COMPLETED: "#36AC87",
    STATE_REFUSED: "#D1D5DB",
    STATE_ARCHIVED: "#9CA3AF",
}
