From 16e4354e393799963ec49630d814292bbfeae110 Mon Sep 17 00:00:00 2001
From: wumu <mayi@mayi.com>
Date: 星期三, 15 五月 2024 23:45:15 +0800
Subject: [PATCH] 0515

---
 internal_system_v1/threemergeproblemlist.cpp |   85 +++++++++
 internal_system_v1/clientmainwindow.ui       |    2 
 internal_system_v1/threemergeproblemlist.ui  |  448 +++++++++++++++++++++++++++++++++++++++++++++---
 internal_system_v1/threemergeproblemlist.h   |    2 
 4 files changed, 501 insertions(+), 36 deletions(-)

diff --git a/internal_system_v1/clientmainwindow.ui b/internal_system_v1/clientmainwindow.ui
index 2698696..ef4d6ab 100644
--- a/internal_system_v1/clientmainwindow.ui
+++ b/internal_system_v1/clientmainwindow.ui
@@ -11,7 +11,7 @@
    </rect>
   </property>
   <property name="windowTitle">
-   <string>IS v2.0</string>
+   <string>IS v3.0</string>
   </property>
   <widget class="QWidget" name="centralWidget">
    <layout class="QGridLayout" name="gridLayout_3">
diff --git a/internal_system_v1/threemergeproblemlist.cpp b/internal_system_v1/threemergeproblemlist.cpp
index 2b00b35..e3ecf7f 100644
--- a/internal_system_v1/threemergeproblemlist.cpp
+++ b/internal_system_v1/threemergeproblemlist.cpp
@@ -830,3 +830,88 @@
     QMessageBox::information(this,"淇濆瓨鎻愮ず",QString("鎬昏鏁颁负%1,鎴愬姛%2琛岋紝澶辫触%3琛屻��").arg(ui->tableWidget->rowCount())
                              .arg(hasContentRow).arg(ui->tableWidget->rowCount()-hasContentRow));
 }
