2025-07-13 16:36:20 +08:00
|
|
|
package certification
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"context"
|
|
|
|
|
|
|
|
|
|
"tyapi-server/internal/application/certification/dto/commands"
|
|
|
|
|
"tyapi-server/internal/application/certification/dto/queries"
|
|
|
|
|
"tyapi-server/internal/application/certification/dto/responses"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
// CertificationApplicationService 认证应用服务接口
|
2025-07-21 15:13:26 +08:00
|
|
|
// 负责用例协调,提供精简的应用层接口
|
2025-07-13 16:36:20 +08:00
|
|
|
type CertificationApplicationService interface {
|
2025-07-21 15:13:26 +08:00
|
|
|
// ================ 用户操作用例 ================
|
|
|
|
|
// 提交企业信息
|
2025-07-20 20:53:26 +08:00
|
|
|
SubmitEnterpriseInfo(ctx context.Context, cmd *commands.SubmitEnterpriseInfoCommand) (*responses.CertificationResponse, error)
|
2025-07-28 01:46:39 +08:00
|
|
|
// 确认状态
|
|
|
|
|
ConfirmAuth(ctx context.Context, cmd *queries.ConfirmAuthCommand) (*responses.ConfirmAuthResponse, error)
|
|
|
|
|
// 确认签署
|
|
|
|
|
ConfirmSign(ctx context.Context, cmd *queries.ConfirmSignCommand) (*responses.ConfirmSignResponse, error)
|
2025-07-21 15:13:26 +08:00
|
|
|
// 申请合同签署
|
|
|
|
|
ApplyContract(ctx context.Context, cmd *commands.ApplyContractCommand) (*responses.ContractSignUrlResponse, error)
|
2025-07-13 16:36:20 +08:00
|
|
|
|
2025-07-21 15:13:26 +08:00
|
|
|
// ================ 查询用例 ================
|
|
|
|
|
|
|
|
|
|
// 获取认证详情
|
|
|
|
|
GetCertification(ctx context.Context, query *queries.GetCertificationQuery) (*responses.CertificationResponse, error)
|
|
|
|
|
|
|
|
|
|
// 获取认证列表(管理员)
|
|
|
|
|
ListCertifications(ctx context.Context, query *queries.ListCertificationsQuery) (*responses.CertificationListResponse, error)
|
|
|
|
|
|
|
|
|
|
// ================ e签宝回调处理 ================
|
2025-07-13 16:36:20 +08:00
|
|
|
|
2025-07-20 20:53:26 +08:00
|
|
|
// 处理e签宝回调
|
2025-07-28 01:46:39 +08:00
|
|
|
HandleEsignCallback(ctx context.Context, cmd *commands.EsignCallbackCommand) error
|
2025-07-13 16:36:20 +08:00
|
|
|
}
|