Commit 7d76e403 by huangjing

hj

parent 593f4369
......@@ -11,9 +11,11 @@ def talk(recommendId):
try:
list_test=[]
update_sql='UPDATE talking t1 ,tj_recommend_do_status t2 set t1.recommendId=t2.recommend_id where t1.recommend_product=t2.product_name'
print(update_sql,"==============根据id查询话术,update_sql")
cur.execute(update_sql)
connection.commit()
select_sql='select start_text,res_text,mq_text,end_text from talking where recommendId="%s"'%(recommendId)
print(select_sql,"=======根据id查询话术")
cur.execute(select_sql)
s=cur.fetchone()
for i in range(0,len(s)):
......@@ -30,6 +32,7 @@ def talkName(recommend_product):
try:
list_test=[]
select_sql='select start_text,res_text,mq_text,end_text from talking where recommend_product="%s"'%(recommend_product)
print(select_sql,"==============查询话术")
cur.execute(select_sql)
s=cur.fetchone()
for i in range(0,len(s)):
......@@ -48,6 +51,7 @@ def talking(server):
def SingleLogoApi():
try:
recommendId = request.get_json().get("recommendId")
print(recommendId,"=======获取recommendId")
isSuss, talkings = talk(recommendId)
if isSuss:
return json.dumps({"status": 0, "msg": "成功", "data": talkings}, ensure_ascii=False)
......
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