初始化项目
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
|
||||
type adPosition struct{}
|
||||
|
||||
var AdPosition = &adPosition{}
|
||||
var AdPosition = new(adPosition)
|
||||
|
||||
// Add 添加广告位
|
||||
func (c *adPosition) Add(ctx context.Context, req *dto.AddAdPositionReq) (res *dto.AddAdPositionRes, err error) {
|
||||
|
||||
@@ -10,9 +10,7 @@ import (
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
)
|
||||
|
||||
var (
|
||||
AdSource = adSource{}
|
||||
)
|
||||
var AdSource = new(adSource)
|
||||
|
||||
type adSource struct{}
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ import (
|
||||
|
||||
type adStatistics struct{}
|
||||
|
||||
var AdStatistics = &adStatistics{}
|
||||
var AdStatistics = new(adStatistics)
|
||||
|
||||
// GetStatistics 获取统计数据
|
||||
func (c *adStatistics) GetStatistics(ctx context.Context, req *dto.GetAdStatisticsReq) (res *dto.GetAdStatisticsRes, err error) {
|
||||
|
||||
@@ -10,7 +10,7 @@ import (
|
||||
|
||||
type advertisement struct{}
|
||||
|
||||
var Advertisement = &advertisement{}
|
||||
var Advertisement = new(advertisement)
|
||||
|
||||
// Add 添加广告
|
||||
func (c *advertisement) Add(ctx context.Context, req *dto.AddAdvertisementReq) (res *dto.AddAdvertisementRes, err error) {
|
||||
|
||||
@@ -10,7 +10,7 @@ import (
|
||||
|
||||
type advertiser struct{}
|
||||
|
||||
var Advertiser = &advertiser{}
|
||||
var Advertiser = new(advertiser)
|
||||
|
||||
// Add 添加广告主
|
||||
func (c *advertiser) Add(ctx context.Context, req *dto.AddAdvertiserReq) (res *dto.AddAdvertiserRes, err error) {
|
||||
|
||||
@@ -7,9 +7,7 @@ import (
|
||||
"cidservice/service"
|
||||
)
|
||||
|
||||
var (
|
||||
Application = application{}
|
||||
)
|
||||
var Application = new(application)
|
||||
|
||||
type application struct{}
|
||||
|
||||
|
||||
@@ -9,9 +9,7 @@ import (
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
)
|
||||
|
||||
var (
|
||||
CID = cid{}
|
||||
)
|
||||
var CID = new(cid)
|
||||
|
||||
type cid struct{}
|
||||
|
||||
|
||||
@@ -7,9 +7,7 @@ import (
|
||||
"cidservice/service"
|
||||
)
|
||||
|
||||
var (
|
||||
RateLimit = rateLimit{}
|
||||
)
|
||||
var RateLimit = new(rateLimit)
|
||||
|
||||
type rateLimit struct{}
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ import (
|
||||
|
||||
type report struct{}
|
||||
|
||||
var Report = &report{}
|
||||
var Report = new(report)
|
||||
|
||||
// Create 创建报表
|
||||
func (c *report) Create(ctx context.Context, req *dto.CreateReportReq) (res *dto.CreateReportRes, err error) {
|
||||
|
||||
@@ -7,9 +7,7 @@ import (
|
||||
"cidservice/service"
|
||||
)
|
||||
|
||||
var (
|
||||
StatReport = &statReport{}
|
||||
)
|
||||
var StatReport = new(statReport)
|
||||
|
||||
type statReport struct{}
|
||||
|
||||
|
||||
@@ -9,9 +9,7 @@ import (
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
)
|
||||
|
||||
var (
|
||||
Strategy = strategy{}
|
||||
)
|
||||
var Strategy = new(strategy)
|
||||
|
||||
type strategy struct{}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user