Some display setting and logic
This commit is contained in:
3
.idea/misc.xml
generated
3
.idea/misc.xml
generated
@@ -4,4 +4,7 @@
|
|||||||
<component name="JavaScriptSettings">
|
<component name="JavaScriptSettings">
|
||||||
<option name="languageLevel" value="ES6" />
|
<option name="languageLevel" value="ES6" />
|
||||||
</component>
|
</component>
|
||||||
|
<component name="ProjectPlainTextFileTypeManager">
|
||||||
|
<file url="file://$PROJECT_DIR$/src/translations/zh_CN.ts" />
|
||||||
|
</component>
|
||||||
</project>
|
</project>
|
||||||
@@ -103,15 +103,6 @@ void DeviceManager::startScan(const char* json, bool empty) {
|
|||||||
static QString msg = "Start scan...";
|
static QString msg = "Start scan...";
|
||||||
AppGlobalValues::setInProcessing(true);
|
AppGlobalValues::setInProcessing(true);
|
||||||
TRIGGER_EVENT(GUIEvents::InvokeOperationStart, nullptr, (QObject*)&msg);
|
TRIGGER_EVENT(GUIEvents::InvokeOperationStart, nullptr, (QObject*)&msg);
|
||||||
qDebug() << "SetScanInfo>>>>>>>>>>>>>>>>>>>>";
|
|
||||||
AppGlobalValues::setEmptyScanFlag(empty);
|
|
||||||
int ret = SetScanInfo(json, empty ? 1 : 0);
|
|
||||||
if (ret) {
|
|
||||||
qDebug() << ">>>>>>>>>>>>>>>>>>>>SetScanInfo failed";
|
|
||||||
THROW_ERROR("Transfer patient information fail!")
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
qDebug() << ">>>>>>>>>>>>>>>>>>>>SetScanInfo success";
|
|
||||||
postScanCommand();
|
postScanCommand();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -188,24 +179,6 @@ void DeviceManager::prepareFinishScan() {
|
|||||||
// stop normal scan with prompt
|
// stop normal scan with prompt
|
||||||
TRIGGER_EVENT(InvokeOperationEnd, nullptr, (QObject *) &var);
|
TRIGGER_EVENT(InvokeOperationEnd, nullptr, (QObject *) &var);
|
||||||
AppGlobalValues::setInProcessing(false);
|
AppGlobalValues::setInProcessing(false);
|
||||||
|
|
||||||
// get output data path
|
|
||||||
QString outputPath = GetDeviceInfo(DEV_OUTPATH);
|
|
||||||
outputPath = outputPath.replace("\\", "/");
|
|
||||||
// get scan ID from path
|
|
||||||
if (outputPath.endsWith('/')) outputPath = outputPath.remove(outputPath.length() - 1, 1);
|
|
||||||
QStringList list = outputPath.split('/');
|
|
||||||
if (list.length()) {
|
|
||||||
if (AppGlobalValues::EmptyScanFlag().toBool()) {
|
|
||||||
ScanJson::Current()->setEmptyScanID(list.last().toStdString().c_str());
|
|
||||||
} else {
|
|
||||||
ScanJson::Current()->setScanID(list.last().toStdString().c_str());
|
|
||||||
}
|
|
||||||
// save json
|
|
||||||
ScanJson::Current()->save();
|
|
||||||
} else {
|
|
||||||
THROW_ERROR("Scan Output Path error!")
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DeviceManager::stopScan() {
|
void DeviceManager::stopScan() {
|
||||||
|
|||||||
Binary file not shown.
@@ -253,22 +253,22 @@
|
|||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>AdminSettingForm</name>
|
<name>SettingFormWidget</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>General</source>
|
<source>General</source>
|
||||||
<translation>通用</translation>
|
<translation>通用</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>Account</source>
|
<source>Account</source>
|
||||||
<translation>用户</translation>
|
<translation>账号</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>System</source>
|
<source>System</source>
|
||||||
<translation>系统</translation>
|
<translation>系统</translation>
|
||||||
</message>
|
</message>
|
||||||
@@ -297,8 +297,8 @@
|
|||||||
<translation type="vanished">操作日志</translation>
|
<translation type="vanished">操作日志</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>About</source>
|
<source>About</source>
|
||||||
<translation>关于</translation>
|
<translation>关于</translation>
|
||||||
</message>
|
</message>
|
||||||
@@ -426,6 +426,59 @@
|
|||||||
<translation>接受</translation>
|
<translation>接受</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>EditPatientDialog</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="35"/>
|
||||||
|
<source>Edit Patient</source>
|
||||||
|
<translation>修改患者信息</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="41"/>
|
||||||
|
<source>ID</source>
|
||||||
|
<translation></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="50"/>
|
||||||
|
<source>Name</source>
|
||||||
|
<translation>姓名</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="87"/>
|
||||||
|
<source>Birth Date</source>
|
||||||
|
<translation>出生日期</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="106"/>
|
||||||
|
<source>Comment</source>
|
||||||
|
<translation>备注</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="59"/>
|
||||||
|
<source>Gender</source>
|
||||||
|
<translation>性别</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="62"/>
|
||||||
|
<source>Female</source>
|
||||||
|
<translation>女</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="69"/>
|
||||||
|
<source>Male</source>
|
||||||
|
<translation>男</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="69"/>
|
||||||
|
<source>Cancel</source>
|
||||||
|
<translation>取消</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Accept</source>
|
||||||
|
<translation>接受</translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
|
|
||||||
<context>
|
<context>
|
||||||
<name>GUIFormBaseDialog</name>
|
<name>GUIFormBaseDialog</name>
|
||||||
<message>
|
<message>
|
||||||
@@ -561,29 +614,29 @@
|
|||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>LoginWindow</name>
|
<name>LoginDialog</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="54"/>
|
<location filename="../LoginDialog.cpp" line="54"/>
|
||||||
<source>U S C T</source>
|
<source>U S C T</source>
|
||||||
<translation></translation>
|
<translation></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="71"/>
|
<location filename="../LoginDialog.cpp" line="71"/>
|
||||||
<source>Username</source>
|
<source>Username</source>
|
||||||
<translation>用户名</translation>
|
<translation>用户名</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="78"/>
|
<location filename="../LoginDialog.cpp" line="78"/>
|
||||||
<source>Password</source>
|
<source>Password</source>
|
||||||
<translation>密码</translation>
|
<translation>密码</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="82"/>
|
<location filename="../LoginDialog.cpp" line="91"/>
|
||||||
<source>Login</source>
|
<source>Login</source>
|
||||||
<translation>登录</translation>
|
<translation>登录</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>login</source>
|
<source>Login</source>
|
||||||
<translation type="vanished">登录</translation>
|
<translation type="vanished">登录</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
|||||||
@@ -253,22 +253,22 @@
|
|||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>AdminSettingForm</name>
|
<name>SettingFormWidget</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>General</source>
|
<source>General</source>
|
||||||
<translation>通用</translation>
|
<translation>通用</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>Account</source>
|
<source>Account</source>
|
||||||
<translation>用户</translation>
|
<translation>账号</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>System</source>
|
<source>System</source>
|
||||||
<translation>系统</translation>
|
<translation>系统</translation>
|
||||||
</message>
|
</message>
|
||||||
@@ -297,8 +297,8 @@
|
|||||||
<translation type="vanished">操作日志</translation>
|
<translation type="vanished">操作日志</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../AdminSettingForm.cpp" line="32"/>
|
<location filename="../SettingFormWidget.cpp" line="32"/>
|
||||||
<location filename="../AdminSettingForm.cpp" line="82"/>
|
<location filename="../SettingFormWidget.cpp" line="82"/>
|
||||||
<source>About</source>
|
<source>About</source>
|
||||||
<translation>关于</translation>
|
<translation>关于</translation>
|
||||||
</message>
|
</message>
|
||||||
@@ -426,6 +426,59 @@
|
|||||||
<translation>接受</translation>
|
<translation>接受</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>EditPatientDialog</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="35"/>
|
||||||
|
<source>Edit Patient</source>
|
||||||
|
<translation>修改患者信息</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="41"/>
|
||||||
|
<source>ID</source>
|
||||||
|
<translation></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="50"/>
|
||||||
|
<source>Name</source>
|
||||||
|
<translation>姓名</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="87"/>
|
||||||
|
<source>Birth Date</source>
|
||||||
|
<translation>出生日期</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="106"/>
|
||||||
|
<source>Comment</source>
|
||||||
|
<translation>备注</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="59"/>
|
||||||
|
<source>Gender</source>
|
||||||
|
<translation>性别</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="62"/>
|
||||||
|
<source>Female</source>
|
||||||
|
<translation>女</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="69"/>
|
||||||
|
<source>Male</source>
|
||||||
|
<translation>男</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../dialogs/EditPatientDialog.cpp" line="69"/>
|
||||||
|
<source>Cancel</source>
|
||||||
|
<translation>取消</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Accept</source>
|
||||||
|
<translation>接受</translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
|
|
||||||
<context>
|
<context>
|
||||||
<name>GUIFormBaseDialog</name>
|
<name>GUIFormBaseDialog</name>
|
||||||
<message>
|
<message>
|
||||||
@@ -561,29 +614,29 @@
|
|||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>LoginWindow</name>
|
<name>LoginDialog</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="54"/>
|
<location filename="../LoginDialog.cpp" line="54"/>
|
||||||
<source>U S C T</source>
|
<source>U S C T</source>
|
||||||
<translation></translation>
|
<translation></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="71"/>
|
<location filename="../LoginDialog.cpp" line="71"/>
|
||||||
<source>Username</source>
|
<source>Username</source>
|
||||||
<translation>用户名</translation>
|
<translation>用户名</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="78"/>
|
<location filename="../LoginDialog.cpp" line="78"/>
|
||||||
<source>Password</source>
|
<source>Password</source>
|
||||||
<translation>密码</translation>
|
<translation>密码</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../loginwindow.cpp" line="82"/>
|
<location filename="../LoginDialog.cpp" line="91"/>
|
||||||
<source>Login</source>
|
<source>Login</source>
|
||||||
<translation>登录</translation>
|
<translation>登录</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>login</source>
|
<source>Login</source>
|
||||||
<translation type="vanished">登录</translation>
|
<translation type="vanished">登录</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
|||||||
@@ -107,16 +107,17 @@ void MainWindow::initializeTabWidget()
|
|||||||
mTabWidget->addTab(selectForm, tr("Select"));
|
mTabWidget->addTab(selectForm, tr("Select"));
|
||||||
auto scanForm = new ScanFormWidget(this);
|
auto scanForm = new ScanFormWidget(this);
|
||||||
mTabWidget->addTab(scanForm, tr("Scan"));
|
mTabWidget->addTab(scanForm, tr("Scan"));
|
||||||
auto verifyForm = new TabFormWidget(this);
|
// auto verifyForm = new TabFormWidget(this);
|
||||||
mTabWidget->addTab(verifyForm, tr("Verify"));
|
// mTabWidget->addTab(verifyForm, tr("Verify"));
|
||||||
|
|
||||||
mTabWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
mTabWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::reloadLanguage() {
|
void MainWindow::reloadLanguage() {
|
||||||
mTabWidget->setTabText(0, tr("Select"));
|
mTabWidget->setTabText(0, tr("Select"));
|
||||||
mTabWidget->setTabText(1, tr("Scan"));
|
mTabWidget->setTabText(1, tr("Scan"));
|
||||||
mTabWidget->setTabText(2, tr("Verify"));
|
// mTabWidget->setTabText(2, tr("Verify"));
|
||||||
mTabWidget->setTabText(3, tr("Settings"));
|
mTabWidget->setTabText(2, tr("Settings"));
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::switchToScanTab() { mTabWidget->setCurrentIndex(1); }
|
void MainWindow::switchToScanTab() { mTabWidget->setCurrentIndex(1); }
|
||||||
|
|||||||
Reference in New Issue
Block a user