Complete Qt6 migration: full clean build green across groups G1-G12 incl. runtime plugin set
new_docker_build.sh gains Group 12 (212 GUI/Data plugins); fixes LtsUtilsGuiDds visibility (LTO-stripped exports), LtsProjectionWorkstation unity name shadow, 6 unity-off dirs (dup file-scope statics, ddsftc INTERFACE sources) and reconfigures BUILD_FILTERMANAGEMENT/BUILD_PLUGINS_SERVICEMONITOR=ON
This commit is contained in:
1718 files changed
+126739
-18495
No files matched your search
+28
-27
@@ -26,6 +26,7 @@ NotificationManagementDialog::NotificationManagementDialog(LtsSession::LtsSessio
|
||||
, m_session(session)
|
||||
, m_menuGroup(menuGroup)
|
||||
, m_requestHelper(new LtsUtils::RequestHelper(this))
|
||||
, m_logger(getLogger("NotificationManagementDialog"))
|
||||
{
|
||||
m_ui->setupUi(this);
|
||||
m_ui->widget->setSelectionMode(QAbstractItemView::ExtendedSelection);
|
||||
@@ -85,23 +86,23 @@ void NotificationManagementDialog::onAcknowledgeNotification()
|
||||
int operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
int workstationId = LtsSessionData::LtsSessionData::getInstance()->getWorkstationId();
|
||||
|
||||
for (const auto &addr : noti.recipientIds())
|
||||
for (const auto &addr : noti.recipientIds)
|
||||
{
|
||||
if ((addr.addressType() == AddressType::Operator && addr.addressId() == operatorId)
|
||||
|| (addr.addressType() == AddressType::Workstation && addr.addressId() == workstationId))
|
||||
if ((addr.addressType == AddressType::Operator && addr.addressId == operatorId)
|
||||
|| (addr.addressType == AddressType::Workstation && addr.addressId == workstationId))
|
||||
{
|
||||
request.addressId(addr.id());
|
||||
request.addressId = addr.id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
request.operatorId(operatorId);
|
||||
request.workstationId(workstationId);
|
||||
request.operatorId = operatorId;
|
||||
request.workstationId = workstationId;
|
||||
|
||||
bool onlyNotYetAcknowledged = true;
|
||||
request.notificationIds(selectedNotificationIds(onlyNotYetAcknowledged));
|
||||
if (request.notificationIds().empty())
|
||||
request.notificationIds = selectedNotificationIds(onlyNotYetAcknowledged);
|
||||
if (request.notificationIds.empty())
|
||||
return;
|
||||
request.processed(true);
|
||||
request.processed = true;
|
||||
|
||||
m_requestHelper->setCustomWaitMessage(tr("Marking notification as read"));
|
||||
m_requestHelper->startSingleRequest(
|
||||
@@ -123,11 +124,11 @@ std::vector<int32_t> NotificationManagementDialog::selectedNotificationIds(bool
|
||||
|
||||
|
||||
|
||||
if (onlyNotYetAcknowledged && noti.processed())
|
||||
if (onlyNotYetAcknowledged && noti.processed)
|
||||
continue;
|
||||
|
||||
|
||||
notificationIds.emplace_back(noti.id());
|
||||
|
||||
notificationIds.emplace_back(noti.id);
|
||||
}
|
||||
|
||||
return notificationIds;
|
||||
@@ -143,20 +144,20 @@ void NotificationManagementDialog::onRemoveNotification()
|
||||
const int operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
const int workstationId = LtsSessionData::LtsSessionData::getInstance()->getWorkstationId();
|
||||
|
||||
for (const auto &addr : noti.recipientIds())
|
||||
for (const auto &addr : noti.recipientIds)
|
||||
{
|
||||
if ((addr.addressType() == AddressType::Operator && addr.addressId() == operatorId)
|
||||
|| (addr.addressType() == AddressType::Workstation && addr.addressId() == workstationId))
|
||||
if ((addr.addressType == AddressType::Operator && addr.addressId == operatorId)
|
||||
|| (addr.addressType == AddressType::Workstation && addr.addressId == workstationId))
|
||||
{
|
||||
request.addressId(addr.id());
|
||||
request.addressId = addr.id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
request.operatorId(operatorId);
|
||||
request.workstationId(workstationId);
|
||||
request.operatorId = operatorId;
|
||||
request.workstationId = workstationId;
|
||||
|
||||
bool acknowledge = false;
|
||||
request.notificationIds(selectedNotificationIds(acknowledge));
|
||||
request.notificationIds = selectedNotificationIds(acknowledge);
|
||||
|
||||
m_requestHelper->setCustomWaitMessage(tr("Delete message"));
|
||||
m_requestHelper->startSingleRequest(
|
||||
@@ -184,15 +185,15 @@ void NotificationManagementDialog::onShowNotificationContent()
|
||||
const QModelIndex curIdx = m_ui->widget->currentIndex();
|
||||
const NomNotification ¬i = m_model->getRowData(curIdx.row());
|
||||
|
||||
QString content = QCoreApplication::translate("Notification", noti.content().c_str());
|
||||
QString content = QCoreApplication::translate("Notification", noti.content.c_str());
|
||||
|
||||
NomNotification notiDDS = m_dtc->nomNotification(noti.id());
|
||||
NomNotification notiDDS = m_dtc->nomNotification(noti.id);
|
||||
DEBUG_LOG(m_logger) << "onShowNotificationContent"
|
||||
<< ", content=" << noti.content()
|
||||
<< ", contentArgs().size()=" << noti.contentArgs().size()
|
||||
<< ", notiDDS.contentArgs().size()=" << notiDDS.contentArgs().size();
|
||||
<< ", content=" << noti.content
|
||||
<< ", contentArgs().size()=" << noti.contentArgs.size()
|
||||
<< ", notiDDS.contentArgs().size()=" << notiDDS.contentArgs.size();
|
||||
|
||||
for (const std::string& arg : notiDDS.contentArgs()) {
|
||||
for (const std::string& arg : notiDDS.contentArgs) {
|
||||
|
||||
content = content.arg(QString::fromStdString(arg));
|
||||
DEBUG_LOG(m_logger) << ".arg() ersetzt immer den kleinsten freien Platzhalter"
|
||||
@@ -223,11 +224,11 @@ void NotificationManagementDialog::onShowNotificationContent()
|
||||
QFont font;
|
||||
font.setBold(true);
|
||||
|
||||
QLabel *lblTitle = new QLabel(QCoreApplication::translate("Notification", noti.title().c_str()), contentPopup);
|
||||
QLabel *lblTitle = new QLabel(QCoreApplication::translate("Notification", noti.title.c_str()), contentPopup);
|
||||
lblTitle->setFont(font);
|
||||
QLabel *lblFrom = new QLabel(tr("From: "));
|
||||
lblFrom->setFont(font);
|
||||
QLabel *lblSender = new QLabel(QString::fromStdString(noti.sender().name()));
|
||||
QLabel *lblSender = new QLabel(QString::fromStdString(noti.sender.name));
|
||||
|
||||
QFrame *line = new QFrame(this);
|
||||
line->setFrameShape(QFrame::HLine);
|
||||
|
||||
+37
-36
@@ -30,6 +30,7 @@ NotificationManagementDialogModel::NotificationManagementDialogModel(QObject *pa
|
||||
parent)
|
||||
, m_dtc(nullptr)
|
||||
, m_ftc(nullptr)
|
||||
, m_logger(getLogger("NotificationManagementDialogModel"))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -56,11 +57,11 @@ bool NotificationManagementDialogModel::initModel(const LtsSession::LtsSessionDa
|
||||
return true;
|
||||
}
|
||||
|
||||
int NotificationManagementDialogModel::getId(const NotificationManagement::NomNotification &data) const { return data.id(); }
|
||||
int NotificationManagementDialogModel::getId(const NotificationManagement::NomNotification &data) const { return data.id; }
|
||||
|
||||
QVariant NotificationManagementDialogModel::data(const QModelIndex &index, int role) const
|
||||
{
|
||||
if ((role != Qt::DisplayRole && role != Qt::UserRole && role != Qt::TextColorRole && role != Qt::FontRole) || !indexIsValid(index))
|
||||
if ((role != Qt::DisplayRole && role != Qt::UserRole && role != Qt::ForegroundRole && role != Qt::FontRole) || !indexIsValid(index))
|
||||
return QVariant();
|
||||
|
||||
const NotificationManagement::NomNotification ¬i = m_vecData.at(index.row());
|
||||
@@ -68,15 +69,15 @@ QVariant NotificationManagementDialogModel::data(const QModelIndex &index, int r
|
||||
if (role == Qt::FontRole)
|
||||
{
|
||||
bool setBold = false;
|
||||
for (const auto &addr : noti.recipientIds())
|
||||
for (const auto &addr : noti.recipientIds)
|
||||
{
|
||||
if (addr.addressType() == AddressType::Operator && addr.addressId() != m_operatorId)
|
||||
if (addr.addressType == AddressType::Operator && addr.addressId != m_operatorId)
|
||||
continue;
|
||||
|
||||
if (addr.addressType() == AddressType::Workstation && addr.addressId() != m_workstationId)
|
||||
if (addr.addressType == AddressType::Workstation && addr.addressId != m_workstationId)
|
||||
continue;
|
||||
|
||||
if (!noti.processed())
|
||||
if (!noti.processed)
|
||||
setBold = true;
|
||||
break;
|
||||
}
|
||||
@@ -93,15 +94,15 @@ QVariant NotificationManagementDialogModel::data(const QModelIndex &index, int r
|
||||
switch (index.column())
|
||||
{
|
||||
case NotificationManagementDialogModel::Columns::Id:
|
||||
return noti.id();
|
||||
return noti.id;
|
||||
case NotificationManagementDialogModel::Columns::Title:
|
||||
return QCoreApplication::translate("Notification", noti.title().c_str());
|
||||
return QCoreApplication::translate("Notification", noti.title.c_str());
|
||||
case NotificationManagementDialogModel::Columns::Content:
|
||||
{
|
||||
QString text = QCoreApplication::translate("Notification", noti.content().c_str());
|
||||
QString text = QCoreApplication::translate("Notification", noti.content.c_str());
|
||||
|
||||
for (const std::string& arg : noti.contentArgs) {
|
||||
|
||||
for (const std::string& arg : noti.contentArgs()) {
|
||||
|
||||
text = text.arg(QString::fromStdString(arg));
|
||||
}
|
||||
|
||||
@@ -109,22 +110,22 @@ QVariant NotificationManagementDialogModel::data(const QModelIndex &index, int r
|
||||
}
|
||||
|
||||
case NotificationManagementDialogModel::Columns::Timestamp:
|
||||
return QDateTime::fromMSecsSinceEpoch(noti.timeStamp());
|
||||
return QDateTime::fromMSecsSinceEpoch(noti.timeStamp);
|
||||
case NotificationManagementDialogModel::Columns::Priority:
|
||||
return NotificationManagement::toString(noti.priority().underlying());
|
||||
return NotificationManagement::toString(noti.priority);
|
||||
case NotificationManagementDialogModel::Columns::ProcessedBy:
|
||||
return getNameByAddressId(noti.processed(), noti.recipientIds());
|
||||
return getNameByAddressId(noti.processed, noti.recipientIds);
|
||||
case NotificationManagementDialogModel::Columns::ProcessTime:
|
||||
return QDateTime::fromMSecsSinceEpoch(noti.processTime());
|
||||
return QDateTime::fromMSecsSinceEpoch(noti.processTime);
|
||||
case NotificationManagementDialogModel::Columns::Sender:
|
||||
return QString::fromStdString(noti.sender().name());
|
||||
return QString::fromStdString(noti.sender.name);
|
||||
}
|
||||
}
|
||||
else if (role == Qt::TextColorRole)
|
||||
else if (role == Qt::ForegroundRole)
|
||||
{
|
||||
if (index.column() == NotificationManagementDialogModel::Columns::Priority)
|
||||
{
|
||||
switch (noti.priority().underlying())
|
||||
switch (noti.priority)
|
||||
{
|
||||
case NotificationManagement::Priority::Low:
|
||||
return QColor(Qt::black);
|
||||
@@ -145,18 +146,18 @@ bool NotificationManagementDialogModel::isFiltered(const NotificationManagement:
|
||||
if (modType == DataModification::eRemoved)
|
||||
return false;
|
||||
|
||||
if (data.exerciseId() != m_exerciseId && data.exerciseId() != 0)
|
||||
if (data.exerciseId != m_exerciseId && data.exerciseId != 0)
|
||||
return true;
|
||||
|
||||
|
||||
|
||||
bool isFiltered = true;
|
||||
for (const auto &addr : data.recipientIds())
|
||||
for (const auto &addr : data.recipientIds)
|
||||
{
|
||||
if (addr.addressType() == AddressType::Workstation)
|
||||
if (addr.addressId() != m_workstationId)
|
||||
if (addr.addressType == AddressType::Workstation)
|
||||
if (addr.addressId != m_workstationId)
|
||||
continue;
|
||||
if (addr.addressType() == AddressType::Operator)
|
||||
if (addr.addressId() != m_operatorId)
|
||||
if (addr.addressType == AddressType::Operator)
|
||||
if (addr.addressId != m_operatorId)
|
||||
continue;
|
||||
|
||||
isFiltered = false;
|
||||
@@ -168,13 +169,13 @@ bool NotificationManagementDialogModel::isFiltered(const NotificationManagement:
|
||||
|
||||
int NotificationManagementDialogModel::isDeleted(const NomNotification &data) const
|
||||
{
|
||||
for (const auto &addr : data.recipientIds())
|
||||
for (const auto &addr : data.recipientIds)
|
||||
{
|
||||
if (addr.addressType() == AddressType::Operator)
|
||||
if (addr.addressType == AddressType::Operator)
|
||||
{
|
||||
if (addr.addressId() != m_operatorId)
|
||||
if (addr.addressId != m_operatorId)
|
||||
continue;
|
||||
if (addr.isDeleted())
|
||||
if (addr.isDeleted)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -185,16 +186,16 @@ QString NotificationManagementDialogModel::getNameByAddressId(int addressId, con
|
||||
{
|
||||
for (const auto &addr : recipients)
|
||||
{
|
||||
if (addr.id() == addressId)
|
||||
if (addr.id == addressId)
|
||||
{
|
||||
if (addr.addressType() == AddressType::Operator)
|
||||
if (addr.addressType == AddressType::Operator)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "addressId=" << addressId
|
||||
<< ", addr.addressId()).name()=" << QString::fromStdString(m_dtcOpm->user(addr.addressId()).name());
|
||||
return QString::fromStdString(m_dtcOpm->user(addr.addressId()).name());
|
||||
<< ", addr.addressId()).name()=" << QString::fromStdString(m_dtcOpm->user(addr.addressId).name);
|
||||
return QString::fromStdString(m_dtcOpm->user(addr.addressId).name);
|
||||
}
|
||||
if (addr.addressType() == AddressType::Workstation)
|
||||
return QString::fromStdString(m_dtcAsm->asset(addr.addressId()).name());
|
||||
if (addr.addressType == AddressType::Workstation)
|
||||
return QString::fromStdString(m_dtcAsm->asset(addr.addressId).name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -218,7 +219,7 @@ bool NotificationDialogProxyModel::lessThan(const QModelIndex &source_left, cons
|
||||
switch (source_left.column())
|
||||
{
|
||||
case NotificationManagementDialogModel::Timestamp:
|
||||
return dataLeft.timeStamp() < dataRight.timeStamp();
|
||||
return dataLeft.timeStamp < dataRight.timeStamp;
|
||||
|
||||
case NotificationManagementDialogModel::Content:
|
||||
case NotificationManagementDialogModel::isRead:
|
||||
|
||||
+48
-48
@@ -37,13 +37,13 @@ InterfaceImpl::~InterfaceImpl() {}
|
||||
int InterfaceImpl::isDeleted(const NomNotification &data) const
|
||||
{
|
||||
int operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
for (const auto &addr : data.recipientIds())
|
||||
for (const auto &addr : data.recipientIds)
|
||||
{
|
||||
if (addr.addressType() == AddressType::Operator)
|
||||
if (addr.addressType == AddressType::Operator)
|
||||
{
|
||||
if (addr.addressId() != operatorId)
|
||||
if (addr.addressId != operatorId)
|
||||
continue;
|
||||
if (addr.isDeleted())
|
||||
if (addr.isDeleted)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -87,7 +87,7 @@ bool InterfaceImpl::eventFilter(QObject *watched, QEvent *event)
|
||||
if(ev->url().host().toLower() == QStringLiteral("notificationack") && id > 0)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "ack";
|
||||
ack(m_nomNotifications.value(m_nomNotifications.value(id).id()));
|
||||
ack(m_nomNotifications.value(m_nomNotifications.value(id).id));
|
||||
}
|
||||
|
||||
DEBUG_LOG(m_logger) << "ev->url().host()=" << ev->url().host();
|
||||
@@ -106,20 +106,20 @@ bool InterfaceImpl::eventFilter(QObject *watched, QEvent *event)
|
||||
|
||||
void InterfaceImpl::onNotificationChanged(const NotificationManagement::NomNotification ¬i, DataModification modType)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "onNotificationChanged title=" << noti.title()
|
||||
<< ", content =" << noti.content()
|
||||
<< ", args.size=" << noti.contentArgs().size()
|
||||
DEBUG_LOG(m_logger) << "onNotificationChanged title=" << noti.title
|
||||
<< ", content =" << noti.content
|
||||
<< ", args.size=" << noti.contentArgs.size()
|
||||
<< ", modType=" << modType;
|
||||
if (noti.exerciseId() != m_session->exerciseId())
|
||||
if (noti.exerciseId != m_session->exerciseId())
|
||||
return;
|
||||
|
||||
if (!isMyMessage(noti.recipientIds()))
|
||||
if (!isMyMessage(noti.recipientIds))
|
||||
return;
|
||||
const QString notiIdent = QCoreApplication::translate("Notification", noti.title().c_str()) + QString::number(noti.id());
|
||||
const QString notiIdent = QCoreApplication::translate("Notification", noti.title.c_str()) + QString::number(noti.id);
|
||||
|
||||
if (isDeleted(noti))
|
||||
{
|
||||
m_unreadMessages.remove(noti.id());
|
||||
m_unreadMessages.remove(noti.id);
|
||||
updateUnreadCount();
|
||||
if (m_session->baseLayout()->messageIdentifierExists(notiIdent))
|
||||
{
|
||||
@@ -130,37 +130,37 @@ void InterfaceImpl::onNotificationChanged(const NotificationManagement::NomNotif
|
||||
|
||||
NomNotification localNoti = noti;
|
||||
|
||||
QString content = QCoreApplication::translate("Notification", localNoti.content().c_str());
|
||||
QString content = QCoreApplication::translate("Notification", localNoti.content.c_str());
|
||||
|
||||
for (const std::string& arg : noti.contentArgs())
|
||||
for (const std::string& arg : noti.contentArgs)
|
||||
{
|
||||
|
||||
|
||||
content = content.arg(QString::fromStdString(arg));
|
||||
DEBUG_LOG(m_logger) << ".arg() ersetzt immer den kleinsten freien Platzhalter"
|
||||
<< ", arg=" << arg
|
||||
<< ", content=" << content;
|
||||
}
|
||||
|
||||
localNoti.content(content.toStdString());
|
||||
localNoti.content = content.toStdString();
|
||||
|
||||
m_nomNotifications.insert(noti.id(), localNoti);
|
||||
m_nomNotifications.insert(noti.id, localNoti);
|
||||
|
||||
|
||||
if (noti.processed() <= 0 && (modType == DataModification::eAdded || modType == DataModification::eModified))
|
||||
if (noti.processed <= 0 && (modType == DataModification::eAdded || modType == DataModification::eModified))
|
||||
{
|
||||
|
||||
if (m_unreadMessages.contains(noti.id()) && noti.priority() < Priority::Normal)
|
||||
if (m_unreadMessages.contains(noti.id) && noti.priority < Priority::Normal)
|
||||
{
|
||||
m_unreadMessages.remove(noti.id());
|
||||
m_unreadMessages.remove(noti.id);
|
||||
}
|
||||
|
||||
if (!m_unreadMessages.contains(noti.id()))
|
||||
if (!m_unreadMessages.contains(noti.id))
|
||||
{
|
||||
m_unreadMessages.insert(noti.id());
|
||||
m_unreadMessages.insert(noti.id);
|
||||
|
||||
QString content = QString::fromStdString(localNoti.content());
|
||||
QString content = QString::fromStdString(localNoti.content);
|
||||
|
||||
for (const std::string& arg : noti.contentArgs()) {
|
||||
for (const std::string& arg : noti.contentArgs) {
|
||||
content = content.arg(QString::fromStdString(arg));
|
||||
}
|
||||
|
||||
@@ -175,20 +175,20 @@ void InterfaceImpl::onNotificationChanged(const NotificationManagement::NomNotif
|
||||
content = content.replace(QStringLiteral("[%1](%2)").arg(it.value(), it.key()), QStringLiteral("<a href='%1'>%2</a>").arg(it.key(), it.value()));
|
||||
}
|
||||
const QString openMessageLink(QStringLiteral("OpenMessages"));
|
||||
const LtsWidgets::LtsNotificationBox::MessageType messageType = static_cast<LtsWidgets::LtsNotificationBox::MessageType>(noti.messageType().underlying());
|
||||
|
||||
if (noti.priority() == Priority::High)
|
||||
const LtsWidgets::LtsNotificationBox::MessageType messageType = static_cast<LtsWidgets::LtsNotificationBox::MessageType>(static_cast<int>(noti.messageType));
|
||||
|
||||
if (noti.priority == Priority::High)
|
||||
{
|
||||
m_session->baseLayout()->showMessage(
|
||||
QCoreApplication::translate("Notification", noti.title().c_str()),
|
||||
QCoreApplication::translate("Notification", noti.title.c_str()),
|
||||
content,
|
||||
messageType,
|
||||
[this, linkMap, noti](const QString &link)
|
||||
{
|
||||
Q_UNUSED(link)
|
||||
|
||||
|
||||
if (!noti.processed())
|
||||
|
||||
|
||||
if (!noti.processed)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "ack";
|
||||
ack(noti);
|
||||
@@ -198,18 +198,18 @@ void InterfaceImpl::onNotificationChanged(const NotificationManagement::NomNotif
|
||||
notiIdent);
|
||||
m_session->baseLayout()->installEventFilter(this);
|
||||
}
|
||||
else if (noti.priority() == Priority::Highest)
|
||||
else if (noti.priority == Priority::Highest)
|
||||
{
|
||||
|
||||
|
||||
for (const auto &link : linkMap.keys())
|
||||
{
|
||||
auto *event = new LtsWidgets::LtsLinkEvent(QUrl(link), m_session->baseLayout());
|
||||
event->setAccepted(false);
|
||||
DEBUG_LOG(m_logger) << "Post event" << event << " " << event->url().toString();
|
||||
QApplication::postEvent(qApp, event);
|
||||
QApplication::postEvent(qApp, event);
|
||||
}
|
||||
|
||||
if (!noti.processed())
|
||||
|
||||
if (!noti.processed)
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "ack";
|
||||
ack(noti);
|
||||
@@ -218,9 +218,9 @@ void InterfaceImpl::onNotificationChanged(const NotificationManagement::NomNotif
|
||||
}
|
||||
}
|
||||
|
||||
if ((noti.processed() && (modType == DataModification::eModified)) || modType == DataModification::eRemoved)
|
||||
if ((noti.processed && (modType == DataModification::eModified)) || modType == DataModification::eRemoved)
|
||||
{
|
||||
m_unreadMessages.remove(noti.id());
|
||||
m_unreadMessages.remove(noti.id);
|
||||
|
||||
if (m_session->baseLayout()->messageIdentifierExists(notiIdent))
|
||||
{
|
||||
@@ -340,20 +340,20 @@ void InterfaceImpl::ack(const NotificationManagement::NomNotification ¬ificat
|
||||
int operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
|
||||
int workstationId = LtsSessionData::LtsSessionData::getInstance()->getWorkstationId();
|
||||
for (const auto &addr : notification.recipientIds())
|
||||
for (const auto &addr : notification.recipientIds)
|
||||
{
|
||||
if ((addr.addressType() == AddressType::Operator && addr.addressId() == operatorId)
|
||||
|| (addr.addressType() == AddressType::Workstation && addr.addressId() == workstationId))
|
||||
if ((addr.addressType == AddressType::Operator && addr.addressId == operatorId)
|
||||
|| (addr.addressType == AddressType::Workstation && addr.addressId == workstationId))
|
||||
{
|
||||
request.addressId(addr.id());
|
||||
request.addressId = addr.id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
request.operatorId(operatorId);
|
||||
request.workstationId(workstationId);
|
||||
request.operatorId = operatorId;
|
||||
request.workstationId = workstationId;
|
||||
|
||||
request.notificationIds({notification.id()});
|
||||
request.processed(!notification.processed());
|
||||
request.notificationIds = {notification.id};
|
||||
request.processed = !notification.processed;
|
||||
DEBUG_LOG(m_logger) << "m_ftc->readReceipt ";
|
||||
m_ftc->readReceiptRequest(request, this);
|
||||
}
|
||||
@@ -369,11 +369,11 @@ bool InterfaceImpl::isMyMessage(const std::vector<Address> &recipents)
|
||||
while (it != recipents.end())
|
||||
{
|
||||
|
||||
if (it->addressType() == AddressType::Operator && it->addressId() == LtsSessionData::LtsSessionData::getInstance()->getOperatorId())
|
||||
if (it->addressType == AddressType::Operator && it->addressId == LtsSessionData::LtsSessionData::getInstance()->getOperatorId())
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else if (it->addressType() == AddressType::Workstation && it->addressId() == LtsSessionData::LtsSessionData::getInstance()->getWorkstationId())
|
||||
else if (it->addressType == AddressType::Workstation && it->addressId == LtsSessionData::LtsSessionData::getInstance()->getWorkstationId())
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user