Method: Contentstack::Entry#fetch
- Defined in:
- lib/contentstack/entry.rb
#fetch ⇒ Contentstack::EntryCollection
Execute entry
Example
@entry = @stack.content_type('product').entry(entry_uid)
@entry.fetch
172 173 174 175 176 177 178 |
# File 'lib/contentstack/entry.rb', line 172 def fetch entry = API.fetch_entry(@content_type, self.fields[:uid], @query) setup(entry["entry"]) @schema = entry["schema"].symbolize_keys if entry["schema"] @content_type = entry["content_type"].symbolize_keys if entry["content_type"] self end |