|
|
@ -60,10 +60,6 @@ void ShopService::calculate(VoucherPtr voucher)
|
|
|
|
|
|
|
|
|
|
|
|
loadSettings();
|
|
|
|
loadSettings();
|
|
|
|
|
|
|
|
|
|
|
|
if (voucher->items().isEmpty()) {
|
|
|
|
|
|
|
|
load(voucher);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
foreach (QSharedPointer<VoucherItem> item, voucher->items()) {
|
|
|
|
foreach (QSharedPointer<VoucherItem> item, voucher->items()) {
|
|
|
|
|
|
|
|
|
|
|
|
if (item->refId() == ROUNDING_ITEM)
|
|
|
|
if (item->refId() == ROUNDING_ITEM)
|
|
|
@ -384,6 +380,9 @@ void ShopService::moveItems(QList<VoucherItemPtr> items, VoucherPtr source, Vouc
|
|
|
|
it->setVoucher(target);
|
|
|
|
it->setVoucher(target);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
calculate(target);
|
|
|
|
|
|
|
|
update(target, &session);
|
|
|
|
|
|
|
|
|
|
|
|
if (source->items().isEmpty())
|
|
|
|
if (source->items().isEmpty())
|
|
|
|
{
|
|
|
|
{
|
|
|
|
erase(source, &session);
|
|
|
|
erase(source, &session);
|
|
|
|