TroopID_Connect - Version 1.4.5

Version Notes

Improve order filtering by affiliation

Download this release

Release Info

Developer ID.me
Extension TroopID_Connect
Version 1.4.5
Comparing to
See all releases


Code changes from version 1.4.4 to 1.4.5

app/code/community/TroopID/Connect/Block/Adminhtml/Sales/Order/View/Tab/Affiliation.php CHANGED
@@ -2,8 +2,7 @@
2
 
3
  class TroopID_Connect_Block_Adminhtml_Sales_Order_View_Tab_Affiliation extends Mage_Adminhtml_Block_Template implements Mage_Adminhtml_Block_Widget_Tab_Interface {
4
 
5
- protected function _construct()
6
- {
7
  parent::_construct();
8
  $this->setTemplate("troopid/connect/affiliation.phtml");
9
  }
@@ -24,11 +23,11 @@ class TroopID_Connect_Block_Adminhtml_Sales_Order_View_Tab_Affiliation extends M
24
  return false;
25
  }
26
 
27
- public function getOrder(){
28
  return Mage::registry("current_order");
29
  }
30
 
31
- public function getUID() {
32
  return $this->getOrder()->getTroopidUid();
33
  }
34
 
2
 
3
  class TroopID_Connect_Block_Adminhtml_Sales_Order_View_Tab_Affiliation extends Mage_Adminhtml_Block_Template implements Mage_Adminhtml_Block_Widget_Tab_Interface {
4
 
5
+ protected function _construct() {
 
6
  parent::_construct();
7
  $this->setTemplate("troopid/connect/affiliation.phtml");
8
  }
23
  return false;
24
  }
25
 
26
+ public function getOrder() {
27
  return Mage::registry("current_order");
28
  }
29
 
30
+ public function getUUID() {
31
  return $this->getOrder()->getTroopidUid();
32
  }
33
 
app/code/community/TroopID/Connect/Model/Order/Observer.php CHANGED
@@ -3,18 +3,6 @@ class TroopID_Connect_Model_Order_Observer {
3
 
4
  protected $options = array();
5
 
6
- public function addCollection(Varien_Event_Observer $observer) {
7
- $collection = $observer->getOrderGridCollection();
8
-
9
- if (!isset($collection))
10
- return;
11
-
12
- $tablename = $collection->getTable("sales/order");
13
-
14
- $select = $collection->getSelect();
15
- $select->joinLeft(array("order" => $tablename), "order.entity_id = main_table.entity_id", array("troopid_scope"));
16
- }
17
-
18
  public function addColumn(Varien_Event_Observer $observer) {
19
  $block = $observer->getBlock();
20
 
@@ -30,8 +18,7 @@ class TroopID_Connect_Model_Order_Observer {
30
  "index" => "troopid_scope",
31
  "type" => "options",
32
  "filter" => "TroopID_Connect_Block_Widget_Grid_Column_Filter_Scope",
33
- "renderer" => "TroopID_Connect_Block_Widget_Grid_Column_Renderer_Scope",
34
- "filter_index" => "order.troopid_scope",
35
  ),
36
  "shipping_name"
37
  );
3
 
4
  protected $options = array();
5
 
 
 
 
 
 
 
 
 
 
 
 
 
6
  public function addColumn(Varien_Event_Observer $observer) {
7
  $block = $observer->getBlock();
8
 
18
  "index" => "troopid_scope",
19
  "type" => "options",
20
  "filter" => "TroopID_Connect_Block_Widget_Grid_Column_Filter_Scope",
21
+ "renderer" => "TroopID_Connect_Block_Widget_Grid_Column_Renderer_Scope"
 
22
  ),
23
  "shipping_name"
24
  );
app/code/community/TroopID/Connect/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <TroopID_Connect>
5
- <version>0.3.0</version>
6
  </TroopID_Connect>
7
  </modules>
8
 
2
  <config>
3
  <modules>
4
  <TroopID_Connect>
5
+ <version>0.4.0</version>
6
  </TroopID_Connect>
7
  </modules>
8
 
app/code/community/TroopID/Connect/sql/troopid_connect_setup/mysql4-upgrade-0.3.0-0.4.0.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ $this->startSetup();
4
+
5
+ $this->getConnection()->addColumn($this->getTable("sales/order_grid"), "troopid_affiliation", "varchar(255)");
6
+ $this->getConnection()->addColumn($this->getTable("sales/order_grid"), "troopid_uid", "varchar(255)");
7
+ $this->getConnection()->addColumn($this->getTable("sales/order_grid"), "troopid_scope", "varchar(255)");
8
+
9
+ $this->run("UPDATE sales_flat_order_grid a, sales_flat_order b SET a.troopid_affiliation = b.troopid_affiliation, a.troopid_uid = b.troopid_uid, a.troopid_scope = b.troopid_scope WHERE a.entity_id = b.entity_id");
10
+
11
+ $this->endSetup();
app/design/adminhtml/default/default/template/troopid/connect/affiliation.phtml CHANGED
@@ -20,7 +20,7 @@
20
  <label><?php echo Mage::helper("troopid_connect")->__("UUID") ?></label>
