From 69ffbcac4474404c413aceaecc96117691fd801a Mon Sep 17 00:00:00 2001
From: Camil Staps
Date: Wed, 27 Jul 2016 21:40:10 +0200
Subject: Traits cannot have constants
---
include/home.php | 8 ++++----
include/offers-overview.php | 10 +++++-----
include/offers-view.php | 4 ++--
3 files changed, 11 insertions(+), 11 deletions(-)
(limited to 'include')
diff --git a/include/home.php b/include/home.php
index 43cfeb1..3903ab2 100644
--- a/include/home.php
+++ b/include/home.php
@@ -167,8 +167,8 @@ require('./header.php');
'id' => $offer->id,
'contactClientName' => $offer->getContact()->getClient()->name,
'percentage' => $percentage,
- 'price_excl' => Constants::invoice_valuta . $offer->calculate(Calculatable::SUBTOTAL),
- 'price_incl' => Constants::invoice_valuta . $offer->calculate(Calculatable::TOTAL)
+ 'price_excl' => Constants::invoice_valuta . $offer->calculate(CALCULATABLE_SUBTOTAL),
+ 'price_incl' => Constants::invoice_valuta . $offer->calculate(CALCULATABLE_TOTAL)
);
}
krsort($list, SORT_STRING);
@@ -285,8 +285,8 @@ require('./header.php');
'assignments_header' => ''
);
foreach ($offer->getAssignments() as $assignment) {
- $temp['assignments'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(Calculatable::TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()}
";
- $temp['assignments_header'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(Calculatable::TOTAL)} incl. VAT)
";
+ $temp['assignments'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()}
";
+ $temp['assignments_header'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_TOTAL)} incl. VAT)
";
}
$list[] = array_merge($temp, array('type' => 'start', 'time' => $offer->start_date, 'description' => 'Offer started'));
$sort_list[] = $offer->start_date . $offer->id . 0;
diff --git a/include/offers-overview.php b/include/offers-overview.php
index 1118793..6c5135a 100644
--- a/include/offers-overview.php
+++ b/include/offers-overview.php
@@ -46,10 +46,10 @@ require_once('./login.php');
{$offer->getContact()->name} |
";
foreach ($offer->getAssignments() as $assignment) {
- echo "{$assignment->title} (".Constants::invoice_valuta."{$assignment->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(Calculatable::TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()} ";
+ echo "{$assignment->title} (".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()} ";
}
foreach ($offer->getDiscounts() as $discount) {
- echo "{$discount->title} (".Constants::invoice_valuta."{$discount->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$discount->calculate(Calculatable::TOTAL)} incl. VAT)
{$discount->description} ";
+ echo "{$discount->title} (".Constants::invoice_valuta."{$discount->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$discount->calculate(CALCULATABLE_TOTAL)} incl. VAT)
{$discount->description} ";
}
echo " |
@@ -82,15 +82,15 @@ require_once('./login.php');
Subtotal: |
- ".Constants::invoice_valuta."{$offer->calculate(Calculatable::SUBTOTAL)} |
+ ".Constants::invoice_valuta."{$offer->calculate(CALCULATABLE_SUBTOTAL)} |
VAT: |
- ".Constants::invoice_valuta."{$offer->calculate(Calculatable::VAT)} |
+ ".Constants::invoice_valuta."{$offer->calculate(CALCULATABLE_VAT)} |
Total: |
- ".Constants::invoice_valuta."{$offer->calculate(Calculatable::TOTAL)} |
+ ".Constants::invoice_valuta."{$offer->calculate(CALCULATABLE_TOTAL)} |
|
diff --git a/include/offers-view.php b/include/offers-view.php
index 802f42f..2df495a 100644
--- a/include/offers-view.php
+++ b/include/offers-view.php
@@ -40,8 +40,8 @@ $_offer = new Offer($_pdo, $_id);
'assignments_header' => ''
);
foreach ($_offer->getAssignments() as $assignment) {
- $temp['assignments'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(Calculatable::TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()}
";
- $temp['assignments_header'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(Calculatable::SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(Calculatable::TOTAL)} incl. VAT)
";
+ $temp['assignments'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_TOTAL)} incl. VAT)
{$assignment->getHTMLDescription()}
";
+ $temp['assignments_header'] .= "{$assignment->title}
(".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_SUBTOTAL)} excl. VAT, ".Constants::invoice_valuta."{$assignment->calculate(CALCULATABLE_TOTAL)} incl. VAT)
";
}
$list[] = array_merge($temp, array('type' => 'start', 'time' => $_offer->start_date, 'description' => 'Offer started'));
$sort_list[] = $_offer->start_date . $_offer->id . 0;
--
cgit v1.2.3