SJ90C V1.1 ,增加滤波功能,优化了界面显示

This commit is contained in:
CHINAMI-TV221UM\Administrator 2024-06-14 17:09:21 +08:00
parent 8765f74530
commit 2866a6f646
21 changed files with 1529 additions and 224 deletions

View File

@ -327,7 +327,7 @@ void CBoardSetting::PushData()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("ACCELEROMETER").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("CTC-AC102").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(strMAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("15000").arg("0.5").arg(30).arg("5000").arg("").arg(0).arg(0).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(1024).arg("").arg("").arg(timeStamp).\
@ -347,7 +347,7 @@ void CBoardSetting::PushData()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("ACCELEROMETER").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("CTC-AC102").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(strMAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("15000").arg("0.5").arg(12).arg("5000").arg("").arg(0).arg(0).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(1024).arg("").arg("").arg(timeStamp).\
@ -366,7 +366,7 @@ void CBoardSetting::PushData()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("PULSE_CURRENT").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("电流变送器").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("").arg("").arg(20).arg("5000").arg("").arg(0).arg(0).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(1024).arg("").arg("").arg(timeStamp).\
@ -386,7 +386,7 @@ void CBoardSetting::PushData()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("SLOW_CURRENT").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("电流变送器").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("").arg("").arg(20).arg("5000").arg("").arg(0).arg(0).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(64).arg("").arg("").arg(timeStamp).\
@ -415,7 +415,7 @@ void CBoardSetting::PushData()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',0,0,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',0,0,'','',0);").\
arg("NULL").arg(0).arg("false").arg(strchannelType).arg("0").arg("").arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg(0).arg(0).arg("").
arg(0).arg("").arg(0).arg("").arg(0).arg(strChannelID).arg("").arg(strChannelName).arg("").arg(0).arg("").arg(0).arg("").arg("").arg(0).arg("").arg(0).arg("").arg("").arg(0).arg("").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("").arg("").arg("").arg(10).arg("").arg("").arg(0).arg(0).arg("0").arg("").arg(0).arg("").arg("").arg("0").arg(0).arg("").arg("").arg(timeStamp).\
@ -757,7 +757,7 @@ void CBoardSetting::on_pushButton_Init_clicked()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("ACCELEROMETER").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("CTC-AC102").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(strMAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("15000").arg("0.5").arg(10).arg("5000").arg("").arg(1).arg(1).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(1024).arg("").arg("").arg(timeStamp).\
@ -776,7 +776,7 @@ void CBoardSetting::on_pushButton_Init_clicked()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("PULSE_CURRENT").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("电流变送器").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("").arg("").arg(20).arg("5000").arg("").arg(1).arg(1).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(1024).arg("").arg("").arg(timeStamp).\
@ -796,7 +796,7 @@ void CBoardSetting::on_pushButton_Init_clicked()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',98,1,'','',0);").\
arg("NULL").arg(0).arg("true").arg("SLOW_CURRENT").arg("0").arg("Bottom").arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg("false").arg(0).arg(0).arg(0).arg("false").
arg(0).arg("false").arg(0).arg("false").arg(0).arg(strChannelID).arg("NONE").arg(strChannelName).arg("false").arg(0).arg("false").arg(0).arg("RMSValue").arg("").arg(0).arg("false").arg(0).arg("电流变送器").arg("false").arg(0).arg("false").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("Hamming").arg("").arg("").arg(20).arg("5000").arg("").arg(0).arg(0).arg("0").arg("60000").arg(0).arg("NONE").arg("").arg("0").arg(64).arg("").arg("").arg(timeStamp).\
@ -825,7 +825,7 @@ void CBoardSetting::on_pushButton_Init_clicked()
QString str = QString(" values('%1','%2','%3','%4',%5,'%6','%7',%8,'%9',%10,'%11',%12,'%13',%14,'%15',%16,'%17',%18,%19,%20,'%21',%22,'%23',%24,\
'%25',%26,'%27','%28','%29','%30',%31,'%32',%33,'%34','%35',%36,'%37',%38,'%39','%40',%41,'%42',%43,'%44',\
'%45','%46',%47,%48,%49,'%50','%51','%52',%53,'%54','%55',%56,%57,'%58','%59',%60,'%61','%62','%63',%64,'%65','%66','%67',\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',0,0,'','');").\
'%68','%69','%70',%71,%72,%73,'%74','%75','%76','%77','%78','%79','%80','%81','%82','%83','%84',%85,'%86','%87','%88','%89','%90','%91','%92','%93','%94','%95','',0,0,'','',0);").\
arg("NULL").arg(0).arg("false").arg(strchannelType).arg("0").arg("").arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg("").arg(0).arg(0).arg(0).arg("").
arg(0).arg("").arg(0).arg("").arg(0).arg(strChannelID).arg("").arg(strChannelName).arg("").arg(0).arg("").arg(0).arg("").arg("").arg(0).arg("").arg(0).arg("").arg("").arg(0).arg("").arg(0).arg("").\
arg("true").arg(MAC).arg(0).arg(1000).arg(0).arg("").arg("").arg("").arg(10).arg("").arg("").arg(0).arg(0).arg("0").arg("").arg(0).arg("").arg("").arg("0").arg(0).arg("").arg("").arg(timeStamp).\
@ -947,6 +947,14 @@ void CBoardSetting::on_pushButton_Init_clicked()
// g_FtpClient->SetUserInfo("root","@#cidw!@123456");
// g_FtpClient->UpLoadFile(name,"UnitBoardsInfo.json");
customLogMessageHandler(QtDebugMsg,"初始化机组板卡配置信息推送完成!");
QJsonObject sendData;
sendData["cmd"] = "111";
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
putJson();
}

View File

