Magentoサイト(Magento 1.8.1.0)を古いサーバーから新しいサーバーに移行しました。統合の問題を解決する方法サイト移行後にPOSシステムを搭載したMagentoストア?
しかし、Winepos統合拡張機能を使用することはできません。
私たちのサイトはWinepos systemに接続されています。このMagento拡張機能は、移行作業の前に操作されています。
これはWinepos API manualです。
現時点では、一部のPHPモジュールが新しいサーバーにインストールされていないと思われます。
しかし、インストールされていないPHPモジュールはわかりません。すべてのPHPモジュールが新しいサーバーにインストールされたようです。
Wineposと統合するMagento拡張は次のとおりです。この拡張は2つのファイルで構成されています。
のConfig.xml
<config>
<global>
<events>
<checkout_onepage_controller_success_action>
<observers>
<igor_winepos_order_success_observer>
<type>singleton</type>
<class>igor_Winepos_Model_Wineposobserver</class>
<method>checkoutSuccessObserve</method>
</igor_winepos_order_success_observer>
</observers>
</checkout_onepage_controller_success_action>
</events>
</global>
</config>
wineposobserver.php
class igor_Winepos_Model_Wineposobserver extends Varien_Event_Observer {
function customlog($obj) {
ob_start();
var_dump($obj);
$out1 = ob_get_contents();
ob_end_clean();
$f = fopen('/tmp/log.txt', 'ab');
fwrite($f, $out1);
fclose($f);
}
public function __construct() {
}
public function checkoutSuccessObserve($observer) {
// $event = $observer->getEvent();
$order_ids = $observer->getData('order_ids');
if(gettype($order_ids) == 'array' && count($order_ids) == 1) {
$the_order = Mage::getModel('sales/order')->load($order_ids[0]);
Mage::helper('globalfunc')->registerOrderWithWinePOSAsynchronousWithTimeout($the_order);
}
}
}
私はApacheのログに次のようになっています:
PHPの警告:PHPのスタートアップ:apc.shm_segmentsを設定MMAPモードでUnknown 0行目で無視[Sun Apr 30 06:32:30 2017] [注意] Apache/2.2.22(Ubuntu)mod_ssl/2.2.22 OpenSSL/1.0.1 confi gured - 私はPOSシステムと統合するための新しいモジュールを作成し、正常に在庫の同期を実現し、通常の操作
285: function registerOrderWithWinePOSAsynchronousWithTimeout($the_order) {
286 try {
287 $items = $the_order->getAllItems();
...
426 $ordered_raw_item = $ordered_products_raw_items[$ordered_product_id];
428: $product_winepos_id = trim(strval($product->getResource()->getAttribute('winepos_id')->getFrontend()->getValue($product)));
429
430 $item_element = $doc->createElement('item');
432 $item_num_element = $doc->createElement('item-num');
433: $item_num_element->appendChild($doc->createTextNode(strval($product_winepos_id)));
434 $item_element->appendChild($item_num_element);
...
466 $the_xml = $doc->saveXML();
468: // $post_result = Mage::helper('globalfunc')->post_to_api_winepos('https://wines-in-november.vznlink.com/orders', $the_xml, 'admin276975', '8dc670fb943dc2c0a1415405cdf00e3ec579c4e6', 8, 10);
470: return Mage::helper('globalfunc')->delayed_post_to_winepos($the_xml);
471 } catch(Exception $e) {
472 $this->customlog($e);
...
475 }
PHP/Apacheのエラーログを見て、そこに役立つヒントがあるかどうかを確認してください。 – halfer
それはあまりにも深刻に見えません、それは単なる警告です。 Wineposに独自の拡張機能がインストールされている場合は、これをサーバーにインストールするだけですか?私はまだあなたが経験している問題がどんなものなのか、それほど確信が持てません。たとえば、操作の画面上のエラーが出ていますか? – halfer
残念ながら、wineposはMagentoとMagentoを統合するためにMagento拡張を提供することはできません。しかし、サポートチームに尋ねたところ、彼らはAPIマニュアルを提供しました。 https://api.vznlink.com/help現時点で、顧客がオフライン店を通じて当社のサイトで製品を購入すると、wineposは当社のMagentoサイトで商品の在庫を減らすように製品インベントリを管理する必要があります。しかし、wineposは私たちのマゼンタサイトを制御しません。真実を伝えるために、ソースコード全体は変更されていません。唯一の変更はサーバー設定です。ハッカーの攻撃のため、新しいサーバーに移行しました。 –