+
+void ThreeMergeProblemList::on_pushButton_moreSearch_clicked()
+{
+    QString sql = "select * from standing_book_info ";
+
+    QVector<QString> vecCon; // 淇濆瓨鎵�鏈夋潯浠�
+
+    if(ui->checkBox_type->isChecked()){
+        QString condition= QString(" 瀹¤绫诲埆='%1' ").arg(ui->comboBox_type->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_year->isChecked()){
+        QString condition= QString(" 瀹¤骞村害='%1' ").arg(ui->dateEdit_year->text());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_com->isChecked()){
+        QString condition= QString(" 瀹¤鍗曚綅='%1' ").arg(ui->comboBox_com->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_way->isChecked()){
+        QString condition= QString(" 瀹¤鏂瑰紡='%1' ").arg(ui->comboBox_way->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_mainCom->isChecked()){
+        QString condition= QString(" 璐d换涓讳綋鍚嶇О='%1' ").arg(ui->comboBox_mainCom->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_pro->isChecked()){
+        QString condition= QString(" 瀹¤椤圭洰='%1' ").arg(ui->comboBox_pro->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_proName->isChecked()){
+        QString condition= QString(" 瀹¤椤圭洰鍚嶇О='%1' ").arg(ui->comboBox_proName->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_qtype->isChecked()){
+        QString condition= QString(" 闂绫诲埆='%1' ").arg(ui->comboBox_qtype->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_qdx->isChecked()){
+        QString condition= QString(" 闂瀹氭��='%1' ").arg(ui->comboBox_qdx->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_about_money->isChecked()){
+        QString condition= QString(" 娑夊強閲戦>='%1' and 娑夊強閲戦<='%2' ").arg(ui->comboBox_about_bgMonney->currentText()).arg(ui->comboBox_about_edMoney->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_changeMoney->isChecked()){
+        QString condition= QString(" 鏁存敼閲戦>='%1' and 鏁存敼閲戦<='%2' ").arg(ui->comboBox_change_bgMoney->currentText()).arg(ui->comboBox_change_edMoney->currentText());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_change_over_time->isChecked()){
+        QString condition= QString(" 鏁存敼瀹屾垚鏃堕棿='%1' ").arg(ui->dateEdit_change_over_time->text());
+        vecCon.append(condition);
+    }
+    if(ui->checkBox_change_expected_time->isChecked()){
+        QString condition= QString(" 鏁存敼棰勮瀹屾垚鏃堕棿='%1' ").arg(ui->dateEdit_change_expected_time->text());
+        vecCon.append(condition);
+    }
+    QString condition;
+    if(vecCon.size() == 1){
+        condition += QString(" where %1").arg(vecCon.at(0));
+    }else if(vecCon.size() > 1){
+        condition += QString(" where %1").arg(vecCon.at(0));
+        for(int i=1;i<vecCon.size();++i){
+            condition += QString(" and %1 ").arg(vecCon.at(i));
+        }
+    }
+    sql += condition;
+    qDebug()<<sql;
+
+    QVector<QVector<QString>> res;
+    int rows = selectSQL(sql,res);
+    if(rows > 0){
+        ui->tableWidget->setRowCount(rows);
+        for(int i=0;i<res.size();++i){
+            for(int j=0;j<res.at(0).size()-1;++j){ // 鍘绘帀璁板綍鏃堕棿
+                ui->tableWidget->setItem(i,j,new QTableWidgetItem(res[i][j]));
+            }
+        }
+    }else{
+        QMessageBox::information(this,"鏌ヨ澶辫触","鍙兘鏌ヨ鐨勫唴瀹逛笉姝g‘鎴栬�呮病鏈夎褰曠浉搴旂殑鏁版嵁");
+    }
+
+}
diff --git a/internal_system_v1/threemergeproblemlist.h b/internal_system_v1/threemergeproblemlist.h
index ccbab03..4de9168 100644
--- a/internal_system_v1/threemergeproblemlist.h
+++ b/internal_system_v1/threemergeproblemlist.h
@@ -68,6 +68,8 @@
 
     void on_pushButton_save_3_clicked();
 
+    void on_pushButton_moreSearch_clicked();
+
 private:
     Ui::ThreeMergeProblemList *ui;
     QMenu *m_menu; // 闂娓呭崟鑿滃崟
diff --git a/internal_system_v1/threemergeproblemlist.ui b/internal_system_v1/threemergeproblemlist.ui
index a60a22a..41a04e6 100644
--- a/internal_system_v1/threemergeproblemlist.ui
+++ b/internal_system_v1/threemergeproblemlist.ui
@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>1483</width>
-    <height>1031</height>
+    <width>1281</width>
+    <height>1038</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -25,8 +25,8 @@
         <rect>
          <x>0</x>
          <y>0</y>
-         <width>1459</width>
-         <height>956</height>
+         <width>1257</width>
+         <height>654</height>
         </rect>
        </property>
        <layout class="QGridLayout" name="gridLayout_5">
@@ -199,33 +199,6 @@
         </item>
         <item row="5" column="0">
          <layout class="QGridLayout" name="gridLayout_3">
-          <item row="1" column="1">
-           <widget class="QLabel" name="label">
-            <property name="text">
-             <string>瑕佸垹闄ゆ煇涓�琛岀洿鎺ュ彸鍑诲垹闄ゅ嵆鍙�</string>
-            </property>
-           </widget>
-          </item>
-          <item row="1" column="2">
-           <spacer name="horizontalSpacer">
-            <property name="orientation">
-             <enum>Qt::Horizontal</enum>
-            </property>
-            <property name="sizeHint" stdset="0">
-             <size>
-              <width>40</width>
-              <height>20</height>
-             </size>
-            </property>
-           </spacer>
-          </item>
-          <item row="1" column="3">
-           <widget class="QPushButton" name="pushButton_save">
-            <property name="text">
-             <string>淇濆瓨</string>
-            </property>
-           </widget>
-          </item>
           <item row="2" column="0" colspan="4">
            <widget class="QTableWidget" name="tableWidget_2">
             <attribute name="horizontalHeaderVisible">
@@ -311,10 +284,30 @@
             </column>
            </widget>
           </item>
-          <item row="1" column="0">
-           <widget class="QPushButton" name="pushButton_addRow">
+          <item row="1" column="2">
+           <spacer name="horizontalSpacer">
+            <property name="orientation">
+             <enum>Qt::Horizontal</enum>
+            </property>
+            <property name="sizeHint" stdset="0">
+             <size>
+              <width>40</width>
+              <height>20</height>
+             </size>
+            </property>
+           </spacer>
+          </item>
+          <item row="1" column="3">
+           <widget class="QPushButton" name="pushButton_save">
             <property name="text">
-             <string>澧炲姞涓�琛�</string>
+             <string>淇濆瓨</string>
+            </property>
+           </widget>
+          </item>
+          <item row="1" column="1">
+           <widget class="QLabel" name="label">
+            <property name="text">
+             <string>瑕佸垹闄ゆ煇涓�琛岀洿鎺ュ彸鍑诲垹闄ゅ嵆鍙�</string>
             </property>
            </widget>
           </item>
@@ -322,6 +315,13 @@
            <widget class="QLabel" name="label_5">
             <property name="text">
              <string>鏁存敼鎴愭灉</string>
+            </property>
+           </widget>
+          </item>
+          <item row="1" column="0">
+           <widget class="QPushButton" name="pushButton_addRow">
+            <property name="text">
+             <string>澧炲姞涓�琛�</string>
             </property>
            </widget>
           </item>
@@ -682,6 +682,384 @@
       </widget>
      </widget>
     </item>
+    <item row="1" column="0">
+     <widget class="QGroupBox" name="groupBox">
+      <property name="minimumSize">
+       <size>
+        <width>0</width>
+        <height>200</height>
+       </size>
+      </property>
+      <property name="title">
+       <string>澶氱淮搴︽煡璇㈡潯浠�</string>
+      </property>
+      <layout class="QGridLayout" name="gridLayout_6">
+       <item row="0" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout">
+         <item>
+          <widget class="QCheckBox" name="checkBox_type">
+           <property name="text">
+            <string>瀹¤绫诲埆</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_type">
+           <item>
+            <property name="text">
+             <string>鍐呭</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>澶栧</string>
+            </property>
+           </item>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="0" column="1">
+        <layout class="QHBoxLayout" name="horizontalLayout_10">
+         <item>
+          <widget class="QCheckBox" name="checkBox_about_money">
+           <property name="text">
+            <string>娑夊強閲戦(涓�)</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_about_bgMonney">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QLabel" name="label_8">
+           <property name="text">
+            <string>鑷�</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_about_edMoney">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="1" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_2">
+         <item>
+          <widget class="QCheckBox" name="checkBox_year">
+           <property name="text">
+            <string>瀹¤骞村害</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QDateEdit" name="dateEdit_year">
+           <property name="displayFormat">
+            <string>yyyy</string>
+           </property>
+           <property name="date">
+            <date>
+             <year>2024</year>
+             <month>1</month>
+             <day>1</day>
+            </date>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="1" column="1">
+        <layout class="QHBoxLayout" name="horizontalLayout_11">
+         <item>
+          <widget class="QCheckBox" name="checkBox_changeMoney">
+           <property name="text">
+            <string>鏁存敼閲戦(涓�)</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_change_bgMoney">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QLabel" name="label_9">
+           <property name="text">
+            <string>鑷�</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_change_edMoney">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="2" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_3">
+         <item>
+          <widget class="QCheckBox" name="checkBox_com">
+           <property name="text">
+            <string>瀹¤鍗曚綅</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_com">
+           <item>
+            <property name="text">
+             <string>瀹¤灞�</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>瀹¤鍘�</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>瀹¤缃�</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>鍏朵粬</string>
+            </property>
+           </item>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="2" column="1">
+        <layout class="QHBoxLayout" name="horizontalLayout_12">
+         <item>
+          <widget class="QCheckBox" name="checkBox_change_over_time">
+           <property name="text">
+            <string>鏁存敼瀹屾垚鏃堕棿</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QDateEdit" name="dateEdit_change_over_time">
+           <property name="displayFormat">
+            <string>yyyy/MM/dd</string>
+           </property>
+           <property name="date">
+            <date>
+             <year>2024</year>
+             <month>1</month>
+             <day>1</day>
+            </date>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="3" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_4">
+         <item>
+          <widget class="QCheckBox" name="checkBox_way">
+           <property name="text">
+            <string>瀹¤鏂瑰紡</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_way">
+           <item>
+            <property name="text">
+             <string>灏卞湴瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>鎶ラ�佸璁�</string>
+            </property>
+           </item>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="3" column="1" rowspan="2">
+        <layout class="QHBoxLayout" name="horizontalLayout_13">
+         <item>
+          <widget class="QCheckBox" name="checkBox_change_expected_time">
+           <property name="text">
+            <string>鏁存敼棰勮瀹屾垚鏃堕棿</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QDateEdit" name="dateEdit_change_expected_time">
+           <property name="displayFormat">
+            <string>yyyy/MM/dd</string>
+           </property>
+           <property name="date">
+            <date>
+             <year>2024</year>
+             <month>1</month>
+             <day>1</day>
+            </date>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="4" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_5">
+         <item>
+          <widget class="QCheckBox" name="checkBox_mainCom">
+           <property name="text">
+            <string>璐d换涓讳綋</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_mainCom">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="5" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_6">
+         <item>
+          <widget class="QCheckBox" name="checkBox_pro">
+           <property name="text">
+            <string>瀹¤椤圭洰</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_pro">
+           <item>
+            <property name="text">
+             <string>璐交钀藉疄鍥藉閲嶅ぇ鏀跨瓥鎺柦瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>璐㈡斂璐㈠姟鏀舵敮瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>鍥哄畾璧勪骇鎶曡祫瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>鍐呴儴鎺у埗鍜岄闄╃鐞嗗璁�</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>缁忔祹璐d换瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>淇℃伅绯荤粺瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>澧冨瀹¤</string>
+            </property>
+           </item>
+           <item>
+            <property name="text">
+             <string>鍏朵粬</string>
+            </property>
+           </item>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="6" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_7">
+         <item>
+          <widget class="QCheckBox" name="checkBox_proName">
+           <property name="text">
+            <string>瀹¤椤圭洰鍚嶇О</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_proName">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="7" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_8">
+         <item>
+          <widget class="QCheckBox" name="checkBox_qtype">
+           <property name="text">
+            <string>闂绫诲埆</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_qtype">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+       <item row="7" column="2" rowspan="2">
+        <widget class="QPushButton" name="pushButton_moreSearch">
+         <property name="font">
+          <font>
+           <pointsize>15</pointsize>
+          </font>
+         </property>
+         <property name="text">
+          <string>澶氱淮搴︽煡璇�</string>
+         </property>
+        </widget>
+       </item>
+       <item row="8" column="0">
+        <layout class="QHBoxLayout" name="horizontalLayout_9">
+         <item>
+          <widget class="QCheckBox" name="checkBox_qdx">
+           <property name="text">
+            <string>闂瀹氭��</string>
+           </property>
+          </widget>
+         </item>
+         <item>
+          <widget class="QComboBox" name="comboBox_qdx">
+           <property name="editable">
+            <bool>true</bool>
+           </property>
+          </widget>
+         </item>
+        </layout>
+       </item>
+      </layout>
+     </widget>
+    </item>
    </layout>
   </widget>
   <widget class="QMenuBar" name="menubar">
@@ -689,7 +1067,7 @@
     <rect>
      <x>0</x>
      <y>0</y>
-     <width>1483</width>
+     <width>1281</width>
      <height>26</height>
     </rect>
    </property>

--
Gitblit v1.8.0