Widget: DCTList: Difference between revisions
From LINKS Community Center
Eschmidt (talk | contribs) No edit summary |
Eschmidt (talk | contribs) No edit summary |
||
Line 124: | Line 124: | ||
let table; | let table; | ||
const FN_SEARCH = 'Search | const FN_SEARCH = 'Search and Monitor'; | ||
const FN_POST = 'Post | const FN_POST = 'Post and Schedule'; | ||
const FN_ANALYSIS = 'Analysis'; | const FN_ANALYSIS = 'Analysis'; | ||
const FN_METRICS = 'Metrics'; | const FN_METRICS = 'Metrics'; | ||
Line 180: | Line 180: | ||
/** @type Map<string, { [DESC_KEY]: string, [FUNC_KEY]: string[] } */ | /** @type Map<string, { [DESC_KEY]: string, [FUNC_KEY]: string[] } */ | ||
const functionsData = new Map(); | const functionsData = new Map(); | ||
const functionsQuery = '[[Category:Function_category]]' + | const functionsQuery = '[[Category:Function_category]]' + | ||
Line 196: | Line 191: | ||
const functionCategory = functionsQueryResults[key]; | const functionCategory = functionsQueryResults[key]; | ||
functionsData.set( | functionsData.set( | ||
removePrefix(functionCategory.fulltext), | removePrefix(functionCategory.fulltext), | ||
{ | { | ||
[DESC_KEY]: functionCategory.printouts[DESC_KEY][0], | [DESC_KEY]: functionCategory.printouts[DESC_KEY][0], | ||
Line 216: | Line 209: | ||
const dctResponse = await fetch(getQueryUrl(dctQuery)).then(response => response.json()); | const dctResponse = await fetch(getQueryUrl(dctQuery)).then(response => response.json()); | ||
const dctList = Object.keys(dctResponse.query.results).map(dctKey => { | const dctList = Object.keys(dctResponse.query.results).map(dctKey => { | ||
const dctResult = dctResponse.query.results[dctKey]; | const dctResult = dctResponse.query.results[dctKey]; | ||
Line 235: | Line 227: | ||
} | } | ||
}); | }); | ||
return dct; | return dct; |
Revision as of 15:11, 30 August 2022
Development verstion of the DCT List.
Not ready for production!