diff --git a/index.html b/index.html
index 5648ae3..2f08b7b 100644
--- a/index.html
+++ b/index.html
@@ -1,5 +1,5 @@
-
+
@@ -22,8 +22,10 @@ 7th Heaven Catalogs
+ |
Name |
Description |
+ Release Date |
Version |
Link |
@@ -43,7 +45,7 @@ 7th Heaven Catalogs
];
function parseLink(url) {
- var match = url.match(/iros:\/\/([a-zA-Z]+)\//);
+ const match = url.match(/iros:\/\/([a-zA-Z]+)\//);
url = url.replace(match[0], '');
@@ -58,6 +60,10 @@ 7th Heaven Catalogs
}
}
+ function parseDate(date) {
+ return date.replace(/T.+/, '')
+ }
+
function fetchAndParseXML(url) {
return $.ajax({
url: url,
@@ -70,12 +76,14 @@ 7th Heaven Catalogs
$(data).find('Mod').each(function() {
const name = $(this).find('Name').text();
const description = $(this).find('Description').text();
+ const releaseDate = $(this).find('ReleaseDate').text();
const version = $(this).find('Version').text();
+ const image = $(this).find('PreviewImage').text();
const links = [];
$(this).find('LatestVersion > Link').each(function() {
links.push($(this).text());
});
- items.push({ name, description, version, links });
+ items.push({ image, name, description, releaseDate, version, links });
});
return items;
}
@@ -85,14 +93,20 @@ 7th Heaven Catalogs
data.forEach(item => {
const linksHtml = item.links.map((link, idx) => `Mirror ${idx + 1}`).join('
');
const row = `
+ |
${item.name} |
${item.description} |
+ ${parseDate(item.releaseDate)} |
${item.version} |
${linksHtml} |
`;
tableBody.append(row);
});
$('#catalog').DataTable({
+ order: [
+ [3, 'desc'],
+ [1, 'asc']
+ ],
pageLength: 25,
responsive: true
});