This commit is contained in:
@@ -583,32 +583,8 @@ export default {
|
||||
|
||||
const toPath = vm.$route.params.topath; //set in app.vue::mounted
|
||||
if (toPath != undefined) {
|
||||
//check if it's an open report link and if so
|
||||
//trigger that to open in a new window and continue on to normal home page
|
||||
if (toPath.startsWith("/xxxxxxxxviewreport")) {
|
||||
(async function() {
|
||||
//open report links have a query string /viewreport?oid=[objectid]&rid=[reportid]
|
||||
const searchParams = new URLSearchParams(vm.$route.params.search);
|
||||
//const objectId = parseInt(searchParams.get("oid"));
|
||||
const reportId = parseInt(searchParams.get("rid"));
|
||||
//await window.$gz.api.renderReport(objectId, reportId); //objectid,reportid
|
||||
|
||||
const reportDataOptions = {
|
||||
ReportId: reportId,
|
||||
SelectedRowIds: [parseInt(searchParams.get("oid"))],
|
||||
ClientMeta: window.$gz.api.reportClientMetaData()
|
||||
};
|
||||
try {
|
||||
await vm.$refs.reportSelector.open(reportDataOptions, reportId);
|
||||
} catch (ex) {
|
||||
window.$gz.errorHandler.handleFormError(ex, vm);
|
||||
}
|
||||
})();
|
||||
vm.$router.push(vm.$store.state.homePage);
|
||||
} else {
|
||||
//otherwise open the url indicated
|
||||
vm.$router.push(vm.$route.params.topath);
|
||||
}
|
||||
//open the url indicated
|
||||
vm.$router.push(vm.$route.params.topath);
|
||||
} else {
|
||||
vm.$router.push(vm.$store.state.homePage);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user