OSDN Git Service

Merge branch 'v06' of git.sourceforge.jp:/gitroot/pettanr/pettanr into v06
[pettanr/pettanr.git] / app / assets / javascripts / models / story_sheet.js.coffee
1 class Pettanr.StorySheet extends Peta.Leaf\r
2   url: '/story_sheets/'\r
3   \r
4   @singular: () ->\r
5     'StorySheet'\r
6   \r
7   @plural: () ->\r
8     'StorySheets'\r
9   \r
10   defaults: {\r
11     id: null,\r
12     story_id: null,\r
13     sheet_id: null,\r
14     t: null\r
15   } \r
16   \r
17   story: () ->\r
18     new Pettanr.Story({id: @get('story_id')})\r
19   \r
20   sheet: () ->\r
21     new Pettanr.Sheet({id: @get('sheet_id')})\r
22   \r
23   initialize: () ->\r
24     if @id\r
25       @url = @url + @id\r
26   \r