Widget: DCTList: Difference between revisions
From LINKS Community Center
Eschmidt (talk | contribs) No edit summary |
Eschmidt (talk | contribs) No edit summary |
||
Line 371: | Line 371: | ||
*/ | */ | ||
function dctFilter(dct, filterState) { | function dctFilter(dct, filterState) { | ||
// If filtering property is empty, don't apply the filter (set the check to true). | // If filtering property is empty, don't apply the filter (set the check to true). | ||
// Passing an empty object (as with applyFilters(true)) should result in an unfiltered table. | // Passing an empty object (as with applyFilters(true)) should result in an unfiltered table. | ||
Line 472: | Line 471: | ||
'<label for="filter-' + identifier + '"><img src="' + curr.image + '"> ' + curr.name + '</label></div>' | '<label for="filter-' + identifier + '"><img src="' + curr.image + '"> ' + curr.name + '</label></div>' | ||
}, ''); | }, ''); | ||
}) | }); | ||
document.getElementById('data-source-filter').innerHTML = dataSourceFilterHtml; | document.getElementById('data-source-filter').innerHTML = dataSourceFilterHtml; | ||
Line 511: | Line 510: | ||
const dct = cell.getData(); | const dct = cell.getData(); | ||
let out = '<a href="' + dct.url + '">' + dct.name + '</a><br>'; | let out = '<a href="' + dct.url + '">' + dct.name + '</a><br>'; | ||
if (dct.businessModel.includes( | if (dct.businessModel.includes(FREE_KEY)) { | ||
out += '<small><span class="badge badge-success">Freeware</span></small> '; | out += '<small><span class="badge badge-success">Freeware</span></small> '; | ||
} | } | ||
if (dct.businessModel.includes( | if (dct.businessModel.includes(FREE_PLAN_KEY)) { | ||
out += '<small><span class="badge badge-success">Free plan</span></small> '; | out += '<small><span class="badge badge-success">Free plan</span></small> '; | ||
} | } |
Revision as of 10:57, 28 September 2022
Development verstion of the DCT List.
Not ready for production!