Exemple #1
0
 /**
  * Register JS files
  *
  * @return array
  */
 public function getJSFiles()
 {
     $list = parent::getJSFiles();
     $list[] = 'modules/CDev/XPaymentsConnector/iframe_common.js';
     $list[] = $this->getDir() . '/script.js';
     return $list;
 }
Exemple #2
0
 /**
  * Get a list of CSS files required to display the widget properly
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = 'items_list/model/table/style.css';
     $list[] = 'items_list/model/style.css';
     return $list;
 }
Exemple #3
0
 /**
  * Return internal list name
  *
  * @return string
  */
 protected function getListName()
 {
     $result = parent::getListName();
     if (!empty($result)) {
         $result .= '.';
     }
     return $result . 'upgrade';
 }
Exemple #4
0
 /**
  * Get current language code
  *
  * @return string
  */
 protected function getCode()
 {
     return \XLite\Core\Request::getInstance()->code ?: parent::getDefaultLanguage();
 }
Exemple #5
0
 /**
  * Return file name for body template
  *
  * @return void
  */
 protected function getBodyTemplate()
 {
     return $this->getCart()->isEmpty() ? 'empty.tpl' : parent::getBodyTemplate();
 }
Exemple #6
0
 /**
  * Register the CSS classes for this block
  *
  * @return string
  */
 protected function getBlockClasses()
 {
     return parent::getBlockClasses() . ' block-subcategories';
 }
Exemple #7
0
 /**
  * Define widget parameters
  *
  * @return void
  */
 protected function defineWidgetParams()
 {
     parent::defineWidgetParams();
     $this->widgetParams += array(self::PARAM_DISPLAY_MODE => new \XLite\Model\WidgetParam\String('Display mode', self::DISPLAY_MODE_TEXT, false), self::PARAM_ADDRESS => new \XLite\Model\WidgetParam\Object('Address object', null, false), self::PARAM_DISPLAY_WRAPPER => new \XLite\Model\WidgetParam\Bool('Display wrapper', false, false));
 }
Exemple #8
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     return parent::isVisible() && \XLite\Core\Auth::getInstance()->isLogged();
 }
Exemple #9
0
 /**
  * Return list of allowed targets
  *
  * @return array
  */
 public static function getAllowedTargets()
 {
     $list = parent::getAllowedTargets();
     $list[] = 'role';
     return $list;
 }
Exemple #10
0
 /**
  * Return list of allowed targets
  *
  * @return array
  */
 public static function getAllowedTargets()
 {
     return array_merge(parent::getAllowedTargets(), array('roles'));
 }
Exemple #11
0
 /**
  * Register CSS files
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = 'modules/XC/Reviews/review/style.css';
     $list[] = 'modules/XC/Reviews/form_field/input/rating/rating.css';
     return $list;
 }
Exemple #12
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     return parent::isVisible() && $this->getCart()->getOrigProfile() && !$this->getCart()->getOrigProfile()->getOrder();
 }
Exemple #13
0
 /**
  * Register JS files
  *
  * @return array
  */
 public function getJSFiles()
 {
     $list = parent::getJSFiles();
     $list[] = 'languages/controller.js';
     return $list;
 }
Exemple #14
0
 /**
  * Return list of targets allowed for this widget
  *
  * @return array
  */
 public static function getAllowedTargets()
 {
     $result = parent::getAllowedTargets();
     $result[] = 'memberships';
     return $result;
 }
Exemple #15
0
 /**
  * Check ACL permissions
  *
  * @return boolean
  */
 protected function checkACL()
 {
     return parent::checkACL() && \XLite\Core\Auth::getInstance()->isPermissionAllowed('manage orders');
 }
 /**
  * Register CSS files
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = 'activate_free_license/style.css';
     return $list;
 }
Exemple #17
0
 /**
  * Register files from common repository
  *
  * @return array
  */
 public function getCommonFiles()
 {
     $list = parent::getCommonFiles();
     $list[static::RESOURCE_JS][] = 'js/core.popup.js';
     $list[static::RESOURCE_JS][] = 'js/core.popup_button.js';
     return $list;
 }
Exemple #18
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     $result = parent::isVisible() && (Paypal\Main::isPaypalCreditEnabled() || Paypal\Main::isPaypalWPSEnabled()) && $this->isValidTarget() && $this->getPublisherId() && $this->getSetting('agreement');
     if ($result) {
         $settingName = 'bannerOn' . ucfirst($this->getParam(static::PARAM_PAGE));
         $result = $this->getParam(static::PARAM_POSITION) == $this->getSetting($settingName);
     }
     return $result;
 }
Exemple #19
0
 /**
  * Register JS files
  *
  * @return array
  */
 public function getJSFiles()
 {
     $list = parent::getJSFiles();
     return $list;
 }
Exemple #20
0
 /**
  * Define widget parameters
  *
  * @return void
  */
 protected function defineWidgetParams()
 {
     parent::defineWidgetParams();
     $this->widgetParams += array(static::PARAM_DISPLAY_CACHED => new \XLite\Model\WidgetParam\Bool('Display cached content', true, false), static::PARAM_ICON_MAX_WIDTH => new \XLite\Model\WidgetParam\Int('Maximal icon width', 0, true), static::PARAM_ICON_MAX_HEIGHT => new \XLite\Model\WidgetParam\Int('Maximal icon height', 0, true));
 }
Exemple #21
0
 /**
  * Add widget specific JS file
  *
  * @return array
  */
 public function getJSFiles()
 {
     $list = parent::getJSFiles();
     $list[] = $this->getDir() . '/controller.js';
     return $list;
 }
Exemple #22
0
 /**
  * Check widget visible
  *
  * @return boolean
  */
 public function isVisible()
 {
     return parent::isVisible() && $this->getPaymentMethod() && $this->getPaymentMethod()->getProcessor() && $this->getPaymentMethod()->getProcessor()->getSettingsWidget();
 }
Exemple #23
0
 /**
  * Get a list of CSS files required to display the widget properly
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = $this->getDir() . '/style.css';
     return $list;
 }
Exemple #24
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     return parent::isVisible() && $this->getPaymentMethod();
 }
Exemple #25
0
 /**
  * Return specific CSS class for dialog wrapper
  *
  * @return string
  */
 protected function getDialogCSSClass()
 {
     return parent::getDialogCSSClass() . ' currency-view-info-dialog';
 }
 /**
  * Register CSS files
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = 'modules/CDev/Moneybookers/settings/style.css';
     return $list;
 }
Exemple #27
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     return parent::isVisible() || $this->isExported();
 }
Exemple #28
0
 /**
  * Check if widget is visible
  *
  * @return boolean
  */
 protected function isVisible()
 {
     return parent::isVisible() && $this->getBody();
 }
Exemple #29
0
 /**
  * getJSFiles
  *
  * @return array
  */
 public function getJSFiles()
 {
     $list = parent::getJSFiles();
     $list[] = $this->getDir() . '/js/script.js';
     return $list;
 }
Exemple #30
0
 /**
  * Register CSS files
  *
  * @return array
  */
 public function getCSSFiles()
 {
     $list = parent::getCSSFiles();
     $list[] = 'modules/CDev/PaypalWPS/settings/style.css';
     return $list;
 }