Commit f7d9d2fb0a49cb5675adc5b44e71e34e960d912a

Authored by Victor Costa
Committed by Rodrigo Souto
1 parent 830e902c

api: pass fields param in article post actions

Showing 1 changed file with 4 additions and 4 deletions   Show diff stats
lib/noosfero/api/v1/articles.rb
@@ -62,7 +62,7 @@ module Noosfero @@ -62,7 +62,7 @@ module Noosfero
62 if !article.save 62 if !article.save
63 render_api_errors!(article.errors.full_messages) 63 render_api_errors!(article.errors.full_messages)
64 end 64 end
65 - present article, :with => Entities::Article 65 + present article, :with => Entities::Article, :fields => params[:fields]
66 end 66 end
67 67
68 68
@@ -101,7 +101,7 @@ module Noosfero @@ -101,7 +101,7 @@ module Noosfero
101 if !article.save 101 if !article.save
102 render_api_errors!(article.errors.full_messages) 102 render_api_errors!(article.errors.full_messages)
103 end 103 end
104 - present article, :with => Entities::Article 104 + present article, :with => Entities::Article, :fields => params[:fields]
105 end 105 end
106 106
107 end 107 end
@@ -140,7 +140,7 @@ module Noosfero @@ -140,7 +140,7 @@ module Noosfero
140 if !article.save 140 if !article.save
141 render_api_errors!(article.errors.full_messages) 141 render_api_errors!(article.errors.full_messages)
142 end 142 end
143 - present article, :with => Entities::Article 143 + present article, :with => Entities::Article, :fields => params[:fields]
144 end 144 end
145 145
146 end 146 end
@@ -179,7 +179,7 @@ module Noosfero @@ -179,7 +179,7 @@ module Noosfero
179 if !article.save 179 if !article.save
180 render_api_errors!(article.errors.full_messages) 180 render_api_errors!(article.errors.full_messages)
181 end 181 end
182 - present article, :with => Entities::Article 182 + present article, :with => Entities::Article, :fields => params[:fields]
183 end 183 end
184 184
185 end 185 end