public function view() { $this->set("itemCount", StoreCart::getTotalItemsInCart()); $this->set("total", StorePrice::format(StoreCalculator::getSubTotal())); $js = \Concrete\Package\VividStore\Controller::returnHeaderJS(); $this->requireAsset('javascript', 'jquery'); $this->addFooterItem($js); $this->requireAsset('javascript', 'vivid-store'); $this->requireAsset('css', 'vivid-store'); }
public static function getTaxes($format = false) { $taxRates = self::getTaxRates(); $taxes = array(); if (count($taxRates) > 0) { foreach ($taxRates as $taxRate) { if ($taxRate->isTaxable()) { $taxAmount = $taxRate->calculate(); if ($taxAmount > 0) { $tax = true; } else { $tax = false; } if ($format == true) { $taxAmount = StorePrice::format($taxAmount); } $taxes[] = array('name' => $taxRate->getTaxLabel(), 'taxamount' => $taxAmount, 'based' => $taxRate->getTaxBasedOn(), 'taxed' => $tax); } } } return $taxes; }
public function getShippingTotal() { $smID = $_POST['smID']; echo StorePrice::format(StoreCalculator::getShippingTotal($smID)); }
public function view() { $this->set("itemCount", StoreCart::getTotalItemsInCart()); $this->set("total", StorePrice::format(StoreCalculator::getSubTotal())); }
} //if cart ?> </ul> <?php if ($cart && !empty($cart)) { ?> <div class="cart-page-cart-total"> <span class="cart-grand-total-label"><?php echo t("Sub Total"); ?> :</span> <span class="cart-grand-total-value"><?php echo StorePrice::format($total); ?> </span> </div> <?php } else { ?> <p class="alert alert-info"><?php echo t('Your cart is empty'); ?> </p> <?php } ?>
</a> </div> <div class="checkout-cart-product-name"> <a href="<?php echo URL::page(Page::getByID($product->getProductPageID())); ?> "> <?php echo $product->getProductName(); ?> </a> </div> <div class="checkout-cart-item-price"> <?php echo Price::format($product->getProductPrice()); ?> </div> <div class="checkout-cart-product-qty"> <span class="checkout-cart-item-label"><?php echo t("Quantity:"); ?> </span> <?php echo $qty; ?> </div> <?php if ($cartItem['productAttributes']) { ?>
public function getDisplay() { $display = trim($this->drDisplay); if ($display) { return $display; } else { if ($this->drDeductType == 'percentage') { return $this->drPercentage . ' ' . t('off'); } if ($this->drDeductType == 'value') { return StorePrice::format($this->drValue) . ' ' . t('off'); } } }
public function getTotal() { echo Price::format(VividCart::getTotal()); }
public function getFormattedPrice() { return Price::format($this->pPrice); }
<td><?php echo Price::format($o->getShippingTotal()); ?> </td> <td> <?php $tax = $o->getTaxTotal(); $includedTax = $o->getIncludedTaxTotal(); if ($tax) { echo Price::format($tax); } elseif ($includedTax) { echo Price::format($includedTax); } ?> </td> <td><?php echo Price::format($o->getTotal()); ?> </td> </tr> <?php } ?> </tbody> </table> <?php if ($paginator->getTotalPages() > 1) { ?> <?php echo $pagination; }
$checked = true; } else { if ($i == 1) { $checked = true; } else { $checked = false; } } ?> <div class="radio"> <label> <input type="radio" name="shippingMethod" value="<?php echo $method->getShippingMethodID(); ?> "<?php if ($checked) { echo " checked"; } ?> > <?php echo $method->getName(); ?> - <?php echo StorePrice::format($method->getShippingMethodTypeMethod()->getRate()); ?> </label> </div> <?php $i++; }
public function getFormattedVariationPrice() { return StorePrice::format($this->pvPrice); }
</a> </div> <div class="checkout-cart-product-name"> <a href="<?php echo URL::page(Page::getByID($product->getProductPageID())); ?> "> <?php echo $product->getProductName(); ?> </a> </div> <div class="checkout-cart-item-price"> <?php echo Price::format($product->getActivePrice()); ?> </div> <?php if ($product->allowQuantity()) { ?> <div class="checkout-cart-product-qty"> <span class="checkout-cart-item-label"><?php echo t("Quantity:"); ?> </span> <?php echo $qty; ?> </div>
public function getShippingTotal() { $smID = $_POST['smID']; echo Price::format(VividCart::getShippingTotal($smID)); }
public function view() { $this->set("itemCount", VividCart::getTotalItemsInCart()); $this->set("total", Price::format(VividCart::getSubTotal())); }
//if is_object $i++; } //foreach } //if cart ?> </ul> <div class="cart-page-cart-total"> <span class="cart-grand-total-label"><?php echo t("Sub Total"); ?> :</span> <span class="cart-grand-total-value"><?php echo Price::format($total); ?> </span> </div> <div class="cart-page-cart-links"> <?php if ($cart && !empty($cart)) { ?> <a class="btn-cart-page-clear" href="javascript:vividStore.clearCart()"><?php echo t('Clear Cart'); ?> </a> <a class="btn-cart-page-checkout" href="<?php echo View::url('/checkout'); ?>
public function getFormattedActivePrice() { return StorePrice::format($this->getActivePrice()); }
echo View::url('/dashboard/store/orders/order/', $order->getOrderID()); ?> "><?php echo $order->getOrderID(); ?> </a></td> <td><?php echo $order->getAttribute('billing_last_name') . ", " . $order->getAttribute('billing_first_name'); ?> </td> <td><?php echo $order->getOrderDate(); ?> </td> <td><?php echo Price::format($order->getTotal()); ?> </td> <td><?php echo ucwords($order->getStatus()); ?> </td> <td><a class="btn btn-primary" href="<?php echo View::url('/dashboard/store/orders/order/', $order->getOrderID()); ?> "><?php echo t("View"); ?> </a></td> </tr> <?php
</thead> <tbody> <?php foreach ($products as $product) { ?> <tr> <td><?php echo $product['name']; ?> </td> <td><?php echo $product['quantity']; ?> </td> <td><?php echo Price::format($product['pricePaid']); ?> </td> </tr> <?php } ?> </tbody> </table> <?php if ($paginator->getTotalPages() > 1) { ?> <?php echo $pagination; }