diff options
author | Paul Duncan <pabs@pablotron.org> | 2016-03-10 09:25:07 -0500 |
---|---|---|
committer | Paul Duncan <pabs@pablotron.org> | 2016-03-10 09:25:07 -0500 |
commit | 5d7cd9615840341d2ccab1d8b7acfd49d6a5b743 (patch) | |
tree | f2ff9b9f47280826123e962efb95202af11f225a /src/guff/views/ecrs/test.ecr | |
parent | adfc9a07d407a9e29bcd7d8af4f24bf7d75c9fe6 (diff) | |
download | old-guff-5d7cd9615840341d2ccab1d8b7acfd49d6a5b743.tar.bz2 old-guff-5d7cd9615840341d2ccab1d8b7acfd49d6a5b743.zip |
rename test to test-blog
Diffstat (limited to 'src/guff/views/ecrs/test.ecr')
-rw-r--r-- | src/guff/views/ecrs/test.ecr | 167 |
1 files changed, 0 insertions, 167 deletions
diff --git a/src/guff/views/ecrs/test.ecr b/src/guff/views/ecrs/test.ecr deleted file mode 100644 index d36b62c..0000000 --- a/src/guff/views/ecrs/test.ecr +++ /dev/null @@ -1,167 +0,0 @@ -<h1><%= h(TITLE) %></h1> - -<% - [{ - id: "draft", - name: "Draft Posts", - - actions: [{ - id: "posted", - name: "Post", - }, { - id: "deleted", - name: "Delete", - }], - }, { - id: "posted", - name: "Posted", - - actions: [{ - id: "draft", - name: "Draft", - }, { - id: "deleted", - name: "Delete", - }], - }, { - id: "deleted", - name: "Deleted Posts", - - actions: [{ - id: "draft", - name: "Draft", - }], - }].each do |kind| -%> - <h2><%= - h(kind[:name] as String) - %></h2> - - <table> - <thead> - <tr> - <th>ID</th> - <th>Created At</th> - <th>Name</th> - <th>Body</th> - <th colspan='2'>Actions</th> - </tr> - </thead> - - <tbody><% posts(kind[:id] as String).rows.each do |post| %> - <tr> - <td><%= - h(post.row["post_id"].to_s) - %></td> - - <td><%= - h(post.row["created_at"].to_s) - %></td> - - <td><%= - h(post.row["name"].to_s) - %></td> - - <td><%= - post.row["body"].to_s - %></td> - - <% (kind[:actions] as Array(Hash(Symbol, String))).each do |a| %> - <td> - <form - method='post' - action='/test/set_state' - > - <input - type='hidden' - name='post_id' - value='<%= h(post.row["post_id"].to_s) %>' - /> - - <input - type='hidden' - name='state' - value='<%= a[:id] %>' - </input> - - <input - type='submit' - title='Set post to <%= h(a[:id]) %>..' - value='<%= h(a[:name]) %>' - /> - </form> - </td> - <% end %> - </tr> - <% end %></tbody> - </table> -<% end %> - -<div class='section'> - <form - method='post' - action='/test/add_post' - > - <label for='post-name'> - Name - </label><br/> - - <input - type='text' - id='post-name' - name='name' - title='Enter post title' - placeholder='Post Title' - value='' - /> - - <br/> - - <label for='post-slug'> - Slug - </label><br/> - - <input - type='text' - id='post-slug' - name='slug' - title='Enter post slug' - placeholder='post-slug' - value='' - /> - - <br/> - - <label for='post-body'> - Post Body - </label><br/> - - <textarea - id='post-body' - name='body' - ></textarea> - - <br/> - - <label for='post-tags'> - Tags (space-delimited) - </label><br/> - - <input - type='text' - id='post-tags' - name='tags' - title='Enter post tags' - placeholder='some post tags' - value='' - /> - - <br/> - - <input - type='submit' - title='Create new post.' - value='Add Post' - /> - </form> -</div> |