Code clean, and code style error fix.

This commit is contained in:
Krad
2022-04-22 17:16:45 +08:00
parent 7cee364fc3
commit 27487fdf3c
21 changed files with 198 additions and 240 deletions

View File

@@ -11,13 +11,11 @@
#include <QUuid>
#include <QDate>
#include "db/SQLHelper.h"
#include "editpatientform.h"
#include "guimacros.h"
#include "event/EventCenter.h"
#include "src/dialogs/AccountFormDialog.h"
#include <QDebug>
#include "log/UserOperationLog.h"
#include <QSortFilterProxyModel>
#include "src/components/VerticalTextToolButton.h"
#include "dialogs/AlertDialog.h"
@@ -158,7 +156,7 @@ SelectFormWidget::SelectFormWidget(QWidget* parent) :
table->selectRow(0);
model->selectRow(0);
}
LOG_USER_OPERATION(AddPatient);
LOG_USER_OPERATION(AddPatient)
btnSelect->setEnabled(true);
});
@@ -208,11 +206,11 @@ SelectFormWidget::SelectFormWidget(QWidget* parent) :
//TODO:add some error handle logic
}
if (isAdd) {
LOG_USER_OPERATION(AddPatient);
LOG_USER_OPERATION(AddPatient)
}
else
{
LOG_USER_OPERATION(ChangePatientInfo);
LOG_USER_OPERATION(ChangePatientInfo)
}
btnSelect->setEnabled(true);
});
@@ -247,7 +245,7 @@ SelectFormWidget::SelectFormWidget(QWidget* parent) :
table->selectRow(0);
model->selectRow(0);
setPatientDetail(table, model, edit_patient);
LOG_USER_OPERATION(DeletePatient);
LOG_USER_OPERATION(DeletePatient)
}
} else {
//TODO:error handle
@@ -265,7 +263,7 @@ SelectFormWidget::SelectFormWidget(QWidget* parent) :
EventCenter::Default()->triggerEvent(GUIEvents::PatientSelected, nullptr, edit_patient->getPatientInformation()->Copy());
selectedPatientUID = edit_patient->getPatientInformation()->PatientUID;
LOG_USER_OPERATION(SelectPatient);
LOG_USER_OPERATION(SelectPatient)
});
// btn account slot

View File

@@ -7,13 +7,9 @@
#include <QStackedWidget>
#include <QStringListModel>
#include <QListWidget>
#include "src/forms/tabformwidget.h"
#include <QListWidgetItem>
#include "ui_tabformwidget.h"
#include <QLabel>
#include "UserOperationLogForm.h"
#include "generalform.h"
#include <QPushButton>
#include "systemsettingform.h"
#include "AccountTableForm.h"
#include "event/EventCenter.h"
@@ -57,20 +53,6 @@ AdminSettingForm::AdminSettingForm(QWidget* parent, Qt::WindowFlags f) : TabForm
systemSettingForm* systemSetting = new systemSettingForm(this);
stackedWidget->addWidget(systemSetting);
//QLabel* systemSetting = new QLabel(this);
//systemSetting->setText("systemSetting");
//stackedWidget->addWidget(systemSetting);
//QLabel* Info = new QLabel(this);
//Info->setText("info");
//stackedWidget->addWidget(Info);
//UserOperationLogForm* operationLogForm = new UserOperationLogForm(this);
//stackedWidget->addWidget(operationLogForm);
//QLabel* about = new QLabel(this);
//about->setText(tr("About"));
AboutWidget* about = new AboutWidget(this);
stackedWidget->addWidget(about);

View File

@@ -71,16 +71,16 @@ GeneralForm::GeneralForm(QWidget* parent) : QWidget(parent)
lockTime->setText(JsonObject::Instance()->lockScreenTimeout());
//connection
connect(instName, &QLineEdit::textChanged, [=](QString str)
connect(instName, &QLineEdit::textChanged, [=](const QString& str)
{
JsonObject::Instance()->setInstitutionName(str);
});
connect(instAddr, &QLineEdit::textChanged, [=](QString str)
connect(instAddr, &QLineEdit::textChanged, [=](const QString& str)
{
JsonObject::Instance()->setInstitutionAddr(str);
});
connect(lockTime, &QLineEdit::textChanged, [=](QString str)
connect(lockTime, &QLineEdit::textChanged, [=](const QString& str)
{
//take effect
JsonObject::Instance()->setLockScreenTimeout(str);

View File

@@ -2,16 +2,11 @@
#include "ui_systemsettingform.h"
#include <QPushButton>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QDebug>
#include <QLabel>
#include <QLineEdit>
#include <QEvent>
#include <QToolButton>
#include "src/dialogs/SelectDialog.h"
#include "components/imageswitch.h"
#include "network/networkcfgdialog.h"
#include "network/dicomcfgdialog.h"
#include "network/getadminpsw.h"
@@ -20,7 +15,6 @@
#include "event/EventCenter.h"
#include "device/DeviceManager.h"
#include "json/cmdhelper.h"
#include "appvals/AppGlobalValues.h"
systemSettingForm::systemSettingForm(QWidget* parent) :
QWidget(parent),