修复bug

This commit is contained in:
18942506660
2023-12-29 14:46:39 +08:00
parent 38f9633191
commit 2e2806c3b0
3 changed files with 6 additions and 4 deletions

View File

@@ -218,10 +218,7 @@ namespace WMS.Web.Domain.Services
UnitId = new ErpNumberDto(unitNumber), //物料带出来 UnitId = new ErpNumberDto(unitNumber), //物料带出来
StockId = new ErpNumberDto(d.StockCode), StockId = new ErpNumberDto(d.StockCode),
SubStockId = new ErpSubStockDto(d.StockCode, d.Erp_SubStockCode), SubStockId = new ErpSubStockDto(d.StockCode, d.Erp_SubStockCode),
//BeforeQty = d.BeforeQty,
AfterQty = d.AfterQty, AfterQty = d.AfterQty,
//FinalQty = entity.ResultType == TakeStockType.Profit ? d.FinalQty : 0,
//LossQty = entity.ResultType == TakeStockType.Loss ? d.FinalQty : 0,
Fnote = d.Remark Fnote = d.Remark
}); });
} }

View File

@@ -49,6 +49,11 @@ namespace WMS.Web.Repositories.Configuration
{ {
ent.ToTable("t_wms_movebox_record"); ent.ToTable("t_wms_movebox_record");
ent.HasKey(x => x.Id); ent.HasKey(x => x.Id);
ent.HasMany(p => p.Details)
.WithOne()
.HasForeignKey(p => p.Fid)
.OnDelete(DeleteBehavior.Cascade);
}); });
//移箱明细 //移箱明细
builder.Entity<MoveBoxRecordDetails>(ent => builder.Entity<MoveBoxRecordDetails>(ent =>

View File

@@ -101,7 +101,7 @@ namespace WMS.Web.Repositories
_transaction.Commit(); _transaction.Commit();
return true; return true;
} }
catch catch(Exception ex)
{ {
if (_transaction != null) if (_transaction != null)
_transaction.Rollback(); _transaction.Rollback();