|
Last change
on this file since 51 was
45,
checked in by peter, 12 years ago
|
- created a separate edit runmode to edit existing bookmarks; handled POST /{id}
- the old edit runmode has been renamed to create, and only handles POST /
- added an update method to the Bookmark class
- the URI field on the bookmark editing form is no longer ever readonly; the URI can be changed after the bookmark has been created
- changes to the URI or the bookmark's tags cause the bookmark's mtime to be updated
|
-
Property svn:executable set to
*
|
|
File size:
714 bytes
|
| Line | |
|---|
| 1 | #!/usr/bin/perl -w |
|---|
| 2 | use strict; |
|---|
| 3 | |
|---|
| 4 | package BookmarkApp::Dispatch; |
|---|
| 5 | use base 'CGI::Application::Dispatch'; |
|---|
| 6 | |
|---|
| 7 | sub dispatch_args { |
|---|
| 8 | return { |
|---|
| 9 | table => [ |
|---|
| 10 | '[get]' => { app => 'BookmarkApp', rm => 'list' }, |
|---|
| 11 | 'list[get]' => { app => 'BookmarkApp', rm => 'list' }, |
|---|
| 12 | 'feed[get]' => { app => 'BookmarkApp', rm => 'feed' }, |
|---|
| 13 | ':id[get]' => { app => 'BookmarkApp', rm => 'view' }, |
|---|
| 14 | ':id/:field[get]' => { app => 'BookmarkApp', rm => 'view_field' }, |
|---|
| 15 | '[post]' => { app => 'BookmarkApp', rm => 'create' }, |
|---|
| 16 | ':id[post]' => { app => 'BookmarkApp', rm => 'edit' }, |
|---|
| 17 | ], |
|---|
| 18 | }; |
|---|
| 19 | } |
|---|
| 20 | |
|---|
| 21 | # module return |
|---|
| 22 | 1; |
|---|
Note: See
TracBrowser
for help on using the repository browser.