定制 bencurio/magento2-module-catalog-import-cli 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

bencurio/magento2-module-catalog-import-cli

最新稳定版本:0.0.3

Composer 安装命令:

composer require bencurio/magento2-module-catalog-import-cli

包简介

Import catalog via console command

README 文档

README

A console command for importing catalog files.

Install

$ composer require bencurio/magento2-module-catalog-import-cli
$ php bin/magento module:enable Bencurio_CatalogImportCommand
$ php bin/magento setup:upgrade
$ php bin/magento setup:di:compile
$ php bin/magento cache:clean

Usage

$ bin/magento catalog:import \
    [-i|--images_path[="..."]] \
    [-p|--entity_type[="advanced_pricing|catalog_product|customer_composite|customer|customer_address|stock_sources"]] \
    [-b|--behavior[="append|add_update|replace|delete"]] \
    [-v|--validation_strategy[="validation-stop-on-errors|validation-skip-errors"]] \
    [-c|--allowed_errors_count[=100]]
    [-s|--field_separator[=","]]] \
    [-m|--multiple_value_separator[=","]]] \
    [-e|--empty_attribute_value_constant[="..."]] \
    [-f|--fields_enclosure] \
csv_file
  • --images_path: (default var/import/images) must be a relative path starting from your Magento 2.x project root
  • --entity_type: (default catalog_product) possible values: advanced_pricing, catalog_product, customer_composite, customer, customer_address, stock_sources
  • --behavior: (default add_update) possible values: append, add_update, replace, delete
  • --validation_strategy: (default validation-skip-errors) possible values: validation-stop-on-errors, validation-skip-errors
  • --allowed_errors_count: (default 10) specify number of errors to halt import process
  • --field_separator: (default ,)
  • --multiple_value_separator: (default ,)
  • --empty_attribute_value_constant: (default __EMPTY__VALUE__)
  • --fields_enclosure: (default false) use fields enclosure
  • csv_file: could be a relative or an absolute path to a valid CSV file

Example

$ bin/magento catalog:import --images_path="." --behavior="add_update" --fields_enclosure mydb.csv

统计信息

  • 总下载量: 10
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 19
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2023-03-23