32 lines
740 B
Go
32 lines
740 B
Go
|
|
package admin_agent
|
||
|
|
|
||
|
|
import (
|
||
|
|
"context"
|
||
|
|
|
||
|
|
"tydata-server/app/main/api/internal/svc"
|
||
|
|
"tydata-server/app/main/api/internal/types"
|
||
|
|
|
||
|
|
"github.com/zeromicro/go-zero/core/logx"
|
||
|
|
)
|
||
|
|
|
||
|
|
type AdminGetSystemConfigLogic struct {
|
||
|
|
logx.Logger
|
||
|
|
ctx context.Context
|
||
|
|
svcCtx *svc.ServiceContext
|
||
|
|
}
|
||
|
|
|
||
|
|
func NewAdminGetSystemConfigLogic(ctx context.Context, svcCtx *svc.ServiceContext) *AdminGetSystemConfigLogic {
|
||
|
|
return &AdminGetSystemConfigLogic{
|
||
|
|
Logger: logx.WithContext(ctx),
|
||
|
|
ctx: ctx,
|
||
|
|
svcCtx: svcCtx,
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
func (l *AdminGetSystemConfigLogic) AdminGetSystemConfig() (resp *types.AdminGetSystemConfigResp, err error) {
|
||
|
|
resp = &types.AdminGetSystemConfigResp{
|
||
|
|
CommissionSafeMode: l.svcCtx.Config.SystemConfig.CommissionSafeMode,
|
||
|
|
}
|
||
|
|
return
|
||
|
|
}
|