Added dashboard to Shop plugin.

This commit is contained in:
2018-05-23 14:11:56 +02:00
parent 22936f2a3f
commit 653f8eac30
11 changed files with 263 additions and 3 deletions
+28
View File
@@ -0,0 +1,28 @@
#include "shopoverview.h"
#include "ui_shopoverview.h"
#include "shop-odb.hxx"
#include "shopservice.h"
ShopOverview::ShopOverview(QWidget *parent) :
QFrame(parent),
ui(new Ui::ShopOverview)
{
ui->setupUi(this);
}
ShopOverview::~ShopOverview()
{
delete ui;
}
void ShopOverview::refresh()
{
ShopService srv;
VoucherSum unpaid = srv.unpaidSummary();
VoucherSum unsend = srv.unsendEET();
ui->labelUnapiedCount->setText(QString::number(unpaid.m_count));
ui->labelUnpaiedAmount->setText(QString::number(unpaid.totalPrice().toDouble()));
ui->labelUnsendEET->setText(QString::number(unsend.m_count));
}