基础服务api
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

72 lignes
2.6 KiB

  1. using BPA.SAAS.Manage.Application.DataBase.Dtos.GoodsAttributePrice;
  2. using BPA.SAAS.Manage.Application.DataBase.Interface;
  3. using BPA.SAAS.Manage.Core.Base;
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. namespace BPA.SAAS.Manage.Application.DataBase
  10. {
  11. [ApiDescriptionSettings("GoodsAttributePrice", Tag = "商品属性价格")]
  12. public class GoodsAttributePriceServices: IDynamicApiController
  13. {
  14. IGoodsAttributePriceService _goodsAttributePriceService;
  15. public GoodsAttributePriceServices(IGoodsAttributePriceService goodsAttributePriceService)
  16. {
  17. _goodsAttributePriceService=goodsAttributePriceService;
  18. }
  19. /// <summary>
  20. /// 分页查询
  21. /// </summary>
  22. /// <param name="dto"></param>
  23. /// <returns></returns>
  24. [HttpPost("/api/goodsattributeprice/getpage")]
  25. public async Task<PageUtil> GetGoodsAttributePricePage(GoodsAttributePriceQueryDto dto)
  26. {
  27. return await _goodsAttributePriceService.GetGoodsAttributePricePage(dto);
  28. }
  29. /// <summary>
  30. /// 查询商品属性价格列表
  31. /// </summary>
  32. /// <param name="goodsId"></param>
  33. /// <returns></returns>
  34. [HttpGet("/api/goodsattributeprice/getlist")]
  35. public async Task<List<GoodsAttributePriceView>> GetGoodsAttributePriceList(string goodsId)
  36. {
  37. return await _goodsAttributePriceService.GetGoodsAttributePriceList(goodsId);
  38. }
  39. /// <summary>
  40. /// 添加
  41. /// </summary>
  42. /// <param name="dto"></param>
  43. /// <returns></returns>
  44. [HttpPost("/api/goodsattributeprice/add")]
  45. public async Task<bool> AddGoodsAttributePrice(GoodsAttributePriceDto dto)
  46. {
  47. return await _goodsAttributePriceService.AddGoodsAttributePrice(dto);
  48. }
  49. /// <summary>
  50. /// 更新
  51. /// </summary>
  52. /// <param name="dto"></param>
  53. /// <returns></returns>
  54. [HttpPost("/api/goodsattributeprice/update")]
  55. public async Task<bool> UpdateGoodsAttributePrice(GoodsAttributePriceDto dto)
  56. {
  57. return await _goodsAttributePriceService.UpdateGoodsAttributePrice(dto);
  58. }
  59. /// <summary>
  60. /// 删除
  61. /// </summary>
  62. /// <param name="Id"></param>
  63. /// <returns></returns>
  64. [HttpGet("/api/goodsattributeprice/delete")]
  65. public async Task<bool> DelGoodsAttributePrice(string Id)
  66. {
  67. return await _goodsAttributePriceService.DelGoodsAttributePrice(Id);
  68. }
  69. }
  70. }