Checkpoint to get cypress working - auth-type from backend, less hard-coded auth0, improvements on query screen (less redundant fetches)

This commit is contained in:
2022-11-15 16:42:54 -06:00
parent c5780df58e
commit 94002f0d16
21 changed files with 2236939 additions and 344 deletions

View File

@ -32,6 +32,7 @@ class QClient
private static handleException(exception: QException)
{
// todo - check for 401 and clear cookie et al & logout?
console.log(`Caught Exception: ${JSON.stringify(exception)}`);
throw (exception);
}

View File

@ -32,30 +32,36 @@ class QProcessUtils
public static getProcessesForTable(metaData: QInstance, tableName: string, includeHidden = false): QProcessMetaData[]
{
const matchingProcesses: QProcessMetaData[] = [];
const processKeys = [...metaData.processes.keys()];
processKeys.forEach((key) =>
if (metaData.processes)
{
const process = metaData.processes.get(key);
if (process.tableName === tableName && (includeHidden || !process.isHidden))
const processKeys = [...metaData.processes.keys()];
processKeys.forEach((key) =>
{
matchingProcesses.push(process);
}
});
const process = metaData.processes.get(key);
if (process.tableName === tableName && (includeHidden || !process.isHidden))
{
matchingProcesses.push(process);
}
});
}
return matchingProcesses;
}
public static getReportsForTable(metaData: QInstance, tableName: string, includeHidden = false): QReportMetaData[]
{
const matchingReports: QReportMetaData[] = [];
const reportKeys = [...metaData.reports.keys()];
reportKeys.forEach((key) =>
if (metaData.reports)
{
const process = metaData.reports.get(key);
if (process.tableName === tableName)
const reportKeys = [...metaData.reports.keys()];
reportKeys.forEach((key) =>
{
matchingReports.push(process);
}
});
const process = metaData.reports.get(key);
if (process.tableName === tableName)
{
matchingReports.push(process);
}
});
}
return matchingReports;
}