Lines 71-79
sub add_opac_new {
Link Here
|
71 |
$sth->execute(@values); |
71 |
$sth->execute(@values); |
72 |
$retval = 1; |
72 |
$retval = 1; |
73 |
|
73 |
|
74 |
#log the NEW OPAC news entry |
74 |
#Log new news entry |
75 |
if (C4::Context->preference("NewsLog")) { |
75 |
if (C4::Context->preference("NewsLog")) { |
76 |
logaction('OPACNEWS', 'ADD' , undef, $href_entry->{lang} . ' | ' . $href_entry->{content}); |
76 |
logaction('NEWS', 'ADD' , undef, $href_entry->{lang} . ' | ' . $href_entry->{content}); |
77 |
} |
77 |
} |
78 |
} |
78 |
} |
79 |
return $retval; |
79 |
return $retval; |
Lines 116-124
sub upd_opac_new {
Link Here
|
116 |
$retval = 1; |
116 |
$retval = 1; |
117 |
} |
117 |
} |
118 |
|
118 |
|
119 |
#log new OPAC news modification |
119 |
#Log news entry modification |
120 |
if (C4::Context->preference("NewsLog")) { |
120 |
if (C4::Context->preference("NewsLog")) { |
121 |
logaction('OPACNEWS', 'MODIFY' , undef, $href_entry->{lang} . ' | ' . $href_entry->{content}); |
121 |
logaction('NEWS', 'MODIFY' , undef, $href_entry->{lang} . ' | ' . $href_entry->{content}); |
122 |
} |
122 |
} |
123 |
return $retval; |
123 |
return $retval; |
124 |
} |
124 |
} |
Lines 127-137
sub del_opac_new {
Link Here
|
127 |
my ($ids) = @_; |
127 |
my ($ids) = @_; |
128 |
if ($ids) { |
128 |
if ($ids) { |
129 |
|
129 |
|
130 |
#log new OPAC news deletion |
130 |
#Log news deletion |
131 |
if (C4::Context->preference("NewsLog")) { |
131 |
if (C4::Context->preference("NewsLog")) { |
132 |
foreach my $newsid ( split(/,/, $ids )) { |
132 |
foreach my $newsid ( split(/,/, $ids )) { |
133 |
my $n = Koha::News->find( $newsid ); |
133 |
my $n = Koha::News->find( $newsid ); |
134 |
logaction('OPACNEWS', 'DELETE', undef, $n->unblessed->{lang} . ' | ' . $n->unblessed->{content} ); |
134 |
logaction('NEWS', 'DELETE', undef, $n->unblessed->{lang} . ' | ' . $n->unblessed->{content} ); |
135 |
} |
135 |
} |
136 |
} |
136 |
} |
137 |
|
137 |
|