diff options
| author | Sean Fridman <fridman@mail.sfsu.edu> | 2015-04-07 23:05:44 -0400 |
|---|---|---|
| committer | Sean Fridman <fridman@mail.sfsu.edu> | 2015-04-07 23:05:44 -0400 |
| commit | 68fc2c92fad18c1685f5d67048d3147bb38d55c7 (patch) | |
| tree | 7418995f1ff084b9a92349547ae4f2e9a9ae3c13 /examples | |
| parent | 007384de007844e865bf906b8cb6eadaed4027e6 (diff) | |
ID fields for resources now determined by app config
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/index.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/examples/index.js b/examples/index.js index 7e0c6f9..c4fd3be 100644 --- a/examples/index.js +++ b/examples/index.js @@ -2,15 +2,15 @@ var okcms = require('..'); var app = okcms.createApp({ - root: 'www', + root: 'public', schemas: { page: { - title: {type: 'string'}, + title: {type: 'string', id: true}, body: {type: 'string'} }, project: { - title: {type: 'string'}, + title: {type: 'string', id: true}, index: {type: 'integer'}, category: {type: 'enum'}, body: {type: 'string'}, @@ -20,8 +20,8 @@ var app = okcms.createApp({ }, resources: [ - { type: 'page', id: 'about' }, - { type: 'page', id: 'contact' }, + { type: 'page', data: {title: 'about'}}, + { type: 'page', data: {title: 'contact'}}, { type: 'project' }, ], |
