исправил индикацию активной строки
This commit is contained in:
@@ -241,7 +241,7 @@ if (typeof window.administrators !== "function") {
|
||||
// Инициализация буфера списка классов
|
||||
// const buffer = [...row.classList];
|
||||
|
||||
// Инициализация статуса активной строки
|
||||
// Инициализация статуса активной строки
|
||||
const selected = row.getAttribute("data-selected");
|
||||
|
||||
// Реинициализация строки
|
||||
@@ -252,9 +252,11 @@ if (typeof window.administrators !== "function") {
|
||||
|
||||
// Копирование классов из буфера классов удалённой строки
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (
|
||||
@@ -278,6 +280,9 @@ if (typeof window.administrators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -1034,6 +1039,9 @@ if (typeof window.administrators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Реинициализация строк
|
||||
@@ -1468,6 +1476,9 @@ if (typeof window.administrators !== "function") {
|
||||
// Удаление всплывающего окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
|
||||
// Деинициализация быстрых действий по кнопкам
|
||||
document.removeEventListener("keydown", this.buttons);
|
||||
|
||||
@@ -1720,6 +1731,9 @@ if (typeof window.administrators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -2069,7 +2083,7 @@ if (typeof window.administrators !== "function") {
|
||||
return list.childElementCount === 0 ? false : true;
|
||||
}
|
||||
|
||||
return false;
|
||||
return false;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@@ -308,6 +308,9 @@ if (typeof window.markets !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Реинициализация строк
|
||||
@@ -1158,6 +1161,9 @@ if (typeof window.markets !== "function") {
|
||||
// Удаление всплывающего окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
|
||||
// Деинициализация быстрых действий по кнопкам
|
||||
document.removeEventListener("keydown", this.buttons);
|
||||
|
||||
@@ -1662,7 +1668,9 @@ if (typeof window.markets !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.body.wrap instanceof HTMLElement) {
|
||||
@@ -1676,6 +1684,9 @@ if (typeof window.markets !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -2485,7 +2496,9 @@ if (typeof window.markets !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (
|
||||
@@ -2509,6 +2522,9 @@ if (typeof window.markets !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.core.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -3279,6 +3295,9 @@ if (typeof window.markets !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.core.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@@ -241,7 +241,7 @@ if (typeof window.operators !== "function") {
|
||||
// Инициализация буфера списка классов
|
||||
// const buffer = [...row.classList];
|
||||
|
||||
// Инициализация статуса активной строки
|
||||
// Инициализация статуса активной строки
|
||||
const selected = row.getAttribute("data-selected");
|
||||
|
||||
// Реинициализация строки
|
||||
@@ -252,9 +252,11 @@ if (typeof window.operators !== "function") {
|
||||
|
||||
// Копирование классов из буфера классов удалённой строки
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (
|
||||
@@ -278,6 +280,9 @@ if (typeof window.operators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -1034,6 +1039,9 @@ if (typeof window.operators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Реинициализация строк
|
||||
@@ -1468,6 +1476,9 @@ if (typeof window.operators !== "function") {
|
||||
// Удаление всплывающего окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
|
||||
// Деинициализация быстрых действий по кнопкам
|
||||
document.removeEventListener("keydown", this.buttons);
|
||||
|
||||
@@ -1720,6 +1731,9 @@ if (typeof window.operators !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -2069,7 +2083,7 @@ if (typeof window.operators !== "function") {
|
||||
return list.childElementCount === 0 ? false : true;
|
||||
}
|
||||
|
||||
return false;
|
||||
return false;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@@ -150,6 +150,9 @@ if (typeof window.tasks !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Реинициализация строк
|
||||
@@ -442,6 +445,9 @@ if (typeof window.tasks !== "function") {
|
||||
// Удаление всплывающего окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
|
||||
// Деинициализация быстрых действий по кнопкам
|
||||
document.removeEventListener("keydown", this.buttons);
|
||||
|
||||
@@ -1690,7 +1696,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
if (data.confirmed) {
|
||||
// Подтверждена заявка
|
||||
@@ -2138,7 +2146,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
if (data.problematic) {
|
||||
// Проблемная заявка
|
||||
@@ -2163,6 +2173,9 @@ if (typeof window.tasks !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -2290,7 +2303,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
if (data.completed) {
|
||||
// Завершена заявка
|
||||
@@ -2315,6 +2330,9 @@ if (typeof window.tasks !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -2370,7 +2388,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
if (data.hided) {
|
||||
// Скрыта заявка
|
||||
@@ -2464,6 +2484,9 @@ if (typeof window.tasks !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Удаление строки
|
||||
@@ -2605,7 +2628,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.body.wrap instanceof HTMLElement) {
|
||||
@@ -2715,7 +2740,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
if (this.body.wrap instanceof HTMLElement) {
|
||||
// Найдено активное окно
|
||||
@@ -3766,7 +3793,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.core.body.wrap instanceof HTMLElement) {
|
||||
@@ -3864,7 +3893,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.core.body.wrap instanceof HTMLElement) {
|
||||
@@ -3965,7 +3996,9 @@ if (typeof window.tasks !== "function") {
|
||||
row.classList.add("published");
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
// Запись текста состояния кнопки
|
||||
button.innerText = "Снять с публикации";
|
||||
@@ -4083,7 +4116,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.remove("published");
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
|
||||
// Запись текста состояния кнопки
|
||||
button.innerText = "Опубликовать";
|
||||
@@ -4901,7 +4936,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.core.body.wrap instanceof HTMLElement) {
|
||||
@@ -4999,7 +5036,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.core.body.wrap instanceof HTMLElement) {
|
||||
@@ -5378,7 +5417,9 @@ if (typeof window.tasks !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
} else {
|
||||
// Не записано новое значение в базу данных
|
||||
|
||||
@@ -5470,7 +5511,9 @@ if (typeof window.tasks !== "function") {
|
||||
row = document.getElementById(id);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (
|
||||
typeof selected === "string" && selected === "true"
|
||||
) row.setAttribute("data-selected", "true");
|
||||
|
||||
// Если непрочитанных сообщений стало больше, то проиграть звук уведомления
|
||||
if (row.lastElementChild.innerText > messages) {
|
||||
|
@@ -364,6 +364,9 @@ if (typeof window.workers !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
|
||||
// Реинициализация строк
|
||||
@@ -1488,6 +1491,9 @@ if (typeof window.workers !== "function") {
|
||||
// Удаление всплывающего окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
|
||||
// Деинициализация быстрых действий по кнопкам
|
||||
document.removeEventListener("keydown", this.buttons);
|
||||
|
||||
@@ -2047,7 +2053,9 @@ if (typeof window.workers !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (this.body.wrap instanceof HTMLElement) {
|
||||
@@ -2061,6 +2069,9 @@ if (typeof window.workers !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -3214,6 +3225,9 @@ if (typeof window.workers !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.core.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -3371,7 +3385,9 @@ if (typeof window.workers !== "function") {
|
||||
// row.classList.add(...buffer);
|
||||
|
||||
// Копирование статуса активной строки
|
||||
if (typeof selected === "string" && selected === "true") row.setAttribute("data-selected", "true");
|
||||
if (typeof selected === "string" && selected === "true") {
|
||||
row.setAttribute("data-selected", "true");
|
||||
}
|
||||
}
|
||||
|
||||
if (
|
||||
@@ -3395,6 +3411,9 @@ if (typeof window.workers !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.core.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -4165,6 +4184,9 @@ if (typeof window.workers !== "function") {
|
||||
|
||||
// Деинициализация активного окна
|
||||
this.core.body.wrap.remove();
|
||||
|
||||
// Удаление статуса активной строки
|
||||
row.removeAttribute("data-selected");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user