From d04f071ae031b41ef4c102a9bd9003e8a439a38b Mon Sep 17 00:00:00 2001 From: Boris Date: Sun, 28 Mar 2021 13:11:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=94=99=E5=88=AB=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/command/cmdline.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/command/cmdline.md b/docs/command/cmdline.md index eb85e012..d324521e 100644 --- a/docs/command/cmdline.md +++ b/docs/command/cmdline.md @@ -86,7 +86,7 @@ ### 2. 创建爬虫 -爬虫分为3中,分别为 轻量级爬虫(AirSpider)、分布式爬虫(Spider)以及 批次爬虫 (BatchSpider) +爬虫分为3种,分别为 轻量级爬虫(AirSpider)、分布式爬虫(Spider)以及 批次爬虫(BatchSpider) 命令 @@ -154,18 +154,18 @@ item为与数据库表的映射,与数据入库的逻辑相关。 ``` from feapder import Item - - + + class SpiderDataItem(Item): """ This class was generated by feapder. command: feapder create -i spider_data. """ - + def __init__(self, *args, **kwargs): # self.id = None self.title = None - + ``` 若字段有默认值或者自增,则默认注释掉,可按序打开 @@ -191,7 +191,7 @@ class SpiderDataItem(Item): **若item字段过多,不想逐一赋值,可通过如下方式创建** feapder create -i spider_data 1 - + 生成: ```