获取入货场站信息新接口

usertest
cjy 4 months ago
parent 11bef9e5ae
commit 4ad313e57d

@ -1,7 +1,9 @@
using DS.Module.Core; using DS.Module.Core;
using DS.Module.Core.Data; using DS.Module.Core.Data;
using DS.Module.SqlSugar;
using DS.WMS.Core.Info.Dtos; using DS.WMS.Core.Info.Dtos;
using DS.WMS.Core.Op.Dtos; using DS.WMS.Core.Op.Dtos;
using DS.WMS.Core.Op.Entity;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
@ -36,7 +38,12 @@ namespace DS.WMS.Core.Op.Interface
/// <param name="id"></param> /// <param name="id"></param>
/// <returns></returns> /// <returns></returns>
DataResult<OpBusinessYardRes> GetOpBusinessYardInfo(string id); DataResult<OpBusinessYardRes> GetOpBusinessYardInfo(string id);
/// <summary>
/// 获取详情按业务id
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
public DataResult<OpBusinessYardRes> GetBusinessYardByKeyId(string id);
/// <summary> /// <summary>
/// 批量删除 /// 批量删除
/// </summary> /// </summary>

@ -83,7 +83,15 @@ namespace DS.WMS.Core.Op.Method
.First(); .First();
return DataResult<OpBusinessYardRes>.Success(data, MultiLanguageConst.DataQuerySuccess); return DataResult<OpBusinessYardRes>.Success(data, MultiLanguageConst.DataQuerySuccess);
} }
public DataResult<OpBusinessYardRes> GetBusinessYardByKeyId(string id)
{
var tenantDb = saasService.GetBizDbScopeById(user.TenantId);
var data = tenantDb.Queryable<BusinessYard>()
.Where(a => a.BusinessId == long.Parse(id))
.Select<OpBusinessYardRes>()
.First();
return DataResult<OpBusinessYardRes>.Success(data, MultiLanguageConst.DataQuerySuccess);
}
public DataResult BatchDelOpBusinessYard(IdModel req) public DataResult BatchDelOpBusinessYard(IdModel req)
{ {
var tenantDb = saasService.GetBizDbScopeById(user.TenantId); var tenantDb = saasService.GetBizDbScopeById(user.TenantId);

@ -63,7 +63,18 @@ public class OpBusinessYardController : ApiController
var res = _invokeService.GetOpBusinessYardInfo(id); var res = _invokeService.GetOpBusinessYardInfo(id);
return res; return res;
} }
/// <summary>
/// 根据业务id详情
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
[Route("GetBusinessYardByKeyId")]
public DataResult<OpBusinessYardRes> GetBusinessYardByKeyId([FromQuery] string id)
{
var res = _invokeService.GetBusinessYardByKeyId(id);
return res;
}
/// <summary> /// <summary>
/// 批量删除 /// 批量删除
/// </summary> /// </summary>

Loading…
Cancel
Save