Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
V
vest
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rank
vest
Commits
7cb58edd
Commit
7cb58edd
authored
Dec 25, 2019
by
lixiaofang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kafka
parent
f1c5e06b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
39 additions
and
11 deletions
+39
-11
Project_Default.xml
.idea/inspectionProfiles/Project_Default.xml
+16
-0
consum.cpython-36.pyc
moment/views/__pycache__/consum.cpython-36.pyc
+0
-0
irrigation.cpython-36.pyc
moment/views/__pycache__/irrigation.cpython-36.pyc
+0
-0
irrigation.py
moment/views/irrigation.py
+23
-11
No files found.
.idea/inspectionProfiles/Project_Default.xml
0 → 100644
View file @
7cb58edd
<component
name=
"InspectionProjectProfileManager"
>
<profile
version=
"1.0"
>
<option
name=
"myName"
value=
"Project Default"
/>
<inspection_tool
class=
"PyPackageRequirementsInspection"
enabled=
"true"
level=
"WARNING"
enabled_by_default=
"true"
>
<option
name=
"ignoredPackages"
>
<value>
<list
size=
"2"
>
<item
index=
"0"
class=
"java.lang.String"
itemvalue=
"gm-rpcd"
/>
<item
index=
"1"
class=
"java.lang.String"
itemvalue=
"gunicorn"
/>
</list>
</value>
</option>
</inspection_tool>
</profile>
</component>
\ No newline at end of file
moment/views/__pycache__/consum.cpython-36.pyc
View file @
7cb58edd
No preview for this file type
moment/views/__pycache__/irrigation.cpython-36.pyc
View file @
7cb58edd
No preview for this file type
moment/views/irrigation.py
View file @
7cb58edd
...
...
@@ -19,18 +19,30 @@ def vest_irrigation(card_id=0, card_type=None, card_user_id=None, create_time=""
logging
.
info
(
"------------------------"
)
topic
=
settings
.
KAFKA_TOPIC_NAME
comment_msg_dict
=
{
"card_id"
:
card_id
,
"card_type"
:
"auto_vest"
,
"create_time"
:
create_time
,
"content_level"
:
content_level
,
"tag_names"
:
tag_names
,
"type"
:
"get_write_answer_userinfo"
,
"current_push_time"
:
create_time
,
'action_type'
:
'comment'
}
producer
.
send
(
topic
,
json
.
dumps
(
comment_msg_dict
)
.
encode
())
tag_list
=
[
"瘦脸针kyc"
,
"双眼皮kyc"
,
"水光针kyc"
,
"玻尿酸kyc"
,
"吸脂kyc"
,
"埋线提升kyc"
,
"鼻综合kyc"
,
"光子嫩肤kyc"
,
"没有想法kyc"
,
"牙齿kyc"
,
"抗衰紧致kyc"
,
"胸部kyc"
]
flag
=
False
if
len
(
tag_names
)
>
0
:
for
i
in
tag_names
:
if
i
in
tag_list
:
flag
=
True
if
flag
==
True
:
comment_msg_dict
=
{
"card_id"
:
card_id
,
"card_type"
:
"auto_vest"
,
"create_time"
:
create_time
,
"content_level"
:
content_level
,
"tag_names"
:
tag_names
,
"type"
:
"get_write_answer_userinfo"
,
"current_push_time"
:
create_time
,
'action_type'
:
'comment'
}
logging
.
info
(
"get card_info:
%
s"
%
comment_msg_dict
)
producer
.
send
(
topic
,
json
.
dumps
(
comment_msg_dict
)
.
encode
())
follow_msg_dict
=
{
"card_id"
:
card_id
,
...
...
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