This commit is contained in:
jl
2025-01-13 13:47:28 +08:00
parent c82154ff51
commit 36e123d79e
6 changed files with 143 additions and 22 deletions

View File

@ -955,5 +955,18 @@ namespace Epost.BLL
} }
#endregion #endregion
#region
public bool getSmallLocList(string loc)
{
return dal.getSmallLocList(loc);
}
#endregion
#region
public bool CreateBoxInfo(string boxcode, string loc, string type)
{
return dal.CreateBoxInfo(boxcode, loc, type);
}
#endregion
} }
} }

View File

@ -854,20 +854,27 @@ namespace Epost.BLL
if (data.Parameter.Length <= 2) if (data.Parameter.Length <= 2)
{ {
#region #region
DataTable quedt = queueBLL.getQueueList(); DataTable quedt = queueBLL.getQueueList();
if (quedt != null && quedt.Rows.Count > 0) if (quedt != null && quedt.Rows.Count > 0)
{ {
LogHelper.WriteLogInfo(quedt.Rows[0]["sku"].ToString()+"绑定小格口" + data.Parameter); LogHelper.WriteLogInfo(quedt.Rows[0]["sku"].ToString() + "绑定小格口" + data.Parameter);
//更新订单记录 //更新订单记录
orderbll.UpdateSkuLoc(quedt.Rows[0]["sku"].ToString(),data.Parameter); orderbll.UpdateSkuLoc(quedt.Rows[0]["sku"].ToString(), data.Parameter);
} }
else { else
{
LogHelper.WriteLogInfo("没有可绑定物料" + data.Parameter); LogHelper.WriteLogInfo("没有可绑定物料" + data.Parameter);
} }
#endregion #endregion
} }
else { else if (data.Parameter.Length > 2 && data.Parameter.Length <= 5)
{
LogHelper.WriteLogInfo("扫描满箱");
FinshLoc(data.Parameter);
}
else
{
#region SKU #region SKU
//根据扫描商品内码获取商品码 //根据扫描商品内码获取商品码
data.ScanCode = data.Parameter; data.ScanCode = data.Parameter;
@ -915,6 +922,35 @@ namespace Epost.BLL
} }
} }
} }
#endregion
#region
public bool FinshLoc(string loc)
{
bool isfin = orderbll.getSmallLocList(loc);
if (isfin)
{
DataTable locdt= addrBLL.GetALLList(" and location='"+loc+"'");
string type = string.Empty;
if (locdt != null && locdt.Rows.Count > 0)
{
type = locdt.Rows[0]["addresstype"].ToString();
}
//生成唯一箱号条码
string boxcode = ((DateTime.Now.ToUniversalTime().Ticks - 621355968000000000) / 10000000).ToString() + loc;
LogHelper.WriteLogInfo(boxcode.ToString());
bool bo = orderbll.CreateBoxInfo(boxcode, loc, type);
return bo;
}
else
{
logBLL.SaveShowMesError("小格口未完全绑定", "小格口未完全绑定,请绑定后再释放!");
return false;
}
}
#endregion #endregion
#region #region

View File

@ -696,7 +696,7 @@ namespace Epost.DAL
#region #region
public DataTable GetALLList(string strwhere) public DataTable GetALLList(string strwhere)
{ {
string sql = string.Format("select * from v_address where 1=1 " + strwhere + " "); string sql = string.Format("select * from addressstorage where 1=1 " + strwhere + " ");
DataTable dt = db.GetsqlForDT(sql); DataTable dt = db.GetsqlForDT(sql);
return dt; return dt;

View File

@ -2493,6 +2493,78 @@ namespace Epost.DAL
} }
} }
#endregion #endregion
#region
public bool getSmallLocList(string loc)
{
string sql = string.Format("select top 1 * from orders where (partcode is null or partcode='') and oprationstate=3 and fromlocation='{0}'", loc);
DataTable dt = db.GetsqlForDT(sql);
if (dt != null && dt.Rows.Count > 0)
{
return false;
}
else
{
return true;
}
}
#endregion
#region
public bool CreateBoxInfo(string boxcode, string loc, string type)
{
try
{
//添加打印信息
string printsql = string.Format("insert into print_sku(orderid,matchid,state,addtime,type) values('{0}','{1}','{2}','{3}','{4}')",
boxcode, loc, "0", DateTime.Now.ToString(), type);
int x = db.InsertSql(printsql);
if (x > 0)
{
//更新订单状态为已完成
string sql = string.Format("update orders set state =3,boxcode='{0}' where fromlocation='{1}' and state<>3 and oprationstate=3",
boxcode, loc);
long y = db.UpdateSql(sql);
LogHelper.WriteLogInfo(y + "更新订单完成" + sql);
//查询此货位是否存在未播商品
//string querysql = string.Format("select * from orders where oprationstate<>3 and fromlocation='{0}'",loc);
//DataTable querydt = db.GetsqlForDT(querysql);
//if (querydt != null && querydt.Rows.Count > 0)
//{
// LogHelper.WriteLogInfo(loc+"还有商品未分配完,不释放格口");
// //不释放格口
// return true;
//}
//else {
// //释放格口
// string upsql = string.Format("update addressstorage set bkaddress=0,addresstype='' where location='{0}'", loc);
// long b = db.UpdateSql(upsql);
// if (b > 0)
// {
// return true;
// }
// else
// {
// LogHelper.WriteLogInfo("释放格口失败" + upsql);
// return false;
// }
//}
return true;
}
else
{
LogHelper.WriteLogInfo("添加打印箱标签失败" + printsql);
return false;
}
}
catch (Exception ex)
{
LogHelper.WriteLogInfo("完成格口异常" + ex.ToString());
return false;
}
}
#endregion
} }
} }