21
  </td>
22
  <td class="value">
23
- <strong><?php echo $this->getUID() ?></strong>
24
  </td>
25
  </tr>
26
  <tr>
20
  <label><?php echo Mage::helper("troopid_connect")->__("UUID") ?></label>
21
  </td>
22
  <td class="value">
23
+ <strong><?php echo $this->getUUID() ?></strong>
24
  </td>
25
  </tr>
26
  <tr>
package.xml CHANGED
@@ -1,19 +1,18 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>TroopID_Connect</name>
4
- <version>1.4.4</version>
5
  <stability>stable</stability>
6
  <license>OSL v3.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>ID.me Integration</summary>
10
  <description>N/A</description>
11
- <notes>Add ID.me affiliation filtering for orders&#xD;
12
- Update button assets</notes>
13
  <authors><author><name>ID.me</name><user>idme</user><email>support@id.me</email></author></authors>
14
- <date>2016-01-20</date>
15
- <time>20:07:12</time>
16
- <contents><target name="magecommunity"><dir name="TroopID"><dir name="Connect"><dir name="Block"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><dir name="View"><dir name="Tab"><file name="Affiliation.php" hash="5b38aa826f52b77a6357598b2361e23f"/></dir></dir></dir></dir><dir name="System"><dir name="Config"><file name="Custom.php" hash="0f7f75b4b55edb638d241852a0220b3f"/><file name="Instructions.php" hash="a723462553ee585ccf3c9ded256c2d55"/></dir></dir></dir><file name="Cart.php" hash="75f526c8e484328a45604c0c50bbf6a8"/><dir name="Widget"><dir name="Grid"><dir name="Column"><dir name="Filter"><file name="Scope.php" hash="672fc40540585ee36e8677135f37bfba"/></dir><dir name="Renderer"><file name="Scope.php" hash="daac97b9a2c3b442fb4cdabb2013b89a"/></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="72586f83d6d5b3b4208f242e410208db"/><file name="Oauth.php" hash="647c96311d574e8bec2d84099ea5b0d9"/></dir><dir name="Model"><dir name="Cart"><file name="Observer.php" hash="c837fb0c02ac02416200002d5e3b233c"/></dir><dir name="Order"><file name="Observer.php" hash="fa61d9c3dd9a5e2de302b3ee4d56ecd4"/></dir><dir name="Rule"><file name="Condition.php" hash="6f3de19ed93753c5695cbeb9b48cb0b0"/><file name="Observer.php" hash="ff3a6cc43e4d46401a4bbb37262f4f56"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Enabled.php" hash="103e4776ee228d313fcb63c0eefcb0db"/></dir></dir></dir></dir><dir name="controllers"><file name="AuthorizeController.php" hash="fa9f2560b2d04995091835935037cc2a"/></dir><dir name="etc"><file name="adminhtml.xml" hash="2bba51d29a0e9c444ff401a460a44142"/><file name="config.xml" hash="f3524e0e3f239e457d88f7a1c391aee7"/><file name="system.xml" hash="c066c7b80e5cf2e489b255d704cfc6c6"/></dir><dir name="sql"><dir name="troopid_connect_setup"><file name="mysql4-install-0.1.0.php" hash="2ed9e5f82407c756477d7fc2d3cd20ff"/><file name="mysql4-upgrade-0.2.0-0.3.0.php" hash="6160551e6951f91ab7ef18e887ea73a9"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="troopid"><file name="idme.css" hash="bc66179fc8bfe9f33d66be34929d964e"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="troopid"><file name="idme.css" hash="57964a12675c76bca426475515160dcc"/><dir name="images"><file name="logo.png" hash="65421456771898d7cbced7b99d4b56ea"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="TroopID_Connect.xml" hash="daae0990b13ba4071764efd4f9f674ec"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="troopid_connect.xml" hash="760c7d73dcab51068a0db524699b354e"/></dir><dir name="template"><dir name="troopid"><dir name="connect"><file name="affiliation.phtml" hash="8a02c93877c22287629f383f16bee34c"/></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="troopid_connect.xml" hash="f83172a0eaea9b8c185f49f0864bf8cb"/></dir><dir name="template"><dir name="troopid"><dir name="connect"><file name="callback.phtml" hash="71b10af7408d6f50999529c08aa75dfb"/><file name="cart.phtml" hash="41dc1e8dcbe61e48e7fd37deeaaedf35"/><file name="script.phtml" hash="5e281cd246f5d02fae91ff9742ee9088"/></dir></dir></dir></dir></dir></dir></target></contents>
17
  <compatible/>
