Skip to content

Instantly share code, notes, and snippets.

@jamesplease
Last active February 19, 2017 06:58
Show Gist options
  • Save jamesplease/d8e58ed2fb50cb17803d84eeb5b28c61 to your computer and use it in GitHub Desktop.
Save jamesplease/d8e58ed2fb50cb17803d84eeb5b28c61 to your computer and use it in GitHub Desktop.
"New" was generated from a SQL table. "original" is the Model used to generate the table.
{ name: 'transaction',
plural_form: 'transactions',
attributes:
{ description: { type: 'VARCHAR(30)', nullable: true },
value: { type: 'NUMERIC(9,2)', nullable: false },
date: { type: 'DATE', nullable: true } },
meta: { copyright: { type: 'VARCHAR(30)', nullable: true } },
relationships: {},
actions:
{ create: true,
read_one: false,
read_many: true,
update: true,
delete: false },
pagination: { enabled: false, default_page_size: 10, default_page_number: 1 },
built_in_meta: { updated_at: true, created_at: true } }
{ name: 'transaction',
actions:
{ create: true,
read_one: false,
read_many: true,
update: true,
delete: false },
pagination: false,
attributes:
{ description: 'VARCHAR(30)',
value: { type: 'NUMERIC(9, 2)', nullable: false },
date: 'DATE' },
meta: { copyright: 'VARCHAR(30)' },
built_in_meta: { created_at: true, updated_at: true } }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment