[Jifty-commit] r4213 - in Jifty-DBI/trunk: lib/Jifty/DBI

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Sun Oct 7 18:28:23 EDT 2007


Author: jesse
Date: Sun Oct  7 18:28:20 2007
New Revision: 4213

Modified:
   Jifty-DBI/trunk/   (props changed)
   Jifty-DBI/trunk/META.yml
   Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm

Log:
 r67965 at 000-166-898:  jesse | 2007-10-07 18:06:53 -0400
 Allow the specification of functions as 'column' on sql search criteria.


Modified: Jifty-DBI/trunk/META.yml
==============================================================================
--- Jifty-DBI/trunk/META.yml	(original)
+++ Jifty-DBI/trunk/META.yml	Sun Oct  7 18:28:20 2007
@@ -3,7 +3,7 @@
   DBD::SQLite: 0
   Test::More: 0.52
 distribution_type: module
-generated_by: Module::Install version 0.670
+generated_by: Module::Install version 0.67
 license: perl
 meta-spec: 
   url: http://module-build.sourceforge.net/META-spec-v1.3.html

Modified: Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm
==============================================================================
--- Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm	(original)
+++ Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm	Sun Oct  7 18:28:20 2007
@@ -1027,7 +1027,7 @@
 
     # {{{ if there's no alias set, we need to set it
 
-    unless ( $args{'alias'} ) {
+    unless (defined  $args{'alias'} ) {
 
         #if the table we're looking at is the same as the main table
         if ( $args{'table'} eq $self->table ) {
@@ -1049,7 +1049,7 @@
     # Set this to the name of the column and the alias, unless we've been
     # handed a subclause name
 
-    my $qualified_column = $args{'alias'} . "." . $args{'column'};
+    my $qualified_column = $args{'alias'} ? $args{'alias'} . "." . $args{'column'} : $args{'column'};
     my $clause_id = $args{'subclause'} || $qualified_column;
 
     # If we're trying to get a leftjoin restriction, lets set


More information about the Jifty-commit mailing list