Created
December 7, 2015 21:07
-
-
Save grippado/8c2f1904288717a2039b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$helper = $this->helper('eotica_hometrial'); | |
$conflictMessage = $helper->getMessageConflict($this->getConflict()); | |
?> | |
<?php echo $this->getLayout()->createBlock('eotica_hometrial/cart')->setTemplate('eotica/hometrial/cart/header.phtml')->toHtml() ?> | |
<div id="cart-conflict"> | |
<div class="message"> | |
PRECISO INSERIR UM CONTEUDO AQUI, QUE SE FOR PeC é uma coisa, se for CART, é outra! | |
<p><?php echo $this->__($conflictMessage); ?></p> | |
<p><?php echo $this->__('Deseja Continuar?'); ?></p> | |
</div> | |
<div class="buttons"> | |
<button class="cancel" onclick="jQuery('.hometrial .tooltip-content').hide();"><?php echo $this->__('Cancelar') ?></button> | |
<button class="continue" onclick="<?php echo $this->getConflict()['product'] ? 'hometrialCart.setHometrialCart(); hometrialForm.submit(this);' : "hometrialCart.unsetHometrialCart(); jQuery('#product_addtocart_form').submit()" ?>"><?php echo $this->__('Continuar') ?></button> | |
</div> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function getMessageConflict($conflict) | |
{ | |
$pec = 'Kit Prove em Casa'; | |
$cart = 'carrinho de compra'; | |
$atual = !$conflict['cart'] ? $cart : $pec; | |
$message = sprintf('Ao adicionar um produto no %s, você vai remover os produtos do %s.', !$conflict['cart'] ? $pec : $cart, $atual); | |
return $message; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment