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

(-)a/acqui/duplicate_orders.pl (+12 lines)
Lines 82-92 $filters->{to_placed_on} = $to_placed_on; Link Here
82
  my ( @result_order_loop, @selected_order_loop );
82
  my ( @result_order_loop, @selected_order_loop );
83
my @ordernumbers = split ',', scalar $input->param('ordernumbers') || '';
83
my @ordernumbers = split ',', scalar $input->param('ordernumbers') || '';
84
if ( $op eq 'select' ) {
84
if ( $op eq 'select' ) {
85
86
    # Set filter for 'all status'
87
    if ( $filters->{orderstatus} eq "any" ) {
88
        delete( $filters->{orderstatus} );
89
        $filters->{get_canceled_order} = 1;
90
    }
91
85
    @result_order_loop = map {
92
    @result_order_loop = map {
86
        my $order = $_;
93
        my $order = $_;
87
        ( grep {$_ eq $order->{ordernumber}} @ordernumbers ) ? () : $order
94
        ( grep {$_ eq $order->{ordernumber}} @ordernumbers ) ? () : $order
88
    } @{ C4::Acquisition::GetHistory(%$filters) };
95
    } @{ C4::Acquisition::GetHistory(%$filters) };
89
96
97
    # Reset order status for 'all status'
98
    if ( $filters->{get_canceled_order} ) {
99
        $filters->{orderstatus} = "any";
100
    }
101
90
    @selected_order_loop =
102
    @selected_order_loop =
91
      scalar @ordernumbers
103
      scalar @ordernumbers
92
      ? @{ C4::Acquisition::GetHistory( ordernumbers => \@ordernumbers ) }
104
      ? @{ C4::Acquisition::GetHistory( ordernumbers => \@ordernumbers ) }
(-)a/acqui/histsearch.pl (+10 lines)
Lines 114-119 while ( my $additional_field = $additional_fields->next ) { Link Here
114
}
114
}
115
$filters->{additional_fields} = \@additional_field_filters;
115
$filters->{additional_fields} = \@additional_field_filters;
116
116
117
# Set filter for 'all status'
118
if ( $filters->{orderstatus} eq "any" ) {
119
    delete( $filters->{orderstatus} );
120
    $filters->{get_canceled_order} = 1;
121
}
117
122
118
my $order_loop;
123
my $order_loop;
119
# If we're supplied any value then we do a search. Otherwise we don't.
124
# If we're supplied any value then we do a search. Otherwise we don't.
Lines 121-126 if ($do_search) { Link Here
121
    $order_loop = GetHistory(%$filters);
126
    $order_loop = GetHistory(%$filters);
122
}
127
}
123
128
129
# Reset order status for 'all status'
130
if ( $filters->{get_canceled_order} ) {
131
    $filters->{orderstatus} = "any";
132
}
133
124
my $budgetperiods = C4::Budgets::GetBudgetPeriods;
134
my $budgetperiods = C4::Budgets::GetBudgetPeriods;
125
my $bp_loop = $budgetperiods;
135
my $bp_loop = $budgetperiods;
126
for my $bp ( @{$budgetperiods} ) {
136
for my $bp ( @{$budgetperiods} ) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/filter-orders.inc (-2 / +6 lines)
Lines 51-57 Link Here
51
            [% IF filters.orderstatus == "" %]
51
            [% IF filters.orderstatus == "" %]
52
              <option value="">Any status except cancelled</option>
52
              <option value="">Any status except cancelled</option>
53
            [% ELSE %]
53
            [% ELSE %]
54
              <option value="" selected="selected"></option>
54
              <option value="" selected="selected">Any status except cancelled</option>
55
            [% END %]
56
            [% IF filters.orderstatus == "any" %]
57
              <option value="any" selected="selected">Any status</option>
58
            [% ELSE %]
59
              <option value="any">Any status</option>
55
            [% END %]
60
            [% END %]
56
            [% IF filters.orderstatus == "new" %]
61
            [% IF filters.orderstatus == "new" %]
57
              <option value="new" selected="selected">New</option>
62
              <option value="new" selected="selected">New</option>
58
- 

Return to bug 14092