Commit 6a522050 by 周杭

三码合一

1 parent 04901588
...@@ -53,7 +53,7 @@ log.info("启动2") ...@@ -53,7 +53,7 @@ log.info("启动2")
# 创建连接池对象 # 创建连接池对象
connection_pool = pooling.MySQLConnectionPool( connection_pool = pooling.MySQLConnectionPool(
pool_name="mypool", pool_name="mypool",
pool_size=10, pool_size=32,
pool_reset_session=True, pool_reset_session=True,
host=Config.host, host=Config.host,
port=Config.port, port=Config.port,
...@@ -438,6 +438,13 @@ def handle_process(jsonData): ...@@ -438,6 +438,13 @@ def handle_process(jsonData):
connection.commit() connection.commit()
ocr_vin(path, data, connection, cursor, original_image) ocr_vin(path, data, connection, cursor, original_image)
# 删除数据库里的sn旧数据
delete_sql1 = "DELETE FROM sys_order_ocr_sn_result WHERE order_id = {}".format(order_id)
log.info(delete_sql1)
cursor.execute(delete_sql1)
connection.commit()
ocr_sn(dst, path, data, connection, cursor, original_image)
if file_type == 1: if file_type == 1:
# 删除数据库里的sn旧数据 # 删除数据库里的sn旧数据
delete_sql1 = "DELETE FROM sys_order_ocr_sn_result WHERE order_id = {}".format(order_id) delete_sql1 = "DELETE FROM sys_order_ocr_sn_result WHERE order_id = {}".format(order_id)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!