This commit is contained in:
jl
2024-01-12 16:53:44 +08:00
parent 95aaa6d25c
commit 9d5221ba0d
8 changed files with 742 additions and 693 deletions

View File

@ -792,8 +792,9 @@ namespace Epost.BLL
demodel.Addresstype = "1";
demodel.ControlID = "";
demodel.ControlIP = item["ControlIP"].ToString();
//demodel.Layer = item["Layer"].ToString();
//demodel.Slist = item["Slist"].ToString();
demodel.Layer = item["Layer"].ToString();
demodel.Slist = item["Slist"].ToString();
demodel.clientcode = item["clientcode"].ToString();
//demodel.Zone = item["zone"].ToString();
//demodel.TaskType =Convert.ToInt32(item["tasktype"].ToString());

View File

@ -1,4 +1,5 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Data;
using System.Data.Entity.Infrastructure;
@ -11,6 +12,7 @@ using Epost.DAL;
using Epost.DAL.Cache;
using Epost.DAL.Enum;
using Epost.Model;
using static Epost.DAL.Enum.LightColor;
namespace Epost.BLL
{
@ -585,7 +587,7 @@ namespace Epost.BLL
if (queueDT != null && queueDT.Rows.Count > 0)
{
ShowMessageModel showmodel = new ShowMessageModel();
////获取当前区任务并加入缓存
//if (!isJobList.Any())
//{
@ -594,7 +596,7 @@ namespace Epost.BLL
if (nowJoblist.Any())
{
var nowmodel = nowJoblist.FirstOrDefault();
string showmes = string.Empty;
#region
foreach (JobModel item in nowJoblist.ToArray())
{
@ -633,10 +635,11 @@ namespace Epost.BLL
{
manufactname = item.manufactname.Substring(0, 4);
}
lamodel.Content = "" + item.Sku.Substring(item.Sku.Length - 4, 4) + "\\t" + item.Spec + "\r" + item.GoodsName + "\r批号" + item.batchno + " " + manufactname + "";
// lamodel.Content = "" + item.Sku.Substring(item.Sku.Length - 4, 4) + "\\t" + item.Spec + "\r" + item.GoodsName + "\r批号" + item.batchno + " " + manufactname + "";
lamodel.Content = "" + item.GoodsName + "\r" + item.Spec + "\r" + manufactname + "";
var aryloc = item.Tolocation.Split('-');
lamodel.Loc = "" + aryloc[0].ToString() + "-" + aryloc[1].ToString() + "";
lamodel.W_quantity = aryloc[2].ToString();
lamodel.Loc = "" + aryloc[0].ToString();
lamodel.W_quantity = item.Slist;
lamodel.Quantity = quantity.ToString();
lamodel.Unit = item.Unit;
lamodel.PicChoose = "";
@ -719,7 +722,7 @@ namespace Epost.BLL
item.DisplayTime = DateTime.Now;
#endregion
showmes = item.clientcode;
}
#endregion
@ -729,6 +732,36 @@ namespace Epost.BLL
{
LogHelper.WriteLogInfo("添加到点亮的list————————————————————" + list.Count);
comBLL.DISPLAY_JOBALL(list);
//点亮显示器
if (!string.IsNullOrEmpty(showmes))
{
LogHelper.WriteLogInfo("下发异常货位信息"+showmes);
if (showmes.Length > 30)
{
string newstr = showmes.Substring(30, showmes.Length - 30);
if (newstr.Length > 30)
{
showmes = showmes.Substring(0, 30) + "\r" + newstr.Substring(0, 30) + "\r" + newstr.Substring(30, newstr.Length - 30);
}
else
{
showmes = showmes.Substring(0, 30) + "\r" + newstr;
}
}
ShowMessageModel_M showmodel = new ShowMessageModel_M();
showmodel.Area = narea;
showmodel.Block = nblock;
showmodel.Color = EnumHelper.EMToDescriptionString(LightColor.Color.Red);
showmodel.Islock = true;
showmodel.Title = "下发货位异常信息";
showmodel.IsTwinkle = 0;
showmodel.Contents = showmes;
showmodel.Type = 2;
comBLL.ShowBoxMessage_M(showmodel);//点亮显示标签
}
}
}
//else

View File

@ -52,7 +52,7 @@ namespace Epost.DAL
string sql = string.Empty;
if (!string.IsNullOrEmpty(area))
{
sql = string.Format("select id,transderDid,orderid,Sku,genericname,GoodsName,Spec,Unit,batchno,manufactname,Quantity,stockquantity,shopname,Tolocation,labelcolor,looklisten,labelIP,labelno,Matchid,barcode,BatchId,DownDate,Discount,address,ControlIP,area,block,shopid from v_orders where state = 0 and oprationstate =0 and block = '{1}' and area='{2}' " + strwhere + "",
sql = string.Format("select id,transderDid,orderid,Sku,genericname,GoodsName,Spec,Unit,batchno,manufactname,Quantity,stockquantity,shopname,Tolocation,labelcolor,looklisten,labelIP,labelno,Matchid,barcode,BatchId,DownDate,Discount,address,ControlIP,area,block,shopid,slist,layer,clientcode from v_orders where state = 0 and oprationstate =0 and block = '{1}' and area='{2}' " + strwhere + "",
sku,
block, area);
@ -60,7 +60,7 @@ namespace Epost.DAL
}
else
{
sql = string.Format("select id,transderDid,orderid,Sku,genericname,GoodsName,Spec,Unit,batchno,manufactname,Quantity,stockquantity,shopname,Tolocation,labelcolor,looklisten,labelIP,labelno,Matchid,barcode,BatchId,DownDate,Discount,address,ControlIP,area,block,shopid from v_orders where state = 0 and oprationstate =0 and sku = '{0}' and block = '{1}' " + strwhere + "",
sql = string.Format("select id,transderDid,orderid,Sku,genericname,GoodsName,Spec,Unit,batchno,manufactname,Quantity,stockquantity,shopname,Tolocation,labelcolor,looklisten,labelIP,labelno,Matchid,barcode,BatchId,DownDate,Discount,address,ControlIP,area,block,shopid,slist,layer,clientcode from v_orders where state = 0 and oprationstate =0 and sku = '{0}' and block = '{1}' " + strwhere + "",
sku,
block);

View File

@ -48,6 +48,7 @@ namespace Epost.Model
private string _Unit = string.Empty;//小单位
private string _UserCode = string.Empty;//工号
private string _no = string.Empty;//任务序号
private string _clientcode = string.Empty;//货位不存在提示
public string BatchId
{
get
@ -396,6 +397,7 @@ namespace Epost.Model
public string UserCode { get => _UserCode; set => _UserCode = value; }
public string No { get => _no; set => _no = value; }
public string ID { get => _ID; set => _ID = value; }
public string clientcode { get => _clientcode; set => _clientcode = value; }
}
}

View File

@ -19,13 +19,19 @@ namespace Epost.TestToolsWeb.Tests.Controllers
[TestMethod]
public void d()
{
string sku = "211100";
if (sku.Substring(0, 1) == "2" && sku.Substring(1, 1) != "5")
string showmes = "211100|394892345|938275908324|93875|934725";
if (showmes.Length > 30)
{
if (sku.Length >= 7)
string newstr = showmes.Substring(30, showmes.Length-30);
if (newstr.Length > 30)
{
sku = sku.Substring(1, 6);
showmes = showmes.Substring(0, 30) + "\r" + newstr.Substring(0, 30) + "\r" + newstr.Substring(30, newstr.Length-30);
}
else
{
showmes = showmes.Substring(0, 30) + "\r" + newstr;
}
}
}
}

View File

@ -10,7 +10,7 @@
<WebStackScaffolding_LayoutPageFile>~/Views/Shared/_EpostLayoutPage.cshtml</WebStackScaffolding_LayoutPageFile>
<WebStackScaffolding_IsAsyncSelected>False</WebStackScaffolding_IsAsyncSelected>
<WebStackScaffolding_ViewDialogWidth>600</WebStackScaffolding_ViewDialogWidth>
<NameOfLastUsedPublishProfile>D:\驿传\Epost\T_DAS_PTL\Epost.TestToolsWeb\Properties\PublishProfiles\Toolsweb.pubxml</NameOfLastUsedPublishProfile>
<NameOfLastUsedPublishProfile>E:\WORK\代码管理\T系列\播种\Epost.TestToolsWeb\Properties\PublishProfiles\Toolsweb.pubxml</NameOfLastUsedPublishProfile>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<Use64BitIISExpress />
<IISExpressSSLPort />

View File

@ -3,6 +3,7 @@ using Epost.Common;
using Epost.DAL;
using Epost.DAL.Cache;
using Epost.Model;
using PTLSystems.Service.PublicF;
using System;
using System.Collections.Generic;
using System.Data;
@ -59,7 +60,7 @@ namespace Epost.DPS.WebService
{
var ReturnDt = set.Tables["pick"];
DataTable dtResult = ReturnDt.Clone();
string str = string.Empty;
foreach (DataRow item in ReturnDt.Rows)
{
@ -69,6 +70,7 @@ namespace Epost.DPS.WebService
DataTable locdt = bll.GetlocationInfo(item["areaId"].ToString());
if (locdt != null && locdt.Rows.Count > 0)
{
locdt.Columns.Add("strinfo", typeof(string));
DataRow dataRow = dtResult.NewRow();
dataRow["transderMid"] = item["transderMid"].ToString();
dataRow["transderDid"] = item["transderDid"].ToString();
@ -88,12 +90,15 @@ namespace Epost.DPS.WebService
dataRow["lookListen"] = item["lookListen"].ToString();
dataRow["labelIP"] = item["labelIP"].ToString();
dataRow["labelNo"] = item["labelNo"].ToString();
dataRow["strinfo"] = dataRow["strinfo"] + str;
dtResult.Rows.Add(dataRow);
}
else
{
LogHelper.WriteLogInfo("" + item["areaId"].ToString() + ",该货位不存在");
str = str + item["areaId"].ToString() + "|";
}
}
else
@ -137,6 +142,8 @@ namespace Epost.DPS.WebService
diclist.Add("lookListen", "looklisten");
diclist.Add("labelIP", "labelIP");
diclist.Add("labelNo", "labelno");
diclist.Add("strinfo", "clientcode");
bool b = bll.ImportOrderinfo(dtResult, diclist);
if (b)