api reporting stuff
This commit is contained in:
+80
-112
@@ -35,7 +35,8 @@ $.stretchyReporting.changeSeparator= function(sepChar, decChar, indFormat) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
function fnRecordsDisplay(){
|
function fnRecordsDisplay(){
|
||||||
//oSettings isn't defined when table first created but coding around to not call this method until after it is.
|
// oSettings isn't defined when table first created but coding around to not
|
||||||
|
// call this method until after it is.
|
||||||
// if (typeof(oSettings) != "undefined") return oSettings.fnRecordsDisplay()
|
// if (typeof(oSettings) != "undefined") return oSettings.fnRecordsDisplay()
|
||||||
// else return 0;
|
// else return 0;
|
||||||
return oSettings.fnRecordsDisplay();
|
return oSettings.fnRecordsDisplay();
|
||||||
@@ -671,8 +672,8 @@ setupReportListSuccess = function(data, textStatus, jqXHR){
|
|||||||
|
|
||||||
function copyXLSon() {
|
function copyXLSon() {
|
||||||
showMsg("Turning them on");
|
showMsg("Turning them on");
|
||||||
$('#ToolTables_MRPshowTable_0').css('display', 'inline');
|
$('#ToolTables_FRshowTable_0').css('display', 'inline');
|
||||||
$('#ToolTables_MRPshowTable_1').css('display', 'inline');
|
$('#ToolTables_FRshowTable_1').css('display', 'inline');
|
||||||
ttInstances = TableTools.fnGetMasters();
|
ttInstances = TableTools.fnGetMasters();
|
||||||
for (i in ttInstances) {
|
for (i in ttInstances) {
|
||||||
ttInstances[i].that.fnResizeButtons();
|
ttInstances[i].that.fnResizeButtons();
|
||||||
@@ -683,8 +684,8 @@ function copyXLSon() {
|
|||||||
|
|
||||||
function copyXLSoff() {
|
function copyXLSoff() {
|
||||||
showMsg("Turning them off");
|
showMsg("Turning them off");
|
||||||
$('#ToolTables_MRPshowTable_0').css('display', 'none');
|
$('#ToolTables_FRshowTable_0').css('display', 'none');
|
||||||
$('#ToolTables_MRPshowTable_1').css('display', 'none');
|
$('#ToolTables_FRshowTable_1').css('display', 'none');
|
||||||
filteredCopyXLSon = false;
|
filteredCopyXLSon = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -767,22 +768,22 @@ return 'var selectSuccess = function(data, textStatus,jqXHR){' +
|
|||||||
|
|
||||||
function createChart(theData) {
|
function createChart(theData) {
|
||||||
|
|
||||||
MRPData = new google.visualization.DataTable();
|
FRData = new google.visualization.DataTable();
|
||||||
MRPData.addColumn('string', dataTableDef.aoColumns[0].sTitle);
|
FRData.addColumn('string', dataTableDef.aoColumns[0].sTitle);
|
||||||
MRPData.addColumn('number', dataTableDef.aoColumns[1].sTitle);
|
FRData.addColumn('number', dataTableDef.aoColumns[1].sTitle);
|
||||||
MRPData.addRows(dataTableDef.aaData.length);
|
FRData.addRows(dataTableDef.aaData.length);
|
||||||
|
|
||||||
var ii = 0;
|
var ii = 0;
|
||||||
var numberData;
|
var numberData;
|
||||||
var dblQuotePos;
|
var dblQuotePos;
|
||||||
for (var i in dataTableDef.aaData)
|
for (var i in dataTableDef.aaData)
|
||||||
{
|
{
|
||||||
MRPData.setValue(ii, 0, dataTableDef.aaData[i][0]);
|
FRData.setValue(ii, 0, dataTableDef.aaData[i][0]);
|
||||||
|
|
||||||
if (dataTableDef.aoColumns[1].sType == "title-numeric" && dataTableDef.aaData[i][1].substr(0, 11) == '<span title') numberData = getOrigTitleNumericValue(dataTableDef.aaData[i][1])
|
if (dataTableDef.aoColumns[1].sType == "title-numeric" && dataTableDef.aaData[i][1].substr(0, 11) == '<span title') numberData = getOrigTitleNumericValue(dataTableDef.aaData[i][1])
|
||||||
else numberData = dataTableDef.aaData[i][1];
|
else numberData = dataTableDef.aaData[i][1];
|
||||||
|
|
||||||
MRPData.setValue(ii, 1, numberData);
|
FRData.setValue(ii, 1, numberData);
|
||||||
ii = ii + 1;
|
ii = ii + 1;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -888,8 +889,8 @@ function convertCRtoBR(str) {
|
|||||||
|
|
||||||
function showTableReport() {
|
function showTableReport() {
|
||||||
isNewTable = true;
|
isNewTable = true;
|
||||||
$('#StretchyReportOutput').html( '<table cellpadding="0" cellspacing="1" border="0" class="display" id="MRPshowTable" width=100%></table>' );
|
$('#StretchyReportOutput').html( '<table cellpadding="0" cellspacing="1" border="0" class="display" id="FRshowTable" width=100%></table>' );
|
||||||
oTable = $('#MRPshowTable').dataTable(dataTableDef);
|
oTable = $('#FRshowTable').dataTable(dataTableDef);
|
||||||
oSettings = oTable.fnSettings();
|
oSettings = oTable.fnSettings();
|
||||||
|
|
||||||
showMsg("1st recs displayed is: " + fnRecordsDisplay());
|
showMsg("1st recs displayed is: " + fnRecordsDisplay());
|
||||||
@@ -899,15 +900,18 @@ function showTableReport() {
|
|||||||
|
|
||||||
function showChartReport(rptSubType) {
|
function showChartReport(rptSubType) {
|
||||||
/*
|
/*
|
||||||
$('#StretchyReportOutput').html( '<table><tr><td width="25%" valign="top"><table cellpadding="0" cellspacing="1" border="0" class="display" id="MRPshowTable" width=100%></table></td><td width="75%" align="right"><div id=MRPshowChart></div></td></tr></table>' );
|
* $('#StretchyReportOutput').html( '<table><tr><td width="25%" valign="top"><table
|
||||||
$('#MRPshowTable').dataTable(dataTableDef);
|
* cellpadding="0" cellspacing="1" border="0" class="display" id="FRshowTable"
|
||||||
|
* width=100%></table></td><td width="75%" align="right"><div
|
||||||
|
* id=FRshowChart></div></td></tr></table>' );
|
||||||
|
* $('#FRshowTable').dataTable(dataTableDef);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$('#StretchyReportOutput').html( '<table><tr></td><td width="100%" align="center"><div id=MRPshowChart></div></td></tr></table>' );
|
$('#StretchyReportOutput').html( '<table><tr></td><td width="100%" align="center"><div id=FRshowChart></div></td></tr></table>' );
|
||||||
|
|
||||||
|
|
||||||
var options;
|
var options;
|
||||||
var MRPchart;
|
var FRchart;
|
||||||
|
|
||||||
switch(rptSubType)
|
switch(rptSubType)
|
||||||
{
|
{
|
||||||
@@ -918,18 +922,19 @@ var MRPchart;
|
|||||||
// chartArea: {left:0,top:0, width:"100%",height:"100%"}
|
// chartArea: {left:0,top:0, width:"100%",height:"100%"}
|
||||||
};
|
};
|
||||||
|
|
||||||
MRPchart = new google.visualization.PieChart(document.getElementById('MRPshowChart'));
|
FRchart = new google.visualization.PieChart(document.getElementById('FRshowChart'));
|
||||||
MRPchart.draw(MRPData, options);
|
FRchart.draw(FRData, options);
|
||||||
break;
|
break;
|
||||||
case "Bar":
|
case "Bar":
|
||||||
options = {
|
options = {
|
||||||
width: 1000, height: 600
|
width: 1000, height: 600
|
||||||
//vAxis: {title: 'xxxxxxx', titleTextStyle: {color: 'red'}}
|
// vAxis: {title: 'xxxxxxx', titleTextStyle: {color:
|
||||||
|
// 'red'}}
|
||||||
// chartArea: {left:0,top:0, width:"100%",height:"100%"}
|
// chartArea: {left:0,top:0, width:"100%",height:"100%"}
|
||||||
};
|
};
|
||||||
|
|
||||||
MRPchart = new google.visualization.BarChart(document.getElementById('MRPshowChart'));
|
FRchart = new google.visualization.BarChart(document.getElementById('FRshowChart'));
|
||||||
MRPchart.draw(MRPData, options);
|
FRchart.draw(FRData, options);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
alert("System Error: Unknown Chart Type: " + rptSubType);
|
alert("System Error: Unknown Chart Type: " + rptSubType);
|
||||||
@@ -940,74 +945,30 @@ var MRPchart;
|
|||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
var MRPchart = new google.visualization.PieChart(document.getElementById('MRPshowChart'));
|
* var FRchart = new
|
||||||
MRPchart.draw(MRPData, {legend: 'right', is3D: true, width: 400, height: 500, chartArea: {left:0,top:0, width:"100%",height:"100%"}});
|
* google.visualization.PieChart(document.getElementById('FRshowChart'));
|
||||||
|
* FRchart.draw(FRData, {legend: 'right', is3D: true, width: 400, height: 500,
|
||||||
|
* chartArea: {left:0,top:0, width:"100%",height:"100%"}});
|
||||||
*/
|
*/
|
||||||
/*
|
/*
|
||||||
var chartCategories = [];
|
* var chartCategories = []; for (var i in dataTableDef.aaData) {
|
||||||
for (var i in dataTableDef.aaData)
|
* chartCategories.push(dataTableDef.aaData[i][0]); }
|
||||||
{
|
*
|
||||||
chartCategories.push(dataTableDef.aaData[i][0]);
|
* var chartSeries = [];
|
||||||
}
|
*
|
||||||
|
* for (var i in dataTableDef.aaData) { chartSeries.push({data:
|
||||||
var chartSeries = [];
|
* dataTableDef.aaData[i][1]}); }
|
||||||
|
*
|
||||||
for (var i in dataTableDef.aaData)
|
*
|
||||||
{
|
* var FRchart = new Highcharts.Chart({ chart: { renderTo: 'FRshowChart',
|
||||||
chartSeries.push({data: dataTableDef.aaData[i][1]});
|
* defaultSeriesType: 'bar' }, title: { text: 'Historic World Population by
|
||||||
}
|
* Region' }, xAxis: { categories: chartCategories, title: { text: null } },
|
||||||
|
* yAxis: { min: -5000000, title: { text: 'Population (millions)', align: 'high' } },
|
||||||
|
* tooltip: { formatter: function() { return ''+ this.series.name +': '+ this.y +'
|
||||||
var MRPchart = new Highcharts.Chart({
|
* millions'; } }, plotOptions: { bar: { dataLabels: { enabled: true } } },
|
||||||
chart: {
|
* legend: { layout: 'vertical', align: 'right', verticalAlign: 'top', x: -100,
|
||||||
renderTo: 'MRPshowChart',
|
* y: 100, floating: true, borderWidth: 1, backgroundColor: '#FFFFFF', shadow:
|
||||||
defaultSeriesType: 'bar'
|
* true }, credits: { enabled: false }, series: chartSeries });
|
||||||
},
|
|
||||||
title: {
|
|
||||||
text: 'Historic World Population by Region'
|
|
||||||
},
|
|
||||||
xAxis: {
|
|
||||||
categories: chartCategories,
|
|
||||||
title: {
|
|
||||||
text: null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
yAxis: {
|
|
||||||
min: -5000000,
|
|
||||||
title: {
|
|
||||||
text: 'Population (millions)',
|
|
||||||
align: 'high'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
tooltip: {
|
|
||||||
formatter: function() {
|
|
||||||
return ''+
|
|
||||||
this.series.name +': '+ this.y +' millions';
|
|
||||||
}
|
|
||||||
},
|
|
||||||
plotOptions: {
|
|
||||||
bar: {
|
|
||||||
dataLabels: {
|
|
||||||
enabled: true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
legend: {
|
|
||||||
layout: 'vertical',
|
|
||||||
align: 'right',
|
|
||||||
verticalAlign: 'top',
|
|
||||||
x: -100,
|
|
||||||
y: 100,
|
|
||||||
floating: true,
|
|
||||||
borderWidth: 1,
|
|
||||||
backgroundColor: '#FFFFFF',
|
|
||||||
shadow: true
|
|
||||||
},
|
|
||||||
credits: {
|
|
||||||
enabled: false
|
|
||||||
},
|
|
||||||
series: chartSeries
|
|
||||||
});
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@@ -1023,9 +984,8 @@ function getReportData(inParams, successFunction) {
|
|||||||
function getReportDataAuth(inParams, successFunction) {
|
function getReportDataAuth(inParams, successFunction) {
|
||||||
|
|
||||||
var inQueryParameters = {};
|
var inQueryParameters = {};
|
||||||
inQueryParameters["MRP_rptDB"] = rptDB;
|
for (var i in inParams ) inQueryParameters["FR_" + i] = inParams[i];
|
||||||
for (var i in inParams ) inQueryParameters["MRP_" + i] = inParams[i];
|
if (rptDB > "") inQueryParameters["FR_rptDB"] = rptDB;
|
||||||
|
|
||||||
|
|
||||||
OAuthSimple().reset();
|
OAuthSimple().reset();
|
||||||
var OAuthProcess = (new OAuthSimple()).sign({
|
var OAuthProcess = (new OAuthSimple()).sign({
|
||||||
@@ -1054,19 +1014,36 @@ function getReportDataAuth(inParams, successFunction) {
|
|||||||
error:function(jqXHR, textStatus, errorThrown){
|
error:function(jqXHR, textStatus, errorThrown){
|
||||||
showMsgE("getReportData IS Auth Error: ");
|
showMsgE("getReportData IS Auth Error: ");
|
||||||
var jsonValue = jQuery.parseJSON(jqXHR.responseText);
|
var jsonValue = jQuery.parseJSON(jqXHR.responseText);
|
||||||
alert(jqXHR.responseText);
|
alert("Response Text: " + jqXHR.responseText + " Text Status: " + textStatus);
|
||||||
alert(textStatus);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function buildReportParms(inParams) {
|
||||||
|
|
||||||
|
var paramCount = 1;
|
||||||
|
var reportParams = "";
|
||||||
|
for (var i in inParams )
|
||||||
|
{
|
||||||
|
if (paramCount > 1) reportParams += "&"
|
||||||
|
reportParams += encodeURIComponent("FR_" + i) + "=" + encodeURIComponent(inParams[i]);
|
||||||
|
paramCount = paramCount + 1;
|
||||||
|
}
|
||||||
|
if (rptDB > "")
|
||||||
|
{
|
||||||
|
if (paramCount > 1) reportParams += "&"
|
||||||
|
reportParams = encodeURIComponent("FR_rptDB") + "=" + encodeURIComponent(rptDB);
|
||||||
|
}
|
||||||
|
|
||||||
|
return reportParams
|
||||||
|
}
|
||||||
|
|
||||||
function getReportDataNoAuth(inParams, successFunction) {
|
function getReportDataNoAuth(inParams, successFunction) {
|
||||||
|
|
||||||
var inQueryParameters = "MRP_rptDB=" + rptDB;
|
var inQueryParameters = buildReportParms(inParams);
|
||||||
for (var i in inParams ) inQueryParameters += "&" + encodeURIComponent("MRP_" + i) + "=" + encodeURIComponent(inParams[i]);
|
|
||||||
|
|
||||||
showMsgE("getReportDataNoAuth: " + inQueryParameters);
|
showMsgE("getReportDataNoAuth: " + inQueryParameters);
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: RESTUrl,
|
url: RESTUrl,
|
||||||
@@ -1082,29 +1059,19 @@ function getReportDataNoAuth(inParams, successFunction) {
|
|||||||
success: successFunction,
|
success: successFunction,
|
||||||
error:function(jqXHR, textStatus, errorThrown){
|
error:function(jqXHR, textStatus, errorThrown){
|
||||||
showMsgE("getReportDataNoAuth: ");
|
showMsgE("getReportDataNoAuth: ");
|
||||||
alert(jqXHR.responseText);
|
alert("Response Text: " + jqXHR.responseText + " Text Status: " + textStatus + " Error Thrown: " + errorThrown);
|
||||||
alert(textStatus);
|
|
||||||
alert(errorThrown);
|
|
||||||
var jsonValue = jQuery.parseJSON(jqXHR.responseText);
|
var jsonValue = jQuery.parseJSON(jqXHR.responseText);
|
||||||
alert(jsonValue.value + "for " + jsonValue.field + " : " + jsonValue.code);
|
alert("Last Alert - " + jsonValue.value + "for " + jsonValue.field + " : " + jsonValue.code);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function getExportCSV(inParams) {
|
function getExportCSV(inParams) {
|
||||||
|
|
||||||
var inQueryParameters = "?" + encodeURIComponent("MRP_rptDB") + "=" + encodeURIComponent(rptDB);
|
var inQueryParameters = buildReportParms(inParams);
|
||||||
//var paramCount = 1;
|
var fullExportUrl = RESTUrl + "?" + inQueryParameters + "&exportCSV=true";
|
||||||
for (var i in inParams )
|
|
||||||
{
|
|
||||||
//if (paramCount > 1) inQueryParameters += "&"
|
|
||||||
//else inQueryParameters += "?";
|
|
||||||
inQueryParameters += "&" + encodeURIComponent("MRP_" + i) + "=" + encodeURIComponent(inParams[i]);
|
|
||||||
//paramCount = paramCount + 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
var fullExportUrl = RESTUrl + inQueryParameters + "&exportCSV=true";
|
|
||||||
showMsg("full export url: " + fullExportUrl);
|
showMsg("full export url: " + fullExportUrl);
|
||||||
var loadHTML = '<iframe id=rptLoadingFrame src="' + fullExportUrl + '" frameborder="0" onload="jQuery.stretchyReporting.clearLoadingImg();" width="100%" height="600px" style="background:url(';
|
var loadHTML = '<iframe id=rptLoadingFrame src="' + fullExportUrl + '" frameborder="0" onload="jQuery.stretchyReporting.clearLoadingImg();" width="100%" height="600px" style="background:url(';
|
||||||
loadHTML += "'" + loadingImg + "'" + ') no-repeat scroll 50% 100px;"><p>Your browser does not support iframes.</p></iframe>';
|
loadHTML += "'" + loadingImg + "'" + ') no-repeat scroll 50% 100px;"><p>Your browser does not support iframes.</p></iframe>';
|
||||||
@@ -1365,7 +1332,8 @@ function redrawOutput() {
|
|||||||
|
|
||||||
function setTableSizeLimit() {
|
function setTableSizeLimit() {
|
||||||
if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)){ // test for MSIE x.x;
|
if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)){ // test for MSIE x.x;
|
||||||
var ieversion=new Number(RegExp.$1) // capture x.x portion and store as a number
|
var ieversion=new Number(RegExp.$1) // capture x.x portion and store as
|
||||||
|
// a number
|
||||||
if (ieversion>=9) return 50000
|
if (ieversion>=9) return 50000
|
||||||
else return 3000;
|
else return 3000;
|
||||||
}
|
}
|
||||||
+1
-1
@@ -16,6 +16,6 @@
|
|||||||
<script type="text/javascript" src="${resValue}/libs/DataTables-1.8.2/extras/TableTools/media/js/TableTools.min.js"></script>
|
<script type="text/javascript" src="${resValue}/libs/DataTables-1.8.2/extras/TableTools/media/js/TableTools.min.js"></script>
|
||||||
<script type="text/javascript" src="${resValue}/libs/jquery.i18n.properties-min-1.0.9.js"></script>
|
<script type="text/javascript" src="${resValue}/libs/jquery.i18n.properties-min-1.0.9.js"></script>
|
||||||
<script type="text/javascript" src="${resValue}/libs/OAuthSimple.js"></script>
|
<script type="text/javascript" src="${resValue}/libs/OAuthSimple.js"></script>
|
||||||
<script type="text/javascript" src="${resValue}/stretchyreporting/stretchyreporting-0.966.js"></script>
|
<script type="text/javascript" src="${resValue}/stretchyreporting/stretchyreporting-0.967.js"></script>
|
||||||
|
|
||||||
<script type="text/javascript" src="https://www.google.com/jsapi"></script>
|
<script type="text/javascript" src="https://www.google.com/jsapi"></script>
|
||||||
|
|||||||
@@ -34,21 +34,6 @@ public class ReportingApiResource {
|
|||||||
@Autowired
|
@Autowired
|
||||||
private ReadExtraDataAndReportingService ReadExtraDataAndReportingService;
|
private ReadExtraDataAndReportingService ReadExtraDataAndReportingService;
|
||||||
|
|
||||||
// private Response makeCORSExport(ResponseBuilder req, String exportFilename,
|
|
||||||
// String returnMethod) {
|
|
||||||
// ResponseBuilder rb = req
|
|
||||||
// .header("Access-Control-Allow-Origin", "*")
|
|
||||||
// .header("Access-Control-Allow-Methods", "GET, POST, OPTIONS")
|
|
||||||
// .header("Content-Disposition",
|
|
||||||
// "attachment;filename=" + exportFilename);
|
|
||||||
//
|
|
||||||
// if (!"".equals(returnMethod)) {
|
|
||||||
// rb.header("Access-Control-Allow-Headers", returnMethod);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// return rb.build();
|
|
||||||
// }
|
|
||||||
|
|
||||||
@GET
|
@GET
|
||||||
@Consumes({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
|
@Consumes({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
|
||||||
@Produces({ MediaType.APPLICATION_JSON, "application/x-msdownload" })
|
@Produces({ MediaType.APPLICATION_JSON, "application/x-msdownload" })
|
||||||
@@ -56,8 +41,8 @@ public class ReportingApiResource {
|
|||||||
|
|
||||||
MultivaluedMap<String, String> queryParams = uriInfo
|
MultivaluedMap<String, String> queryParams = uriInfo
|
||||||
.getQueryParameters();
|
.getQueryParameters();
|
||||||
String name = queryParams.getFirst("MRP_Name");
|
String name = queryParams.getFirst("FR_Name");
|
||||||
String type = queryParams.getFirst("MRP_Type");
|
String type = queryParams.getFirst("FR_Type");
|
||||||
String exportCSV = queryParams.getFirst("exportCSV");
|
String exportCSV = queryParams.getFirst("exportCSV");
|
||||||
|
|
||||||
Map<String, String> extractedQueryParams = new HashMap<String, String>();
|
Map<String, String> extractedQueryParams = new HashMap<String, String>();
|
||||||
@@ -67,10 +52,9 @@ public class ReportingApiResource {
|
|||||||
String pValue;
|
String pValue;
|
||||||
for (String k : keys) {
|
for (String k : keys) {
|
||||||
|
|
||||||
if (k.startsWith("MRP_")) {
|
if (k.startsWith("FR_")) {
|
||||||
pKey = "${" + k.substring(4) + "}";
|
pKey = "${" + k.substring(3) + "}";
|
||||||
pValue = queryParams.get(k).get(0);
|
pValue = queryParams.get(k).get(0);
|
||||||
|
|
||||||
extractedQueryParams.put(pKey, pValue);
|
extractedQueryParams.put(pKey, pValue);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -83,9 +67,15 @@ public class ReportingApiResource {
|
|||||||
return Response.ok().entity(result).build();
|
return Response.ok().entity(result).build();
|
||||||
}
|
}
|
||||||
|
|
||||||
StreamingOutput result = this.ReadExtraDataAndReportingService.retrieveReportCSV(name, type, extractedQueryParams);
|
StreamingOutput result = this.ReadExtraDataAndReportingService
|
||||||
|
.retrieveReportCSV(name, type, extractedQueryParams);
|
||||||
|
|
||||||
return Response.ok().entity(result).header("Content-Disposition","attachment;filename=" + name.replaceAll(" ", "") + ".csv").build();
|
return Response
|
||||||
|
.ok()
|
||||||
|
.entity(result)
|
||||||
|
.header("Content-Disposition",
|
||||||
|
"attachment;filename=" + name.replaceAll(" ", "")
|
||||||
|
+ ".csv").build();
|
||||||
}
|
}
|
||||||
|
|
||||||
@GET
|
@GET
|
||||||
|
|||||||
Reference in New Issue
Block a user