forkel_bars - Version 1.0.3

Version Notes

===== 1.0.3 =====
* Replaced "hostname" with a execution environment variable dropdown
* Added SERVER_NAME as a default
* Added style.css for notification bar
* Added configuration tab in System > Configuration
* Fixed wrong translation xml path

===== 1.0.2 =====
* Wrong XML syntax in bars.xml.
* Simplified main.js with pure JavaScript. No Prototype anymore.
* Minimized main.js
* Hide bar until DOM is loaded.

===== 1.0.1 =====
* Display each notification bar for a specific admin user role.

===== 1.0.0 =====
* Initial version of this module

Download this release

Release Info

Developer Tobias Forkel
Extension forkel_bars
Version 1.0.3
Comparing to
See all releases


Code changes from version 1.0.2 to 1.0.3

app/code/community/Forkel/Bars/Block/Adminhtml/Notification.php CHANGED
@@ -12,9 +12,7 @@ class Forkel_Bars_Block_Adminhtml_Notification extends Mage_Core_Block_Template
12
  {
13
  public function getNotification()
14
  {
15
- return Mage::getSingleton(Forkel_Bars_Helper_Data::MODEL_INDEX)->loadByHostname(
16
- Mage::helper(Forkel_Bars_Helper_Data::MODULE_KEY)->getHostname()
17
- );
18
  }
19
 
20
  /**
12
  {
13
  public function getNotification()
14
  {
15
+ return Mage::getSingleton(Forkel_Bars_Helper_Data::MODEL_INDEX)->loadByEnvironmentVariable();
 
 
16
  }
17
 
18
  /**
app/code/community/Forkel/Bars/Block/Adminhtml/Server/Edit/Form.php CHANGED
@@ -63,11 +63,19 @@ class Forkel_Bars_Block_Adminhtml_Server_Edit_Form extends Mage_Adminhtml_Block_
63
  'required' => true
64
  ));
65
 
66
- $fieldset->addField('hostname', 'text', array(
67
- 'name' => 'hostname',
68
- 'label' => $this->__('Hostname'),
69
- 'title' => $this->__('Hostname'),
70
- 'note' => $this->__('The hostname without http and slashes /.'),
 
 
 
 
 
 
 
 
71
  ));
72
 
73
  $form->setValues($model->getData());
@@ -77,3 +85,4 @@ class Forkel_Bars_Block_Adminhtml_Server_Edit_Form extends Mage_Adminhtml_Block_
77
  return parent::_prepareForm();
78
  }
79
  }
 
63
  'required' => true
64
  ));
65
 
66
+ $fieldset->addField('environment_variable', 'select', array(
67
+ 'name' => 'environment_variable',
68
+ 'label' => $this->__('Environment Variable'),
69
+ 'title' => $this->__('Environment Variable'),
70
+ 'values' => Mage::getSingleton('forkel_bars/server_environment')->getOptionArray(),
71
+ 'note' => $this->__('The execution environment variable for server identification. Add more variables in <a href="%s"> System > Configuration > Forkel Bars > Server</a>.', $this->getUrl('adminhtml/system_config/edit/section/forkel_bars')),
72
+ ));
73
+
74
+ $fieldset->addField('environment_value', 'text', array(
75
+ 'name' => 'environment_value',
76
+ 'label' => $this->__('Environment Value'),
77
+ 'title' => $this->__('Environment Value'),
78
+ 'note' => $this->__('The value that should match the selected variable.'),
79
  ));
80
 
81
  $form->setValues($model->getData());
85
  return parent::_prepareForm();
86
  }
87
  }
88
+
app/code/community/Forkel/Bars/Block/Adminhtml/Server/Grid.php CHANGED
@@ -72,10 +72,17 @@ class Forkel_Bars_Block_Adminhtml_Server_Grid extends Mage_Adminhtml_Block_Widge
72
  )
73
  );
74
 
75
- $this->addColumn('hostname',
76
  array(
77
- 'header' => $this->__('Hostname'),
78
- 'index' => 'hostname'
 
 
 
 
 
 
 
79
  )
80
  );
81
 
72
  )
73
  );
74
 
75
+ $this->addColumn('environment_variable',
76
  array(
77
+ 'header' => $this->__('Environment Variable'),
78
+ 'index' => 'environment_variable'
79
+ )
80
+ );
81
+
82
+ $this->addColumn('environment_value',
83
+ array(
84
+ 'header' => $this->__('Environment Value'),
85
+ 'index' => 'environment_value'
86
  )
87
  );
88
 
app/code/community/Forkel/Bars/Changelog.txt CHANGED
@@ -7,6 +7,13 @@
7
  * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
  */
9
 
 
 
 
 
 
 
 
10
  ===== 1.0.2 =====
11
  * Wrong XML syntax in bars.xml.
12
  * Simplified main.js with pure JavaScript. No Prototype anymore.
7
  * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
  */
9
 
10
+ ===== 1.0.3 =====
11
+ * Replaced "hostname" with a execution environment variable dropdown
12
+ * Added SERVER_NAME as a default
13
+ * Added style.css for notification bar
14
+ * Added configuration tab in System > Configuration
15
+ * Fixed wrong translation xml path
16
+
17
  ===== 1.0.2 =====
18
  * Wrong XML syntax in bars.xml.
19
  * Simplified main.js with pure JavaScript. No Prototype anymore.
app/code/community/Forkel/Bars/Helper/Data.php CHANGED
@@ -15,18 +15,53 @@ class Forkel_Bars_Helper_Data extends Mage_Core_Helper_Abstract
15
 
16
  const MODEL_INDEX = 'forkel_bars/index';
17
  const MODEL_SERVER = 'forkel_bars/server';
 
18
 
19
  /**
20
- * Return hostname by current url
21
  *
22
  * @return array
23
  */
24
- public function getHostname()
25
  {
26
- $url = Mage::helper('core/url')->getCurrentUrl();
27
- $url = Mage::getSingleton('core/url')->parseUrl($url);
28
 
29
- return $url->getHost();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
  }
31
 
32
  /**
15
 
16
  const MODEL_INDEX = 'forkel_bars/index';
17
  const MODEL_SERVER = 'forkel_bars/server';
18
+ const MODEL_SERVER_ENVIRONMENT = 'forkel_bars/server_environment';
19
 
20
  /**
21
+ * Return filtered $_SERVER array
22
  *
23
  * @return array
24
  */
25
+ public function getServerEnvFiltered()
26
  {
27
+ $filter = explode(',', Mage::getStoreConfig('forkel_bars/server/variables'));
 
28
 
29
+ if (count($filter) > 0)
30
+ {
31
+ return array_intersect_key($_SERVER, array_flip($filter));
32
+ }
33
+
34
+ return $_SERVER;
35
+ }
36
+
37
+ /**
38
+ * Return environment variables
39
+ *
40
+ * @return array
41
+ */
42
+ public function getEnvironment()
43
+ {
44
+ $options = array();
45
+ $env = $this->getServerEnvFiltered();
46
+
47
+ array_push($options, array(
48
+ 'value' => '',
49
+ 'label' => $this->__('Select a server variable')
50
+ ));
51
+
52
+ if (is_array($env)) {
53
+
54
+ foreach ($env as $index => $value) {
55
+
56
+ $options[] = array(
57
+ 'value' => trim($index),
58
+ 'label' => sprintf('%s ( %s )', $index, $value)
59
+ );
60
+ }
61
+
62
+ }
63
+
64
+ return $options;
65
  }
66
 
67
  /**
app/code/community/Forkel/Bars/Model/Index.php CHANGED
@@ -16,12 +16,14 @@ class Forkel_Bars_Model_Index extends Mage_Core_Model_Abstract
16
  }
17
 
18
  /**
19
- * Load collection filtered by hostname and status
20
  *
21
  * @return Forkel_Bars_Model_Index
22
  */
23
- public function loadByHostname($hostname = '', $status = 1)
24
  {
 
 
25
  $session = Mage::getSingleton('admin/session');
26
  $role_id = implode('', $session->getUser()->getRoles());
27
 
@@ -36,8 +38,13 @@ class Forkel_Bars_Model_Index extends Mage_Core_Model_Abstract
36
  )
37
  );
38
 
39
- $collection->addFieldToFilter('hostname', $hostname);
 
 
 
 
40
 
41
  return $collection->getFirstItem();
42
  }
43
  }
 
16
  }
17
 
18
  /**
19
+ * Load collection filtered by environment variable and status
20
  *
21
  * @return Forkel_Bars_Model_Index
22
  */
23
+ public function loadByEnvironmentVariable($status = 1)
24
  {
25
+ $env = Mage::helper(Forkel_Bars_Helper_Data::MODULE_KEY)->getServerEnvFiltered();
26
+
27
  $session = Mage::getSingleton('admin/session');
28
  $role_id = implode('', $session->getUser()->getRoles());
29
 
38
  )
39
  );
40
 
41
+ $keys = array_keys($env);
42
+ $values = array_values($env);
43
+
44
+ $collection->addFieldToFilter('environment_variable', array('finset', $keys));
45
+ $collection->addFieldToFilter('environment_value', array('finset', $values));
46
 
47
  return $collection->getFirstItem();
48
  }
49
  }
50
+
app/code/community/Forkel/Bars/Model/Server/Environment.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Forkel Bars
4
+ *
5
+ * @category Forkel
6
+ * @package Forkel_Bars
7
+ * @copyright Copyright (c) 2015 Tobias Forkel (http://www.tobiasforkel.de)
8
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
9
+ */
10
+
11
+ class Forkel_Bars_Model_Server_Environment extends Mage_Core_Model_Abstract
12
+ {
13
+ protected function _construct()
14
+ {
15
+ $this->_init(Forkel_Bars_Helper_Data::MODEL_SERVER_ENVIRONMENT);
16
+ }
17
+
18
+ /**
19
+ * Return all collection as an option array
20
+ *
21
+ * @return array
22
+ */
23
+ public function getOptionArray()
24
+ {
25
+ $helper = Mage::helper('forkel_bars');
26
+
27
+ return $helper->getEnvironment();
28
+ }
29
+ }
app/code/community/Forkel/Bars/data/forkel_bars_setup/data-install-1.0.0.php CHANGED
@@ -17,8 +17,8 @@ if ($model->getCollection()->count() == 0)
17
  array(
18
  'name' => 'Noooope!',
19
  'description' => 'Your boss will fire you right away.',
20
- 'color' => '#a94442',
21
- 'color_background' => '#f2dede',
22
  'server_id' => 4,
23
  'status' => 1,
24
  'admin_role_id' => 1
@@ -26,8 +26,8 @@ if ($model->getCollection()->count() == 0)
26
  array(
27
  'name' => 'Please!',
28
  'description' => 'This environment is tested and ready for deployment.',
29
- 'color' => '#715630',
30
- 'color_background' => '#f5ce96',
31
  'server_id' => 3,
32
  'status' => 1,
33
  'admin_role_id' => 1,
@@ -35,8 +35,8 @@ if ($model->getCollection()->count() == 0)
35
  array(
36
  'name' => 'Well ...',
37
  'description' => 'Ask your team and project manager before do any changes.',
38
- 'color' => '#31708f',
39
- 'color_background' => '#d9edf7',
40
  'server_id' => 2,
41
  'status' => 1,
42
  'admin_role_id' => 1
@@ -44,8 +44,8 @@ if ($model->getCollection()->count() == 0)
44
  array(
45
  'name' => 'Good!',
46
  'description' => ' You can do whatever you want.',
47
- 'color' => '#3c763d',
48
- 'color_background' => '#dff0d8',
49
  'server_id' => 1,
50
  'status' => 1,
51
  'admin_role_id' => 1
@@ -67,22 +67,22 @@ if ($model->getCollection()->count() == 0)
67
  array(
68
  'name' => 'Local Environment',
69
  'description' => 'Dictum viverra suspendisse hendrerit quam pellentesque pharetra, elementum sit urna, morbi scelerisque.',
70
- 'hostname' => 'local.server.com'
71
  ),
72
  array(
73
  'name' => 'Staging Environment',
74
  'description' => 'Diharetra, elementum sit urna, morbi scelerisque.',
75
- 'hostname' => 'staging.server.com'
76
  ),
77
  array(
78
  'name' => 'Preview Environment',
79
  'description' => 'Sed ut, amet nam, cras in arcu. Mollis aenean pede tortor fusce mattis rutrum, non sollicitudin.',
80
- 'hostname' => 'preview.server.com'
81
  ),
82
  array(
83
  'name' => 'Production Environment',
84
  'description' => 'Mollis aenean pede tortor fusce mattis rutrum, non sollicitudin.',
85
- 'hostname' => 'www.server.com'
86
  ),
87
  );
88
 
17
  array(
18
  'name' => 'Noooope!',
19
  'description' => 'Your boss will fire you right away.',
20
+ 'color' => '#fff',
21
+ 'color_background' => '#d2552e',
22
  'server_id' => 4,
23
  'status' => 1,
24
  'admin_role_id' => 1
26
  array(
27
  'name' => 'Please!',
28
  'description' => 'This environment is tested and ready for deployment.',
29
+ 'color' => '#fff',
30
+ 'color_background' => '#8a6d3b',
31
  'server_id' => 3,
32
  'status' => 1,
33
  'admin_role_id' => 1,
35
  array(
36
  'name' => 'Well ...',
37
  'description' => 'Ask your team and project manager before do any changes.',
38
+ 'color' => '#fff',
39
+ 'color_background' => '#31708f',
40
  'server_id' => 2,
41
  'status' => 1,
42
  'admin_role_id' => 1
44
  array(
45
  'name' => 'Good!',
46
  'description' => ' You can do whatever you want.',
47
+ 'color' => '#fff',
48
+ 'color_background' => '#3c763d',
49
  'server_id' => 1,
50
  'status' => 1,
51
  'admin_role_id' => 1
67
  array(
68
  'name' => 'Local Environment',
69
  'description' => 'Dictum viverra suspendisse hendrerit quam pellentesque pharetra, elementum sit urna, morbi scelerisque.',
70
+ 'environment_value' => 'local.server.com'
71
  ),
72
  array(
73
  'name' => 'Staging Environment',
74
  'description' => 'Diharetra, elementum sit urna, morbi scelerisque.',
75
+ 'environment_value' => 'staging.server.com'
76
  ),
77
  array(
78
  'name' => 'Preview Environment',
79
  'description' => 'Sed ut, amet nam, cras in arcu. Mollis aenean pede tortor fusce mattis rutrum, non sollicitudin.',
80
+ 'environment_value' => 'preview.server.com'
81
  ),
82
  array(
83
  'name' => 'Production Environment',
84
  'description' => 'Mollis aenean pede tortor fusce mattis rutrum, non sollicitudin.',
85
+ 'environment_value' => 'www.server.com'
86
  ),
87
  );
88
 
app/code/community/Forkel/Bars/etc/adminhtml.xml CHANGED
@@ -27,6 +27,13 @@
27
  </server>
28
  </children>
29
  </forkel_bars>
 
 
 
 
 
 
 
30
  </children>
31
  </system>
32
  </children>
@@ -46,6 +53,11 @@
46
  <sort_order>10</sort_order>
47
  <action>adminhtml/forkel_bars_server/index</action>
48
  </server>
 
 
 
 
 
49
  </children>
50
  </forkel_bars>
51
  </children>
27
  </server>
28
  </children>
29
  </forkel_bars>
30
+ <config>
31
+ <children>
32
+ <forkel_bars translate="title" module="forkel_bars">
33
+ <title>Forkel Bars</title>
34
+ </forkel_bars>
35
+ </children>
36
+ </config>
37
  </children>
38
  </system>
39
  </children>
53
  <sort_order>10</sort_order>
54
  <action>adminhtml/forkel_bars_server/index</action>
55
  </server>
56
+ <settings translate="title">
57
+ <title>Settings</title>
58
+ <sort_order>20</sort_order>
59
+ <action>adminhtml/system_config/edit/section/forkel_bars</action>
60
+ </settings>
61
  </children>
62
  </forkel_bars>
63
  </children>
app/code/community/Forkel/Bars/etc/config.xml CHANGED
@@ -13,7 +13,7 @@
13
  <config>
14
  <modules>
15
  <Forkel_Bars>
16
- <version>1.0.2</version>
17
  </Forkel_Bars>
18
  </modules>
19
  <global>
@@ -73,12 +73,19 @@
73
  </layout>
74
  <translate>
75
  <modules>
76
- <forkel_maintenancealert>
77
  <files>
78
  <default>Forkel_Bars.csv</default>
79
  </files>
80
- </forkel_maintenancealert>
81
  </modules>
82
  </translate>
83
  </adminhtml>
 
 
 
 
 
 
 
84
  </config>
13
  <config>
14
  <modules>
15
  <Forkel_Bars>
16
+ <version>1.0.3</version>
17
  </Forkel_Bars>
18
  </modules>
19
  <global>
73
  </layout>
74
  <translate>
75
  <modules>
76
+ <forkel_bars>
77
  <files>
78
  <default>Forkel_Bars.csv</default>
79
  </files>
80
+ </forkel_bars>
81
  </modules>
82
  </translate>
83
  </adminhtml>
84
+ <default>
85
+ <forkel_bars>
86
+ <server>
87
+ <variables>SERVER_NAME,HTTP_HOST,SERVER_ADDR,MAGE_IS_DEVELOPER_MODE</variables>
88
+ </server>
89
+ </forkel_bars>
90
+ </default>
91
  </config>
app/code/community/Forkel/Bars/etc/system.xml ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Forkel Bars
5
+ *
6
+ * @category Forkel
7
+ * @package Forkel_Bars
8
+ * @copyright Copyright (c) 2016 Tobias Forkel (http://www.tobiasforkel.de)
9
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
10
+ */
11
+ -->
12
+
13
+ <config>
14
+ <tabs>
15
+ <forkel_bars translate="label" module="forkel_bars">
16
+ <label>Forkel Bars</label>
17
+ <sort_order>9000</sort_order>
18
+ </forkel_bars>
19
+ </tabs>
20
+ <sections>
21
+ <forkel_bars translate="label" module="forkel_bars">
22
+ <label>Forkel Bars</label>
23
+ <tab>general</tab>
24
+ <sort_order>100</sort_order>
25
+ <show_in_default>1</show_in_default>
26
+ <show_in_website>1</show_in_website>
27
+ <show_in_store>1</show_in_store>
28
+ <groups>
29
+ <server translate="label">
30
+ <label>Server</label>
31
+ <sort_order>10</sort_order>
32
+ <show_in_default>1</show_in_default>
33
+ <show_in_website>1</show_in_website>
34
+ <show_in_store>1</show_in_store>
35
+ <fields>
36
+ <variables translate="label">
37
+ <label>Server Variables</label>
38
+ <frontend_type>text</frontend_type>
39
+ <sort_order>10</sort_order>
40
+ <show_in_default>1</show_in_default>
41
+ <show_in_website>1</show_in_website>
42
+ <show_in_store>1</show_in_store>
43
+ </variables>
44
+ </fields>
45
+ </server>
46
+ </groups>
47
+ </forkel_bars>
48
+ </sections>
49
+ </config>
app/code/community/Forkel/Bars/sql/forkel_bars_setup/install-1.0.0.php CHANGED
@@ -8,7 +8,7 @@ $installer->startSetup();
8
  * Create table 'forkel_bars_index'
9
  */
10
  $table = $installer->getTable('forkel_bars/index');
11
- if ($installer->getConnection()->isTableExists($table) != true)
12
  {
13
  $table = $installer->getConnection()
14
  ->newTable($table)
@@ -49,7 +49,7 @@ if ($installer->getConnection()->isTableExists($table) != true)
49
  * Create table 'forkel_bars_server'
50
  */
51
  $table = $installer->getTable('forkel_bars/server');
52
- if ($installer->getConnection()->isTableExists($table) != true)
53
  {
54
  $table = $installer->getConnection()
55
  ->newTable($table)
8
  * Create table 'forkel_bars_index'
9
  */
10
  $table = $installer->getTable('forkel_bars/index');
11
+ if (!$installer->getConnection()->isTableExists($table))
12
  {
13
  $table = $installer->getConnection()
14
  ->newTable($table)
49
  * Create table 'forkel_bars_server'
50
  */
51
  $table = $installer->getTable('forkel_bars/server');
52
+ if (!$installer->getConnection()->isTableExists($table))
53
  {
54
  $table = $installer->getConnection()
55
  ->newTable($table)
app/code/community/Forkel/Bars/sql/forkel_bars_setup/upgrade-1.0.0-1.0.1.php CHANGED
@@ -9,14 +9,17 @@ $installer->startSetup();
9
  */
10
  $table = $installer->getTable('forkel_bars/index');
11
 
12
- $installer->getConnection()
13
- ->addColumn($table,
14
- 'admin_role_id',
15
- array(
16
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
17
- 'nullable' => true,
18
- 'comment' => 'Admin Role'
19
- )
20
- );
 
 
 
21
 
22
  $installer->endSetup();
9
  */
10
  $table = $installer->getTable('forkel_bars/index');
11
 
12
+ if (!$installer->getConnection()->tableColumnExists($table, 'admin_role_id'))
13
+ {
14
+ $installer->getConnection()
15
+ ->addColumn($table,
16
+ 'admin_role_id',
17
+ array(
18
+ 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
19
+ 'nullable' => true,
20
+ 'comment' => 'Admin Role'
21
+ )
22
+ );
23
+ }
24
 
25
  $installer->endSetup();
app/code/community/Forkel/Bars/sql/forkel_bars_setup/upgrade-1.0.2-1.0.3.php ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /* @var $installer Mage_Core_Model_Resource_Setup */
4
+ $installer = $this;
5
+ $installer->startSetup();
6
+
7
+ /**
8
+ * Create table 'forkel_bars_index'
9
+ */
10
+ $table = $installer->getTable('forkel_bars/server');
11
+
12
+ if ($installer->getConnection()->tableColumnExists($table, 'hostname'))
13
+ {
14
+ $installer->getConnection()
15
+ ->changeColumn($table,
16
+ 'hostname',
17
+ 'environment_value',
18
+ array(
19
+ 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
20
+ 'length' => 255,
21
+ 'comment' => 'Server Environment Value'
22
+ )
23
+ );
24
+ }
25
+
26
+ $installer->getConnection()
27
+ ->addColumn($table,
28
+ 'environment_variable',
29
+ array(
30
+ 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
31
+ 'length' => 255,
32
+ 'default' => 'HTTP_HOST',
33
+ 'comment' => 'Server Environment Variable'
34
+ )
35
+ );
36
+
37
+ $installer->endSetup();
app/design/adminhtml/default/default/layout/forkel/bars.xml CHANGED
@@ -2,6 +2,9 @@
2
  <layout>
3
  <default>
4
  <reference name="head">
 
 
 
5
  <action method="addJs"><script>community/forkel_bars/main.min.js</script></action>
6
  </reference>
7
  <reference name="notifications">
2
  <layout>
3
  <default>
4
  <reference name="head">
5
+ <action method="addCss">
6
+ <name>forkel/bars/styles.css</name>
7
+ </action>
8
  <action method="addJs"><script>community/forkel_bars/main.min.js</script></action>
9
  </reference>
10
  <reference name="notifications">
app/design/adminhtml/default/default/template/forkel/bars/adminhtml/notification.phtml CHANGED
@@ -4,12 +4,7 @@
4
 
5
  <style>
6
  #forkel_bars_adminhtml_notification {
7
- display: none;
8
  color: <?php echo $notification->getColor() ?>;
9
- overflow: hidden;
10
- font-size: 1.2em;
11
- text-align: left;
12
- padding: 1em 1.5em;
13
  background: repeating-linear-gradient(
14
  45deg,
15
  <?php echo $this->getBackgroundLighter($notification->getColorBackground(), '20') ?>,
@@ -27,4 +22,3 @@
27
  </div>
28
 
29
  <?php endif; ?>
30
-
4
 
5
  <style>
6
  #forkel_bars_adminhtml_notification {
 
7
  color: <?php echo $notification->getColor() ?>;
 
 
 
 
8
  background: repeating-linear-gradient(
9
  45deg,
10
  <?php echo $this->getBackgroundLighter($notification->getColorBackground(), '20') ?>,
22
  </div>
23
 
24
  <?php endif; ?>
 
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>forkel_bars</name>
4
- <version>1.0.2</version>
5
  <stability>stable</stability>
6
  <license uri="https://opensource.org/licenses/OSL-3.0">Open Software License v. 3.0 (OSL-3.0)</license>
7
  <channel>community</channel>
@@ -14,6 +14,10 @@
14
  &lt;br /&gt;&#xD;
15
  &lt;br /&gt;&#xD;
16
  &#xD;
 
 
 
 
17
  &lt;img src="//www.tobiasforkel.de/public/magento/forkel_bars/version/1.0/screenshots/backend/backend_bar_list_overview.gif" /&gt;&#xD;
18
  &lt;br /&gt;&#xD;
19
  &lt;br /&gt;&#xD;
@@ -61,7 +65,14 @@
61
  &#xD;
62
  &lt;h3&gt;Support&lt;/h3&gt;&#xD;
63
  &lt;p&gt;This module is provided as-is with no warranty or support. Purchase a Warranty and Support Package on &lt;a href="http://www.tobiasforkel.de"&gt;http://www.tobiasforkel.de&lt;/a&gt; starting from $50.&lt;/p&gt;</description>
64
- <notes>===== 1.0.2 =====&#xD;
 
 
 
 
 
 
 
65
  * Wrong XML syntax in bars.xml.&#xD;
66
  * Simplified main.js with pure JavaScript. No Prototype anymore.&#xD;
67
  * Minimized main.js&#xD;
@@ -73,9 +84,9 @@
73
  ===== 1.0.0 =====&#xD;
74
  * Initial version of this module</notes>
75
  <authors><author><name>Tobias Forkel</name><user>tforkel</user><email>magento@tobiasforkel.de</email></author></authors>
76
- <date>2016-03-19</date>
77
- <time>05:50:58</time>
78
- <contents><target name="magecommunity"><dir name="Forkel"><dir name="Bars"><dir name="Block"><dir name="Adminhtml"><dir name="Index"><dir name="Edit"><file name="Form.php" hash="98183881e27d929e1a5b43aaaecd611c"/></dir><file name="Edit.php" hash="0103c7c1c3459fce8605ed20abbd6e78"/><file name="Grid.php" hash="5a2dbf65cda4161d3b4d077302ec2e9f"/></dir><file name="Index.php" hash="525509035f5c44c2d8adc0967a052415"/><file name="Notification.php" hash="0dcf5550a6838bbcbce1fed5bfb501f4"/><dir name="Server"><dir name="Edit"><file name="Form.php" hash="a8ff7f4a34ce5102188317b863bdeda6"/></dir><file name="Edit.php" hash="27810453296f514b1f381dbb1841ce43"/><file name="Grid.php" hash="8a70811620d424cfe3a4c162024a1d13"/></dir><file name="Server.php" hash="c993f4e4212e3b3ca3513ebb501def4a"/></dir></dir><file name="Changelog.txt" hash="5d62558c7c578ca87067541056b0059a"/><dir name="controllers"><dir name="Adminhtml"><dir name="Forkel"><dir name="Bars"><file name="IndexController.php" hash="c6caff3224fd46a067e92b2a69e6f3fe"/><file name="ServerController.php" hash="1da8c0ef1465fdad96aaed34a74818ee"/></dir></dir></dir></dir><dir name="data"><dir name="forkel_bars_setup"><file name="data-install-1.0.0.php" hash="aa5f4bfd3543c266eb498890e42397a0"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8731d3ad2f9ebc933f327f73d4332922"/><file name="config.xml" hash="b1c3544faad45862fb47ffd92d4e9595"/></dir><dir name="Helper"><file name="Data.php" hash="3db6cae062e3ea960b0095ce25608202"/></dir><dir name="Model"><file name="Index.php" hash="4dd69936a248504bbf28d2ea4f672093"/><dir name="Resource"><dir name="Index"><file name="Collection.php" hash="1c9b8c4157f07777058eea128c683426"/></dir><file name="Index.php" hash="16f51afe18dba2f4bf1146ae1bf2a73a"/><dir name="Server"><file name="Collection.php" hash="da06239337f1b586285df29fd308200e"/></dir><file name="Server.php" hash="11141fe5a4646eda013b85e2e1ec7d07"/></dir><file name="Roles.php" hash="037b30f230e133eb28f73bcb44b7a7db"/><file name="Server.php" hash="1b373759e53211ad488d2b5bf1ba2344"/></dir><dir name="sql"><dir name="forkel_bars_setup"><file name="install-1.0.0.php" hash="ca8634919a6ed6221172f81b2613a416"/><file name="upgrade-1.0.0-1.0.1.php" hash="f0c2d80d5b645570758b42aa744a45b2"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><dir name="forkel"><file name="bars.xml" hash="976b594a70575c0a47ecaeee6d770abf"/></dir></dir><dir name="template"><dir name="forkel"><dir name="bars"><dir><dir name="adminhtml"><file name="notification.phtml" hash="f9109b4d316832790926df436ca61cb4"/></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Forkel_Bars.xml" hash="1b36f833bbcf2b4061f775a0a95dbdfe"/></dir></target><target name="mage"><dir name="js"><dir name="community"><dir name="forkel_bars"><file name="main.min.js" hash="9fc965c32ea6ad226f4add7c4ddaae11"/></dir></dir></dir></target><target name="magelocal"><dir name="de_DE"><file name="Forkel_Bars.csv" hash=""/></dir><dir name="en_US"><file name="Forkel_Bars.csv" hash=""/></dir></target></contents>
79
  <compatible/>
80
  <dependencies><required><php><min>5.4.0</min><max>5.6.16</max></php></required></dependencies>
81
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>forkel_bars</name>
4
+ <version>1.0.3</version>
5
  <stability>stable</stability>
6
  <license uri="https://opensource.org/licenses/OSL-3.0">Open Software License v. 3.0 (OSL-3.0)</license>
7
  <channel>community</channel>
14
  &lt;br /&gt;&#xD;
15
  &lt;br /&gt;&#xD;
16
  &#xD;
17
+ &lt;img src="//www.tobiasforkel.de/public/magento/forkel_bars/version/1.0/screenshots/backend/backend_bar_edit.gif" /&gt;&#xD;
18
+ &lt;br /&gt;&#xD;
19
+ &lt;br /&gt;&#xD;
20
+ &#xD;
21
  &lt;img src="//www.tobiasforkel.de/public/magento/forkel_bars/version/1.0/screenshots/backend/backend_bar_list_overview.gif" /&gt;&#xD;
22
  &lt;br /&gt;&#xD;
23
  &lt;br /&gt;&#xD;
65
  &#xD;
66
  &lt;h3&gt;Support&lt;/h3&gt;&#xD;
67
  &lt;p&gt;This module is provided as-is with no warranty or support. Purchase a Warranty and Support Package on &lt;a href="http://www.tobiasforkel.de"&gt;http://www.tobiasforkel.de&lt;/a&gt; starting from $50.&lt;/p&gt;</description>
68
+ <notes>===== 1.0.3 =====&#xD;
69
+ * Replaced "hostname" with a execution environment variable dropdown&#xD;
70
+ * Added SERVER_NAME as a default&#xD;
71
+ * Added style.css for notification bar&#xD;
72
+ * Added configuration tab in System &gt; Configuration&#xD;
73
+ * Fixed wrong translation xml path&#xD;
74
+ &#xD;
75
+ ===== 1.0.2 =====&#xD;
76
  * Wrong XML syntax in bars.xml.&#xD;
77
  * Simplified main.js with pure JavaScript. No Prototype anymore.&#xD;
78
  * Minimized main.js&#xD;
84
  ===== 1.0.0 =====&#xD;
85
  * Initial version of this module</notes>
86
  <authors><author><name>Tobias Forkel</name><user>tforkel</user><email>magento@tobiasforkel.de</email></author></authors>
87
+ <date>2016-09-25</date>
88
+ <time>12:54:03</time>
89
+ <contents><target name="magecommunity"><dir name="Forkel"><dir name="Bars"><dir name="Block"><dir name="Adminhtml"><dir name="Index"><dir name="Edit"><file name="Form.php" hash="98183881e27d929e1a5b43aaaecd611c"/></dir><file name="Edit.php" hash="0103c7c1c3459fce8605ed20abbd6e78"/><file name="Grid.php" hash="5a2dbf65cda4161d3b4d077302ec2e9f"/></dir><file name="Index.php" hash="525509035f5c44c2d8adc0967a052415"/><file name="Notification.php" hash="02aa79bb46584a3872a2cd6589e4ed8b"/><dir name="Server"><dir name="Edit"><file name="Form.php" hash="9ea81e92caf12a69bae34cca54cd0e92"/></dir><file name="Edit.php" hash="27810453296f514b1f381dbb1841ce43"/><file name="Grid.php" hash="f63d1ee50ae199d0a9270f51b3383cea"/></dir><file name="Server.php" hash="c993f4e4212e3b3ca3513ebb501def4a"/></dir></dir><file name="Changelog.txt" hash="d9cec18b9a81e8aae152e76289f93c03"/><dir name="controllers"><dir name="Adminhtml"><dir name="Forkel"><dir name="Bars"><file name="IndexController.php" hash="c6caff3224fd46a067e92b2a69e6f3fe"/><file name="ServerController.php" hash="1da8c0ef1465fdad96aaed34a74818ee"/></dir></dir></dir></dir><dir name="data"><dir name="forkel_bars_setup"><file name="data-install-1.0.0.php" hash="f7e401cecb403245a2ea001322d4f03d"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="835cff67082882a422825db514311675"/><file name="config.xml" hash="0550d413bb59cc6249dde3f27436589d"/><file name="system.xml" hash="5de53c92eb106ebb75ef7c448eb594dc"/></dir><dir name="Helper"><file name="Data.php" hash="e392727850db60b445e9ae775dbd4990"/></dir><dir name="Model"><file name="Index.php" hash="11721f1834493e8dbc875d07c38a6a3d"/><dir name="Resource"><dir name="Index"><file name="Collection.php" hash="1c9b8c4157f07777058eea128c683426"/></dir><file name="Index.php" hash="16f51afe18dba2f4bf1146ae1bf2a73a"/><dir name="Server"><file name="Collection.php" hash="da06239337f1b586285df29fd308200e"/></dir><file name="Server.php" hash="11141fe5a4646eda013b85e2e1ec7d07"/></dir><file name="Roles.php" hash="037b30f230e133eb28f73bcb44b7a7db"/><dir name="Server"><file name="Environment.php" hash="8765a66608ebebe69900d4ba5f1bf0b5"/></dir><file name="Server.php" hash="1b373759e53211ad488d2b5bf1ba2344"/></dir><dir name="sql"><dir name="forkel_bars_setup"><file name="install-1.0.0.php" hash="cc207c4656ef681ea86ac9961174a612"/><file name="upgrade-1.0.0-1.0.1.php" hash="7e40cd39ec5c7884e1934bd918b62e8d"/><file name="upgrade-1.0.2-1.0.3.php" hash="40ea2a36f4bc1e8ba1da6708bcbcf7aa"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><dir name="forkel"><file name="bars.xml" hash="7de21a059c6ea03101ec5e9c71667cfa"/></dir></dir><dir name="template"><dir name="forkel"><dir name="bars"><dir><dir name="adminhtml"><file name="notification.phtml" hash="8a64a0237618e6b0418f67ac4209fe9a"/></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Forkel_Bars.xml" hash="1b36f833bbcf2b4061f775a0a95dbdfe"/></dir></target><target name="mage"><dir name="js"><dir name="community"><dir name="forkel_bars"><file name="main.min.js" hash="9fc965c32ea6ad226f4add7c4ddaae11"/></dir></dir></dir></target><target name="magelocal"><dir name="de_DE"><file name="Forkel_Bars.csv" hash=""/></dir><dir name="en_US"><file name="Forkel_Bars.csv" hash=""/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="base"><dir name="default"><dir name="forkel"><dir name="bars"><file name="styles.css" hash="5f44a4fed9fc7cce1d8ea964eb3c0e46"/></dir></dir></dir></dir></dir></target></contents>
90
  <compatible/>
91
  <dependencies><required><php><min>5.4.0</min><max>5.6.16</max></php></required></dependencies>
92
  </package>
skin/adminhtml/base/default/forkel/bars/styles.css ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
1
+ #forkel_bars_adminhtml_notification {
2
+ display: none;
3
+ font-size: 1.2em;
4
+ overflow: hidden;
5
+ text-align: left;
6
+ padding: 1em 1.5em;
7
+ }