Completed
Push — master ( bf34f3...88111b )
by Michael
03:08
created
class/SmartobjectCustomtagHandler.php 2 patches
Indentation   +36 added lines, -36 removed lines patch added patch discarded remove patch
@@ -30,48 +30,48 @@
 block discarded – undo
30 30
  */
31 31
 class SmartobjectCustomtagHandler extends Smartobject\SmartPersistableObjectHandler
32 32
 {
33
-    public $objects = false;
33
+	public $objects = false;
34 34
 
35
-    /**
36
-     * SmartobjectCustomtagHandler constructor.
37
-     * @param \XoopsDatabase $db
38
-     */
39
-    public function __construct(\XoopsDatabase $db)
40
-    {
41
-        parent::__construct($db, 'customtag', 'customtagid', 'name', 'description', 'smartobject');
42
-        $this->addPermission('view', _CO_SOBJECT_CUSTOMTAG_PERMISSION_VIEW, _CO_SOBJECT_CUSTOMTAG_PERMISSION_VIEW_DSC);
43
-    }
35
+	/**
36
+	 * SmartobjectCustomtagHandler constructor.
37
+	 * @param \XoopsDatabase $db
38
+	 */
39
+	public function __construct(\XoopsDatabase $db)
40
+	{
41
+		parent::__construct($db, 'customtag', 'customtagid', 'name', 'description', 'smartobject');
42
+		$this->addPermission('view', _CO_SOBJECT_CUSTOMTAG_PERMISSION_VIEW, _CO_SOBJECT_CUSTOMTAG_PERMISSION_VIEW_DSC);
43
+	}
44 44
 
45
-    /**
46
-     * @return array|bool
47
-     */
48
-    public function getCustomtagsByName()
49
-    {
50
-        if (!$this->objects) {
51
-            global $xoopsConfig;
45
+	/**
46
+	 * @return array|bool
47
+	 */
48
+	public function getCustomtagsByName()
49
+	{
50
+		if (!$this->objects) {
51
+			global $xoopsConfig;
52 52
 
53
-            $ret = [];
53
+			$ret = [];
54 54
 
55
-            $criteria = new \CriteriaCompo();
55
+			$criteria = new \CriteriaCompo();
56 56
 
57
-            $criteria_language = new \CriteriaCompo();
58
-            $criteria_language->add(new \Criteria('language', $xoopsConfig['language']));
59
-            $criteria_language->add(new \Criteria('language', 'all'), 'OR');
60
-            $criteria->add($criteria_language);
57
+			$criteria_language = new \CriteriaCompo();
58
+			$criteria_language->add(new \Criteria('language', $xoopsConfig['language']));
59
+			$criteria_language->add(new \Criteria('language', 'all'), 'OR');
60
+			$criteria->add($criteria_language);
61 61
 
62
-            $smartobjectPermissionsHandler = new SmartObjectPermissionHandler($this);
63
-            $granted_ids                   = $smartobjectPermissionsHandler->getGrantedItems('view');
62
+			$smartobjectPermissionsHandler = new SmartObjectPermissionHandler($this);
63
+			$granted_ids                   = $smartobjectPermissionsHandler->getGrantedItems('view');
64 64
 
65
-            if ($granted_ids && count($granted_ids) > 0) {
66
-                $criteria->add(new \Criteria('customtagid', '(' . implode(', ', $granted_ids) . ')', 'IN'));
67
-                $customtagsObj =& $this->getObjects($criteria, true);
68
-                foreach ($customtagsObj as $customtagObj) {
69
-                    $ret[$customtagObj->getVar('name')] = $customtagObj;
70
-                }
71
-            }
72
-            $this->objects = $ret;
73
-        }
65
+			if ($granted_ids && count($granted_ids) > 0) {
66
+				$criteria->add(new \Criteria('customtagid', '(' . implode(', ', $granted_ids) . ')', 'IN'));
67
+				$customtagsObj =& $this->getObjects($criteria, true);
68
+				foreach ($customtagsObj as $customtagObj) {
69
+					$ret[$customtagObj->getVar('name')] = $customtagObj;
70
+				}
71
+			}
72
+			$this->objects = $ret;
73
+		}
74 74
 
75
-        return $this->objects;
76
-    }
75
+		return $this->objects;
76
+	}
77 77
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -63,8 +63,8 @@
 block discarded – undo
63 63
             $granted_ids                   = $smartobjectPermissionsHandler->getGrantedItems('view');
64 64
 
65 65
             if ($granted_ids && count($granted_ids) > 0) {
66
-                $criteria->add(new \Criteria('customtagid', '(' . implode(', ', $granted_ids) . ')', 'IN'));
67
-                $customtagsObj =& $this->getObjects($criteria, true);
66
+                $criteria->add(new \Criteria('customtagid', '('.implode(', ', $granted_ids).')', 'IN'));
67
+                $customtagsObj = & $this->getObjects($criteria, true);
68 68
                 foreach ($customtagsObj as $customtagObj) {
69 69
                     $ret[$customtagObj->getVar('name')] = $customtagObj;
70 70
                 }
Please login to merge, or discard this patch.
class/Constants.php 1 patch
Indentation   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -24,38 +24,38 @@
 block discarded – undo
24 24
  */
25 25
 class Constants
26 26
 {
27
-    /**#@+
27
+	/**#@+
28 28
      * Constant definition
29 29
      */
30 30
 
31
-    const DISALLOW = 0;
31
+	const DISALLOW = 0;
32 32
 
33
-    // CONFIG displayicons
34
-    const DISPLAYICONS_ICON = 1;
35
-    const DISPLAYICONS_TEXT = 2;
36
-    const DISPLAYICONS_NO = 3;
33
+	// CONFIG displayicons
34
+	const DISPLAYICONS_ICON = 1;
35
+	const DISPLAYICONS_TEXT = 2;
36
+	const DISPLAYICONS_NO = 3;
37 37
 
38
-    // CONFIG submissions
39
-    const SUBMISSIONS_NONE = 1;
40
-    const SUBMISSIONS_DOWNLOAD = 2;
41
-    const SUBMISSIONS_MIRROR = 3;
42
-    const SUBMISSIONS_BOTH = 4;
38
+	// CONFIG submissions
39
+	const SUBMISSIONS_NONE = 1;
40
+	const SUBMISSIONS_DOWNLOAD = 2;
41
+	const SUBMISSIONS_MIRROR = 3;
42
+	const SUBMISSIONS_BOTH = 4;
43 43
 
44
-    // CONFIG anonpost
45
-    const ANONPOST_NONE = 1;
46
-    const ANONPOST_DOWNLOAD = 2;
47
-    const ANONPOST_MIRROR = 3;
48
-    const ANONPOST_BOTH = 4;
44
+	// CONFIG anonpost
45
+	const ANONPOST_NONE = 1;
46
+	const ANONPOST_DOWNLOAD = 2;
47
+	const ANONPOST_MIRROR = 3;
48
+	const ANONPOST_BOTH = 4;
49 49
 
50
-    // CONFIG autoapprove
51
-    const AUTOAPPROVE_NONE = 1;
52
-    const AUTOAPPROVE_DOWNLOAD = 2;
53
-    const AUTOAPPROVE_MIRROR = 3;
54
-    const AUTOAPPROVE_BOTH = 4;
50
+	// CONFIG autoapprove
51
+	const AUTOAPPROVE_NONE = 1;
52
+	const AUTOAPPROVE_DOWNLOAD = 2;
53
+	const AUTOAPPROVE_MIRROR = 3;
54
+	const AUTOAPPROVE_BOTH = 4;
55 55
 
56
-    const DEFAULT_ELEMENT_SIZE = 1;
56
+	const DEFAULT_ELEMENT_SIZE = 1;
57 57
 
58 58
 
59
-    /**#@-*/
59
+	/**#@-*/
60 60
 }
61 61
 
Please login to merge, or discard this patch.
class/Utility.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -9,11 +9,11 @@
 block discarded – undo
9 9
  */
10 10
 class Utility
11 11
 {
12
-    use Common\VersionChecks; //checkVerXoops, checkVerPhp Traits
12
+	use Common\VersionChecks; //checkVerXoops, checkVerPhp Traits
13 13
 
14
-    use Common\ServerStats; // getServerStats Trait
14
+	use Common\ServerStats; // getServerStats Trait
15 15
 
16
-    use Common\FilesManagement; // Files Management Trait
16
+	use Common\FilesManagement; // Files Management Trait
17 17
 
18
-    //--------------- Custom module methods -----------------------------
18
+	//--------------- Custom module methods -----------------------------
19 19
 }
Please login to merge, or discard this patch.
class/SmartobjectUrlLink.php 1 patch
Indentation   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -29,20 +29,20 @@
 block discarded – undo
29 29
  */
30 30
 class SmartobjectUrlLink extends Smartobject\BaseSmartObjectBasedUrl
31 31
 {
32
-    /**
33
-     * SmartobjectUrlLink constructor.
34
-     */
35
-    public function __construct()
36
-    {
37
-        parent::__construct();
38
-        $this->quickInitVar('urllinkid', XOBJ_DTYPE_TXTBOX, true);
39
-        $this->quickInitVar('target', XOBJ_DTYPE_TXTBOX, true);
32
+	/**
33
+	 * SmartobjectUrlLink constructor.
34
+	 */
35
+	public function __construct()
36
+	{
37
+		parent::__construct();
38
+		$this->quickInitVar('urllinkid', XOBJ_DTYPE_TXTBOX, true);
39
+		$this->quickInitVar('target', XOBJ_DTYPE_TXTBOX, true);
40 40
 
41
-        $this->setControl('target', [
42
-            'options' => [
43
-                '_self'  => _CO_SOBJECT_URLLINK_SELF,
44
-                '_blank' => _CO_SOBJECT_URLLINK_BLANK
45
-            ]
46
-        ]);
47
-    }
41
+		$this->setControl('target', [
42
+			'options' => [
43
+				'_self'  => _CO_SOBJECT_URLLINK_SELF,
44
+				'_blank' => _CO_SOBJECT_URLLINK_BLANK
45
+			]
46
+		]);
47
+	}
48 48
 }
Please login to merge, or discard this patch.
class/SmartobjectCurrency.php 2 patches
Indentation   +109 added lines, -109 removed lines patch added patch discarded remove patch
@@ -30,113 +30,113 @@
 block discarded – undo
30 30
  */
31 31
 class SmartobjectCurrency extends Smartobject\BaseSmartObject
32 32
 {
33
-    public $_modulePlugin = false;
34
-
35
-    /**
36
-     * SmartobjectCurrency constructor.
37
-     */
38
-    public function __construct()
39
-    {
40
-        $this->quickInitVar('currencyid', XOBJ_DTYPE_INT, true);
41
-        $this->quickInitVar('iso4217', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_ISO4217, _CO_SOBJECT_CURRENCY_ISO4217_DSC);
42
-        $this->quickInitVar('name', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_NAME);
43
-        $this->quickInitVar('symbol', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_SYMBOL);
44
-        $this->quickInitVar('rate', XOBJ_DTYPE_FLOAT, true, _CO_SOBJECT_CURRENCY_RATE, '', '1.0');
45
-        $this->quickInitVar('default_currency', XOBJ_DTYPE_INT, false, _CO_SOBJECT_CURRENCY_DEFAULT, '', false);
46
-
47
-        $this->setControl('symbol', [
48
-            'name'      => 'text',
49
-            'size'      => '15',
50
-            'maxlength' => '15'
51
-        ]);
52
-
53
-        $this->setControl('iso4217', [
54
-            'name'      => 'text',
55
-            'size'      => '5',
56
-            'maxlength' => '5'
57
-        ]);
58
-
59
-        $this->setControl('rate', [
60
-            'name'      => 'text',
61
-            'size'      => '5',
62
-            'maxlength' => '5'
63
-        ]);
64
-
65
-        $this->setControl('rate', [
66
-            'name'      => 'text',
67
-            'size'      => '5',
68
-            'maxlength' => '5'
69
-        ]);
70
-
71
-        $this->hideFieldFromForm('default_currency');
72
-    }
73
-
74
-    /**
75
-     * @param  string $key
76
-     * @param  string $format
77
-     * @return mixed
78
-     */
79
-    public function getVar($key, $format = 's')
80
-    {
81
-        if ('s' === $format && in_array($key, ['rate', 'default_currency'])) {
82
-            //            return call_user_func(array($this, $key));
83
-            return $this->{$key}();
84
-        }
85
-
86
-        return parent::getVar($key, $format);
87
-    }
88
-
89
-    /**
90
-     * @return mixed
91
-     */
92
-    public function getCurrencyLink()
93
-    {
94
-        $ret = $this->getVar('name', 'e');
95
-
96
-        return $ret;
97
-    }
98
-
99
-    /**
100
-     * @return mixed
101
-     */
102
-    public function getCode()
103
-    {
104
-        $ret = $this->getVar('iso4217', 'e');
105
-
106
-        return $ret;
107
-    }
108
-
109
-    /**
110
-     * @return float|int|mixed|string
111
-     */
112
-    public function rate()
113
-    {
114
-        return smart_currency($this->getVar('rate', 'e'));
115
-    }
116
-
117
-    /**
118
-     * @return string
119
-     */
120
-    public function defaultCurrency()
121
-    {
122
-        if (true === $this->getVar('default_currency', 'e')) {
123
-            return _YES;
124
-        } else {
125
-            return _NO;
126
-        }
127
-    }
128
-
129
-    /**
130
-     * @return string
131
-     */
132
-    public function getDefaultCurrencyControl()
133
-    {
134
-        $radio_box = '<input name="default_currency" value="' . $this->getVar('currencyid') . '" type="radio"';
135
-        if ($this->getVar('default_currency', 'e')) {
136
-            $radio_box .= 'checked';
137
-        }
138
-        $radio_box .= '>';
139
-
140
-        return $radio_box;
141
-    }
33
+	public $_modulePlugin = false;
34
+
35
+	/**
36
+	 * SmartobjectCurrency constructor.
37
+	 */
38
+	public function __construct()
39
+	{
40
+		$this->quickInitVar('currencyid', XOBJ_DTYPE_INT, true);
41
+		$this->quickInitVar('iso4217', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_ISO4217, _CO_SOBJECT_CURRENCY_ISO4217_DSC);
42
+		$this->quickInitVar('name', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_NAME);
43
+		$this->quickInitVar('symbol', XOBJ_DTYPE_TXTBOX, true, _CO_SOBJECT_CURRENCY_SYMBOL);
44
+		$this->quickInitVar('rate', XOBJ_DTYPE_FLOAT, true, _CO_SOBJECT_CURRENCY_RATE, '', '1.0');
45
+		$this->quickInitVar('default_currency', XOBJ_DTYPE_INT, false, _CO_SOBJECT_CURRENCY_DEFAULT, '', false);
46
+
47
+		$this->setControl('symbol', [
48
+			'name'      => 'text',
49
+			'size'      => '15',
50
+			'maxlength' => '15'
51
+		]);
52
+
53
+		$this->setControl('iso4217', [
54
+			'name'      => 'text',
55
+			'size'      => '5',
56
+			'maxlength' => '5'
57
+		]);
58
+
59
+		$this->setControl('rate', [
60
+			'name'      => 'text',
61
+			'size'      => '5',
62
+			'maxlength' => '5'
63
+		]);
64
+
65
+		$this->setControl('rate', [
66
+			'name'      => 'text',
67
+			'size'      => '5',
68
+			'maxlength' => '5'
69
+		]);
70
+
71
+		$this->hideFieldFromForm('default_currency');
72
+	}
73
+
74
+	/**
75
+	 * @param  string $key
76
+	 * @param  string $format
77
+	 * @return mixed
78
+	 */
79
+	public function getVar($key, $format = 's')
80
+	{
81
+		if ('s' === $format && in_array($key, ['rate', 'default_currency'])) {
82
+			//            return call_user_func(array($this, $key));
83
+			return $this->{$key}();
84
+		}
85
+
86
+		return parent::getVar($key, $format);
87
+	}
88
+
89
+	/**
90
+	 * @return mixed
91
+	 */
92
+	public function getCurrencyLink()
93
+	{
94
+		$ret = $this->getVar('name', 'e');
95
+
96
+		return $ret;
97
+	}
98
+
99
+	/**
100
+	 * @return mixed
101
+	 */
102
+	public function getCode()
103
+	{
104
+		$ret = $this->getVar('iso4217', 'e');
105
+
106
+		return $ret;
107
+	}
108
+
109
+	/**
110
+	 * @return float|int|mixed|string
111
+	 */
112
+	public function rate()
113
+	{
114
+		return smart_currency($this->getVar('rate', 'e'));
115
+	}
116
+
117
+	/**
118
+	 * @return string
119
+	 */
120
+	public function defaultCurrency()
121
+	{
122
+		if (true === $this->getVar('default_currency', 'e')) {
123
+			return _YES;
124
+		} else {
125
+			return _NO;
126
+		}
127
+	}
128
+
129
+	/**
130
+	 * @return string
131
+	 */
132
+	public function getDefaultCurrencyControl()
133
+	{
134
+		$radio_box = '<input name="default_currency" value="' . $this->getVar('currencyid') . '" type="radio"';
135
+		if ($this->getVar('default_currency', 'e')) {
136
+			$radio_box .= 'checked';
137
+		}
138
+		$radio_box .= '>';
139
+
140
+		return $radio_box;
141
+	}
142 142
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 // defined('XOOPS_ROOT_PATH') || die('Restricted access');
24 24
 
25 25
 //require_once XOOPS_ROOT_PATH . '/modules/smartobject/class/smartobject.php';
26
-require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
26
+require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
27 27
 
28 28
 /**
29 29
  * Class SmartobjectCurrency
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
      */
132 132
     public function getDefaultCurrencyControl()
133 133
     {
134
-        $radio_box = '<input name="default_currency" value="' . $this->getVar('currencyid') . '" type="radio"';
134
+        $radio_box = '<input name="default_currency" value="'.$this->getVar('currencyid').'" type="radio"';
135 135
         if ($this->getVar('default_currency', 'e')) {
136 136
             $radio_box .= 'checked';
137 137
         }
Please login to merge, or discard this patch.
class/SmartAddTo.php 1 patch
Indentation   +62 added lines, -62 removed lines patch added patch discarded remove patch
@@ -31,66 +31,66 @@
 block discarded – undo
31 31
 
32 32
 class SmartAddTo
33 33
 {
34
-    public $_layout;
35
-    public $_method;
36
-
37
-    /**
38
-     * Constructor of SmartAddTo
39
-     *
40
-     * @param int $layout 0=Horizontal 1 row, 1=Horizontal 2 rows, 2=Vertical with icons, 3=Vertical no icons
41
-     * @param int $method 0=directpage, 1=popup
42
-     */
43
-    public function __construct($layout = 0, $method = 1)
44
-    {
45
-        $layout = (int)$layout;
46
-        if ($layout < 0 || $layout > 3) {
47
-            $layout = 0;
48
-        }
49
-        $this->_layout = $layout;
50
-
51
-        $method = (int)$method;
52
-        if ($method < 0 || $method > 1) {
53
-            $method = 1;
54
-        }
55
-        $this->_method = $method;
56
-    }
57
-
58
-    /**
59
-     * @param  bool $fetchOnly
60
-     * @return mixed|string|void
61
-     */
62
-    public function render($fetchOnly = false)
63
-    {
64
-        global $xoTheme, $xoopsTpl;
65
-
66
-        $xoTheme->addStylesheet(SMARTOBJECT_URL . 'include/addto/addto.css');
67
-
68
-        $xoopsTpl->assign('smartobject_addto_method', $this->_method);
69
-        $xoopsTpl->assign('smartobject_addto_layout', $this->_layout);
70
-
71
-        $xoopsTpl->assign('smartobject_addto_url', SMARTOBJECT_URL . 'include/addto/');
72
-
73
-        if ($fetchOnly) {
74
-            return $xoopsTpl->fetch('db:smartobject_addto.tpl');
75
-        } else {
76
-            $xoopsTpl->display('db:smartobject_addto.tpl');
77
-        }
78
-    }
79
-
80
-    /**
81
-     * @return array
82
-     */
83
-    public function renderForBlock()
84
-    {
85
-        global $xoTheme;
86
-
87
-        $xoTheme->addStylesheet(SMARTOBJECT_URL . 'include/addto/addto.css');
88
-
89
-        $block                             = [];
90
-        $block['smartobject_addto_method'] = $this->_method;
91
-        $block['smartobject_addto_layout'] = $this->_layout;
92
-        $block['smartobject_addto_url']    = SMARTOBJECT_URL . 'include/addto/';
93
-
94
-        return $block;
95
-    }
34
+	public $_layout;
35
+	public $_method;
36
+
37
+	/**
38
+	 * Constructor of SmartAddTo
39
+	 *
40
+	 * @param int $layout 0=Horizontal 1 row, 1=Horizontal 2 rows, 2=Vertical with icons, 3=Vertical no icons
41
+	 * @param int $method 0=directpage, 1=popup
42
+	 */
43
+	public function __construct($layout = 0, $method = 1)
44
+	{
45
+		$layout = (int)$layout;
46
+		if ($layout < 0 || $layout > 3) {
47
+			$layout = 0;
48
+		}
49
+		$this->_layout = $layout;
50
+
51
+		$method = (int)$method;
52
+		if ($method < 0 || $method > 1) {
53
+			$method = 1;
54
+		}
55
+		$this->_method = $method;
56
+	}
57
+
58
+	/**
59
+	 * @param  bool $fetchOnly
60
+	 * @return mixed|string|void
61
+	 */
62
+	public function render($fetchOnly = false)
63
+	{
64
+		global $xoTheme, $xoopsTpl;
65
+
66
+		$xoTheme->addStylesheet(SMARTOBJECT_URL . 'include/addto/addto.css');
67
+
68
+		$xoopsTpl->assign('smartobject_addto_method', $this->_method);
69
+		$xoopsTpl->assign('smartobject_addto_layout', $this->_layout);
70
+
71
+		$xoopsTpl->assign('smartobject_addto_url', SMARTOBJECT_URL . 'include/addto/');
72
+
73
+		if ($fetchOnly) {
74
+			return $xoopsTpl->fetch('db:smartobject_addto.tpl');
75
+		} else {
76
+			$xoopsTpl->display('db:smartobject_addto.tpl');
77
+		}
78
+	}
79
+
80
+	/**
81
+	 * @return array
82
+	 */
83
+	public function renderForBlock()
84
+	{
85
+		global $xoTheme;
86
+
87
+		$xoTheme->addStylesheet(SMARTOBJECT_URL . 'include/addto/addto.css');
88
+
89
+		$block                             = [];
90
+		$block['smartobject_addto_method'] = $this->_method;
91
+		$block['smartobject_addto_layout'] = $this->_layout;
92
+		$block['smartobject_addto_url']    = SMARTOBJECT_URL . 'include/addto/';
93
+
94
+		return $block;
95
+	}
96 96
 }
Please login to merge, or discard this patch.
class/SmartobjectCurrencyHandler.php 2 patches
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -30,22 +30,22 @@
 block discarded – undo
30 30
  */
31 31
 class SmartObjectCurrencyHandler extends Smartobject\SmartPersistableObjectHandler
32 32
 {
33
-    /**
34
-     * SmartObjectCurrencyHandler constructor.
35
-     * @param \XoopsDatabase $db
36
-     */
37
-    public function __construct(\XoopsDatabase $db)
38
-    {
39
-        parent::__construct($db, 'currency', 'currencyid', 'name', '', 'smartobject');
40
-    }
41
-
42
-    /**
43
-     * @return array
44
-     */
45
-    public function getCurrencies()
46
-    {
47
-        $currenciesObj =& $this->getObjects(null, true);
48
-
49
-        return $currenciesObj;
50
-    }
33
+	/**
34
+	 * SmartObjectCurrencyHandler constructor.
35
+	 * @param \XoopsDatabase $db
36
+	 */
37
+	public function __construct(\XoopsDatabase $db)
38
+	{
39
+		parent::__construct($db, 'currency', 'currencyid', 'name', '', 'smartobject');
40
+	}
41
+
42
+	/**
43
+	 * @return array
44
+	 */
45
+	public function getCurrencies()
46
+	{
47
+		$currenciesObj =& $this->getObjects(null, true);
48
+
49
+		return $currenciesObj;
50
+	}
51 51
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 // defined('XOOPS_ROOT_PATH') || die('Restricted access');
24 24
 
25 25
 //require_once XOOPS_ROOT_PATH . '/modules/smartobject/class/smartobject.php';
26
-require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
26
+require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
27 27
 
28 28
 /**
29 29
  * Class SmartObjectCurrencyHandler
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
      */
45 45
     public function getCurrencies()
46 46
     {
47
-        $currenciesObj =& $this->getObjects(null, true);
47
+        $currenciesObj = & $this->getObjects(null, true);
48 48
 
49 49
         return $currenciesObj;
50 50
     }
Please login to merge, or discard this patch.
class/SmartJax.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -30,10 +30,10 @@
 block discarded – undo
30 30
  */
31 31
 class SmartJax extends \Projax
32 32
 {
33
-    public function initiateFromUserside()
34
-    {
35
-        global $xoTheme;
36
-        $xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/prototype.js');
37
-        $xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/scriptaculous.js');
38
-    }
33
+	public function initiateFromUserside()
34
+	{
35
+		global $xoTheme;
36
+		$xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/prototype.js');
37
+		$xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/scriptaculous.js');
38
+	}
39 39
 }
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 
24 24
 // defined('XOOPS_ROOT_PATH') || die('Restricted access');
25 25
 
26
-require_once XOOPS_ROOT_PATH . '/modules/smartobject/include/projax/projax.php';
26
+require_once XOOPS_ROOT_PATH.'/modules/smartobject/include/projax/projax.php';
27 27
 
28 28
 /**
29 29
  * Class SmartJax
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     public function initiateFromUserside()
34 34
     {
35 35
         global $xoTheme;
36
-        $xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/prototype.js');
37
-        $xoTheme->addScript(SMARTOBJECT_URL . 'include/projax/js/scriptaculous.js');
36
+        $xoTheme->addScript(SMARTOBJECT_URL.'include/projax/js/prototype.js');
37
+        $xoTheme->addScript(SMARTOBJECT_URL.'include/projax/js/scriptaculous.js');
38 38
     }
39 39
 }
Please login to merge, or discard this patch.
class/SmartobjectTag.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -28,17 +28,17 @@
 block discarded – undo
28 28
  */
29 29
 class SmartobjectTag extends SmartMlObject
30 30
 {
31
-    /**
32
-     * SmartobjectTag constructor.
33
-     */
34
-    public function __construct()
35
-    {
36
-        $this->initVar('tagid', XOBJ_DTYPE_INT, '', true);
37
-        $this->initVar('name', XOBJ_DTYPE_TXTBOX, '', true, 255, '', false, _CO_SOBJECT_TAG_TAGID_CAPTION, _CO_SOBJECT_TAG_TAGID_DSC, true);
38
-        $this->initVar('description', XOBJ_DTYPE_TXTAREA, '', true, null, '', false, _CO_SOBJECT_TAG_DESCRIPTION_CAPTION, _CO_SOBJECT_TAG_DESCRIPTION_DSC);
39
-        $this->initVar('value', XOBJ_DTYPE_TXTAREA, '', true, null, '', true, _CO_SOBJECT_TAG_VALUE_CAPTION, _CO_SOBJECT_TAG_VALUE_DSC);
31
+	/**
32
+	 * SmartobjectTag constructor.
33
+	 */
34
+	public function __construct()
35
+	{
36
+		$this->initVar('tagid', XOBJ_DTYPE_INT, '', true);
37
+		$this->initVar('name', XOBJ_DTYPE_TXTBOX, '', true, 255, '', false, _CO_SOBJECT_TAG_TAGID_CAPTION, _CO_SOBJECT_TAG_TAGID_DSC, true);
38
+		$this->initVar('description', XOBJ_DTYPE_TXTAREA, '', true, null, '', false, _CO_SOBJECT_TAG_DESCRIPTION_CAPTION, _CO_SOBJECT_TAG_DESCRIPTION_DSC);
39
+		$this->initVar('value', XOBJ_DTYPE_TXTAREA, '', true, null, '', true, _CO_SOBJECT_TAG_VALUE_CAPTION, _CO_SOBJECT_TAG_VALUE_DSC);
40 40
 
41
-        // call parent constructor to get Multilanguage field initiated
42
-        $this->SmartMlObject();
43
-    }
41
+		// call parent constructor to get Multilanguage field initiated
42
+		$this->SmartMlObject();
43
+	}
44 44
 }
Please login to merge, or discard this patch.