Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
岳巧源
/
jd_data_process
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
e6369c5c
authored
Oct 25, 2024
by
岳巧源
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
add update
parent
023e32be
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
10 deletions
crontab.py
tmp.sql
crontab.py
View file @
e6369c5c
...
@@ -163,7 +163,7 @@ def update_vc_attr(conf: dict):
...
@@ -163,7 +163,7 @@ def update_vc_attr(conf: dict):
else
:
else
:
print
(
"此input_type类型暂未兼容处理!请单独处理!"
)
print
(
"此input_type类型暂未兼容处理!请单独处理!"
)
create_time
=
int
(
time
.
time
())
create_time
=
int
(
time
.
time
())
update_time
=
int
(
time
.
time
())
"""
"""
检查属性需不需要更新等等。。。
检查属性需不需要更新等等。。。
"""
"""
...
@@ -206,8 +206,8 @@ def update_vc_attr(conf: dict):
...
@@ -206,8 +206,8 @@ def update_vc_attr(conf: dict):
exists_attr
=
True
exists_attr
=
True
for
key
in
origin_attr_map
:
for
key
in
origin_attr_map
:
if
origin_attr_map
[
key
]
!=
now_attr_map
[
key
]:
if
origin_attr_map
[
key
]
!=
now_attr_map
[
key
]:
update_sql1
=
"update lie_shop_attr set unit =
%
s, enum_value =
%
s, input_type =
%
s, is_required =
%
s, is_mapping = 0 where id =
%
s"
update_sql1
=
"update lie_shop_attr set unit =
%
s, enum_value =
%
s, input_type =
%
s, is_required =
%
s,
update_time =
%
s ,
is_mapping = 0 where id =
%
s"
cursor
.
execute
(
query
=
update_sql1
,
args
=
(
unit
,
enum_value
,
input_type
,
is_required
,
primary_id
))
cursor
.
execute
(
query
=
update_sql1
,
args
=
(
unit
,
enum_value
,
input_type
,
is_required
,
update_time
,
primary_id
))
db
.
commit
()
db
.
commit
()
print
(
update_sql1
%
(
unit
,
enum_value
,
input_type
,
is_required
,
primary_id
))
print
(
update_sql1
%
(
unit
,
enum_value
,
input_type
,
is_required
,
primary_id
))
break
break
...
...
tmp.sql
View file @
e6369c5c
delete
from
lie_shop_class
where
platform
=
1
;
-- delete from lie_shop_class where platform = 1;
delete
from
lie_shop_attr
where
platform
=
1
;
-- delete from lie_shop_attr where platform = 1;
delete
from
lie_shop_class_mapping
where
platform
=
1
;
-- delete from lie_shop_class_mapping where platform = 1;
delete
from
lie_shop_attr_mapping
where
platform
=
1
;
-- delete from lie_shop_attr_mapping where platform = 1;
select
apply_id
from
lie_shop_push_sku_log
where
spu_id
=
1
and
sku_id
=
1
order
by
create_time
desc
limit
1
;
-- select apply_id from lie_shop_push_sku_log where spu_id = 1 and sku_id = 1 order by create_time desc limit 1;
--
--
-- update lie_shop_push_sku_log set audit_status = 0 where ware_id == ""
--
alter
table
lie_shop_push_sku_log
add
column
stock_num
int
unsigned
default
0
not
null
comment
'库存数量'
after
ware_id
;
update
lie_shop_push_sku_log
set
audit_status
=
0
where
ware_id
==
""
alter
table
lie_shop_push_sku_log
change
status
push_status
tinyint
(
1
)
unsigned
default
0
not
null
comment
'发品状态 -1:失败 1:成功'
;
\ No newline at end of file
alter
table
lie_shop_push_sku_log
add
column
init_status
tinyint
(
1
)
unsigned
default
0
not
null
comment
'库存、时效初始化状态 -1:失败 1:成功'
after
update_time
;
\ No newline at end of file
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