View File

@ -11,7 +11,7 @@
<WebStackScaffolding_IsAsyncSelected>False</WebStackScaffolding_IsAsyncSelected> <WebStackScaffolding_IsAsyncSelected>False</WebStackScaffolding_IsAsyncSelected>
<WebStackScaffolding_ViewDialogWidth>600</WebStackScaffolding_ViewDialogWidth> <WebStackScaffolding_ViewDialogWidth>600</WebStackScaffolding_ViewDialogWidth>
<NameOfLastUsedPublishProfile>E:\WORK\代码管理\T系列\播种\Epost.TestToolsWeb\Properties\PublishProfiles\Toolsweb.pubxml</NameOfLastUsedPublishProfile> <NameOfLastUsedPublishProfile>E:\WORK\代码管理\T系列\播种\Epost.TestToolsWeb\Properties\PublishProfiles\Toolsweb.pubxml</NameOfLastUsedPublishProfile>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig> <LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<Use64BitIISExpress /> <Use64BitIISExpress />
<IISExpressSSLPort /> <IISExpressSSLPort />
<IISExpressAnonymousAuthentication /> <IISExpressAnonymousAuthentication />

View File

@ -7,7 +7,7 @@
<PropertyGroup> <PropertyGroup>
<TimeStampOfAssociatedLegacyPublishXmlFile /> <TimeStampOfAssociatedLegacyPublishXmlFile />
<_PublishTargetUrl>D:\驿传\T系列\taitan_songjiang_dengdai</_PublishTargetUrl> <_PublishTargetUrl>D:\驿传\T系列\taitan_songjiang_dengdai</_PublishTargetUrl>
<History>True|2024-12-27T08:58:01.4437668Z;True|2023-12-29T17:18:53.8690686+08:00;True|2023-12-26T15:40:46.3666722+08:00;True|2023-12-25T15:43:42.7553160+08:00;True|2023-12-15T15:23:23.0482897+08:00;True|2023-12-15T13:44:34.3203359+08:00;False|2023-12-15T13:42:34.6149508+08:00;True|2023-12-14T17:25:24.5353788+08:00;True|2023-11-30T19:07:23.8812051+08:00;True|2023-04-23T15:53:28.0062911+08:00;True|2023-04-22T10:28:09.9896404+08:00;True|2023-04-20T10:35:53.5768979+08:00;True|2022-07-15T16:41:13.9750291+08:00;True|2022-07-14T14:02:20.7983427+08:00;True|2022-07-13T17:40:22.7531000+08:00;True|2022-07-13T17:34:22.9908701+08:00;True|2022-07-13T17:30:06.3588502+08:00;True|2022-07-11T10:32:06.9053981+08:00;True|2021-04-26T10:07:37.4889549+08:00;True|2021-04-09T10:32:51.9130162+08:00;True|2021-04-09T10:31:50.4974012+08:00;</History> <History>True|2025-01-10T07:38:19.0722445Z;True|2024-12-27T16:58:01.4437668+08:00;True|2023-12-29T17:18:53.8690686+08:00;True|2023-12-26T15:40:46.3666722+08:00;True|2023-12-25T15:43:42.7553160+08:00;True|2023-12-15T15:23:23.0482897+08:00;True|2023-12-15T13:44:34.3203359+08:00;False|2023-12-15T13:42:34.6149508+08:00;True|2023-12-14T17:25:24.5353788+08:00;True|2023-11-30T19:07:23.8812051+08:00;True|2023-04-23T15:53:28.0062911+08:00;True|2023-04-22T10:28:09.9896404+08:00;True|2023-04-20T10:35:53.5768979+08:00;True|2022-07-15T16:41:13.9750291+08:00;True|2022-07-14T14:02:20.7983427+08:00;True|2022-07-13T17:40:22.7531000+08:00;True|2022-07-13T17:34:22.9908701+08:00;True|2022-07-13T17:30:06.3588502+08:00;True|2022-07-11T10:32:06.9053981+08:00;True|2021-04-26T10:07:37.4889549+08:00;True|2021-04-09T10:32:51.9130162+08:00;True|2021-04-09T10:31:50.4974012+08:00;</History>
<LastFailureDetails /> <LastFailureDetails />
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
@ -33,19 +33,19 @@
<publishTime>04/04/2018 15:45:12</publishTime> <publishTime>04/04/2018 15:45:12</publishTime>
</File> </File>
<File Include="bin/App_global.asax.compiled"> <File Include="bin/App_global.asax.compiled">
<publishTime>12/27/2024 16:57:57</publishTime> <publishTime>01/10/2025 15:44:50</publishTime>
</File> </File>
<File Include="bin/App_global.asax.dll"> <File Include="bin/App_global.asax.dll">
<publishTime>12/27/2024 16:57:57</publishTime> <publishTime>01/10/2025 15:44:50</publishTime>
</File> </File>
<File Include="bin/BouncyCastle.Crypto.dll"> <File Include="bin/BouncyCastle.Crypto.dll">
<publishTime>02/24/2020 15:29:24</publishTime> <publishTime>02/24/2020 15:29:24</publishTime>
</File> </File>
<File Include="bin/Common.dll"> <File Include="bin/Common.dll">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:54</publishTime>
</File> </File>
<File Include="bin/Common.pdb"> <File Include="bin/Common.pdb">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:54</publishTime>
</File> </File>
<File Include="bin/ComposerSDK.dll"> <File Include="bin/ComposerSDK.dll">
<publishTime>04/29/2020 16:50:14</publishTime> <publishTime>04/29/2020 16:50:14</publishTime>
@ -63,31 +63,31 @@
<publishTime>10/23/2017 13:15:20</publishTime> <publishTime>10/23/2017 13:15:20</publishTime>
</File> </File>
<File Include="bin/Epost.BLL.dll"> <File Include="bin/Epost.BLL.dll">
<publishTime>12/27/2024 16:57:37</publishTime> <publishTime>01/10/2025 15:44:40</publishTime>
</File> </File>
<File Include="bin/Epost.BLL.pdb"> <File Include="bin/Epost.BLL.pdb">
<publishTime>12/27/2024 16:57:37</publishTime> <publishTime>01/10/2025 15:44:40</publishTime>
</File> </File>
<File Include="bin/Epost.BLL.XmlSerializers.dll"> <File Include="bin/Epost.BLL.XmlSerializers.dll">
<publishTime>08/26/2020 18:09:48</publishTime> <publishTime>08/26/2020 18:09:48</publishTime>
</File> </File>
<File Include="bin/Epost.DAL.dll"> <File Include="bin/Epost.DAL.dll">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:54</publishTime>
</File> </File>
<File Include="bin/Epost.DAL.pdb"> <File Include="bin/Epost.DAL.pdb">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:54</publishTime>
</File> </File>
<File Include="bin/Epost.DPS.dll"> <File Include="bin/Epost.DPS.dll">
<publishTime>12/27/2024 16:57:40</publishTime> <publishTime>01/10/2025 15:44:42</publishTime>
</File> </File>
<File Include="bin/Epost.DPS.pdb"> <File Include="bin/Epost.DPS.pdb">
<publishTime>12/27/2024 16:57:40</publishTime> <publishTime>01/10/2025 15:44:42</publishTime>
</File> </File>
<File Include="bin/Epost.Model.dll"> <File Include="bin/Epost.Model.dll">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:53</publishTime>
</File> </File>
<File Include="bin/Epost.Model.pdb"> <File Include="bin/Epost.Model.pdb">
<publishTime>12/27/2024 16:57:36</publishTime> <publishTime>01/10/2025 15:37:53</publishTime>
</File> </File>
<File Include="bin/Epost.TestToolsWeb.dll"> <File Include="bin/Epost.TestToolsWeb.dll">
<publishTime>09/06/2018 11:57:11</publishTime> <publishTime>09/06/2018 11:57:11</publishTime>
@ -5658,7 +5658,7 @@
<publishTime>05/30/2022 16:58:47</publishTime> <publishTime>05/30/2022 16:58:47</publishTime>
</File> </File>
<File Include="PrecompiledApp.config"> <File Include="PrecompiledApp.config">
<publishTime>12/27/2024 16:57:42</publishTime> <publishTime>01/10/2025 15:44:44</publishTime>
</File> </File>
<File Include="Scripts/ai.0.22.9-build00167.js"> <File Include="Scripts/ai.0.22.9-build00167.js">
<publishTime>04/04/2018 15:45:12</publishTime> <publishTime>04/04/2018 15:45:12</publishTime>
@ -7578,7 +7578,7 @@
<publishTime>07/04/2022 14:22:38</publishTime> <publishTime>07/04/2022 14:22:38</publishTime>
</File> </File>
<File Include="Web.config"> <File Include="Web.config">
<publishTime>12/27/2024 16:57:41</publishTime> <publishTime>01/10/2025 15:38:00</publishTime>
</File> </File>
</ItemGroup> </ItemGroup>
</Project> </Project>