Adds immediate migration results in progress
This commit is contained in:
2102 files changed
+17482
-15071
No files matched your search
+3
-4
@@ -99,10 +99,9 @@ void DetailedChartModel::onDynamicParticipantDataChanged(const ParticipantManage
|
||||
emit dataChanged(index(0, 0), index(rowCount() - 1, columnCount() - 1));
|
||||
}
|
||||
|
||||
DetailedChartModel::DetailedChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent)
|
||||
: AbstractChartModel(config, parent)
|
||||
.getNGLLogger("OnlineReportDetailedChartModel"))
|
||||
{
|
||||
DetailedChartModel::DetailedChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent) : AbstractChartModel(config, parent)
|
||||
.getNGLLogger("OnlineReportDetailedChartModel")),
|
||||
m_logger(NGL::NGLLoggerBootstrap::getLogger()) {
|
||||
m_participantStates.insert(ProjectDataManagement::VulnerabilityState::CombatReady, QSet<int32_t>());
|
||||
m_participantStates.insert(ProjectDataManagement::VulnerabilityState::LightDamage, QSet<int32_t>());
|
||||
m_participantStates.insert(ProjectDataManagement::VulnerabilityState::MediumDamage, QSet<int32_t>());
|
||||
|
||||
+2
@@ -24,6 +24,8 @@ private Q_SLOTS:
|
||||
void onDynamicParticipantDataChanged(const ParticipantManagement::DynamicParticipantData &data, DataModification modType);
|
||||
|
||||
private:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
explicit DetailedChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent);
|
||||
|
||||
private:
|
||||
|
||||
+5
-6
@@ -61,8 +61,8 @@ void SimpleChartModel::onDynamicParticipantDataChanged(const ParticipantManageme
|
||||
|
||||
const ParticipantManagement::StateInformation &stateInfo = m_config.ppmDtc->youngestStateInformation(data.stateHistory());
|
||||
|
||||
DEBUG_LOG() << "Participant id = " << data.participantId();
|
||||
DEBUG_LOG() << "State Info Vulnerability = " << stateInfo.vulnerabilityState();
|
||||
DEBUG_LOG(m_logger) << "Participant id = " << data.participantId();
|
||||
DEBUG_LOG(m_logger) << "State Info Vulnerability = " << stateInfo.vulnerabilityState();
|
||||
|
||||
if (stateInfo.vulnerabilityState() < ProjectDataManagement::VulnerabilityState::CatastrophicKill)
|
||||
setCombatReady(data.participantId());
|
||||
@@ -72,10 +72,9 @@ void SimpleChartModel::onDynamicParticipantDataChanged(const ParticipantManageme
|
||||
emit dataChanged(index(0, 0), index(rowCount() - 1, columnCount() - 1));
|
||||
}
|
||||
|
||||
SimpleChartModel::SimpleChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent)
|
||||
: AbstractChartModel(config, parent)
|
||||
.getNGLLogger("OnlineReportSimpleChartModel"))
|
||||
{
|
||||
SimpleChartModel::SimpleChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent) : AbstractChartModel(config, parent)
|
||||
.getNGLLogger("OnlineReportSimpleChartModel")),
|
||||
m_logger(NGL::NGLLoggerBootstrap::getLogger()) {
|
||||
auto cb = [this](const ParticipantManagement::DynamicParticipantData & data)
|
||||
{
|
||||
if (!m_config.participantIds.contains(data.participantId()))
|
||||
|
||||
+2
@@ -24,6 +24,8 @@ private Q_SLOTS:
|
||||
void onDynamicParticipantDataChanged(const ParticipantManagement::DynamicParticipantData &data, DataModification modType);
|
||||
|
||||
private:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
explicit SimpleChartModel(const AbstractChartModel::ChartConfig &config, QObject *parent);
|
||||
|
||||
void setCombatReady(int32_t participantId);
|
||||
|
||||
+2
-2
@@ -184,7 +184,7 @@ bool CreateReportDialog::apply()
|
||||
m_ppmDtc,
|
||||
participantIds);
|
||||
|
||||
DEBUG_LOG() << "Creating new ReportDialog with config: "
|
||||
DEBUG_LOG(m_logger) << "Creating new ReportDialog with config: "
|
||||
<< chartConfig.toJson().toJson();
|
||||
ReportDialog *dialog = new ReportDialog(chartConfig, this);
|
||||
|
||||
@@ -215,7 +215,7 @@ void CreateReportDialog::setChildrenSelected(const QModelIndex &parent)
|
||||
if (m_participantModel->hasChildren(childIndex))
|
||||
setChildrenSelected(childIndex);
|
||||
|
||||
DEBUG_LOG() << "Setting row "
|
||||
DEBUG_LOG(m_logger) << "Setting row "
|
||||
<< childIndex.row()
|
||||
<< " selected";
|
||||
|
||||
|
||||
+2
@@ -43,6 +43,8 @@ private slots:
|
||||
void onRemoveName(const QString &name);
|
||||
|
||||
private:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
bool apply() override;
|
||||
void retranslate() override;
|
||||
void setChildrenSelected(const QModelIndex &parent);
|
||||
|
||||
+2
-2
@@ -37,7 +37,7 @@ ReportDialog::ReportDialog(const AbstractChartModel::ChartConfig &config, QWidge
|
||||
{
|
||||
QString errorStr = tr("Not possible to draw diagram. There are no participants to be looked at");
|
||||
m_ui->verticalLayout->addWidget(new QLabel(errorStr, this));
|
||||
ERROR_LOG() << errorStr;
|
||||
ERROR_LOG(m_logger) << errorStr;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -152,7 +152,7 @@ KDChart::Chart *ReportDialog::createNewChart(const AbstractChartModel::ChartConf
|
||||
|
||||
if (!diagram)
|
||||
{
|
||||
ERROR_LOG() << "Got unkown chart type. Aborting.";
|
||||
ERROR_LOG(m_logger) << "Got unkown chart type. Aborting.";
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
+2
@@ -35,6 +35,8 @@ Q_SIGNALS:
|
||||
void removeName(const QString &name);
|
||||
|
||||
private:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
void retranslate() override;
|
||||
static QVector<QBrush> brushes(const AbstractChartModel::ChartConfig &config);
|
||||
KDChart::Chart *createNewChart(const AbstractChartModel::ChartConfig &config, const QPen &linePen, bool hasToCreateLegend, const QString &header = QString());
|
||||
|
||||
+2
@@ -20,6 +20,8 @@ public:
|
||||
QVariant data(const QModelIndex &index, int role) const override;
|
||||
|
||||
protected:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
bool isFiltered(const ParticipantManagement::Type &data, DataModification modType) const override;
|
||||
private:
|
||||
std::shared_ptr<ParticipantManagement::Interface::Dtc> m_ppmDtc;
|
||||
|
||||
Reference in new issue
Block a user