瀏覽代碼

MOD:素材库-文本模块,添加文本筛选

cxyu 3 年之前
父節點
當前提交
98c37bf7fe
共有 2 個文件被更改,包括 2 次插入3 次删除
  1. 2 2
      data_manage/public_analysis.py
  2. 0 1
      handlers/PublicAnalysisHandler.py

+ 2 - 2
data_manage/public_analysis.py

@@ -1012,8 +1012,8 @@ def content_rank(user_id, start, end, page, page_size, order, order_by, book, ch
     max(video_length) as video_length,
     sum(use_times) as use_times
     from dw_image_cost_day 
-    where (REPLACE(REPLACE(description, CHAR(10), ''), CHAR(13), '') is not null 
-    or REPLACE(REPLACE(title, CHAR(10), ''), CHAR(13), '') is not null )
+    where (  length(REPLACE(REPLACE(description, CHAR(10), ''), CHAR(13), ''))>0 
+    or length(REPLACE(REPLACE(title, CHAR(10), ''), CHAR(13), ''))>0  )
     and (1=1 {op1}  {op_or1})
     {op4} {op10} {op_content} {op_campaign_id} 
     {op_time_bigger} {op_time_small} 

+ 0 - 1
handlers/PublicAnalysisHandler.py

@@ -243,7 +243,6 @@ class AdvertisementContent(BaseHandler):
         if not self._au:
             self.write_fail(msg='auth error')
         else:
-
             du = DateUtils()
             arg = self.get_args()
             data_type = arg.get('dataType', 'all') if arg.get('dataType',