Browse Source

提交

master
gwbvipvip 6 months ago
parent
commit
732df4df32
27 changed files with 723 additions and 2 deletions
  1. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/BaseEPDto.cs
  2. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/DtoValidator.cs
  3. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/ResultSAASManageDto.cs
  4. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/UserAnalysis.cs
  5. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Enum/ErrorCodeEnum.cs
  6. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/AuthServices.cs
  7. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Dtos/StoreAuthDto.cs
  8. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Services/AuthService.cs
  9. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Services/IAuthService.cs
  10. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/CheckServices.cs
  11. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/Services/CheckServices.cs
  12. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/Services/ICheckServices.cs
  13. +99
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Dtos/ResultGoodsResultDto.cs
  14. +71
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Services/GoodsServices.cs
  15. +18
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Services/IGoodsServices.cs
  16. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/MaterialServices.cs
  17. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/Services/IMaterialServices.cs
  18. +0
    -0
      BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/Services/MaterialService.cs
  19. +3
    -0
      BPA.SAAS.KitChenManage.Application/BPA.SAAS.KitChenManage.Application.csproj
  20. +317
    -0
      BPA.SAAS.KitChenManage.Application/BPA.SAAS.KitChenManage.Application.xml
  21. +28
    -0
      BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs
  22. +4
    -2
      BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs
  23. +18
    -0
      BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs
  24. +99
    -0
      BPA.SAAS.KitChenManage.Application/Food/Dtos/ResultSAASManageDto.cs
  25. +11
    -0
      BPA.SAAS.KitChenManage.Application/Food/FoodMenuServices.cs
  26. +49
    -0
      BPA.SAAS.KitChenManage.Application/Food/Services/FoodMenuService.cs
  27. +6
    -0
      BPA.SAAS.KitChenManage.Application/Food/Services/IFoodMenuService.cs

BPA.SAAS.KitChenManage.Application/AExternalPlatform/BaseDto/BaseEPDto.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/BaseEPDto.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/BaseDto/DtoValidator.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/DtoValidator.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/BaseDto/ResultSAASManageDto.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/ResultSAASManageDto.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/BaseDto/UserAnalysis.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/BaseDto/UserAnalysis.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Enum/ErrorCodeEnum.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Enum/ErrorCodeEnum.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Authorization/AuthServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/AuthServices.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Authorization/Dtos/StoreAuthDto.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Dtos/StoreAuthDto.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Authorization/Services/AuthService.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Services/AuthService.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Authorization/Services/IAuthService.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Authorization/Services/IAuthService.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/CheckService/CheckServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/CheckServices.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/CheckService/Services/CheckServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/Services/CheckServices.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/CheckService/Services/ICheckServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/CheckService/Services/ICheckServices.cs View File


+ 99
- 0
BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Dtos/ResultGoodsResultDto.cs View File

@@ -0,0 +1,99 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos
{
public class ResultGoodsResultDto
{
public int statusCode { get; set; }

public List<GoodsTypeResultDto> data { get; set; }

public string succeeded { get; set; }

public string errors { get; set; }

public string extras { get; set; }

public int timestamp { get; set; }
}

public class GoodsTypeResultDto
{
public string GoodsTypeId { get; set; }

public string GoodsTypeName { get; set; }

public List<GoodsAttributeResultDto> GoodsAttributeList { get; set; }

public List<GoodsInfoResultDto> GoodsInfoList { get; set; }
}


public class GoodsAttributeResultDto
{
public string GoodsAttributeId { get; set; }

public string GoodsAttributeName { get; set; }

public List<GoodsAttributeValueResultDto> GoodsAttributeValueList { get; set; }
}

public class GoodsAttributeValueResultDto
{
public string GoodsAttributeId { get; set; }
public string GoodsAttributeValueId { get; set; }
public string AttributeValue { get; set; }
}

public class GoodsResultDto
{
public string TypeId { get; set; }

public string TypeName { get; set; }
}

public class GoodsInfoResultDto
{
public string GoodsId { get; set; }

public string GoodsName { get; set; }

public List<GoodsTechnologyActionResultDto> GoodsTechnologyActionList { get; set; }
}

public class GoodsTechnologyActionResultDto
{
/// <summary>
/// 步骤名称
/// </summary>
public string StepName { get; set; }
/// <summary>
/// 动作json
/// </summary>
public string ActionJson { get; set; }
/// <summary>
/// 商品属性id集合
/// </summary>
public string GoodsAttributeId { get; set; }
/// <summary>
/// 是否物料
/// </summary>
public bool IsBatch { get; set; }
/// <summary>
/// 动作value
/// </summary>
public string ChnologyId { get; set; }
public string GroupId { get; set; }
public int Sort { get; set; }
public string GoodsId { get; set; }
public string DeviceId { get; set; }
/// <summary>
/// 仓位模板
/// </summary>
public string WarehousrTemplateId { get; set; }
}
}

+ 71
- 0
BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Services/GoodsServices.cs View File

@@ -0,0 +1,71 @@
using BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto;
using BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos;
using BPA.SAAS.KitChenManage.Comm.Tool;
using BPA.SAAS.KitChenManage.Core.Model;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Services
{

[ApiDescriptionSettings("开放平台", Tag = "商品信息"), AllowAnonymous, NonUnify]
public class Goods: IGoodsServices, ITransient,IDynamicApiController
{

private readonly ISqlSugarClient _db;
public Goods(ISqlSugarClient db)
{
_db = db;
}
/// <summary>
/// 获取设备物料信息
/// </summary>
/// <returns></returns>
[HttpPost("/api/goods/Getdevicegoods")]
public async Task<ResultGoodsResultDto> GetDeviceGoods(string deviceId)
{


var goodsId = await _db.Queryable<BPA_DeviceGoods>()
.Where(x => x.DeviceId == deviceId)
.Select(x => x.GoodsId)
.ToListAsync();

var data = await GetDeviceGoodspost(goodsId);

return data;
}


/// <summary>
/// 获取商品信息
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
public async Task<ResultGoodsResultDto> GetDeviceGoodspost(List<string> goodsList)
{
try
{


Dictionary<string, string> dic = new Dictionary<string, string>();
var url = App.Configuration["baseurl"] + "api/goods/GetGoodsListByIds";
var inputData = JsonConvert.SerializeObject(goodsList);
var jsonData = HttpHelper.PostData(url, inputData, Encoding.UTF8, "application/json", dic);
var data = JsonConvert.DeserializeObject<ResultGoodsResultDto>(jsonData);
return data;
}
catch (Exception ex)
{

throw Oops.Oh("获取商品失败");
}


}
}
}

+ 18
- 0
BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Goods/Services/IGoodsServices.cs View File

@@ -0,0 +1,18 @@
using BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Services
{
public interface IGoodsServices
{
/// <summary>
/// 获取设备物料信息
/// </summary>
/// <returns></returns>
Task<ResultGoodsResultDto> GetDeviceGoods(string deviceId);
}
}

BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Platform/Material/MaterialServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/MaterialServices.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Platform/Material/Services/IMaterialServices.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/Services/IMaterialServices.cs View File


BPA.SAAS.KitChenManage.Application/AExternalPlatform/Service/Platform/Material/Services/MaterialService.cs → BPA.SAAS.KitChenManage.Application/AExternalPlatform1/Service/Platform/Material/Services/MaterialService.cs View File


+ 3
- 0
BPA.SAAS.KitChenManage.Application/BPA.SAAS.KitChenManage.Application.csproj View File

@@ -10,8 +10,11 @@


<ItemGroup>
<Compile Remove="AExternalPlatform - 复制\**" />
<Compile Remove="AExternalPlatform\**" />
<EmbeddedResource Remove="AExternalPlatform - 复制\**" />
<EmbeddedResource Remove="AExternalPlatform\**" />
<None Remove="AExternalPlatform - 复制\**" />
<None Remove="AExternalPlatform\**" />
</ItemGroup>



