From d932713f0fb293da1024673168f0b5267094f04b Mon Sep 17 00:00:00 2001 From: wangweiye7840 Date: Sun, 16 Jun 2024 18:09:30 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=8B=E8=83=BD=E5=8D=B7=E7=94=9F=E6=88=90?= =?UTF-8?q?=E5=8A=9F=E8=83=BD=E9=80=82=E9=85=8Dmariadb=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E7=9A=84=E6=9D=90=E6=96=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 工具v4/赋能卷生成.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/工具v4/赋能卷生成.py b/工具v4/赋能卷生成.py index 7aeb55aa..5e6d173f 100644 --- a/工具v4/赋能卷生成.py +++ b/工具v4/赋能卷生成.py @@ -32,7 +32,6 @@ class MyWindow_fnsc(QWidget,Ui_Form): mydb = connect(hostname = db_host, port = db_port, username=db_user, pwd=db_pwd, db = self.database_name) mycursor = mydb.cursor() pro_dict,obj_dict,bn_dict,unit_obj_dict = generateDictsfromMariaDB(mycursor) - mydb.close() units_list = [] for self.checkbox in self.findChildren(QCheckBox): if self.checkbox.isChecked(): @@ -48,7 +47,8 @@ class MyWindow_fnsc(QWidget,Ui_Form): elif self.radioButton_median.isChecked(): method = "median" sim_threshold = float(self.lineEdit_threshold.text()) - excludeids = findxiaobenIDs("../备课组",grade = self.lineEdit_grade.text()) + excludeids = findxiaobenIDs(mycursor,grade = self.lineEdit_grade.text()) + mydb.close() papercount = int(self.lineEdit_papercount.text()) output = "" for i in range(papercount):