Lines 37-43
use Data::Dumper; # used as part of logging item record changes, not just for
Link Here
|
37 |
use Koha::DateUtils qw/dt_from_string/; |
37 |
use Koha::DateUtils qw/dt_from_string/; |
38 |
use Koha::Database; |
38 |
use Koha::Database; |
39 |
|
39 |
|
40 |
use Koha::Database; |
40 |
use Koha::Items; |
41 |
use Koha::SearchEngine; |
41 |
use Koha::SearchEngine; |
42 |
use Koha::SearchEngine::Search; |
42 |
use Koha::SearchEngine::Search; |
43 |
|
43 |
|
Lines 3046-3065
sub PrepareItemrecordDisplay {
Link Here
|
3046 |
}; |
3046 |
}; |
3047 |
} |
3047 |
} |
3048 |
|
3048 |
|
3049 |
=head2 columns |
|
|
3050 |
|
3051 |
my @columns = C4::Items::columns(); |
3052 |
|
3053 |
Returns an array of items' table columns on success, |
3054 |
and an empty array on failure. |
3055 |
|
3056 |
=cut |
3057 |
|
3058 |
sub columns { |
3059 |
my $rs = Koha::Database->new->schema->resultset('Item'); |
3060 |
return $rs->result_source->columns; |
3061 |
} |
3062 |
|
3063 |
=head2 biblioitems_columns |
3049 |
=head2 biblioitems_columns |
3064 |
|
3050 |
|
3065 |
my @columns = C4::Items::biblioitems_columns(); |
3051 |
my @columns = C4::Items::biblioitems_columns(); |
Lines 3081-3087
sub ToggleNewStatus {
Link Here
|
3081 |
|
3067 |
|
3082 |
my $dbh = C4::Context->dbh; |
3068 |
my $dbh = C4::Context->dbh; |
3083 |
my @errors; |
3069 |
my @errors; |
3084 |
my @item_columns = map { "items.$_" } C4::Items::columns; |
3070 |
my @item_columns = map { "items.$_" } Koha::Items->columns; |
3085 |
my @biblioitem_columns = map { "biblioitems.$_" } C4::Items::biblioitems_columns; |
3071 |
my @biblioitem_columns = map { "biblioitems.$_" } C4::Items::biblioitems_columns; |
3086 |
my $report; |
3072 |
my $report; |
3087 |
for my $rule ( @rules ) { |
3073 |
for my $rule ( @rules ) { |