Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
杨树贤
/
search_server
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
cb50a0de
authored
Apr 20, 2023
by
SUDPTDUBLXEROFX\Administrator
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
添加活动信息
parent
b0f31df2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
model/goods.go
service/goods_service.go
model/goods.go
View file @
cb50a0de
...
...
@@ -15,6 +15,7 @@ type ApiGoods struct {
MpqStr
interface
{}
`json:"mpq"`
Mpl
int
`json:"-"`
StandardBrand
string
`json:"standard_brand"`
ActivityInfo
interface
{}
`json:"activity_info"`
StandardBrandName
string
`json:"standard_brand_name"`
StandardBrandUrl
string
`json:"standard_brand_url"`
MplStr
interface
{}
`json:"mpl,omitempty"`
...
...
service/goods_service.go
View file @
cb50a0de
...
...
@@ -86,7 +86,19 @@ func CurlGoodsInfo(ctx *gin.Context, goodsIdsStr string, params req.Param) (good
// goods.StandardBrandName = ""
// goods.StandardBrandUrl = ""
//}
ActivityInfoStr
:=
data
.
Get
(
"activity_info"
)
.
String
()
ActivityInfo
:=
map
[
string
]
string
{
"activity_id"
:
gjson
.
Get
(
ActivityInfoStr
,
"activity_id"
)
.
String
(),
"activity_name"
:
gjson
.
Get
(
ActivityInfoStr
,
"activity_name"
)
.
String
(),
"user_scope"
:
gjson
.
Get
(
ActivityInfoStr
,
"user_scope"
)
.
String
(),
"ratio"
:
gjson
.
Get
(
ActivityInfoStr
,
"ratio"
)
.
String
(),
"ratio_us"
:
gjson
.
Get
(
ActivityInfoStr
,
"ratio_us"
)
.
String
(),
"sign_text"
:
gjson
.
Get
(
ActivityInfoStr
,
"sign_text"
)
.
String
(),
"sign"
:
gjson
.
Get
(
ActivityInfoStr
,
"sign"
)
.
String
(),
"show_name"
:
gjson
.
Get
(
ActivityInfoStr
,
"show_name"
)
.
String
(),
}
goods
.
ActivityInfo
=
ActivityInfo
goods
.
StandardBrandName
=
""
goods
.
StandardBrandUrl
=
""
goods
.
PickType
=
int
(
data
.
Get
(
"pick_type"
)
.
Int
())
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment