简体   繁体   English

PrestaShop导入模块

[英]PrestaShop import module

I am looking for some documentation or actually any info for creating PrestaShop back office modules (importing XML file containing list of products to database/importing CSV that was converted from that custom XML/any other way to get those products out there). 我正在寻找用于创建PrestaShop后台模块的一些文档或实际上任何信息(将包含产品列表的XML文件导入数据库/从该自定义XML转换的CSV导入CSV /以其他任何方式将这些产品运出那里)。

http://doc.prestashop.com/display/PS16/User+Guide <- are the only docs I found for PrestaShop. http://doc.prestashop.com/display/PS16/User+Guide <-是我为PrestaShop找到的唯一文档。 And... to be honest: how am I to know what classes they have? 还有...说实话:我怎么知道他们上什么课? What methods they offer and what they return/take as parameters? 它们提供什么方法​​以及它们返回/作为参数的内容?

I feel like I am missing something like: Wordpress Codex or Meteor API Docs. 我觉得我缺少诸如:Wordpress Codex或Meteor API Docs之类的东西。

This is what I think is necessary: 我认为这是必要的:

  1. Create new back office module. 创建新的后台模块。
  2. Create a view in the back office with the option to select a file from user's PC and some settings like product tag name, it's property names and so on (no data on that in the "docs" I found information only on SE/SO). 在后台创建一个视图,并带有从用户PC中选择文件的选项以及一些设置(例如产品标签名称,属性名称等)的选项(“ docs”中没有任何数据,我只能在SE / SO上找到信息) 。
  3. Use PHP's XMLReader (loading whole files is not an option I think) to parse XML and insert into database every time it recognizes a node with appropriate options. 使用PHP的XMLReader(我认为不加载整个文件是一种选择)来解析XML,并在每次识别带有适当选项的节点时将其插入数据库。 (Some knowledge about products and categories would be nice, I have found none). (有关产品和类别的一些知识会很好,但我没有发现)。
  4. ...profit? ...利润?

It all sounds so easy when you look at it like that but I just don't know where to start with Presta. 当您这样看时,听起来一切都很容易,但我只是不知道从Presta开始。

first try to create a basic module, prestashop is providing an online tool for creating module please look at the tool and create one. 首先尝试创建一个基本模块,prestashop提供了一个在线工具来创建模块,请查看该工具并创建一个。 The generated module have a basic config page, you can modify this and do as you want 生成的模块具有一个基本的配置页面,您可以对其进行修改并根据需要进行操作

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM