is ( $templates->[1]->{units}, 'POINT', 'units is good' );
isnt( exists $templates->[1]->{creator}, 'Labels', 'creator is good' );
-# With filter params ------------------
-$templates = get_all_templates( filter => 'rows = 7' );
+# With filters params ------------------
+$templates = get_all_templates( { filters => { rows => 7} } );
$query = '
SELECT count(*)
is( $templates->[0]->{creator}, 'Labels', 'creator is good' );
# With orderby param ------------------
-$templates = get_all_templates( orderby => 'rows DESC' );
+$templates = get_all_templates( { orderby => 'rows DESC' } );
$query = '
SELECT count(*)
isnt( exists $layouts->[1]->{layout_xml}, 'layout_xml2', 'layout_xml is good' );
isnt( exists $layouts->[1]->{creator}, 'Labels', 'creator is good' );
-# With filter params ------------------
-$layouts = get_all_layouts( filter => 'font_size = 12' );
+# With filters params ------------------
+$layouts = get_all_layouts( { filters => { font_size => 12 } } );
$query = '
SELECT count(*)
is( $layouts->[0]->{creator}, 'Labels', 'creator is good' );
# With orderby param ------------------
-$layouts = get_all_layouts( orderby => 'font_size DESC' );
+$layouts = get_all_layouts( { orderby => 'font_size DESC' } );
$query = '
SELECT count(*)
isnt( exists $profiles->[1]->{units}, 'POINT', 'units is good' );
isnt( exists $profiles->[1]->{creator}, 'Labels', 'creator is good' );
-# With filter params ------------------
-$profiles = get_all_profiles( filters => { template_id => 1235 } );
+# With filters params ------------------
+$profiles = get_all_profiles( { filters => { template_id => 1235 } } );
$query = '
SELECT count(*)
}
# Without creator params --------------
-my $batches = get_batch_summary( creator => 'Labels' );
+my $batches = get_batch_summary( { filters => { creator => 'Labels' } } );
$query = '
SELECT batch_id, count(batch_id)
is( $batches->[1]->{batch_id}, 12, 'batch_id is good' );
is( $batches->[1]->{_item_count}, $count, 'item_number is good for this batch_id' );
-# Without filter & creator params -----
-$batches = get_batch_summary( filter => "branch_code='$library1->{branchcode}'", creator => 'Labels' );
+# Without filters -----
+$batches = get_batch_summary( { filters => { branch_code => $library1->{branchcode}, creator => 'Labels' } } );
is( @$batches, 1, 'There is 1 batch matching' );
$query = '