magento_mobile_assistant_manager - Version 0.1.10

Version Notes

-Bug Fixing for Product Stock Alerts

Download this release

Release Info

Developer Biztech
Extension magento_mobile_assistant_manager
Version 0.1.10
Comparing to
See all releases


Code changes from version 0.1.9 to 0.1.10

app/code/local/Biztech/Mobileassistant/Model/Observer.php CHANGED
@@ -4,18 +4,16 @@
4
  private static $_handleCustomerFirstOrderCounter = 1;
5
  private static $_handleCustomerFirstRegisterNotificationCounter = 1;
6
 
7
-
8
  /*inventory status-starts*/
9
  public function catalogInventorySave(Varien_Event_Observer $observer)
10
- {
11
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
12
  $event = $observer->getEvent();
13
  $_item = $event->getItem();
14
  $params = array();
15
  $params['product_id'] = $_item->getProductId();
16
- $params['name'] = $_item->getProductName();
17
- $params['qty'] = $_item->getProduct()->getStockItem()->getQty();
18
- //$params['qty_change'] = ($_item->getTotalQty());
19
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
20
  if($params['qty'] <= $minQty){
21
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
@@ -27,14 +25,13 @@
27
  public function subtractQuoteInventory(Varien_Event_Observer $observer)
28
  {
29
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
30
-
31
  $quote = $observer->getEvent()->getQuote();
32
  foreach ($quote->getAllItems() as $item) {
33
  $params = array();
34
  $params['product_id'] = $item->getProductId();
35
  $params['name'] = $item->getName();
36
  $params['qty'] = $item->getProduct()->getStockItem()->getQty();
37
- //$params['qty_change'] = ($_item->getTotalQty());
38
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
39
  if(($params['qty']-$params['qty_change']) <= $minQty){
40
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
@@ -47,14 +44,13 @@
47
  public function revertQuoteInventory(Varien_Event_Observer $observer)
48
  {
49
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
50
-
51
  $quote = $observer->getEvent()->getQuote();
52
  foreach ($quote->getAllItems() as $item) {
53
  $params = array();
54
  $params['product_id'] = $item->getProductId();
55
  $params['name'] = $item->getName();
56
  $params['qty'] = $item->getProduct()->getStockItem()->getQty();
57
- //$params['qty_change'] = ($_item->getTotalQty());
58
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
59
  if(($params['qty']+$params['qty_change']) <= $minQty){
60
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
@@ -62,13 +58,14 @@
62
  }
63
  }
64
  }
 
65
  /*inventory status- ends*/
66
 
67
 
68
  public function sales_order_save_after(Varien_Event_Observer $observer)
69
  {
70
  if(Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')){
71
-
72
  $action = Mage::app()->getFrontController()->getAction();
73
  if ($action->getFullActionName() == 'checkout_onepage_saveOrder')
74
  {
4
  private static $_handleCustomerFirstOrderCounter = 1;
5
  private static $_handleCustomerFirstRegisterNotificationCounter = 1;
6
 
 
7
  /*inventory status-starts*/
8
  public function catalogInventorySave(Varien_Event_Observer $observer)
9
+ {
10
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
11
  $event = $observer->getEvent();
12
  $_item = $event->getItem();
13
  $params = array();
14
  $params['product_id'] = $_item->getProductId();
15
+ $params['name'] = Mage::getModel('catalog/product')->load($params['product_id'])->getName();
16
+ $params['qty'] = $_item->getQty();
 
17
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
18
  if($params['qty'] <= $minQty){
19
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
25
  public function subtractQuoteInventory(Varien_Event_Observer $observer)
26
  {
27
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
 
28
  $quote = $observer->getEvent()->getQuote();
29
  foreach ($quote->getAllItems() as $item) {
30
  $params = array();
31
  $params['product_id'] = $item->getProductId();
32
  $params['name'] = $item->getName();
33
  $params['qty'] = $item->getProduct()->getStockItem()->getQty();
34
+ $params['qty_change'] = $item->getTotalQty();
35
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
36
  if(($params['qty']-$params['qty_change']) <= $minQty){
37
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
44
  public function revertQuoteInventory(Varien_Event_Observer $observer)
45
  {
46
  if (Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')) {
 
47
  $quote = $observer->getEvent()->getQuote();
48
  foreach ($quote->getAllItems() as $item) {
49
  $params = array();
50
  $params['product_id'] = $item->getProductId();
51
  $params['name'] = $item->getName();
52
  $params['qty'] = $item->getProduct()->getStockItem()->getQty();
53
+ $params['qty_change'] = $item->getTotalQty();
54
  $minQty = Mage::getStoreConfig('mobileassistant/mobileassistant_general/minimum_qty');
55
  if(($params['qty']+$params['qty_change']) <= $minQty){
56
  Mage::helper('mobileassistant')->pushNotification('product',$params['product_id'],$params);
58
  }
59
  }
60
  }
61
+
62
  /*inventory status- ends*/
63
 
64
 
65
  public function sales_order_save_after(Varien_Event_Observer $observer)
66
  {
67
  if(Mage::getStoreConfig('mobileassistant/mobileassistant_general/enabled')){
68
+
69
  $action = Mage::app()->getFrontController()->getAction();
70
  if ($action->getFullActionName() == 'checkout_onepage_saveOrder')
71
  {
app/code/local/Biztech/Mobileassistant/etc/config.xml CHANGED
@@ -10,7 +10,7 @@
10
  <config>
11
  <modules>
12
  <Biztech_Mobileassistant>
13
- <version>0.1.9</version>
14
  </Biztech_Mobileassistant>
15
  </modules>
16
  <frontend>
10
  <config>
11
  <modules>
12
  <Biztech_Mobileassistant>
13
+ <version>0.1.10</version>
14
  </Biztech_Mobileassistant>
15
  </modules>
16
  <frontend>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>magento_mobile_assistant_manager</name>
4
- <version>0.1.9</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
@@ -25,14 +25,11 @@ To ensure smooth working of this extension you need to download this extension i
25
  Application Download Link:&#xD;
26
  https://itunes.apple.com/us/app/magentomobilemanager/id695074519?mt=8&amp;ign-mpt=uo%3D4&#xD;
27
  </description>
28
- <notes>-Bug Fixes and Enhacements&#xD;
29
- -Added Provision Enable/Disable feature from Device&#xD;
30
- -Stock Alert On device&#xD;
31
- - Added order details in notification on device</notes>
32
  <authors><author><name>Biztech</name><user>biztechcon</user><email>sales@biztechconsultancy.com</email></author></authors>
33
- <date>2015-06-03</date>
34
- <time>05:45:41</time>
35
- <contents><target name="mageetc"><dir name="modules"><file name="Biztech_Mobileassistant.xml" hash="18d9cf7b8e516db899336adfd8210621"/><file name="Biztech_All.xml" hash="f4c3b9c029e56da8f09d7d71336c00f7"/></dir></target><target name="magelocal"><dir name="Biztech"><dir name="Mobileassistant"><dir name="Helper"><file name="Data.php" hash="c4c160896ad9aa366a5d3e3b58cb9417"/></dir><dir name="Model"><dir name="Mobileassistant"><file name="Api.php" hash="4e8e1f556fc8f1d9e6c2f520a3a84e52"/></dir><file name="Mobileassistant.php" hash="68e160bf752ec8c1facc514389c00849"/><dir name="Mysql4"><dir name="Mobileassistant"><file name="Collection.php" hash="e9319365535ec2c42429ea1d9dbdc097"/></dir><file name="Mobileassistant.php" hash="62dc51f43aa6dff1dc762646b71cd600"/></dir><file name="Observer.php" hash="24c60c285907e95cda85b2fed407aec8"/></dir><dir name="controllers"><file name="CustomerController.php" hash="35ba5c85e9b6042846fd919316fe09db"/><file name="DashboardController.php" hash="9b4976bf56373d7a82cf1c2d45b5563b"/><file name="IndexController.php" hash="270697d98f4aedf6012a5714536f814f"/><file name="OrderController.php" hash="cf76a6f679380eca13ce48b4ac855fee"/><file name="ProductController.php" hash="4dab0e0cb4f5dddf2cdeaab94e4f3b1e"/></dir><dir name="etc"><file name="api.xml" hash="7860c9fe0f121148eb2a3a498d1879b1"/><file name="config.xml" hash="6efc013dd918ea284ae1efc59df6d3ba"/><file name="system.xml" hash="ae22361f905daf8c8b39863afb9bab19"/></dir><dir name="sql"><dir name="mobileassistant_setup"><file name="mysql4-install-0.1.0.php" hash="4f06ae1c3c5362b88fae1b1951a6b02a"/><file name="mysql4-upgrade-0.1.0-0.1.4.php" hash="172e9ecba3b5b385cef1c257b2af4bfa"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="bd4adba7146d89fed6c548dd46a30a81"/><file name="mysql4-upgrade-0.1.5-0.1.6.php" hash="172e9ecba3b5b385cef1c257b2af4bfa"/></dir></dir></dir><dir name="All"><dir name="Helper"><file name="Data.php" hash="e856726fd089e7f73ca7de450b696419"/></dir><dir name="Model"><file name="All.php" hash="a9aeeb9c6d7be9cf20414f405efc878d"/><dir name="Mysql4"><dir name="All"><file name="Collection.php" hash="a1909236183d126f38e628b85bb57e81"/></dir><file name="All.php" hash="f02542393eb26eadfb9b92d901d2ac12"/></dir><dir name="Source"><dir name="Updates"><file name="Type.php" hash="fa695bf4764c2d93c7436ed54bde89ba"/></dir></dir><file name="Status.php" hash="30a6f0da7d9d45e1082da532d5f8dabc"/><file name="Update.php" hash="83ceddbab4d621545b9c7c4bccdec7c0"/></dir><dir name="etc"><file name="config.xml" hash="27e403cedb861da03753d28527d9c664"/><file name="system.xml" hash="17262087dc933d934e09ac04cafb4c51"/></dir></dir></dir></target><target name="mage"><dir name="lib"><dir name="mobileassistant"><file name="pushcert.pem" hash="37a517e3bdd6ee2e4c61af6699f7f21b"/></dir></dir></target></contents>
36
  <compatible/>
37
  <dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php></required></dependencies>
38
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>magento_mobile_assistant_manager</name>
4
+ <version>0.1.10</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
25
  Application Download Link:&#xD;
26
  https://itunes.apple.com/us/app/magentomobilemanager/id695074519?mt=8&amp;ign-mpt=uo%3D4&#xD;
27
  </description>
28
+ <notes>-Bug Fixing for Product Stock Alerts</notes>
 
 
 
29
  <authors><author><name>Biztech</name><user>biztechcon</user><email>sales@biztechconsultancy.com</email></author></authors>
30
+ <date>2015-06-08</date>
31
+ <time>06:20:01</time>
32
+ <contents><target name="mageetc"><dir name="modules"><file name="Biztech_Mobileassistant.xml" hash="18d9cf7b8e516db899336adfd8210621"/><file name="Biztech_All.xml" hash="f4c3b9c029e56da8f09d7d71336c00f7"/></dir></target><target name="magelocal"><dir name="Biztech"><dir name="Mobileassistant"><dir name="Helper"><file name="Data.php" hash="c4c160896ad9aa366a5d3e3b58cb9417"/></dir><dir name="Model"><dir name="Mobileassistant"><file name="Api.php" hash="4e8e1f556fc8f1d9e6c2f520a3a84e52"/></dir><file name="Mobileassistant.php" hash="68e160bf752ec8c1facc514389c00849"/><dir name="Mysql4"><dir name="Mobileassistant"><file name="Collection.php" hash="e9319365535ec2c42429ea1d9dbdc097"/></dir><file name="Mobileassistant.php" hash="62dc51f43aa6dff1dc762646b71cd600"/></dir><file name="Observer.php" hash="d02c2c14c3da1a87d01138ea9b101375"/></dir><dir name="controllers"><file name="CustomerController.php" hash="35ba5c85e9b6042846fd919316fe09db"/><file name="DashboardController.php" hash="9b4976bf56373d7a82cf1c2d45b5563b"/><file name="IndexController.php" hash="270697d98f4aedf6012a5714536f814f"/><file name="OrderController.php" hash="cf76a6f679380eca13ce48b4ac855fee"/><file name="ProductController.php" hash="4dab0e0cb4f5dddf2cdeaab94e4f3b1e"/></dir><dir name="etc"><file name="api.xml" hash="7860c9fe0f121148eb2a3a498d1879b1"/><file name="config.xml" hash="95b5428ffccac5384aa0e86c2deebbdd"/><file name="system.xml" hash="ae22361f905daf8c8b39863afb9bab19"/></dir><dir name="sql"><dir name="mobileassistant_setup"><file name="mysql4-install-0.1.0.php" hash="4f06ae1c3c5362b88fae1b1951a6b02a"/><file name="mysql4-upgrade-0.1.0-0.1.4.php" hash="172e9ecba3b5b385cef1c257b2af4bfa"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="bd4adba7146d89fed6c548dd46a30a81"/><file name="mysql4-upgrade-0.1.5-0.1.6.php" hash="172e9ecba3b5b385cef1c257b2af4bfa"/></dir></dir></dir><dir name="All"><dir name="Helper"><file name="Data.php" hash="e856726fd089e7f73ca7de450b696419"/></dir><dir name="Model"><file name="All.php" hash="a9aeeb9c6d7be9cf20414f405efc878d"/><dir name="Mysql4"><dir name="All"><file name="Collection.php" hash="a1909236183d126f38e628b85bb57e81"/></dir><file name="All.php" hash="f02542393eb26eadfb9b92d901d2ac12"/></dir><dir name="Source"><dir name="Updates"><file name="Type.php" hash="fa695bf4764c2d93c7436ed54bde89ba"/></dir></dir><file name="Status.php" hash="30a6f0da7d9d45e1082da532d5f8dabc"/><file name="Update.php" hash="83ceddbab4d621545b9c7c4bccdec7c0"/></dir><dir name="etc"><file name="config.xml" hash="27e403cedb861da03753d28527d9c664"/><file name="system.xml" hash="17262087dc933d934e09ac04cafb4c51"/></dir></dir></dir></target><target name="mage"><dir name="lib"><dir name="mobileassistant"><file name="pushcert.pem" hash="37a517e3bdd6ee2e4c61af6699f7f21b"/></dir></dir></target></contents>
33
  <compatible/>
34
  <dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php></required></dependencies>
35
  </package>