diff --git a/model/dto/ad_position_dto.go b/model/dto/ad_position_dto.go index d918e4f..403ca36 100644 --- a/model/dto/ad_position_dto.go +++ b/model/dto/ad_position_dto.go @@ -128,7 +128,7 @@ type UpdateAdPositionStatusReq struct { // GetAdPositionStatisticsReq 获取广告位统计数据请求 type GetAdPositionStatisticsReq struct { - g.Meta `path:"getStatisticsAdPosition" method:"get" tags:"广告位管理" summary:"获取广告位统计数据" dc:"获取广告位的统计数据"` + g.Meta `path:"/getStatistics" method:"get" tags:"广告位管理" summary:"获取广告位统计数据" dc:"获取广告位的统计数据"` Id string `json:"id" v:"required"` // 广告位ID StatType string `json:"statType" v:"required"` // 统计类型:天、周、月 @@ -143,7 +143,7 @@ type GetAdPositionStatisticsRes struct { // GetAvailableAdPositionsReq 获取可用广告位请求 type GetAvailableAdPositionsReq struct { - g.Meta `path:"getAvailableAdPositions" method:"get" tags:"广告位管理" summary:"获取可用广告位列表" dc:"获取所有启用的广告位列表"` + g.Meta `path:"/getAvailableAdPositions" method:"get" tags:"广告位管理" summary:"获取可用广告位列表" dc:"获取所有启用的广告位列表"` } type GetAvailableAdPositionsRes struct { @@ -152,7 +152,7 @@ type GetAvailableAdPositionsRes struct { // MatchAdReq 匹配广告请求 type MatchAdReq struct { - g.Meta `path:"matchAdAdPosition" method:"post" tags:"广告位管理" summary:"匹配广告" dc:"根据广告位编码和用户信息匹配适合的广告"` + g.Meta `path:"/matchAd" method:"post" tags:"广告位管理" summary:"匹配广告" dc:"根据广告位编码和用户信息匹配适合的广告"` PositionCode string `json:"positionCode" v:"required"` // 广告位编码 UserInfo map[string]interface{} `json:"userInfo"` // 用户信息 diff --git a/model/dto/ad_source_dto.go b/model/dto/ad_source_dto.go index 31e7f52..4e14f2a 100644 --- a/model/dto/ad_source_dto.go +++ b/model/dto/ad_source_dto.go @@ -9,7 +9,7 @@ import ( // CreateAdSourceReq 创建广告源请求 type CreateAdSourceReq struct { - g.Meta `path:"createAdSource" method:"post" tags:"广告源管理" summary:"创建广告源" dc:"创建新的广告源配置"` + g.Meta `path:"/create" method:"post" tags:"广告源管理" summary:"创建广告源" dc:"创建新的广告源配置"` // 基本信息 Name string `json:"name" v:"required"` // 广告源名称 @@ -69,7 +69,7 @@ type CreateAdSourceRes struct { // GetAdSourceReq 获取广告源详情请求 type GetAdSourceReq struct { - g.Meta `path:"getByIDAdSource" method:"get" tags:"广告源管理" summary:"获取广告源详情" dc:"根据ID获取单个广告源详情"` + g.Meta `path:"/getByID" method:"get" tags:"广告源管理" summary:"获取广告源详情" dc:"根据ID获取单个广告源详情"` Id string `json:"id" v:"required"` // 广告源ID } @@ -79,7 +79,7 @@ type GetAdSourceRes struct { // ListAdSourceReq 获取广告源列表请求 type ListAdSourceReq struct { - g.Meta `path:"getListAdSource" method:"get" tags:"广告源管理" summary:"获取广告源列表" dc:"分页查询广告源列表,支持多条件筛选"` + g.Meta `path:"/getList" method:"get" tags:"广告源管理" summary:"获取广告源列表" dc:"分页查询广告源列表,支持多条件筛选"` http.Page Name string `json:"name"` // 广告源名称模糊查询 @@ -97,7 +97,7 @@ type ListAdSourceRes struct { // UpdateAdSourceReq 更新广告源请求 type UpdateAdSourceReq struct { - g.Meta `path:"updateAdSource" method:"put" tags:"广告源管理" summary:"更新广告源" dc:"更新广告源信息"` + g.Meta `path:"/update" method:"put" tags:"广告源管理" summary:"更新广告源" dc:"更新广告源信息"` Id string `json:"id" v:"required"` // 广告源ID @@ -152,7 +152,7 @@ type UpdateAdSourceReq struct { // UpdateAdSourceStatusReq 更新广告源状态请求 type UpdateAdSourceStatusReq struct { - g.Meta `path:"/adsource" method:"patch" tags:"广告源管理" summary:"更新广告源状态" dc:"更新广告源状态"` + // g.Meta `path:"/adsource" method:"patch" tags:"广告源管理" summary:"更新广告源状态" dc:"更新广告源状态"` // 暂时注释,缺少对应的controller方法 Id string `json:"id" v:"required"` // 广告源ID Status string `json:"status" v:"required"` // 广告源状态:active、inactive、maintenance @@ -160,14 +160,14 @@ type UpdateAdSourceStatusReq struct { // DeleteAdSourceReq 删除广告源请求 type DeleteAdSourceReq struct { - g.Meta `path:"deleteAdSource" method:"delete" tags:"广告源管理" summary:"删除广告源" dc:"删除指定的广告源"` + g.Meta `path:"/delete" method:"delete" tags:"广告源管理" summary:"删除广告源" dc:"删除指定的广告源"` Id string `json:"id" v:"required"` // 广告源ID } // TestAdSourceReq 测试广告源连接请求 type TestAdSourceReq struct { - g.Meta `path:"/adsource-test" method:"post" tags:"广告源管理" summary:"测试广告源连接" dc:"测试广告源的连接性和可用性"` + // g.Meta `path:"/adsource-test" method:"post" tags:"广告源管理" summary:"测试广告源连接" dc:"测试广告源的连接性和可用性"` // 暂时注释,缺少对应的controller方法 Id string `json:"id" v:"required"` // 广告源ID } @@ -195,7 +195,7 @@ type AdSourceTestMetrics struct { // GetAdSourceStatisticsReq 获取广告源统计数据请求 type GetAdSourceStatisticsReq struct { - g.Meta `path:"/adsource-statistics" method:"get" tags:"广告源管理" summary:"获取广告源统计数据" dc:"获取广告源的详细统计数据"` + // g.Meta `path:"/adsource-statistics" method:"get" tags:"广告源管理" summary:"获取广告源统计数据" dc:"获取广告源的详细统计数据"` // 暂时注释,缺少对应的controller方法 Id string `json:"id" v:"required"` // 广告源ID StartDate int64 `json:"startDate" v:"required"` // 开始日期 diff --git a/model/dto/ad_statistics_dto.go b/model/dto/ad_statistics_dto.go index 2b50863..329eac1 100644 --- a/model/dto/ad_statistics_dto.go +++ b/model/dto/ad_statistics_dto.go @@ -9,7 +9,7 @@ import ( // GetAdStatisticsReq 获取广告统计数据请求 type GetAdStatisticsReq struct { - g.Meta `path:"getStatisticsAdStatistics" method:"get" tags:"广告统计" summary:"获取广告统计数据" dc:"获取广告的统计数据"` + g.Meta `path:"/getStatistics" method:"get" tags:"广告统计" summary:"获取广告统计数据" dc:"获取广告的统计数据"` // 分页参数 http.Page @@ -42,7 +42,7 @@ type GetAdStatisticsRes struct { // GetDashboardReq 获取仪表盘数据请求 type GetDashboardReq struct { - g.Meta `path:"getDashboardAdStatistics" method:"get" tags:"广告仪表盘" summary:"获取仪表盘数据" dc:"获取广告系统的仪表盘统计数据"` + g.Meta `path:"/getDashboard" method:"get" tags:"广告仪表盘" summary:"获取仪表盘数据" dc:"获取广告系统的仪表盘统计数据"` // 时间范围 StartDate int64 `json:"startDate" v:"required"` // 开始日期 @@ -103,7 +103,7 @@ type RankData struct { // GenerateDailyStatisticsReq 生成每日统计数据请求 type GenerateDailyStatisticsReq struct { - g.Meta `path:"generateDailyStatisticsAdStatistics" method:"post" tags:"广告统计" summary:"生成每日统计数据" dc:"手动生成指定日期的广告统计数据"` + g.Meta `path:"/generateDailyStatistics" method:"post" tags:"广告统计" summary:"生成每日统计数据" dc:"手动生成指定日期的广告统计数据"` Date int64 `json:"date" v:"required"` // 日期时间戳 } diff --git a/model/dto/advertisement_dto.go b/model/dto/advertisement_dto.go index 318bcf4..3e888ce 100644 --- a/model/dto/advertisement_dto.go +++ b/model/dto/advertisement_dto.go @@ -9,7 +9,7 @@ import ( // AddAdvertisementReq 添加广告请求 type AddAdvertisementReq struct { - g.Meta `path:"addAdvertisement" method:"post" tags:"广告管理" summary:"添加广告" dc:"添加新的广告"` + g.Meta `path:"/add" method:"post" tags:"广告管理" summary:"添加广告" dc:"添加新的广告"` // 广告基本信息 Title string `json:"title" v:"required"` // 广告标题 @@ -40,7 +40,7 @@ type AddAdvertisementRes struct { // UpdateAdvertisementReq 更新广告请求 type UpdateAdvertisementReq struct { - g.Meta `path:"updateAdvertisement" method:"put" tags:"广告管理" summary:"更新广告" dc:"更新广告信息"` + g.Meta `path:"/update" method:"put" tags:"广告管理" summary:"更新广告" dc:"更新广告信息"` Id string `json:"id" v:"required"` // ID @@ -74,7 +74,7 @@ type UpdateAdvertisementReq struct { // GetAdvertisementReq 获取广告详情请求 type GetAdvertisementReq struct { - g.Meta `path:"getOneAdvertisement" method:"get" tags:"广告管理" summary:"获取广告详情" dc:"根据ID获取单个广告详情"` + g.Meta `path:"/getOne" method:"get" tags:"广告管理" summary:"获取广告详情" dc:"根据ID获取单个广告详情"` Id string `json:"id" v:"required"` // ID } @@ -84,7 +84,7 @@ type GetAdvertisementRes struct { // ListAdvertisementReq 获取广告列表请求 type ListAdvertisementReq struct { - g.Meta `path:"listAdvertisement" method:"get" tags:"广告管理" summary:"获取广告列表" dc:"分页查询广告列表,支持多条件筛选"` + g.Meta `path:"/list" method:"get" tags:"广告管理" summary:"获取广告列表" dc:"分页查询广告列表,支持多条件筛选"` http.Page AdvertiserId string `json:"advertiserId"` // 广告主ID @@ -103,7 +103,7 @@ type ListAdvertisementRes struct { // AuditAdvertisementReq 审核广告请求 type AuditAdvertisementReq struct { - g.Meta `path:"auditAdvertisement" method:"post" tags:"广告管理" summary:"审核广告" dc:"审核广告,通过或拒绝"` + g.Meta `path:"/audit" method:"post" tags:"广告管理" summary:"审核广告" dc:"审核广告,通过或拒绝"` Id string `json:"id" v:"required"` // 广告ID AuditStatus string `json:"auditStatus" v:"required"` // 审核状态:通过、拒绝 @@ -112,7 +112,7 @@ type AuditAdvertisementReq struct { // UpdateAdStatusReq 更新广告状态请求 type UpdateAdStatusReq struct { - g.Meta `path:"updateStatusAdvertisement" method:"patch" tags:"广告管理" summary:"更新广告状态" dc:"更新广告状态"` + g.Meta `path:"/updateStatus" method:"patch" tags:"广告管理" summary:"更新广告状态" dc:"更新广告状态"` Id string `json:"id" v:"required"` // 广告ID Status string `json:"status" v:"required"` // 广告状态:启用、禁用 @@ -120,7 +120,7 @@ type UpdateAdStatusReq struct { // GetAdStatisticsReq 获取广告统计数据请求 type GetAdStatisticsForAdvertisementReq struct { - g.Meta `path:"getStatisticsAdvertisement" method:"get" tags:"广告管理" summary:"获取广告统计数据" dc:"获取广告的统计数据"` + g.Meta `path:"/getStatistics" method:"get" tags:"广告管理" summary:"获取广告统计数据" dc:"获取广告的统计数据"` Id string `json:"id" v:"required"` // 广告ID StatType string `json:"statType" v:"required"` // 统计类型:天、周、月 diff --git a/model/dto/advertiser_dto.go b/model/dto/advertiser_dto.go index 7898a58..9574d9a 100644 --- a/model/dto/advertiser_dto.go +++ b/model/dto/advertiser_dto.go @@ -9,7 +9,7 @@ import ( // AddAdvertiserReq 添加广告主请求 type AddAdvertiserReq struct { - g.Meta `path:"addAdvertiser" method:"post" tags:"广告主管理" summary:"添加广告主" dc:"添加新的广告主"` + g.Meta `path:"/add" method:"post" tags:"广告主管理" summary:"添加广告主" dc:"添加新的广告主"` // 基本信息 Name string `json:"name" v:"required"` // 广告主名称 @@ -49,7 +49,7 @@ type AddAdvertiserRes struct { // UpdateAdvertiserReq 更新广告主请求 type UpdateAdvertiserReq struct { - g.Meta `path:"updateAdvertiser" method:"put" tags:"广告主管理" summary:"更新广告主" dc:"更新广告主信息"` + g.Meta `path:"/update" method:"put" tags:"广告主管理" summary:"更新广告主" dc:"更新广告主信息"` Id string `json:"id" v:"required"` // ID @@ -92,7 +92,7 @@ type UpdateAdvertiserReq struct { // GetAdvertiserReq 获取广告主详情请求 type GetAdvertiserReq struct { - g.Meta `path:"getOneAdvertiser" method:"get" tags:"广告主管理" summary:"获取广告主详情" dc:"根据ID获取单个广告主详情"` + g.Meta `path:"/getOne" method:"get" tags:"广告主管理" summary:"获取广告主详情" dc:"根据ID获取单个广告主详情"` Id string `json:"id" v:"required"` // ID } @@ -102,7 +102,7 @@ type GetAdvertiserRes struct { // ListAdvertiserReq 获取广告主列表请求 type ListAdvertiserReq struct { - g.Meta `path:"listAdvertiser" method:"get" tags:"广告主管理" summary:"获取广告主列表" dc:"分页查询广告主列表,支持多条件筛选"` + g.Meta `path:"/list" method:"get" tags:"广告主管理" summary:"获取广告主列表" dc:"分页查询广告主列表,支持多条件筛选"` http.Page Name string `json:"name"` // 广告主名称模糊查询 @@ -121,7 +121,7 @@ type ListAdvertiserRes struct { // AuditAdvertiserReq 审核广告主请求 type AuditAdvertiserReq struct { - g.Meta `path:"auditAdvertiser" method:"post" tags:"广告主管理" summary:"审核广告主" dc:"审核广告主,通过或拒绝"` + g.Meta `path:"/audit" method:"post" tags:"广告主管理" summary:"审核广告主" dc:"审核广告主,通过或拒绝"` Id string `json:"id" v:"required"` // 广告主ID AuditStatus string `json:"auditStatus" v:"required"` // 审核状态:通过、拒绝 @@ -130,7 +130,7 @@ type AuditAdvertiserReq struct { // UpdateAdvertiserStatusReq 更新广告主状态请求 type UpdateAdvertiserStatusReq struct { - g.Meta `path:"updateStatusAdvertiser" method:"patch" tags:"广告主管理" summary:"更新广告主状态" dc:"更新广告主状态"` + g.Meta `path:"/updateStatus" method:"patch" tags:"广告主管理" summary:"更新广告主状态" dc:"更新广告主状态"` Id string `json:"id" v:"required"` // 广告主ID Status string `json:"status" v:"required"` // 广告主状态:启用、禁用、冻结 @@ -138,7 +138,7 @@ type UpdateAdvertiserStatusReq struct { // RechargeAdvertiserReq 广告主充值请求 type RechargeAdvertiserReq struct { - g.Meta `path:"rechargeAdvertiser" method:"post" tags:"广告主管理" summary:"广告主充值" dc:"为广告主账户充值"` + g.Meta `path:"/recharge" method:"post" tags:"广告主管理" summary:"广告主充值" dc:"为广告主账户充值"` Id string `json:"id" v:"required"` // 广告主ID Amount int64 `json:"amount" v:"required"` // 充值金额(分) @@ -147,7 +147,7 @@ type RechargeAdvertiserReq struct { // UpdateCreditLimitReq 更新授信额度请求 type UpdateCreditLimitReq struct { - g.Meta `path:"updateCreditLimitAdvertiser" method:"post" tags:"广告主管理" summary:"更新授信额度" dc:"更新广告主的授信额度"` + g.Meta `path:"/updateCreditLimit" method:"post" tags:"广告主管理" summary:"更新授信额度" dc:"更新广告主的授信额度"` Id string `json:"id" v:"required"` // 广告主ID CreditLimit int64 `json:"creditLimit" v:"required"` // 授信额度(分) @@ -156,7 +156,7 @@ type UpdateCreditLimitReq struct { // GetAdvertiserBalanceReq 获取广告主余额请求 type GetAdvertiserBalanceReq struct { - g.Meta `path:"getBalanceAdvertiser" method:"get" tags:"广告主管理" summary:"获取广告主余额" dc:"根据ID获取广告主账户余额和授信额度"` + g.Meta `path:"/getBalance" method:"get" tags:"广告主管理" summary:"获取广告主余额" dc:"根据ID获取广告主账户余额和授信额度"` Id string `json:"id" v:"required"` // 广告主ID } diff --git a/model/dto/application_dto.go b/model/dto/application_dto.go index 65a7f18..086c814 100644 --- a/model/dto/application_dto.go +++ b/model/dto/application_dto.go @@ -6,7 +6,7 @@ import ( // CreateApplicationReq 创建应用请求 type CreateApplicationReq struct { - g.Meta `path:"createApplication" method:"post" summary:"创建应用"` + g.Meta `path:"/createApplication" method:"post" summary:"创建应用"` TenantID int64 `json:"tenantId" v:"required#租户ID不能为空"` Name string `json:"name" v:"required#应用名称不能为空"` @@ -30,7 +30,7 @@ type CreateApplicationRes struct { // UpdateApplicationReq 更新应用请求 type UpdateApplicationReq struct { - g.Meta `path:"updateApplication" method:"put" summary:"更新应用"` + g.Meta `path:"/updateApplication" method:"put" summary:"更新应用"` ID int64 `json:"id" v:"required#应用ID不能为空"` Name string `json:"name"` @@ -51,7 +51,7 @@ type UpdateApplicationRes struct { // GetApplicationReq 获取应用请求 type GetApplicationReq struct { - g.Meta `path:"getApplication" method:"get" summary:"获取应用信息"` + g.Meta `path:"/getApplication" method:"get" summary:"获取应用信息"` ID int64 `json:"id" v:"required#应用ID不能为空"` } @@ -78,7 +78,7 @@ type GetApplicationRes struct { // ListApplicationsReq 获取应用列表请求 type ListApplicationsReq struct { - g.Meta `path:"listApplications" method:"get" summary:"获取应用列表"` + g.Meta `path:"/listApplications" method:"get" summary:"获取应用列表"` TenantID int64 `json:"tenantId" v:"required#租户ID不能为空"` Platform string `json:"platform"` @@ -114,7 +114,7 @@ type ApplicationItem struct { // ResetAPIKeysReq 重置API密钥请求 type ResetAPIKeysReq struct { - g.Meta `path:"/applications-reset-keys" method:"post" summary:"重置API密钥"` + g.Meta `path:"/resetAPIKeys" method:"post" summary:"重置API密钥"` ID int64 `json:"id" v:"required#应用ID不能为空"` } @@ -127,7 +127,7 @@ type ResetAPIKeysRes struct { // ValidateApplicationReq 验证应用请求 type ValidateApplicationReq struct { - g.Meta `path:"/applications-validate" method:"post" summary:"验证应用权限"` + g.Meta `path:"/validateApplication" method:"post" summary:"验证应用权限"` AppKey string `json:"appKey" v:"required#应用密钥不能为空"` AppSecret string `json:"appSecret" v:"required#应用密钥不能为空"` @@ -146,7 +146,7 @@ type ValidateApplicationRes struct { // DeleteApplicationReq 删除应用请求 type DeleteApplicationReq struct { - g.Meta `path:"/applications" method:"delete" summary:"删除应用"` + g.Meta `path:"/deleteApplication" method:"delete" summary:"删除应用"` ID int64 `json:"id" v:"required#应用ID不能为空"` } diff --git a/model/dto/cid_dto.go b/model/dto/cid_dto.go index 721b82b..e8e4f15 100644 --- a/model/dto/cid_dto.go +++ b/model/dto/cid_dto.go @@ -6,7 +6,7 @@ import ( // GenerateCIDReq 生成CID请求 type GenerateCIDReq struct { - g.Meta `path:"/cid-generate" method:"post" tags:"CID服务" summary:"生成CID广告" dc:"为当前用户生成CID广告"` + g.Meta `path:"/generateCID" method:"post" tags:"CID服务" summary:"生成CID广告" dc:"为当前用户生成CID广告"` UserId int64 `json:"user_id"` // 用户ID(可选,如果不提供则从token获取) RequestType string `json:"request_type"` // 请求类型 Parameters map[string]interface{} `json:"parameters"` // 请求参数 @@ -38,7 +38,7 @@ type GenerateCIDRes struct { // GetCIDStatisticsReq 获取CID统计请求 type GetCIDStatisticsReq struct { - g.Meta `path:"/cid-statistics" method:"get" tags:"CID服务" summary:"获取CID统计" dc:"获取CID服务的统计信息"` + g.Meta `path:"/getStatistics" method:"get" tags:"CID服务" summary:"获取CID统计" dc:"获取CID服务的统计信息"` UserId int64 `json:"user_id"` // 用户ID(可选) TenantId int64 `json:"tenant_id"` // 租户ID(可选) DateFrom int64 `json:"date_from"` // 开始日期 @@ -67,7 +67,7 @@ type CIDRequestHistory struct { // GetCIDHistoryReq 获取CID历史请求 type GetCIDHistoryReq struct { - g.Meta `path:"/cid-history" method:"get" tags:"CID服务" summary:"获取CID历史记录" dc:"分页获取用户的CID请求历史"` + g.Meta `path:"/getCidHistory" method:"get" tags:"CID服务" summary:"获取CID历史记录" dc:"分页获取用户的CID请求历史"` Page int `json:"page" v:"required|min:1"` // 页码 Size int `json:"size" v:"required|min:1|max:100"` // 每页数量 } diff --git a/model/dto/rate_limit_dto.go b/model/dto/rate_limit_dto.go index e8dc770..82540e5 100644 --- a/model/dto/rate_limit_dto.go +++ b/model/dto/rate_limit_dto.go @@ -6,7 +6,7 @@ import ( // SetTenantRateLimitReq 设置租户限流配置请求 type SetTenantRateLimitReq struct { - g.Meta `path:"/ratelimit-tenant-set" method:"post" tags:"租户限流" summary:"设置租户限流配置" dc:"设置指定租户的请求次数限制配置(实际使用全局配置)"` + g.Meta `path:"/setTenantRateLimit" method:"post" tags:"租户限流" summary:"设置租户限流配置" dc:"设置指定租户的请求次数限制配置(实际使用全局配置)"` TenantID int64 `json:"tenant_id" v:"required"` // 租户ID(仅用于记录,实际使用全局配置) RequestsPerSecond float64 `json:"requests_per_second" v:"required"` // 每秒请求数 @@ -21,7 +21,7 @@ type SetTenantRateLimitRes struct { // GetTenantRateLimitUsageReq 获取租户限流使用情况请求 type GetTenantRateLimitUsageReq struct { - g.Meta `path:"/ratelimit-tenant-usage" method:"get" tags:"租户限流" summary:"获取租户限流使用情况" dc:"获取指定租户的请求次数使用情况"` + g.Meta `path:"/getTenantRateLimitUsage" method:"get" tags:"租户限流" summary:"获取租户限流使用情况" dc:"获取指定租户的请求次数使用情况"` TenantID int64 `json:"tenant_id" v:"required"` // 租户ID } diff --git a/model/dto/report_dto.go b/model/dto/report_dto.go index 8451ac9..1ea3045 100644 --- a/model/dto/report_dto.go +++ b/model/dto/report_dto.go @@ -9,7 +9,7 @@ import ( // CreateReportReq 创建报表请求 type CreateReportReq struct { - g.Meta `path:"/report/create" method:"post" tags:"广告报表" summary:"创建报表" dc:"创建新的广告报表"` + g.Meta `path:"/create" method:"post" tags:"广告报表" summary:"创建报表" dc:"创建新的广告报表"` // 报表信息 ReportName string `json:"reportName" v:"required"` // 报表名称 @@ -31,7 +31,7 @@ type CreateReportRes struct { // GetReportReq 获取报表详情请求 type GetReportReq struct { - g.Meta `path:"/report/one" method:"get" tags:"广告报表" summary:"获取报表详情" dc:"根据ID获取单个报表详情"` + g.Meta `path:"/getOne" method:"get" tags:"广告报表" summary:"获取报表详情" dc:"根据ID获取单个报表详情"` Id string `json:"id" v:"required"` // ID } @@ -41,7 +41,7 @@ type GetReportRes struct { // ListReportReq 获取报表列表请求 type ListReportReq struct { - g.Meta `path:"/report/list" method:"get" tags:"广告报表" summary:"获取报表列表" dc:"分页查询报表列表,支持多条件筛选"` + g.Meta `path:"/list" method:"get" tags:"广告报表" summary:"获取报表列表" dc:"分页查询报表列表,支持多条件筛选"` http.Page ReportName string `json:"reportName"` // 报表名称模糊查询 @@ -58,7 +58,7 @@ type ListReportRes struct { // UpdateReportReq 更新报表请求 type UpdateReportReq struct { - g.Meta `path:"/report/update" method:"post" tags:"广告报表" summary:"更新报表" dc:"更新报表信息"` + g.Meta `path:"/update" method:"post" tags:"广告报表" summary:"更新报表" dc:"更新报表信息"` Id string `json:"id" v:"required"` // ID @@ -78,14 +78,14 @@ type UpdateReportReq struct { // DeleteReportReq 删除报表请求 type DeleteReportReq struct { - g.Meta `path:"/report/delete" method:"post" tags:"广告报表" summary:"删除报表" dc:"删除指定的报表"` + g.Meta `path:"/delete" method:"post" tags:"广告报表" summary:"删除报表" dc:"删除指定的报表"` Id string `json:"id" v:"required"` // 报表ID } // DownloadReportReq 下载报表请求 type DownloadReportReq struct { - g.Meta `path:"/report/download" method:"get" tags:"广告报表" summary:"下载报表" dc:"下载指定的报表文件"` + g.Meta `path:"/download" method:"get" tags:"广告报表" summary:"下载报表" dc:"下载指定的报表文件"` Id string `json:"id" v:"required"` // 报表ID } @@ -98,7 +98,7 @@ type DownloadReportRes struct { // GenerateReportReq 生成报表请求 type GenerateReportReq struct { - g.Meta `path:"/report/generate" method:"post" tags:"广告报表" summary:"生成报表" dc:"手动生成报表"` + g.Meta `path:"/generate" method:"post" tags:"广告报表" summary:"生成报表" dc:"手动生成报表"` Id string `json:"id" v:"required"` // 报表ID } diff --git a/model/dto/stat_report_dto.go b/model/dto/stat_report_dto.go index 367d6d2..96bbd68 100644 --- a/model/dto/stat_report_dto.go +++ b/model/dto/stat_report_dto.go @@ -4,7 +4,7 @@ import "github.com/gogf/gf/v2/frame/g" // 报表生成请求 type ReportGenerateReq struct { - g.Meta `path:"/report/generate" method:"post"` + g.Meta `path:"/generateReport" method:"post"` TenantID int64 `json:"tenant_id" v:"required"` AppID int64 `json:"app_id"` ReportType string `json:"report_type" v:"required|in:daily,monthly,quarterly,yearly"` @@ -21,7 +21,7 @@ type ReportGenerateResp struct { // 报表列表请求 type ReportListReq struct { - g.Meta `path:"/report/list" method:"get"` + g.Meta `path:"/getReportList" method:"get"` TenantID int64 `json:"tenant_id"` AppID int64 `json:"app_id"` ReportType string `json:"report_type"` @@ -41,7 +41,7 @@ type ReportListResp struct { // 报表详情请求 type ReportDetailReq struct { - g.Meta `path:"/report/detail" method:"get"` + g.Meta `path:"/getReportDetail" method:"get"` ReportID int64 `json:"report_id" v:"required"` } @@ -68,7 +68,7 @@ type ReportDTO struct { // 统计查询请求 type StatQueryReq struct { - g.Meta `path:"/stat/query" method:"get"` + g.Meta `path:"/queryStats" method:"get"` TenantID int64 `json:"tenant_id" v:"required"` AppID int64 `json:"app_id"` AdType string `json:"ad_type"` @@ -115,7 +115,7 @@ type GrowthRate struct { // 实时统计请求 type RealTimeStatReq struct { - g.Meta `path:"/stat/realtime" method:"get"` + g.Meta `path:"/realTimeStats" method:"get"` TenantID int64 `json:"tenant_id" v:"required"` AppID int64 `json:"app_id"` Hours int `json:"hours" d:"24"` // 过去多少小时的统计 diff --git a/model/dto/strategy_dto.go b/model/dto/strategy_dto.go index 99e989e..619a2fc 100644 --- a/model/dto/strategy_dto.go +++ b/model/dto/strategy_dto.go @@ -6,7 +6,7 @@ import ( // CreateStrategyReq 创建策略请求 type CreateStrategyReq struct { - g.Meta `path:"/strategy" method:"post" tags:"策略管理" summary:"创建匹配策略" dc:"创建新的广告匹配策略"` + g.Meta `path:"/create" method:"post" tags:"策略管理" summary:"创建匹配策略" dc:"创建新的广告匹配策略"` Name string `json:"name" v:"required|length:3,50"` // 策略名称 Description string `json:"description" v:"max:500"` // 描述 TenantLevel string `json:"tenant_level" v:"required|in:basic,standard,premium"` // 租户级别 @@ -21,7 +21,7 @@ type CreateStrategyReq struct { // UpdateStrategyReq 更新策略请求 type UpdateStrategyReq struct { - g.Meta `path:"/strategy" method:"put" tags:"策略管理" summary:"更新匹配策略" dc:"更新现有的广告匹配策略"` + g.Meta `path:"/update" method:"put" tags:"策略管理" summary:"更新匹配策略" dc:"更新现有的广告匹配策略"` Id int64 `json:"id" v:"required"` // 策略ID Name string `json:"name" v:"required|length:3,50"` // 策略名称 Description string `json:"description" v:"max:500"` // 描述 @@ -37,19 +37,19 @@ type UpdateStrategyReq struct { // DeleteStrategyReq 删除策略请求 type DeleteStrategyReq struct { - g.Meta `path:"/strategy" method:"delete" tags:"策略管理" summary:"删除匹配策略" dc:"删除指定的广告匹配策略"` + g.Meta `path:"/delete" method:"delete" tags:"策略管理" summary:"删除匹配策略" dc:"删除指定的广告匹配策略"` Id int64 `json:"id" v:"required"` // 策略ID } // GetStrategyReq 获取策略请求 type GetStrategyReq struct { - g.Meta `path:"/strategy" method:"get" tags:"策略管理" summary:"获取策略详情" dc:"获取指定策略的详细信息"` + g.Meta `path:"/getByID" method:"get" tags:"策略管理" summary:"获取策略详情" dc:"获取指定策略的详细信息"` Id int64 `json:"id" v:"required"` // 策略ID } // GetStrategyListReq 获取策略列表请求 type GetStrategyListReq struct { - g.Meta `path:"/strategies" method:"get" tags:"策略管理" summary:"获取策略列表" dc:"分页获取策略列表"` + g.Meta `path:"/getList" method:"get" tags:"策略管理" summary:"获取策略列表" dc:"分页获取策略列表"` Page int `json:"page" v:"required|min:1"` // 页码 Size int `json:"size" v:"required|min:1|max:100"` // 每页数量 TenantLevel string `json:"tenant_level"` // 租户级别筛选