jianghaiqing 2 years ago
commit 406ce7a945

@ -19,6 +19,11 @@ namespace Myshipping.Application.Entity
/// 尺寸 /// 尺寸
/// </summary> /// </summary>
public string SIZE { get; set; } public string SIZE { get; set; }
/// <summary>
/// 表现形式 箱型
/// </summary>
public string CTNALL { get; set; }
/// <summary> /// <summary>
/// 集装箱箱型 /// 集装箱箱型
/// </summary> /// </summary>

@ -117,6 +117,11 @@ namespace Myshipping.Application
{ {
var ctn = item.Adapt<BookingOrderSeaeEdiCtn>(); var ctn = item.Adapt<BookingOrderSeaeEdiCtn>();
ctn.PId = entity.Id; ctn.PId = entity.Id;
if (ctn.CTNALL.Length==4) {
ctn.SIZE = ctn.CTNALL != null ? ctn.CTNALL.Substring(0, 2) : "";
ctn.SIZE = ctn.CTNALL != null ? ctn.CTNALL.Substring(2, 2) : "";
}
await _seaeedictn.InsertAsync(ctn); await _seaeedictn.InsertAsync(ctn);
} }
} }
@ -143,6 +148,12 @@ namespace Myshipping.Application
{ {
var ctn = item.Adapt<BookingOrderSeaeEdiCtn>(); var ctn = item.Adapt<BookingOrderSeaeEdiCtn>();
ctn.PId = entity.Id; ctn.PId = entity.Id;
if (ctn.CTNALL.Length == 4)
{
ctn.SIZE = ctn.CTNALL != null ? ctn.CTNALL.Substring(0, 2) : "";
ctn.SIZE = ctn.CTNALL != null ? ctn.CTNALL.Substring(2, 2) : "";
}
await _seaeedictn.InsertAsync(ctn); await _seaeedictn.InsertAsync(ctn);
} }
} }
@ -169,6 +180,7 @@ namespace Myshipping.Application
/// <param name="Ids"></param> /// <param name="Ids"></param>
/// <returns></returns> /// <returns></returns>
[SqlSugarUnitOfWork] [SqlSugarUnitOfWork]
[HttpPost("/BookingOrderSeaeEdi/Delete")] [HttpPost("/BookingOrderSeaeEdi/Delete")]
public async Task Delete(string Ids) public async Task Delete(string Ids)
{ {
@ -234,7 +246,6 @@ namespace Myshipping.Application
List<CTNDATAItem> CTNDATA = new List<CTNDATAItem>(); List<CTNDATAItem> CTNDATA = new List<CTNDATAItem>();
mDATA = order.Adapt<MDATA>(); mDATA = order.Adapt<MDATA>();
CTNDATA = ctns.Adapt<List<CTNDATAItem>>(); CTNDATA = ctns.Adapt<List<CTNDATAItem>>();
custEDIDtos.Add( custEDIDtos.Add(
new CustEDIDto new CustEDIDto
{ {
@ -258,10 +269,10 @@ namespace Myshipping.Application
var jobjResp = JObject.Parse(strResp); var jobjResp = JObject.Parse(strResp);
int respCode = jobjResp.GetIntValue("code"); bool respCode = jobjResp.GetBooleanValue("Success");
if (respCode != 200) if (respCode== false)
{ {
throw Oops.Bah(BookingErrorCode.BOOK129, jobjResp.GetStringValue("message")); throw Oops.Bah(jobjResp.GetStringValue("Message"));
} }
//货运动态 //货运动态
var bsl = new BookingStatusLog(); var bsl = new BookingStatusLog();

@ -204,6 +204,10 @@ namespace Myshipping.Application.Service.BookingOrderSeaeEdi.Dto
/// </summary> /// </summary>
public string SIZE { get; set; } public string SIZE { get; set; }
/// <summary> /// <summary>
/// 集装箱箱型表现形式
/// </summary>
public string CTNALL { get; set; }
/// <summary>
/// 集装箱箱型 /// 集装箱箱型
/// </summary> /// </summary>
public string CTN { get; set; } public string CTN { get; set; }

@ -77,7 +77,8 @@ public class SysUserService : ISysUserService, IDynamicApiController, ITransient
o.Pids.Contains(pid.Trim())) o.Pids.Contains(pid.Trim()))
.WhereIF(Enum.IsDefined(typeof(CommonStatus), input.SearchStatus), (u, e, o) => u.Status == input.SearchStatus) .WhereIF(Enum.IsDefined(typeof(CommonStatus), input.SearchStatus), (u, e, o) => u.Status == input.SearchStatus)
.Where((u, e, o) => u.AdminType == AdminType.None) .Where((u, e, o) => u.AdminType == AdminType.None)
.Select<UserOutput>("u.*,t.Name As TenantName ").ToDataFilter("u", "Id", FilterType.User).ToPagedListAsync(input.PageNo, input.PageSize); .Select<UserOutput>("u.*,t.Name As TenantName ").ToDataFilter("u", "Id", FilterType.User).OrderByDescending(u=>u.Name).
ToPagedListAsync(input.PageNo, input.PageSize);
var empInfos = await _sysEmpService.GetEmpInfo(users.Items.Select(m => long.Parse(m.Id)).ToList()); var empInfos = await _sysEmpService.GetEmpInfo(users.Items.Select(m => long.Parse(m.Id)).ToList());
foreach (var user in users.Items) foreach (var user in users.Items)
@ -103,7 +104,7 @@ public class SysUserService : ISysUserService, IDynamicApiController, ITransient
// 数据范围检查 // 数据范围检查
CheckDataScope(input.SysEmpParam == null || string.IsNullOrEmpty(input.SysEmpParam.OrgId) ? 0 : long.Parse(input.SysEmpParam.OrgId)); CheckDataScope(input.SysEmpParam == null || string.IsNullOrEmpty(input.SysEmpParam.OrgId) ? 0 : long.Parse(input.SysEmpParam.OrgId));
var isExist = await _sysUserRep.AsQueryable().Filter(null, true).AnyAsync(u => u.Account == input.Account); var isExist = await _sysUserRep.AsQueryable().Filter(null, true).AnyAsync(u => u.Account == input.Account&&u.IsDeleted==false);
if (isExist) throw Oops.Oh(ErrorCode.D1003); if (isExist) throw Oops.Oh(ErrorCode.D1003);
var keyDES = App.GetOptions<EncryptKeyOptions>().DES; var keyDES = App.GetOptions<EncryptKeyOptions>().DES;

Loading…
Cancel
Save