@ -7,6 +7,7 @@
#include <QDate>
#include <QTime>
#include <QInputDialog>
#include <QListView>
#include "NetMgr.h"
CChannelList::CChannelList(QWidget *parent) :
@ -14,6 +15,7 @@ CChannelList::CChannelList(QWidget *parent) :
ui(new Ui::CChannelList)
{
ui->setupUi(this);
ui->comboBox_operate->setView(new QListView());
// this->setWindowTitle("QTableView简单使用");
// //建立模型对象空间并指定父对象
@ -48,7 +50,7 @@ CChannelList::CChannelList(QWidget *parent) :
// this->setColumnCheckable(0, true);
// //this->setColumnCheckable(2, true);
//--1 初始化
headerStr = QObject::tr(" ,通道名称,模块编号,通道序号,通道状态,通道类型,采样频率(Hz),灵敏度,工程单位,范围检查,最小值,\
headerStr = QObject::tr(" ,通道名称,模块编号,通道滤波状态,通道状态,通道类型,采样频率(Hz),灵敏度,工程单位,范围检查,最小值,\
,1x幅值补偿,1x相位补偿,,,,,,,,\
,,IEPE,,0,,,沿,,Hysteresis(V),\
,,,,,,");
@ -57,7 +59,7 @@ CChannelList::CChannelList(QWidget *parent) :
iniVar();
iniUi();
iniConnect();
initReadConfig();
connect(ui->tableView, SIGNAL(doubleClicked(const QModelIndex &)), this, SLOT(slotRowDoubleClicked(const QModelIndex &)));
ui->tableView->setEditTriggers(QAbstractItemView::NoEditTriggers);
ui->tableView->setColumnWidth(33, 256);
@ -70,12 +72,17 @@ CChannelList::CChannelList(QWidget *parent) :
SlowSpeeddialog = new CSlowSpeedChannelSetting();
connect(SlowSpeeddialog, SIGNAL(sgSetChannelData(ChannelSetting)), this, SLOT(slotSetChannelData(ChannelSetting)));
ui->comboBox_operate->addItem("带通滤波");
ui->comboBox_operate->addItem("通道");
//--2 创建表格项
// QStringList workingConditionName;
// workingConditionName<<tr("工况1")<<tr("工况2")<<tr("工况3");
// createItem(workingConditionName);
#ifdef QT_DEBUG
initReadConfig();
#endif
}
@ -100,20 +107,25 @@ void CChannelList::initReadConfig()
QVariantList strRowItem ;
QString strChannelStatus;
QString strChannelStatus,strChannelFilterStatus,strChannelNo;
if(g_channelSetting[i].isEnable)
strChannelStatus = "启用";
else
strChannelStatus = "关闭";
if(g_channelSetting[i].filterStatus)
strChannelFilterStatus = "启用";
else
strChannelFilterStatus = "关闭";
QString strcouplingACDC;
if(g_channelSetting[i].couplingACDC)
strcouplingACDC = "AC";
else
strcouplingACDC = "DC";
strChannelNo = QString("%1-%2").arg(g_channelSetting[i].sensorModuleNo).arg(g_channelSetting[i].sensorNo);
QString TStr = QDateTime::fromSecsSinceEpoch(g_channelSetting[i].sensorConfigureDate.toInt()).toString("yyyy-MM-dd hh:mm:ss");
strRowItem << g_channelSetting[i].channelName << g_channelSetting[i].sensorModuleNo << g_channelSetting[i].sensorNo\
strRowItem << g_channelSetting[i].channelName << strChannelNo << strChannelFilterStatus\
<< strChannelStatus << strChannelType << g_channelSetting[i].samplingRate\
<< g_channelSetting[i].sensorSensitivity <<g_channelSetting[i].sensorEngineeringUnit <<g_channelSetting[i].sensorRangeCheck \
<< g_channelSetting[i].sensorRangeMin <<g_channelSetting[i].sensorRangeMax <<g_channelSetting[i].sensor1xAmplitudeRunout\
@ -154,7 +166,7 @@ void CChannelList::iniUi()
if(i == 1){
ui->tableView->setColumnWidth(i, 200);
}else{
ui->tableView->setColumnWidth(i, 150);
ui->tableView->setColumnWidth(i, 130);
}
}
@ -164,6 +176,20 @@ void CChannelList::iniConnect()
{
connect(myHeader, &TableHeaderView::stateChanged, this, &CChannelList::headerStateChangedSlot);
connect(model, SIGNAL(itemChanged(QStandardItem*)), this, SLOT(itemChangedSlot(QStandardItem*)));
connect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
QJsonObject sendData;
sendData["cmd"] = "97";
QJsonArray chan_list;
for (int i = 0; i < g_channelSetting.size(); i++) {
if(g_channelSetting[i].boardType != "5" && g_channelSetting[i].boardType != "6" )
chan_list.append(g_channelSetting[i].channelId);
}
sendData["chan_list"] = chan_list;
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
}
void CChannelList::createItem(QStringList filename)
@ -583,47 +609,85 @@ void CChannelList::on_columnSectionClicked(int column, bool checked)
void CChannelList::on_pushButton_open_clicked()
{
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
// QLabel *pLabel = new QLabel(this);
// pLabel->setText("启用");
// QPalette palette;
// palette.setColor(QPalette::Background, QColor(Qt::green));
// //palette.setColor(QPalette::WindowText,Qt::white);
// //pLabel->setAutoFillBackground(true);
// pLabel->setPalette(palette);
// ui->tableView->setIndexWidget(model->index(i,4),pLabel);
//model->setData(model->index(i,4),QBrush(Qt::red), Qt::BackgroundRole);
model->setItem(i,4,new QStandardItem("启用"));
QString strChannelID = model->data(model->index(i,38)).toString();
QString strUpdateSql = QString(" set isEnable = %1 , isWork = %2 where channelId = '%3' ").arg(1).arg(1).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
if(ui->comboBox_operate->currentText() == "通道"){
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
// QLabel *pLabel = new QLabel(this);
// pLabel->setText("启用");
// QPalette palette;
// palette.setColor(QPalette::Background, QColor(Qt::green));
// //palette.setColor(QPalette::WindowText,Qt::white);
// //pLabel->setAutoFillBackground(true);
// pLabel->setPalette(palette);
// ui->tableView->setIndexWidget(model->index(i,4),pLabel);
//model->setData(model->index(i,4),QBrush(Qt::red), Qt::BackgroundRole);
model->setItem(i,4,new QStandardItem("启用"));
QString strChannelID = model->data(model->index(i,38)).toString();
QString strUpdateSql = QString(" set isEnable = %1 , isWork = %2 where channelId = '%3' ").arg(1).arg(1).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
}
}
}
putJson();
putJson();
}else if(ui->comboBox_operate->currentText() == "带通滤波"){
QJsonArray channleList;
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
model->setItem(i,3,new QStandardItem("启用"));
QString strChannelID = model->data(model->index(i,38)).toString();
QString strUpdateSql = QString(" set filterStatus = %1 where channelId = '%2' ").arg(1).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
channleList.append(g_channelSetting[i].channelId);
}
}
operateChannelFilter(true,channleList);
}
}
void CChannelList::on_pushButton_close_clicked()
{
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
model->setItem(i,4,new QStandardItem("关闭"));
QString strChannelID = model->data(model->index(i,39)).toString();
QString strUpdateSql = QString(" set isEnable = %1, isWork = %2 where channelId = '%3' ").arg(0).arg(0).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
if(ui->comboBox_operate->currentText() == "通道"){
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
model->setItem(i,4,new QStandardItem("关闭"));
QString strChannelID = model->data(model->index(i,39)).toString();
QString strUpdateSql = QString(" set isEnable = %1, isWork = %2 where channelId = '%3' ").arg(0).arg(0).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
}
}
putJson();
}else if(ui->comboBox_operate->currentText() == "带通滤波"){
QJsonArray channleList;
for (int i = 0; i < model->rowCount(); i++) {
QModelIndex indexCheck = model->index(i,0);
bool check = model->data(indexCheck, Qt::UserRole).toBool();
if(check){
model->setItem(i,3,new QStandardItem("关闭"));
QString strChannelID = model->data(model->index(i,38)).toString();
QString strUpdateSql = QString(" set filterStatus = %1 where channelId = '%2' ").arg(0).arg(g_channelSetting[i].channelId);
QString tableName = "t_ChannelSetting ";
g_SqliteDB->UpdateDataSql(tableName,strUpdateSql);
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
channleList.append(g_channelSetting[i].channelId);
}
}
operateChannelFilter(false,channleList);
}
putJson();
}
@ -631,7 +695,18 @@ void CChannelList::on_pushButton_refresh_clicked()
{
model->removeRows(0, model->rowCount());
g_channelSetting = g_SqliteDB->GetDataMultiLine("t_ChannelSetting");
initReadConfig();
connect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
QJsonObject sendData;
sendData["cmd"] = "97";
QJsonArray chan_list;
for (int i = 0; i < g_channelSetting.size(); i++) {
chan_list.append(g_channelSetting[i].channelId);
}
sendData["chan_list"] = chan_list;
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
}
void CChannelList::slotNetMgr(QString sAddr, const QVariant &msg)
@ -641,14 +716,28 @@ void CChannelList::slotNetMgr(QString sAddr, const QVariant &msg)
{
QJsonValue arrays_value = objec.take("cmd");
//qDebug()<<"cmd ="<<arrays_value.toString();
if(arrays_value.toString() == "08"){
if(arrays_value.toString() == "08" || arrays_value.toString() == "96"){
bool Status = objec.take("success").toBool();
QString strMessage = objec.take("message").toString();
if(Status){
QMessageBox::information(NULL, QStringLiteral("提示"), "保存成功!");
}else{
QMessageBox::information(NULL, QStringLiteral("提示"), strMessage);
}
}else if(arrays_value.toString() == "97"){
QJsonArray chan_list = objec["chan_list"].toArray();
QJsonArray status = objec["status"].toArray();
for (int i = 0; i < g_channelSetting.size(); i++) {
for (int j = 0; j < chan_list.size(); j++) {
if(g_channelSetting[i].channelId == chan_list[j].toString()){
g_channelSetting[i].filterStatus = status[j].toInt();
}
}
}
initReadConfig();
}
}
disconnect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
}
void CChannelList::on_pushButton_restart_clicked()
{
@ -669,3 +758,15 @@ void CChannelList::on_pushButton_restart_clicked()
}
void CChannelList::operateChannelFilter(bool type,QJsonArray& channleList)
{
connect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
QJsonObject sendData;
sendData["cmd"] = "96";
sendData["open"] = type;
sendData["chan_list"] = channleList;
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
}

