Commit fa41bb40d6beb9ee34f40b9e23bd91c7236dcbb3

Authored by 고영탁
1 parent d20f8d98a6
Exists in master and in 2 other branches fhd, fhd-demo

HACCP 데이터 파일 다운로드 기능 추가

 - HACCP 데이터 다운로드 다이얼로그 추가
 - HACCP 데이터 다운로드 쓰레드 기능 추가
app/gui/oven_control/config.cpp
... ... @@ -28,6 +28,7 @@
28 28 #include "system.h"
29 29 #include "unistd.h"
30 30 #include "configdemomodedlg.h"
  31 +#include "haccpdownloaddlg.h"
31 32 #include <QFontDatabase>
32 33  
33 34 using namespace Define;
... ... @@ -566,6 +567,8 @@ void Config::execConfigWindow(QWidget *parent, Define::ConfigType idx){
566 567 dlg=new ConfigIpDlg(parent);
567 568 break;
568 569 case config_haccp_data_download:
  570 + dlg = new HaccpDownloadDlg(parent);
  571 + break;
569 572 case config_info_data_download:
570 573 case config_service_data_download:
571 574 case config_program_download:
... ...
app/gui/oven_control/configwindow.h
... ... @@ -32,12 +32,12 @@ class ConfigWindow : public QMainWindow
32 32  
33 33 private:
34 34 const uint16_t m_arrMaxMenuCount[7] ={
35   - 6,8,8,2,3,0,6
  35 + 6,8,9,2,3,0,6
36 36 };
37 37 const Define::ConfigType m_arrConfigListInfos[7][20] = {
38 38 {config_language,config_datetime, config_temptype,config_backlight, config_time_type,config_resttime_format,},
39 39 {config_marster_vol,config_keypad_sound1,config_keypad_sound2,config_request_loadexec,config_programstep_finish,config_cooktime_finish,config_stoperror_distinguish,config_sound_factory_reset},
40   - {config_info_data_download,config_service_data_download,config_program_download,config_program_upload ,config_program_initialize,config_ip,config_set_download,config_set_upload},
  40 + {config_haccp_data_download, config_info_data_download,config_service_data_download,config_program_download,config_program_upload ,config_program_initialize,config_ip,config_set_download,config_set_upload},
41 41 {config_set_half_energy,config_set_auto_darkness,},
42 42 {config_duty_wash,config_loading_door_monitoring,config_cooking_door_monitoring},
43 43 {config_invalid,},
... ...
app/gui/oven_control/fileprocessdlg.cpp
... ... @@ -18,7 +18,7 @@
18 18  
19 19  
20 20 ProgramCopyWorker::ProgramCopyWorker(){
21   - m_bStop = false;
  21 +
22 22 }
23 23  
24 24  
... ... @@ -236,13 +236,55 @@ void ProgramCopyWorker::addSrcFile(QString strfilename){
236 236 m_arrSrcFileList.append(strfilename);
237 237 }
238 238  
239   -void ProgramCopyWorker::workerStop(){
240   - //QMutexLocker locker(&m_mutex);
241   - // qDebug() << "stop thread";
242   - m_bStop = true;
  239 +
  240 +
  241 +
  242 +void ProgramCopyWorker::haccpDownloadMain()
  243 +{
  244 + int nDateTotalCount = m_dtStart.daysTo(m_dtEnd)+1;
  245 + int nDateCpltCount=0;
  246 + int year, mon, day;
  247 + QProcess process;
  248 +
  249 + qDebug() << __func__;
  250 + if(nDateTotalCount <= 0){
  251 + qDebug() << "total date" << nDateTotalCount;
  252 + emit progressed(100,0);
  253 + emit finished();
  254 + return;
  255 + }
  256 +
  257 + for(QDate dt = m_dtStart; dt <= m_dtEnd; dt=dt.addDays(1)){
  258 + year = dt.year(); mon = dt.month(); day=dt.day();
  259 + QString path = QString("/prime/haccp/%1/%2/%3/").arg(year,2,10,QLatin1Char('4')).arg(mon, 2,10,QLatin1Char('0')).arg(day,2,10,QLatin1Char('0'));
  260 + QDir dir(path);
  261 + QString cmd = QString("sh -c \"zip -P primeov980308 -r %1/%2%3%4.zip *\"").arg(m_strDestDir).arg(year,2,10,QLatin1Char('4')).arg(mon, 2,10,QLatin1Char('0')).arg(day,2,10,QLatin1Char('0'));
  262 +
  263 + if(dir.exists()){
  264 + qDebug() << "path is " << path<< "cmd is "<< cmd;
  265 + process.setWorkingDirectory(path);
  266 + process.start(cmd);
  267 + if(!process.waitForFinished(30000)){
  268 + qDebug() << "zip failed";
  269 + }
  270 + process.start("sync");
  271 + process.waitForFinished();
  272 + nDateCpltCount++;
  273 + emit progressed(nDateCpltCount*100/nDateTotalCount , nDateTotalCount - nDateCpltCount);
  274 + QThread::currentThread()->msleep(300);
  275 + }
  276 + else {
  277 + nDateCpltCount++;
  278 + emit progressed( nDateCpltCount*100/nDateTotalCount , nDateTotalCount - nDateCpltCount);
  279 + QThread::currentThread()->msleep(500);
  280 + }
  281 + }
  282 + sync();
  283 + emit finished();
243 284 }
244 285  
245 286  
  287 +
246 288 FileProcessDlg::FileProcessDlg(QWidget *parent, ConfigType type, bool isDown) :
247 289 QDialog(parent),
248 290 ui(new Ui::FileProcessDlg)
... ... @@ -261,12 +303,15 @@ FileProcessDlg::FileProcessDlg(QWidget *parent, ConfigType type, bool isDown) :
261 303 ui->ctrWjProcess->setMinimum(0);
262 304 ui->ctrWjProcess->setMaximum(100);
263 305  
  306 +
264 307 if(isDown){
265 308 QPixmap pxmap;
266 309 pxmap.load(":/images/config/102_usb_upload_icon.png");
267 310 ui->label_2->setPixmap(pxmap);
268 311 }
269 312  
  313 +
  314 +
270 315 switch(type){
271 316 case config_haccp_data_download:
272 317 QTimer::singleShot(100,this,SLOT(haccpdataDownload()));
... ... @@ -298,6 +343,34 @@ FileProcessDlg::FileProcessDlg(QWidget *parent, ConfigType type, bool isDown) :
298 343 }
299 344 }
300 345  
  346 +FileProcessDlg::FileProcessDlg(QDate startdt, QDate enddt, QWidget *parent):
  347 + QDialog(parent),
  348 + ui(new Ui::FileProcessDlg)
  349 +{
  350 + ui->setupUi(this);
  351 + setAttribute(Qt::WA_DeleteOnClose);
  352 + setAttribute(Qt::WA_TranslucentBackground);
  353 + setWindowFlags(Qt::FramelessWindowHint);
  354 + qApp->setActiveWindow(this);
  355 + this->setFocus();
  356 + ui->ctrBtnCancel->setFocus();
  357 +
  358 + m_bRst = true;
  359 + m_nCfgtype = config_haccp_data_download;
  360 +
  361 + ui->ctrWjProcess->setMinimum(0);
  362 + ui->ctrWjProcess->setMaximum(100);
  363 +
  364 + m_dtStart = startdt;
  365 + m_dtEnd = enddt;
  366 +
  367 + QPixmap pxmap;
  368 + pxmap.load(":/images/config/102_usb_upload_icon.png");
  369 + ui->label_2->setPixmap(pxmap);
  370 +
  371 + QTimer::singleShot(100,this,SLOT(haccpdataDownload()));
  372 +}
  373 +
301 374 FileProcessDlg::~FileProcessDlg()
302 375 {
303 376 delete ui;
... ... @@ -306,7 +379,6 @@ FileProcessDlg::~FileProcessDlg()
306 379 void FileProcessDlg::on_ctrBtnCancel_clicked()
307 380 {
308 381  
309   - //emit stopcopy();
310 382 programCopyThd.requestInterruption();
311 383 //close();
312 384 }
... ... @@ -574,10 +646,8 @@ void FileProcessDlg::programDownload(){
574 646 connect(&programCopyThd,SIGNAL(started()), &worker, SLOT(workerMain()));
575 647 connect(&worker, SIGNAL(progressed(int,int)), this, SLOT(onProgressed(int,int)));
576 648 connect(&worker, SIGNAL(errorFired(QString)), this, SLOT(onErrorFired(QString)));
577   - connect(this, SIGNAL(stopcopy()), &worker, SLOT(workerStop()));
578 649 connect(&worker, SIGNAL(finished()), &programCopyThd,SLOT(quit()));
579 650 connect(&programCopyThd, SIGNAL(finished()), this, SLOT(onProgressFinished()));
580   - //connect(ui->ctrBtnCancel, SIGNAL(clicked(bool)), &worker, SLOT(workerStop()));
581 651  
582 652 programCopyThd.start();
583 653 qDebug() << "thread start";
... ... @@ -665,6 +735,7 @@ void FileProcessDlg::onErrorFired(QString Desc)
665 735 void FileProcessDlg::onProgressed(int progress, int sec){
666 736 int min, _sec;
667 737 QString strTemp;
  738 + qDebug() << __func__<< progress << sec;
668 739 ui->ctrWjProcess->setValue(progress);
669 740 min = sec/60;
670 741 _sec = sec%60;
... ... @@ -673,9 +744,11 @@ void FileProcessDlg::onProgressed(int progress, int sec){
673 744 ui->ctrLbRemainTime->setText(strTemp);
674 745 }
675 746 else{
676   - strTemp = tr("남은 예상 시간 : %1초").arg(_sec);
  747 + strTemp = QString(tr("남은 예상 시간 : %1초")).arg(_sec);
  748 + qDebug() << strTemp;
677 749 ui->ctrLbRemainTime->setText(strTemp);
678 750 }
  751 + update();
679 752 }
680 753  
681 754 void FileProcessDlg::programUpload(){
... ... @@ -704,10 +777,8 @@ void FileProcessDlg::programUpload(){
704 777 connect(&programCopyThd,SIGNAL(started()), &worker, SLOT(workerMain()));
705 778 connect(&worker, SIGNAL(progressed(int,int)), this, SLOT(onProgressed(int,int)));
706 779 connect(&worker,SIGNAL(errorFired(QString)),this,SLOT(onErrorFired(QString)));
707   - connect(this, SIGNAL(stopcopy()), &worker, SLOT(workerStop()));
708 780 connect(&worker, SIGNAL(finished()), &programCopyThd,SLOT(quit()));
709 781 connect(&programCopyThd, SIGNAL(finished()), this, SLOT(onProgressFinished()));
710   - //connect(ui->ctrBtnCancel, SIGNAL(clicked(bool)), &worker, SLOT(workerStop()));
711 782  
712 783 programCopyThd.start();
713 784 qDebug() << "thread start";
... ... @@ -816,9 +887,37 @@ void FileProcessDlg::configUpload(){
816 887 }
817 888  
818 889 void FileProcessDlg::haccpdataDownload(){
819   - ui->ctrWjProcess->setValue(100);
820   - ui->ctrLbRemainTime->setText(tr("남은 예상 시간 : 완료"));
821   - QTimer::singleShot(1000,this,SLOT(close()));
  890 + QString strSrcPath;
  891 +
  892 + if(FileProcessor::detectUSB(strSrcPath)){
  893 + strSrcPath = QString("%1/prime/haccp").arg(strSrcPath);
  894 + QDir dir(strSrcPath);
  895 + if(dir.exists()){
  896 + qDebug() << "remove dirs " << strSrcPath;
  897 + dir.removeRecursively();
  898 + sync();
  899 + sleep(1);
  900 + }
  901 + qDebug() << "src paht is " << strSrcPath;
  902 + dir.mkpath(strSrcPath);
  903 + sync();
  904 + worker.setDestPath(strSrcPath);
  905 + worker.setStartDate(m_dtStart);
  906 + worker.setEndDate(m_dtEnd);
  907 + worker.moveToThread(&programCopyThd);
  908 +
  909 + connect(&programCopyThd,SIGNAL(started()), &worker, SLOT(haccpDownloadMain()));
  910 + connect(&worker, SIGNAL(progressed(int,int)), this, SLOT(onProgressed(int,int)));
  911 + connect(&worker,SIGNAL(errorFired(QString)),this,SLOT(onErrorFired(QString)));
  912 + connect(&worker, SIGNAL(finished()), &programCopyThd,SLOT(quit()));
  913 + connect(&programCopyThd, SIGNAL(finished()), this, SLOT(onProgressFinished()));
  914 +
  915 + programCopyThd.start();
  916 + }
  917 + else{
  918 + ui->ctrLbRemainTime->setText(tr("USB 인식을 실패하였습니다."));
  919 + QTimer::singleShot(1000,this,SLOT(close()));
  920 + }
822 921 }
823 922  
824 923 void FileProcessDlg::standardInfoUpload()
... ...
app/gui/oven_control/fileprocessdlg.h
... ... @@ -8,6 +8,7 @@
8 8 #include <QList>
9 9 #include <QMutex>
10 10 #include <QKeyEvent>
  11 +#include <QDate>
11 12 #include "config.h"
12 13 #include "servicedata.h"
13 14 #include "historylistwindow.h"
... ... @@ -26,17 +27,22 @@ class ProgramCopyWorker : public QObject{
26 27 QList<QString> m_arrSrcDirList;
27 28 QMutex m_mutex;
28 29 bool m_bStop;
  30 + QDate m_dtStart;
  31 + QDate m_dtEnd;
  32 +
29 33 public:
30 34 explicit ProgramCopyWorker(QString strDest);
31 35 explicit ProgramCopyWorker();
32 36 void setDestPath(QString strDest);
33 37 void addSrcFile(QString strfilename);
34 38 void addSrcDir(QString strDirPath);
  39 + void setStartDate(QDate &dt){m_dtStart = dt;}
  40 + void setEndDate(QDate &dt){m_dtEnd = dt;}
35 41  
36 42  
37 43 public slots:
38 44 void workerMain();
39   - void workerStop();
  45 + void haccpDownloadMain();
40 46  
41 47 signals:
42 48 void finished();
... ... @@ -52,6 +58,7 @@ class FileProcessDlg : public QDialog
52 58  
53 59 public:
54 60 explicit FileProcessDlg(QWidget *parent = 0, ConfigType type = config_invalid, bool isDown = true);
  61 + explicit FileProcessDlg(QDate startdt, QDate enddt, QWidget *parent = 0);
55 62 ~FileProcessDlg();
56 63  
57 64 private slots:
... ... @@ -66,7 +73,6 @@ private slots:
66 73 void standardInfoUpload();
67 74  
68 75 signals:
69   - void stopcopy();
70 76  
71 77 public slots:
72 78 void onProgressed(int progress,int sec);
... ... @@ -82,6 +88,8 @@ private:
82 88 ConfigType m_nCfgtype;
83 89 QThread programCopyThd;
84 90 ProgramCopyWorker worker;
  91 + QDate m_dtStart;
  92 + QDate m_dtEnd;
85 93 bool m_bRst;
86 94 };
87 95  
... ...
app/gui/oven_control/haccpdownloaddlg.cpp
... ... @@ -0,0 +1,144 @@
  1 +#include <QSignalMapper>
  2 +#include <QDate>
  3 +#include <QKeyEvent>
  4 +#include <QDebug>
  5 +#include "haccpdownloaddlg.h"
  6 +#include "ui_haccpdownloaddlg.h"
  7 +#include "soundplayer.h"
  8 +#include "fileprocessdlg.h"
  9 +#include "config.h"
  10 +
  11 +HaccpDownloadDlg::HaccpDownloadDlg(QWidget *parent) :
  12 + QDialog(parent),
  13 + ui(new Ui::HaccpDownloadDlg)
  14 +{
  15 + ui->setupUi(this);
  16 + this->setWindowFlags(Qt::FramelessWindowHint);
  17 + setAttribute(Qt::WA_DeleteOnClose);
  18 + qApp->setActiveWindow(this);
  19 + this->setFocus();
  20 +
  21 + foreach (QPushButton *button, findChildren<QPushButton *>())
  22 + connect(button, &QPushButton::pressed, SoundPlayer::playClick);
  23 +
  24 + ui->ctrSpBxYearStart->setFormatterWidth(4);
  25 + ui->ctrSpBxYearEnd->setFormatterWidth(4);
  26 + QDate date = QDate::currentDate();
  27 + ui->ctrSpBxDayEnd->setValue(date.day());
  28 + ui->ctrSpBxDayStart->setValue(date.day());
  29 + ui->ctrSpBxMonthEnd->setValue(date.month());
  30 + ui->ctrSpBxMonthStart->setValue(date.month());
  31 + ui->ctrSpBxYearStart->setValue(date.year());
  32 + ui->ctrSpBxYearEnd->setValue(date.year());
  33 +
  34 + ui->ctrSpBxYearStart->setFocus();
  35 +
  36 +
  37 +
  38 + connect(ui->keyboardwidget, SIGNAL(onOkKeyClicked()), this, SLOT(keyEnter_clicked()));
  39 + connect(ui->keyboardwidget, SIGNAL(onCancelKeyClicked()), this, SLOT(keyCancel_clicked()));
  40 +
  41 + QSignalMapper* mapper = new QSignalMapper(this);
  42 + mapper->setMapping(ui->ctrSpBxYearStart, ui->ctrSpBxYearStart);
  43 + mapper->setMapping(ui->ctrSpBxYearEnd, ui->ctrSpBxYearEnd);
  44 + mapper->setMapping(ui->ctrSpBxMonthStart, ui->ctrSpBxMonthStart);
  45 + mapper->setMapping(ui->ctrSpBxMonthEnd, ui->ctrSpBxMonthEnd);
  46 + mapper->setMapping(ui->ctrSpBxDayStart, ui->ctrSpBxDayStart);
  47 +
  48 + connect(ui->ctrSpBxDayEnd, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  49 + connect(ui->ctrSpBxDayStart, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  50 + connect(ui->ctrSpBxMonthEnd, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  51 + connect(ui->ctrSpBxMonthStart, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  52 + connect(ui->ctrSpBxYearStart, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  53 + connect(ui->ctrSpBxYearEnd, SIGNAL(focusInEdit()), mapper,SLOT(map()));
  54 +
  55 + connect(mapper, SIGNAL(mapped(QWidget*)), this, SLOT(focusInSpinBox(QWidget*)));
  56 +
  57 +
  58 +}
  59 +
  60 +HaccpDownloadDlg::~HaccpDownloadDlg()
  61 +{
  62 + delete ui;
  63 +}
  64 +
  65 +void HaccpDownloadDlg::on_ctrBtnCancel_clicked()
  66 +{
  67 + deleteLater();
  68 +}
  69 +
  70 +void HaccpDownloadDlg::on_ctrBtnOk_clicked()
  71 +{
  72 + FileProcessDlg* dlg = new FileProcessDlg(QDate(ui->ctrSpBxYearStart->value(), ui->ctrSpBxMonthStart->value(), ui->ctrSpBxDayStart->value()),
  73 + QDate(ui->ctrSpBxYearEnd->value(),ui->ctrSpBxMonthEnd->value(), ui->ctrSpBxDayEnd->value()),
  74 + this);
  75 + connect(dlg, SIGNAL(destroyed(QObject*)), SLOT(deleteLater()));
  76 + dlg->setWindowModality(Qt::WindowModal);
  77 + dlg->show();
  78 + dlg->exec();
  79 +}
  80 +
  81 +void HaccpDownloadDlg::keyCancel_clicked()
  82 +{
  83 + QSpinBox *spbx = qobject_cast<QSpinBox*>(focusWidget());
  84 + if(spbx != NULL){
  85 + spbx->setValue(m_nFocusValue);
  86 + }
  87 + ui->keyboardwidget->focusOutKeyboard();
  88 +}
  89 +
  90 +void HaccpDownloadDlg::keyEnter_clicked(){
  91 + ui->keyboardwidget->focusOutKeyboard();
  92 +}
  93 +
  94 +
  95 +void HaccpDownloadDlg::focusInSpinBox(QWidget *widget){
  96 + QSpinBox *spbx = qobject_cast<QSpinBox*>(widget);
  97 + if(spbx != NULL){
  98 + m_nFocusValue = spbx->value();
  99 + }
  100 +}
  101 +
  102 +void HaccpDownloadDlg::keyReleaseEvent(QKeyEvent *event)
  103 +{
  104 + switch (event->key())
  105 + {
  106 + case 0x01000032: // Turn left
  107 + if(focusWidget() == ui->ctrSpBxYearStart) ui->ctrBtnCancel->setFocus();
  108 + else focusPreviousChild();
  109 + break;
  110 + case 0x01000031: // Push
  111 + {
  112 + QPushButton *btn = qobject_cast<QPushButton*>(focusWidget());
  113 + if(btn != NULL){
  114 + btn->click();
  115 + }
  116 + else{
  117 + QSpinBox *spbx = qobject_cast<QSpinBox*>(focusWidget());
  118 + qDebug() << "grab keyboard";
  119 + if(spbx != NULL) ui->keyboardwidget->focusInKeyboard();
  120 + }
  121 + break;
  122 + }
  123 + case 0x01000030: // Turn right
  124 + if(focusWidget() == ui->ctrBtnCancel) ui->ctrSpBxYearStart->setFocus();
  125 + else focusNextChild();
  126 + break;
  127 + }
  128 +}
  129 +
  130 +void HaccpDownloadDlg::keyPressEvent(QKeyEvent *event){
  131 + switch (event->key())
  132 + {
  133 + case 0x01000032: // Turn left
  134 + if(focusWidget() == ui->ctrSpBxYearStart) ui->ctrBtnCancel->setFocus();
  135 + else focusPreviousChild();
  136 + break;
  137 + case 0x01000031: // Push
  138 + break;
  139 + case 0x01000030: // Turn right
  140 + if(focusWidget() == ui->ctrBtnCancel) ui->ctrSpBxYearStart->setFocus();
  141 + else focusNextChild();
  142 + break;
  143 + }
  144 +}
... ...
app/gui/oven_control/haccpdownloaddlg.h
... ... @@ -0,0 +1,37 @@
  1 +#ifndef HACCPDOWNLOADDLG_H
  2 +#define HACCPDOWNLOADDLG_H
  3 +
  4 +#include <QDialog>
  5 +
  6 +namespace Ui {
  7 +class HaccpDownloadDlg;
  8 +}
  9 +
  10 +class HaccpDownloadDlg : public QDialog
  11 +{
  12 + Q_OBJECT
  13 +
  14 +public:
  15 + explicit HaccpDownloadDlg(QWidget *parent = 0);
  16 + ~HaccpDownloadDlg();
  17 +
  18 +private slots:
  19 + void on_ctrBtnCancel_clicked();
  20 +
  21 + void on_ctrBtnOk_clicked();
  22 +
  23 + void keyCancel_clicked();
  24 + void keyEnter_clicked();
  25 +
  26 + void focusInSpinBox(QWidget *widget);
  27 +
  28 +protected:
  29 + void keyReleaseEvent(QKeyEvent* event);
  30 + void keyPressEvent(QKeyEvent* event);
  31 +
  32 +private:
  33 + Ui::HaccpDownloadDlg *ui;
  34 + int m_nFocusValue;
  35 +};
  36 +
  37 +#endif // HACCPDOWNLOADDLG_H
... ...
app/gui/oven_control/haccpdownloaddlg.ui
... ... @@ -0,0 +1,609 @@
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<ui version="4.0">
  3 + <class>HaccpDownloadDlg</class>
  4 + <widget class="QDialog" name="HaccpDownloadDlg">
  5 + <property name="geometry">
  6 + <rect>
  7 + <x>0</x>
  8 + <y>0</y>
  9 + <width>900</width>
  10 + <height>1600</height>
  11 + </rect>
  12 + </property>
  13 + <property name="styleSheet">
  14 + <string notr="true">#ConfigDateTimeDlg{
  15 + /*background-color : transparent;*/
  16 +}
  17 +
  18 +#centralwidget{
  19 + background-image : url(:/images/background/popup/913.png);
  20 +}
  21 +
  22 +QLabel {
  23 + color : white;
  24 +}
  25 +QLineEdit{
  26 + background-color : transparent;
  27 + color : white;
  28 +}
  29 +
  30 +QSpinBox{
  31 + background-color : transparent;
  32 + color : white;
  33 +}
  34 +
  35 +QPushButton{
  36 + border-color : transparent;
  37 + background-color : transparent;
  38 + color : white;
  39 +}
  40 +QPushButton::pressed, QPushButton::focus{
  41 + color : yellow;
  42 +}</string>
  43 + </property>
  44 + <widget class="QWidget" name="centralwidget" native="true">
  45 + <property name="geometry">
  46 + <rect>
  47 + <x>0</x>
  48 + <y>425</y>
  49 + <width>900</width>
  50 + <height>1025</height>
  51 + </rect>
  52 + </property>
  53 + <widget class="QWidget" name="verticalLayoutWidget">
  54 + <property name="geometry">
  55 + <rect>
  56 + <x>0</x>
  57 + <y>0</y>
  58 + <width>901</width>
  59 + <height>421</height>
  60 + </rect>
  61 + </property>
  62 + <layout class="QVBoxLayout" name="verticalLayout" stretch="10,10,10,10,8">
  63 + <property name="spacing">
  64 + <number>10</number>
  65 + </property>
  66 + <property name="sizeConstraint">
  67 + <enum>QLayout::SetDefaultConstraint</enum>
  68 + </property>
  69 + <item>
  70 + <widget class="QLabel" name="label">
  71 + <property name="maximumSize">
  72 + <size>
  73 + <width>16777215</width>
  74 + <height>94</height>
  75 + </size>
  76 + </property>
  77 + <property name="font">
  78 + <font>
  79 + <family>나눔고딕</family>
  80 + <pointsize>18</pointsize>
  81 + <weight>75</weight>
  82 + <bold>true</bold>
  83 + </font>
  84 + </property>
  85 + <property name="styleSheet">
  86 + <string notr="true">color : white;</string>
  87 + </property>
  88 + <property name="text">
  89 + <string>HACCP 데이터 다운로드</string>
  90 + </property>
  91 + <property name="alignment">
  92 + <set>Qt::AlignCenter</set>
  93 + </property>
  94 + </widget>
  95 + </item>
  96 + <item>
  97 + <widget class="Line" name="line">
  98 + <property name="styleSheet">
  99 + <string notr="true">color: rgb(255, 255, 255);</string>
  100 + </property>
  101 + <property name="orientation">
  102 + <enum>Qt::Horizontal</enum>
  103 + </property>
  104 + </widget>
  105 + </item>
  106 + <item>
  107 + <layout class="QHBoxLayout" name="horizontalLayout_2" stretch="0,0,1,0,1,0,1">
  108 + <property name="spacing">
  109 + <number>15</number>
  110 + </property>
  111 + <property name="leftMargin">
  112 + <number>150</number>
  113 + </property>
  114 + <property name="rightMargin">
  115 + <number>150</number>
  116 + </property>
  117 + <item>
  118 + <widget class="QLabel" name="label_8">
  119 + <property name="font">
  120 + <font>
  121 + <family>나눔고딕</family>
  122 + <pointsize>18</pointsize>
  123 + <weight>75</weight>
  124 + <bold>true</bold>
  125 + </font>
  126 + </property>
  127 + <property name="text">
  128 + <string/>
  129 + </property>
  130 + <property name="pixmap">
  131 + <pixmap resource="resources.qrc">:/images/symbol/up_date.png</pixmap>
  132 + </property>
  133 + </widget>
  134 + </item>
  135 + <item>
  136 + <widget class="FormatterSpinBox" name="ctrSpBxYearStart">
  137 + <property name="sizePolicy">
  138 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  139 + <horstretch>0</horstretch>
  140 + <verstretch>0</verstretch>
  141 + </sizepolicy>
  142 + </property>
  143 + <property name="font">
  144 + <font>
  145 + <family>나눔고딕</family>
  146 + <pointsize>18</pointsize>
  147 + <underline>true</underline>
  148 + </font>
  149 + </property>
  150 + <property name="focusPolicy">
  151 + <enum>Qt::StrongFocus</enum>
  152 + </property>
  153 + <property name="frame">
  154 + <bool>false</bool>
  155 + </property>
  156 + <property name="alignment">
  157 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  158 + </property>
  159 + <property name="buttonSymbols">
  160 + <enum>QAbstractSpinBox::NoButtons</enum>
  161 + </property>
  162 + <property name="minimum">
  163 + <number>2000</number>
  164 + </property>
  165 + <property name="maximum">
  166 + <number>2100</number>
  167 + </property>
  168 + <property name="value">
  169 + <number>2000</number>
  170 + </property>
  171 + </widget>
  172 + </item>
  173 + <item>
  174 + <widget class="QLabel" name="label_2">
  175 + <property name="font">
  176 + <font>
  177 + <family>나눔고딕</family>
  178 + <pointsize>18</pointsize>
  179 + <weight>75</weight>
  180 + <bold>true</bold>
  181 + </font>
  182 + </property>
  183 + <property name="text">
  184 + <string>년</string>
  185 + </property>
  186 + </widget>
  187 + </item>
  188 + <item>
  189 + <widget class="FormatterSpinBox" name="ctrSpBxMonthStart">
  190 + <property name="sizePolicy">
  191 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  192 + <horstretch>0</horstretch>
  193 + <verstretch>0</verstretch>
  194 + </sizepolicy>
  195 + </property>
  196 + <property name="font">
  197 + <font>
  198 + <family>나눔고딕</family>
  199 + <pointsize>18</pointsize>
  200 + <underline>true</underline>
  201 + </font>
  202 + </property>
  203 + <property name="focusPolicy">
  204 + <enum>Qt::StrongFocus</enum>
  205 + </property>
  206 + <property name="frame">
  207 + <bool>false</bool>
  208 + </property>
  209 + <property name="alignment">
  210 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  211 + </property>
  212 + <property name="buttonSymbols">
  213 + <enum>QAbstractSpinBox::NoButtons</enum>
  214 + </property>
  215 + <property name="minimum">
  216 + <number>1</number>
  217 + </property>
  218 + <property name="maximum">
  219 + <number>12</number>
  220 + </property>
  221 + <property name="value">
  222 + <number>12</number>
  223 + </property>
  224 + </widget>
  225 + </item>
  226 + <item>
  227 + <widget class="QLabel" name="label_4">
  228 + <property name="font">
  229 + <font>
  230 + <family>나눔고딕</family>
  231 + <pointsize>18</pointsize>
  232 + <weight>75</weight>
  233 + <bold>true</bold>
  234 + </font>
  235 + </property>
  236 + <property name="text">
  237 + <string>월</string>
  238 + </property>
  239 + </widget>
  240 + </item>
  241 + <item>
  242 + <widget class="FormatterSpinBox" name="ctrSpBxDayStart">
  243 + <property name="sizePolicy">
  244 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  245 + <horstretch>0</horstretch>
  246 + <verstretch>0</verstretch>
  247 + </sizepolicy>
  248 + </property>
  249 + <property name="font">
  250 + <font>
  251 + <family>나눔고딕</family>
  252 + <pointsize>18</pointsize>
  253 + <underline>true</underline>
  254 + </font>
  255 + </property>
  256 + <property name="focusPolicy">
  257 + <enum>Qt::StrongFocus</enum>
  258 + </property>
  259 + <property name="frame">
  260 + <bool>false</bool>
  261 + </property>
  262 + <property name="alignment">
  263 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  264 + </property>
  265 + <property name="buttonSymbols">
  266 + <enum>QAbstractSpinBox::NoButtons</enum>
  267 + </property>
  268 + <property name="minimum">
  269 + <number>1</number>
  270 + </property>
  271 + <property name="maximum">
  272 + <number>31</number>
  273 + </property>
  274 + <property name="value">
  275 + <number>1</number>
  276 + </property>
  277 + </widget>
  278 + </item>
  279 + <item>
  280 + <widget class="QLabel" name="label_3">
  281 + <property name="font">
  282 + <font>
  283 + <family>나눔고딕</family>
  284 + <pointsize>18</pointsize>
  285 + <weight>75</weight>
  286 + <bold>true</bold>
  287 + </font>
  288 + </property>
  289 + <property name="text">
  290 + <string>일</string>
  291 + </property>
  292 + </widget>
  293 + </item>
  294 + </layout>
  295 + </item>
  296 + <item>
  297 + <layout class="QHBoxLayout" name="horizontalLayout_3" stretch="0,0,1,0,1,0,1">
  298 + <property name="spacing">
  299 + <number>15</number>
  300 + </property>
  301 + <property name="leftMargin">
  302 + <number>150</number>
  303 + </property>
  304 + <property name="rightMargin">
  305 + <number>150</number>
  306 + </property>
  307 + <item>
  308 + <widget class="QLabel" name="label_9">
  309 + <property name="font">
  310 + <font>
  311 + <family>나눔고딕</family>
  312 + <pointsize>18</pointsize>
  313 + <weight>75</weight>
  314 + <bold>true</bold>
  315 + </font>
  316 + </property>
  317 + <property name="text">
  318 + <string/>
  319 + </property>
  320 + <property name="pixmap">
  321 + <pixmap resource="resources.qrc">:/images/symbol/down_date.png</pixmap>
  322 + </property>
  323 + </widget>
  324 + </item>
  325 + <item>
  326 + <widget class="FormatterSpinBox" name="ctrSpBxYearEnd">
  327 + <property name="sizePolicy">
  328 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  329 + <horstretch>0</horstretch>
  330 + <verstretch>0</verstretch>
  331 + </sizepolicy>
  332 + </property>
  333 + <property name="font">
  334 + <font>
  335 + <family>나눔고딕</family>
  336 + <pointsize>18</pointsize>
  337 + <underline>true</underline>
  338 + </font>
  339 + </property>
  340 + <property name="focusPolicy">
  341 + <enum>Qt::StrongFocus</enum>
  342 + </property>
  343 + <property name="frame">
  344 + <bool>false</bool>
  345 + </property>
  346 + <property name="alignment">
  347 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  348 + </property>
  349 + <property name="buttonSymbols">
  350 + <enum>QAbstractSpinBox::NoButtons</enum>
  351 + </property>
  352 + <property name="minimum">
  353 + <number>2000</number>
  354 + </property>
  355 + <property name="maximum">
  356 + <number>2100</number>
  357 + </property>
  358 + <property name="value">
  359 + <number>2000</number>
  360 + </property>
  361 + </widget>
  362 + </item>
  363 + <item>
  364 + <widget class="QLabel" name="label_5">
  365 + <property name="font">
  366 + <font>
  367 + <family>나눔고딕</family>
  368 + <pointsize>18</pointsize>
  369 + <weight>75</weight>
  370 + <bold>true</bold>
  371 + </font>
  372 + </property>
  373 + <property name="text">
  374 + <string>년</string>
  375 + </property>
  376 + </widget>
  377 + </item>
  378 + <item>
  379 + <widget class="FormatterSpinBox" name="ctrSpBxMonthEnd">
  380 + <property name="sizePolicy">
  381 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  382 + <horstretch>0</horstretch>
  383 + <verstretch>0</verstretch>
  384 + </sizepolicy>
  385 + </property>
  386 + <property name="font">
  387 + <font>
  388 + <family>나눔고딕</family>
  389 + <pointsize>18</pointsize>
  390 + <underline>true</underline>
  391 + </font>
  392 + </property>
  393 + <property name="focusPolicy">
  394 + <enum>Qt::StrongFocus</enum>
  395 + </property>
  396 + <property name="frame">
  397 + <bool>false</bool>
  398 + </property>
  399 + <property name="alignment">
  400 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  401 + </property>
  402 + <property name="buttonSymbols">
  403 + <enum>QAbstractSpinBox::NoButtons</enum>
  404 + </property>
  405 + <property name="minimum">
  406 + <number>1</number>
  407 + </property>
  408 + <property name="maximum">
  409 + <number>12</number>
  410 + </property>
  411 + <property name="value">
  412 + <number>12</number>
  413 + </property>
  414 + </widget>
  415 + </item>
  416 + <item>
  417 + <widget class="QLabel" name="label_6">
  418 + <property name="font">
  419 + <font>
  420 + <family>나눔고딕</family>
  421 + <pointsize>18</pointsize>
  422 + <weight>75</weight>
  423 + <bold>true</bold>
  424 + </font>
  425 + </property>
  426 + <property name="text">
  427 + <string>월</string>
  428 + </property>
  429 + </widget>
  430 + </item>
  431 + <item>
  432 + <widget class="FormatterSpinBox" name="ctrSpBxDayEnd">
  433 + <property name="sizePolicy">
  434 + <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
  435 + <horstretch>0</horstretch>
  436 + <verstretch>0</verstretch>
  437 + </sizepolicy>
  438 + </property>
  439 + <property name="font">
  440 + <font>
  441 + <family>나눔고딕</family>
  442 + <pointsize>18</pointsize>
  443 + <underline>true</underline>
  444 + </font>
  445 + </property>
  446 + <property name="focusPolicy">
  447 + <enum>Qt::StrongFocus</enum>
  448 + </property>
  449 + <property name="frame">
  450 + <bool>false</bool>
  451 + </property>
  452 + <property name="alignment">
  453 + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  454 + </property>
  455 + <property name="buttonSymbols">
  456 + <enum>QAbstractSpinBox::NoButtons</enum>
  457 + </property>
  458 + <property name="minimum">
  459 + <number>1</number>
  460 + </property>
  461 + <property name="maximum">
  462 + <number>31</number>
  463 + </property>
  464 + <property name="value">
  465 + <number>30</number>
  466 + </property>
  467 + </widget>
  468 + </item>
  469 + <item>
  470 + <widget class="QLabel" name="label_7">
  471 + <property name="font">
  472 + <font>
  473 + <family>나눔고딕</family>
  474 + <pointsize>18</pointsize>
  475 + <weight>75</weight>
  476 + <bold>true</bold>
  477 + </font>
  478 + </property>
  479 + <property name="text">
  480 + <string>일</string>
  481 + </property>
  482 + </widget>
  483 + </item>
  484 + </layout>
  485 + </item>
  486 + <item>
  487 + <layout class="QGridLayout" name="gridLayout_" columnstretch="0,0" columnminimumwidth="0,0">
  488 + <property name="leftMargin">
  489 + <number>100</number>
  490 + </property>
  491 + <property name="rightMargin">
  492 + <number>100</number>
  493 + </property>
  494 + <property name="bottomMargin">
  495 + <number>10</number>
  496 + </property>
  497 + <property name="spacing">
  498 + <number>0</number>
  499 + </property>
  500 + <item row="0" column="0">
  501 + <widget class="QPushButton" name="ctrBtnOk">
  502 + <property name="sizePolicy">
  503 + <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
  504 + <horstretch>0</horstretch>
  505 + <verstretch>0</verstretch>
  506 + </sizepolicy>
  507 + </property>
  508 + <property name="minimumSize">
  509 + <size>
  510 + <width>157</width>
  511 + <height>77</height>
  512 + </size>
  513 + </property>
  514 + <property name="font">
  515 + <font>
  516 + <weight>75</weight>
  517 + <bold>true</bold>
  518 + <underline>true</underline>
  519 + </font>
  520 + </property>
  521 + <property name="styleSheet">
  522 + <string notr="true">QPushButton{
  523 + border-image : url(:/images/config/105_icon_download.png);
  524 +}
  525 +
  526 +QPushButton::pressed, QPushButton::focus{
  527 + border-image : url(:/images/config/105_icon_download_ov.png);
  528 +}</string>
  529 + </property>
  530 + <property name="text">
  531 + <string/>
  532 + </property>
  533 + </widget>
  534 + </item>
  535 + <item row="0" column="1">
  536 + <widget class="QPushButton" name="ctrBtnCancel">
  537 + <property name="sizePolicy">
  538 + <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
  539 + <horstretch>0</horstretch>
  540 + <verstretch>0</verstretch>
  541 + </sizepolicy>
  542 + </property>
  543 + <property name="minimumSize">
  544 + <size>
  545 + <width>82</width>
  546 + <height>82</height>
  547 + </size>
  548 + </property>
  549 + <property name="font">
  550 + <font>
  551 + <weight>75</weight>
  552 + <bold>true</bold>
  553 + <underline>true</underline>
  554 + </font>
  555 + </property>
  556 + <property name="styleSheet">
  557 + <string notr="true">QPushButton{
  558 + border-image : url(:/images/config/105_icon_cancel.png);
  559 +}
  560 +
  561 +QPushButton::pressed, QPushButton::focus{
  562 + border-image : url(:/images/config/105_icon_cancel_ov.png);
  563 +}
  564 +</string>
  565 + </property>
  566 + <property name="text">
  567 + <string/>
  568 + </property>
  569 + </widget>
  570 + </item>
  571 + </layout>
  572 + </item>
  573 + </layout>
  574 + </widget>
  575 + <widget class="KeyboardWidget" name="keyboardwidget" native="true">
  576 + <property name="geometry">
  577 + <rect>
  578 + <x>0</x>
  579 + <y>425</y>
  580 + <width>900</width>
  581 + <height>600</height>
  582 + </rect>
  583 + </property>
  584 + </widget>
  585 + </widget>
  586 + </widget>
  587 + <customwidgets>
  588 + <customwidget>
  589 + <class>KeyboardWidget</class>
  590 + <extends>QWidget</extends>
  591 + <header>keyboardwidget.h</header>
  592 + <container>1</container>
  593 + </customwidget>
  594 + <customwidget>
  595 + <class>FormatterSpinBox</class>
  596 + <extends>QSpinBox</extends>
  597 + <header>formatterspinbox.h</header>
  598 + </customwidget>
  599 + </customwidgets>
  600 + <tabstops>
  601 + <tabstop>ctrSpBxYearStart</tabstop>
  602 + <tabstop>ctrSpBxMonthStart</tabstop>
  603 + <tabstop>ctrSpBxDayStart</tabstop>
  604 + </tabstops>
  605 + <resources>
  606 + <include location="resources.qrc"/>
  607 + </resources>
  608 + <connections/>
  609 +</ui>
... ...
app/gui/oven_control/images/not_recognized/config_service/104_dwon.png

530 Bytes

app/gui/oven_control/images/not_recognized/config_service/104_update.png

527 Bytes

app/gui/oven_control/images/symbol/down_date.png

530 Bytes

app/gui/oven_control/images/symbol/up_date.png

527 Bytes

app/gui/oven_control/mainwindow.cpp
... ... @@ -61,8 +61,9 @@ void MainWindow::jump(QMainWindow *newChild)
61 61  
62 62 void MainWindow::killChild()
63 63 {
64   - if (instance->child)
  64 + if (instance->child){
65 65 instance->child->deleteLater();
  66 + }
66 67 }
67 68  
68 69 bool MainWindow::killChildCook()
... ...
app/gui/oven_control/oven_control.pro
... ... @@ -144,7 +144,8 @@ SOURCES += main.cpp\
144 144 multicookbook.cpp \
145 145 haccp.cpp \
146 146 canvas.cpp \
147   - touchtestwindow.cpp
  147 + touchtestwindow.cpp \
  148 + haccpdownloaddlg.cpp
148 149  
149 150  
150 151 HEADERS += mainwindow.h \
... ... @@ -279,7 +280,8 @@ HEADERS += mainwindow.h \
279 280 multicookbook.h \
280 281 haccp.h \
281 282 canvas.h \
282   - touchtestwindow.h
  283 + touchtestwindow.h \
  284 + haccpdownloaddlg.h
283 285  
284 286 FORMS += mainwindow.ui \
285 287 manualcookwindow.ui \
... ... @@ -364,7 +366,8 @@ FORMS += mainwindow.ui \
364 366 multicookselectionwindow.ui \
365 367 multicookmanualwindow.ui \
366 368 multicookautowindow.ui \
367   - touchtestwindow.ui
  369 + touchtestwindow.ui \
  370 + haccpdownloaddlg.ui
368 371  
369 372 RESOURCES += \
370 373 resources.qrc
... ...
app/gui/oven_control/resources.qrc
... ... @@ -630,5 +630,7 @@
630 630 <file>images/help/page_prev.png</file>
631 631 <file>images/help/page_prev_over.png</file>
632 632 <file>images/background/popup/509.png</file>
  633 + <file>images/symbol/up_date.png</file>
  634 + <file>images/symbol/down_date.png</file>
633 635 </qresource>
634 636 </RCC>
... ...
release/application.tar
No preview for this file type