This commit is contained in:
@@ -157,8 +157,8 @@ export default {
|
||||
window.$gz.eventBus.$on("menu-click", clickHandler);
|
||||
|
||||
//route params MUST have source data
|
||||
if (!vm.$route.params.sourceData) {
|
||||
throw "ay-report-edit::created - missing sourceData route parameter";
|
||||
if (!vm.$route.params.reportDataOptions) {
|
||||
throw "ay-report-edit::created - missing reportDataOptions route parameter";
|
||||
}
|
||||
|
||||
//id 0 means create a new record don't load one
|
||||
@@ -766,22 +766,22 @@ async function fetchTranslatedText(vm) {
|
||||
////////////////////
|
||||
//
|
||||
async function fetchReportData(vm) {
|
||||
let sourceData = vm.$route.params.sourceData;
|
||||
let reportDataOptions = vm.$route.params.reportDataOptions;
|
||||
vm.obj.objectType = vm.$route.params.ayaType;
|
||||
if (!sourceData) {
|
||||
throw "ay-report-edit:fetchReportData - route parameter sourceData is missing or empty, unable to init report designer";
|
||||
if (!reportDataOptions) {
|
||||
throw "ay-report-edit:fetchReportData - route parameter reportDataOptions is missing or empty, unable to init report designer";
|
||||
}
|
||||
if (vm.obj.objectType == null) {
|
||||
throw "ay-report-edit:fetchReportData - route parameter ayaType is missing or empty, unable to init report designer";
|
||||
}
|
||||
/* public class ObjectReportDataParameter
|
||||
{
|
||||
public AyaType ObjectType { get; set; }
|
||||
public long[] ObjectIdArray { get; set; }
|
||||
} */
|
||||
/* public AyaType ObjectType { get; set; }
|
||||
public long[] SelectedRowIds { get; set; }
|
||||
public string DataListKey { get; set; }
|
||||
public string ListView { get; set; }//optional, if null or empty will use default list view built into DataList
|
||||
*/
|
||||
let res = await window.$gz.api.upsert("report/object-report-data", {
|
||||
ObjectType: vm.obj.objectType,
|
||||
ObjectIdArray: sourceData
|
||||
ObjectIdArray: reportDataOptions
|
||||
});
|
||||
//We never expect there to be no data here
|
||||
if (!res.hasOwnProperty("data")) {
|
||||
|
||||
@@ -80,7 +80,7 @@ async function clickHandler(menuItem) {
|
||||
|
||||
let res = await m.vm.$refs.reportSelector.open(
|
||||
window.$gz.type.Widget,
|
||||
m.vm.$refs.gzdatatable.getDataTableSourceOptions()
|
||||
m.vm.$refs.gzdatatable.getReportDataOptions()
|
||||
);
|
||||
|
||||
//if null for no selection
|
||||
|
||||
Reference in New Issue
Block a user