public IActionResult GetDataGeneralReport(GeneralReportCriteria criteria, int page, int size)
        {
            var data   = shipmentService.GetDataGeneralReport(criteria, page, size, out int rowCount);
            var result = new { data, totalItems = rowCount, page, size };

            return(Ok(result));
        }
        public IActionResult GetDataExportShipmentOverview(GeneralReportCriteria criteria)
        {
            var data   = shipmentService.GetDataGeneralExportShipmentOverview(criteria);
            var result = data;

            return(Ok(result));
        }
        public async Task <IActionResult> ExportShipmentOverview(GeneralReportCriteria criteria)
        {
            var responseFromApi = await HttpServiceExtension.GetDataFromApi(criteria, aPis.HostStaging + Urls.Documentation.GetDataShipmentOverviewUrl);

            var dataObjects = responseFromApi.Content.ReadAsAsync <List <ExportShipmentOverview> >();

            if (dataObjects.Result == null)
            {
                return(new FileHelper().ExportExcel(new MemoryStream(), ""));
            }

            var stream = new DocumentationHelper().GenerateShipmentOverviewExcel(dataObjects.Result, criteria, null);

            if (stream == null)
            {
                return(new FileHelper().ExportExcel(new MemoryStream(), ""));
            }
            FileContentResult fileContent = new FileHelper().ExportExcel(stream, "Shipment Overview.xlsx");

            return(fileContent);
        }