This commit is contained in:
@@ -3,16 +3,9 @@
|
||||
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
|
||||
|
||||
|
||||
todo: export from grid to xls, csv etc.
|
||||
I'm thinking perhaps also a secondary ability to make report templates that are actually intended for export to xls or whatever as an additional feature
|
||||
but the easiest thing for people would be a straight export of grid data from grid, perhaps using the reportdata system since it pulls in all the bits needed for full data rather than just id links
|
||||
https://www.npmjs.com/package/json-2-csv
|
||||
|
||||
todo: Is the report list filtered by roles? It should not present reports that a user is not permitted to use by role.
|
||||
probably need to post-process the report list or include the roles with it and then test them at the client before displaying or at the server before sending
|
||||
|
||||
todo: Add sanitize html for Marked markdown helper as in Wiki control
|
||||
|
||||
todo: what does jsreport do to sanitize / secure the generated templates?
|
||||
|
||||
TODO: Report confirmation checklist
|
||||
page breaks properly EXAMPLE NEEDED
|
||||
@@ -38,6 +31,13 @@ TODO: Report confirmation checklist
|
||||
|
||||
-------- NON REPORTING RELATED STUFF ---------------
|
||||
|
||||
todo: export from grid to xls, csv etc.
|
||||
I'm thinking perhaps also a secondary ability to make report templates that are actually intended for export to xls or whatever as an additional feature
|
||||
but the easiest thing for people would be a straight export of grid data from grid, perhaps using the reportdata system since it pulls in all the bits needed for full data rather than just id links
|
||||
https://www.npmjs.com/package/json-2-csv
|
||||
From extensions?
|
||||
(because it's a single or list thing)
|
||||
|
||||
todo: consider feature to set server to always use a pre-set browser locale settings and not the ones in the browse itself
|
||||
Scenario is user in another country but needs to login and work with central server?
|
||||
server - wide
|
||||
|
||||
@@ -87,16 +87,6 @@ export default {
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
public class RenderReportParameter
|
||||
{
|
||||
public long ReportId { 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
|
||||
public JToken ClientMeta {get;set;}//meta JSON data passed from client, not part of biz object data
|
||||
}
|
||||
*/
|
||||
let reportDataOptions = vm.reportDataOptions;
|
||||
if (!reportDataOptions) {
|
||||
throw "Missing report data unable to render report";
|
||||
@@ -104,15 +94,12 @@ export default {
|
||||
reportDataOptions.ReportId = reportId;
|
||||
//Meta data from client for use by report script
|
||||
reportDataOptions.ClientMeta = window.$gz.api.reportClientMetaData();
|
||||
|
||||
let url = "report/render";
|
||||
|
||||
let res = await window.$gz.api.upsert(url, reportDataOptions);
|
||||
if (res.error) {
|
||||
throw res.error;
|
||||
} else {
|
||||
let reportUrl = window.$gz.api.reportDownloadUrl(res.data);
|
||||
//console.log("Report url:", reportUrl);
|
||||
if (window.open(reportUrl, "Report") == null) {
|
||||
throw "Problem displaying report in new window. Browser must allow pop-ups to view reports; check your browser setting";
|
||||
}
|
||||
@@ -129,25 +116,11 @@ export default {
|
||||
throw "report-selector:Open - ObjectType is missing or empty";
|
||||
}
|
||||
|
||||
//source data object
|
||||
//either need to rehydrate or send as is if not selectedRowIds
|
||||
// {
|
||||
// ObjectType: ayaType,
|
||||
// selectedRowIds: selectedRowIds,
|
||||
// dataListKey: vm.dataListKey,
|
||||
// listView: untokenizeListView(vm.listView)
|
||||
// }
|
||||
|
||||
this.reportDataOptions = reportDataOptions;
|
||||
|
||||
//rights
|
||||
|
||||
//get report list from server
|
||||
|
||||
let res = await window.$gz.api.get(
|
||||
`report/list/${reportDataOptions.ObjectType}`
|
||||
);
|
||||
//console.log("report-selectr report list from server is: ", res);
|
||||
if (res.error) {
|
||||
throw res.error;
|
||||
} else {
|
||||
|
||||
@@ -356,7 +356,7 @@ Handlebars.registerHelper('loud', function (aString) {
|
||||
|
||||
//enable / disable RENDER button if it can be rendered (has data)
|
||||
if (this.reportData != null) {
|
||||
if (!val.dirty && val.valid) {
|
||||
if (!val.dirty) {//not disabling if invalid because that sometimes just means it needs to be re-run due to server error
|
||||
window.$gz.eventBus.$emit("menu-enable-item", FORM_KEY + ":render");
|
||||
} else {
|
||||
window.$gz.eventBus.$emit(
|
||||
|
||||
Reference in New Issue
Block a user