소스 검색

物料上传接口修改20240919

kitchenmanage
gwbvipvip 1 개월 전
부모
커밋
a4d18a4aac
1개의 변경된 파일10개의 추가작업 그리고 9개의 파일을 삭제
  1. +10
    -9
      BPA.SAAS.Manage.Application/AExternalPlatform/Service/Material/Services/MaterialService.cs

+ 10
- 9
BPA.SAAS.Manage.Application/AExternalPlatform/Service/Material/Services/MaterialService.cs 파일 보기

@@ -75,16 +75,9 @@ namespace BPA.SAAS.Manage.Application.AExternalPlatform.Service.Material.Service
{ {
try try
{ {
SqlSugarDb.Db.Ado.BeginTran();
var userId = await _checkServices.GetUserId(App.HttpContext.Request.Headers["key"].ToString()); var userId = await _checkServices.GetUserId(App.HttpContext.Request.Headers["key"].ToString());
var batchingList = await SqlSugarDb.Db.Queryable<BPA_Batching>().ToListAsync();
var typeList = await SqlSugarDb.Db.Queryable<BPA_BatchingType>().ToListAsync();
var uintList = await SqlSugarDb.Db.Queryable<BPA_BatchingUint>().ToListAsync();
var typeIdList = new List<string>();
var uintIdList = new List<string>();
var repeatList = new List<ResponseMessageDto>();
var successList = new List<ResponseMessageDto>();
var defaultUintData = uintList.FirstOrDefault(t => t.Name == "g" || t.Name == "默认单位");
var oldUintList = await SqlSugarDb.Db.Queryable<BPA_BatchingUint>().ToListAsync();
var defaultUintData = oldUintList.FirstOrDefault(t => t.Name == "g" || t.Name == "默认单位");
var defaultUint = new DefaultUintDto(); var defaultUint = new DefaultUintDto();
if (defaultUintData != null) if (defaultUintData != null)
{ {
@@ -103,6 +96,14 @@ namespace BPA.SAAS.Manage.Application.AExternalPlatform.Service.Material.Service
defaultUint.Id = dUint.Id; defaultUint.Id = dUint.Id;
defaultUint.Name = dUint.Name; defaultUint.Name = dUint.Name;
} }
SqlSugarDb.Db.Ado.BeginTran();
var batchingList = await SqlSugarDb.Db.Queryable<BPA_Batching>().ToListAsync();
var typeList = await SqlSugarDb.Db.Queryable<BPA_BatchingType>().ToListAsync();
var uintList = await SqlSugarDb.Db.Queryable<BPA_BatchingUint>().ToListAsync();
var typeIdList = new List<string>();
var uintIdList = new List<string>();
var repeatList = new List<ResponseMessageDto>();
var successList = new List<ResponseMessageDto>();
var typeAddList = new List<BPA_BatchingType>(); var typeAddList = new List<BPA_BatchingType>();
var typeUpdateList = new List<BPA_BatchingType>(); var typeUpdateList = new List<BPA_BatchingType>();
var uintAddList = new List<BPA_BatchingUint>(); var uintAddList = new List<BPA_BatchingUint>();


불러오는 중...
취소
저장