Ejemplo n.º 1
0
 public function getCoupons()
 {
     $couponDao = new CouponDao();
     $customerId = Mage::getSingleton('customer/session')->getId();
     $coupons = $couponDao->getOverviewByCustomerId($customerId);
     return $coupons;
 }
Ejemplo n.º 2
0
 public function getStampCard()
 {
     $couponDao = new CouponDao();
     $customerId = Mage::getSingleton('customer/session')->getId();
     $coupons = $couponDao->getOverviewByCustomerId($customerId);
     foreach ($coupons as $coupon) {
         $aantal = $coupon['aantalproducten'];
         $duurste = $coupon['duursteproduct'];
         $value = array_values($coupon);
     }
     return $coupons;
 }
Ejemplo n.º 3
0
 public function getStampCard()
 {
     $stampcard = $this->getCustomer()->getPrimaryShippingAddress();
     $couponDao = new CouponDao();
     $customerId = Mage::getSingleton('customer/session')->getId();
     $coupons = $couponDao->getOverviewByCustomerId($customerId);
     foreach ($coupons as $coupon) {
         $aantal = $coupon['aantalproducten'];
         $duurste = $coupon['duursteproduct'];
         $value = array_values($coupon);
         echo " copuon  {$aantal} en {$duurste}";
         Mage::log("data {$value}", null, 'custom.log');
     }
     return $coupons;
     //        if( $stampcard instanceof Varien_Object ) {
     //            return $stampcard->format('html');
     //        } else {
     //            return Mage::helper('customer')->__('You have not set a default shipping address.');
     //        }
 }