Version Notes
2014
Download this release
Release Info
Developer | Frantisek Barancik |
Extension | TOPefekt_Magesms |
Version | 1.3.0 |
Comparing to | |
See all releases |
Code changes from version 1.2.1 to 1.3.0
- app/code/community/Topefekt/Magesms/Controller/Template/Action.php +1 -1
- app/code/community/Topefekt/Magesms/Helper/Data.php +1 -1
- app/code/community/Topefekt/Magesms/Model/Api.php +1 -1
- app/code/community/Topefekt/Magesms/Model/Hooks.php +1 -1
- app/code/community/Topefekt/Magesms/Model/Marketing/Filter/Birthdayall.php +1 -1
- app/code/community/Topefekt/Magesms/Model/Sms.php +1 -1
- app/code/community/Topefekt/Magesms/controllers/Adminhtml/Magesms/CustomersmsController.php +1 -1
- app/code/community/Topefekt/Magesms/etc/config.xml +1 -1
- app/code/community/Topefekt/Magesms/etc/system.xml +8 -2
- app/design/adminhtml/default/default/template/topefekt/magesms/customersms.phtml +2 -2
- package.xml +4 -4
app/code/community/Topefekt/Magesms/Controller/Template/Action.php
CHANGED
@@ -13,7 +13,7 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Controller_Template_Action extends Topefekt_Magesms_Controller_Action { public function templateAction() { $ia1a238c1f12f3901520c7ca55efa646e471f7f6e = new Varien_Object(); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setError(false); if ($this->getRequest()->getParams()) { $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2 = $this->getRequest(); if ($i1507c94b68f51b22087227858337782550edf618 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('action')) { try { switch ($i1507c94b68f51b22087227858337782550edf618) { case 'saveTemplate': $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate()); break; case 'loadTemplate': $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate(false)); break; case 'save': if ($this->getRequest()->isPost()) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->setData(array( 'name' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('saveName'), 'template' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('text'), 'unicode' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('unicode'), 'unique' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('unique'), 'date' => date('Y-m-d H:i:s'), 'type' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('type') )); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->save(); } break; case 'remove': if ($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('id')) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->load($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->delete(); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate(false)); } break; case 'restore': if ($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('id')) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->load($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->addData(array('data' => $iefc930e6dfdf3023610ed7d663c73d176a7544e0->getData())); } break; } } catch (Exception $i8c174347956f0a76258a09557543e84f88beb4a0) { Mage::getSingleton('adminhtml/session')->addError($i8c174347956f0a76258a09557543e84f88beb4a0->getMessage()); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setError(true); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setMessage($this->getLayout()->getMessagesBlock()->getGroupedHtml()); } } } $this->getResponse()->setBody($ia1a238c1f12f3901520c7ca55efa646e471f7f6e->toJson()); } protected function _prepareText($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null, $i7a5ea366969a291381fafa1448c9a2fafd34ad5e = null) { if (preg_match_all('/{(.*?)}/', $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $iebd691e534c6cf2e84cf8a88790a5271154fca05) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b[$iebd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$iebd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'] = Mage::getStoreConfig('web/unsecure/base_url', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getStoreConfig('general/store_information/name', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); if (empty($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { if (!empty($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getModel('core/store')->load($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->getName(); } else { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::app()->getStore()->getName(); } } } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'] = Mage::getStoreConfig('trans_email/ident_general/email', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'] = Mage::getStoreConfig('general/store_information/phone', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (is_object($i7a5ea366969a291381fafa1448c9a2fafd34ad5e) && $i7a5ea366969a291381fafa1448c9a2fafd34ad5e instanceof Varien_Object) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getTelephone(); } } foreach($i0933475b5bd80561a9f50282fd9eb0b8345cec4b as $i670253c23c6fcba76bc4256a88fdd8fbc1041039=>$if2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace('{'.$i670253c23c6fcba76bc4256a88fdd8fbc1041039.'}', $if2eee0665f163a28f4adcfe84e3fc666bf1bcd89, $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); } } return $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; } protected function _saveTemplate($iacea0d13bc5e2676192c06d68cb091dc0ce26320 = true) { $id82aaf2f437652c4b6efbd55703199f614e8e516 = ''; if ($iacea0d13bc5e2676192c06d68cb091dc0ce26320) { $i1791b2d1f89bb2bd83b34046f59125af207713db = $this->getLayout()->createBlock( 'Topefekt_Magesms_Block_Template', 'magesms_marketing_templateform', array('template' => 'topefekt/magesms/template/form.phtml') ); $id82aaf2f437652c4b6efbd55703199f614e8e516 = $i1791b2d1f89bb2bd83b34046f59125af207713db->toHtml(); } $i42cf41da37138d64d37b0778e6561aab5e1239d6 = $this->getLayout()->createBlock('magesms/template_template'); return $id82aaf2f437652c4b6efbd55703199f614e8e516.$i42cf41da37138d64d37b0778e6561aab5e1239d6->toHtml(); } protected function _initAction() { parent::_initAction(); $this->getLayout()->getBlock('head')->addJs('topefekt/template.js'); $i3358fd35282548f1f8ccafbf23d60a4ade466fd3 = '
|
17 |
Translator.add("Template has been loaded.", "'.$this->__('Template has been loaded.').'");
|
18 |
Translator.add("Template has been saved.", "'.$this->__('Template has been saved.').'");
|
19 |
Translator.add("Are you sure you want to remove the template?", "'.$this->__('Are you sure you want to remove the template?').'");
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Controller_Template_Action extends Topefekt_Magesms_Controller_Action { public function templateAction() { $ia1a238c1f12f3901520c7ca55efa646e471f7f6e = new Varien_Object(); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setError(false); if ($this->getRequest()->getParams()) { $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2 = $this->getRequest(); if ($i1507c94b68f51b22087227858337782550edf618 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('action')) { try { switch ($i1507c94b68f51b22087227858337782550edf618) { case 'saveTemplate': $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate()); break; case 'loadTemplate': $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate(false)); break; case 'save': if ($this->getRequest()->isPost()) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->setData(array( 'name' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('saveName'), 'template' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('text'), 'unicode' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('unicode'), 'unique' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('unique'), 'date' => date('Y-m-d H:i:s'), 'type' => $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('type') )); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->save(); } break; case 'remove': if ($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('id')) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->load($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->delete(); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setHtml($this->_saveTemplate(false)); } break; case 'restore': if ($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538 = $i628d8ebfdcd1b4d13c7bb90cffb2f53678d994d2->getParam('id')) { $iefc930e6dfdf3023610ed7d663c73d176a7544e0 = Mage::getModel('magesms/template'); $iefc930e6dfdf3023610ed7d663c73d176a7544e0->load($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->addData(array('data' => $iefc930e6dfdf3023610ed7d663c73d176a7544e0->getData())); } break; } } catch (Exception $i8c174347956f0a76258a09557543e84f88beb4a0) { Mage::getSingleton('adminhtml/session')->addError($i8c174347956f0a76258a09557543e84f88beb4a0->getMessage()); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setError(true); $ia1a238c1f12f3901520c7ca55efa646e471f7f6e->setMessage($this->getLayout()->getMessagesBlock()->getGroupedHtml()); } } } $this->getResponse()->setBody($ia1a238c1f12f3901520c7ca55efa646e471f7f6e->toJson()); } protected function _prepareText($i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null, $i7a5ea366969a291381fafa1448c9a2fafd34ad5e = null) { if (Mage::registry('magesms_store_id')) Mage::unregister('magesms_store_id'); Mage::register('magesms_store_id', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66, true); if (preg_match_all('/{(.*?)}/', $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $iebd691e534c6cf2e84cf8a88790a5271154fca05) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b[$iebd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$iebd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'] = Mage::getStoreConfig('web/unsecure/base_url', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getStoreConfig('general/store_information/name', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); if (empty($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { if (!empty($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getModel('core/store')->load($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->getName(); } else { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::app()->getStore()->getName(); } } } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'] = Mage::getStoreConfig('trans_email/ident_general/email', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'] = Mage::getStoreConfig('general/store_information/phone', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (is_object($i7a5ea366969a291381fafa1448c9a2fafd34ad5e) && $i7a5ea366969a291381fafa1448c9a2fafd34ad5e instanceof Varien_Object) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = $i7a5ea366969a291381fafa1448c9a2fafd34ad5e->getTelephone(); } } foreach($i0933475b5bd80561a9f50282fd9eb0b8345cec4b as $i670253c23c6fcba76bc4256a88fdd8fbc1041039=>$if2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace('{'.$i670253c23c6fcba76bc4256a88fdd8fbc1041039.'}', $if2eee0665f163a28f4adcfe84e3fc666bf1bcd89, $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); } } return $i7d411c0cc32cdb65ec82b9e8d79aa996946f5538fc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; } protected function _saveTemplate($iacea0d13bc5e2676192c06d68cb091dc0ce26320 = true) { $id82aaf2f437652c4b6efbd55703199f614e8e516 = ''; if ($iacea0d13bc5e2676192c06d68cb091dc0ce26320) { $i1791b2d1f89bb2bd83b34046f59125af207713db = $this->getLayout()->createBlock( 'Topefekt_Magesms_Block_Template', 'magesms_marketing_templateform', array('template' => 'topefekt/magesms/template/form.phtml') ); $id82aaf2f437652c4b6efbd55703199f614e8e516 = $i1791b2d1f89bb2bd83b34046f59125af207713db->toHtml(); } $i42cf41da37138d64d37b0778e6561aab5e1239d6 = $this->getLayout()->createBlock('magesms/template_template'); return $id82aaf2f437652c4b6efbd55703199f614e8e516.$i42cf41da37138d64d37b0778e6561aab5e1239d6->toHtml(); } protected function _initAction() { parent::_initAction(); $this->getLayout()->getBlock('head')->addJs('topefekt/template.js'); $i3358fd35282548f1f8ccafbf23d60a4ade466fd3 = '
|
17 |
Translator.add("Template has been loaded.", "'.$this->__('Template has been loaded.').'");
|
18 |
Translator.add("Template has been saved.", "'.$this->__('Template has been saved.').'");
|
19 |
Translator.add("Are you sure you want to remove the template?", "'.$this->__('Are you sure you want to remove the template?').'");
|
app/code/community/Topefekt/Magesms/Helper/Data.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Helper_Data extends Mage_Adminhtml_Helper_Data { public function prepareFilterString($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2) { $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array(); $i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2 = base64_decode($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2); parse_str($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2, $ia61712c27ea241bd7a543dc2b02ea572274d0322); array_walk_recursive($ia61712c27ea241bd7a543dc2b02ea572274d0322, array($this, 'decodeFilter')); return $ia61712c27ea241bd7a543dc2b02ea572274d0322; } public function decodeFilter(&$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89 = rawurldecode($ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89); } public function strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b) { return strlen(utf8_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b)); } public function substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dee10b1113e98c522f9d7b19b278ac191206cf98d, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424 = -1) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5 = preg_split('//u', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b, -1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd3f9e660973a05c72dd2df52c035747f20824128 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424 == -1 ? count($ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5) : $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac = ''; for($ibcdf76f8c9ddc330c79f805116a8bb146c43749d=$ibcdf76f8c9ddc330c79f805116a8bb146c43749dee10b1113e98c522f9d7b19b278ac191206cf98d; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d<$ibcdf76f8c9ddc330c79f805116a8bb146c43749dd3f9e660973a05c72dd2df52c035747f20824128; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d++) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac .= $ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d]; return $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac; } public function strpos($icf8e6d55f3b73687e31b5bfb7df726c05be874e6, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dfba351358ab7c7f378315c6b3cb913d7f4d7b0fa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d37e0852c5c95f9440a8999674f38c2ab1fbd56e2 = 0) { return mb_strpos($icf8e6d55f3b73687e31b5bfb7df726c05be874e6, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dfba351358ab7c7f378315c6b3cb913d7f4d7b0fa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d37e0852c5c95f9440a8999674f38c2ab1fbd56e2, 'UTF-8'); } public function detectLang($ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 = false) { if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90 = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475 = explode(';', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1]); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475[0])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475[0]; } $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getModel('magesms/country_lang')->getCollection(); $iff7e46827cbb6547116c592bf800f4687428abf9->addFilter('lang', strtolower($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[0])); foreach ($iff7e46827cbb6547116c592bf800f4687428abf9 as $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3) { return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 ? $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('iso2') : $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('country_name'); } if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])) { $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getModel('magesms/country_lang')->getCollection(); $iff7e46827cbb6547116c592bf800f4687428abf9->addFilter('lang', strtolower($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])); foreach ($iff7e46827cbb6547116c592bf800f4687428abf9 as $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3) { return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 ? $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('iso2') : $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('country_name'); } } Mage::log('Dont detect lang: '.$_SERVER['HTTP_ACCEPT_LANGUAGE']); } return 'en'; } public function formatPrice($ibcdf76f8c9ddc330c79f805116a8bb146c43749d58457975a91d59a84d2920953badcb7365ac1f01, $i2457499363c0873527a65aa9ad19ce774bd79cbc = 4) { return number_format((float)$ibcdf76f8c9ddc330c79f805116a8bb146c43749d58457975a91d59a84d2920953badcb7365ac1f01, $i2457499363c0873527a65aa9ad19ce774bd79cbc, ",", " "); } public function moreText($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83) { if($this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa) > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83): $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae = $this->strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, ' ', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424, 'UTF-8'); if($ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83 || $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae == 0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83; return "<span style=\"cursor:help;text-decoration:underline;\" title=\"".$ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa."\">".$this->substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, 0, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae)."...</span>"; else: return $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; endif; } public function isPhoneNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d9e76a736cd2ce866634b875b0e477fe802efd466) { return preg_match('/^[0-9]{7,18}$/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d9e76a736cd2ce866634b875b0e477fe802efd466); } public function isTextSender($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1e0ab2cc14bf21436fd5165a18812bf40da12d82) { return preg_match('/(?!^\d+$)^[0-9a-zA-Z_.]{3,11}$/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1e0ab2cc14bf21436fd5165a18812bf40da12d82); } public function countSms($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749de8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace("\r\n","\n", $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749de8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 = $this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 < 71) $if295547318143e26fc7026b92d58e3d1eec229db = 1; elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 % 67 == 0) $if295547318143e26fc7026b92d58e3d1eec229db= floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/67); else $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/67) + 1; } else { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 = $this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 < 161) $if295547318143e26fc7026b92d58e3d1eec229db = 1; elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 % 153 == 0) $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/153); else $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/153) + 1; } return $if295547318143e26fc7026b92d58e3d1eec229db; } public function prepareNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a, $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0 = 0; $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = ''; $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = str_replace(array(' ', '-', '(', ')', '/'), '', $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2); if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '+') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 1); if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '00') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 2); elseif (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '0') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = Mage::getSingleton('magesms/exceptions')->number($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd); $ibcdf76f8c9ddc330c79f805116a8bb146c43749db8c2593511e733deb36fb6bc932a747fcf3b754c = strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 = Mage::getSingleton('magesms/maps')->getCollection(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0->count()) { foreach ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { if (preg_match("/^".$ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea()."/", $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d45e0dbda03c5e1b049126d29f809da95d0e0aa03)) { $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 0, strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dc155ac0a2e7d522b71a8f6aae45a2917bd596596 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getNumber(); if (($ibcdf76f8c9ddc330c79f805116a8bb146c43749db8c2593511e733deb36fb6bc932a747fcf3b754c-strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea())) == $ibcdf76f8c9ddc330c79f805116a8bb146c43749dc155ac0a2e7d522b71a8f6aae45a2917bd596596) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0 = 1; continue; } } } } if(!$ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd.$ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2; if (!$ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd && $i7492a7ab99a6ff1e0ae253366480ecb40a550224) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = $i7492a7ab99a6ff1e0ae253366480ecb40a550224; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df = array( 'mobile' => $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 'prefix' => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, 'isms' => '', 'sendertype' => '', 'senderID' => '' ); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 = Mage::getSingleton('magesms/routes')->getCollection() ->addFieldToFilter('area', $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd) ->addFieldToFilter('type', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a); foreach ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['isms'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['isms']; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['sendertype'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['sendertype']; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['senderID'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['senderID']; if (!is_null($ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d898347c1def9d4effdd15deb4483c4b4a4aa8ab7 = Mage::getModel('core/store')->load($ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->getGroup()->getId(); $ida3b491904fb073f446bf820cd55a0ff69b347d1 = Mage::getSingleton('magesms/routes_alternative')->getCollection() ->addFieldToFilter('route_id', $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getId()) ->addFieldToFilter('store_group_id', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d898347c1def9d4effdd15deb4483c4b4a4aa8ab7); if ($ida3b491904fb073f446bf820cd55a0ff69b347d1->count()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['senderID'] = $ida3b491904fb073f446bf820cd55a0ff69b347d1->getFirstItem()->getTextsender(); } } } return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df; } public function getHooks($i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7137e40370cf1c5ccf937060891613788203e2d6 = 'default') { if ($i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc > 0) { $if739aceffec69fa2733946a3d319defaa354082d = Mage::getSingleton('magesms/hooks')->getCollection() ->addFieldToFilter('lang', Mage::getStoreConfig('magesms/template/language')) ->addFieldToFilter('owner', array('neq'=>1)) ->addFieldToFilter('`group`', $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc); } else { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks')->getCollection() ->addFieldToFilter('lang', Mage::getStoreConfig('magesms/template/language')) ->addFieldToFilter('owner', array('neq'=>1)) ->addFieldToFilter('`group`', $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc) ->getFirstItem(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd09e842bda9623afdb1b69812abe0b86eaf039c9 = Mage::getSingleton('sales/order_status')->getCollection(); $if739aceffec69fa2733946a3d319defaa354082d = array(); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd09e842bda9623afdb1b69812abe0b86eaf039c9 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05 = clone($i42ee48f418943c9662de0976069476c7dc8f620d); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5 = Mage::helper('sales')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getLabel()); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setTemplate(str_replace('{{order_status_name}}', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->getTemplate())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setTemplate2(str_replace('{{order_status_name}}', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->getTemplate2())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setName('orderStatus'.uc_words($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getStatus(), '')); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setStatusName($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getLabel()); $if739aceffec69fa2733946a3d319defaa354082d[] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05; } } $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array(); foreach($if739aceffec69fa2733946a3d319defaa354082d as $i42ee48f418943c9662de0976069476c7dc8f620d) { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$i42ee48f418943c9662de0976069476c7dc8f620d->getName()] = $i42ee48f418943c9662de0976069476c7dc8f620d; } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e = Mage::getSingleton('magesms/hooks_'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a)->getCollection(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a == 'customers') $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e->addFieldToFilter('mutation', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7137e40370cf1c5ccf937060891613788203e2d6); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e->count()) { foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getName(); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setSmstext($ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getSmstext()); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a == 'admins') { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getAdminId().'_'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getStoreGroupId()] = 1; $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setActive(1); } else { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setActive($ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getActive()); } } } } return $ia61712c27ea241bd7a543dc2b02ea572274d0322; } public function hookVariablesJS($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa) { if (preg_match_all('/{(.*?)}/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749da00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749da00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b[$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d322d20c6b1eb01ecb5d5801e003969fcc1f407a9 = Mage::getSingleton('magesms/variables')->getCollection() ->addFieldToFilter('name', array('in'=>array(array_keys($ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b)))); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d322d20c6b1eb01ecb5d5801e003969fcc1f407a9 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b[$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getName()] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate() ? Mage::helper('magesms')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate()) : $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate(); } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 = ''; foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039=>$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7)) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 .= ', '; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 .= $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039.': "'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89.'"'; } return $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7; } } public function filterDates($if66f788c75229f5f3ea1a622ab4dee258553c789, $ic78bc645a0f45c428f6551163ed2dce47dd289ee) { if (empty($ic78bc645a0f45c428f6551163ed2dce47dd289ee)) { return $if66f788c75229f5f3ea1a622ab4dee258553c789; } $i25d716f44b9a21507a214e968cc96805785eff97 = new Zend_Filter_LocalizedToNormalized(array( 'date_format' => Mage::app()->getLocale()->getDateFormat(Mage_Core_Model_Locale::FORMAT_TYPE_SHORT) )); $id1da71c6f00d9b85058894facc6aae99ed82822c = new Zend_Filter_NormalizedToLocalized(array( 'date_format' => Varien_Date::DATE_INTERNAL_FORMAT )); foreach ($ic78bc645a0f45c428f6551163ed2dce47dd289ee as $i36424a86007474ffc648c582cbfca240cda58c1e) { if (array_key_exists($i36424a86007474ffc648c582cbfca240cda58c1e, $if66f788c75229f5f3ea1a622ab4dee258553c789) && !empty($i36424a86007474ffc648c582cbfca240cda58c1e)) { $if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e] = $i25d716f44b9a21507a214e968cc96805785eff97->filter($if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e]); $if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e] = $id1da71c6f00d9b85058894facc6aae99ed82822c->filter($if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e]); } } return $if66f788c75229f5f3ea1a622ab4dee258553c789; } public function getCustomerCollection() { $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getResourceModel('customer/customer_collection') ->addNameToSelect() ->joinAttribute('billing_telephone', 'customer_address/telephone', 'default_billing', null, 'left') ->joinAttribute('shipping_telephone', 'customer_address/telephone', 'default_shipping', null, 'left') ->joinAttribute('billing_city', 'customer_address/city', 'default_billing', null, 'left') ->joinAttribute('billing_country_id', 'customer_address/country_id', 'default_billing', null, 'left') ->joinAttribute('shipping_country_id', 'customer_address/country_id', 'default_shipping', null, 'left') ->addFieldToFilter(array( array( 'attribute' => 'billing_telephone', array(array('notnull' => true), array('neq' => '')) ), array( 'attribute' => 'shipping_telephone', array(array('notnull' => true), array('neq' => '')) ) )); $iff7e46827cbb6547116c592bf800f4687428abf9->getSelect() ->columns('IF(`at_shipping_telephone`.`value`, `at_shipping_telephone`.`value`, `at_billing_telephone`.`value`) AS telephone'); $iff7e46827cbb6547116c592bf800f4687428abf9->getSelect() ->columns('IF(`at_shipping_country_id`.`value`, `at_shipping_country_id`.`value`, `at_billing_country_id`.`value`) AS country_id'); return $iff7e46827cbb6547116c592bf800f4687428abf9; } }
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Helper_Data extends Mage_Adminhtml_Helper_Data { public function prepareFilterString($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2) { $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array(); $i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2 = base64_decode($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2); parse_str($i215e94a3ecdacdf2b3af7056dddcbb72bf4f3ad2, $ia61712c27ea241bd7a543dc2b02ea572274d0322); array_walk_recursive($ia61712c27ea241bd7a543dc2b02ea572274d0322, array($this, 'decodeFilter')); return $ia61712c27ea241bd7a543dc2b02ea572274d0322; } public function decodeFilter(&$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89 = rawurldecode($ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89); } public function strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b) { return strlen(utf8_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b)); } public function substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dee10b1113e98c522f9d7b19b278ac191206cf98d, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424 = -1) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5 = preg_split('//u', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7c53db4e1e286ce8a65b930c9d93cdabb069954b, -1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd3f9e660973a05c72dd2df52c035747f20824128 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424 == -1 ? count($ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5) : $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac = ''; for($ibcdf76f8c9ddc330c79f805116a8bb146c43749d=$ibcdf76f8c9ddc330c79f805116a8bb146c43749dee10b1113e98c522f9d7b19b278ac191206cf98d; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d<$ibcdf76f8c9ddc330c79f805116a8bb146c43749dd3f9e660973a05c72dd2df52c035747f20824128; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d++) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac .= $ibcdf76f8c9ddc330c79f805116a8bb146c43749d353d238323208401995f652ac6757c9d9fd6d8d5[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d]; return $ibcdf76f8c9ddc330c79f805116a8bb146c43749d43e9cdc24374813037dc691df23094b5f8072dac; } public function strpos($icf8e6d55f3b73687e31b5bfb7df726c05be874e6, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dfba351358ab7c7f378315c6b3cb913d7f4d7b0fa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d37e0852c5c95f9440a8999674f38c2ab1fbd56e2 = 0) { return mb_strpos($icf8e6d55f3b73687e31b5bfb7df726c05be874e6, $ibcdf76f8c9ddc330c79f805116a8bb146c43749dfba351358ab7c7f378315c6b3cb913d7f4d7b0fa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d37e0852c5c95f9440a8999674f38c2ab1fbd56e2, 'UTF-8'); } public function detectLang($ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 = false) { if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90 = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475 = explode(';', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1]); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475[0])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749db473854f4b306e706e896b68ceb14665e7bc5475[0]; } $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getModel('magesms/country_lang')->getCollection(); $iff7e46827cbb6547116c592bf800f4687428abf9->addFilter('lang', strtolower($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[0])); foreach ($iff7e46827cbb6547116c592bf800f4687428abf9 as $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3) { return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 ? $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('iso2') : $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('country_name'); } if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])) { $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getModel('magesms/country_lang')->getCollection(); $iff7e46827cbb6547116c592bf800f4687428abf9->addFilter('lang', strtolower($ibcdf76f8c9ddc330c79f805116a8bb146c43749d593f9fb6306ab4cdb862f1ef6769504d63647c90[1])); foreach ($iff7e46827cbb6547116c592bf800f4687428abf9 as $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3) { return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dccb00baf62ef7b52dab4785b2fe3e5d6471b5d03 ? $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('iso2') : $i4cf0596ef3a67e5add95b49723a3c49aecd1dbd3->getData('country_name'); } } Mage::log('Dont detect lang: '.$_SERVER['HTTP_ACCEPT_LANGUAGE']); } return 'en'; } public function formatPrice($ibcdf76f8c9ddc330c79f805116a8bb146c43749d58457975a91d59a84d2920953badcb7365ac1f01, $i2457499363c0873527a65aa9ad19ce774bd79cbc = 4) { return number_format((float)$ibcdf76f8c9ddc330c79f805116a8bb146c43749d58457975a91d59a84d2920953badcb7365ac1f01, $i2457499363c0873527a65aa9ad19ce774bd79cbc, ",", " "); } public function moreText($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83) { if($this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa) > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83): $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae = $this->strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, ' ', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4616676bff4c07942c8542e6b4e0ccf29d473424, 'UTF-8'); if($ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83 || $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae == 0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d41874a76da96da0584b16b9f04de6e3f06863c83; return "<span style=\"cursor:help;text-decoration:underline;\" title=\"".$ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa."\">".$this->substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, 0, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d838a72d011cf88c91dfc0040ea07c7fa8e44c6ae)."...</span>"; else: return $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; endif; } public function isPhoneNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d9e76a736cd2ce866634b875b0e477fe802efd466) { return preg_match('/^[0-9]{7,18}$/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d9e76a736cd2ce866634b875b0e477fe802efd466); } public function isTextSender($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1e0ab2cc14bf21436fd5165a18812bf40da12d82) { return preg_match('/(?!^\d+$)^[0-9a-zA-Z_.]{3,11}$/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1e0ab2cc14bf21436fd5165a18812bf40da12d82); } public function countSms($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749de8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace("\r\n","\n", $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749de8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 = $this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 < 71) $if295547318143e26fc7026b92d58e3d1eec229db = 1; elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 % 67 == 0) $if295547318143e26fc7026b92d58e3d1eec229db= floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/67); else $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/67) + 1; } else { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 = $this->strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 < 161) $if295547318143e26fc7026b92d58e3d1eec229db = 1; elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956 % 153 == 0) $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/153); else $if295547318143e26fc7026b92d58e3d1eec229db = floor($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8cf55ea687bc1e974c51c5dbd65047184db69956/153) + 1; } return $if295547318143e26fc7026b92d58e3d1eec229db; } public function prepareNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a, $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0 = 0; $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = ''; $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = str_replace(array(' ', '-', '(', ')', '/'), '', $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2); if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '+') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 1); if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '00') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 2); elseif (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, '0') === 0 ) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = Mage::getSingleton('magesms/exceptions')->number($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd); $ibcdf76f8c9ddc330c79f805116a8bb146c43749db8c2593511e733deb36fb6bc932a747fcf3b754c = strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 = Mage::getSingleton('magesms/maps')->getCollection(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0->count()) { foreach ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { if (preg_match("/^".$ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea()."/", $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d45e0dbda03c5e1b049126d29f809da95d0e0aa03)) { $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 0, strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dc155ac0a2e7d522b71a8f6aae45a2917bd596596 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getNumber(); if (($ibcdf76f8c9ddc330c79f805116a8bb146c43749db8c2593511e733deb36fb6bc932a747fcf3b754c-strlen($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getArea())) == $ibcdf76f8c9ddc330c79f805116a8bb146c43749dc155ac0a2e7d522b71a8f6aae45a2917bd596596) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0 = 1; continue; } } } } if(!$ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd.$ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2; elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbad5149cd536c7e1f814c7b3874463985a5fc9e0 && $i7492a7ab99a6ff1e0ae253366480ecb40a550224) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = $i7492a7ab99a6ff1e0ae253366480ecb40a550224; if (!$ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd && $i7492a7ab99a6ff1e0ae253366480ecb40a550224) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = $i7492a7ab99a6ff1e0ae253366480ecb40a550224; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df = array( 'mobile' => $ibcdf76f8c9ddc330c79f805116a8bb146c43749daab7d0929a7000dca6467ef8cddbf22298ab81f2, 'prefix' => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, 'isms' => '', 'sendertype' => '', 'senderID' => '' ); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 = Mage::getSingleton('magesms/routes')->getCollection() ->addFieldToFilter('area', $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd) ->addFieldToFilter('type', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a); foreach ($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd567d29153b9150b8add34bc81058cd5432e46a0 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['isms'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['isms']; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['sendertype'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['sendertype']; $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['senderID'] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d['senderID']; if (!is_null($ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d898347c1def9d4effdd15deb4483c4b4a4aa8ab7 = Mage::getModel('core/store')->load($ibcdf76f8c9ddc330c79f805116a8bb146c43749d3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->getGroup()->getId(); $ida3b491904fb073f446bf820cd55a0ff69b347d1 = Mage::getSingleton('magesms/routes_alternative')->getCollection() ->addFieldToFilter('route_id', $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d->getId()) ->addFieldToFilter('store_group_id', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d898347c1def9d4effdd15deb4483c4b4a4aa8ab7); if ($ida3b491904fb073f446bf820cd55a0ff69b347d1->count()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df['senderID'] = $ida3b491904fb073f446bf820cd55a0ff69b347d1->getFirstItem()->getTextsender(); } } } return $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd96ad83fb93ea5189e8edb176831948b382810df; } public function getHooks($i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7137e40370cf1c5ccf937060891613788203e2d6 = 'default') { if (isset(Topefekt_Magesms_Model_Hooks::$groups[$i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc]) && $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc != 'order_status') { $if739aceffec69fa2733946a3d319defaa354082d = Mage::getSingleton('magesms/hooks')->getCollection() ->addFieldToFilter('lang', Mage::getStoreConfig('magesms/template/language')) ->addFieldToFilter('owner', array('neq'=>1)) ->addFieldToFilter('`group`', Topefekt_Magesms_Model_Hooks::$groups[$i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc]); } elseif (isset(Topefekt_Magesms_Model_Hooks::$groups[$i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc])) { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks')->getCollection() ->addFieldToFilter('lang', Mage::getStoreConfig('magesms/template/language')) ->addFieldToFilter('owner', array('neq'=>1)) ->addFieldToFilter('`group`', Topefekt_Magesms_Model_Hooks::$groups[$i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc]) ->getFirstItem(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd09e842bda9623afdb1b69812abe0b86eaf039c9 = Mage::getSingleton('sales/order_status')->getCollection(); $if739aceffec69fa2733946a3d319defaa354082d = array(); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd09e842bda9623afdb1b69812abe0b86eaf039c9 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05 = clone($i42ee48f418943c9662de0976069476c7dc8f620d); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5 = Mage::helper('sales')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getLabel()); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setTemplate(str_replace('{{order_status_name}}', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->getTemplate())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setTemplate2(str_replace('{{order_status_name}}', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0bd865ed0ae1ae72e839b8c033a4c0f7d84122b5, $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->getTemplate2())); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setName('orderStatus'.uc_words($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getStatus(), '')); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05->setStatusName($ibcdf76f8c9ddc330c79f805116a8bb146c43749d712821c3a64ae4a252ded9f3deaaddb6e942d985->getLabel()); $if739aceffec69fa2733946a3d319defaa354082d[] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d35f7502d936f0fb94b528aa6d4fbaca3f779fa05; } } else { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getModel('magesms/hooks'); Mage::dispatchEvent('topefekt_magesms_customersms_hook', array('hook' => $i42ee48f418943c9662de0976069476c7dc8f620d, 'mutation' => $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7137e40370cf1c5ccf937060891613788203e2d6)); } $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array(); foreach($if739aceffec69fa2733946a3d319defaa354082d as $i42ee48f418943c9662de0976069476c7dc8f620d) { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$i42ee48f418943c9662de0976069476c7dc8f620d->getName()] = $i42ee48f418943c9662de0976069476c7dc8f620d; } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e = Mage::getSingleton('magesms/hooks_'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a)->getCollection(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a == 'customers') $ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e->addFieldToFilter('mutation', $ibcdf76f8c9ddc330c79f805116a8bb146c43749d7137e40370cf1c5ccf937060891613788203e2d6); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e->count()) { foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d1ddb77d41f3678bb92f39c5c4d47aa6e58d4b89e as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getName(); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setSmstext($ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getSmstext()); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d30f20aafde612a957f7f966cb5b85e35782bc88a == 'admins') { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getAdminId().'_'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getStoreGroupId()] = 1; $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setActive(1); } else { $ia61712c27ea241bd7a543dc2b02ea572274d0322[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]->setActive($ibcdf76f8c9ddc330c79f805116a8bb146c43749d4df015c4c10bbcf1d38137f3659b01221d2dc076->getActive()); } } } } return $ia61712c27ea241bd7a543dc2b02ea572274d0322; } public function hookVariablesJS($ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa) { if (preg_match_all('/{(.*?)}/', $ibcdf76f8c9ddc330c79f805116a8bb146c43749ddfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ibcdf76f8c9ddc330c79f805116a8bb146c43749da00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749da00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b[$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d322d20c6b1eb01ecb5d5801e003969fcc1f407a9 = Mage::getSingleton('magesms/variables')->getCollection() ->addFieldToFilter('name', array('in'=>array(array_keys($ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b)))); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d322d20c6b1eb01ecb5d5801e003969fcc1f407a9 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b[$ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getName()] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate() ? Mage::helper('magesms')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate()) : $ibcdf76f8c9ddc330c79f805116a8bb146c43749debd691e534c6cf2e84cf8a88790a5271154fca05->getTemplate(); } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 = ''; foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749d0933475b5bd80561a9f50282fd9eb0b8345cec4b as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039=>$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7)) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 .= ', '; $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7 .= $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039.': "'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89.'"'; } return $ibcdf76f8c9ddc330c79f805116a8bb146c43749d5528ed14b056e3debe4695094269de3a98f76fe7; } } public function filterDates($if66f788c75229f5f3ea1a622ab4dee258553c789, $ic78bc645a0f45c428f6551163ed2dce47dd289ee) { if (empty($ic78bc645a0f45c428f6551163ed2dce47dd289ee)) { return $if66f788c75229f5f3ea1a622ab4dee258553c789; } $i25d716f44b9a21507a214e968cc96805785eff97 = new Zend_Filter_LocalizedToNormalized(array( 'date_format' => Mage::app()->getLocale()->getDateFormat(Mage_Core_Model_Locale::FORMAT_TYPE_SHORT) )); $id1da71c6f00d9b85058894facc6aae99ed82822c = new Zend_Filter_NormalizedToLocalized(array( 'date_format' => Varien_Date::DATE_INTERNAL_FORMAT )); foreach ($ic78bc645a0f45c428f6551163ed2dce47dd289ee as $i36424a86007474ffc648c582cbfca240cda58c1e) { if (array_key_exists($i36424a86007474ffc648c582cbfca240cda58c1e, $if66f788c75229f5f3ea1a622ab4dee258553c789) && !empty($i36424a86007474ffc648c582cbfca240cda58c1e)) { $if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e] = $i25d716f44b9a21507a214e968cc96805785eff97->filter($if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e]); $if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e] = $id1da71c6f00d9b85058894facc6aae99ed82822c->filter($if66f788c75229f5f3ea1a622ab4dee258553c789[$i36424a86007474ffc648c582cbfca240cda58c1e]); } } return $if66f788c75229f5f3ea1a622ab4dee258553c789; } public function getCustomerCollection() { $iff7e46827cbb6547116c592bf800f4687428abf9 = Mage::getResourceModel('customer/customer_collection') ->addNameToSelect() ->joinAttribute('billing_telephone', 'customer_address/telephone', 'default_billing', null, 'left') ->joinAttribute('shipping_telephone', 'customer_address/telephone', 'default_shipping', null, 'left') ->joinAttribute('billing_city', 'customer_address/city', 'default_billing', null, 'left') ->joinAttribute('billing_country_id', 'customer_address/country_id', 'default_billing', null, 'left') ->joinAttribute('shipping_country_id', 'customer_address/country_id', 'default_shipping', null, 'left') ->addFieldToFilter(array( array( 'attribute' => 'billing_telephone', array(array('notnull' => true), array('neq' => '')) ), array( 'attribute' => 'shipping_telephone', array(array('notnull' => true), array('neq' => '')) ) )); $iff7e46827cbb6547116c592bf800f4687428abf9->getSelect() ->columns('IF(`at_shipping_telephone`.`value`, `at_shipping_telephone`.`value`, `at_billing_telephone`.`value`) AS telephone'); $iff7e46827cbb6547116c592bf800f4687428abf9->getSelect() ->columns('IF(`at_shipping_country_id`.`value`, `at_shipping_country_id`.`value`, `at_billing_country_id`.`value`) AS country_id'); return $iff7e46827cbb6547116c592bf800f4687428abf9; } }
|
app/code/community/Topefekt/Magesms/Model/Api.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Model_Api extends Varien_Object { private $v9f1e7fea943b3d06ee78f55d3b61a95353536218 = 'Magento'; private $v9f1e7fea943b3d06ee78f55d3b61a95353536218_version; private $v240a8b53893ca3ef75eff909fc854708b004d86d; private $v178a3e710e3d4aca00fd843753ef02f29eb2145d; private $v45213b023462fa21483839e6493acb7cbe1faeab = 'smsmidlet.com'; private $v7d5fd66476c545cbe20f5b704f5ef46970896444 = '/api/api.php'; private $v9e19674cb6e6518d1f09715fae28b8fe6b262f87; private $v7cb5076e93f299085ab8c3bfa32e5712b4990f85 = 80; private $vb57aea5fc32ac2e31b4752c9f7610744dee1af4d = 443; private $v077a05d1aa14d236b9794734fee8900f425eefdf = 5; private $v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = 'auto'; private $vcb9f213798e6a676a15ee3c66b26bee41d69d0d4; private $vc4185f8999ea79fe5ab81e90671fb9efdd6f4bdb = false; public $data; public $query; private $v31d4e11356546b3c102ad42948b903df3b2dcbfc = array(); private $v8adb8a55748ba4eeb0af088f166489d679f689d0 = array(); public function __construct($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = null) { $this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version = Mage::getVersion(); $this->v240a8b53893ca3ef75eff909fc854708b004d86d = Mage::getConfig()->getModuleConfig('Topefekt_Magesms')->version; $this->v178a3e710e3d4aca00fd843753ef02f29eb2145d = Mage::getStoreConfig('magesms/appId'); if (empty($this->v178a3e710e3d4aca00fd843753ef02f29eb2145d)) $this->v178a3e710e3d4aca00fd843753ef02f29eb2145d = 'no-appId'; if ($i4fa8552ddebdef541b5cf2171f90a3e3066468e0) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; return $this; } private function f418217640effcf22811abf41fb6822676544f195($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = null) { if ($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 != null) { if (in_array($i4fa8552ddebdef541b5cf2171f90a3e3066468e0, array('auto', 'ssl', 'curl-ssl', 'no-ssl', 'curl'))) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'ssl') { @$this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = fsockopen('ssl://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab, $this->vb57aea5fc32ac2e31b4752c9f7610744dee1af4d, $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['ssl'], $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['ssl'], $this->v077a05d1aa14d236b9794734fee8900f425eefdf); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return 'ssl'; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'curl-ssl') { $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = curl_init('https://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab.$this->v7d5fd66476c545cbe20f5b704f5ef46970896444); $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'] = curl_errno($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['curl'] = curl_error($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && empty($this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'])) return 'curl-ssl'; $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'no-ssl') { @$this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = fsockopen($this->v45213b023462fa21483839e6493acb7cbe1faeab, $this->v7cb5076e93f299085ab8c3bfa32e5712b4990f85, $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['no-ssl'], $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['no-ssl'], $this->v077a05d1aa14d236b9794734fee8900f425eefdf); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return 'no-ssl'; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'curl') { $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = curl_init('http://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab.$this->v7d5fd66476c545cbe20f5b704f5ef46970896444); $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'] = curl_errno($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['curl'] = curl_error($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && empty($this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'])) return 'curl'; $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; } return false; } private function fba8eb60cc038de71062462629784762fcf874461($ia61712c27ea241bd7a543dc2b02ea572274d0322) { if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return false; $this->query = $ia61712c27ea241bd7a543dc2b02ea572274d0322; preg_match('/action=(.*?)&/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i43da24755ffd60b125b8d028fe9374322824e354); $i87f2ea938389759d33b89c6fb4d2e619c5e100fa = $i43da24755ffd60b125b8d028fe9374322824e354[1]; switch ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9) { case 'no-ssl': case 'ssl': fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "POST ".$this->v7d5fd66476c545cbe20f5b704f5ef46970896444." HTTP/1.0\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "User-Agent: Smsmidlet-api/1.0 (".$this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9."; ".$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218."; ".$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version."; call: $i87f2ea938389759d33b89c6fb4d2e619c5e100fa)\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Host: ".$this->v45213b023462fa21483839e6493acb7cbe1faeab."\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Content-type: application/x-www-form-urlencoded; charset=utf-8\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Content-length: ".strlen ($ia61712c27ea241bd7a543dc2b02ea572274d0322)."\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "\r\n".$ia61712c27ea241bd7a543dc2b02ea572274d0322."\r\n"); $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = ''; while (!feof($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) { @$i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 .= fgets($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, 2048); } $ie4a1f55ce89a34eb3838ef044286891434352fb7 = fclose($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); list($ie3dffdbcc706f9e096534318ed81a9f59e289e7d, $this->data) = explode("\r\n\r\n", $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3, 2); return $this->data; break; case 'curl': case 'curl-ssl': if (get_resource_type($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) == 'curl') { @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_POST, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_POSTFIELDS, $ia61712c27ea241bd7a543dc2b02ea572274d0322); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_FOLLOWLOCATION, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_HEADER, 0); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_RETURNTRANSFER, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_SSL_VERIFYPEER, false); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_USERAGENT,'Smsmidlet-api/1.0 ('.$this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9.'; '.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218.'; '.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version."; call: $i87f2ea938389759d33b89c6fb4d2e619c5e100fa )"); @$i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = curl_exec($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = html_entity_decode($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3); curl_close($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); return $this->data = $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } break; } return false; } public function getconnectMethod() { return $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9; } public function serverPost($ia61712c27ea241bd7a543dc2b02ea572274d0322, $i17c20960d197486b19dc890665362a4f2fd6f24a = true) { if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 != 'auto') $i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = $this->f418217640effcf22811abf41fb6822676544f195(); if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) $i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = $this->f418217640effcf22811abf41fb6822676544f195('auto'); if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return false; if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && isset($i4fa8552ddebdef541b5cf2171f90a3e3066468e0)) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = $this->fba8eb60cc038de71062462629784762fcf874461($ia61712c27ea241bd7a543dc2b02ea572274d0322.'&AppID='.$this->v178a3e710e3d4aca00fd843753ef02f29eb2145d.'&version='.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version.'&moduleVersion='.$this->v240a8b53893ca3ef75eff909fc854708b004d86d); $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; return $i17c20960d197486b19dc890665362a4f2fd6f24a ? $this->parser($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3) : $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } public function parser($ia61712c27ea241bd7a543dc2b02ea572274d0322, $ia9229b7048dd0adf905022d8569b2d2310c74a8d = ';') { if (is_bool($ia61712c27ea241bd7a543dc2b02ea572274d0322)) return $ia61712c27ea241bd7a543dc2b02ea572274d0322; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = array('errno' => 99, 'error' => 'Parse error: '.$ia61712c27ea241bd7a543dc2b02ea572274d0322, 'query' => $this->query, 'source' => $ia61712c27ea241bd7a543dc2b02ea572274d0322, 'data' => NULL, 'datasrc' => null); if (preg_match('/<b>(.*?)<\/b>/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i712821c3a64ae4a252ded9f3deaaddb6e942d985)) { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['errno'] = $i712821c3a64ae4a252ded9f3deaaddb6e942d985[1]; } if (preg_match('/<u>(.*)<\/u>/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i5528ed14b056e3debe4695094269de3a98f76fe7)) { if (!in_array($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['errno'], array(1, 11, 111))) { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['error'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['datasrc'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; } else { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['error'] = 'OK'; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['datasrc'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['data'] = explode($ia9229b7048dd0adf905022d8569b2d2310c74a8d, $i5528ed14b056e3debe4695094269de3a98f76fe7[1]); } } return $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } }
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Model_Api extends Varien_Object { private $v9f1e7fea943b3d06ee78f55d3b61a95353536218 = 'Magento'; private $v9f1e7fea943b3d06ee78f55d3b61a95353536218_version; private $v240a8b53893ca3ef75eff909fc854708b004d86d; private $v178a3e710e3d4aca00fd843753ef02f29eb2145d; private $v45213b023462fa21483839e6493acb7cbe1faeab = 'smsmidlet.com'; private $v7d5fd66476c545cbe20f5b704f5ef46970896444 = '/api/api.php'; private $v9e19674cb6e6518d1f09715fae28b8fe6b262f87; private $v7cb5076e93f299085ab8c3bfa32e5712b4990f85 = 80; private $vb57aea5fc32ac2e31b4752c9f7610744dee1af4d = 443; private $v077a05d1aa14d236b9794734fee8900f425eefdf = 5; private $v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = 'auto'; private $vcb9f213798e6a676a15ee3c66b26bee41d69d0d4; private $vc4185f8999ea79fe5ab81e90671fb9efdd6f4bdb = false; public $data; public $query; private $v31d4e11356546b3c102ad42948b903df3b2dcbfc = array(); private $v8adb8a55748ba4eeb0af088f166489d679f689d0 = array(); public function __construct($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = null) { $this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version = Mage::getVersion(); $this->v240a8b53893ca3ef75eff909fc854708b004d86d = Mage::getConfig()->getModuleConfig('Topefekt_Magesms')->version; $this->v178a3e710e3d4aca00fd843753ef02f29eb2145d = Mage::getStoreConfig('magesms/appId'); if (empty($this->v178a3e710e3d4aca00fd843753ef02f29eb2145d)) $this->v178a3e710e3d4aca00fd843753ef02f29eb2145d = 'no-appId'; if ($i4fa8552ddebdef541b5cf2171f90a3e3066468e0) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; return $this; } private function f418217640effcf22811abf41fb6822676544f195($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = null) { if ($i4fa8552ddebdef541b5cf2171f90a3e3066468e0 != null) { if (in_array($i4fa8552ddebdef541b5cf2171f90a3e3066468e0, array('auto', 'ssl', 'curl-ssl', 'no-ssl', 'curl'))) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'ssl') { @$this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = fsockopen('ssl://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab, $this->vb57aea5fc32ac2e31b4752c9f7610744dee1af4d, $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['ssl'], $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['ssl'], $this->v077a05d1aa14d236b9794734fee8900f425eefdf); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return 'ssl'; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'curl-ssl') { $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = curl_init('https://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab.$this->v7d5fd66476c545cbe20f5b704f5ef46970896444); $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'] = curl_errno($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['curl'] = curl_error($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && empty($this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'])) return 'curl-ssl'; $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'no-ssl') { @$this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = fsockopen($this->v45213b023462fa21483839e6493acb7cbe1faeab, $this->v7cb5076e93f299085ab8c3bfa32e5712b4990f85, $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['no-ssl'], $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['no-ssl'], $this->v077a05d1aa14d236b9794734fee8900f425eefdf); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return 'no-ssl'; } if ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'auto' || $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 == 'curl') { $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = curl_init('http://'.$this->v45213b023462fa21483839e6493acb7cbe1faeab.$this->v7d5fd66476c545cbe20f5b704f5ef46970896444); $this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'] = curl_errno($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $this->v8adb8a55748ba4eeb0af088f166489d679f689d0['curl'] = curl_error($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && empty($this->v31d4e11356546b3c102ad42948b903df3b2dcbfc['curl'])) return 'curl'; $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; } return false; } private function fba8eb60cc038de71062462629784762fcf874461($ia61712c27ea241bd7a543dc2b02ea572274d0322) { if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return false; $this->query = $ia61712c27ea241bd7a543dc2b02ea572274d0322; preg_match('/action=(.*?)&/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i43da24755ffd60b125b8d028fe9374322824e354); $i87f2ea938389759d33b89c6fb4d2e619c5e100fa = $i43da24755ffd60b125b8d028fe9374322824e354[1]; switch ($this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9) { case 'no-ssl': case 'ssl': fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "POST ".$this->v7d5fd66476c545cbe20f5b704f5ef46970896444." HTTP/1.0\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "User-Agent: Smsmidlet-api/1.0 (".$this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9."; ".$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218."; ".$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version."; call: $i87f2ea938389759d33b89c6fb4d2e619c5e100fa)\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Host: ".$this->v45213b023462fa21483839e6493acb7cbe1faeab."\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Content-type: application/x-www-form-urlencoded; charset=utf-8\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "Content-length: ".strlen ($ia61712c27ea241bd7a543dc2b02ea572274d0322)."\r\n"); fwrite($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, "\r\n".$ia61712c27ea241bd7a543dc2b02ea572274d0322."\r\n"); $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = ''; while (!feof($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) { @$i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 .= fgets($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, 2048); } $ie4a1f55ce89a34eb3838ef044286891434352fb7 = fclose($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); list($ie3dffdbcc706f9e096534318ed81a9f59e289e7d, $this->data) = explode("\r\n\r\n", $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3, 2); return $this->data; break; case 'curl': case 'curl-ssl': if (get_resource_type($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) == 'curl') { @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_POST, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_POSTFIELDS, $ia61712c27ea241bd7a543dc2b02ea572274d0322); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_FOLLOWLOCATION, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_HEADER, 0); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_RETURNTRANSFER, 1); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_SSL_VERIFYPEER, false); @curl_setopt($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87, CURLOPT_USERAGENT,'Smsmidlet-api/1.0 ('.$this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9.'; '.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218.'; '.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version."; call: $i87f2ea938389759d33b89c6fb4d2e619c5e100fa )"); @$i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = curl_exec($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = html_entity_decode($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3); curl_close($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87); return $this->data = $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } break; } return false; } public function getconnectMethod() { return $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9; } public function serverPost($ia61712c27ea241bd7a543dc2b02ea572274d0322, $i17c20960d197486b19dc890665362a4f2fd6f24a = true) { if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 != 'auto') $i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = $this->f418217640effcf22811abf41fb6822676544f195(); if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) $i4fa8552ddebdef541b5cf2171f90a3e3066468e0 = $this->f418217640effcf22811abf41fb6822676544f195('auto'); if (empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87)) return false; if (!empty($this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87) && isset($i4fa8552ddebdef541b5cf2171f90a3e3066468e0)) $this->v488f1ce59a4e07137e2e136095a7b0bc80a53bd9 = $i4fa8552ddebdef541b5cf2171f90a3e3066468e0; $i2f4c8461c23acd59e2d84b6cbd67931b74d28001 = ''; if (Mage::registry('magesms_store_id')) $i2f4c8461c23acd59e2d84b6cbd67931b74d28001 = '&storeid='.Mage::registry('magesms_store_id'); $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = $this->fba8eb60cc038de71062462629784762fcf874461($ia61712c27ea241bd7a543dc2b02ea572274d0322.$i2f4c8461c23acd59e2d84b6cbd67931b74d28001.'&AppID='.$this->v178a3e710e3d4aca00fd843753ef02f29eb2145d.'&version='.$this->v9f1e7fea943b3d06ee78f55d3b61a95353536218_version.'&moduleVersion='.$this->v240a8b53893ca3ef75eff909fc854708b004d86d); $this->v9e19674cb6e6518d1f09715fae28b8fe6b262f87 = null; return $i17c20960d197486b19dc890665362a4f2fd6f24a ? $this->parser($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3) : $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } public function parser($ia61712c27ea241bd7a543dc2b02ea572274d0322, $ia9229b7048dd0adf905022d8569b2d2310c74a8d = ';') { if (is_bool($ia61712c27ea241bd7a543dc2b02ea572274d0322)) return $ia61712c27ea241bd7a543dc2b02ea572274d0322; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3 = array('errno' => 99, 'error' => 'Parse error: '.$ia61712c27ea241bd7a543dc2b02ea572274d0322, 'query' => $this->query, 'source' => $ia61712c27ea241bd7a543dc2b02ea572274d0322, 'data' => NULL, 'datasrc' => null); if (preg_match('/<b>(.*?)<\/b>/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i712821c3a64ae4a252ded9f3deaaddb6e942d985)) { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['errno'] = $i712821c3a64ae4a252ded9f3deaaddb6e942d985[1]; } if (preg_match('/<u>(.*)<\/u>/', $ia61712c27ea241bd7a543dc2b02ea572274d0322, $i5528ed14b056e3debe4695094269de3a98f76fe7)) { if (!in_array($i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['errno'], array(1, 11, 111))) { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['error'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['datasrc'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; } else { $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['error'] = 'OK'; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['datasrc'] = $i5528ed14b056e3debe4695094269de3a98f76fe7[1]; $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3['data'] = explode($ia9229b7048dd0adf905022d8569b2d2310c74a8d, $i5528ed14b056e3debe4695094269de3a98f76fe7[1]); } } return $i3bd625bb1dc4606e8c0dc77ad823797f51341fc3; } }
|
app/code/community/Topefekt/Magesms/Model/Hooks.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Model_Hooks extends Mage_Core_Model_Abstract { protected function _construct() { $this->_init('magesms/hooks'); } public function send($i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5) { $i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18 = Mage::getSingleton('magesms/smsprofile'); if ($i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->user) { $i589c2cccd18de711ec5e779b98b9f98d0347a925 = Mage::app()->getStore()->getGroupId(); if (!$i589c2cccd18de711ec5e779b98b9f98d0347a925 && $i5e65dd16263683749d16a84171f719e768ed14b5->hasStoreId()) { $i589c2cccd18de711ec5e779b98b9f98d0347a925 = Mage::getModel('core/store')->load($i5e65dd16263683749d16a84171f719e768ed14b5->getStoreId())->getGroupId(); } if ($i5e65dd16263683749d16a84171f719e768ed14b5->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = $i5e65dd16263683749d16a84171f719e768ed14b5->getStore()->getId(); elseif (Mage::app()->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = Mage::app()->getStore()->getStoreId(); else $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null; $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8 = Mage::getSingleton('magesms/hooks_admins')->getCollection(); if ($i589c2cccd18de711ec5e779b98b9f98d0347a925 || !Mage::getSingleton('admin/session')->isLoggedIn()) { $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('store_group_id', $i589c2cccd18de711ec5e779b98b9f98d0347a925); } else { $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->getSelect()->group('admin_id'); } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus') $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('name', 'orderStatus'.ucfirst($i5e65dd16263683749d16a84171f719e768ed14b5->getStatus())); else $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('name', $i41496536c6b29c24b90c374d9fc25143f114dc9a); if ($ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->count()) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode')->getCollection() ->addFieldToFilter('type', 'admin')->getFirstItem(); foreach($ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8 as $i3d68c0cf53594c3449a7debf01d1c337a93fc4ae) { $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87 = Mage::getModel('magesms/admins')->load($i3d68c0cf53594c3449a7debf01d1c337a93fc4ae->getAdminId()); if (!$i2977ace3ff82db806c1e7c92dd6811f3d76f0e87) continue; $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f = Mage::getModel('magesms/sms'); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->addRecipient($i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getNumber(), array('recipient' => $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getName(), 'adminId' => $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getId())) ->setMessage($this->prepareText($i3d68c0cf53594c3449a7debf01d1c337a93fc4ae->getSmstext(), $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5)) ->setSubject($i41496536c6b29c24b90c374d9fc25143f114dc9a) ->setType(Topefekt_Magesms_Model_Sms::TYPE_ADMIN) ->setPriority(true) ->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()) ->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setHookName($i41496536c6b29c24b90c374d9fc25143f114dc9a); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->send(); } } $i71e09ed37bc7273d250df9932c1693668e879cdd = Mage::getSingleton('magesms/hooks_customers')->getCollection() ->addFieldToFilter('active', 1); if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus') $i71e09ed37bc7273d250df9932c1693668e879cdd->addFieldToFilter('name', 'orderStatus'.ucfirst($i5e65dd16263683749d16a84171f719e768ed14b5->getStatus())); else $i71e09ed37bc7273d250df9932c1693668e879cdd->addFieldToFilter('name', $i41496536c6b29c24b90c374d9fc25143f114dc9a); if ($i71e09ed37bc7273d250df9932c1693668e879cdd->count()) { $if2014d170e15e7f6f64523fd3238720980ceb64a = Mage::getSingleton('magesms/hooks_unicode')->getCollection() ->addFieldToFilter('type', 'customer'); if ($i5e65dd16263683749d16a84171f719e768ed14b5 instanceof Mage_Sales_Model_Order) { $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142 = Mage::getConfig()->getNode('default/config/optout')->sku; $ib8129b89cda7dae2cfe1b114353de8ba2385974e = Mage::getModel('catalog/product')->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->loadByAttribute('sku', $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142); if ($ib8129b89cda7dae2cfe1b114353de8ba2385974e && $ib8129b89cda7dae2cfe1b114353de8ba2385974e->getStatus() == Mage_Catalog_Model_Product_Status::STATUS_ENABLED) { $i32ce098f2dde8081cf3c4de31f52b408a6ad48be = $i5e65dd16263683749d16a84171f719e768ed14b5->getItemsCollection(); $ibfceba0b027e7caa5ff39764963a80a73f4cdfeb = false; foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { if ($i69a1201e93806d55c970dfb18feec53d221ba37b->getSku() == $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142) { $ibfceba0b027e7caa5ff39764963a80a73f4cdfeb = true; break; } } if (!$ibfceba0b027e7caa5ff39764963a80a73f4cdfeb) return $this; } if ($i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->getPrefbilling()) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getCountryId(); if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getCountryId(); } } else { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getCountryId(); if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getCountryId(); } } $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerId(); if (!$ifb2b31a17a2f13d19aebc5823ae02f42988a78f2) $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = 0; $i489c048e0604d314330360b5ee23b42f486ebb98 = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerName(); } else { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = ''; $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = $i5e65dd16263683749d16a84171f719e768ed14b5->getId(); } if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a = Mage::app()->getRequest()->getParams(); foreach(array('mobilenumber', 'phone', 'telephone', 'mobile') as $i670253c23c6fcba76bc4256a88fdd8fbc1041039) { if (!empty($ia8a35a47a8e61218e15d1a33dac64bdc2449c01a[$i670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a[$i670253c23c6fcba76bc4256a88fdd8fbc1041039]; $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = Mage::getStoreConfig('general/country/default', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66);; break; } } } if ($i1f1945594819c4321de45ac15ed6d4dc07f41e2f && is_numeric($ifb2b31a17a2f13d19aebc5823ae02f42988a78f2)) { if ($idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b) { $i854b57231c05dbaa7f22331dbaed4152a402d2f1 = new Zend_Locale_Data(); $i065c883e3f45e58104d21f8196ee3fe9bd2f513d = $i854b57231c05dbaa7f22331dbaed4152a402d2f1->getList('en-EN', 'phonetoterritory'); $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = $i065c883e3f45e58104d21f8196ee3fe9bd2f513d[$idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b]; } else { $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = ''; } $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = ''; foreach($i71e09ed37bc7273d250df9932c1693668e879cdd as $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7) { if ($ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getMutation() == $i7492a7ab99a6ff1e0ae253366480ecb40a550224) { $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getSmstext(); break; } elseif ($ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getMutation() == 'default') $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getSmstext(); } if ($i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f) { $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f = Mage::getModel('magesms/sms'); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->addRecipient($i1f1945594819c4321de45ac15ed6d4dc07f41e2f, array('recipient' => $i489c048e0604d314330360b5ee23b42f486ebb98, 'customerId' => $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2, 'country' => $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b)) ->setMessage($this->prepareText($i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f, $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5)) ->setSubject($i41496536c6b29c24b90c374d9fc25143f114dc9a) ->setType(Topefekt_Magesms_Model_Sms::TYPE_CUSTOMER) ->setPriority(true) ->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); foreach($if2014d170e15e7f6f64523fd3238720980ceb64a as $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { if ($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getArea() == $i7492a7ab99a6ff1e0ae253366480ecb40a550224) { $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()); break; } elseif ($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getArea() == 'default') $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()); } $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setHookName($i41496536c6b29c24b90c374d9fc25143f114dc9a); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->send(); } } } } return $this; } public function prepareText($idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5) { if (preg_match_all('/{(.*?)}/', $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $iebd691e534c6cf2e84cf8a88790a5271154fca05) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b[$iebd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$iebd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } if ($i5e65dd16263683749d16a84171f719e768ed14b5->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = $i5e65dd16263683749d16a84171f719e768ed14b5->getStore()->getId(); elseif (Mage::app()->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = Mage::app()->getStore()->getStoreId(); else $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null; if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'])) { $ic157485eecbe64d400493d7b9e7f434b83aca5d0 = parse_url(Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB)); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'] = $ic157485eecbe64d400493d7b9e7f434b83aca5d0['host'].($ic157485eecbe64d400493d7b9e7f434b83aca5d0['path'] != '/' ? $ic157485eecbe64d400493d7b9e7f434b83aca5d0['path'] : ''); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getStoreConfig('general/store_information/name', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name2'] = Mage::app()->getStore()->getName(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'] = Mage::getStoreConfig('trans_email/ident_general/email', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'] = Mage::getStoreConfig('general/store_information/phone', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'contactForm') { $iacbd1c78463510856e506611fe14b5e1173581a6 = Mage::app()->getRequest(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('email')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_name'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('name')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('telephone')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short1'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 120); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short2'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 100); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short3'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short3'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 80); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'customerRegisterSuccess') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_password'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_password'] = Mage::app()->getRequest()->getParam('password'); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getLastname(); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'newOrder' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderTrackingNumber') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerLastname(); } if (!isset($i22b151d2a920ca46892d343096abbccfad9f3678)) $i22b151d2a920ca46892d343096abbccfad9f3678 = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_company'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_company'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCompany(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_address'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_address'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getStreet(1); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_postcode'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_postcode'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getPostcode(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_city'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_city'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCity(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_country'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_country'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCountry(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_state'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_state'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getRegion(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getTelephone(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_vat_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_vat_number'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getVatId(); } if (!isset($i560c12365c45b205daa0512840c70486783226b1)) $i560c12365c45b205daa0512840c70486783226b1 = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_company'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_company'] = $i560c12365c45b205daa0512840c70486783226b1->getCompany(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_firstname'] = $i560c12365c45b205daa0512840c70486783226b1->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_lastname'] = $i560c12365c45b205daa0512840c70486783226b1->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_address'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_address'] = $i560c12365c45b205daa0512840c70486783226b1->getStreet(1); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_postcode'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_postcode'] = $i560c12365c45b205daa0512840c70486783226b1->getPostcode(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_city'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_city'] = $i560c12365c45b205daa0512840c70486783226b1->getCity(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_country'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_country'] = $i560c12365c45b205daa0512840c70486783226b1->getCountry(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_state'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_state'] = $i560c12365c45b205daa0512840c70486783226b1->getRegion(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_phone'] = $i560c12365c45b205daa0512840c70486783226b1->getTelephone(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_vat_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_vat_number'] = $i560c12365c45b205daa0512840c70486783226b1->getVatId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getIncrementId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getPayment()->getMethodInstance()->getTitle(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment_html'])) { $ic078737049591e1e2db7c285f3e3b95cb867c6d0 = Mage::helper('payment')->getInfoBlock($i5e65dd16263683749d16a84171f719e768ed14b5->getPayment()) ->setIsSecureMode(true); $ic078737049591e1e2db7c285f3e3b95cb867c6d0->getMethod()->setStore($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); $i42745015bca99637011d2ba8a559beb3a8b0961f = strip_tags($ic078737049591e1e2db7c285f3e3b95cb867c6d0->toHtml()); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace('/ +/', ' ', $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/ \n/", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/\n /", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/\n\n+/", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment_html'] = trim($i42745015bca99637011d2ba8a559beb3a8b0961f); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_total_paid'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_total_paid'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getGrandTotal(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_currency'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_currency'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getOrderCurrency()->getCurrencyCode(); } $this->f2b4066ec99f97011a4a9f20dd18d97b5a49b8b51($i0933475b5bd80561a9f50282fd9eb0b8345cec4b, $i5e65dd16263683749d16a84171f719e768ed14b5->getCreatedAt()); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'])) { $ifd002a4ef735f38a6030baa73fafafa1118ff492 = Mage::getModel('ecommerceteam_ddc/order'); if ($ifd002a4ef735f38a6030baa73fafafa1118ff492) { $i82d8f80a6f30d2bff1b6b037fd170117a61f4e69 = $ifd002a4ef735f38a6030baa73fafafa1118ff492->load($i5e65dd16263683749d16a84171f719e768ed14b5->getEntityId(), 'order_id')->getData(); if (isset($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['order_id'])) { if (strtotime($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['delivery_date'])) { $i5b8dea0c150539c8b78ffa4a4ee9b4ea0bf09414 = Mage::getSingleton('core/locale')->date($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['delivery_date'], Zend_Date::ISO_8601, null, false)->toString(Mage::app()->getLocale()->getDateFormat(Mage_Core_Model_Locale::FORMAT_TYPE_FULL)); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'] = $i5b8dea0c150539c8b78ffa4a4ee9b4ea0bf09414; } } elseif ($i2d35534ee8eb5c1c7e742a61e000486ce24db667 = Mage::app()->getRequest()->getParam('delivery_date')) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'] = $i2d35534ee8eb5c1c7e742a61e000486ce24db667; } } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'newOrder') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['cart_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['cart_id'] = Mage::getSingleton('checkout/session')->getQuoteId(); } $i32ce098f2dde8081cf3c4de31f52b408a6ad48be = $i5e65dd16263683749d16a84171f719e768ed14b5->getItemsCollection(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder1'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getName().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder1'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder2'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = 'id:'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getId().', ' .Mage::helper('magesms')->__('name').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getName().', ' .Mage::helper('magesms')->__('qty').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder2'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder3'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder3'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder4'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = 'id:'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getId().', ' .Mage::helper('magesms')->__('qty').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder4'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder5'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getSku().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder5'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderTrackingNumber') { $i9805d668f75b6b461f88474f57c5f6aa86a87316 = $i5e65dd16263683749d16a84171f719e768ed14b5->getTracksCollection()->getLastItem(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['carrier_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['carrier_name'] = $i9805d668f75b6b461f88474f57c5f6aa86a87316->getTitle(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_shipping_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_shipping_number'] = $i9805d668f75b6b461f88474f57c5f6aa86a87316->getTrackNumber(); } $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87 = Mage::getSingleton('admin/session')->getUser(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_id'] = $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_email'] = $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getEmail(); } } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'productOutOfStock' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'productLowStock') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getProductId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_quantity'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_quantity'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getQty(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'])) { $i69a1201e93806d55c970dfb18feec53d221ba37b = Mage::getModel('catalog/product'); $i69a1201e93806d55c970dfb18feec53d221ba37b->load($i5e65dd16263683749d16a84171f719e768ed14b5->getProductId()); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name'] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getName(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getSku(); } } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { if ($i21e55df616c305955791876c1eb4da83448beba2 = Mage::getSingleton('customer/session')->getCustomer()) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i21e55df616c305955791876c1eb4da83448beba2->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i21e55df616c305955791876c1eb4da83448beba2->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i21e55df616c305955791876c1eb4da83448beba2->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i21e55df616c305955791876c1eb4da83448beba2->getFirstname(); } } } } foreach($i0933475b5bd80561a9f50282fd9eb0b8345cec4b as $i670253c23c6fcba76bc4256a88fdd8fbc1041039=>$if2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace('{'.$i670253c23c6fcba76bc4256a88fdd8fbc1041039.'}', $if2eee0665f163a28f4adcfe84e3fc666bf1bcd89, $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); } } return $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; } private function f2b4066ec99f97011a4a9f20dd18d97b5a49b8b51(&$i0933475b5bd80561a9f50282fd9eb0b8345cec4b, $i53ddb2282ac3aca0d44abe35abcf69959ed66574) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date'] = $i53ddb2282ac3aca0d44abe35abcf69959ed66574; } $i17c20960d197486b19dc890665362a4f2fd6f24a = date_parse($i53ddb2282ac3aca0d44abe35abcf69959ed66574); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date1'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date2'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date3'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date3'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date4'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date4'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['year'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date5'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date5'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date6'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date6'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date7'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date7'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['hour'].':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['minute']); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time1'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['hour'].':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['minute']).':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['second']); } } }
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Model_Hooks extends Mage_Core_Model_Abstract { public static $groups = array( 'order_status' => 0, 'order' => 1, 'account' => 2 ); protected function _construct() { $this->_init('magesms/hooks'); } public function send($i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5) { $i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18 = Mage::getSingleton('magesms/smsprofile'); if ($i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->user) { $i589c2cccd18de711ec5e779b98b9f98d0347a925 = Mage::app()->getStore()->getGroupId(); if (!$i589c2cccd18de711ec5e779b98b9f98d0347a925 && $i5e65dd16263683749d16a84171f719e768ed14b5->hasStoreId()) { $i589c2cccd18de711ec5e779b98b9f98d0347a925 = Mage::getModel('core/store')->load($i5e65dd16263683749d16a84171f719e768ed14b5->getStoreId())->getGroupId(); } if ($i5e65dd16263683749d16a84171f719e768ed14b5->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = $i5e65dd16263683749d16a84171f719e768ed14b5->getStore()->getId(); elseif (Mage::app()->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = Mage::app()->getStore()->getStoreId(); else $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null; if (Mage::registry('magesms_store_id')) Mage::unregister('magesms_store_id'); Mage::register('magesms_store_id', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66, true); $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8 = Mage::getSingleton('magesms/hooks_admins')->getCollection(); if ($i589c2cccd18de711ec5e779b98b9f98d0347a925 || !Mage::getSingleton('admin/session')->isLoggedIn()) { $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('store_group_id', $i589c2cccd18de711ec5e779b98b9f98d0347a925); } else { $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->getSelect()->group('admin_id'); } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus') $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('name', 'orderStatus'.ucfirst($i5e65dd16263683749d16a84171f719e768ed14b5->getStatus())); else $ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->addFieldToFilter('name', $i41496536c6b29c24b90c374d9fc25143f114dc9a); if ($ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8->count()) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode')->getCollection() ->addFieldToFilter('type', 'admin')->getFirstItem(); foreach($ib8622dd6b5bb413f7d6f85eb31e2abce529ae0a8 as $i3d68c0cf53594c3449a7debf01d1c337a93fc4ae) { $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87 = Mage::getModel('magesms/admins')->load($i3d68c0cf53594c3449a7debf01d1c337a93fc4ae->getAdminId()); if (!$i2977ace3ff82db806c1e7c92dd6811f3d76f0e87) continue; $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f = Mage::getModel('magesms/sms'); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->addRecipient($i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getNumber(), array('recipient' => $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getName(), 'adminId' => $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getId())) ->setMessage($this->prepareText($i3d68c0cf53594c3449a7debf01d1c337a93fc4ae->getSmstext(), $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5)) ->setSubject($i41496536c6b29c24b90c374d9fc25143f114dc9a) ->setType(Topefekt_Magesms_Model_Sms::TYPE_ADMIN) ->setPriority(true) ->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()) ->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setHookName($i41496536c6b29c24b90c374d9fc25143f114dc9a); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->send(); } } $i71e09ed37bc7273d250df9932c1693668e879cdd = Mage::getSingleton('magesms/hooks_customers')->getCollection() ->addFieldToFilter('active', 1); if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus') $i71e09ed37bc7273d250df9932c1693668e879cdd->addFieldToFilter('name', 'orderStatus'.ucfirst($i5e65dd16263683749d16a84171f719e768ed14b5->getStatus())); else $i71e09ed37bc7273d250df9932c1693668e879cdd->addFieldToFilter('name', $i41496536c6b29c24b90c374d9fc25143f114dc9a); if ($i71e09ed37bc7273d250df9932c1693668e879cdd->count()) { $if2014d170e15e7f6f64523fd3238720980ceb64a = Mage::getSingleton('magesms/hooks_unicode')->getCollection() ->addFieldToFilter('type', 'customer'); if ($i5e65dd16263683749d16a84171f719e768ed14b5 instanceof Mage_Sales_Model_Order) { $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142 = Mage::getConfig()->getNode('default/config/optout')->sku; $ib8129b89cda7dae2cfe1b114353de8ba2385974e = Mage::getModel('catalog/product')->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66)->loadByAttribute('sku', $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142); if ($ib8129b89cda7dae2cfe1b114353de8ba2385974e && $ib8129b89cda7dae2cfe1b114353de8ba2385974e->getStatus() == Mage_Catalog_Model_Product_Status::STATUS_ENABLED) { $i32ce098f2dde8081cf3c4de31f52b408a6ad48be = $i5e65dd16263683749d16a84171f719e768ed14b5->getItemsCollection(); $ibfceba0b027e7caa5ff39764963a80a73f4cdfeb = false; foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { if ($i69a1201e93806d55c970dfb18feec53d221ba37b->getSku() == $ic010a5d08128ec6abcd0a1a16cb1d8abe7bf2142) { $ibfceba0b027e7caa5ff39764963a80a73f4cdfeb = true; break; } } if (!$ibfceba0b027e7caa5ff39764963a80a73f4cdfeb) return $this; } if ($i6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->getPrefbilling()) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getCountryId(); if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getCountryId(); } } else { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress()->getCountryId(); if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getTelephone(); $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress()->getCountryId(); } } $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerId(); if (!$ifb2b31a17a2f13d19aebc5823ae02f42988a78f2) $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = 0; $i489c048e0604d314330360b5ee23b42f486ebb98 = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerName(); } else { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = ''; $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2 = $i5e65dd16263683749d16a84171f719e768ed14b5->getId(); } if (!$i1f1945594819c4321de45ac15ed6d4dc07f41e2f) { $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a = Mage::app()->getRequest()->getParams(); foreach(array('mobilenumber', 'phone', 'telephone', 'mobile') as $i670253c23c6fcba76bc4256a88fdd8fbc1041039) { if (!empty($ia8a35a47a8e61218e15d1a33dac64bdc2449c01a[$i670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i1f1945594819c4321de45ac15ed6d4dc07f41e2f = $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a[$i670253c23c6fcba76bc4256a88fdd8fbc1041039]; $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b = Mage::getStoreConfig('general/country/default', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66);; break; } } } if ($i1f1945594819c4321de45ac15ed6d4dc07f41e2f && is_numeric($ifb2b31a17a2f13d19aebc5823ae02f42988a78f2)) { if ($idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b) { $i854b57231c05dbaa7f22331dbaed4152a402d2f1 = new Zend_Locale_Data(); $i065c883e3f45e58104d21f8196ee3fe9bd2f513d = $i854b57231c05dbaa7f22331dbaed4152a402d2f1->getList('en-EN', 'phonetoterritory'); $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = $i065c883e3f45e58104d21f8196ee3fe9bd2f513d[$idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b]; } else { $i7492a7ab99a6ff1e0ae253366480ecb40a550224 = ''; } $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = ''; foreach($i71e09ed37bc7273d250df9932c1693668e879cdd as $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7) { if ($ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getMutation() == $i7492a7ab99a6ff1e0ae253366480ecb40a550224) { $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getSmstext(); break; } elseif ($ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getMutation() == 'default') $i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f = $ifede0aa7d9c3f77f8ca4eb9c1002d82f3a770ae7->getSmstext(); } if ($i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f) { $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f = Mage::getModel('magesms/sms'); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->addRecipient($i1f1945594819c4321de45ac15ed6d4dc07f41e2f, array('recipient' => $i489c048e0604d314330360b5ee23b42f486ebb98, 'customerId' => $ifb2b31a17a2f13d19aebc5823ae02f42988a78f2, 'country' => $idcde4f5fb5532c8e634fa3aa4c7ce182a046d76b)) ->setMessage($this->prepareText($i6d6da9eb4bc3bca1db3f4eb2b907f496d625d20f, $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5)) ->setSubject($i41496536c6b29c24b90c374d9fc25143f114dc9a) ->setType(Topefekt_Magesms_Model_Sms::TYPE_CUSTOMER) ->setPriority(true) ->setStoreId($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); foreach($if2014d170e15e7f6f64523fd3238720980ceb64a as $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd) { if ($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getArea() == $i7492a7ab99a6ff1e0ae253366480ecb40a550224) { $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()); break; } elseif ($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getArea() == 'default') $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setUnicode($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getUnicode()); } $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->setHookName($i41496536c6b29c24b90c374d9fc25143f114dc9a); $i2012325f8714e1168a6c4fd06b9fa8eee23fcc7f->send(); } } } } return $this; } public function prepareText($idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $i41496536c6b29c24b90c374d9fc25143f114dc9a, $i5e65dd16263683749d16a84171f719e768ed14b5) { if (preg_match_all('/{(.*?)}/', $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa, $ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e)) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b = array(); foreach($ia00c63b7b8f0d76f361b9bd281e5073cc0d0aa3e[1] as $iebd691e534c6cf2e84cf8a88790a5271154fca05) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b[$iebd691e534c6cf2e84cf8a88790a5271154fca05] = '{'.$iebd691e534c6cf2e84cf8a88790a5271154fca05.'}'; } if ($i5e65dd16263683749d16a84171f719e768ed14b5->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = $i5e65dd16263683749d16a84171f719e768ed14b5->getStore()->getId(); elseif (Mage::app()->getStore()) $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = Mage::app()->getStore()->getStoreId(); else $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66 = null; if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'])) { $ic157485eecbe64d400493d7b9e7f434b83aca5d0 = parse_url(Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB)); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_domain'] = $ic157485eecbe64d400493d7b9e7f434b83aca5d0['host'].($ic157485eecbe64d400493d7b9e7f434b83aca5d0['path'] != '/' ? $ic157485eecbe64d400493d7b9e7f434b83aca5d0['path'] : ''); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name'] = Mage::getStoreConfig('general/store_information/name', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_name2'] = Mage::app()->getStore()->getName(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_email'] = Mage::getStoreConfig('trans_email/ident_general/email', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['shop_phone'] = Mage::getStoreConfig('general/store_information/phone', $i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'contactForm') { $iacbd1c78463510856e506611fe14b5e1173581a6 = Mage::app()->getRequest(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('email')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_name'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('name')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('telephone')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message'] = trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short1'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 120); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short2'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 100); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short3'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_message_short3'] = Mage::helper('magesms')->substr(trim($iacbd1c78463510856e506611fe14b5e1173581a6->getPost('comment')), 0, 80); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'customerRegisterSuccess') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_password'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_password'] = Mage::app()->getRequest()->getParam('password'); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getLastname(); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'newOrder' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderTrackingNumber') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getCustomerLastname(); } if (!isset($i22b151d2a920ca46892d343096abbccfad9f3678)) $i22b151d2a920ca46892d343096abbccfad9f3678 = $i5e65dd16263683749d16a84171f719e768ed14b5->getShippingAddress(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_company'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_company'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCompany(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_address'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_address'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getStreet(1); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_postcode'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_postcode'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getPostcode(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_city'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_city'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCity(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_country'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_country'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getCountry(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_state'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_state'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getRegion(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_phone'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getTelephone(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_vat_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_vat_number'] = $i22b151d2a920ca46892d343096abbccfad9f3678->getVatId(); } if (!isset($i560c12365c45b205daa0512840c70486783226b1)) $i560c12365c45b205daa0512840c70486783226b1 = $i5e65dd16263683749d16a84171f719e768ed14b5->getBillingAddress(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_company'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_company'] = $i560c12365c45b205daa0512840c70486783226b1->getCompany(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_firstname'] = $i560c12365c45b205daa0512840c70486783226b1->getFirstname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_lastname'] = $i560c12365c45b205daa0512840c70486783226b1->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_address'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_address'] = $i560c12365c45b205daa0512840c70486783226b1->getStreet(1); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_postcode'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_postcode'] = $i560c12365c45b205daa0512840c70486783226b1->getPostcode(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_city'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_city'] = $i560c12365c45b205daa0512840c70486783226b1->getCity(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_country'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_country'] = $i560c12365c45b205daa0512840c70486783226b1->getCountry(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_state'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_state'] = $i560c12365c45b205daa0512840c70486783226b1->getRegion(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_phone'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_phone'] = $i560c12365c45b205daa0512840c70486783226b1->getTelephone(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_vat_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_invoice_vat_number'] = $i560c12365c45b205daa0512840c70486783226b1->getVatId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getIncrementId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getPayment()->getMethodInstance()->getTitle(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment_html'])) { $ic078737049591e1e2db7c285f3e3b95cb867c6d0 = Mage::helper('payment')->getInfoBlock($i5e65dd16263683749d16a84171f719e768ed14b5->getPayment()) ->setIsSecureMode(true); $ic078737049591e1e2db7c285f3e3b95cb867c6d0->getMethod()->setStore($i3bf172bc34c83f4a18624b192bc0bd7c4d647a66); $i42745015bca99637011d2ba8a559beb3a8b0961f = strip_tags($ic078737049591e1e2db7c285f3e3b95cb867c6d0->toHtml()); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace('/ +/', ' ', $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/ \n/", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/\n /", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = preg_replace("/\n\n+/", "\n", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_payment_html'] = trim($i42745015bca99637011d2ba8a559beb3a8b0961f); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_total_paid'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_total_paid'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getGrandTotal(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_currency'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_currency'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getOrderCurrency()->getCurrencyCode(); } $this->f2b4066ec99f97011a4a9f20dd18d97b5a49b8b51($i0933475b5bd80561a9f50282fd9eb0b8345cec4b, $i5e65dd16263683749d16a84171f719e768ed14b5->getCreatedAt()); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'])) { $ifd002a4ef735f38a6030baa73fafafa1118ff492 = Mage::getModel('ecommerceteam_ddc/order'); if ($ifd002a4ef735f38a6030baa73fafafa1118ff492) { $i82d8f80a6f30d2bff1b6b037fd170117a61f4e69 = $ifd002a4ef735f38a6030baa73fafafa1118ff492->load($i5e65dd16263683749d16a84171f719e768ed14b5->getEntityId(), 'order_id')->getData(); if (isset($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['order_id'])) { if (strtotime($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['delivery_date'])) { $i5b8dea0c150539c8b78ffa4a4ee9b4ea0bf09414 = Mage::getSingleton('core/locale')->date($i82d8f80a6f30d2bff1b6b037fd170117a61f4e69['delivery_date'], Zend_Date::ISO_8601, null, false)->toString(Mage::app()->getLocale()->getDateFormat(Mage_Core_Model_Locale::FORMAT_TYPE_FULL)); $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'] = $i5b8dea0c150539c8b78ffa4a4ee9b4ea0bf09414; } } elseif ($i2d35534ee8eb5c1c7e742a61e000486ce24db667 = Mage::app()->getRequest()->getParam('delivery_date')) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['delivery_date'] = $i2d35534ee8eb5c1c7e742a61e000486ce24db667; } } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'newOrder') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['cart_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['cart_id'] = Mage::getSingleton('checkout/session')->getQuoteId(); } $i32ce098f2dde8081cf3c4de31f52b408a6ad48be = $i5e65dd16263683749d16a84171f719e768ed14b5->getItemsCollection(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder1'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getName().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder1'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder2'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = 'id:'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getId().', ' .Mage::helper('magesms')->__('name').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getName().', ' .Mage::helper('magesms')->__('qty').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder2'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder3'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder3'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder4'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = 'id:'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getId().', ' .Mage::helper('magesms')->__('qty').':'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder4'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder5'])) { $i813c950729f632ca03f8c203c0a769de5e8bdf29 = array(); foreach($i32ce098f2dde8081cf3c4de31f52b408a6ad48be as $i69a1201e93806d55c970dfb18feec53d221ba37b) { $i813c950729f632ca03f8c203c0a769de5e8bdf29[] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getId().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getSku().'/'.$i69a1201e93806d55c970dfb18feec53d221ba37b->getQtyOrdered(); } $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['newOrder5'] = implode('; ', $i813c950729f632ca03f8c203c0a769de5e8bdf29); } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderStatus' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'updateOrderTrackingNumber') { $i9805d668f75b6b461f88474f57c5f6aa86a87316 = $i5e65dd16263683749d16a84171f719e768ed14b5->getTracksCollection()->getLastItem(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['carrier_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['carrier_name'] = $i9805d668f75b6b461f88474f57c5f6aa86a87316->getTitle(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_shipping_number'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_shipping_number'] = $i9805d668f75b6b461f88474f57c5f6aa86a87316->getTrackNumber(); } $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87 = Mage::getSingleton('admin/session')->getUser(); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_id'] = $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['employee_email'] = $i2977ace3ff82db806c1e7c92dd6811f3d76f0e87->getEmail(); } } } if ($i41496536c6b29c24b90c374d9fc25143f114dc9a == 'productOutOfStock' || $i41496536c6b29c24b90c374d9fc25143f114dc9a == 'productLowStock') { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_id'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getProductId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_quantity'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_quantity'] = $i5e65dd16263683749d16a84171f719e768ed14b5->getQty(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'])) { $i69a1201e93806d55c970dfb18feec53d221ba37b = Mage::getModel('catalog/product'); $i69a1201e93806d55c970dfb18feec53d221ba37b->load($i5e65dd16263683749d16a84171f719e768ed14b5->getProductId()); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_name'] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getName(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['product_ref'] = $i69a1201e93806d55c970dfb18feec53d221ba37b->getSku(); } } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname']) || isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { if ($i21e55df616c305955791876c1eb4da83448beba2 = Mage::getSingleton('customer/session')->getCustomer()) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_id'] = $i21e55df616c305955791876c1eb4da83448beba2->getId(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_email'] = $i21e55df616c305955791876c1eb4da83448beba2->getEmail(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_lastname'] = $i21e55df616c305955791876c1eb4da83448beba2->getLastname(); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['customer_firstname'] = $i21e55df616c305955791876c1eb4da83448beba2->getFirstname(); } } } } foreach($i0933475b5bd80561a9f50282fd9eb0b8345cec4b as $i670253c23c6fcba76bc4256a88fdd8fbc1041039=>$if2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa = str_replace('{'.$i670253c23c6fcba76bc4256a88fdd8fbc1041039.'}', $if2eee0665f163a28f4adcfe84e3fc666bf1bcd89, $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa); } } return $idfc9fbe8edf868c14fc4a3f15c7f40aabfa080aa; } private function f2b4066ec99f97011a4a9f20dd18d97b5a49b8b51(&$i0933475b5bd80561a9f50282fd9eb0b8345cec4b, $i53ddb2282ac3aca0d44abe35abcf69959ed66574) { if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date'] = $i53ddb2282ac3aca0d44abe35abcf69959ed66574; } $i17c20960d197486b19dc890665362a4f2fd6f24a = date_parse($i53ddb2282ac3aca0d44abe35abcf69959ed66574); if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date1'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date2'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date2'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date3'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date3'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date4'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date4'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['year'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date5'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date5'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'.'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date6'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date6'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'/'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date7'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_date7'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['month'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['day'].'-'.$i17c20960d197486b19dc890665362a4f2fd6f24a['year']; } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['hour'].':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['minute']); } if (isset($i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time1'])) { $i0933475b5bd80561a9f50282fd9eb0b8345cec4b['order_time1'] = $i17c20960d197486b19dc890665362a4f2fd6f24a['hour'].':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['minute']).':'.sprintf('%02.0f', $i17c20960d197486b19dc890665362a4f2fd6f24a['second']); } } }
|
app/code/community/Topefekt/Magesms/Model/Marketing/Filter/Birthdayall.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Model_Marketing_Filter_Birthdayall extends Varien_Object { public $filter; public function __construct() { $this->filter = array( 'title' => Mage::helper('magesms')->__('Date of birth from: ').'('.Mage::helper('magesms')->__('All years').')', 'type' => 'birthdayall', 'name' => 'birthdayall', 'color' => '#907090', 'glue' => ' / ', ); } public function getFilter($iff7e46827cbb6547116c592bf800f4687428abf9, $i2d8fb6b6f17ec9aa17899ea311cc26bc493cd9a2) { $i717aafa07eeca1a7c0f40cc18a0eb90e0984de3e = array(); foreach($i2d8fb6b6f17ec9aa17899ea311cc26bc493cd9a2 as $iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a) { if ($iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a instanceof $this) { $i3ca4aff6918962dee4a8054ca52f13ef3b6bab08 = $iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a->getValue();
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Model_Marketing_Filter_Birthdayall extends Varien_Object { public $filter; public function __construct() { $this->filter = array( 'title' => Mage::helper('magesms')->__('Date of birth from: ').'('.Mage::helper('magesms')->__('All years').')', 'type' => 'birthdayall', 'name' => 'birthdayall', 'color' => '#907090', 'glue' => ' / ', ); } public function getFilter($iff7e46827cbb6547116c592bf800f4687428abf9, $i2d8fb6b6f17ec9aa17899ea311cc26bc493cd9a2) { $i717aafa07eeca1a7c0f40cc18a0eb90e0984de3e = array(); foreach($i2d8fb6b6f17ec9aa17899ea311cc26bc493cd9a2 as $iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a) { if ($iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a instanceof $this) { $i3ca4aff6918962dee4a8054ca52f13ef3b6bab08 = $iba20acc78644ac0e9cd48ea35d8ad03b058f6b5a->getValue(); if (!empty($i3ca4aff6918962dee4a8054ca52f13ef3b6bab08[0]) && !empty($i3ca4aff6918962dee4a8054ca52f13ef3b6bab08[1])) $i717aafa07eeca1a7c0f40cc18a0eb90e0984de3e[] = 'at_dob.value LIKE \'____-'.sprintf('%02d', $i3ca4aff6918962dee4a8054ca52f13ef3b6bab08[1]).'-'.sprintf('%02d', $i3ca4aff6918962dee4a8054ca52f13ef3b6bab08[0]).' %\''; } } if (count($i717aafa07eeca1a7c0f40cc18a0eb90e0984de3e)) { $iff7e46827cbb6547116c592bf800f4687428abf9->addFieldToFilter('dob', array('notnull' => true)); $iff7e46827cbb6547116c592bf800f4687428abf9->getSelect()->where('('.implode(' OR ', $i717aafa07eeca1a7c0f40cc18a0eb90e0984de3e).')'); } return $iff7e46827cbb6547116c592bf800f4687428abf9; } }
|
app/code/community/Topefekt/Magesms/Model/Sms.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Model_Sms extends Varien_Object { const SENT = 1; const ERROR = 2; const DELIVERED = 3; const UNAVAILABLE = 4; const SIMULATION = 5; const SCHEDULED = 6; const DELETED = 7; const DND = 8; const DUPLICATE = 9; const TYPE_ADMIN = 1; const TYPE_CUSTOMER = 2; const TYPE_MARKETING = 3; const TYPE_SIMPLE = 4; protected $_routes_type = array( self::TYPE_ADMIN => 'admin', self::TYPE_CUSTOMER => 'customer', self::TYPE_MARKETING => 'customer', self::TYPE_SIMPLE => 'customer'); private $v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = true; public function _construct() { $this->setData(array( 'recipient' => new Varien_Data_Collection(), 'message' => '', 'subject' => '', 'unicode' => false, 'sendlater' => false, 'type' => self::TYPE_SIMPLE, 'priority' => true, 'unique' => false, 'adminId' => 0, 'customerId' => 0, 'recipientName' => '', 'storeId' => null )); parent::_construct(); } public function send() { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18 = Mage::getSingleton('magesms/smsprofile'); try { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f = array(); if (!strlen($this->getMessage())) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Fill in SMS text.'); } if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); if ($this->getSendlater()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8284e7e828b5452004207db69edd7aa7ff0703ab = Mage::getModel('core/date')->gmtTimestamp(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8284e7e828b5452004207db69edd7aa7ff0703ab >= $this->getSendlater()) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Wrong time of SMS sending.'); } if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); if (!count($this->getRecipient())) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Recipients found: 0'); if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519 = html_entity_decode($this->getMessage(), ENT_QUOTES, 'UTF-8'); $if295547318143e26fc7026b92d58e3d1eec229db = Mage::helper('magesms')->countSms($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519, $this->getUnicode()); if (!$ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->simulatesms && count($this->getRecipient())*$if295547318143e26fc7026b92d58e3d1eec229db*0.05 > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->credit) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('You do not have enough credit to send SMS to all ') .count($this->getRecipient()).Mage::helper('magesms')->__(' recipients.'); if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d854b57231c05dbaa7f22331dbaed4152a402d2f1 = new Zend_Locale_Data(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d854b57231c05dbaa7f22331dbaed4152a402d2f1->getList('en-EN', 'phonetoterritory'); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2 = array('number'=>array(), 'isms'=>array(), 'sendertype'=>array(), 'senderID'=>array(), 'admin_id'=>array(), 'customer_id'=>array(), 'data' => array()); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d = 0; foreach($this->getRecipient() as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getNumber(); $i037b855bc01175f2c77d5c3e19eda9a0003feff4 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCountry() ? $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCountry() : ''; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = ''; if ($i037b855bc01175f2c77d5c3e19eda9a0003feff4 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d[$i037b855bc01175f2c77d5c3e19eda9a0003feff4] && !(strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '+') === 0 || strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '00') === 0)) { if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '0') === 0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, 1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d[$i037b855bc01175f2c77d5c3e19eda9a0003feff4]; } $i813c950729f632ca03f8c203c0a769de5e8bdf29 = Mage::helper('magesms')->prepareNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, $this->_routes_type[$this->getType()], $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, $this->getStoreId()); if(is_array($i813c950729f632ca03f8c203c0a769de5e8bdf29)) { if ($this->getUnique()) { if (in_array($i813c950729f632ca03f8c203c0a769de5e8bdf29['mobile'], $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'])) continue; } $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['mobile']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['isms']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['sendertype'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['sendertype']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['senderID']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getAdminId(); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCustomerId(); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getRecipient(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->hasText()) { $i42745015bca99637011d2ba8a559beb3a8b0961f = html_entity_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getText(), ENT_QUOTES, 'UTF-8'); $i42745015bca99637011d2ba8a559beb3a8b0961f = addslashes($i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d] = $i42745015bca99637011d2ba8a559beb3a8b0961f; } } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d++; } if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->simulatesms) { foreach($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b = Mage::getModel('magesms/smshistory'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNumber('+'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setDate(date('Y-m-d H:i:s')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal(Mage::helper('magesms')->countSms($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039], $this->getUnicode())); } else { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal($if295547318143e26fc7026b92d58e3d1eec229db); } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SIMULATION); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSender($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setType($this->getType()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('SMS SIMULATION (Sending of SMS was simulated. Recipient will not receive SMS)')); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSmsid('simulate'.md5(microtime())); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSubject($this->getSubject()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setAdminId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->save(); } if (count($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'])) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was sent (simulation).')); $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = false; } else { $ia61712c27ea241bd7a543dc2b02ea572274d0322 = 'username='.urlencode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->user).'&password='.urlencode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->passwd) .'&unicode='.($this->getUnicode() ? 1 : 0); if ($this->getPriority()) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&action=sendsms&number='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][0]) .'&isms='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms'][0]).'&sender='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][0]); else $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&action=sendsmsall'.($this->getType() == self::TYPE_MARKETING ? '2' : '').'&number='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number']) .'&isms='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms']).'&sender='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID']); if ($this->getType() == self::TYPE_MARKETING && !empty($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'])) foreach ($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d=>$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&data'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d.'='.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89; else { $i42745015bca99637011d2ba8a559beb3a8b0961f = html_entity_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519, ENT_QUOTES, 'UTF-8'); $i42745015bca99637011d2ba8a559beb3a8b0961f = addslashes($i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&data='.$i42745015bca99637011d2ba8a559beb3a8b0961f; } if ($this->getSendlater()) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&datelater='.urlencode($this->getSendlater()); if ($this->getHookName()) { $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&HN='.$this->getHookName(); } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720 = Mage::getModel('magesms/api')->serverPost($ia61712c27ea241bd7a543dc2b02ea572274d0322, false); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720)) { if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720, 'QQQ___QQQ') !== false) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 = explode("QQQ___QQQ", $ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720); else $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 = array($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a = Mage::getModel('magesms/api')->parser($ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89, '__'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b = Mage::getModel('magesms/smshistory'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNumber('+'.$if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setDate(date('Y-m-d H:i:s')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal(Mage::helper('magesms')->countSms($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039], $this->getUnicode())); } else { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal($if295547318143e26fc7026b92d58e3d1eec229db); } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::ERROR); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][1])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setPrice($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][1]); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][2])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCredit($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][2]); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][0])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSmsid($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][0]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSender($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setAdminId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setType($this->getType()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSubject($this->getSubject()); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 1 || $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 11) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SENT); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 111) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SCHEDULED); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('SMS will be send later - ').Mage::helper('core')->formatDate(date('Y-m-d H:i:s', $this->getSendlater()), 'medium', true)); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 9) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('wrong number or unavailable')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 15) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('unauthorized senderID in confirmation sms')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 10) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('low credit for sending sms')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 22) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('unicode is not supported')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 23) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('message duplicity')); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::DUPLICATE); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['error'])); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 4) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customerID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customerID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); } else { continue; } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->save(); } $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = false; if ($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getStatus() == self::SENT) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was sent.')); elseif ($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getStatus() == self::SCHEDULED) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was saved.')); else { Mage::getSingleton('adminhtml/session')->addError($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getNote()); $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = true; } } } } catch (Exception $i8c174347956f0a76258a09557543e84f88beb4a0) { Mage::getSingleton('adminhtml/session')->addError($i8c174347956f0a76258a09557543e84f88beb4a0->getMessage()); } } public function setRecipient($ia61712c27ea241bd7a543dc2b02ea572274d0322) { if (is_string($ia61712c27ea241bd7a543dc2b02ea572274d0322)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber($ia61712c27ea241bd7a543dc2b02ea572274d0322); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); } elseif (is_array($ia61712c27ea241bd7a543dc2b02ea572274d0322)) { foreach ($ia61712c27ea241bd7a543dc2b02ea572274d0322 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { if (!trim($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d)) continue; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber(trim($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d)); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); } } return $this; } public function addRecipient($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['country'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setCountry($ia61712c27ea241bd7a543dc2b02ea572274d0322['country']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['customerId'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setCustomerId($ia61712c27ea241bd7a543dc2b02ea572274d0322['customerId']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['adminId'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setAdminId($ia61712c27ea241bd7a543dc2b02ea572274d0322['adminId']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['recipient'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setRecipient($ia61712c27ea241bd7a543dc2b02ea572274d0322['recipient']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['text'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setText($ia61712c27ea241bd7a543dc2b02ea572274d0322['text']); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); return $this; } public function isError() { return $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b ? true : false; } public function status($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257 = false) { $i2e68560d8e15e3c18bb400939778a6bf1ae47190 = array(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SENT); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_sent.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SENT to recipient')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::ERROR); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_canceled.gif'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('ERROR')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DELIVERED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_accepted.gif'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DELIVERED to recipient')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::UNAVAILABLE); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_buffered.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('RECIPIENT UNAVAILABLE')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SIMULATION); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_simulation.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SIMULATION')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SCHEDULED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_scheduled.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SCHEDULED')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DELETED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_deleted.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DELETED')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DND); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_donotdisturb.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DO NOT DISTURB registry (DND)')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DUPLICATE); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_duplicate.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DUPLICATE')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257 === false) return $i2e68560d8e15e3c18bb400939778a6bf1ae47190; elseif (isset($i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257])) return $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257]; return false; } }
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Model_Sms extends Varien_Object { const SENT = 1; const ERROR = 2; const DELIVERED = 3; const UNAVAILABLE = 4; const SIMULATION = 5; const SCHEDULED = 6; const DELETED = 7; const DND = 8; const DUPLICATE = 9; const TYPE_ADMIN = 1; const TYPE_CUSTOMER = 2; const TYPE_MARKETING = 3; const TYPE_SIMPLE = 4; protected $_routes_type = array( self::TYPE_ADMIN => 'admin', self::TYPE_CUSTOMER => 'customer', self::TYPE_MARKETING => 'customer', self::TYPE_SIMPLE => 'customer'); private $v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = true; public function _construct() { $this->setData(array( 'recipient' => new Varien_Data_Collection(), 'message' => '', 'subject' => '', 'unicode' => false, 'sendlater' => false, 'type' => self::TYPE_SIMPLE, 'priority' => true, 'unique' => false, 'admin_id' => 0, 'customer_id' => 0, 'recipient_name' => '', 'store_id' => null )); parent::_construct(); } public function send() { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18 = Mage::getSingleton('magesms/smsprofile'); try { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f = array(); if (!strlen($this->getMessage())) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Fill in SMS text.'); } if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); if ($this->getSendlater()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d8284e7e828b5452004207db69edd7aa7ff0703ab = Mage::getModel('core/date')->gmtTimestamp(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d8284e7e828b5452004207db69edd7aa7ff0703ab >= $this->getSendlater()) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Wrong time of SMS sending.'); } if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); if (!count($this->getRecipient())) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('Recipients found: 0'); if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); $ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519 = html_entity_decode($this->getMessage(), ENT_QUOTES, 'UTF-8'); $if295547318143e26fc7026b92d58e3d1eec229db = Mage::helper('magesms')->countSms($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519, $this->getUnicode()); if (!$ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->simulatesms && count($this->getRecipient())*$if295547318143e26fc7026b92d58e3d1eec229db*0.05 > $ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->credit) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[] = Mage::helper('magesms')->__('You do not have enough credit to send SMS to all ') .count($this->getRecipient()).Mage::helper('magesms')->__(' recipients.'); if (is_array($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f) && sizeof($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f)) Mage::throwException($ibcdf76f8c9ddc330c79f805116a8bb146c43749dbdd27a8dd714410289189d318feb96fe6ed8e07f[0]); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d854b57231c05dbaa7f22331dbaed4152a402d2f1 = new Zend_Locale_Data(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d854b57231c05dbaa7f22331dbaed4152a402d2f1->getList('en-EN', 'phonetoterritory'); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2 = array('number'=>array(), 'isms'=>array(), 'sendertype'=>array(), 'senderID'=>array(), 'admin_id'=>array(), 'customer_id'=>array(), 'data' => array()); $ibcdf76f8c9ddc330c79f805116a8bb146c43749d = 0; foreach($this->getRecipient() as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getNumber(); $i037b855bc01175f2c77d5c3e19eda9a0003feff4 = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCountry() ? $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCountry() : ''; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = ''; if ($i037b855bc01175f2c77d5c3e19eda9a0003feff4 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d[$i037b855bc01175f2c77d5c3e19eda9a0003feff4] && !(strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '+') === 0 || strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '00') === 0)) { if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, '0') === 0) $ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f = substr($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, 1); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d065c883e3f45e58104d21f8196ee3fe9bd2f513d[$i037b855bc01175f2c77d5c3e19eda9a0003feff4]; } $i813c950729f632ca03f8c203c0a769de5e8bdf29 = Mage::helper('magesms')->prepareNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, $this->_routes_type[$this->getType()], $ibcdf76f8c9ddc330c79f805116a8bb146c43749df0177bfe4bf22cfbb3da2ac06eca557829f0a4cd, $this->getStoreId()); if(is_array($i813c950729f632ca03f8c203c0a769de5e8bdf29)) { if ($this->getUnique()) { if (in_array($i813c950729f632ca03f8c203c0a769de5e8bdf29['mobile'], $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'])) continue; } $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['mobile']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['isms']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['sendertype'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['sendertype']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][] = $i813c950729f632ca03f8c203c0a769de5e8bdf29['senderID']; $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getAdminId(); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getCustomerId(); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getRecipient(); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->hasText()) { $i42745015bca99637011d2ba8a559beb3a8b0961f = html_entity_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d90bf5ab4e4ec7f89dc69f079d1a10e0bfa14c802->getText(), ENT_QUOTES, 'UTF-8'); $i42745015bca99637011d2ba8a559beb3a8b0961f = addslashes($i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d] = $i42745015bca99637011d2ba8a559beb3a8b0961f; } } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d++; } if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->simulatesms) { foreach($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b = Mage::getModel('magesms/smshistory'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNumber('+'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setDate(date('Y-m-d H:i:s')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal(Mage::helper('magesms')->countSms($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039], $this->getUnicode())); } else { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal($if295547318143e26fc7026b92d58e3d1eec229db); } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SIMULATION); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSender($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setType($this->getType()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('SMS SIMULATION (Sending of SMS was simulated. Recipient will not receive SMS)')); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSmsid('simulate'.md5(microtime())); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSubject($this->getSubject()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setAdminId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->save(); } if (count($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'])) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was sent (simulation).')); $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = false; } else { $ia61712c27ea241bd7a543dc2b02ea572274d0322 = 'username='.urlencode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->user).'&password='.urlencode($ibcdf76f8c9ddc330c79f805116a8bb146c43749d6abff7c4dab2aa28578ae1dc49699ba6b1d18c18->user->passwd) .'&unicode='.($this->getUnicode() ? 1 : 0); if ($this->getPriority()) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&action=sendsms&number='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][0]) .'&isms='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms'][0]).'&sender='.urlencode($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][0]); else $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&action=sendsmsall'.($this->getType() == self::TYPE_MARKETING ? '2' : '').'&number='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number']) .'&isms='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['isms']).'&sender='.implode(';', $if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID']); if ($this->getType() == self::TYPE_MARKETING && !empty($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'])) foreach ($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'] as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d=>$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&data'.$ibcdf76f8c9ddc330c79f805116a8bb146c43749d.'='.$ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89; else { $i42745015bca99637011d2ba8a559beb3a8b0961f = html_entity_decode($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519, ENT_QUOTES, 'UTF-8'); $i42745015bca99637011d2ba8a559beb3a8b0961f = addslashes($i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $i42745015bca99637011d2ba8a559beb3a8b0961f = str_replace("&", "%26", $i42745015bca99637011d2ba8a559beb3a8b0961f); $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&data='.$i42745015bca99637011d2ba8a559beb3a8b0961f; } if ($this->getSendlater()) $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&datelater='.urlencode($this->getSendlater()); if ($this->getHookName()) { $ia61712c27ea241bd7a543dc2b02ea572274d0322 .= '&HN='.$this->getHookName(); } $ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720 = Mage::getModel('magesms/api')->serverPost($ia61712c27ea241bd7a543dc2b02ea572274d0322, false); if (!empty($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720)) { if (strpos($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720, 'QQQ___QQQ') !== false) $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 = explode("QQQ___QQQ", $ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720); else $ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 = array($ibcdf76f8c9ddc330c79f805116a8bb146c43749d55dd4e7042a1f9031b84f07f04c37165ce3d0720); foreach($ibcdf76f8c9ddc330c79f805116a8bb146c43749dd18c7e5bc71d5242a8b8cc24d43559e5dccbddb5 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039 => $ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a = Mage::getModel('magesms/api')->parser($ibcdf76f8c9ddc330c79f805116a8bb146c43749df2eee0665f163a28f4adcfe84e3fc666bf1bcd89, '__'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b = Mage::getModel('magesms/smshistory'); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNumber('+'.$if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['number'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setDate(date('Y-m-d H:i:s')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal(Mage::helper('magesms')->countSms($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['data'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039], $this->getUnicode())); } else { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setText($ibcdf76f8c9ddc330c79f805116a8bb146c43749dcd14fe4ea296b55b8ecbf19d2fd7bfef3a511519); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setTotal($if295547318143e26fc7026b92d58e3d1eec229db); } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::ERROR); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][1])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setPrice($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][1]); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][2])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCredit($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][2]); if (isset($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][0])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSmsid($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['data'][0]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSender($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['senderID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setAdminId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['admin_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customer_id'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setUnicode($this->getUnicode()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setType($this->getType()); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setSubject($this->getSubject()); if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 1 || $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 11) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SENT); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 111) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::SCHEDULED); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('SMS will be send later - ').Mage::helper('core')->formatDate(date('Y-m-d H:i:s', $this->getSendlater()), 'medium', true)); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 9) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('wrong number or unavailable')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 15) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('unauthorized senderID in confirmation sms')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 10) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('low credit for sending sms')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 22) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('unicode is not supported')); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3 && $ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['datasrc'] == 23) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('message duplicity')); $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setStatus(self::DUPLICATE); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 3) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['error'])); } elseif ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d17c20960d197486b19dc890665362a4f2fd6f24a['errno'] == 4) { $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setNote(Mage::helper('magesms')->__('')); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customerID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setCustomerId($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['customerID'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); if (isset($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039])) $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->setRecipient($if85a12d6e5fb576dbfd0203ae61d13b94a9fadd2['recipient'][$ibcdf76f8c9ddc330c79f805116a8bb146c43749d670253c23c6fcba76bc4256a88fdd8fbc1041039]); } else { continue; } $i5ee2fa256ff77dd811a9c1911f7563263a694e4b->save(); } $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = false; if ($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getStatus() == self::SENT) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was sent.')); elseif ($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getStatus() == self::SCHEDULED) Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS was saved.')); else { Mage::getSingleton('adminhtml/session')->addError($i5ee2fa256ff77dd811a9c1911f7563263a694e4b->getNote()); $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b = true; } } } } catch (Exception $i8c174347956f0a76258a09557543e84f88beb4a0) { Mage::getSingleton('adminhtml/session')->addError($i8c174347956f0a76258a09557543e84f88beb4a0->getMessage()); } } public function setRecipient($ia61712c27ea241bd7a543dc2b02ea572274d0322) { if (is_string($ia61712c27ea241bd7a543dc2b02ea572274d0322)) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber($ia61712c27ea241bd7a543dc2b02ea572274d0322); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); } elseif (is_array($ia61712c27ea241bd7a543dc2b02ea572274d0322)) { foreach ($ia61712c27ea241bd7a543dc2b02ea572274d0322 as $ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d) { if (!trim($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d)) continue; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber(trim($ibcdf76f8c9ddc330c79f805116a8bb146c43749debe3a16a01f87f9a4ebbb9731163db3e3e64cc3d)); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); } } return $this; } public function addRecipient($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f, $ia61712c27ea241bd7a543dc2b02ea572274d0322 = array()) { $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setNumber($ibcdf76f8c9ddc330c79f805116a8bb146c43749d39404799a9171a012cb8b15cd8f27b347aa44a5f); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['country'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setCountry($ia61712c27ea241bd7a543dc2b02ea572274d0322['country']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['customerId'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setCustomerId($ia61712c27ea241bd7a543dc2b02ea572274d0322['customerId']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['adminId'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setAdminId($ia61712c27ea241bd7a543dc2b02ea572274d0322['adminId']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['recipient'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setRecipient($ia61712c27ea241bd7a543dc2b02ea572274d0322['recipient']); if (isset($ia61712c27ea241bd7a543dc2b02ea572274d0322['text'])) $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setText($ia61712c27ea241bd7a543dc2b02ea572274d0322['text']); $this->getRecipient()->addItem($ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6); return $this; } public function isError() { return $this->v3a95f9a85ae3fecc89b69aa9ea2d057ac2807b0b ? true : false; } public function status($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257 = false) { $i2e68560d8e15e3c18bb400939778a6bf1ae47190 = array(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SENT); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_sent.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SENT to recipient')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::ERROR); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_canceled.gif'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('ERROR')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DELIVERED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_accepted.gif'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DELIVERED to recipient')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::UNAVAILABLE); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_buffered.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('RECIPIENT UNAVAILABLE')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SIMULATION); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_simulation.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SIMULATION')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::SCHEDULED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_scheduled.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('SCHEDULED')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DELETED); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_deleted.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DELETED')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DND); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_donotdisturb.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DO NOT DISTURB registry (DND)')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6 = new Varien_Object(); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setStatus(self::DUPLICATE); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setIcon('i_duplicate.png'); $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->setName(Mage::helper('magesms')->__('DUPLICATE')); $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6->status] = $ibcdf76f8c9ddc330c79f805116a8bb146c43749df66cdb02406b60b7d525f1fed0b5904ce5586ee6; if ($ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257 === false) return $i2e68560d8e15e3c18bb400939778a6bf1ae47190; elseif (isset($i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257])) return $i2e68560d8e15e3c18bb400939778a6bf1ae47190[$ibcdf76f8c9ddc330c79f805116a8bb146c43749d7e9551ab4470830f87be4f9ff5edc75013bc9257]; return false; } }
|
app/code/community/Topefekt/Magesms/controllers/Adminhtml/Magesms/CustomersmsController.php
CHANGED
@@ -13,4 +13,4 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
class Topefekt_Magesms_Adminhtml_Magesms_CustomersmsController extends Topefekt_Magesms_Controller_Action { public function indexAction() { $this->_initAction(); $i8ee45e0018a32fb1a855b82624506e35789cc4d2 = $this->getLayout()->createBlock( 'Topefekt_Magesms_Block_Template', 'my_block_name_here', array('template' => 'topefekt/magesms/customersms.phtml') ); $this->getLayout()->getBlock('content')->append($i8ee45e0018a32fb1a855b82624506e35789cc4d2); $this->renderLayout(); return $this; } public function addmutationAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('country', 'default'); $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates')->getCollection()->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6); if (!$idb618c56be2c8abc9a54a16881dadfd5317ba624->count()) { $i195899c9895b81b9bc75dba762c949638a6f36dd = Mage::getSingleton('magesms/country_area')->getCollection()->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6); $i7d716a8fdc4101e29ab8fd7002b332e962603d8c = array(); foreach($i195899c9895b81b9bc75dba762c949638a6f36dd as $i037b855bc01175f2c77d5c3e19eda9a0003feff4) { $i7d716a8fdc4101e29ab8fd7002b332e962603d8c[] = $i037b855bc01175f2c77d5c3e19eda9a0003feff4->getCountryName(); } if (count($i7d716a8fdc4101e29ab8fd7002b332e962603d8c)) { $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates'); $idb618c56be2c8abc9a54a16881dadfd5317ba624->setArea($i7137e40370cf1c5ccf937060891613788203e2d6); $idb618c56be2c8abc9a54a16881dadfd5317ba624->setAreaText(implode(', ', $i7d716a8fdc4101e29ab8fd7002b332e962603d8c)); $idb618c56be2c8abc9a54a16881dadfd5317ba624->save(); Mage::getSingleton('adminhtml/session')->addSuccess( Mage::helper('magesms')->__('SMS text version for ').$idb618c56be2c8abc9a54a16881dadfd5317ba624->getAreaText(). Mage::helper('magesms')->__(' was saved') ); } } $this->_redirect('*/*/', array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6)); return $this; } public function delmutationAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation'); if ($i7137e40370cf1c5ccf937060891613788203e2d6) { $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->getFirstItem() ->delete(); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->addFilter('type', 'customer') ->getFirstItem() ->delete(); $ibad8f78c098260b16424eb12ceee5f8336591d56 = Mage::getSingleton('magesms/hooks_customers') ->getCollection() ->addFilter('mutation', $i7137e40370cf1c5ccf937060891613788203e2d6); foreach($ibad8f78c098260b16424eb12ceee5f8336591d56 as $i21e55df616c305955791876c1eb4da83448beba2) $i21e55df616c305955791876c1eb4da83448beba2->delete(); Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS text version was deleted.')); } $this->_redirect('*/*/index'); return $this; } public function saveunicodeAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation'); if ($i7137e40370cf1c5ccf937060891613788203e2d6) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->addFilter('type', 'customer') ->getFirstItem(); if (!count($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getData())) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode'); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setArea($i7137e40370cf1c5ccf937060891613788203e2d6); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setType('customer'); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setUnicode($this->getRequest()->getParam('unicode' , 0)); } else { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setUnicode($this->getRequest()->getParam('unicode' , 0)); } $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->save(); Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('Unicode was saved.')); } $this->_redirect('*/*/', array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6)); return $this; } public function savehookAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation', 'default'); $i30f20aafde612a957f7f966cb5b85e35782bc88a = $this->getRequest()->getParam('type'); $i2bd9743336318d0e14be0600c9129730279505dd = $this->getRequest()->getParam('name'); $i24273814df383b4a6926acc1db1a788b12f5a411 = $this->getRequest()->getParam('text' , ''); if ($i30f20aafde612a957f7f966cb5b85e35782bc88a && $i2bd9743336318d0e14be0600c9129730279505dd && $i24273814df383b4a6926acc1db1a788b12f5a411) { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks_'.$i30f20aafde612a957f7f966cb5b85e35782bc88a) ->getCollection() ->addFilter('name', $i2bd9743336318d0e14be0600c9129730279505dd) ->addFilter('mutation', $i7137e40370cf1c5ccf937060891613788203e2d6) ->getFirstItem(); if (!count($i42ee48f418943c9662de0976069476c7dc8f620d->getData())) { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks_'.$i30f20aafde612a957f7f966cb5b85e35782bc88a); $i42ee48f418943c9662de0976069476c7dc8f620d->setMutation($i7137e40370cf1c5ccf937060891613788203e2d6); $i42ee48f418943c9662de0976069476c7dc8f620d->setName($i2bd9743336318d0e14be0600c9129730279505dd); } $i42ee48f418943c9662de0976069476c7dc8f620d->setActive($this->getRequest()->getParam('active' , 0)); $i42ee48f418943c9662de0976069476c7dc8f620d->setSmstext($i24273814df383b4a6926acc1db1a788b12f5a411); $i42ee48f418943c9662de0976069476c7dc8f620d->save(); Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('Text of SMS was saved.')); } $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a = array('_fragment' => $i2bd9743336318d0e14be0600c9129730279505dd); if ($i7137e40370cf1c5ccf937060891613788203e2d6 != 'default') $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a += array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6); $this->_redirect('*/*/', $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a); return $this; } protected function _initAction() { parent::_initAction(); $this->_setActiveMenu('magesms/customersms') ->_title(Mage::helper('magesms')->__('Customer SMS')) ; return $this; } }
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
class Topefekt_Magesms_Adminhtml_Magesms_CustomersmsController extends Topefekt_Magesms_Controller_Action { private $v2b483c223d472d1fb22c9823dcc35f84765b2c06 = array(); public function _construct() { $this->v2b483c223d472d1fb22c9823dcc35f84765b2c06 = new Varien_Data_Collection(); $this->v2b483c223d472d1fb22c9823dcc35f84765b2c06->addItem(new Varien_Object( array( 'group' => 'order_status', 'name' =>Mage::helper('magesms')->__('Order status'), 'icon' => 'magesms/AdminOrders.gif' ) ))->addItem(new Varien_Object( array( 'group' => 'order', 'name' =>Mage::helper('magesms')->__('Order'), 'icon' => 'magesms/AdminOrders.gif' ) ))->addItem(new Varien_Object( array( 'group' => 'account', 'name' =>Mage::helper('magesms')->__('Account'), 'icon' => 'magesms/AdminCustomers.gif' ) )); parent::_construct(); } public function indexAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation', 'default'); $this->_initAction(); $i8ee45e0018a32fb1a855b82624506e35789cc4d2 = $this->getLayout()->createBlock( 'Topefekt_Magesms_Block_Template', 'my_block_name_here', array('template' => 'topefekt/magesms/customersms.phtml') ); foreach ($this->v2b483c223d472d1fb22c9823dcc35f84765b2c06 as $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc) { $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc->setHooks(Mage::helper('magesms')->getHooks($i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc['group'], 'customers', $i7137e40370cf1c5ccf937060891613788203e2d6)); } $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a = new Varien_Data_Collection(); Mage::dispatchEvent('topefekt_magesms_customersms_groups', array('groups' => $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a)); foreach ($ia8a35a47a8e61218e15d1a33dac64bdc2449c01a as $i4abcdb69150d2b99477ddace90c2020fb244c4f6) { if ($i4abcdb69150d2b99477ddace90c2020fb244c4f6->getGroup() && !$this->v2b483c223d472d1fb22c9823dcc35f84765b2c06->getItemByColumnValue('group', $i4abcdb69150d2b99477ddace90c2020fb244c4f6->getGroup())) { $this->v2b483c223d472d1fb22c9823dcc35f84765b2c06->addItem($i4abcdb69150d2b99477ddace90c2020fb244c4f6); } else { foreach($i4abcdb69150d2b99477ddace90c2020fb244c4f6->getHooks() as $i42ee48f418943c9662de0976069476c7dc8f620d) { if ($i42ee48f418943c9662de0976069476c7dc8f620d->getName() && ($i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc = $this->v2b483c223d472d1fb22c9823dcc35f84765b2c06->getItemByColumnValue('group', $i42ee48f418943c9662de0976069476c7dc8f620d->getGroup()))) { $ib621bf9fa69ea2cdc5a9bc8679d915479caec16a = $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc->getHooks(); $ib621bf9fa69ea2cdc5a9bc8679d915479caec16a[$i42ee48f418943c9662de0976069476c7dc8f620d->getName()] = $i42ee48f418943c9662de0976069476c7dc8f620d; $i45529c33bd7aa0ebcc4b6e41bd3e02f2889252fc->setHooks($ib621bf9fa69ea2cdc5a9bc8679d915479caec16a); } } } } $i8ee45e0018a32fb1a855b82624506e35789cc4d2->setGroups($this->v2b483c223d472d1fb22c9823dcc35f84765b2c06); $this->getLayout()->getBlock('content')->append($i8ee45e0018a32fb1a855b82624506e35789cc4d2); $this->renderLayout(); return $this; } public function addmutationAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('country', 'default'); $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates')->getCollection()->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6); if (!$idb618c56be2c8abc9a54a16881dadfd5317ba624->count()) { $i195899c9895b81b9bc75dba762c949638a6f36dd = Mage::getSingleton('magesms/country_area')->getCollection()->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6); $i7d716a8fdc4101e29ab8fd7002b332e962603d8c = array(); foreach($i195899c9895b81b9bc75dba762c949638a6f36dd as $i037b855bc01175f2c77d5c3e19eda9a0003feff4) { $i7d716a8fdc4101e29ab8fd7002b332e962603d8c[] = $i037b855bc01175f2c77d5c3e19eda9a0003feff4->getCountryName(); } if (count($i7d716a8fdc4101e29ab8fd7002b332e962603d8c)) { $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates'); $idb618c56be2c8abc9a54a16881dadfd5317ba624->setArea($i7137e40370cf1c5ccf937060891613788203e2d6); $idb618c56be2c8abc9a54a16881dadfd5317ba624->setAreaText(implode(', ', $i7d716a8fdc4101e29ab8fd7002b332e962603d8c)); $idb618c56be2c8abc9a54a16881dadfd5317ba624->save(); Mage::getSingleton('adminhtml/session')->addSuccess( Mage::helper('magesms')->__('SMS text version for ').$idb618c56be2c8abc9a54a16881dadfd5317ba624->getAreaText(). Mage::helper('magesms')->__(' was saved') ); } } $this->_redirect('*/*/', array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6)); return $this; } public function delmutationAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation'); if ($i7137e40370cf1c5ccf937060891613788203e2d6) { $idb618c56be2c8abc9a54a16881dadfd5317ba624 = Mage::getSingleton('magesms/hooks_templates') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->getFirstItem() ->delete(); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->addFilter('type', 'customer') ->getFirstItem() ->delete(); $ibad8f78c098260b16424eb12ceee5f8336591d56 = Mage::getSingleton('magesms/hooks_customers') ->getCollection() ->addFilter('mutation', $i7137e40370cf1c5ccf937060891613788203e2d6); foreach($ibad8f78c098260b16424eb12ceee5f8336591d56 as $i21e55df616c305955791876c1eb4da83448beba2) $i21e55df616c305955791876c1eb4da83448beba2->delete(); Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('SMS text version was deleted.')); } $this->_redirect('*/*/index'); return $this; } public function saveunicodeAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation'); if ($i7137e40370cf1c5ccf937060891613788203e2d6) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode') ->getCollection() ->addFilter('area', $i7137e40370cf1c5ccf937060891613788203e2d6) ->addFilter('type', 'customer') ->getFirstItem(); if (!count($ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->getData())) { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd = Mage::getSingleton('magesms/hooks_unicode'); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setArea($i7137e40370cf1c5ccf937060891613788203e2d6); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setType('customer'); $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setUnicode($this->getRequest()->getParam('unicode' , 0)); } else { $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->setUnicode($this->getRequest()->getParam('unicode' , 0)); } $ie8d90f6313614fbb6564426c0b0cb59a0ca4cecd->save(); Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('Unicode was saved.')); } $this->_redirect('*/*/', array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6)); return $this; } public function savehookAction() { $i7137e40370cf1c5ccf937060891613788203e2d6 = $this->getRequest()->getParam('mutation', 'default'); $i30f20aafde612a957f7f966cb5b85e35782bc88a = $this->getRequest()->getParam('type'); $i2bd9743336318d0e14be0600c9129730279505dd = $this->getRequest()->getParam('name'); $id2202a8a92e3022b2b00717b92bc918373dc2edc = $this->getRequest()->getParam('plugin'); $i24273814df383b4a6926acc1db1a788b12f5a411 = $this->getRequest()->getParam('text' , ''); if ($i30f20aafde612a957f7f966cb5b85e35782bc88a && $i2bd9743336318d0e14be0600c9129730279505dd && $i24273814df383b4a6926acc1db1a788b12f5a411) { if ($id2202a8a92e3022b2b00717b92bc918373dc2edc) { Mage::dispatchEvent('topefekt_magesms_customersms_save'); } else { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks_'.$i30f20aafde612a957f7f966cb5b85e35782bc88a) ->getCollection() ->addFilter('name', $i2bd9743336318d0e14be0600c9129730279505dd) ->addFilter('mutation', $i7137e40370cf1c5ccf937060891613788203e2d6) ->getFirstItem(); if (!count($i42ee48f418943c9662de0976069476c7dc8f620d->getData())) { $i42ee48f418943c9662de0976069476c7dc8f620d = Mage::getSingleton('magesms/hooks_'.$i30f20aafde612a957f7f966cb5b85e35782bc88a); $i42ee48f418943c9662de0976069476c7dc8f620d->setMutation($i7137e40370cf1c5ccf937060891613788203e2d6); $i42ee48f418943c9662de0976069476c7dc8f620d->setName($i2bd9743336318d0e14be0600c9129730279505dd); } $i42ee48f418943c9662de0976069476c7dc8f620d->setActive($this->getRequest()->getParam('active' , 0)); $i42ee48f418943c9662de0976069476c7dc8f620d->setSmstext($i24273814df383b4a6926acc1db1a788b12f5a411); $i42ee48f418943c9662de0976069476c7dc8f620d->save(); } Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('magesms')->__('Text of SMS was saved.')); } $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a = array('_fragment' => $i2bd9743336318d0e14be0600c9129730279505dd); if ($i7137e40370cf1c5ccf937060891613788203e2d6 != 'default') $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a += array('mutation' => $i7137e40370cf1c5ccf937060891613788203e2d6); $this->_redirect('*/*/', $ia8a35a47a8e61218e15d1a33dac64bdc2449c01a); return $this; } protected function _initAction() { parent::_initAction(); $this->_setActiveMenu('magesms/customersms') ->_title(Mage::helper('magesms')->__('Customer SMS')) ; return $this; } }
|
app/code/community/Topefekt/Magesms/etc/config.xml
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Topefekt_Magesms>
|
5 |
-
<version>1.
|
6 |
</Topefekt_Magesms>
|
7 |
</modules>
|
8 |
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Topefekt_Magesms>
|
5 |
+
<version>1.3.0</version>
|
6 |
</Topefekt_Magesms>
|
7 |
</modules>
|
8 |
|
app/code/community/Topefekt/Magesms/etc/system.xml
CHANGED
@@ -1,9 +1,15 @@
|
|
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
<config>
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
<sections>
|
4 |
<magesms translate="label" module="magesms">
|
5 |
-
<label>
|
6 |
-
<tab>
|
7 |
<frontend_type>text</frontend_type>
|
8 |
<sort_order>101</sort_order>
|
9 |
<show_in_default>1</show_in_default>
|
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
<config>
|
3 |
+
<tabs>
|
4 |
+
<magesms_tab translate="label" module="magesms">
|
5 |
+
<label>Mage SMS</label>
|
6 |
+
<sort_order>500</sort_order>
|
7 |
+
</magesms_tab>
|
8 |
+
</tabs>
|
9 |
<sections>
|
10 |
<magesms translate="label" module="magesms">
|
11 |
+
<label>Configuration</label>
|
12 |
+
<tab>magesms_tab</tab>
|
13 |
<frontend_type>text</frontend_type>
|
14 |
<sort_order>101</sort_order>
|
15 |
<show_in_default>1</show_in_default>
|
app/design/adminhtml/default/default/template/topefekt/magesms/customersms.phtml
CHANGED
@@ -13,8 +13,8 @@
|
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
-
?><?php $user = $this->profile->user; ?><?php $lang = $this->profile->lang; ?><?php $mutation = $this->getRequest()->getParam('mutation', 'default');
|
17 |
countitSMS_<?php echo $hook->getName(); ?> = new countitSMS(document.getElementById('textfake_<?php echo $hook->getName(); ?>'), '<?php echo $unicode; ?>', document.getElementById('label_<?php echo $hook->getName(); ?>'));countitSMS_<?php echo $hook->getName(); ?>.chartext1 = '<?php echo Mage::helper('magesms')->__('Characters: '); ?>';countitSMS_<?php echo $hook->getName(); ?>.chartext2 = '<?php echo Mage::helper('magesms')->__('total sms:'); ?>';countitSMS_<?php echo $hook->getName(); ?>.alert = '';countitSMS_<?php echo $hook->getName(); ?>.translate = {<?php echo Mage::helper('magesms')->hookVariablesJS($hook->getNotice()); ?>};countitSMS_<?php echo $hook->getName(); ?>.copyFrom = document.getElementById('text_<?php echo $hook->getName(); ?>');$('text_<?php echo $hook->getName(); ?>').onkeyup = function() {countitSMS_<?php echo $hook->getName(); ?>.count();};Event.observe(window, "load", function() {countitSMS_<?php echo $hook->getName(); ?>.count();countitSMS_<?php echo $hook->getName(); ?>.help(document.getElementById('notice_<?php echo $hook->getName(); ?>'));});
|
18 |
-
//]]></script><div class="clear"></div
|
19 |
Event.observe(window, "load", function(){var gridData = document.getElementById('magesms');var tr_array = gridData.getElementsByTagName('tr');for (var i=0, len=tr_array.length; i < len; i++) {if (tr_array[i].className.indexOf('hover') !== -1) {tr_array[i].onmouseover = function() {this.className = this.className + ' on-mouse';};tr_array[i].onmouseout = function() {this.className = this.className.replace(' on-mouse', '');};tr_array[i].onclick = function() {var arr = this.id.split('_');var next = document.getElementById('histd_'+arr[1]);if (next.style.display == 'none') {next.style.display = 'table-row';} else {next.style.display = 'none';}var img = this.getElementsByClassName('img');if (img[0].style.display == 'none') {img[0].style.display = 'inline';} else {img[0].style.display = 'none';}if (img[1].style.display == 'none') {img[1].style.display = 'inline';} else {img[1].style.display = 'none';}};}}if (window.location.hash.substr(1)) {$('hist_' + window.location.hash.substr(1)).click();$('hist_' + window.location.hash.substr(1)).scrollIntoView(true);var messageTo = $('hist_' + window.location.hash.substr(1)).parentNode.parentNode.parentNode;var messages = $('messages').cloneNode(true);messageTo.insertBefore(messages, messageTo.childNodes[0]);}});
|
20 |
//]]></script></div>
|
13 |
* @copyright Copyright (c) 2012-2014 TOPefekt s.r.o. (http://www.mage-sms.com)
|
14 |
* @license http://opensource.org/licenses/BSD-3-Clause
|
15 |
*/
|
16 |
+
?><?php $user = $this->profile->user; ?><?php $lang = $this->profile->lang; ?><?php $mutation = $this->getRequest()->getParam('mutation', 'default'); ?><h2><?php echo Mage::helper('magesms')->__('Customer SMS').' - '; ?><?php if ($mutation == 'default') { echo $mutation_text = Mage::helper('magesms')->__('default').' '.Mage::helper('magesms')->__(' language version'); } else { $country = Mage::getSingleton('magesms/hooks_templates')->getCollection() ->addFilter('area', $mutation)->getFirstItem(); echo $mutation_text = $country->getAreaText().' (+'.$mutation.')'; } ?></h2><p><?php echo Mage::helper('magesms')->__('Select events during which shall be customer notified via SMS and customize text of messages. You can also add a new language version of SMS messages for each country separately. In countries with undefined language version will be used default language version.'); ?></p><div id="magesms"><div class="entry-edit"><div class="entry-edit-head"><h4 class="icon-head fieldset-legend head-account"><img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/translation.gif'; ?>" alt="" /> <?php echo Mage::helper('magesms')->__('Add SMS text version'); ?></h4></div><div class="fieldset grid"><div style="float:right"><?php $templates = Mage::getSingleton('magesms/hooks_templates')->getCollection(); if ($templates->count()): ?><table class="data"><tr><td colspan="3"><a href="<?php echo Mage::helper("adminhtml")->getUrl('*/*/index'); ?>" style="<?php echo $mutation == 'default' ? 'font-weight:bold;' : ''; ?>"><?php echo Mage::helper('magesms')->__('default'); ?></a></td></tr><?php foreach($templates as $template): ?><tr><td><a href="<?php echo Mage::helper("adminhtml")->getUrl('*/*/index', array('mutation' => $template->getArea())); ?>" style="<?php echo $template->getArea() == $mutation ? 'font-weight:bold;' : ''; ?>"><?php echo $template->getAreaText(); ?></a></td><td>(+<?php echo $template->getArea(); ?>)</td><td><a href="<?php echo Mage::helper("adminhtml")->getUrl('*/*/delmutation', array('mutation' => $template->getArea())); ?>" onclick="return confirm('<?php echo Mage::helper('magesms')->__('Are you sure to delete').' '.$template->getAreaText().'?'; ?>')"><img title="<?php echo Mage::helper('magesms')->__('DELETE language version'). ' '.$template->getAreaText(); ?>" alt="delete <?php echo $template->getAreaText(); ?>" style="border:0px;" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/delete.gif'; ?>" /></a></td></tr><?php endforeach; ?></table><?php endif; ?></div><form id="magesms_addmutation" action="<?php echo Mage::getUrl('*/*/addmutation') ?>" method="post"><input name="form_key" type="hidden" value="<?php echo Mage::getSingleton('core/session')->getFormKey() ?>" /><div class="margin-form"><label for="country"><?php echo Mage::helper('magesms')->__('Select country: '); ?></label><select name="country" id="country"><?php foreach( Mage::getSingleton('magesms/country_area') ->getCollection() ->addFieldToFilter('area', array('nin'=>array(0))) ->setOrder('country_name', 'ASC') as $country ): ?><option value="<?php echo $country->getArea(); ?>" <?php echo $lang == $country->getCountryName() ? 'selected' : ''; ?>><?php echo $country->getCountryName(); ?> (+<?php echo $country->getArea(); ?>)</option><?php endforeach; ?></select><input type="submit" value="<?php echo Mage::helper('magesms')->__('Add'); ?>" class="form-button" /></div></form><div class="clear"></div></div></div><div class="entry-edit"><div class="entry-edit-head"><h4 class="icon-head fieldset-legend head-account"><img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/AdminTools.gif'; ?>" alt="" /> <?php echo Mage::helper('magesms')->__('Unicode SMS').' - '.$mutation_text; ?></h4></div><div class="fieldset grid"><form id="magesms_changeunicode" action="<?php echo Mage::getUrl('*/*/saveunicode') ?>" method="post"><input name="form_key" type="hidden" value="<?php echo Mage::getSingleton('core/session')->getFormKey() ?>" /><div class="margin-form"><p><?php echo Mage::helper('magesms')->__('Check only if you want to use Chinese, Arabic, Greek, Hebrew, Korean, Cyrillic, etc. or diacritic in the text of your SMS message (Unicode text allows you to insert characters in all fonts and various other symbols simultaneously. Number of characters in one SMS will be reduced to 70).'); ?></p><input type="checkbox" id="unicode" name="unicode" value="1" <?php echo ($unicode = Mage::getSingleton('magesms/hooks_unicode')->getCollection()->addFilter('area', $mutation)->addFilter('type', 'customer')->getFirstItem()->getUnicode()) ? 'checked' : ''; ?> /><input type="hidden" name="mutation" value="<?php echo $mutation; ?>" /><label for="unicode"><?php echo Mage::helper('magesms')->__('Unicode SMS'); ?></label><input type="submit" value="<?php echo Mage::helper('magesms')->__('Save'); ?>" class="form-button" /></div></form></div></div><?php foreach ($this->getGroups() as $group): ?><div class="entry-edit"><div class="entry-edit-head"><h4 class="icon-head fieldset-legend head-account"><?php if ($group->icon): ?><img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).$group->icon; ?>" alt="" /> <?php endif; ?><?php echo $group->name; ?></h4></div><div class="fieldset grid"><?php if (count($group->getHooks())): ?><table class="data"><col /><col width="100px" /><?php $even = 1; foreach($group->getHooks() as $hook): if ($even) $even = 0; else $even = 1; ?><tr id="hist_<?php echo $hook->getName(); ?>" class="hover <?php if ($even) echo 'even'?>"><td><span class="img"><img class="toggle" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/i_plus.gif'; ?>"></span><span class="img" style="display:none"><img class="toggle" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/i_minus.gif'; ?>"></span><?php if (!$group->getGroup()): ?><?php echo $hook->getInfo(); ?> - <?php echo $statusT = Mage::helper('sales')->__($hook->getStatusName()); ?><?php if ($statusT != $hook->getStatusName()): ?> (<?php echo $hook->getStatusName(); ?>)<?php endif; ?><?php else: ?><?php echo $hook->getName(); ?> - <?php echo $hook->getInfo(); ?><?php endif; ?></td><td class="a-center"><?php $title = $hook->getActive() ? Mage::helper('magesms')->__('Sending notifications via SMS is ACTIVE') : Mage::helper('magesms')->__('Sending notifications via SMS is NOT ACTIVE. To activate SMS sending check „Active“ in desired status detail.'); $img = $hook->getActive() ? 'i_accepted.gif' : 'i_canceled.gif'; ?><span style="cursor:help;" title="<?php echo $title; ?>" onclick="popup_title(this)"><img class="toggle" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA).'magesms/'.$img; ?>"></span></td></tr><tr id="histd_<?php echo $hook->getName(); ?>" style="display:none"><td colspan="2"><form id="hook_<?php echo $hook->getName(); ?>" action="<?php echo Mage::getUrl('*/*/savehook') ?>" method="post"><input name="form_key" type="hidden" value="<?php echo Mage::getSingleton('core/session')->getFormKey() ?>" /><input type="hidden" name="type" value="customers" /><input type="hidden" name="name" value="<?php echo $hook->getName(); ?>" /><input type="hidden" name="mutation" value="<?php echo $mutation; ?>" /><?php if ($hook->getPlugin()): ?><input type="hidden" name="plugin" value="<?php echo $hook->getPlugin(); ?>" /><?php endif; ?><div style="display:inline-block;width:350px;"><label style="font-weight:normal;text-align:left;width:350px;"><?php echo Mage::helper('magesms')->__('SMS text'); ?></label><br><textarea id="text_<?php echo $hook->getName(); ?>" name="text" class="required-entry input-text" style="width:290px;height:100px;border:1px solid grey;"><?php echo ($text = $hook->getSmstext()) ? $text : $hook->getTemplate2(); ?></textarea></div><div style="display:inline-block;width:320px;"><label style="font-weight:normal;text-align:left"><?php echo Mage::helper('magesms')->__('Preview'); ?> (<span id="label_<?php echo $hook->getName(); ?>"></span>)</label><br><textarea id="textfake_<?php echo $hook->getName(); ?>" name="textfake" disabled="disabled" style="width:290px;height:100px;border:1px solid grey;"></textarea></div><div style="display:inline-block;width:310px;"><?php echo Mage::helper('magesms')->__('Active'); ?><br /><br /><input type="checkbox" name="active" id="active_<?php echo $hook->getName(); ?>" value="1" <?php echo $hook->getActive() ? 'checked' : ''; ?> /><label for="active_<?php echo $hook->getName(); ?>"><?php echo Mage::helper('magesms')->__('Active'); ?></label><br /><br /><br /><div style="float:left;"><input type="submit" value="<?php echo Mage::helper('magesms')->__('Save'); ?>" class="form-button" /></div><div style="float:left;padding-left:20px;"><input value="<?php echo Mage::helper('magesms')->__('Cancel'); ?>" title="Restore unsaved changes to its original state." class="form-button" type="button" onclick="this.form.reset();countitSMS_<?php echo $hook->getName(); ?>.count();" /></div></div><?php if ($hook->getCustomForm()): ?><?php echo $hook->getCustomForm();?><?php endif; ?></form><script type="text/javascript">//<![CDATA[
|
17 |
countitSMS_<?php echo $hook->getName(); ?> = new countitSMS(document.getElementById('textfake_<?php echo $hook->getName(); ?>'), '<?php echo $unicode; ?>', document.getElementById('label_<?php echo $hook->getName(); ?>'));countitSMS_<?php echo $hook->getName(); ?>.chartext1 = '<?php echo Mage::helper('magesms')->__('Characters: '); ?>';countitSMS_<?php echo $hook->getName(); ?>.chartext2 = '<?php echo Mage::helper('magesms')->__('total sms:'); ?>';countitSMS_<?php echo $hook->getName(); ?>.alert = '';countitSMS_<?php echo $hook->getName(); ?>.translate = {<?php echo Mage::helper('magesms')->hookVariablesJS($hook->getNotice()); ?>};countitSMS_<?php echo $hook->getName(); ?>.copyFrom = document.getElementById('text_<?php echo $hook->getName(); ?>');$('text_<?php echo $hook->getName(); ?>').onkeyup = function() {countitSMS_<?php echo $hook->getName(); ?>.count();};Event.observe(window, "load", function() {countitSMS_<?php echo $hook->getName(); ?>.count();countitSMS_<?php echo $hook->getName(); ?>.help(document.getElementById('notice_<?php echo $hook->getName(); ?>'));});
|
18 |
+
//]]></script><div class="clear"></div><?php if ($hook->getNotice()): ?><span style="font-size:10px;"><?php echo Mage::helper('magesms')->__('Possible variables:'); ?><br /><div id="notice_<?php echo $hook->getName(); ?>"><?php echo $hook->getNotice(); ?></div></span><?php endif?></td></tr><?php endforeach; ?></table><?php endif; ?></div></div><?php endforeach; ?><script type="text/javascript">//<![CDATA[
|
19 |
Event.observe(window, "load", function(){var gridData = document.getElementById('magesms');var tr_array = gridData.getElementsByTagName('tr');for (var i=0, len=tr_array.length; i < len; i++) {if (tr_array[i].className.indexOf('hover') !== -1) {tr_array[i].onmouseover = function() {this.className = this.className + ' on-mouse';};tr_array[i].onmouseout = function() {this.className = this.className.replace(' on-mouse', '');};tr_array[i].onclick = function() {var arr = this.id.split('_');var next = document.getElementById('histd_'+arr[1]);if (next.style.display == 'none') {next.style.display = 'table-row';} else {next.style.display = 'none';}var img = this.getElementsByClassName('img');if (img[0].style.display == 'none') {img[0].style.display = 'inline';} else {img[0].style.display = 'none';}if (img[1].style.display == 'none') {img[1].style.display = 'inline';} else {img[1].style.display = 'none';}};}}if (window.location.hash.substr(1)) {$('hist_' + window.location.hash.substr(1)).click();$('hist_' + window.location.hash.substr(1)).scrollIntoView(true);var messageTo = $('hist_' + window.location.hash.substr(1)).parentNode.parentNode.parentNode;var messages = $('messages').cloneNode(true);messageTo.insertBefore(messages, messageTo.childNodes[0]);}});
|
20 |
//]]></script></div>
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>TOPefekt_Magesms</name>
|
4 |
-
<version>1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/BSD-3-Clause">BSD</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>Free SMS module for Magento with advanced features and user friendly design.</description>
|
11 |
<notes>2014</notes>
|
12 |
<authors><author><name>Frantisek Barancik</name><user>SIRAPY</user><email>barancik@sirapy.cz</email></author><author><name>Lubomir Kozak</name><user>TOPefekt</user><email>info@topefekt.com</email></author></authors>
|
13 |
-
<date>2014-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Topefekt"><dir name="Magesms"><dir name="Block"><dir name="Answers"><file name="Grid.php" hash="b4161fe0c9f84ae2842ad1c5b1fee67b"/><dir name="Renderer"><file name="Actions.php" hash="8978857641921533a7ef1a511d6e98cc"/><file name="Smsc.php" hash="dec1e2ffb867499edaf2660e83a1f763"/></dir></dir><file name="Answers.php" hash="d8e8f1ddc9dc2c200d48ba61fd45f258"/><dir name="Customer"><file name="Grid.php" hash="01cd30df42024487ddbb85dc805b29f2"/></dir><file name="Customer.php" hash="8817fa3634895fb9317fc7c979f326fa"/><file name="Magesms.php" hash="80c1ac3571e5305b9a18a332d50d3598"/><dir name="Marketing"><file name="Customer.php" hash="91fcf8f90baf8ceeef6bdce74838e9e9"/><file name="Form.php" hash="1f6f5fb07741aae051f4250a027df299"/><file name="Grid.php" hash="6866d29549f350f009971deda49f31f7"/><file name="Template.php" hash="1f48e5754feb003ff361824ca0e29ebb"/></dir><file name="Marketing.php" hash="298b9175edc892566097f199f95f0d95"/><file name="Profile.php" hash="87be5911ea730b61179eaa43274ed031"/><file name="ShowTabsAdminBlock.php" hash="9d021b7bfa6ca922d7074313865bde87"/><dir name="System"><dir name="Config"><file name="Apikeygenerator.php" hash="9b5f9256de21a985efbacbbc00032296"/></dir></dir><dir name="Template"><file name="Template.php" hash="4713fdc848c5f1d5ab771011df11ff40"/></dir><file name="Template.php" hash="1420e7b7615214a3cfe8ef87d86ebd1a"/><dir name="Wizard"><file name="Grid.php" hash="62ea044623fda139cdc23e8a768d1b60"/></dir><file name="Wizard.php" hash="ef10fbfc80385cb9e90e7a6bfbf555f4"/></dir><dir name="Controller"><file name="Action.php" hash="a12f3ca7279da57be21521e7e1f33b7b"/><dir name="Template"><file name="Action.php" hash="c1fbebd2736adfbeb1ad7dd1d93fe2d9"/></dir></dir><dir name="Helper"><dir name="Adminhtml"><file name="Data.php" hash="ebf8c3ac5f4ede5e30218f307c60c9c3"/></dir><file name="Data.php" hash="ce1437fd6586beb716b631fa5617fe04"/></dir><dir name="Model"><file name="Admins.php" hash="ced35da523fa261708ca76bf09744492"/><file name="Answers.php" hash="33fcc03e70064860f47b17291b2682ec"/><file name="Api.php" hash="6b5b23ac096fd8090926bc7fc5e6900c"/><dir name="Country"><file name="Area.php" hash="4268548148d51c519328472ae744e0cd"/><file name="Lang.php" hash="1c47ceb19d913853c9ee7ab9b50f010a"/></dir><file name="Country.php" hash="6ea4a1f25f0c43c14392903328bbf794"/><file name="Exceptions.php" hash="856910cdd46ffcfb8b961826c8563670"/><dir name="Hooks"><file name="Admins.php" hash="c42b32a696e6101f50dc67942d738e6d"/><file name="Customers.php" hash="cc275a7f7c738174b420bd3c3301f79d"/><file name="Templates.php" hash="bcf959ff2f2c84bc8f287e5d7dfd637a"/><file name="Unicode.php" hash="351a49d393871e186921a98376aaa5bb"/></dir><file name="Hooks.php" hash="522c2544fc306cb35bcfff8f456420d7"/><file name="Magesms.php" hash="e299fef5c1617dc2aba79861a170ee57"/><file name="Maps.php" hash="7526a18b5bda119e8b564b95e13c823f"/><dir name="Marketing"><dir name="Filter"><file name="Birthday.php" hash="56d6e9638c2548a9dabd86548609d04d"/><file name="Birthdayall.php" hash="52b7459447fd8964c79bff54aef7499e"/><file name="City.php" hash="851bf11fa4eba68f5afe90bc73061075"/><file name="Collection.php" hash="a59b5af9d4dbdb3a4f4d2a319991526a"/><file name="Country.php" hash="226ea48e858db867cad73ec5df430481"/><file name="Firstname.php" hash="d2fb9d1c18d65616e85b94a19d937303"/><file name="Gender.php" hash="08583ec548a718fd598db0c8382f8fea"/><file name="Group.php" hash="5ae6a9e763a228d66dec97d6edd9504b"/><file name="Lastname.php" hash="4ce733ed97662ae7e3b9bd7fd09a9b23"/><file name="Newsletter.php" hash="e32e2584c4a5b4e83774c90ca8e03d21"/><file name="Register.php" hash="18462dd6abae0d72f6863a285364885a"/><file name="Type.php" hash="49b3fefa77c399003a60edc716a19810"/><file name="Website.php" hash="998fa5822c12e7e10a9363c74922d25f"/></dir><file name="Filter.php" hash="c67e8a70e671dc9c05194d6fea62ba1d"/></dir><dir name="Mysql4"><dir name="Admins"><file name="Collection.php" hash="c1ada270e5c640cc77beca20a90c06c1"/></dir><file name="Admins.php" hash="c1efc07554a47ddd61add948f8d7184d"/><dir name="Answers"><file name="Collection.php" hash="e0d1dfb4666cd442105b786cd8e1938b"/></dir><file name="Answers.php" hash="9b116c0acd6598b22fda9a3f7bfd0e1f"/><file name="Collection.php" hash="0713d799c11bcc14437ca3924d0aae0f"/><dir name="Country"><dir name="Area"><file name="Collection.php" hash="57076e9ef2eaee34ede11fd2b8c079ea"/></dir><file name="Area.php" hash="cb14e562273148090fcafe17a5764dcf"/><file name="Collection.php" hash="9d1c5aa0e9d956d98e45706dd24dc0f0"/><dir name="Lang"><file name="Collection.php" hash="5784492b259d0636c5c37f3f945873cf"/></dir><file name="Lang.php" hash="45c61334ccc799908468603a1601f75f"/></dir><file name="Country.php" hash="dd1e7ba04fb2d2484fcd14d35fd63513"/><dir name="Exceptions"><file name="Collection.php" hash="0f27011bb167d3686149edcea2cf9af0"/></dir><file name="Exceptions.php" hash="087363570c7e19e98343508fde136b71"/><dir name="Hooks"><dir name="Admins"><file name="Collection.php" hash="08c59f372ae4d724d1451836df655deb"/></dir><file name="Admins.php" hash="0b97679a105c98c53fb27e6f35cc49da"/><file name="Collection.php" hash="781323404157c7935539212e6c9d5948"/><dir name="Customers"><file name="Collection.php" hash="9f85b8e63521abcc575d717eaca6f7b0"/></dir><file name="Customers.php" hash="446451f0e038bc5b25ec0d3032a608a9"/><dir name="Templates"><file name="Collection.php" hash="10d674db501bdd93bfc11e0411be53b2"/></dir><file name="Templates.php" hash="b9d88cc611aa7c5ea369d9b4056a3858"/><dir name="Unicode"><file name="Collection.php" hash="e30a9e81400f25829b89d8fa4927e4e7"/></dir><file name="Unicode.php" hash="930b9f23e7b0674cef75898bebd8d4f5"/></dir><file name="Hooks.php" hash="db0d3898325974475d39f0dd786a0c7d"/><dir name="Maps"><file name="Collection.php" hash="2b8609291dc25d2445b1c168024c1783"/></dir><file name="Maps.php" hash="21e7e04096b879db02971223dbf11a1a"/><dir name="Marketing"><dir name="Filter"><file name="Collection.php" hash="ee5bfddfe067a317c94b62eea4e59aeb"/></dir><file name="Filter.php" hash="42342671cb9bcbca71165ffffa7d309d"/></dir><dir name="Ownnumbersender"><file name="Collection.php" hash="0f77ebc089da24e306dc2616178fab35"/></dir><file name="Ownnumbersender.php" hash="0b8963a836de22ff2c54ec8a6f0819bd"/><dir name="Routes"><dir name="Alternative"><file name="Collection.php" hash="dd8908e3c72bef9a4d54ab4d04119fc9"/></dir><file name="Alternative.php" hash="0b07c80a9b35a1dc6f16e310614ddbda"/><file name="Collection.php" hash="9a9f26422877c0ff82f5bc3a6865ed1f"/></dir><file name="Routes.php" hash="f500ad3e8d96b8742a194015acdd4c58"/><dir name="Smshistory"><file name="Collection.php" hash="76f838ee4e14af4789e494badf46ad84"/></dir><file name="Smshistory.php" hash="15edfec649fa894ec310e3e37d97f694"/><dir name="Smsuser"><file name="Collection.php" hash="dad8d028a32e3a860d254c0957f9d23f"/></dir><file name="Smsuser.php" hash="b9913d6c444f646623d6e282f35e8a08"/><dir name="Template"><file name="Collection.php" hash="a9e237b2e23e64e7226a95d3e6e9a7dc"/></dir><file name="Template.php" hash="20a0aad89f43fa6716d96ece9f243000"/><dir name="Textsender"><file name="Collection.php" hash="1574273dc207231460977dce7af007a9"/></dir><file name="Textsender.php" hash="242e7ac5f28b7e7b8521e201fe7cf806"/><dir name="Variables"><file name="Collection.php" hash="0c249b390280ba16db97d3acd320fedb"/></dir><file name="Variables.php" hash="e364920ad4d1a69f33ec037184f27de7"/></dir><file name="Observer.php" hash="49e655453ae47a6420161997cf2c0f80"/><dir name="Overide"><dir name="Cataloginventory"><file name="Stock.php" hash="76e53307192e54dc08b0983288acdda3"/></dir></dir><file name="Ownnumbersender.php" hash="c209b3a3756491c3d9f30c1a9055361b"/><dir name="Routes"><file name="Alternative.php" hash="c52374301eb8e0726dc54e8b08b24a8d"/></dir><file name="Routes.php" hash="917bf19f5983ccafa6e61cd9cc1d8f13"/><file name="Sms.php" hash="5df02903304d576cfac33698565ecc0f"/><file name="Smshistory.php" hash="b96ef0d1f609d28159c5a03777c953ce"/><file name="Smsprofile.php" hash="4ff023aa338c1eab827448e2c0712852"/><file name="Smsuser.php" hash="1f4906fe7a288e95de706b1343f5b985"/><dir name="System"><dir name="Config"><file name="Lang.php" hash="7bb45d97a8c3f4b4a32bf1229f5cab8b"/></dir></dir><file name="Template.php" hash="8590ec1c798028e5025bf866629bf719"/><file name="Textsender.php" hash="589c0a2087ba27d6e5310796b60e6a48"/><file name="Variables.php" hash="12844fb6fc0c4258cdcbb8d6b5343fc9"/></dir><file name="api_test1.php" hash="8a71c6b1d085ee65b3bde60c20379c9d"/><file name="api_test2.php" hash="6c1d19f8fc1e8a71a1f3129541939262"/><file name="api_test3.php" hash="9c162033d327a93bc974aa20804c161d"/><dir name="controllers"><dir name="Adminhtml"><dir name="Magesms"><file name="AboutController.php" hash="28de3dfca6c6a9ff46228ae4833ea10b"/><file name="AdminsmsController.php" hash="3de78bd855405893f2ad460c33f7d737"/><file name="AnswersController.php" hash="ca05a9506f32a90ff359f01f90ff7031"/><file name="CustomersmsController.php" hash="98482d09c3a1194170f0b010e5c0487e"/><file name="HistoryController.php" hash="ca2a53f872a87ce16bbacfb1bcbb376b"/><file name="MarketingController.php" hash="754ac431dd48cb4b25ee1ade24d31e1f"/><file name="OptoutController.php" hash="4e72b192749f1fabf527194712094414"/><file name="ProfileController.php" hash="511e53d9ed0df629c2fbc213b3ef5c9d"/><file name="PurchasecreditController.php" hash="377c26a55d5fc6e0ebfa281298747a00"/><file name="SendsmsController.php" hash="aa163c55589f55bc03e97a6d1ad78b71"/><file name="StatisticsController.php" hash="65b69a09bf45b80291a15c87ebb6ad04"/><file name="WizardController.php" hash="fadcde5fbdf51869a917b8bc20596530"/></dir></dir><file name="ApiController.php" hash="9756da9bfb339b1ddbab7883b7e362b1"/><file name="DeliveryController.php" hash="8f604254b6c19c9adb84bea325e3c8ea"/><file name="IndexController.php" hash="aa69e6f90f6e822941f382b1162c75d6"/></dir><dir name="data"><dir name="magesms_setup"><file name="data-install-1.0.0.php" hash="5df79e7e9193abbac12191f35c4d45a9"/><file name="data-upgrade-1.0.1-1.0.2.php" hash="290c4939bebfd6a0529dc7da20534bf5"/><file name="data-upgrade-1.0.3-1.0.4.php" hash="a60b7ce260a43d71c3afcb62e4f875e2"/><file name="data-upgrade-1.1.0-1.1.1.php" hash="c464142a975b03b81a49ba41284e1b96"/><file name="data-upgrade-1.1.1-1.1.2.php" hash="28fc124ce1e29130056ed059e5c824f0"/><file name="data-upgrade-1.2.0-1.2.1.php" hash="119a68ac6e6238bfa07c1b5cc90045d0"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="637551698f955e9428774cc64e91ccb9"/><file name="config.xml" hash="fd1f98910320f36bf666c19745348dfe"/><file name="system.xml" hash="dbc73379e62abcbe045e203f6a0a6b41"/></dir><dir name="sql"><dir name="magesms_setup"><file name="mysql4-install-0.9.0.php" hash="b3d8975e98cb1cfe12194d7a18bbfc2f"/><file name="mysql4-install-1.0.0.php" hash="d7363753089c833e275847a9137b6c89"/><file name="mysql4-upgrade-0.9.11-0.9.12.php" hash="765533b9d6f9fa987949c0a5f73ff37d"/><file name="mysql4-upgrade-0.9.12-0.9.13.php" hash="0d3ea4875bd51593c8113805402e58fd"/><file name="mysql4-upgrade-1.0.1-1.0.2.php" hash="02b2fecd79ace03940cd7c50419c8878"/><file name="mysql4-upgrade-1.1.3-1.1.4.php" hash="d0b532bf1d394fbd27c577bd9de27564"/><file name="mysql4-upgrade-1.1.5-1.2.0.php" hash="1f32fbc9aacc4e0139fd91b35589d591"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="topefekt"><dir name="magesms"><file name="about.phtml" hash="915f3356c5819a3d7373865f665d626f"/><file name="adminsms.phtml" hash="8cd430b34c539174e2820b3c99508c9b"/><file name="customersms.phtml" hash="891bca1a083b1bcaa2399b6a1ec9be34"/><file name="history.phtml" hash="27325466405ae1a33f93978434b4ad11"/><dir name="marketing"><file name="customer.phtml" hash="5d56650f36d41535808dbcc9f0670e35"/><file name="form.phtml" hash="37a354655ae727480d779c6775d227f2"/></dir><file name="marketing.phtml" hash="630defb84f73d76435b67d05b4e4691e"/><file name="optout.phtml" hash="78891f09375e29485e58b68623a1ebb2"/><file name="profile.phtml" hash="7aa0f7b562bb8a6e4c4fc07f7058d144"/><file name="purchasecredit.phtml" hash="0ec35354e68a85b0fff078f9a8b14d96"/><file name="sendsms.phtml" hash="3a2f21302e2b246d149998bfdfea95d9"/><file name="statistics.phtml" hash="dd708338a0a5ad36bb10141ad394ea22"/><dir name="template"><file name="form.phtml" hash="e6a006574345ef9e85e28251310d96ec"/></dir><file name="wizard-alternative.phtml" hash="53128ea65c7eb6ea80faac040c0d63f2"/><file name="wizard-edit.phtml" hash="e247901a92b290fcb85128b4a08ee91d"/><file name="wizard-list.phtml" hash="cee281d28e0b61f93c0acb90f064c922"/><file name="wizard-sender.phtml" hash="3ff2f15bf3e6db24f2e771f7aa2a500b"/><file name="wizard.phtml" hash="d0a70bb920e76604959c48de8fe57c84"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Topefekt_Magesms.xml" hash="d88282bf3409717dcc6c8d36102480a3"/></dir></target><target name="magelocale"><dir><dir name="cs_CZ"><file name="Topefekt_Magesms.csv" hash="01ffb74e44c2d2374fe9ef4768888e13"/></dir><dir name="de_DE"><file name="Topefekt_Magesms.csv" hash="2e7287b30954b3126169403822669f2a"/></dir><dir name="el_GR"><file name="Topefekt_Magesms.csv" hash="b4d8c7090d22aa1ae994ea2f13b27593"/></dir><dir name="en_US"><file name="Topefekt_Magesms.csv" hash="2aeade9ce5193f08d1b19959631764d0"/></dir><dir name="es_ES"><file name="Topefekt_Magesms.csv" hash="66aae8475301ad574cdecec4511aab80"/></dir><dir name="fr_FR"><file name="Topefekt_Magesms.csv" hash="b9f82cdd6f0779e8b13dee31e7bd8974"/></dir><dir name="it_IT"><file name="Topefekt_Magesms.csv" hash="aa2a250c18b47bf5ccad1787e2dbebda"/></dir><dir name="pl_PL"><file name="Topefekt_Magesms.csv" hash="622944ce311c1ffb5e9e8fb6c4c447cc"/></dir><dir name="pt_PT"><file name="Topefekt_Magesms.csv" hash="d7b14419f2ee4469bcf023729b523e3d"/></dir><dir name="ru_RU"><file name="Topefekt_Magesms.csv" hash="c92302b7f783678c0903695a6a47fcee"/></dir><dir name="sk_SK"><file name="Topefekt_Magesms.csv" hash="5662bb27898880cfceb182daa346869e"/></dir><dir name="sr_RS"><file name="Topefekt_Magesms.csv" hash="17761427d3db52adb3d55bc68c7fece9"/></dir><dir name="tr_TR"><file name="Topefekt_Magesms.csv" hash="c64505ca859e2004090fd2729ffe7b65"/></dir></dir></target><target name="magemedia"><dir name="magesms"><file name="About.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminCatalog.gif" hash="2500d6277ec65b73cec8e858e8f3e5ef"/><file name="AdminCustomers.gif" hash="2575dfefce12bc9451e4dfa1e0972a1e"/><file name="AdminEmployees.gif" hash="cdb742ba271aae8e0f5129e9422d8480"/><file name="AdminOrders.gif" hash="b0b296f24674d37c3749a4c68e014173"/><file name="AdminSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminSmsProfile.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminTools.gif" hash="a3d566311d5cdd11470e60a30c4f1a1d"/><file name="CustomerSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="Empty.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="PayPal123.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SendSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsAnswers.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsCharging.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsHistory.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsMarketing.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsWizard.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="calendar.jpg" hash="ec1c2dde2879bca23fb232bdfb6459b1"/><file name="delete.gif" hash="b658193cc19b4be4776fbca433c86354"/><file name="edit.gif" hash="100198930f65efde449cce2d4fd3dd49"/><file name="i_accepted.gif" hash="befd5320058efee73744cb53f1ac58a6"/><file name="i_buffered.png" hash="df919a54ebb68a101899da77671a7ae4"/><file name="i_canceled.gif" hash="f54cd085dc4a709a590650df64c9307a"/><file name="i_deleted.png" hash="2cac2bf05b4f0bfc7f0b24ad3274c8aa"/><file name="i_donotdisturb.png" hash="cc15ea466d59c68c2278f9eac825fac9"/><file name="i_duplicate.png" hash="9a12c256c640bae544204d17933a8e0b"/><file name="i_error.gif" hash="45f02b921ce504353050a3921c6a6b70"/><file name="i_minus.gif" hash="16e4ff79084066203148d261b4d14712"/><file name="i_plus.gif" hash="1cc64296ccbf2bd9dfd61a0ce6a7f117"/><file name="i_scheduled.png" hash="b644f202e2a2cf0fccf073dfdc8befb1"/><file name="i_sent.png" hash="938d41c783cc770339e1febbe2fe538e"/><file name="i_simulation.png" hash="6b6f65f4c1ca5e9017c978274a186091"/><file name="licence_cz.pdf" hash="c61b5f052326b3cb74dd3346911c41bb"/><file name="licence_en.pdf" hash="5a96ef0dcb08cee786ef574c16608365"/><file name="logo.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="logocart.png" hash="cb095b552c60e3c23ac449a453981e6c"/><file name="magesms-logo.png" hash="5352d2cb3b95990a1eb237f0d48ed811"/><file name="next.gif" hash="d4a145a07fa436e51cbaa4a28c14b622"/><file name="prev.gif" hash="d1dab45da5f0690fcaac4ce62f6bd04d"/><file name="sms.png" hash="5473a773314938564ad2f8fb826445bd"/><file name="topefekt-logo.gif" hash="149c7fd9bb2a4f70637963b0036e5a07"/><file name="translation.gif" hash="d2f85c78ea940b1a62919e50175a4c4f"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="base"><dir name="default"><dir name="css"><dir name="topefekt"><dir name="magesms"><dir name="img"><file name="i_canceled.gif" hash="f54cd085dc4a709a590650df64c9307a"/><file name="i_sent.png" hash="938d41c783cc770339e1febbe2fe538e"/></dir><file name="stylesheet.css" hash="24cf22aaf8499776fda44f33ad245799"/></dir></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="topefekt"><file name="functions.js" hash="bd4bde8c632a3d5eb8d7c21278189875"/><file name="template.js" hash="26a2428302a7306fd49b940529147042"/></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>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>TOPefekt_Magesms</name>
|
4 |
+
<version>1.3.0</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/BSD-3-Clause">BSD</license>
|
7 |
<channel>community</channel>
|
10 |
<description>Free SMS module for Magento with advanced features and user friendly design.</description>
|
11 |
<notes>2014</notes>
|
12 |
<authors><author><name>Frantisek Barancik</name><user>SIRAPY</user><email>barancik@sirapy.cz</email></author><author><name>Lubomir Kozak</name><user>TOPefekt</user><email>info@topefekt.com</email></author></authors>
|
13 |
+
<date>2014-12-10</date>
|
14 |
+
<time>17:38:47</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Topefekt"><dir name="Magesms"><dir name="Block"><dir name="Answers"><file name="Grid.php" hash="b4161fe0c9f84ae2842ad1c5b1fee67b"/><dir name="Renderer"><file name="Actions.php" hash="8978857641921533a7ef1a511d6e98cc"/><file name="Smsc.php" hash="dec1e2ffb867499edaf2660e83a1f763"/></dir></dir><file name="Answers.php" hash="d8e8f1ddc9dc2c200d48ba61fd45f258"/><dir name="Customer"><file name="Grid.php" hash="01cd30df42024487ddbb85dc805b29f2"/></dir><file name="Customer.php" hash="8817fa3634895fb9317fc7c979f326fa"/><file name="Magesms.php" hash="80c1ac3571e5305b9a18a332d50d3598"/><dir name="Marketing"><file name="Customer.php" hash="91fcf8f90baf8ceeef6bdce74838e9e9"/><file name="Form.php" hash="1f6f5fb07741aae051f4250a027df299"/><file name="Grid.php" hash="6866d29549f350f009971deda49f31f7"/><file name="Template.php" hash="1f48e5754feb003ff361824ca0e29ebb"/></dir><file name="Marketing.php" hash="298b9175edc892566097f199f95f0d95"/><file name="Profile.php" hash="87be5911ea730b61179eaa43274ed031"/><file name="ShowTabsAdminBlock.php" hash="9d021b7bfa6ca922d7074313865bde87"/><dir name="System"><dir name="Config"><file name="Apikeygenerator.php" hash="9b5f9256de21a985efbacbbc00032296"/></dir></dir><dir name="Template"><file name="Template.php" hash="4713fdc848c5f1d5ab771011df11ff40"/></dir><file name="Template.php" hash="1420e7b7615214a3cfe8ef87d86ebd1a"/><dir name="Wizard"><file name="Grid.php" hash="62ea044623fda139cdc23e8a768d1b60"/></dir><file name="Wizard.php" hash="ef10fbfc80385cb9e90e7a6bfbf555f4"/></dir><dir name="Controller"><file name="Action.php" hash="a12f3ca7279da57be21521e7e1f33b7b"/><dir name="Template"><file name="Action.php" hash="0b759e85e6cb7d0c862338b4bf96664d"/></dir></dir><dir name="Helper"><dir name="Adminhtml"><file name="Data.php" hash="ebf8c3ac5f4ede5e30218f307c60c9c3"/></dir><file name="Data.php" hash="a86af234043d6639b528e5bcd23cf7b3"/></dir><dir name="Model"><file name="Admins.php" hash="ced35da523fa261708ca76bf09744492"/><file name="Answers.php" hash="33fcc03e70064860f47b17291b2682ec"/><file name="Api.php" hash="e8520b753ae28b9adefa34b43f5b58cf"/><dir name="Country"><file name="Area.php" hash="4268548148d51c519328472ae744e0cd"/><file name="Lang.php" hash="1c47ceb19d913853c9ee7ab9b50f010a"/></dir><file name="Country.php" hash="6ea4a1f25f0c43c14392903328bbf794"/><file name="Exceptions.php" hash="856910cdd46ffcfb8b961826c8563670"/><dir name="Hooks"><file name="Admins.php" hash="c42b32a696e6101f50dc67942d738e6d"/><file name="Customers.php" hash="cc275a7f7c738174b420bd3c3301f79d"/><file name="Templates.php" hash="bcf959ff2f2c84bc8f287e5d7dfd637a"/><file name="Unicode.php" hash="351a49d393871e186921a98376aaa5bb"/></dir><file name="Hooks.php" hash="f76530cbd1b5c1e966e53a04c309ac8d"/><file name="Magesms.php" hash="e299fef5c1617dc2aba79861a170ee57"/><file name="Maps.php" hash="7526a18b5bda119e8b564b95e13c823f"/><dir name="Marketing"><dir name="Filter"><file name="Birthday.php" hash="56d6e9638c2548a9dabd86548609d04d"/><file name="Birthdayall.php" hash="81b3dd750820746bf39f6fd094626683"/><file name="City.php" hash="851bf11fa4eba68f5afe90bc73061075"/><file name="Collection.php" hash="a59b5af9d4dbdb3a4f4d2a319991526a"/><file name="Country.php" hash="226ea48e858db867cad73ec5df430481"/><file name="Firstname.php" hash="d2fb9d1c18d65616e85b94a19d937303"/><file name="Gender.php" hash="08583ec548a718fd598db0c8382f8fea"/><file name="Group.php" hash="5ae6a9e763a228d66dec97d6edd9504b"/><file name="Lastname.php" hash="4ce733ed97662ae7e3b9bd7fd09a9b23"/><file name="Newsletter.php" hash="e32e2584c4a5b4e83774c90ca8e03d21"/><file name="Register.php" hash="18462dd6abae0d72f6863a285364885a"/><file name="Type.php" hash="49b3fefa77c399003a60edc716a19810"/><file name="Website.php" hash="998fa5822c12e7e10a9363c74922d25f"/></dir><file name="Filter.php" hash="c67e8a70e671dc9c05194d6fea62ba1d"/></dir><dir name="Mysql4"><dir name="Admins"><file name="Collection.php" hash="c1ada270e5c640cc77beca20a90c06c1"/></dir><file name="Admins.php" hash="c1efc07554a47ddd61add948f8d7184d"/><dir name="Answers"><file name="Collection.php" hash="e0d1dfb4666cd442105b786cd8e1938b"/></dir><file name="Answers.php" hash="9b116c0acd6598b22fda9a3f7bfd0e1f"/><file name="Collection.php" hash="0713d799c11bcc14437ca3924d0aae0f"/><dir name="Country"><dir name="Area"><file name="Collection.php" hash="57076e9ef2eaee34ede11fd2b8c079ea"/></dir><file name="Area.php" hash="cb14e562273148090fcafe17a5764dcf"/><file name="Collection.php" hash="9d1c5aa0e9d956d98e45706dd24dc0f0"/><dir name="Lang"><file name="Collection.php" hash="5784492b259d0636c5c37f3f945873cf"/></dir><file name="Lang.php" hash="45c61334ccc799908468603a1601f75f"/></dir><file name="Country.php" hash="dd1e7ba04fb2d2484fcd14d35fd63513"/><dir name="Exceptions"><file name="Collection.php" hash="0f27011bb167d3686149edcea2cf9af0"/></dir><file name="Exceptions.php" hash="087363570c7e19e98343508fde136b71"/><dir name="Hooks"><dir name="Admins"><file name="Collection.php" hash="08c59f372ae4d724d1451836df655deb"/></dir><file name="Admins.php" hash="0b97679a105c98c53fb27e6f35cc49da"/><file name="Collection.php" hash="781323404157c7935539212e6c9d5948"/><dir name="Customers"><file name="Collection.php" hash="9f85b8e63521abcc575d717eaca6f7b0"/></dir><file name="Customers.php" hash="446451f0e038bc5b25ec0d3032a608a9"/><dir name="Templates"><file name="Collection.php" hash="10d674db501bdd93bfc11e0411be53b2"/></dir><file name="Templates.php" hash="b9d88cc611aa7c5ea369d9b4056a3858"/><dir name="Unicode"><file name="Collection.php" hash="e30a9e81400f25829b89d8fa4927e4e7"/></dir><file name="Unicode.php" hash="930b9f23e7b0674cef75898bebd8d4f5"/></dir><file name="Hooks.php" hash="db0d3898325974475d39f0dd786a0c7d"/><dir name="Maps"><file name="Collection.php" hash="2b8609291dc25d2445b1c168024c1783"/></dir><file name="Maps.php" hash="21e7e04096b879db02971223dbf11a1a"/><dir name="Marketing"><dir name="Filter"><file name="Collection.php" hash="ee5bfddfe067a317c94b62eea4e59aeb"/></dir><file name="Filter.php" hash="42342671cb9bcbca71165ffffa7d309d"/></dir><dir name="Ownnumbersender"><file name="Collection.php" hash="0f77ebc089da24e306dc2616178fab35"/></dir><file name="Ownnumbersender.php" hash="0b8963a836de22ff2c54ec8a6f0819bd"/><dir name="Routes"><dir name="Alternative"><file name="Collection.php" hash="dd8908e3c72bef9a4d54ab4d04119fc9"/></dir><file name="Alternative.php" hash="0b07c80a9b35a1dc6f16e310614ddbda"/><file name="Collection.php" hash="9a9f26422877c0ff82f5bc3a6865ed1f"/></dir><file name="Routes.php" hash="f500ad3e8d96b8742a194015acdd4c58"/><dir name="Smshistory"><file name="Collection.php" hash="76f838ee4e14af4789e494badf46ad84"/></dir><file name="Smshistory.php" hash="15edfec649fa894ec310e3e37d97f694"/><dir name="Smsuser"><file name="Collection.php" hash="dad8d028a32e3a860d254c0957f9d23f"/></dir><file name="Smsuser.php" hash="b9913d6c444f646623d6e282f35e8a08"/><dir name="Template"><file name="Collection.php" hash="a9e237b2e23e64e7226a95d3e6e9a7dc"/></dir><file name="Template.php" hash="20a0aad89f43fa6716d96ece9f243000"/><dir name="Textsender"><file name="Collection.php" hash="1574273dc207231460977dce7af007a9"/></dir><file name="Textsender.php" hash="242e7ac5f28b7e7b8521e201fe7cf806"/><dir name="Variables"><file name="Collection.php" hash="0c249b390280ba16db97d3acd320fedb"/></dir><file name="Variables.php" hash="e364920ad4d1a69f33ec037184f27de7"/></dir><file name="Observer.php" hash="49e655453ae47a6420161997cf2c0f80"/><dir name="Overide"><dir name="Cataloginventory"><file name="Stock.php" hash="76e53307192e54dc08b0983288acdda3"/></dir></dir><file name="Ownnumbersender.php" hash="c209b3a3756491c3d9f30c1a9055361b"/><dir name="Routes"><file name="Alternative.php" hash="c52374301eb8e0726dc54e8b08b24a8d"/></dir><file name="Routes.php" hash="917bf19f5983ccafa6e61cd9cc1d8f13"/><file name="Sms.php" hash="3c11dd8eb01bb93eacce91a54c37682a"/><file name="Smshistory.php" hash="b96ef0d1f609d28159c5a03777c953ce"/><file name="Smsprofile.php" hash="4ff023aa338c1eab827448e2c0712852"/><file name="Smsuser.php" hash="1f4906fe7a288e95de706b1343f5b985"/><dir name="System"><dir name="Config"><file name="Lang.php" hash="7bb45d97a8c3f4b4a32bf1229f5cab8b"/></dir></dir><file name="Template.php" hash="8590ec1c798028e5025bf866629bf719"/><file name="Textsender.php" hash="589c0a2087ba27d6e5310796b60e6a48"/><file name="Variables.php" hash="12844fb6fc0c4258cdcbb8d6b5343fc9"/></dir><file name="api_test1.php" hash="8a71c6b1d085ee65b3bde60c20379c9d"/><file name="api_test2.php" hash="6c1d19f8fc1e8a71a1f3129541939262"/><file name="api_test3.php" hash="9c162033d327a93bc974aa20804c161d"/><dir name="controllers"><dir name="Adminhtml"><dir name="Magesms"><file name="AboutController.php" hash="28de3dfca6c6a9ff46228ae4833ea10b"/><file name="AdminsmsController.php" hash="3de78bd855405893f2ad460c33f7d737"/><file name="AnswersController.php" hash="ca05a9506f32a90ff359f01f90ff7031"/><file name="CustomersmsController.php" hash="56ad4a9bfecc66ca15ea6c58effd97a9"/><file name="HistoryController.php" hash="ca2a53f872a87ce16bbacfb1bcbb376b"/><file name="MarketingController.php" hash="754ac431dd48cb4b25ee1ade24d31e1f"/><file name="OptoutController.php" hash="4e72b192749f1fabf527194712094414"/><file name="ProfileController.php" hash="511e53d9ed0df629c2fbc213b3ef5c9d"/><file name="PurchasecreditController.php" hash="377c26a55d5fc6e0ebfa281298747a00"/><file name="SendsmsController.php" hash="aa163c55589f55bc03e97a6d1ad78b71"/><file name="StatisticsController.php" hash="65b69a09bf45b80291a15c87ebb6ad04"/><file name="WizardController.php" hash="fadcde5fbdf51869a917b8bc20596530"/></dir></dir><file name="ApiController.php" hash="9756da9bfb339b1ddbab7883b7e362b1"/><file name="DeliveryController.php" hash="8f604254b6c19c9adb84bea325e3c8ea"/><file name="IndexController.php" hash="aa69e6f90f6e822941f382b1162c75d6"/></dir><dir name="data"><dir name="magesms_setup"><file name="data-install-1.0.0.php" hash="5df79e7e9193abbac12191f35c4d45a9"/><file name="data-upgrade-1.0.1-1.0.2.php" hash="290c4939bebfd6a0529dc7da20534bf5"/><file name="data-upgrade-1.0.3-1.0.4.php" hash="a60b7ce260a43d71c3afcb62e4f875e2"/><file name="data-upgrade-1.1.0-1.1.1.php" hash="c464142a975b03b81a49ba41284e1b96"/><file name="data-upgrade-1.1.1-1.1.2.php" hash="28fc124ce1e29130056ed059e5c824f0"/><file name="data-upgrade-1.2.0-1.2.1.php" hash="119a68ac6e6238bfa07c1b5cc90045d0"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="637551698f955e9428774cc64e91ccb9"/><file name="config.xml" hash="59dbfede37977303f7b980219fa0a879"/><file name="system.xml" hash="8c35619b72895b190b8a5aea21c6b934"/></dir><dir name="sql"><dir name="magesms_setup"><file name="mysql4-install-0.9.0.php" hash="b3d8975e98cb1cfe12194d7a18bbfc2f"/><file name="mysql4-install-1.0.0.php" hash="d7363753089c833e275847a9137b6c89"/><file name="mysql4-upgrade-0.9.11-0.9.12.php" hash="765533b9d6f9fa987949c0a5f73ff37d"/><file name="mysql4-upgrade-0.9.12-0.9.13.php" hash="0d3ea4875bd51593c8113805402e58fd"/><file name="mysql4-upgrade-1.0.1-1.0.2.php" hash="02b2fecd79ace03940cd7c50419c8878"/><file name="mysql4-upgrade-1.1.3-1.1.4.php" hash="d0b532bf1d394fbd27c577bd9de27564"/><file name="mysql4-upgrade-1.1.5-1.2.0.php" hash="1f32fbc9aacc4e0139fd91b35589d591"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="topefekt"><dir name="magesms"><file name="about.phtml" hash="915f3356c5819a3d7373865f665d626f"/><file name="adminsms.phtml" hash="8cd430b34c539174e2820b3c99508c9b"/><file name="customersms.phtml" hash="0214ac60ff33b1d690a3996e9d7166c5"/><file name="history.phtml" hash="27325466405ae1a33f93978434b4ad11"/><dir name="marketing"><file name="customer.phtml" hash="5d56650f36d41535808dbcc9f0670e35"/><file name="form.phtml" hash="37a354655ae727480d779c6775d227f2"/></dir><file name="marketing.phtml" hash="630defb84f73d76435b67d05b4e4691e"/><file name="optout.phtml" hash="78891f09375e29485e58b68623a1ebb2"/><file name="profile.phtml" hash="7aa0f7b562bb8a6e4c4fc07f7058d144"/><file name="purchasecredit.phtml" hash="0ec35354e68a85b0fff078f9a8b14d96"/><file name="sendsms.phtml" hash="3a2f21302e2b246d149998bfdfea95d9"/><file name="statistics.phtml" hash="dd708338a0a5ad36bb10141ad394ea22"/><dir name="template"><file name="form.phtml" hash="e6a006574345ef9e85e28251310d96ec"/></dir><file name="wizard-alternative.phtml" hash="53128ea65c7eb6ea80faac040c0d63f2"/><file name="wizard-edit.phtml" hash="e247901a92b290fcb85128b4a08ee91d"/><file name="wizard-list.phtml" hash="cee281d28e0b61f93c0acb90f064c922"/><file name="wizard-sender.phtml" hash="3ff2f15bf3e6db24f2e771f7aa2a500b"/><file name="wizard.phtml" hash="d0a70bb920e76604959c48de8fe57c84"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Topefekt_Magesms.xml" hash="d88282bf3409717dcc6c8d36102480a3"/></dir></target><target name="magelocale"><dir><dir name="cs_CZ"><file name="Topefekt_Magesms.csv" hash="01ffb74e44c2d2374fe9ef4768888e13"/></dir><dir name="de_DE"><file name="Topefekt_Magesms.csv" hash="2e7287b30954b3126169403822669f2a"/></dir><dir name="el_GR"><file name="Topefekt_Magesms.csv" hash="b4d8c7090d22aa1ae994ea2f13b27593"/></dir><dir name="en_US"><file name="Topefekt_Magesms.csv" hash="2aeade9ce5193f08d1b19959631764d0"/></dir><dir name="es_ES"><file name="Topefekt_Magesms.csv" hash="66aae8475301ad574cdecec4511aab80"/></dir><dir name="fr_FR"><file name="Topefekt_Magesms.csv" hash="b9f82cdd6f0779e8b13dee31e7bd8974"/></dir><dir name="it_IT"><file name="Topefekt_Magesms.csv" hash="aa2a250c18b47bf5ccad1787e2dbebda"/></dir><dir name="pl_PL"><file name="Topefekt_Magesms.csv" hash="622944ce311c1ffb5e9e8fb6c4c447cc"/></dir><dir name="pt_PT"><file name="Topefekt_Magesms.csv" hash="d7b14419f2ee4469bcf023729b523e3d"/></dir><dir name="ru_RU"><file name="Topefekt_Magesms.csv" hash="c92302b7f783678c0903695a6a47fcee"/></dir><dir name="sk_SK"><file name="Topefekt_Magesms.csv" hash="5662bb27898880cfceb182daa346869e"/></dir><dir name="sr_RS"><file name="Topefekt_Magesms.csv" hash="17761427d3db52adb3d55bc68c7fece9"/></dir><dir name="tr_TR"><file name="Topefekt_Magesms.csv" hash="c64505ca859e2004090fd2729ffe7b65"/></dir></dir></target><target name="magemedia"><dir name="magesms"><file name="About.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminCatalog.gif" hash="2500d6277ec65b73cec8e858e8f3e5ef"/><file name="AdminCustomers.gif" hash="2575dfefce12bc9451e4dfa1e0972a1e"/><file name="AdminEmployees.gif" hash="cdb742ba271aae8e0f5129e9422d8480"/><file name="AdminOrders.gif" hash="b0b296f24674d37c3749a4c68e014173"/><file name="AdminSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminSmsProfile.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="AdminTools.gif" hash="a3d566311d5cdd11470e60a30c4f1a1d"/><file name="CustomerSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="Empty.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="PayPal123.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SendSms.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsAnswers.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsCharging.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsHistory.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsMarketing.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="SmsWizard.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="calendar.jpg" hash="ec1c2dde2879bca23fb232bdfb6459b1"/><file name="delete.gif" hash="b658193cc19b4be4776fbca433c86354"/><file name="edit.gif" hash="100198930f65efde449cce2d4fd3dd49"/><file name="i_accepted.gif" hash="befd5320058efee73744cb53f1ac58a6"/><file name="i_buffered.png" hash="df919a54ebb68a101899da77671a7ae4"/><file name="i_canceled.gif" hash="f54cd085dc4a709a590650df64c9307a"/><file name="i_deleted.png" hash="2cac2bf05b4f0bfc7f0b24ad3274c8aa"/><file name="i_donotdisturb.png" hash="cc15ea466d59c68c2278f9eac825fac9"/><file name="i_duplicate.png" hash="9a12c256c640bae544204d17933a8e0b"/><file name="i_error.gif" hash="45f02b921ce504353050a3921c6a6b70"/><file name="i_minus.gif" hash="16e4ff79084066203148d261b4d14712"/><file name="i_plus.gif" hash="1cc64296ccbf2bd9dfd61a0ce6a7f117"/><file name="i_scheduled.png" hash="b644f202e2a2cf0fccf073dfdc8befb1"/><file name="i_sent.png" hash="938d41c783cc770339e1febbe2fe538e"/><file name="i_simulation.png" hash="6b6f65f4c1ca5e9017c978274a186091"/><file name="licence_cz.pdf" hash="c61b5f052326b3cb74dd3346911c41bb"/><file name="licence_en.pdf" hash="5a96ef0dcb08cee786ef574c16608365"/><file name="logo.gif" hash="a5e975f6b52cd9dbf20fed18216d1536"/><file name="logocart.png" hash="cb095b552c60e3c23ac449a453981e6c"/><file name="magesms-logo.png" hash="5352d2cb3b95990a1eb237f0d48ed811"/><file name="next.gif" hash="d4a145a07fa436e51cbaa4a28c14b622"/><file name="prev.gif" hash="d1dab45da5f0690fcaac4ce62f6bd04d"/><file name="sms.png" hash="5473a773314938564ad2f8fb826445bd"/><file name="topefekt-logo.gif" hash="149c7fd9bb2a4f70637963b0036e5a07"/><file name="translation.gif" hash="d2f85c78ea940b1a62919e50175a4c4f"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="base"><dir name="default"><dir name="css"><dir name="topefekt"><dir name="magesms"><dir name="img"><file name="i_canceled.gif" hash="f54cd085dc4a709a590650df64c9307a"/><file name="i_sent.png" hash="938d41c783cc770339e1febbe2fe538e"/></dir><file name="stylesheet.css" hash="24cf22aaf8499776fda44f33ad245799"/></dir></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="topefekt"><file name="functions.js" hash="bd4bde8c632a3d5eb8d7c21278189875"/><file name="template.js" hash="26a2428302a7306fd49b940529147042"/></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>
|