Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
physical
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
0
Merge Requests
0
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
alpha
physical
Commits
2c56499c
Commit
2c56499c
authored
Dec 10, 2018
by
段英荣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modify
parent
b7f09802
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
20 deletions
+15
-20
user_transfer.py
trans2es/utils/user_transfer.py
+15
-20
No files found.
trans2es/utils/user_transfer.py
View file @
2c56499c
...
...
@@ -49,7 +49,7 @@ class UserTransfer(object):
res
[
"is_recommend"
]
=
is_recommend
res
[
"is_shadow"
]
=
is_shadow
except
:
logging
.
error
(
"
duan test,
catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
logging
.
error
(
"catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
res
[
"is_recommend"
]
=
False
res
[
"is_shadow"
]
=
False
...
...
@@ -57,30 +57,25 @@ class UserTransfer(object):
latest_topic_time_val
=
instance
.
get_latest_topic_time_val
()
res
[
"latest_topic_time_val"
]
=
latest_topic_time_val
except
:
logging
.
error
(
"
duan test,
catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
logging
.
error
(
"catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
res
[
"latest_topic_time_val"
]
=
-
1
try
:
tzlc_create_time
=
tzlc
(
instance
.
create_time
)
res
[
"create_time"
]
=
tzlc_create_time
res
[
"create_time_val"
]
=
int
(
time
.
mktime
(
tzlc_create_time
.
timetuple
()))
tzlc_create_time
=
tzlc
(
instance
.
create_time
)
res
[
"create_time"
]
=
tzlc_create_time
res
[
"create_time_val"
]
=
int
(
time
.
mktime
(
tzlc_create_time
.
timetuple
()))
tzlc_update_time
=
tzlc
(
instance
.
update_time
)
res
[
"update_time"
]
=
tzlc_update_time
res
[
"update_time_val"
]
=
int
(
time
.
mktime
(
tzlc_update_time
.
timetuple
()))
tzlc_update_time
=
tzlc
(
instance
.
update_time
)
res
[
"update_time"
]
=
tzlc_update_time
res
[
"update_time_val"
]
=
int
(
time
.
mktime
(
tzlc_update_time
.
timetuple
()))
res
[
"tag_list"
]
=
[]
res
[
"attention_user_id_list"
]
=
[]
res
[
"attention_group_id_list"
]
=
[]
res
[
"pick_user_id_list"
]
=
[]
res
[
"same_group_user_id_list"
]
=
[]
# res["tag_list"] = instance.get_user_tag_id_list()
# res["attention_user_id_list"] = cls.get_follow_user_id_list(userInstance=instance)
# res["attention_group_id_list"] = instance.get_attention_group_id_list()
# res["pick_user_id_list"] = instance.get_pick_user_id_list()
# res["same_group_user_id_list"] = instance.get_same_group_user_id_list()
try
:
res
[
"tag_list"
]
=
instance
.
get_user_tag_id_list
()
res
[
"attention_user_id_list"
]
=
cls
.
get_follow_user_id_list
(
userInstance
=
instance
)
res
[
"attention_group_id_list"
]
=
instance
.
get_attention_group_id_list
()
res
[
"pick_user_id_list"
]
=
instance
.
get_pick_user_id_list
()
res
[
"same_group_user_id_list"
]
=
instance
.
get_same_group_user_id_list
()
except
:
logging
.
error
(
"
duan test,
catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
logging
.
error
(
"catch exception,err_msg:
%
s"
%
traceback
.
format_exc
())
res
[
"tag_list"
]
=
[]
res
[
"attention_user_id_list"
]
=
[]
res
[
"attention_group_id_list"
]
=
[]
...
...
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