سؤال

أحاول إجراء ترحيل Magento 2 على جهازي المحلي، وذلك في الغالب حتى يكون لدي بيانات حقيقية للعمل معها أثناء تعلم Magento 2 (دقة الترحيل ليست مهمة).

عندما أقوم بتشغيل أداة الترحيل، أحصل على هذا الخطأ (الأخطاء):

[ERROR]: Incorrect value: Freightquote_Shipping_Model_Carrier_Source_Class in: eav_attribute.source_model for attribute_code=freightquote_class
[ERROR]: Incorrect value: Freightquote_Shipping_Model_Carrier_Source_Packaging in: eav_attribute.source_model for attribute_code=freightquote_packaging
[ERROR]: Incorrect value: Freightquote_Shipping_Model_Carrier_Source_Commodity in: eav_attribute.source_model for attribute_code=freightquote_commodity
[ERROR]: Incorrect value: Freightquote_Shipping_Model_Carrier_Source_Content in: eav_attribute.source_model for attribute_code=freightquote_content

وتنتهي ب

[Migration\Exception]
Volume Check Failed

في eav_attribute الجدول المصدر (مختصر):

attribute_code           | backend_type | frontend_input | source_model
-----------------------------------------------------------------------------------------------------------------
freightquote_class       | varchar      | select         | Freightquote_Shipping_Model_Carrier_Source_Class
freightquote_packaging   | varchar      | select         | Freightquote_Shipping_Model_Carrier_Source_Packaging
freightquote_commodity   | varchar      | select         | Freightquote_Shipping_Model_Carrier_Source_Commodity
freightquote_content     | varchar      | select         | Freightquote_Shipping_Model_Carrier_Source_Content

لا بأس في استبعاد هذه الوحدة من الترحيل إذا كان ذلك ممكنًا/ضروريًا.لقد حاولت البحث في ملفات config.xml وmap.xml المختلفة للحصول على أمثلة حول كيفية التعامل مع هذا الأمر، ولكن لم أتمكن من فهمه حقًا.

هل كانت مفيدة؟

المحلول 2

أدركت أن البيانات الموجودة في eav_attribute الجدول بحاجة للتعديليلزم تغيير نماذج مصدر أسعار الشحن لتكون بالتنسيق المتوقع.

لذا Freightquote_Shipping_Model_Carrier_Source_Class يصبح freightquote_shipping/carrier_source_class.تم إجراء ذلك لكل صف من الصفوف مما تسبب في حدوث خطأ وأعاد تشغيل الاستيراد.هذا أصلح الخطأ.

نصائح أخرى

كان لدي نفس المشكلة وسألت على جيثب https://github.com/magento/data-migration-tool-ce/issues/13.

يمكنك محاولة إضافة الأسطر التالية إلى ملفك المورد/magento/data-migration-tool/etc/ce-to-ce/class-map.xml.dist:

<rename>
    <from>freightquote_shipping/carrier_source_class</from>
    <to />
</rename>
<rename>
    <from>freightquote_shipping/carrier_source_packaging</from>
    <to />
</rename>
<name>
    <from>freightquote_shipping/carrier_source_commodity</from>
    <to />
</rename>
<rename>
    <from>freightquote_shipping/carrier_source_content</from>
    <to />
</rename>
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى magento.stackexchange
scroll top