public async Task <Tracking[]> TraceByWaybillNo(TraceByWaybillDto TraceByWaybillDto) { ClientInformation objClientInformation = new ClientInformation(); objClientInformation.ClientID = TraceByWaybillDto.clientID; objClientInformation.Password = TraceByWaybillDto.password; objClientInformation.Version = TraceByWaybillDto.version; return(await client.TraceByWaybillNoAsync(objClientInformation, TraceByWaybillDto.WaybillNo)); }
public async Task <IActionResult> TraceByWaybill([FromBody] TraceByWaybillDto TraceByWaybillDto) { try { Tracking[] TraceByWaybillResponse = new Tracking[0]; return(Ok(TraceByWaybillResponse)); //await _NaqelServices.TraceByWaybillNoDetails(TraceByWaybillDto); //if (TraceByWaybillResponse.Length > 0) //{ // return Ok(TraceByWaybillResponse); //} //else //{ // return BadRequest(new GenericResultDto<string> { Result = "There is no information on the Waybill, Please try again later" }); //} } catch (Exception err) { return(BadRequest(new GenericResultDto <string> { Result = err.Message })); } }
public async Task <Tracking[]> TraceByWaybillNoDetails(TraceByWaybillDto TraceByWaybillDto) { return(await _NaqelDataAccess.TraceByWaybillNo(TraceByWaybillDto)); }