View File

@ -55,6 +55,8 @@ private:
int m_nCurRow;
CSlowSpeedChannelSetting *SlowSpeeddialog;
CChannelSetting *ChannelSettingdialog;
void operateChannelFilter(bool type,QJsonArray& channleList);
private slots:
void headerStateChangedSlot(int state);
void itemChangedSlot(QStandardItem* item);

View File

@ -5,7 +5,8 @@
#include <QTime>
#include "CopyChannelSetting.h"
#include "NetMgr.h"
#include "CustomFilter.h"
#include <QNetworkRequest>
CChannelSetting::CChannelSetting(QWidget *parent) :
QWidget(parent),
@ -18,6 +19,8 @@ CChannelSetting::CChannelSetting(QWidget *parent) :
ui->RPMComBox->setView(new QListView());
ui->pairChannelComBox->setView(new QListView());
ui->channelTypeCombox->setView(new QListView());
ui->comboBox_sensorICP_2->setView(new QListView());
ui->comboBox_sensorType->setView(new QListView());
ui->tabWidget->tabBar()->hide();
QRegExp exp("[0-9\\.-]+$");
@ -34,8 +37,8 @@ CChannelSetting::CChannelSetting(QWidget *parent) :
ui->lineEdit_analyseRate->setValidator(Validator);
ui->lineEdit_RateRatio->setValidator(Validator);
ui->lineEdit_envelopeLowpassband->setValidator(Validator);
ui->lineEdit_envelopeHighpassband->setValidator(Validator);
//ui->lineEdit_envelopeLowpassband->setValidator(Validator);
//ui->lineEdit_envelopeHighpassband->setValidator(Validator);
ui->lineEdit_sensorLocationInDegree->setValidator(Validator);
ui->lineEdit_sensor1xPhaseRunout->setValidator(Validator);
ui->lineEdit_sensor1xAmplitudeRunout->setValidator(Validator);
@ -237,9 +240,9 @@ void CChannelSetting::displayChannelSetting()
// ui->comboBox_samplingRate->setCurrentText("16kHz");
QString envelopeLowpassband = QString("%1").arg(channelSetting.envelopeLowpassband);
ui->lineEdit_envelopeLowpassband->setText(envelopeLowpassband);
//ui->lineEdit_envelopeLowpassband->setText(envelopeLowpassband);
QString envelopeHighpassband = QString("%1").arg(channelSetting.envelopeHighpassband);
ui->lineEdit_envelopeHighpassband->setText(envelopeHighpassband);
//ui->lineEdit_envelopeHighpassband->setText(envelopeHighpassband);
QString sensorLocationInDegree = QString("%1").arg(channelSetting.sensorLocationInDegree);
ui->lineEdit_sensorLocationInDegree->setText(sensorLocationInDegree);
@ -458,8 +461,8 @@ void CChannelSetting::PushData()
channelSetting.sensor1xPhaseRunout = ui->lineEdit_sensor1xPhaseRunout->text();
channelSetting.sensor1xAmplitudeRunout = ui->lineEdit_sensor1xAmplitudeRunout->text();
channelSetting.envelopeHighpassband = ui->lineEdit_envelopeHighpassband->text().toDouble();
channelSetting.envelopeLowpassband = ui->lineEdit_envelopeLowpassband->text().toDouble();
//channelSetting.envelopeHighpassband = ui->lineEdit_envelopeHighpassband->text().toDouble();
//channelSetting.envelopeLowpassband = ui->lineEdit_envelopeLowpassband->text().toDouble();
channelSetting.sensorTypes = ui->comboBox_sensorType->currentText();
if(ui->comboBox_bearingStartPosition->currentText() == ""){
@ -570,8 +573,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
// ui->comboBox_coupling->clear();
// ui->comboBox_coupling->addItem("AC");
// ui->comboBox_coupling->addItem("DC");
ui->lineEdit_envelopeLowpassband->setText("10");
ui->lineEdit_envelopeHighpassband->setText("3500");
//ui->lineEdit_envelopeLowpassband->setText("10");
//ui->lineEdit_envelopeHighpassband->setText("3500");
ui->lineEdit_sensorRange->setText("2032");
}else if(arg1 == "速度"){
@ -595,8 +598,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
ui->comboBox_coupling->clear();
ui->comboBox_coupling->addItem("AC");
ui->comboBox_coupling->addItem("DC");
ui->lineEdit_envelopeLowpassband->setText("4.5");
ui->lineEdit_envelopeHighpassband->setText("5000");
//ui->lineEdit_envelopeLowpassband->setText("4.5");
//ui->lineEdit_envelopeHighpassband->setText("5000");
ui->pairChannelComBox->setCurrentText("- -");
ui->RPMComBox->setCurrentText("- -");
ui->lineEdit_sensorRange->setText("2054");
@ -622,8 +625,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
ui->comboBox_coupling->clear();
ui->comboBox_coupling->addItem("AC");
ui->comboBox_coupling->addItem("DC");
ui->lineEdit_envelopeLowpassband->setText("350");
ui->lineEdit_envelopeHighpassband->setText("12000");
//ui->lineEdit_envelopeLowpassband->setText("350");
//ui->lineEdit_envelopeHighpassband->setText("12000");
ui->pairChannelComBox->setCurrentText("- -");
ui->RPMComBox->setCurrentText("- -");
ui->lineEdit_sensorRange->setText("2000");
@ -650,8 +653,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
ui->comboBox_coupling->clear();
ui->comboBox_coupling->addItem("DC");
ui->comboBox_coupling->addItem("AC");
ui->lineEdit_envelopeLowpassband->setText("1");
ui->lineEdit_envelopeHighpassband->setText("4000");
//ui->lineEdit_envelopeLowpassband->setText("1");
//ui->lineEdit_envelopeHighpassband->setText("4000");
ui->pairChannelComBox->setCurrentText("- -");
ui->RPMComBox->setCurrentText("- -");
ui->lineEdit_sensorRange->setText("2000");
@ -679,8 +682,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
ui->comboBox_coupling->clear();
ui->comboBox_coupling->addItem("DC");
ui->comboBox_coupling->addItem("AC");
ui->lineEdit_envelopeLowpassband->setText("1");
ui->lineEdit_envelopeHighpassband->setText("4000");
//ui->lineEdit_envelopeLowpassband->setText("1");
//ui->lineEdit_envelopeHighpassband->setText("4000");
ui->pairChannelComBox->setCurrentText("- -");
ui->RPMComBox->setCurrentText("- -");
ui->lineEdit_sensorRange->setText("2");
@ -705,8 +708,8 @@ void CChannelSetting::on_channelTypeCombox_currentTextChanged(const QString &arg
ui->comboBox_coupling->clear();
ui->comboBox_coupling->addItem("DC");
ui->comboBox_coupling->addItem("AC");
ui->lineEdit_envelopeLowpassband->setText("0");
ui->lineEdit_envelopeHighpassband->setText("5000");
//ui->lineEdit_envelopeLowpassband->setText("0");
//ui->lineEdit_envelopeHighpassband->setText("5000");
ui->pairChannelComBox->setCurrentText("- -");
ui->RPMComBox->setCurrentText("- -");
ui->lineEdit_sensorRange->setText("2000");
@ -832,3 +835,18 @@ void CChannelSetting::on_lineEdit_engineeringUnit_editingFinished()
ui->label_unit2->setText(str);
}
void CChannelSetting::on_pushButton_CustomFilter_clicked()
{
CustomFilter *pCustomFilter = new CustomFilter();
pCustomFilter->channel_ID = channelSetting.channelId;
if(ui->channelTypeCombox->currentText()=="径向振动位移" && ui->comboBox_sensorType->currentText() =="低频位移")
pCustomFilter->vibrate_channel = 1;
else
pCustomFilter->vibrate_channel = 0;
pCustomFilter->setWindowModality(Qt::ApplicationModal);
pCustomFilter->show();
pCustomFilter->getfilterInfo();
}

View File

@ -40,6 +40,8 @@ private slots:
void on_lineEdit_engineeringUnit_editingFinished();
void on_pushButton_CustomFilter_clicked();
public slots:
void slotSetChannelData(QStringList&);
private:

View File

@ -246,6 +246,10 @@ void CConfiguration::slotDeleteItem()
}else{
QStandardItem* parantitem = item->parent();
if(parantitem == NULL){
model_Relay->removeRow(curIndex.row(),curIndex.parent());
return;
}
QString paranNodeText = parantitem->text();
if(paranNodeText.contains("logicAND")){

195
CustomFilter.cpp Normal file
View File

@ -0,0 +1,195 @@
#include "CustomFilter.h"
#include "ui_CustomFilter.h"
#include <QNetworkRequest>
#include "QMyTableViewBtnDelegate.h"
#include "NetMgr.h"
#include <QListView>
CustomFilter::CustomFilter(QWidget *parent) :
QWidget(parent),
ui(new Ui::CustomFilter)
{
ui->setupUi(this);
headerStr = QObject::tr("频率(Hz),衰减位移量(um)");
model = new QStandardItemModel(ui->tableView);
ui->tableView->setSelectionBehavior(QAbstractItemView::SelectRows); //选中行
QStringList headerList = headerStr.split(",");
model->setHorizontalHeaderLabels(headerList);
model->setColumnCount(headerList.size());
ui->tableView->setModel(model);
ui->tableView->setAlternatingRowColors(true);
ui->tableView->setColumnWidth(1, 150);
ui->tableView->horizontalHeader()->setSectionResizeMode(QHeaderView::Interactive);
ui->comboBox_open->setView(new QListView());
ui->comboBox_open->addItem("");
ui->comboBox_open->addItem("");
connect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
connect(ui->comboBox_open,SIGNAL(currentIndexChanged(const QString &)),this,SLOT(comboBox_open_currentTextChanged(const QString&)));
setAttribute(Qt::WA_DeleteOnClose);
}
CustomFilter::~CustomFilter()
{
qDebug() << "~CustomFilter()" << endl;
disconnect(g_NetMgr,SIGNAL(sigNetMgr(QString, const QVariant&)), this, SLOT(slotNetMgr(QString,const QVariant&)));
delete ui;
}
void CustomFilter::on_pushButton_Add_clicked()
{
int rowCount = model->rowCount();
model->setRowCount(rowCount+1);
model->setData(model->index(rowCount,0,QModelIndex()),"");
model->setData(model->index(rowCount,1,QModelIndex()),"");
}
void CustomFilter::on_pushButton_Del_clicked()
{
int rowCount = model->rowCount();
int row = ui->tableView->currentIndex().row();//获得当前行索引
if(rowCount < 1 || row == -1){
QMessageBox::warning(this, QStringLiteral("提示"), QStringLiteral("请先选择一条记录!"));
return;
}
model->removeRow(row);
}
void CustomFilter::on_pushButton_Submit_clicked()
{
int rowCount = model->rowCount();
QJsonObject sendData;
sendData["cmd"] = "99";
sendData["chan_id"] = channel_ID;
sendData["num"] = rowCount;
QJsonArray range;
for(int i = 0; i < rowCount;i++){
QModelIndex index = model->index(i,0);
QString strData = model->data(index).toString();
range.append(strData.toInt());
index = model->index(i,1);
strData = model->data(index).toString();
range.append(strData.toInt());
}
sendData["range"] = range;
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
bool type ;
if(ui->comboBox_open->currentText() == ""){
type = true;
}
if(ui->comboBox_open->currentText() == ""){
type = false;
}
if(ui->spinBox_start->text().toInt() >= ui->spinBox_stop->text().toInt()){
QMessageBox::warning(this, QStringLiteral("提示"), QStringLiteral("频率下限设置错误!"));
return;
}
QJsonObject sendData2;
sendData2["cmd"] = "95";
sendData2["chan_id"] = channel_ID;
sendData2["open"] = type;
sendData2["start"] = ui->spinBox_start->text().toInt();
sendData2["stop"] = ui->spinBox_stop->text().toInt();
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData2);
}
void CustomFilter::slotNetMgr(QString sAddr, const QVariant &msg)
{
QJsonObject objec = msg.value<QJsonObject>();
if(objec.contains("cmd"))
{
QJsonValue arrays_value = objec.take("cmd");
qDebug() << "arrays_value" << arrays_value << endl;
bool Status = objec.take("success").toBool();
QString strMessage = objec.take("message").toString();
if(!Status){
QMessageBox::information(NULL, QStringLiteral("提示"), strMessage);
return;
}
if(arrays_value.toString() == "94"){
int Statusfilter = objec.take("status").toInt();
ui->spinBox_start->setValue(objec.take("start").toInt());
ui->spinBox_stop->setValue(objec.take("stop").toInt());
if(Statusfilter){
ui->comboBox_open->setCurrentText("");
}else if(!Statusfilter){
ui->comboBox_open->setCurrentText("");
}
QMessageBox::information(this, QStringLiteral("提示"), QStringLiteral("获取成功!"));
}else if(arrays_value.toString() == "98"){
int num = objec["num"].toInt();
int j = 0;
model->setRowCount(num);
QJsonArray range = objec["range"].toArray();
for (int i = 0; i < num; i++) {
model->setData(model->index(i,0,QModelIndex()),range[j].toInt());
j++;
model->setData(model->index(i,1,QModelIndex()),range[j].toInt());
j++;
}
QMessageBox::information(this, QStringLiteral("提示"), QStringLiteral("获取成功!"));
}else if(arrays_value.toString() == "112"){
int Statusfilter = objec.take("status").toInt();
ui->spinBox_start->setValue(objec.take("start").toInt());
ui->spinBox_stop->setValue(objec.take("stop").toInt());
if(Statusfilter){
ui->comboBox_open->setCurrentText("");
}else if(!Statusfilter){
ui->comboBox_open->setCurrentText("");
}
int num = objec["num"].toInt();
int j = 0;
model->setRowCount(num);
QJsonArray range = objec["range"].toArray();
for (int i = 0; i < num; i++) {
model->setData(model->index(i,0,QModelIndex()),range[j].toInt());
j++;
model->setData(model->index(i,1,QModelIndex()),range[j].toInt());
j++;
}
QMessageBox::information(this, QStringLiteral("提示"), QStringLiteral("获取成功!"));
}else if(arrays_value.toString() == "95" || arrays_value.toString() == "99"){
QMessageBox::information(this, QStringLiteral("提示"), QStringLiteral("设置成功!"));
}
}
if(!vibrate_channel){
ui->comboBox_open->setEnabled(false);
ui->spinBox_start->setEnabled(false);
ui->spinBox_stop->setEnabled(false);
}
}
void CustomFilter::getfilterInfo()
{
QJsonObject sendData;
sendData["cmd"] = "112";
sendData["chan_id"] = channel_ID;
QNetworkRequest req;
QString sUrl = QString("http://%1/cgi-bin/General.cgi/").arg(IP);
req.setUrl(sUrl);
g_NetMgr->PostJson(req,sendData);
}
void CustomFilter::comboBox_open_currentTextChanged(const QString &)
{
qDebug() << "" << endl;
}

39
CustomFilter.h Normal file
View File

@ -0,0 +1,39 @@
#ifndef CUSTOMFILTER_H
#define CUSTOMFILTER_H
#include <QWidget>
#include <QStandardItemModel> //数据模型类
#include "TableHeaderView.h"
#include "global.h"
namespace Ui {
class CustomFilter;
}
class CustomFilter : public QWidget
{
Q_OBJECT
public:
explicit CustomFilter(QWidget *parent = nullptr);
~CustomFilter();
QString channel_ID;
int vibrate_channel;
void getfilterInfo();
private slots:
void on_pushButton_Add_clicked();
void on_pushButton_Del_clicked();
void on_pushButton_Submit_clicked();
void slotNetMgr(QString sAddr,const QVariant& msg);
void comboBox_open_currentTextChanged(const QString &);
private:
Ui::CustomFilter *ui;
TableHeaderView *myHeader;
QStandardItemModel *model;
QString headerStr ;
};
#endif // CUSTOMFILTER_H

333
CustomFilter.ui Normal file
View File

@ -0,0 +1,333 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>CustomFilter</class>
<widget class="QWidget" name="CustomFilter">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>716</width>
<height>480</height>
</rect>
</property>
<property name="windowTitle">
<string>滤波配置</string>
</property>
<property name="styleSheet">
<string notr="true">font: 10pt &quot;黑体&quot;;
color: rgb(27, 30, 35);</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QWidget" name="widget" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>100</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>100</height>
</size>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QGroupBox" name="groupBox_2">
<property name="title">
<string>带通滤波</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<spacer name="horizontalSpacer_6">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>32</width>
<height>33</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QLabel" name="label">
<property name="text">
<string>是否开启</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBox_open">
<property name="minimumSize">
<size>
<width>50</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>32</width>
<height>33</height>
</size>
</property>
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="label_2">
<property name="text">
<string>频率下限</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="spinBox_start">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximum">
<number>9999</number>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QLabel" name="label_6">
<property name="text">
<string>Hz</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>32</width>
<height>33</height>
</size>
</property>
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>频率上限</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="spinBox_stop">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximum">
<number>9999</number>
</property>
<property name="value">
<number>200</number>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QLabel" name="label_5">
<property name="text">
<string>Hz</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>32</width>
<height>33</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_2" native="true">
<layout class="QVBoxLayout" name="verticalLayout_5">
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>自定义滤波设置</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QWidget" name="widget_3" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QTableView" name="tableView"/>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_4" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>136</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="pushButton_Add">
<property name="minimumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_Add { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_Add:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Add:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Add:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>新增</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButton_Del">
<property name="minimumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_Del { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_Del:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Del:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Del:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>删除</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButton_Submit">
<property name="minimumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_Submit { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_Submit:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Submit:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_Submit:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>提交</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>136</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources/>
<connections/>
</ui>

View File

@ -33,6 +33,7 @@ SOURCES += \
Configuration.cpp \
CopyChannelSetting.cpp \
CopyDatFile.cpp \
CustomFilter.cpp \
DIO_Board.cpp \
DataGraphView.cpp \
FileServerConfig.cpp \
@ -83,6 +84,7 @@ HEADERS += \
Configuration.h \
CopyChannelSetting.h \
CopyDatFile.h \
CustomFilter.h \
DIO_Board.h \
DataGraphView.h \
FileServerConfig.h \
@ -133,6 +135,7 @@ FORMS += \
Configuration.ui \
CopyChannelSetting.ui \
CopyDatFile.ui \
CustomFilter.ui \
DIO_Board.ui \
DataGraphView.ui \
FileServerConfig.ui \

View File

@ -130,6 +130,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>电厂名称</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -157,6 +160,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>机组名称</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -184,6 +190,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>电厂编号</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -211,6 +220,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>机组编号</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -238,6 +250,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>水轮机制造厂家</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -265,6 +280,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>发电机制造厂家</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -292,6 +310,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>机组类型</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -319,6 +340,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>流量系数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -346,6 +370,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>额定励磁电流(A)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -380,6 +407,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>压力脉冲显示</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -407,6 +437,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>额定转速(r/min)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -471,6 +504,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>额定功率(MW)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -498,6 +534,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>最大水头(m)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -525,6 +564,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>最小水头(m)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -552,6 +594,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>设计水头(m)</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -579,6 +624,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>叶片数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -606,6 +654,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>导叶数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -633,6 +684,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>上导瓦数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -660,6 +714,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>下导瓦数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -687,6 +744,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>水导瓦数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -714,6 +774,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>推力瓦数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
@ -744,6 +807,9 @@ color: rgb(27, 30, 35);</string>
<property name="text">
<string>发电机转子磁极个数</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>

View File

@ -19,7 +19,7 @@ CWaveDisPlay::CWaveDisPlay(QWidget *parent) :
ui->widget->setProperty("flag", "Title");
ui->widget_4->setProperty("flag", "normal");
ui->widget_wave->plotLayout()->insertRow(0);
QString strTitle = QString("1倍频频率 %1Hz1倍频幅值 %2相位角 %3").arg(0).arg(0).arg(0);
QString strTitle = QString("主频频率 %1 Hz频幅值 %2相位角 %3").arg(0).arg(0).arg(0);
customLogMessageHandler(QtDebugMsg,strTitle);
m_title = new QCPTextElement(ui->widget_wave, strTitle);
ui->widget_wave->plotLayout()->addElement(0, 0, m_title);
@ -287,7 +287,7 @@ void CWaveDisPlay::ParseDataFsWave(QJsonObject & objContent)
//qDebug() << m_ListWaveData << endl;
ui->widget_wave->xAxis->setRange(0, 1);
ui->widget_wave->xAxis->setLabel("Fs(Hz)");
//ui->widget_wave->yAxis->setLabel("um");
ui->widget_wave->yAxis->setLabel(m_ChannelUnit);
QVector<double> x,y;
QCPGraph* graph = ui->widget_wave->addGraph(ui->widget_wave->xAxis, ui->widget_wave->yAxis);
@ -320,8 +320,9 @@ void CWaveDisPlay::ParseDataKeyPhase(QJsonObject& objContent)
double freq1x = objContent["1xfreq"].toDouble();
m_ListKeyPhaseData = data.split(",");
qDebug() << "m_ListKeyPhaseData" << m_ListKeyPhaseData << endl;
QString strTitle = QString("1倍频频率 %1Hz1倍频幅值 %2相位角 %3").arg(freq1x).arg(amp1x).arg(PhaseAngle);
QString strAmp1x = QString::number(amp1x, 'f', 2); // 保留两位小数
QString strPhaseAngle = QString::number(PhaseAngle, 'f', 1);
QString strTitle = QString("主频频率 %1 Hz主频幅值 %2相位角 %3").arg(freq1x).arg(strAmp1x).arg(strPhaseAngle);
customLogMessageHandler(QtDebugMsg,strTitle);
m_title = new QCPTextElement(ui->widget_wave, strTitle);
ui->widget_wave->plotLayout()->addElement(0, 0, m_title);
@ -518,7 +519,7 @@ void CWaveDisPlay::on_comboBox_channel_2_currentTextChanged(const QString &arg1)
m_ChannelID = g_ChannelBaseInfo[i].channelID;
m_ChannelType = g_ChannelBaseInfo[i].channelType;
m_speedRefChannelId = g_ChannelBaseInfo[i].speedRefChannelId;
m_ChannelUnit = g_ChannelBaseInfo[i].sensorEngineeringUnit;
if(ui->Btn_Timewave->isChecked())
{

View File

@ -49,6 +49,7 @@ private:
Ui::CWaveDisPlay *ui;
NetMgr *m_pNetMgr; //HTTP消息类对象
QString m_ChannelID;
QString m_ChannelUnit;
QString m_ChannelType;
QString m_speedRefChannelId;
QString m_WaveData;

View File

@ -0,0 +1,535 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>CWokingConditionConfig</class>
<widget class="QWidget" name="CWokingConditionConfig">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>845</width>
<height>678</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<property name="styleSheet">
<string notr="true">font: 10pt &quot;黑体&quot;;
color: rgb(27, 30, 35);</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QWidget" name="widget" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>50</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>30</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>393</width>
<height>9</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QLabel" name="label_5">
<property name="text">
<string>工况逻辑配置</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>393</width>
<height>9</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_2" native="true">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QWidget" name="widget_3" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QWidget" name="widget_5" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>80</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>30</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>工况名称:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit_workContion"/>
</item>
</layout>
</item>
<item>
<spacer name="horizontalSpacer_6">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>1</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="QLabel" name="label_4">
<property name="text">
<string>工况参数选择:</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBox_unitType">
<property name="minimumSize">
<size>
<width>150</width>
<height>0</height>
</size>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_6" native="true">
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QTableView" name="tableView">
<property name="dragDropMode">
<enum>QAbstractItemView::DragDrop</enum>
</property>
<attribute name="verticalHeaderVisible">
<bool>false</bool>
</attribute>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_7" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>200</height>
</size>
</property>
<widget class="QPushButton" name="pushButton_save">
<property name="geometry">
<rect>
<x>300</x>
<y>130</y>
<width>120</width>
<height>35</height>
</rect>
</property>
<property name="minimumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_save { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_save:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_save:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_save:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>保存</string>
</property>
</widget>
<widget class="QPushButton" name="pushButton_addUnit">
<property name="geometry">
<rect>
<x>40</x>
<y>130</y>
<width>120</width>
<height>35</height>
</rect>
</property>
<property name="minimumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_addUnit { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_addUnit:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_addUnit:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_addUnit:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>添加</string>
</property>
</widget>
<widget class="QPushButton" name="pushButton_del">
<property name="geometry">
<rect>
<x>170</x>
<y>130</y>
<width>120</width>
<height>35</height>
</rect>
</property>
<property name="minimumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_del { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_del:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_del:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_del:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>删除</string>
</property>
</widget>
<widget class="QWidget" name="layoutWidget">
<property name="geometry">
<rect>
<x>21</x>
<y>51</y>
<width>364</width>
<height>52</height>
</rect>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_9">
<item>
<widget class="QLabel" name="label_2">
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>描述:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QTextEdit" name="textEdit_Description">
<property name="minimumSize">
<size>
<width>100</width>
<height>50</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>50</height>
</size>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="layoutWidget">
<property name="geometry">
<rect>
<x>21</x>
<y>10</y>
<width>284</width>
<height>22</height>
</rect>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_8">
<item>
<widget class="QLabel" name="label">
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>工况判定间隔时间:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit_Interval"/>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_4" native="true">
<property name="minimumSize">
<size>
<width>300</width>
<height>0</height>
</size>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QWidget" name="widget_8" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<layout class="QVBoxLayout" name="verticalLayout_5">
<property name="topMargin">
<number>20</number>
</property>
<item>
<widget class="QLabel" name="label_6">
<property name="text">
<string>Relay Logic Editor</string>
</property>
</widget>
</item>
<item>
<widget class="QTreeView" name="treeView">
<property name="dragDropMode">
<enum>QAbstractItemView::DragDrop</enum>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_9" native="true">
<property name="minimumSize">
<size>
<width>0</width>
<height>125</height>
</size>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>27</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QPushButton" name="pushButton_and">
<property name="minimumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_and { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_and:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_and:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_and:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>添加AND</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_5">
<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>
<widget class="QPushButton" name="pushButton_or">
<property name="minimumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>120</width>
<height>35</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_or { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_or:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_or:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_or:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>添加OR</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>27</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<resources/>
<connections/>
</ui>

View File

@ -178,7 +178,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -208,7 +208,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -238,7 +238,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -268,7 +268,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -298,7 +298,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -328,7 +328,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -358,7 +358,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -371,7 +371,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_9">
<property name="text">
<string>蜗壳差压通道</string>
<string>蜗壳差压:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -388,7 +388,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -401,7 +401,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_10">
<property name="text">
<string>机组效率通道</string>
<string>机组效率:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -418,7 +418,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -431,7 +431,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_11">
<property name="text">
<string>发电机出口开关通道</string>
<string>发电机出口开关:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -448,7 +448,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -461,7 +461,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_12">
<property name="text">
<string>励磁开关通道</string>
<string>励磁开关:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -478,7 +478,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -491,7 +491,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_13">
<property name="text">
<string>发电/抽水工况通道</string>
<string>发电/抽水工况:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -508,7 +508,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -521,7 +521,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_14">
<property name="text">
<string>蜗壳进口压力通道</string>
<string>蜗壳进口压力:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -538,7 +538,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -551,7 +551,7 @@ color: rgb(27, 30, 35);</string>
<item>
<widget class="QLabel" name="label_15">
<property name="text">
<string>尾水出口压力通道</string>
<string>尾水出口压力:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -568,7 +568,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>280</width>
<width>150</width>
<height>16777215</height>
</size>
</property>
@ -598,7 +598,7 @@ color: rgb(27, 30, 35);</string>
</property>
<property name="maximumSize">
<size>
<width>240</width>
<width>150</width>
<height>16777215</height>
</size>
</property>

View File

@ -73,6 +73,16 @@ QTableView::item {
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QComboBox" name="comboBox_operate">
<property name="minimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButton_open">
<property name="minimumSize">

View File

@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>812</width>
<height>718</height>
<height>754</height>
</rect>
</property>
<property name="windowTitle">
@ -15,8 +15,7 @@
</property>
<property name="styleSheet">
<string notr="true">font: 10pt &quot;黑体&quot;;
color: rgb(27, 30, 35);
</string>
color: rgb(27, 30, 35);</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
@ -251,7 +250,7 @@ color: rgb(27, 30, 35);
<property name="title">
<string> 通道信息</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_58">
<layout class="QHBoxLayout" name="horizontalLayout_33">
<item>
<spacer name="horizontalSpacer_11">
<property name="orientation">
@ -462,12 +461,9 @@ color: rgb(27, 30, 35);
</spacer>
</item>
<item>
<layout class="QVBoxLayout" name="verticalLayout_17">
<layout class="QVBoxLayout" name="verticalLayout_13">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_11">
<property name="spacing">
<number>1</number>
</property>
<item>
<widget class="QLabel" name="label_12">
<property name="minimumSize">
@ -494,7 +490,7 @@ color: rgb(27, 30, 35);
<widget class="QComboBox" name="pairChannelComBox">
<property name="minimumSize">
<size>
<width>150</width>
<width>0</width>
<height>0</height>
</size>
</property>
@ -514,7 +510,7 @@ color: rgb(27, 30, 35);
</property>
<property name="maximumSize">
<size>
<width>110</width>
<width>100</width>
<height>16777215</height>
</size>
</property>
@ -530,7 +526,7 @@ color: rgb(27, 30, 35);
<widget class="QLineEdit" name="lineEdit_confidenceDegree">
<property name="minimumSize">
<size>
<width>120</width>
<width>0</width>
<height>0</height>
</size>
</property>
@ -543,7 +539,7 @@ color: rgb(27, 30, 35);
<widget class="QLabel" name="label_50">
<property name="minimumSize">
<size>
<width>3</width>
<width>0</width>
<height>0</height>
</size>
</property>
@ -555,7 +551,7 @@ color: rgb(27, 30, 35);
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_55">
<layout class="QHBoxLayout" name="horizontalLayout_30">
<item>
<widget class="QLabel" name="label_49">
<property name="minimumSize">
@ -566,7 +562,7 @@ color: rgb(27, 30, 35);
</property>
<property name="maximumSize">
<size>
<width>110</width>
<width>100</width>
<height>16777215</height>
</size>
</property>
@ -582,7 +578,7 @@ color: rgb(27, 30, 35);
<widget class="QLineEdit" name="lineEdit_sectionNum">
<property name="minimumSize">
<size>
<width>150</width>
<width>0</width>
<height>0</height>
</size>
</property>
@ -635,7 +631,7 @@ color: rgb(27, 30, 35);
<item>
<widget class="QTabWidget" name="tabWidget">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
@ -662,7 +658,7 @@ color: rgb(27, 30, 35);
<property name="minimumSize">
<size>
<width>0</width>
<height>120</height>
<height>135</height>
</size>
</property>
<property name="title">
@ -676,7 +672,7 @@ color: rgb(27, 30, 35);
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
<number>10</number>
</property>
<property name="rightMargin">
<number>0</number>
@ -1258,7 +1254,7 @@ color: rgb(27, 30, 35);
<property name="title">
<string> 采样设置</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_33">
<layout class="QHBoxLayout" name="horizontalLayout_29">
<item>
<layout class="QVBoxLayout" name="verticalLayout_11">
<property name="spacing">
@ -1393,24 +1389,8 @@ color: rgb(27, 30, 35);
</property>
</spacer>
</item>
<item>
<spacer name="horizontalSpacer_7">
<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>
<layout class="QVBoxLayout" name="verticalLayout_12">
<property name="spacing">
<number>1</number>
</property>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_27">
<item>
@ -1495,96 +1475,13 @@ color: rgb(27, 30, 35);
</item>
</layout>
</item>
</layout>
</item>
<item>
<spacer name="horizontalSpacer_8">
<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>
<layout class="QVBoxLayout" name="verticalLayout_13">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_29">
<item>
<widget class="QLabel" name="label_29">
<property name="minimumSize">
<size>
<width>95</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>低通频率:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit_envelopeLowpassband">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>10</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_30">
<item>
<widget class="QLabel" name="label_28">
<property name="minimumSize">
<size>
<width>95</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>高通频率:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit_envelopeHighpassband">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="text">
<string>3500</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_31">
<item>
<widget class="QLabel" name="label_47">
<property name="minimumSize">
<size>
<width>95</width>
<width>100</width>
<height>0</height>
</size>
</property>
@ -1619,6 +1516,48 @@ color: rgb(27, 30, 35);
</item>
</layout>
</item>
<item>
<spacer name="horizontalSpacer_7">
<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>
<widget class="QPushButton" name="pushButton_CustomFilter">
<property name="minimumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>96</width>
<height>28</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">#pushButton_CustomFilter { border-image: url(:/image/Btn/normal_Btn.png);
color:#1f5188 }
#pushButton_CustomFilter:hover { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_CustomFilter:pressed { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}
#pushButton_CustomFilter:checked { border-image: url(:/image/Btn/normal_Btn_p.png);
color:#ffffff}</string>
</property>
<property name="text">
<string>滤波设置</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_17">
<property name="orientation">
@ -2627,6 +2566,19 @@ color: rgb(27, 30, 35);
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
@ -2696,6 +2648,9 @@ color: rgb(27, 30, 35);
<string> 备注</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_18">
<property name="topMargin">
<number>10</number>
</property>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_67">
<item>
@ -2706,13 +2661,13 @@ color: rgb(27, 30, 35);
<widget class="QLabel" name="label_51">
<property name="minimumSize">
<size>
<width>80</width>
<width>85</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>80</width>
<width>85</width>
<height>16777215</height>
</size>
</property>

View File

@ -123,6 +123,7 @@ typedef struct ChannelSetting{
int sectionNum;
QString EngineeringUnit;
QString firstPoleNum;
int filterStatus;
ChannelSetting(){
speedRefChannelId = "";
xZeroScalePosition = "";

View File

@ -21,7 +21,7 @@ MainWindow::MainWindow(QWidget *parent) :
//读取ini
QSettings settingsread(QCoreApplication::applicationDirPath() + "\\config\\config.ini",QSettings::IniFormat);
g_strVersion = settingsread.value("main/Version").toString();
g_strVersion = "SJ90C V1.1";
g_strProject = settingsread.value("main/Project").toString();
g_strFre = settingsread.value("main/Fre").toString();

View File

@ -6,7 +6,7 @@ qproperty-backgroundBrush:#f2f4f7;
}
QWidget[form="true"],QLabel[frameShape="1"]{
border:1px solid #242424;
border:1px solid #f2f4f7;
border-radius:0px;
}
@ -20,7 +20,7 @@ border:1px solid #f2f4f7;
QWidget[form="bottom"] QLabel,QWidget[form="title"] QLabel{
border-radius:0px;
color:#f2f4f7;
color:#484848;
background:none;
border-style:none;
}
@ -108,9 +108,25 @@ background:none;
selection-background-color:#AAAAAA;
selection-color:#ffffff;
}
QComboBox,QTextEdit,QLineEdit,QTimeEdit{
color:#666666;
font-size:14px;
padding: 1px 15px 1px 3px;
border:1px solid rgba(228,228,228,1);
border-radius:5px 5px 0px 0px;
height:20px;
}
QComboBox:disabled,QTextEdit:disabled,QLineEdit:disabled,QTimeEdit:disabled{
color:#666666;
font-size:14px;
padding: 1px 15px 1px 3px;
border:1px solid rgba(228,228,228,1);
border-radius:5px 5px 0px 0px;
height:20px;
}
QLineEdit:focus,QTextEdit:focus,QPlainTextEdit:focus,QSpinBox:focus,QDoubleSpinBox:focus,QComboBox:focus,QDateEdit:focus,QTimeEdit:focus,QDateTimeEdit:focus,QLineEdit:hover,QTextEdit:hover,QPlainTextEdit:hover,QSpinBox:hover,QDoubleSpinBox:hover,QComboBox:hover,QDateEdit:hover,QTimeEdit:hover,QDateTimeEdit:hover{
border:1px solid #242424;
border:1px solid #245d9b;
}
QLineEdit[echoMode="2"]{
@ -123,9 +139,15 @@ border-radius:3px;
}
.QGroupBox{
border:1px solid #242424;
/*border:1px solid #242424;
border-radius:5px;
margin-top:9px;
margin-top:9px;*/
color:#666666;
font-size:14px;
padding: 1px 15px 1px 3px;
border:1px solid rgba(228,228,228,1);
border-radius:5px 5px 0px 0px;
height:20px;
}
.QGroupBox::title{
@ -297,7 +319,7 @@ border-left-width:0px;
border-left-style:solid;
border-top-right-radius:3px;
border-bottom-right-radius:3px;
border-left-color:#242424;
border-left-color:#409CE1;
}
QComboBox::drop-down:on{

View File

@ -69,7 +69,15 @@ int SqliteDB::initTable()
.arg("sqlite_master").arg("t_TriggerConfig").arg("operate");
iRet = ExeSqlData(strSql);
if(iRet == 0){
strSql = "ALTER TABLE t_TriggerConfig ADD COLUMN 'operate' integer";
strSql = "ALTER TABLE t_TriggerConfig ADD COLUMN 'operate' integer DEFAULT 1";
ExeSqlData(strSql);
}
strSql = QString("select count(*) from %1 where name = '%2' and sql LIKE '%%3%' ")\
.arg("sqlite_master").arg("t_ChannelSetting").arg("filterStatus");
iRet = ExeSqlData(strSql);
if(iRet == 0){
strSql = "ALTER TABLE t_ChannelSetting ADD COLUMN 'filterStatus' integer";
ExeSqlData(strSql);
}
@ -261,6 +269,7 @@ QVector<ChannelSetting> SqliteDB::GetDataMultiLine(QString tablename, QString co
tempchannel.sectionNum = sql_query.value(97).toInt();
tempchannel.EngineeringUnit = sql_query.value(98).toString();
tempchannel.firstPoleNum = sql_query.value(99).toString();
tempchannel.filterStatus = sql_query.value(100).toInt();
vecResult.append(tempchannel);
}
}