View | Details | Raw Unified | Return to bug 23463
Collapse All | Expand All

(-)a/C4/Items.pm (-25 lines)
Lines 48-54 BEGIN { Link Here
48
        MoveItemFromBiblio
48
        MoveItemFromBiblio
49
        CartToShelf
49
        CartToShelf
50
        GetAnalyticsCount
50
        GetAnalyticsCount
51
        SearchItemsByField
52
        SearchItems
51
        SearchItems
53
        PrepareItemrecordDisplay
52
        PrepareItemrecordDisplay
54
    );
53
    );
Lines 2053-2081 sub GetAnalyticsCount { Link Here
2053
    return ($result);
2052
    return ($result);
2054
}
2053
}
2055
2054
2056
=head2 SearchItemsByField
2057
2058
    my $items = SearchItemsByField($field, $value);
2059
2060
SearchItemsByField will search for items on a specific given field.
2061
For instance you can search all items with a specific stocknumber like this:
2062
2063
    my $items = SearchItemsByField('stocknumber', $stocknumber);
2064
2065
=cut
2066
2067
sub SearchItemsByField {
2068
    my ($field, $value) = @_;
2069
2070
    my $filters = {
2071
        field => $field,
2072
        query => $value,
2073
    };
2074
2075
    my ($results) = SearchItems($filters);
2076
    return $results;
2077
}
2078
2079
sub _SearchItems_build_where_fragment {
2055
sub _SearchItems_build_where_fragment {
2080
    my ($filter) = @_;
2056
    my ($filter) = @_;
2081
2057
2082
- 

Return to bug 23463