wanghaomei 2 years ago
commit f7ee747e00

@ -14,7 +14,7 @@ namespace Myshipping.Application.Entity
/// <summary> /// <summary>
/// 订舱ID /// 订舱ID
/// </summary> /// </summary>
[Description("车队ID")] [Description("订舱ID")]
public Nullable<long> BookingId { get; set; } public Nullable<long> BookingId { get; set; }
/// <summary> /// <summary>
/// 车队ID /// 车队ID
@ -27,9 +27,9 @@ namespace Myshipping.Application.Entity
[Description("车队代码")] [Description("车队代码")]
public string TruckCode { get; set; } public string TruckCode { get; set; }
/// <summary> /// <summary>
/// 车队代码 /// 车队名称
/// </summary> /// </summary>
[Description("车队代码")] [Description("车队名称")]
public string TruckName { get; set; } public string TruckName { get; set; }
/// <summary> /// <summary>
/// TO /// TO

@ -5078,8 +5078,6 @@ namespace Myshipping.Application
} }
} }
Dictionary<string, string> dic1 = new Dictionary<string, string>(); Dictionary<string, string> dic1 = new Dictionary<string, string>();
foreach (PropertyDescriptor descriptor in TypeDescriptor.GetProperties(ctn)) foreach (PropertyDescriptor descriptor in TypeDescriptor.GetProperties(ctn))
{ {

@ -99,7 +99,7 @@ namespace Myshipping.Application
{ {
_bookingTruckRepository.Insert(entity); _bookingTruckRepository.Insert(entity);
if (entityCtnList.Count > 0) if (entityCtnList != null && entityCtnList.Count > 0)
{ {
entityCtnList.ForEach(async ctn => entityCtnList.ForEach(async ctn =>
{ {
@ -124,7 +124,7 @@ namespace Myshipping.Application
it.TruckCode, it.TruckCode,
}).ExecuteCommandAsync(); }).ExecuteCommandAsync();
if (entityCtnList.Count > 0) if (entityCtnList != null && entityCtnList.Count > 0)
{ {
entityCtnList.ForEach(async ctn => entityCtnList.ForEach(async ctn =>
{ {

@ -11821,7 +11821,7 @@
<param name="dto"></param> <param name="dto"></param>
<returns></returns> <returns></returns>
</member> </member>
<member name="M:Myshipping.Core.Service.DjyVesselInfoService.GetList(System.String,System.Nullable{System.DateTime},System.String)"> <member name="M:Myshipping.Core.Service.DjyVesselInfoService.GetList(System.String,System.Nullable{System.DateTime},System.String,System.String)">
<summary> <summary>
下拉列表 下拉列表
</summary> </summary>

@ -1515,6 +1515,7 @@ public class CommonDBService : ICommonDBService, IDynamicApiController, ITransie
/// </summary> /// </summary>
/// <param name="input">查询条件</param> /// <param name="input">查询条件</param>
/// <returns></returns> /// <returns></returns>
[HttpGet("/commondb/CodeCountryList")]
public async Task<dynamic> CodeCountryList([FromQuery] NameQueryDto input) public async Task<dynamic> CodeCountryList([FromQuery] NameQueryDto input)
{ {
List<CodeCountry> list = await _sysCacheService.GetAllCodeCountry(); List<CodeCountry> list = await _sysCacheService.GetAllCodeCountry();

@ -109,12 +109,13 @@ namespace Myshipping.Core.Service
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
[HttpGet("/DjyVesselInfoService/GetList")] [HttpGet("/DjyVesselInfoService/GetList")]
public async Task<dynamic> GetList([FromQuery] string CarrierID, DateTime? ETD = null, string KeyWord = "") public async Task<dynamic> GetList([FromQuery] string CarrierID, DateTime? ETD = null, string PortDischargeId = null,string KeyWord = "")
{ {
//获取船名 //获取船名
List<CodeVessel> list = await _sysCacheService.GetAllCodeVessel(); List<CodeVessel> list = await _sysCacheService.GetAllCodeVessel();
var tlist = await _rep.AsQueryable().Filter(null, true).WhereIF(!string.IsNullOrWhiteSpace(KeyWord), x => x.Vessel.StartsWith(KeyWord.ToUpper())). var tlist = await _rep.AsQueryable().Filter(null, true).WhereIF(!string.IsNullOrWhiteSpace(KeyWord), x => x.Vessel.StartsWith(KeyWord.ToUpper())).
WhereIF(!string.IsNullOrEmpty(PortDischargeId),x=>x.PortDischargeId==PortDischargeId).
WhereIF(ETD != null, x => Convert.ToDateTime(x.ETD).ToString("yyyy-MM-dd") == Convert.ToDateTime(ETD).ToString("yyyy-MM-dd")).//船期关联船名 WhereIF(ETD != null, x => Convert.ToDateTime(x.ETD).ToString("yyyy-MM-dd") == Convert.ToDateTime(ETD).ToString("yyyy-MM-dd")).//船期关联船名
WhereIF(ETD == null, x => x.ETD > DateTime.Now.AddDays(-7)).//领导需求当前日期7天之前 WhereIF(ETD == null, x => x.ETD > DateTime.Now.AddDays(-7)).//领导需求当前日期7天之前
WhereIF(!string.IsNullOrEmpty(CarrierID),x=>x.CARRIERID==CarrierID|| x.CARRIERID==null|| x.CARRIERID == ""). WhereIF(!string.IsNullOrEmpty(CarrierID),x=>x.CARRIERID==CarrierID|| x.CARRIERID==null|| x.CARRIERID == "").
@ -126,6 +127,8 @@ namespace Myshipping.Core.Service
Vessel = x.Vessel, Vessel = x.Vessel,
ETD = x.ETD == null ? "" : Convert.ToDateTime(x.ETD).ToString("yyyy-MM-dd"), ETD = x.ETD == null ? "" : Convert.ToDateTime(x.ETD).ToString("yyyy-MM-dd"),
ATD = x.ATD == null ? "" : Convert.ToDateTime(x.ATD).ToString("yyyy-MM-dd"), ATD = x.ATD == null ? "" : Convert.ToDateTime(x.ATD).ToString("yyyy-MM-dd"),
PortDischargeId=x.PortDischargeId,
PortDischarge=x.PortDischarge
}).Take(20). }).Take(20).
ToListAsync(); ToListAsync();
@ -147,6 +150,8 @@ namespace Myshipping.Core.Service
Vessel = x.Name, Vessel = x.Name,
ETD = "", ETD = "",
ATD = "", ATD = "",
PortDischargeId = "",
PortDischarge = ""
}).Take(20).ToList(); }).Take(20).ToList();
foreach (var item in ves) foreach (var item in ves)
{ {

Loading…
Cancel
Save