From: Moritz Bunkus Date: Fri, 31 Aug 2012 14:41:32 +0000 (+0200) Subject: Sorted-Controller-Helfer: Default-Wert für 'DEFAULT_BY' gefixt X-Git-Tag: release-3.0.0beta1~256 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=481e3f934e08d79a35597e01e0c02bb9931ef4a7;p=kivitendo-erp.git Sorted-Controller-Helfer: Default-Wert für 'DEFAULT_BY' gefixt --- diff --git a/SL/Controller/Helper/Sorted.pm b/SL/Controller/Helper/Sorted.pm index 7f5f4526d..817f80319 100644 --- a/SL/Controller/Helper/Sorted.pm +++ b/SL/Controller/Helper/Sorted.pm @@ -23,7 +23,7 @@ sub make_sorted { } $specs{DEFAULT_DIR} = $specs{DEFAULT_DIR} || !defined($specs{DEFAULT_DIR}) ? 1 : 0; - $specs{DEFAULT_BY} ||= "SL::DB::$specs{MODEL}::Manager"->_get_sort_spec($class)->{default}->[0]; + $specs{DEFAULT_BY} ||= { "SL::DB::Manager::$specs{MODEL}"->_sort_spec }->{default}->[0]; $specs{FORM_PARAMS} ||= [ qw(sort_by sort_dir) ]; $specs{ONLY} ||= []; $specs{ONLY} = [ $specs{ONLY} ] if !ref $specs{ONLY};