diff --git a/views/index.ejs b/views/index.ejs index 742a946..de37982 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -328,19 +328,18 @@ <% entries.forEach(e => { %> - - <%= e.value_cidr %> + + <%= e.value_cidr %><% if (e.deleted_at) { %> удалена<% } %> <%= e.comment || '—' %> <%= e.created_by %> <%= new Date(e.created_at).toLocaleDateString('ru', {day:'numeric',month:'short',year:'numeric',hour:'2-digit',minute:'2-digit',timeZone:'Etc/GMT-4'}) %> - <%= e.updated_at ? new Date(e.updated_at).toLocaleDateString('ru', {day:'numeric',month:'short',hour:'2-digit',minute:'2-digit',timeZone:'Etc/GMT-4'}) : '—' %> - <% + <% if (!e.deleted_at) { %> // data-* атрибуты для JS-заполнения modal без inline-onclick с параметрами. // Так как комментарий может содержать кавычки — EJS экранирует их в HTML. // Но в data-атрибуте JSON::stringify безопаснее. @@ -364,6 +363,7 @@ + <% } %> <% }) %>