Skip to content

Commit

Permalink
EZP-31412: use timezone helper for date
Browse files Browse the repository at this point in the history
  • Loading branch information
Michał Grabowski committed Mar 25, 2020
1 parent 227e5ab commit 6661ab8
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@
};
const renderRow = (item, index) => {
const { escapeHTML } = eZ.helpers.text;
const { formatShortDateTime } = eZ.helpers.timezone;
const contentTypeName = eZ.helpers.contentType.getContentTypeName(item.ContentInfo.Content.ContentTypeInfo.identifier);
const contentName = escapeHTML(item.ContentInfo.Content.TranslatedName);
const contentId = escapeHTML(item.ContentInfo.Content._id);
Expand All @@ -149,7 +150,7 @@
<td><input type="checkbox" value="${contentId}" /></td>
<td class="ez-relations__item-name">${contentName}</td>
<td>${contentTypeName}</td>
<td>${new Date(item.ContentInfo.Content.publishedDate).toLocaleString()}</td>
<td>${formatShortDateTime(item.ContentInfo.Content.publishedDate)}</td>
<td colspan="2"><input class="ez-relations__order-input" type="number" value="${selectedItems.length +
index +
1}" /></td>
Expand Down

0 comments on commit 6661ab8

Please # to comment.