添加按companyid返回广告列表的方法

This commit is contained in:
pengtao 2019-07-11 11:03:02 +08:00
parent 240631dfcc
commit 22bfc069df

View File

@ -57,7 +57,7 @@ class Ad(Resource):
f"status,companyid,locationid,gameid from ad where companyid={companyid};" f"status,companyid,locationid,gameid from ad where companyid={companyid};"
elif status or status == 0: elif status or status == 0:
sel_sql = f"select id,name,begin_time,end_time,ad_num,ad_title,ad_body,ad_image,ad_url,ad_sort," \ sel_sql = f"select id,name,begin_time,end_time,ad_num,ad_title,ad_body,ad_image,ad_url,ad_sort," \
f"statuscompanyid,locationid,gameid from ad where status={status};" f"status,companyid,locationid,gameid from ad where status={status};"
else: else:
sel_sql = f"select id,name,begin_time,end_time,ad_num,ad_title,ad_body,ad_image,ad_url,ad_sort," \ sel_sql = f"select id,name,begin_time,end_time,ad_num,ad_title,ad_body,ad_image,ad_url,ad_sort," \
f"status,companyid,locationid,gameid from ad ;" f"status,companyid,locationid,gameid from ad ;"