Skip to content

Latest commit

 

History

History
23 lines (19 loc) · 793 Bytes

bootstrap.md

File metadata and controls

23 lines (19 loc) · 793 Bytes

Character

Bootstrap Data

Bootstrapped data configuration example with disabled item updates and pagination:

postsConfig = (data) ->
  itemTitleField:     'title'
  disableUpdateItems: true
  objects:            data.posts
  arrayStore: new RailsArrayStore({
    resource:    'post'
    path:        '/admin/posts'
    sortBy:      'title'
    pagination:  false
  })
  formSchema:
    title: { type: 'string' }
    body:  { type: 'text'   }

disableUpdateItems — do not update items in the list while navigation, objects — provides initial (bootstrapped) array of objects to be added to the list, pagination — disable pagination for list. If attached as modules root list, you can access store data with: chr.modules.posts.arrayStore.data().