[dancer-users] no request method
Fayland Lam
fayland at gmail.com
Sun Nov 2 15:09:04 GMT 2014
Why not? you should just give it a try.
database('foo') works under sub doit
Thanks
On Sun, Nov 2, 2014 at 11:04 PM, Jean-Marc Choulet <jm130794 at gmail.com> wrote:
> Hello,
>
> Is it possible to create a no request method in Dancer2 module ?
>
> get qr{/(\d+)/members} => sub {
> my ($department) = splat;
> ...
> my $sth = database('foo')->prepare($queryString);
> ...
> # call my method doit();
> my $data = doit()...
> }
>
> sub doit {
> # I want to retrieve some data from my database 'foo'
>
> return $data
> }
>
> Thanks,
>
> Jean-Marc
>
> _______________________________________________
> dancer-users mailing list
> dancer-users at dancer.pm
> http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
--
Fayland Lam // http://www.fayland.org/
More information about the dancer-users
mailing list