diff --git a/index.html b/index.html
index 417a16c..8ad9ba8 100644
--- a/index.html
+++ b/index.html
@@ -160,7 +160,7 @@
Schedule
- Здесь будет отображаться график встреч
+
diff --git a/script.js b/script.js
index dc1d747..6fcbcf5 100644
--- a/script.js
+++ b/script.js
@@ -122,6 +122,7 @@ function setupCalendar() {
// ---- Рендер ----
function renderBoard(key) {
+ if (key === "gdplan") renderSchedule();
const list = document.getElementById("list-" + key);
if (!list) return;
let items = state[key] || [];
@@ -172,12 +173,23 @@ function renderBoard(key) {
`).join("");
}
-function renderSchedule(){
- const placeholder=$1('#schedule-placeholder');
- if(!placeholder) return;
- if(!state.gdplan.length){placeholder.innerHTML='Нет запланированных встреч
';return;}
- const items=state.gdplan.slice().sort((a,b)=>{const ta=a.time||'99:99',tb=b.time||'99:99';return ta.localeCompare(tb);});
- placeholder.innerHTML=items.map(t=>`${escapeHtml(t.time||'')} ${escapeHtml(t.text)}
`).join('');
+function renderSchedule() {
+ const placeholder = $1("#schedule-placeholder");
+ if (!placeholder) return;
+ if (!state.gdplan.length) {
+ placeholder.innerHTML = 'Нет запланированных встреч
';
+ return;
+ }
+ const items = state.gdplan.slice().sort((a, b) =>
+ (a.due || "9999-99-99").localeCompare(b.due || "9999-99-99") ||
+ (a.time || "99:99").localeCompare(b.time || "99:99")
+ );
+ placeholder.innerHTML = items.map(t => `
+
+ ${escapeHtml(fmtDateShort(t.due))}
+ ${escapeHtml(t.time || "—")}
+ ${escapeHtml(t.text)}
+
`).join("");
}
function renderNews() {
const list = document.getElementById("list-news");