Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
黄成意
/
go_sku_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
6696f4e1
authored
Mar 09, 2026
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
补充spu字段
parent
48df4097
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
11 deletions
model/ly_sku.go
service/service_ly_common.go
model/ly_sku.go
View file @
6696f4e1
...
...
@@ -60,16 +60,19 @@ type LySku struct {
ClassName
string
`json:"class_name,omitempty"`
ErpTax
interface
{}
`json:"erp_tax"`
GoodsSn
string
`json:"goods_sn"`
GoodsDetails
string
`json:"goods_details"`
ClassName1
string
`json:"class_name1,omitempty"`
ClassName2
string
`json:"class_name2,omitempty"`
ClassName3
string
`json:"class_name3,omitempty"`
Ratio
float64
`json:"ratio,omitempty"`
RatioUs
float64
`json:"ratio_us,omitempty"`
SpuDetail
string
`json:"spu_detail,omitempty"`
AcType
int
`json:"ac_type"`
GoodsSn
string
`json:"goods_sn"`
GoodsDetails
string
`json:"goods_details"`
ClassName1
string
`json:"class_name1,omitempty"`
ClassName2
string
`json:"class_name2,omitempty"`
ClassName3
string
`json:"class_name3,omitempty"`
Ratio
float64
`json:"ratio,omitempty"`
RatioUs
float64
`json:"ratio_us,omitempty"`
SpuDetail
string
`json:"spu_detail,omitempty"`
ApplicationLevel
string
`json:"application_level"`
HasRohs
string
`json:"has_rohs"`
Series
string
`json:"series"`
Lifecycle
string
`json:"lifecycle"`
AcType
int
`json:"ac_type"`
//活动信息
HasGiftActivity
int
`json:"has_gift_activity"`
GiftActivity
GiftActivity
`json:"gift_activity"`
...
...
service/service_ly_common.go
View file @
6696f4e1
...
...
@@ -251,7 +251,8 @@ func (ls *LyService) GetIsBuy(sku model.LySku) (isBuy int) {
return
}
if
sku
.
AbilityLevel
==
0
&&
sku
.
OrgId
==
1
&&
sku
.
Canal
!=
"L0015730"
{
//L0016691 L0015730 L0015835 L0016793 L0016887 L0016886 L0016784
if
sku
.
AbilityLevel
==
0
&&
sku
.
OrgId
==
1
&&
(
sku
.
Canal
!=
"L0015730"
&&
sku
.
Canal
!=
"L0015835"
&&
sku
.
Canal
!=
"L0016691"
&&
sku
.
Canal
!=
"L0016793"
&&
sku
.
Canal
!=
"L0016887"
&&
sku
.
Canal
!=
"L0016886"
&&
sku
.
Canal
!=
"L0016784"
)
{
return
}
if
sku
.
Stock
==
0
{
...
...
@@ -300,6 +301,10 @@ func (ls *LyService) CombineSup(sku model.LySku, spuStr string) model.LySku {
sku
.
Status
=
int
(
gjson
.
Get
(
spuStr
,
"status"
)
.
Int
())
sku
.
Encap
=
gjson
.
Get
(
spuStr
,
"encap"
)
.
String
()
sku
.
SpuEccn
=
gjson
.
Get
(
spuStr
,
"eccn"
)
.
String
()
sku
.
ApplicationLevel
=
gjson
.
Get
(
spuStr
,
"application_level"
)
.
String
()
sku
.
HasRohs
=
gjson
.
Get
(
spuStr
,
"has_rohs"
)
.
String
()
sku
.
Series
=
gjson
.
Get
(
spuStr
,
"series"
)
.
String
()
sku
.
Lifecycle
=
gjson
.
Get
(
spuStr
,
"lifecycle"
)
.
String
()
return
sku
}
...
...
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