+ 317
- 0
BPA.SAAS.KitChenManage.Application/BPA.SAAS.KitChenManage.Application.xml View File

@@ -4,6 +4,221 @@
<name>BPA.SAAS.KitChenManage.Application</name>
</assembly>
<members>
<member name="T:BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto.DtoValidator">
<summary>
Dto参数验证
</summary>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto.DtoValidator.GetSign``1(``0,System.Int32)">
<summary>
获取签名
</summary>
<typeparam name="T"></typeparam>
<param name="t"></param>
<param name="otype">0-不排序 1-按名称ASCII排序</param>
<returns></returns>
</member>
<member name="T:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum">
<summary>
系统错误码
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1000">
<summary>
用户没有注册
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1001">
<summary>
操作错误
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1002">
<summary>
重复添加
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1003">
<summary>
操作数据不存在
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1004">
<summary>
key不正确
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1005">
<summary>
签名错误
</summary>
</member>
<member name="F:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Enum.ErrorCodeEnum.Code1006">
<summary>
签名错误
</summary>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.AuthServices.GetListStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto.BaseEPDto)">
<summary>
获取店铺授权码列表
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.AuthServices.GetStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
获取店铺授权码
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.AuthServices.AddStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
添加店铺授权码
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.AuthServices.UpdateStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
修改店铺授权码
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.AuthService.GetListStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto.BaseEPDto)">
<summary>
获取店铺授权码列表
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.AuthService.GetStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
获取店铺授权码
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.AuthService.AddStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
添加店铺授权码
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.AuthService.UpdateStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
修改店铺授权码
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.IAuthService.GetListStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.BaseDto.BaseEPDto)">
<summary>
获取店铺授权码列表
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.IAuthService.GetStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
获取店铺授权码
</summary>
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.IAuthService.AddStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
添加店铺授权码
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Services.IAuthService.UpdateStoreAuthKey(BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.Authorization.Dtos.StoreAuthDto)">
<summary>
修改店铺授权码
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.CheckService.Services.CheckServices.CheckSign``1(``0)">
<summary>
检查Sign
</summary>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.CheckService.Services.CheckServices.GetModelValue``1(``0,System.String)">
<summary>
获取模型值
</summary>
<typeparam name="T"></typeparam>
<param name="t"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.CheckService.Services.CheckServices.CheckKey(System.String)">
<summary>
检查店铺key验证
</summary>
<param name="key"></param>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.CheckService.Services.CheckServices.CheckTenant(System.String)">
<summary>
检查租户
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform.Service.CheckService.Services.ICheckServices.CheckSign``1(``0)">
<summary>
检查Sign
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.StepName">
<summary>
步骤名称
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.ActionJson">
<summary>
动作json
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.GoodsAttributeId">
<summary>
商品属性id集合
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.IsBatch">
<summary>
是否物料
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.ChnologyId">
<summary>
动作value
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Dtos.GoodsTechnologyActionResultDto.WarehousrTemplateId">
<summary>
仓位模板
</summary>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Services.Goods.GetDeviceGoods(System.String)">
<summary>
获取设备物料信息
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Services.Goods.GetDeviceGoodspost(System.Collections.Generic.List{System.String})">
<summary>
获取商品信息
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.AExternalPlatform1.Service.Goods.Services.IGoodsServices.GetDeviceGoods(System.String)">
<summary>
获取设备物料信息
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Authorization.AuthorizationServices.PageStoreAuthorization(BPA.SAAS.KitChenManage.Core.Base.PageInputBase)">
<summary>
分页店铺授权码
@@ -171,6 +386,20 @@
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.DevicePushRecodeServices.GetDeviceGoods(System.String)">
<summary>
获取设备商品
</summary>
<param name="deviceId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.DevicePushRecodeServices.EditDeviceGoods(BPA.SAAS.KitChenManage.Application.Device.Dtos.DeviceGoodsInputDto)">
<summary>
编辑设备商品
</summary>
<param name="inputDto"></param>
<returns></returns>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Device.Dtos.ProductTopics.Topics">
<summary>
Topics类
@@ -339,6 +568,20 @@
<param name="callbackUrl"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.Services.DevicePushRecodeService.GetDeviceGoods(System.String)">
<summary>
获取设备商品
</summary>
<param name="deviceId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.Services.DevicePushRecodeService.EditDeviceGoods(BPA.SAAS.KitChenManage.Application.Device.Dtos.DeviceGoodsInputDto)">
<summary>
编辑设备商品
</summary>
<param name="inputDto"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.Services.IDevicePushRecodeService.Page(BPA.SAAS.KitChenManage.Application.Device.Dtos.DevicePushRecodeDtoPageInput)">
<summary>
分页
@@ -367,6 +610,20 @@
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.Services.IDevicePushRecodeService.GetDeviceGoods(System.String)">
<summary>
获取设备商品
</summary>
<param name="deviceId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Device.Services.IDevicePushRecodeService.EditDeviceGoods(BPA.SAAS.KitChenManage.Application.Device.Dtos.DeviceGoodsInputDto)">
<summary>
编辑设备商品
</summary>
<param name="inputDto"></param>
<returns></returns>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.FoodMenuBaseDto.GoodsIds">
<summary>
商品菜品id
@@ -377,6 +634,36 @@
菜谱信息表
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.StepName">
<summary>
步骤名称
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.ActionJson">
<summary>
动作json
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.GoodsAttributeId">
<summary>
商品属性id集合
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.IsBatch">
<summary>
是否物料
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.ChnologyId">
<summary>
动作value
</summary>
</member>
<member name="P:BPA.SAAS.KitChenManage.Application.Food.Dtos.GoodsTechnologyActionResultDto.WarehousrTemplateId">
<summary>
仓位模板
</summary>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.FoodMenuServices.Page(BPA.SAAS.KitChenManage.Application.Food.Dtos.FoodMenuDtoPageInput)">
<summary>
分页查询
@@ -419,6 +706,12 @@
<param name="foodMenuId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.FoodMenuServices.GetDeviceGoods(System.String)">
<summary>
获取设备物料信息
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.Services.FoodMenuService.Page(BPA.SAAS.KitChenManage.Application.Food.Dtos.FoodMenuDtoPageInput)">
<summary>
分页
@@ -461,6 +754,19 @@
<param name="foodMenuId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.Services.FoodMenuService.GetDeviceGoods(System.String)">
<summary>
获取设备物料信息
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.Services.FoodMenuService.GetDeviceGoodspost(System.Collections.Generic.List{System.String})">
<summary>
获取商品信息
</summary>
<param name="id"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.Services.IFoodMenuService.Page(BPA.SAAS.KitChenManage.Application.Food.Dtos.FoodMenuDtoPageInput)">
<summary>
分页
@@ -503,6 +809,12 @@
<param name="foodMenuId"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Food.Services.IFoodMenuService.GetDeviceGoods(System.String)">
<summary>
获取设备物料信息
</summary>
<returns></returns>
</member>
<member name="M:BPA.SAAS.KitChenManage.Application.Push.Comm.CommDefaultHandle.GetDynamic(System.Object,System.Object)">
<summary>
映射数据
@@ -803,5 +1115,10 @@
<param name="input"></param>
<returns></returns>
</member>
<member name="M:BPA.SAAS.Manage.Application.AExternalPlatform.Service.CheckService.CheckServices.CheckSign``1(``0)">
<summary>
检查Sign
</summary>
</member>
</members>
</doc>

+ 28
- 0
BPA.SAAS.KitChenManage.Application/Device/DevicePushRecodeServices.cs View File

@@ -72,5 +72,33 @@ namespace BPA.SAAS.KitChenManage.Application.Device
{
return await _devicePushRecodeService.Delete(input);
}



#region 设备商品

/// <summary>
/// 获取设备商品
/// </summary>
/// <param name="deviceId"></param>
/// <returns></returns>
[HttpPost("/api/devicepushrecode/getdevicegoods")]
public async Task<List<Goods>> GetDeviceGoods(string deviceId)
{
return await _devicePushRecodeService.GetDeviceGoods(deviceId);
}

/// <summary>
/// 编辑设备商品
/// </summary>
/// <param name="inputDto"></param>
/// <returns></returns>
[HttpPost("/api/devicepushrecode/editdevicegoods")]
public async Task<bool> EditDeviceGoods(DeviceGoodsInputDto inputDto)
{
return await _devicePushRecodeService.EditDeviceGoods(inputDto);
}

#endregion
}
}

+ 4
- 2
BPA.SAAS.KitChenManage.Application/Device/Services/DevicePushRecodeService.cs View File

@@ -343,7 +343,7 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services
{
var result = new List<Goods>();

result = await _db.Queryable<BPA_DeviceGoods>().Where(x => x.DeviceId == deviceId)
result = await _db.Queryable<BPA_DeviceGoods>()
.Select(x => new Goods()
{
GoodsId = x.GoodsId,
@@ -372,6 +372,7 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services
{
list.Add(new BPA_DeviceGoods()
{
Id=Guid.NewGuid().ToString(),
DeviceId = inputDto.DeviceId,
GoodsId = item.GoodsId,
GoodsName = item.GoodsName,
@@ -379,9 +380,10 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services
}
var res = await _db.Insertable(list).ExecuteCommandAsync();

return res > 0;

_db.Ado.CommitTran();

return res > 0;
}
catch (Exception e)
{


+ 18
- 0
BPA.SAAS.KitChenManage.Application/Device/Services/IDevicePushRecodeService.cs View File

@@ -36,5 +36,23 @@ namespace BPA.SAAS.KitChenManage.Application.Device.Services
/// <param name="input"></param>
/// <returns></returns>
Task<bool> Delete(List<string> input);

#region 设备商品

/// <summary>
/// 获取设备商品
/// </summary>
/// <param name="deviceId"></param>
/// <returns></returns>
Task<List<Goods>> GetDeviceGoods(string deviceId);

/// <summary>
/// 编辑设备商品
/// </summary>
/// <param name="inputDto"></param>
/// <returns></returns>
Task<bool> EditDeviceGoods(DeviceGoodsInputDto inputDto);

#endregion
}
}

+ 99
- 0
BPA.SAAS.KitChenManage.Application/Food/Dtos/ResultSAASManageDto.cs View File

@@ -0,0 +1,99 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BPA.SAAS.KitChenManage.Application.Food.Dtos
{
public class ResultSAASManageDto
{
public int statusCode { get; set; }

public List<GoodsTypeResultDto> data { get; set; }

public string succeeded { get; set; }

public string errors { get; set; }

public string extras { get; set; }

public int timestamp { get; set; }
}

public class GoodsTypeResultDto
{
public string GoodsTypeId { get; set; }

public string GoodsTypeName { get; set; }

public List<GoodsAttributeResultDto> GoodsAttributeList { get; set; }

public List<GoodsInfoResultDto> GoodsInfoList { get; set; }
}


public class GoodsAttributeResultDto
{
public string GoodsAttributeId { get; set; }

public string GoodsAttributeName { get; set; }

public List<GoodsAttributeValueResultDto> GoodsAttributeValueList { get; set; }
}

public class GoodsAttributeValueResultDto
{
public string GoodsAttributeId { get; set; }
public string GoodsAttributeValueId { get; set; }
public string AttributeValue { get; set; }
}

public class GoodsResultDto
{
public string TypeId { get; set; }

public string TypeName { get; set; }
}

public class GoodsInfoResultDto
{
public string GoodsId { get; set; }

public string GoodsName { get; set; }

public List<GoodsTechnologyActionResultDto> GoodsTechnologyActionList { get; set; }
}

public class GoodsTechnologyActionResultDto
{
/// <summary>
/// 步骤名称
/// </summary>
public string StepName { get; set; }
/// <summary>
/// 动作json
/// </summary>
public string ActionJson { get; set; }
/// <summary>
/// 商品属性id集合
/// </summary>
public string GoodsAttributeId { get; set; }
/// <summary>
/// 是否物料
/// </summary>
public bool IsBatch { get; set; }
/// <summary>
/// 动作value
/// </summary>
public string ChnologyId { get; set; }
public string GroupId { get; set; }
public int Sort { get; set; }
public string GoodsId { get; set; }
public string DeviceId { get; set; }
/// <summary>
/// 仓位模板
/// </summary>
public string WarehousrTemplateId { get; set; }
}
}

+ 11
- 0
BPA.SAAS.KitChenManage.Application/Food/FoodMenuServices.cs View File

@@ -81,5 +81,16 @@ namespace BPA.SAAS.KitChenManage.Application.Food
{
return await _foodmenuService.GetFoodMenuGoods(foodMenuId);
}

/// <summary>
/// 获取设备物料信息
/// </summary>
/// <returns></returns>
[HttpGet("/api/foodmenu/getdevicegoods")]
public async Task<ResultSAASManageDto> GetDeviceGoods(string deviceId)
{
return await _foodmenuService.GetDeviceGoods(deviceId);
}
}
}

+ 49
- 0
BPA.SAAS.KitChenManage.Application/Food/Services/FoodMenuService.cs View File

@@ -1,9 +1,11 @@
using BPA.SAAS.KitChenManage.Application.Food.Dtos;
using BPA.SAAS.KitChenManage.Application.Store.Dtos;
using BPA.SAAS.KitChenManage.Application.Store.Services;
using BPA.SAAS.KitChenManage.Comm.Tool;
using BPA.SAAS.KitChenManage.Core.Base;
using BPA.SAAS.KitChenManage.Core.Model;
using Furion.LinqBuilder;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
@@ -127,5 +129,52 @@ namespace BPA.SAAS.KitChenManage.Application.Food.Services
{
return await _db.Queryable<BPA_FoodMenuGoods>().Where(x => x.FoodMenuId == foodMenuId).ToListAsync();
}


/// <summary>
/// 获取设备物料信息
/// </summary>
/// <returns></returns>
public async Task<ResultSAASManageDto> GetDeviceGoods(string deviceId)
{


var goodsId =await _db.Queryable<BPA_DeviceGoods>()
.Where(x => x.DeviceId == deviceId)
.Select(x => x.GoodsId)
.ToListAsync();

var data = await GetDeviceGoodspost(goodsId);

return data;
}


/// <summary>
/// 获取商品信息
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
public async Task<ResultSAASManageDto> GetDeviceGoodspost(List<string> goodsList)
{
try
{


Dictionary<string, string> dic = new Dictionary<string, string>();
var url = App.Configuration["baseurl"] + "api/goods/GetGoodsListByIds";
var inputData = JsonConvert.SerializeObject(goodsList);
var jsonData = HttpHelper.PostData(url, inputData, Encoding.UTF8, "application/json", dic);
var data = JsonConvert.DeserializeObject<ResultSAASManageDto>(jsonData);
return data;
}
catch (Exception ex)
{

throw Oops.Oh("获取商品失败");
}

}
}
}

+ 6
- 0
BPA.SAAS.KitChenManage.Application/Food/Services/IFoodMenuService.cs View File

@@ -48,5 +48,11 @@ namespace BPA.SAAS.KitChenManage.Application.Food.Services
/// <param name="foodMenuId"></param>
/// <returns></returns>
Task<List<BPA_FoodMenuGoods>> GetFoodMenuGoods(string foodMenuId);

/// <summary>
/// 获取设备物料信息
/// </summary>
/// <returns></returns>
Task<ResultSAASManageDto> GetDeviceGoods(string deviceId);
}
}

Loading…
Cancel
Save