Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
孙龙
/
golang_asynctask
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
5ab1e276
authored
Aug 13, 2021
by
Joneq
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
去除旧商品
parent
d3af865b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
cmd/scm/sync_customs/main.go
cmd/scm/sync_customs/main.go
View file @
5ab1e276
...
@@ -50,6 +50,8 @@ var currentDatetime int64
...
@@ -50,6 +50,8 @@ var currentDatetime int64
//同步海关信息至中间库
//同步海关信息至中间库
func
main
()
{
func
main
()
{
UpdateOldGoodsId
()
panic
(
1
)
runtime
.
GOMAXPROCS
(
5
)
runtime
.
GOMAXPROCS
(
5
)
//获取当天时间
//获取当天时间
...
@@ -249,6 +251,7 @@ func UpdateOldGoodsId() {
...
@@ -249,6 +251,7 @@ func UpdateOldGoodsId() {
for
_
,
v
:=
range
numArr
{
for
_
,
v
:=
range
numArr
{
result
,
_
:=
sub
.
GetCustomsDockingData
(
`{"tableName":"Purchase_Order2","bizDate":"`
+
v
+
`"}`
)
result
,
_
:=
sub
.
GetCustomsDockingData
(
`{"tableName":"Purchase_Order2","bizDate":"`
+
v
+
`"}`
)
fmt
.
Println
(
"正在修改"
+
v
)
if
gjson
.
Get
(
result
,
"0.goods_id"
)
.
String
()
!=
""
{
if
gjson
.
Get
(
result
,
"0.goods_id"
)
.
String
()
!=
""
{
sqlDb
.
Exec
(
"update Purchase_Order set goods_id = '"
+
gjson
.
Get
(
result
,
"0.goods_id"
)
.
String
()
+
"' where number ='"
+
v
+
"'"
)
sqlDb
.
Exec
(
"update Purchase_Order set goods_id = '"
+
gjson
.
Get
(
result
,
"0.goods_id"
)
.
String
()
+
"' where number ='"
+
v
+
"'"
)
}
}
...
...
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