open_taobao 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +2 -2
- data/lib/open_taobao/version.rb +1 -1
- data/spec/open_taobao_spec.rb +2 -2
- metadata +1 -1
data/README.md
CHANGED
@@ -20,7 +20,7 @@ Run generate to complete install:
|
|
20
20
|
|
21
21
|
$ rails g open_taobao:install
|
22
22
|
|
23
|
-
|
23
|
+
在你的`Rails`项目的`config`目录下会生成一个`taobao.yml`文件,
|
24
24
|
打开taobao.yml文件,设置你自己的`app_key`, `secret_key`, 淘宝客的`pid`
|
25
25
|
|
26
26
|
## Usage
|
@@ -33,7 +33,7 @@ this will create taobao.yml in your config/ directory.
|
|
33
33
|
:parent_cid => 0
|
34
34
|
)
|
35
35
|
|
36
|
-
|
36
|
+
返回内容将自动转化为hash格式。
|
37
37
|
|
38
38
|
## Contributing
|
39
39
|
|
data/lib/open_taobao/version.rb
CHANGED
data/spec/open_taobao_spec.rb
CHANGED
@@ -108,14 +108,14 @@ describe OpenTaobao do
|
|
108
108
|
|
109
109
|
it "should parse result data" do
|
110
110
|
data = '
|
111
|
-
"item_get_response": {
|
111
|
+
{"item_get_response": {
|
112
112
|
"item": {
|
113
113
|
"item_imgs": {
|
114
114
|
"item_img": [
|
115
115
|
]
|
116
116
|
}
|
117
117
|
}
|
118
|
-
}
|
118
|
+
}}
|
119
119
|
'
|
120
120
|
|
121
121
|
OpenTaobao.parse_result(data).should == {
|