|
|
|
@ -80,12 +80,29 @@ namespace SlnMesnac.Business
|
|
|
|
|
_mesProductOrderService = serviceProvider.GetRequiredService<IMesProductOrderService>();
|
|
|
|
|
_baseMaterialInfoService = serviceProvider.GetRequiredService<IBaseMaterialInfoService>();
|
|
|
|
|
Init();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void test()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
sqlSugarClient.AsTenant().BeginTran();
|
|
|
|
|
string palletCode1 = "";
|
|
|
|
|
|
|
|
|
|
WmsBaseLocation source = sqlSugarClient.AsTenant().GetConnection("mes").Queryable<WmsBaseLocation>().Where(x => x.LocationCode == "3114").First();
|
|
|
|
|
WmsBaseLocation target = sqlSugarClient.AsTenant().GetConnection("mes").Queryable<WmsBaseLocation>().Where(x => x.LocationCode == "3314").First();
|
|
|
|
|
palletCode1 = source.ContainerCode;
|
|
|
|
|
|
|
|
|
|
source.ContainerCode = target.ContainerCode;
|
|
|
|
|
target.ContainerCode = palletCode1;
|
|
|
|
|
sqlSugarClient.AsTenant().GetConnection("mes").Updateable<WmsBaseLocation>(source).ExecuteCommand();
|
|
|
|
|
sqlSugarClient.AsTenant().GetConnection("mes").Updateable<WmsBaseLocation>(target).ExecuteCommand();
|
|
|
|
|
sqlSugarClient.AsTenant().CommitTran();
|
|
|
|
|
}catch(Exception ex)
|
|
|
|
|
{
|
|
|
|
|
sqlSugarClient.AsTenant().RollbackTran();
|
|
|
|
|
}
|
|
|
|
|
// MesProductPlanDetail? mesProductPlanDetail = sqlSugarClient.AsTenant().GetConnection("mes").Queryable<MesProductPlanDetail>().First(x => x.PlanCode == "20240724144533JL001");
|
|
|
|
|
//sqlSugarClient.AsTenant().BeginTran();
|
|
|
|
|
//string epc = "JYHB01010102";
|
|
|
|
@ -94,7 +111,7 @@ namespace SlnMesnac.Business
|
|
|
|
|
//BindingBarCode(bigCode, epc, productPlanDto);
|
|
|
|
|
//sqlSugarClient.AsTenant().BeginTran();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 3114
|
|
|
|
|
|
|
|
|
|
private static bool isEmptyPalletHandleRunning = false;
|
|
|
|
|
public void Init()
|
|
|
|
|