浏览代码

switch kw

Jason 1 年之前
父节点
当前提交
21c8125f8b
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      website_clickjobs/type-V/_execute.py

+ 3 - 2
website_clickjobs/type-V/_execute.py

@@ -40,8 +40,9 @@ def pickterm(client): # OLD TABLE NAME: seo.seo_jobs
     ds=db.query("select json from public.seo_jobs_temp where cust='" + client + "' order by random() limit 1")
     #TAG ABOVE AND UNTAG BELOW FOR DEBUG
     #ds=hhhdb.query('select * from seo.seo_articles where cust=')
-    
+    print(len([ds]))
     for c in ds:
+        print(c['json'])
         js=json.loads(c['json'])
         prefix=js['prefix']
         postfix=js['postfix']
@@ -50,7 +51,7 @@ def pickterm(client): # OLD TABLE NAME: seo.seo_jobs
         rnd=js['rnd']
     kw1 = choice(positive)
     kw2 = choice(rnd)
-    kw = prefix + " " + kw1 + " " + kw2
+    kw = kw1 + " " + kw2 + " " + prefix
     return kw
 
 def process_one(term, tgt, n, sr, se):