IPartnerAppService.cs
3.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
using FoodLabeling.Application.Contracts.Dtos.Common;
using FoodLabeling.Application.Contracts.Dtos.Partner;
using Microsoft.AspNetCore.Mvc;
using Volo.Abp.Application.Dtos;
using Volo.Abp.Application.Services;
namespace FoodLabeling.Application.Contracts.IServices;
/// <summary>
/// 合作伙伴管理接口(fl_partner)
/// </summary>
public interface IPartnerAppService : IApplicationService
{
/// <summary>
/// 合作伙伴分页列表(与导出使用相同筛选条件)
/// </summary>
/// <param name="input">分页与筛选;SkipCount 为页码(从 1 起)</param>
/// <returns>分页数据</returns>
/// <response code="200">成功</response>
/// <response code="400">参数错误</response>
/// <response code="500">服务器错误</response>
Task<PagedResultWithPageDto<PartnerGetListOutputDto>> GetListAsync(PartnerGetListInputVo input);
/// <summary>
/// 合作伙伴详情
/// </summary>
/// <param name="id">主键 Id</param>
/// <returns>详情</returns>
/// <response code="200">成功</response>
/// <response code="400">Id 无效</response>
/// <response code="500">服务器错误</response>
Task<PartnerGetOutputDto> GetAsync(string id);
/// <summary>
/// 新增合作伙伴
/// </summary>
/// <param name="input">名称、邮箱、电话、启用状态</param>
/// <returns>新建后的详情</returns>
/// <remarks>
/// 示例请求:
/// ```json
/// {
/// "partnerName": "Global Foods Inc.",
/// "contactEmail": "admin@globalfoods.com",
/// "phoneNumber": "+1 (555) 100-2000",
/// "state": true
/// }
/// ```
/// </remarks>
/// <response code="200">成功</response>
/// <response code="400">校验失败</response>
/// <response code="500">服务器错误</response>
Task<PartnerGetOutputDto> CreateAsync(PartnerCreateInputVo input);
/// <summary>
/// 编辑合作伙伴
/// </summary>
/// <param name="id">主键 Id</param>
/// <param name="input">名称、邮箱、电话、启用状态</param>
/// <returns>更新后的详情</returns>
/// <response code="200">成功</response>
/// <response code="400">校验失败或记录不存在</response>
/// <response code="500">服务器错误</response>
Task<PartnerGetOutputDto> UpdateAsync(string id, PartnerUpdateInputVo input);
/// <summary>
/// 删除合作伙伴(逻辑删除)
/// </summary>
/// <param name="id">主键 Id</param>
/// <response code="200">成功</response>
/// <response code="400">Id 无效或记录不存在</response>
/// <response code="500">服务器错误</response>
Task DeleteAsync(string id);
/// <summary>
/// 按当前列表筛选条件批量导出合作伙伴为 PDF(不分页,上限 5000 条)
/// </summary>
/// <param name="input">与列表相同的 Keyword、State;分页字段忽略</param>
/// <returns>PDF 文件流</returns>
/// <remarks>
/// 筛选条件需与 <see cref="GetListAsync"/> 一致,便于统计与导出数据对齐。
/// </remarks>
/// <response code="200">成功返回 application/pdf</response>
/// <response code="400">参数错误</response>
/// <response code="500">服务器错误</response>
Task<IActionResult> ExportPdfAsync(PartnerGetListInputVo input);
}