18
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
19
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>TroopID_Connect</name>
4
+ <version>1.4.5</version>
5
  <stability>stable</stability>
6
  <license>OSL v3.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>ID.me Integration</summary>
10
  <description>N/A</description>
11
+ <notes>Improve order filtering by affiliation</notes>
 
12
  <authors><author><name>ID.me</name><user>idme</user><email>support@id.me</email></author></authors>
13
+ <date>2016-03-21</date>
14
+ <time>18:53:01</time>
15
+ <contents><target name="magecommunity"><dir name="TroopID"><dir name="Connect"><dir name="Block"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><dir name="View"><dir name="Tab"><file name="Affiliation.php" hash="28eb1f722a1649a3382ea4cf99b132ce"/></dir></dir></dir></dir><dir name="System"><dir name="Config"><file name="Custom.php" hash="0f7f75b4b55edb638d241852a0220b3f"/><file name="Instructions.php" hash="a723462553ee585ccf3c9ded256c2d55"/></dir></dir></dir><file name="Cart.php" hash="75f526c8e484328a45604c0c50bbf6a8"/><dir name="Widget"><dir name="Grid"><dir name="Column"><dir name="Filter"><file name="Scope.php" hash="672fc40540585ee36e8677135f37bfba"/></dir><dir name="Renderer"><file name="Scope.php" hash="daac97b9a2c3b442fb4cdabb2013b89a"/></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="72586f83d6d5b3b4208f242e410208db"/><file name="Oauth.php" hash="647c96311d574e8bec2d84099ea5b0d9"/></dir><dir name="Model"><dir name="Cart"><file name="Observer.php" hash="c837fb0c02ac02416200002d5e3b233c"/></dir><dir name="Order"><file name="Observer.php" hash="1c3d5c66ff6dad2b2d148e86ce1466a3"/></dir><dir name="Rule"><file name="Condition.php" hash="6f3de19ed93753c5695cbeb9b48cb0b0"/><file name="Observer.php" hash="ff3a6cc43e4d46401a4bbb37262f4f56"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Enabled.php" hash="103e4776ee228d313fcb63c0eefcb0db"/></dir></dir></dir></dir><dir name="controllers"><file name="AuthorizeController.php" hash="fa9f2560b2d04995091835935037cc2a"/></dir><dir name="etc"><file name="adminhtml.xml" hash="2bba51d29a0e9c444ff401a460a44142"/><file name="config.xml" hash="32f8816801d18d65b91096e90ae60f09"/><file name="system.xml" hash="c066c7b80e5cf2e489b255d704cfc6c6"/></dir><dir name="sql"><dir name="troopid_connect_setup"><file name="mysql4-install-0.1.0.php" hash="2ed9e5f82407c756477d7fc2d3cd20ff"/><file name="mysql4-upgrade-0.2.0-0.3.0.php" hash="6160551e6951f91ab7ef18e887ea73a9"/><file name="mysql4-upgrade-0.3.0-0.4.0.php" hash="1c1baf7dd3b7ef43629c1dc1562e9a91"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="troopid"><file name="idme.css" hash="bc66179fc8bfe9f33d66be34929d964e"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="troopid"><file name="idme.css" hash="57964a12675c76bca426475515160dcc"/><dir name="images"><file name="logo.png" hash="65421456771898d7cbced7b99d4b56ea"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="TroopID_Connect.xml" hash="daae0990b13ba4071764efd4f9f674ec"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="troopid_connect.xml" hash="760c7d73dcab51068a0db524699b354e"/></dir><dir name="template"><dir name="troopid"><dir name="connect"><file name="affiliation.phtml" hash="f7b6ea1c7b9db34cb69bd0b94e608692"/></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="troopid_connect.xml" hash="f83172a0eaea9b8c185f49f0864bf8cb"/></dir><dir name="template"><dir name="troopid"><dir name="connect"><file name="callback.phtml" hash="71b10af7408d6f50999529c08aa75dfb"/><file name="cart.phtml" hash="41dc1e8dcbe61e48e7fd37deeaaedf35"/><file name="script.phtml" hash="5e281cd246f5d02fae91ff9742ee9088"/></dir></dir></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>