Bug 23590: (QA follow-up) Fix some problems created by recent changes and updatedatab...
authorKatrin Fischer <katrin.fischer.83@web.de>
Fri, 31 Jan 2020 21:18:29 +0000 (21:18 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Wed, 25 Mar 2020 09:35:24 +0000 (09:35 +0000)
- Ensure that the sequence of columns will be the same for new
  and updated installations (add AFTER ...)
- Fix permissions (see bug 22868)
- Fix column configuration (see 16784)
- Remove '- ' displying before the date

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

admin/columns_settings.yml
installer/data/mysql/atomicupdate/bug_23590.perl
koha-tmpl/intranet-tmpl/prog/en/modules/common/patron_search.tt
koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt
suggestion/add_user_search.pl

index 282d929..08ea52b 100644 (file)
@@ -127,6 +127,10 @@ modules:
         -
           columnname: managed_on
         -
+          columnname: lastmodificationby
+        -
+          columnname: lastmodificationdate
+        -
           columnname: library
         -
           columnname: library_fund
index cb6d48d..d71862f 100644 (file)
@@ -11,7 +11,7 @@ if( CheckVersion( $DBversion ) ) {
     }
     if( !column_exists( 'suggestions', 'lastmodificationdate' ) ) {
         $dbh->do(q|
-            ALTER TABLE suggestions ADD COLUMN lastmodificationdate DATE DEFAULT NULL
+            ALTER TABLE suggestions ADD COLUMN lastmodificationdate DATE DEFAULT NULL AFTER lastmodificationby
         |);
     }
 
index 19cd0ab..f8dcf45 100644 (file)
                     [% ELSIF patrons_with_suggestion_perm_only %]
                     ,{
                         'name': 'has_permission',
-                        'value': 'acquisition.suggestions_manage',
+                        'value': 'suggestions.suggestions_manage',
                     }
                     [% END %]
                     );
index f55c90f..ba1b10c 100644 (file)
                     <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% suggestions_loo.lastmodificationby | uri %]">[% suggestions_loo.surnamelastmodificationby | html %][% IF ( suggestions_loo.firstnamelastmodificationby ) %], [% suggestions_loo.firstnamelastmodificationby | html %][% END %]</a>
                 </td>
                 <td data-order="[% suggestions_loo.lastmodificationdate | html %]">
-                    [% IF ( suggestions_loo.lastmodificationdate ) %] - [% suggestions_loo.lastmodificationdate | $KohaDates %][% END %]
+                    [% IF ( suggestions_loo.lastmodificationdate ) %][% suggestions_loo.lastmodificationdate | $KohaDates %][% END %]
                 </td>
                 <td>
                     [% Branches.GetName( suggestions_loo.branchcode ) | html %]
index 290f80d..2501447 100755 (executable)
@@ -33,7 +33,7 @@ my ( $template, $loggedinuser, $cookie, $staff_flags ) = get_template_and_user(
         query           => $input,
         type            => "intranet",
         authnotrequired => 0,
-        flagsrequired   => { acquisition => 'suggestions_manage' },
+        flagsrequired   => { suggestions => 'suggestions_manage' },
     }
 );