Bug 16058: Delete individual news item from koha-news.pl
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / intranet-main.tt
1 [% USE Koha %]
2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha staff client</title>
4 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/mainpage.css" />
5 [% INCLUDE 'doc-head-close.inc' %]
6 <style type="text/css"> </style>
7 <script type="text/javascript">
8 //<![CDATA[
9 var MSG_CONFIRM_DELETE = _("Are you sure you want to delete this news item? This cannot be undone.");
10 //]]>
11 </script>
12 </head>
13 <body id="main_intranet-main" class="main">
14 [% INCLUDE 'header.inc' %]
15 [% INCLUDE 'home-search.inc' %]
16
17 <div id="breadcrumbs" >Home</div>
18
19
20 <div id="doc3" class="yui-t3">
21    <div id="bd" role="main">
22     <div id="yui-main">
23     <div class="yui-b"><div class="yui-g">
24     [% IF adminWarning %]
25         <div id="adminwarning" class="dialog alert">
26             <p><strong>Warning:</strong> You are logged in as the database administrative user. This is not recommended because some parts of Koha will not function as expected when using this account.</p>
27             <p>Please log in instead with a regular staff account. To create a staff account, create a library, a patron category 'Staff' and add a new patron. Then give this patron permissions from 'More' in the toolbar.</p>
28 <p><a class="btn btn-small" href="/cgi-bin/koha/members/members-home.pl"><i class="fa fa-plus"> </i> Create patron</a></p>
29         </div>
30     [% END %]
31     <div class="yui-u first">
32
33             <div id="area-list-left">
34                 <ul class="biglinks-list">
35                     [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
36                     <li>
37                         <a class="icon_general icon_circulation" href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>
38                     </li>
39                     [% END %]
40
41                     [% IF ( CAN_user_borrowers ) %]
42                     <li>
43                         <a class="icon_general icon_patrons" href="/cgi-bin/koha/members/members-home.pl">Patrons</a>
44                     </li>
45                     [% END %]
46
47                     [% IF ( CAN_user_catalogue ) %]
48                     <li>
49                         <a class="icon_general icon_search" href="/cgi-bin/koha/catalogue/search.pl">Advanced search</a>
50                     </li>
51                     [% END %]
52
53                     <li>
54                         <a class="icon_general icon_lists" href="/cgi-bin/koha/virtualshelves/shelves.pl">Lists</a>
55                     </li>
56
57                     [% IF ( UseCourseReserves ) %]
58                         <li>
59                             <a class="icon_general icon_course_reserves" href="/cgi-bin/koha/course_reserves/course-reserves.pl">Course reserves</a>
60                         </li>
61                     [% END %]
62
63                     [% IF ( CAN_user_editcatalogue_edit_catalogue || CAN_user_editcatalogue_edit_items ) %]
64                     <li>
65                         <a class="icon_general icon_cataloging" href="/cgi-bin/koha/cataloguing/addbooks.pl">Cataloging</a>
66                     </li>
67                     [% END %]
68                     <li>
69                         <a class="icon_general icon_authorities" href="/cgi-bin/koha/authorities/authorities-home.pl">Authorities</a>
70                     </li>
71                 </ul>
72             </div><!-- /area-list-left -->
73         </div><!-- /yui-u first -->
74     <div class="yui-u">
75             <div id="area-list-right">
76                 <ul class="biglinks-list">
77                     [% IF ( CAN_user_serials ) %]
78                     <li>
79                         <a class="icon_general icon_serials" href="/cgi-bin/koha/serials/serials-home.pl">Serials</a>
80                         <span class="biglink"></span>
81                     </li>
82                     [% END %]
83
84                     [% IF ( CAN_user_acquisition ) %]
85                     <li>
86                         <a class="icon_general icon_acquisitions" href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
87                         <span class="biglink"></span>
88                     </li>
89                     [% END %]
90
91                     [% IF ( CAN_user_reports ) %]
92                     <li>
93                         <a class="icon_general icon_reports" href="/cgi-bin/koha/reports/reports-home.pl">Reports</a>
94                     </li>
95                     [% END %]
96
97
98                     [% IF ( CAN_user_tools ) %]
99                     <li>
100                         <a class="icon_general icon_tools" href="/cgi-bin/koha/tools/tools-home.pl">Tools</a>
101                     </li>
102                     [% END %]
103
104                     [% IF ( CAN_user_parameters ) %]
105                     <li>
106                         <a class="icon_general icon_administration" href="/cgi-bin/koha/admin/admin-home.pl">Koha administration</a>
107                     </li>
108                     [% END %]
109                     <li>
110                         <a class="icon_general icon_koha" href="/cgi-bin/koha/about.pl">About Koha</a>
111                     </li>
112                 </ul>
113             </div><!-- /area-list-right -->
114         </div><!-- /yui-u -->
115 </div><!-- /yui-g -->
116 <div class="yui-g">
117             [% IF ( ( CAN_user_tools_moderate_comments  && pendingcomments ) 
118                     || ( CAN_user_tools_moderate_tags && pendingtags )
119                     || ( CAN_user_borrowers && pending_borrower_modifications )
120                     || ( CAN_user_acquisition && pendingsuggestions )
121                     || ( CAN_user_borrowers && pending_discharge_requests )
122             ) %]
123                 <div id="area-pending">
124                     [% IF ( CAN_user_acquisition && pendingsuggestions ) %]
125                     <div class="pending-info" id="suggestions_pending">
126
127                         <a href="/cgi-bin/koha/suggestion/suggestion.pl#ASKED">Suggestions pending approval</a>:
128                         <span class="pending-number-link">[% pendingsuggestions %]</span>
129                     </div>
130                     [% END %]
131
132                     [% IF ( CAN_user_tools_moderate_comments  && pendingcomments ) %]
133                     <div class="pending-info" id="comments_pending">
134                         <a href="/cgi-bin/koha/reviews/reviewswaiting.pl">Comments pending approval</a>:
135                         <span class="pending-number-link">[% pendingcomments %]</span>
136                     </div>
137                     [% END %]
138
139                     [% IF ( CAN_user_tools_moderate_tags && pendingtags ) %]
140                     <div class="pending-info" id="tags_pending">
141                         <a href="/cgi-bin/koha/tags/review.pl">Tags pending approval</a>:
142                         <span class="pending-number-link">[% pendingtags %]</span>
143                     </div>
144                     [% END %]
145
146
147                     [% IF ( CAN_user_borrowers && pending_borrower_modifications ) %]
148                     <div class="pending-info" id="patron_updates_pending">
149                         <a href="/cgi-bin/koha/members/members-update.pl">Patrons requesting modifications</a>:
150                         <span class="pending-number-link">[% pending_borrower_modifications %]</span>
151                     </div>
152                     [% END %]
153
154                     [% IF CAN_user_borrowers && pending_discharge_requests %]
155                     <div class="pending-info" id="patron_discharges_pending">
156                         <a href="/cgi-bin/koha/members/discharges.pl">Discharge requests pending</a>:
157                         <span class="pending-number-link">[% pending_discharge_requests %]</span>
158                     </div>
159                     [% END %]
160
161                 </div>
162
163             [% END %]
164
165 </div>
166             [% IF ( IntranetmainUserblock ) %]
167                 <div class="yui-g" id="area-userblock">
168                     <div class="user-info">
169                         [% IntranetmainUserblock %]
170                     </div>
171                 </div>
172             [% END %]
173 </div>
174     </div>
175     <div class="yui-b"><!-- YOUR NAVIGATION GOES HERE -->
176     [% IF ( koha_news_count ) %]
177         <div id="area-news">
178             <h3><span="news_title">News</span></h3>
179             [% SET newsdisp = Koha.Preference('NewsAuthorDisplay') %]
180             [% FOREACH koha_new IN koha_news %]
181                 <div class="newsitem" id="news[% koha_new.idnew %]"><h4>[% koha_new.title %]</h4>
182                     <p>[% koha_new.new %]</p>
183                     <p class="newsfooter"> Posted on [% koha_new.newdate %][% IF( ( newsdisp == 'staff' || newsdisp == 'both' ) && koha_new.borrowernumber ) %] by <span class="newsauthor_title">[% koha_new.author_title %] </span>[% koha_new.author_firstname %] [% koha_new.author_surname %]<br />[% END %]
184                         [% IF ( CAN_user_tools ) %]
185                             <a href="/cgi-bin/koha/tools/koha-news.pl?op=add_form&amp;id=[% koha_new.idnew %]">Edit</a>
186                              | <a href="/cgi-bin/koha/tools/koha-news.pl?op=del&amp;ids=[% koha_new.idnew %]" onclick="return confirm(MSG_CONFIRM_DELETE);">Delete</a>
187                              | <a href="/cgi-bin/koha/tools/koha-news.pl?op=add_form">New</a>
188                         [% END %]
189                     </p>
190                 </div>
191             [% END %]
192         </div><!-- /koha-news -->
193     [% END %]
194     </div>
195     </div>
196 </div>
197
198 <!-- the main div is closed in intranet-bottom.inc -->
199 [% INCLUDE 'intranet-bottom.inc' %]