Skip to content

Commit

Permalink
small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
BigAndini committed Mar 1, 2017
1 parent a558799 commit 93fb2dc
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 18 deletions.
3 changes: 3 additions & 0 deletions module/ErsBase/src/ErsBase/Service/OrderService.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,9 @@ public function changeCurrency($paramCurrency) {
if($debug) {
error_log('set item to currency: '.$currency);
}
if($item->hasParentItems()) {
continue;
}
$product = $item->getProduct();
$participant = $item->getPackage()->getParticipant();

Expand Down
13 changes: 13 additions & 0 deletions module/PreReg/src/PreReg/Controller/OrderController.php
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,10 @@ public function paymentAction() {
$paymenttype = $em->getRepository('ErsBase\Entity\PaymentType')
->findOneBy(array('id' => $data['paymenttype_id']));

if($paymenttype->getCurrency()->getShort() != $order->getCurrency()->getShort()) {
throw new \Exception('Unable to set this payment type for this order. Please chooser another payment type.');
}

$order->setPaymentType($paymenttype);

$em->persist($order);
Expand Down Expand Up @@ -474,6 +478,13 @@ public function checkoutAction() {
$forrest = new Service\BreadcrumbService();
$forrest->remove('terms');
switch(strtolower($order->getPaymentType()->getType())) {
case 'sepa':
return $this->redirect()->toRoute('payment',
array(
'action' => 'banktransfer',
'hashkey' => $order->getHashkey(),
));
break;
case 'banktransfer':
return $this->redirect()->toRoute('payment',
array(
Expand Down Expand Up @@ -509,6 +520,8 @@ public function checkoutAction() {
));
break;
default:
throw new \Exception('We were unable to handle your chose payment type: '.strtolower($order->getPaymentType()->getType()));
break;
}

}
Expand Down
12 changes: 6 additions & 6 deletions module/PreReg/view/pre-reg/info/impressum.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ $this->headTitle($this->translate('Impressum'));
<div>
<div class="jumbotron">
<h1>Impressum</h1>
<p>Jonglieren in München e.V.<br />
Goethe Str. 10<br />
80336 München<br />
Deutschland</p>
<p>Stichting European Juggling Association<br />
Jodenbreestraat 24-1<br />
1011 NK Amsterdam<br />
The Netherlands</p>

<p>E-Mail: info@jimev.de<br />
Web: <a href="http://www.jimev.de/" target="_blank">www.jimev.de</a></p>
<p>E-Mail: info@eja.net<br />
Web: <a href="http://www.eja.net/" target="_blank">www.eja.net</a></p>

</div>
</div>
15 changes: 6 additions & 9 deletions module/PreReg/view/pre-reg/info/terms.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,10 @@
$this->headTitle($this->translate('Terms & Conditions'));
?>

<div>
<a href="<?php echo $this->url($breadcrumb->route, $breadcrumb->params, $breadcrumb->options); ?>"><?php echo $this->translate('Back'); ?></a>
<div class="jumbotron">
<h1><?php echo $this->translate('Terms and Conditions'); ?></h1>
<?php /* <a href="/Terms-and-Conditions-ERS-EN-v5.pdf" target="_blank">Terms and Conditions ERS EN v5</a><br />
<a href="/Terms-and-Conditions-ORGA-EN-v4.pdf" target="_blank">Terms and Conditions ORGA EN v4</a>*/ ?>
<h3><?php echo $this->translate('Disclaimer'); ?></h3>
<p><?php echo $this->translate('Upon attending the EJC, in no event shall the host or its representatives or its assistants be liable for any loss or injury or any damages, unless they are grounded in cause of gross negligence or wilful act of breach of duty by the host or its representatives or its assistants. Participants attend by choice, on their own risk; they take the responsibility for their own health status and pay attention to it. We especially point out that the Convention is a sports event where professional jugglers and acrobats will train together with non - professionals of all skill levels. There will be workshops in all sorts of circus disciplines open (but maybe not appropriate!) for everyone; above that props and apparatus will be accessible, be it because the host provides them or any participant simply puts them up and let others use them as well. It is your own responsibility and neither the hosts\', nor the workshop leaders\', their representatives\' or assistants\' to make sure at any time that your health and fitness condition is adequate to take part in the workshop in question or to use props and apparatus mentioned hereinabove safely.'); ?></p>
</div>
<div class="jumbotron">
<h1><?php echo $this->translate('Terms and Conditions'); ?></h1>
<?php /* <a href="/Terms-and-Conditions-ERS-EN-v5.pdf" target="_blank">Terms and Conditions ERS EN v5</a><br />
<a href="/Terms-and-Conditions-ORGA-EN-v4.pdf" target="_blank">Terms and Conditions ORGA EN v4</a>*/ ?>
<h3><?php echo $this->translate('Disclaimer'); ?></h3>
<p><?php echo $this->translate('Upon attending the EJC, in no event shall the host or its representatives or its assistants be liable for any loss or injury or any damages, unless they are grounded in cause of gross negligence or wilful act of breach of duty by the host or its representatives or its assistants. Participants attend by choice, on their own risk; they take the responsibility for their own health status and pay attention to it. We especially point out that the Convention is a sports event where professional jugglers and acrobats will train together with non - professionals of all skill levels. There will be workshops in all sorts of circus disciplines open (but maybe not appropriate!) for everyone; above that props and apparatus will be accessible, be it because the host provides them or any participant simply puts them up and let others use them as well. It is your own responsibility and neither the hosts\', nor the workshop leaders\', their representatives\' or assistants\' to make sure at any time that your health and fitness condition is adequate to take part in the workshop in question or to use props and apparatus mentioned hereinabove safely.'); ?></p>
</div>
1 change: 0 additions & 1 deletion module/PreReg/view/pre-reg/product/add.phtml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<?php $this->headTitle($product->getName()); ?>
<a href="<?php echo $this->url($breadcrumb->route, $breadcrumb->params, $breadcrumb->options);?>"><?php echo $this->translate('back to Overview'); ?></a>
<?php if($chooser && false): ?>
<div class="p_overlay">
<div class="p_overlay_inner">
Expand Down
2 changes: 0 additions & 2 deletions module/PreReg/view/pre-reg/product/edit.phtml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
<?php $this->headTitle($product->getName()); ?>
<a href="<?php echo $this->url($breadcrumb->route, $breadcrumb->params, $breadcrumb->options);?>"><?php echo $this->translate('back to Overview'); ?></a>

<?php if(count($product->getProductPrices()) == 0): ?>
<p class="desc-short"><?php echo $this->translate('This product is unavailable'); ?></p>
<?php else: ?>
Expand Down

0 comments on commit 93fb2dc

Please sign in to comment.