diff --git a/src/Modules/新版JIT或JIS系统服务端/src/WY.NewJit.Domain/MsgCheck/Services/BillNumberRecordDomainService.cs b/src/Modules/新版JIT或JIS系统服务端/src/WY.NewJit.Domain/MsgCheck/Services/BillNumberRecordDomainService.cs index d2ce9cb..54b1b02 100644 --- a/src/Modules/新版JIT或JIS系统服务端/src/WY.NewJit.Domain/MsgCheck/Services/BillNumberRecordDomainService.cs +++ b/src/Modules/新版JIT或JIS系统服务端/src/WY.NewJit.Domain/MsgCheck/Services/BillNumberRecordDomainService.cs @@ -4,6 +4,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; +using Volo.Abp; using Volo.Abp.Domain.Repositories; using Volo.Abp.Domain.Services; using WY.NewJit.MsgBaseData; @@ -75,6 +76,11 @@ namespace WY.NewJit.MsgCheck { List datas = new List(); var recordcache= _billNumberRecordCaches.FirstOrDefault(r=>r.ProductLine==productLine); + if (recordcache == null) + { + _logger.LogDebug("缓存记录为空无法解析!"); + throw new BusinessException("1001", "缓存记录为空无法解析!"); + } int recordNumber = recordcache.RecordNumber;//记录号 int roundNumber = recordcache.RoundNumber; //记录轮数 int x = number - recordNumber;