diff --git a/MagicLightAssistant.vcxproj.user b/MagicLightAssistant.vcxproj.user
index 4edcdb3..b3a60d5 100644
--- a/MagicLightAssistant.vcxproj.user
+++ b/MagicLightAssistant.vcxproj.user
@@ -2,9 +2,9 @@
- 2023-02-23T09:48:54.7583650Z
+ 2023-03-14T12:37:28.3943389Z
- 2023-02-23T09:48:54.8438294Z
+ 2023-03-14T12:37:28.4952107Z
\ No newline at end of file
diff --git a/approvalwork.cpp b/approvalwork.cpp
index 76aa43a..3b6c5ea 100644
--- a/approvalwork.cpp
+++ b/approvalwork.cpp
@@ -220,8 +220,14 @@ void ApprovalWork::autoExecuteSystemApplyItems()
if (options[2] != "无") //更新手机号
subQuery.exec(QString("UPDATE magic_users SET telephone='%1' WHERE uid=%2").arg(options[2], record.value("uid").toString()));
subQuery.exec(QString("UPDATE magic_apply SET status=3 WHERE apply_id='%1'").arg(apply_id)); //已自动处理数据
+ subQuery.exec(QString("SELECT mail FROM magic_users WHERE uid='%1';").arg(record.value("uid").toString()));
+ QString mail;
+ if (subQuery.next())
+ mail = subQuery.value("mail").toString();
DB_SECOND.close();
- finishedNum++;
+ finishedNum++;
+ if(!mail.isEmpty())
+ service::sendMail(smtp_config, mail, "WePlanet 审批进度更新", QString("用户%1:\n你的【个人信息异动申请】现已完成审核,个人信息现已更新。\n\n注:若异动信息有误,请联系管理员。").arg(record.value("uid").toString()));
}
}
}
@@ -266,8 +272,14 @@ void ApprovalWork::autoExecuteSystemApplyItems()
QSqlQuery subQuery(DB_SECOND);
subQuery.exec(QString("INSERT INTO magic_verify (v_uid, vid, info) VALUES ('%1', '%2', '%3') ON DUPLICATE KEY UPDATE vid='%4', info='%5';").arg(record.value("uid").toString(), options[0], options[1], options[0], options[1]));
subQuery.exec(QString("UPDATE magic_apply SET status=3 WHERE apply_id='%1'").arg(apply_id)); //已自动处理数据
+ subQuery.exec(QString("SELECT mail FROM magic_users WHERE uid='%1';").arg(record.value("uid").toString()));
+ QString mail;
+ if (subQuery.next())
+ mail = subQuery.value("mail").toString();
DB_SECOND.close();
finishedNum++;
+ if (!mail.isEmpty())
+ service::sendMail(smtp_config, mail, "WePlanet 审批进度更新", QString("用户%1:\n你的【账号认证申请】现已完成审核,账号认证信息现已更新。\n\n注:若认证信息有误,请联系管理员。").arg(record.value("uid").toString()));
}
}
}
@@ -531,5 +543,10 @@ QList ApprovalWork::getAuthApplyTokenResultList()
return authApplyTokenResultList;
}
+void ApprovalWork::setSmtpConfig(const QList config)
+{
+ smtp_config = config;
+}
+
ApprovalWork::~ApprovalWork()
{}
diff --git a/approvalwork.h b/approvalwork.h
index 413f832..b3293b2 100644
--- a/approvalwork.h
+++ b/approvalwork.h
@@ -22,6 +22,7 @@ class ApprovalWork : public QObject
QHash currentFormOptionsText; //当前申请表单 用户填写的文本
QList applyFormList, applyFormListDone; //等待审核的列表,已经审核的列表(apply_id, uid, item_id, options, operate_time)
QList authApplyTokenResultList; //包含申请表id,申请人,申请项目名,审核状态,申请时间
+ QList smtp_config;
public:
void getManagePageApplyItems(const QString& uid);
@@ -48,6 +49,7 @@ class ApprovalWork : public QObject
QList getCurrentApplyProcess(const QString& id);
QString getCurrentFormOptionsText(const QString& id); //当前申请表单的填写项的文本
QList getAuthApplyTokenResultList();
+ void setSmtpConfig(const QList config);
private slots:
diff --git a/checkupdate.cpp b/checkupdate.cpp
index e5c67e1..8c841bb 100644
--- a/checkupdate.cpp
+++ b/checkupdate.cpp
@@ -3,8 +3,8 @@
checkUpdate::checkUpdate()
{
- CurVersion = "1.2.8.8"; //鍦ㄦ澶勫畾涔夎蒋浠跺綋鍓嶇増鏈
- AutoUpdateToolVersion = 11288; //鑷姩鏇存柊宸ュ叿璇嗗埆鐗堟湰
+ CurVersion = "1.2.8.9"; //鍦ㄦ澶勫畾涔夎蒋浠跺綋鍓嶇増鏈
+ AutoUpdateToolVersion = 11289; //鑷姩鏇存柊宸ュ叿璇嗗埆鐗堟湰
writeVersion();
}
checkUpdate::~checkUpdate()
diff --git a/mainwindow.cpp b/mainwindow.cpp
index 0de5b5f..569d121 100644
--- a/mainwindow.cpp
+++ b/mainwindow.cpp
@@ -1264,7 +1264,7 @@ void MainWindow::on_actExit_triggered()
void MainWindow::on_actHome_triggered()
{
- if (ui->stackedWidget->currentIndex() == 13)
+ if (homeLoading)
return;
initModelViewIsDisplay();
ui->stackedWidget->setCurrentIndex(0);
@@ -1670,6 +1670,7 @@ void MainWindow::setApplyListManagePage()
QList currentFormOptionsList = currentOptions.split("$", QString::SkipEmptyParts);
updateApplyItemOptions(1, currentFormOptionsList);
+ ui->groupBox_inputApproveResult->setVisible(true);
ui->textEdit_applyResultText->setEnabled(true);
ui->btn_submitApplyResult_argee->setEnabled(true);
ui->btn_submitApplyResult_reject->setEnabled(true);
@@ -1710,6 +1711,7 @@ void MainWindow::setApplyListManagePage()
QList currentFormOptionsList = currentOptions.split("$", QString::SkipEmptyParts);
updateApplyItemOptions(1, currentFormOptionsList);
+ ui->groupBox_inputApproveResult->setVisible(false);
ui->textEdit_applyResultText->setEnabled(false);
ui->btn_submitApplyResult_argee->setEnabled(false);
ui->btn_submitApplyResult_reject->setEnabled(false);
@@ -2636,6 +2638,7 @@ void MainWindow::on_btn_setApplyToken_clicked()
void MainWindow::on_btn_autoExecuteSystemApplyItems_clicked()
{
autoExecuteSystemApplyItemsLoading = true;
+ approvalWork->setSmtpConfig(setBaseInfoWork->getSmtpConfig());
emit autoExecuteSystemApplyItems();
}
@@ -2932,8 +2935,15 @@ void MainWindow::on_actRefresh_triggered()
}
}
+void MainWindow::on_btn_openStore_clicked()
+{
+ QMessageBox::information(this, "鎻愮ず", "杩笉鍙婂緟浜嗭紵绉垎鍟嗗煄鐩墠姝e湪瑁呬慨涓...灏嗗湪浠婂勾绋嶅悗鎺ㄥ嚭銆", QMessageBox::Ok);
+}
+
void MainWindow::on_actSettings_triggered()
{
+ if (settingLoading)
+ return;
initModelViewIsDisplay();
if (ui->groupBox_system->isEnabled())
{
diff --git a/mainwindow.h b/mainwindow.h
index c7049e3..0996e07 100644
--- a/mainwindow.h
+++ b/mainwindow.h
@@ -283,6 +283,8 @@ private slots:
void receiveData(QString uid); //鎺ユ敹鐧诲綍绐楀彛淇″彿
+ void on_btn_openStore_clicked();
+
void on_actExit_triggered();
void on_actHome_triggered();
diff --git a/mainwindow.ui b/mainwindow.ui
index 919c099..91827a2 100644
--- a/mainwindow.ui
+++ b/mainwindow.ui
@@ -40,7 +40,7 @@
- 9
+ 0
@@ -547,6 +547,9 @@
--
+
+ true
+
-
@@ -576,6 +579,29 @@
+ -
+
+
+
+ 100
+ 35
+
+
+
+
+ 120
+ 35
+
+
+
+ 绉垎鍟嗗煄
+
+
+
+ :/images/color_icon/color-star_2.svg:/images/color_icon/color-star_2.svg
+
+
+
@@ -607,6 +633,7 @@
avatar
label_verifyIcon
+ btn_openStore
-
@@ -2116,8 +2143,8 @@ padding: 0px 5px;
0
0
- 259
- 16
+ 98
+ 28
@@ -2149,8 +2176,8 @@ padding: 0px 5px;
0
0
- 100
- 30
+ 98
+ 28
@@ -3997,8 +4024,8 @@ p, li { white-space: pre-wrap; }
0
0
- 259
- 16
+ 98
+ 28
@@ -4030,8 +4057,8 @@ p, li { white-space: pre-wrap; }
0
0
- 100
- 30
+ 98
+ 28
@@ -4063,8 +4090,8 @@ p, li { white-space: pre-wrap; }
0
0
- 100
- 30
+ 98
+ 28
@@ -4148,8 +4175,8 @@ p, li { white-space: pre-wrap; }
0
0
- 22
- 16
+ 100
+ 30
@@ -4188,8 +4215,8 @@ p, li { white-space: pre-wrap; }
0
0
- 20
- 263
+ 98
+ 28
@@ -7587,8 +7614,8 @@ padding: 0px 5px;
0
0
- 280
- 557
+ 98
+ 28
@@ -7620,8 +7647,8 @@ padding: 0px 5px;
0
0
- 280
- 557
+ 98
+ 28
@@ -7735,8 +7762,8 @@ padding: 0px 5px;
0
0
- 1048
- 278
+ 100
+ 30
@@ -7843,7 +7870,7 @@ padding: 0px 5px;
-
-
+
0
@@ -8032,8 +8059,8 @@ padding: 0px 5px;
0
0
- 290
- 557
+ 98
+ 28
@@ -8065,8 +8092,8 @@ padding: 0px 5px;
0
0
- 100
- 30
+ 98
+ 28
@@ -8231,8 +8258,8 @@ padding: 0px 5px;
0
0
- 1016
- 83
+ 100
+ 30
@@ -8547,8 +8574,8 @@ padding: 0px 5px;
0
0
- 226
- 267
+ 100
+ 30
@@ -10233,7 +10260,7 @@ padding: 0px 5px;
0
0
- 439
+ 421
291
diff --git a/service.cpp b/service.cpp
index 7de2155..9512294 100644
--- a/service.cpp
+++ b/service.cpp
@@ -261,7 +261,7 @@ bool service::initDatabaseTables(QSqlDatabase db)
"CREATE TABLE IF NOT EXISTS magic_verify"
"(v_uid int(10) NOT NULL AUTO_INCREMENT,"
"vid int(10) NOT NUll,"
- "info varchar(64),"
+ "info varchar(256),"
"PRIMARY KEY (v_uid)"
")ENGINE=InnoDB;";
if (res)