OXID eShop CE  4.9.6
 All Classes Files Functions Variables Pages
delivery_articles.php
Go to the documentation of this file.
1 <?php
2 
3 
11 {
12 
19  public function render()
20  {
22 
23  $soxId = $this->getEditObjectId();
24 
25  if ($soxId != "-1" && isset($soxId)) {
26  $this->_createCategoryTree("artcattree");
27 
28  // load object
29  $oDelivery = oxNew("oxdelivery");
30  $oDelivery->load($soxId);
31  $this->_aViewData["edit"] = $oDelivery;
32 
33  //Disable editing for derived articles
34  if ($oDelivery->isDerived()) {
35  $this->_aViewData['readonly'] = true;
36  }
37  }
38 
39  $iAoc = oxRegistry::getConfig()->getRequestParameter("aoc");
40  if ($iAoc == 1) {
41  $oDeliveryArticlesAjax = oxNew('delivery_articles_ajax');
42  $this->_aViewData['oxajax'] = $oDeliveryArticlesAjax->getColumns();
43 
44  return "popups/delivery_articles.tpl";
45  } elseif ($iAoc == 2) {
46  $oDeliveryCategoriesAjax = oxNew('delivery_categories_ajax');
47  $this->_aViewData['oxajax'] = $oDeliveryCategoriesAjax->getColumns();
48 
49  return "popups/delivery_categories.tpl";
50  }
51 
52  return "delivery_articles.tpl";
53  }
54 }