The calculation of how many harvest shares are expected in total.

This commit is contained in:
2026-02-21 22:54:59 +01:00
parent 6b383b8f55
commit d800ecfed7
7 changed files with 71 additions and 3 deletions

View File

@ -10,6 +10,8 @@ ModelSummary::ModelSummary(std::shared_ptr<TableModel> model, QObject* parent)
// TODO ? use existing model signals (dataChanged(role),...) instead of special signals
connect(m_model.get(), &TableModel::nExpectedBiddingsChanged, this,
&ModelSummary::nExpectedBiddingsChanged);
connect(m_model.get(), &TableModel::nTotalExpectedSharesChanged, this,
&ModelSummary::nTotalExpectedSharesChanged);
connect(m_model.get(), &TableModel::nPlacedBiddingsChanged, this,
&ModelSummary::nPlacedBiddingsChanged);
connect(m_model.get(), &TableModel::biddingSumChanged, this, &ModelSummary::biddingSumChanged);
@ -29,6 +31,8 @@ QBindable<int> ModelSummary::bindableRowCount() {
return &m_rowCount;
}
qreal ModelSummary::nTotalExpectedShares() const { return m_model->nTotalExpectedShares(); }
int ModelSummary::nExpectedBiddings() const { return m_model->nExpectedBiddings(); }
int ModelSummary::nPlacedBiddings1() const { return m_model->nPlacedBiddings1(); }