Bug 7295: More granular permissions for baskets
[koha.git] / tools / koha-news.pl
index 08b38c8..4dd07a9 100755 (executable)
 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 # A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
 #
-# You should have received a copy of the GNU General Public License along with
-# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
-# Suite 330, Boston, MA  02111-1307 USA
+# You should have received a copy of the GNU General Public License along
+# with Koha; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
 use strict;
+#use warnings; FIXME - Bug 2505
 use CGI;
 use C4::Auth;
 use C4::Koha;
@@ -73,11 +74,12 @@ my $op = $cgi->param('op');
 if ( $op eq 'add_form' ) {
     $template->param( add_form => 1 );
     if ($id) {
+        if($new_detail->{lang} eq "slip"){ $template->param( slip => 1); }
         $template->param( 
             op => 'edit',
             id => $new_detail->{'idnew'}
         );
-        $template->param($new_detail);
+        $template->{VARS}->{'new_detail'} = $new_detail;
     }
     else {
         $template->param( op => 'add' );
@@ -116,8 +118,4 @@ else {
         opac_news_count => $opac_news_count,
                );
 }
-$template->param(
-                               DHTMLcalendar_dateformat =>  C4::Dates->DHTMLcalendar(),
-                               dateformat    => C4::Context->preference("dateformat"),
-               );
 output_html_with_http_headers $cgi, $cookie, $template->output;