Commit 8ed62dad authored by lixiaofang's avatar lixiaofang

add

parent b7bfe8ac
......@@ -143,7 +143,7 @@ class Pictorial(models.Model):
def get_edit_tag_name(self, tag_id):
try:
tag_name_list = list(
Tag.objects.filter(id__in=tag_id, is_online=True, is_collection=1).values_list("name", flat=True))
Tag.objects.filter(id__in=tag_id, is_online=True).values_list("name", flat=True))
return tag_name_list
except:
......@@ -271,7 +271,7 @@ class Pictorial(models.Model):
PictorialTopics.objects.filter(pictorial_id=self.id, is_online=True, is_deleted=False).values_list(
"topic_id", flat=True))
topic_info = Topic.objects.filter(id__in=topic_id_list).values("user_id", "create_time")
topic_info = Topic.objects.filter(id__in=topic_id_list,is_online=1).values("user_id", "create_time")
if topic_info.count() > 0:
for topic in topic_info:
......
......@@ -74,7 +74,7 @@ class PictorialTransfer(object):
res["latest_real_topic_time"] = instance.get_latest_real_topic_time()
res["real_user_activate_time"] = instance.get_real_user_activate_time()
res["edit_tag_id"] = instance.get_edit_tag_id()
res["edit_tag_name"] = instance.get_edit_tag_name()
res["edit_tag_name"] = instance.get_edit_tag_name(res["edit_tag_id"])
logging.info("get data:%s" % res)
return res
except:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment