[Catalyst-commits] r13148 - in CatalystX-CRUD/CatalystX-CRUD/trunk:
. lib/CatalystX lib/CatalystX/CRUD
lib/CatalystX/CRUD/Iterator lib/CatalystX/CRUD/Model
lib/CatalystX/CRUD/ModelAdapter lib/CatalystX/CRUD/Object
lib/CatalystX/CRUD/Test
karpet at dev.catalyst.perl.org
karpet at dev.catalyst.perl.org
Sun Apr 11 16:59:04 GMT 2010
Author: karpet
Date: 2010-04-11 17:59:04 +0100 (Sun, 11 Apr 2010)
New Revision: 13148
Modified:
CatalystX-CRUD/CatalystX-CRUD/trunk/Changes
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm
Log:
release 0.49
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/Changes
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/Changes 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/Changes 2010-04-11 16:59:04 UTC (rev 13148)
@@ -235,3 +235,8 @@
0.48 29 Jan 2009
* fix bug with create() introduced in 0.47.
* remove explicit dep on Class::C3 per RT54097
+
+0.49 11 April 2010
+ * uri_for_view_on_single_result() will return uri for 'view' action,
+ regardless of value of can_write().
+
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -37,7 +37,7 @@
naked_results => 0,
);
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
@@ -851,7 +851,7 @@
Returns 0 unless view_on_single_result returns true.
Otherwise, calls the primary_key() value on the first object
-in I<results> and constructs a uri_for() value to the edit()
+in I<results> and constructs a uri_for() value to the 'view'
action in the same class as the current action.
=cut
@@ -866,10 +866,9 @@
my $id = $self->make_primary_key_string($obj);
- # the append . '' is to force stringify anything
- # that might be an object with overloading. Otherwise
- # uri_for() assumes it is an Action object.
- return $c->uri_for( $id . '', $self->can_write($c) ? 'edit' : 'view' );
+ # force stringify $id in case it is an object.
+ # Otherwise uri_for() assumes it is an Action object.
+ return $c->uri_for( "$id", 'view' );
}
=head2 make_query( I<context>, I<arg> )
@@ -910,7 +909,7 @@
}
# turn flag on unless explicitly turned off
- $c->stash->{view_on_single_result} = 1
+ $c->stash->{view_on_single_result} = 'edit'
unless exists $c->stash->{view_on_single_result};
my $query;
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -3,7 +3,7 @@
use warnings;
use Carp;
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -4,7 +4,7 @@
use Carp;
use base qw( CatalystX::CRUD );
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -10,7 +10,7 @@
__PACKAGE__->mk_accessors(qw( inc_path ));
-our $VERSION = '0.48';
+our $VERSION = '0.49';
# test whether symlink() works at compile time
my $SYMLINK_SUPPORTED = eval { symlink( "", "" ); 1 };
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -9,7 +9,7 @@
__PACKAGE__->mk_accessors(qw( use_ilike ne_sign ));
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -9,7 +9,7 @@
Catalyst::Model
);
-our $VERSION = '0.48';
+our $VERSION = '0.49';
__PACKAGE__->mk_accessors(qw( object_class page_size ));
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -3,7 +3,7 @@
use warnings;
use base qw( CatalystX::CRUD::ModelAdapter );
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -13,7 +13,7 @@
__PACKAGE__->mk_accessors(qw( content file ));
__PACKAGE__->delegate_class('Path::Class::File');
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -12,7 +12,7 @@
__PACKAGE__->mk_ro_accessors(qw( delegate ));
__PACKAGE__->mk_classdata('delegate_class');
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -10,7 +10,7 @@
__PACKAGE__->mk_accessors(qw( enable_rpc_compat ));
__PACKAGE__->config( enable_rpc_compat => 0 );
-our $VERSION = '0.48';
+our $VERSION = '0.49';
#warn "REST VERSION = $VERSION";
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -8,7 +8,7 @@
__PACKAGE__->mk_ro_accessors(qw( count pager query results ));
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -8,7 +8,7 @@
__PACKAGE__->mk_accessors( qw( form_fields ) );
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -7,7 +7,7 @@
__PACKAGE__->mk_accessors(qw( params fields ));
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm 2010-04-10 08:39:38 UTC (rev 13147)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm 2010-04-11 16:59:04 UTC (rev 13148)
@@ -4,7 +4,7 @@
use strict;
use Carp;
-our $VERSION = '0.48';
+our $VERSION = '0.49';
=head1 NAME
More information about the Catalyst-commits
mailing list