/[drupal]/contributions/modules/magento/magento_api/magento_api.xmlrpc.inc
ViewVC logotype

Diff of /contributions/modules/magento/magento_api/magento_api.xmlrpc.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1 by mtopolov, Mon May 25 10:30:48 2009 UTC revision 1.2 by mtopolov, Tue Nov 10 10:48:39 2009 UTC
# Line 73  function magento_api_productSaveEventHan Line 73  function magento_api_productSaveEventHan
73                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productSaveEventHandler', '%event' => 'catalog_product_save', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productSaveEventHandler', '%event' => 'catalog_product_save', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);
74                  module_invoke_all('magento_event', 'catalog_product_save', $productId);                  module_invoke_all('magento_event', 'catalog_product_save', $productId);
75          }          }
76          catch (Ecxeption $ex)          catch (Exception $ex)
77          {          {
78                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
79          }          }
# Line 91  function magento_api_productDeleteEventH Line 91  function magento_api_productDeleteEventH
91                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productDeleteEventHandler', '%event' => 'catalog_product_delete', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productDeleteEventHandler', '%event' => 'catalog_product_delete', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);
92                  module_invoke_all('magento_event', 'catalog_product_delete', $productId);                  module_invoke_all('magento_event', 'catalog_product_delete', $productId);
93          }          }
94          catch (Ecxeption $ex)          catch (Exception $ex)
95          {          {
96                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
97          }          }
# Line 109  function magento_api_productStatusUpdate Line 109  function magento_api_productStatusUpdate
109                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productStatusUpdateEventHandler', '%event' => 'product_status_update', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_productStatusUpdateEventHandler', '%event' => 'product_status_update', '%args' => serialize(array($productId))), WATCHDOG_NOTICE, $link = NULL);
110                  module_invoke_all('magento_event', 'product_status_update', $productId);                  module_invoke_all('magento_event', 'product_status_update', $productId);
111          }          }
112          catch (Ecxeption $ex)          catch (Exception $ex)
113          {          {
114                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
115          }          }
# Line 127  function magento_api_catalogCategorySave Line 127  function magento_api_catalogCategorySave
127                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_catalogCategorySaveEventHandler', '%event' => 'catalog_category_save', '%args' => serialize(array($tree))), WATCHDOG_NOTICE, $link = NULL);                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_catalogCategorySaveEventHandler', '%event' => 'catalog_category_save', '%args' => serialize(array($tree))), WATCHDOG_NOTICE, $link = NULL);
128                  module_invoke_all('magento_event', 'catalog_category_save', $tree);                  module_invoke_all('magento_event', 'catalog_category_save', $tree);
129          }          }
130          catch (Ecxeption $ex)          catch (Exception $ex)
131          {          {
132                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
133          }          }
# Line 145  function magento_api_catalogCategoryDele Line 145  function magento_api_catalogCategoryDele
145                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_catalogCategoryDeleteEventHandler', '%event' => 'catalog_category_delete', '%args' => serialize(array($tree))), WATCHDOG_NOTICE, $link = NULL);                  if (variable_get('magento_api_log', 0)) watchdog('magento_api', 'Drupal function = %drupal_function, Magento event = %event, Arguments = %args', array('%drupal_function' => 'magento_api_catalogCategoryDeleteEventHandler', '%event' => 'catalog_category_delete', '%args' => serialize(array($tree))), WATCHDOG_NOTICE, $link = NULL);
146                  module_invoke_all('magento_event', 'catalog_category_delete', $tree);                  module_invoke_all('magento_event', 'catalog_category_delete', $tree);
147          }          }
148          catch (Ecxeption $ex)          catch (Exception $ex)
149          {          {
150                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
151          }          }
# Line 163  function magento_api_catalogRuleApplyAft Line 163  function magento_api_catalogRuleApplyAft
163                           array('%drupal_function' => 'magento_api_catalogRuleApplyAfterEventHandler', '%event' => 'catalog_rule_apply', '%args' => serialize(array(NULL))), WATCHDOG_NOTICE, $link = NULL);                           array('%drupal_function' => 'magento_api_catalogRuleApplyAfterEventHandler', '%event' => 'catalog_rule_apply', '%args' => serialize(array(NULL))), WATCHDOG_NOTICE, $link = NULL);
164                  module_invoke_all('magento_event', 'catalog_rule_apply', NULL);                  module_invoke_all('magento_event', 'catalog_rule_apply', NULL);
165          }          }
166          catch (Ecxeption $ex)          catch (Exception $ex)
167          {          {
168                  return services_error(t('Drupal event handler error: ').$ex->getMessage());                  return services_error(t('Drupal event handler error: ').$ex->getMessage());
169          }          }

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.3