/[SQLSession]/trunk/lib/SQLSession/Dispatcher.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /trunk/lib/SQLSession/Dispatcher.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 28 - (show annotations)
Thu Dec 7 19:56:41 2006 UTC (17 years, 4 months ago) by dpavlin
File size: 437 byte(s)
dodana biljeĆĄka uz SQL query, malo CSS-a
1 package SQLSession::Dispatcher;
2
3 use strict;
4 use warnings;
5
6 use Jifty::Dispatcher -base;
7
8 use Data::Dump qw/dump/;
9
10 under qr{sql/(\d+)} => run {
11
12 my $q = SQLSession::Model::Query->new();
13 $q->load( $1 ) or next_rule;
14
15 warn "q = ",dump( $q );
16
17 set sql_query => $q->sql_query;
18 set name => $q->name;
19 set database => $q->on_database->id;
20
21 show '/sql';
22
23 };
24
25 on 'new' => run {
26 show '/sql';
27 };
28
29 on '/' => run {
30 redirect '/list';
31 };
32
33 1;

  ViewVC Help
Powered by ViewVC 1.1.26