Unplanned
Last Updated: 01 Nov 2023 14:33 by waqas
waqas
Created on: 01 Nov 2023 14:33
Type: Bug Report
1
WebServiceDataSource Preview page displays [object Object]

When the service of the Web Report Designer is running in a .NET Framework application, the preview page of the WebServiceDataSource component displays [object Object] instead of the data string.

The WRD front end expects the ReportDesignerController's PreviewWebServiceData(DataSourceInfo) method to return stringified JSON but instead, it currently(R3 2023) returns a JSON.

As a workaround, the method can be overridden so that the string result is returned instead:

        public override IHttpActionResult PreviewWebServiceData(DataSourceInfo dataSourceInfo)
        {
            var baseResult = (ResponseMessageResult)base.PreviewWebServiceData(dataSourceInfo);
            var jsonString = baseResult.Response.Content.ReadAsStringAsync().Result;

            return Ok(jsonString);
        }

 

0 comments