fix 补充代码

This commit is contained in:
2024-01-08 11:36:38 +08:00
parent b341a59359
commit a4333f7f45
9 changed files with 96 additions and 71 deletions

View File

@@ -63,10 +63,10 @@ public class OrderService : IOrderService
.FirstAsync();
var gafinfo = await _dbContext.Queryable<GainfoEntity>()
.Where(x => x.Guestno == canteenUser.UserId)
.Where(x => x.No == canteenUser.UserId)
.FirstAsync();
var settings = await _canteenSettingService.GetUserSettingAsync(gafinfo.Guestno);
var settings = await _canteenSettingService.GetUserSettingAsync(gafinfo.No);
var switchTime = GetSetting<TimeOnly>(settings, CanteenSettingItemEnumType.BusinessSwitchTime);
//金额处理
request.Amount = request.Type == BalanceRecordTypeEnumType.In ? Math.Abs(request.Amount) : -Math.Abs(request.Amount);
@@ -100,7 +100,7 @@ public class OrderService : IOrderService
ThirdNo = request.ThirdNo,
Type = request.Type.Value,
OrderStatus = CanteenOrderStatusEnumType.Wait,
Name = gafinfo.Gname,
Name = gafinfo.Name,
Source = request.Source,
UserId = canteenUser.UserId,
UserCode = canteenUser.UserCode,
@@ -109,7 +109,7 @@ public class OrderService : IOrderService
BusinessShiftCode = shift?.Code,
CostDate = costDate.Date,
CostId = canteenUser.CostId,
DepartmentNo = gafinfo.Appellation,
DepartmentNo = gafinfo.DepartmentNo,
DeviceInfo = device.Code.ToString(),
No = "O" + SnowFlakeHelper.Instance.NextId(),