Пример #1
0
 public function importItem($item = null)
 {
     parent::importItem($item);
     $this->id = 'ubsk';
     $this->confirm = true;
     $this->price_group = 'ubsk.' . $this->getOption('kit_class')->get('value', 'A') . ($this->getOption('shade_type')->get('value') ? '.' . $this->getOption('shade_type')->get('value') : '');
     $this->type = 'ubsk';
     $this->make = "LaPorte's T-Top Boat Covers";
 }
Пример #2
0
 public function importItem($item = null)
 {
     parent::importItem($item);
     $this->id = 'ccc';
     $this->confirm = true;
     $this->type = 'ccc';
     $this->name = 'Center Console Curtain';
     $this->make = "LaPorte's T-Top Boat Covers";
     $this->price_group = 'ccc.' . $this->getOption('class')->get('value', 'B');
 }
Пример #3
0
 public function create($item, $type = null)
 {
     if (!isset($item->sku) || !isset($this->_items[$item->sku])) {
         $class = $type . 'StoreItem';
         if ($type) {
             if (file_exists($this->app->path->path('classes:store/items/' . $type . '.php'))) {
                 $this->app->loader->register($class, 'classes:store/items/' . $type . '.php');
                 $storeItem = new $class($this->app);
             } else {
                 $storeItem = new StoreItem($this->app);
             }
         } else {
             $storeItem = new StoreItem($this->app);
         }
         $storeItem->importItem($item);
         // fire event
         $this->app->event->dispatcher->notify($this->app->event->create($storeItem, 'storeitem:init'));
         $this->_items[$storeItem->sku] = $storeItem;
         return $this->_items[$storeItem->sku];
     }
     return $this->_items[$item->sku];
 }
Пример #4
0
 public function importItem($item = null)
 {
     parent::importItem($item);
     $this->price_group = 'ttopboatcover.' . $this->attributes['boat_length']->get('value');
     if ($item instanceof Item) {
         $this->name = 'T-Top Boat Cover';
         $this->attributes['boat_model'] = $this->app->data->create();
         $this->attributes['boat_model']->set('name', 'Boat Model');
         $this->attributes['boat_model']->set('value', $item->name);
         $this->attributes['boat_model']->set('text', $item->name);
     }
     $this->confirm = true;
     $this->make = "LaPorte's T-Top Boat Covers";
     $this->model = 'T-Top Boat Cover ' . $this->attributes['oem']->get('name') . ' ' . $this->attributes['boat_length']->get('value');
 }
Пример #5
0
 public function importItem($item = null)
 {
     parent::importItem($item);
     if (!$item instanceof Item) {
         if (isset($item['fromCart']) && $item['fromCart']) {
             $this->id = 'bsk-' . $this->options['kit_type']->get('value', 'aft');
         } else {
             $this->id = 'bsk';
         }
     } else {
         $this->id = 'bsk';
     }
     $this->confirm = true;
     $this->price_group = 'bsk.' . $this->getOption('kit_class')->get('value', 'B');
     $this->type = 'bsk';
     $this->make = "LaPorte's T-Top Boat Covers";
 }
Пример #6
0
 /**
  * Set the Item
  *
  * @param 	StoreItem	$item 	StoreItem Class Object
  *
  * @return 	Price 	$this	Support for chaining.
  *
  * @since 1.0
  */
 public function setItem(StoreItem $item)
 {
     $this->_item = $item;
     $this->setGroup($item->getPriceGroup());
     $this->setMarkupRate($item->markup);
     return $this;
 }