[Git][noosfero/noosfero][master] 2 commits: api: expose block definition

Leandro Nunes gitlab at mg.gitlab.com
Thu May 11 11:30:30 BRT 2017


Leandro Nunes pushed to branch master at Noosfero / noosfero


Commits:
c87da627 by Victor Costa at 2017-05-09T13:50:36-03:00
api: expose block definition

- - - - -
c4725ff2 by Leandro Nunes at 2017-05-11T14:30:23+00:00
Merge branch 'block-definition-api' into 'master'

api: expose block definition

See merge request !1208
- - - - -


1 changed file:

- app/api/entities.rb


Changes:

=====================================
app/api/entities.rb
=====================================
--- a/app/api/entities.rb
+++ b/app/api/entities.rb
@@ -104,6 +104,9 @@ module Api
         Entities.permissions_for_entity(block, options[:current_person], :allow_edit?)
       end
       expose :images, :using => Image
+      expose :definition do |block, options|
+        BlockDefinition.represent(block.class)
+      end
     end
 
     class Box < Entity



View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/f29956d572c9ce75578129c9a733971732435570...c4725ff26e9f971c1ba06c600201a9c6d2f4bdb8

---
View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/f29956d572c9ce75578129c9a733971732435570...c4725ff26e9f971c1ba06c600201a9c6d2f4bdb8
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20170511/eb3337ca/attachment.html>


More information about the Noosfero-dev mailing list