From 70173f8b1f5a776b0d385fa368957138d04e2e5c Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Thu, 15 Nov 2018 13:39:33 +0000 Subject: [PATCH] Bug 21838: Wrong alignment of instructors in course reserves This patch adds CSS to course reserve pages so that multiple instructors on a course are displayed well. To test, apply the patch and: - Add or edit a course. - Test adding and removing instructors, saving, and adding and removing again. - View a course with multiple instructors and confirm that they are displayed well. --- .../en/modules/course_reserves/course-details.tt | 19 ++++++++++++- .../prog/en/modules/course_reserves/course.tt | 32 +++++++++++++++------- 2 files changed, 40 insertions(+), 11 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt index c34d14e..931a355 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt @@ -10,6 +10,14 @@ [% INCLUDE 'doc-head-close.inc' %] [% Asset.css("css/datatables.css") | $raw %] + @@ -45,7 +53,16 @@
  • Department [% AuthorisedValues.GetByCode( 'DEPARTMENT', course.department ) | html %]
  • Course number [% course.course_number | html %]
  • Section [% course.section | html %]
  • -
  • Instructors [% FOREACH i IN course.instructors %][% END %]
  • +
  • + Instructors +
    + [% FOREACH i IN course.instructors %] + + [% END %] +
    +
  • Staff note [% course.staff_note | html %]
  • Public note [% course.public_note | html %]
  • Student count [% course.students_count | html %]
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course.tt index 91db22b..a47195d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course.tt @@ -2,6 +2,14 @@ [% INCLUDE 'doc-head-open.inc' %] Koha › Course reserves › [% IF course_name %] Edit [% course_name | html %] [% ELSE %] New course [% END %] [% INCLUDE 'doc-head-close.inc' %] + @@ -78,16 +86,20 @@
  • Instructors: -
    -
    [% FOREACH i IN instructors %]
    [% i.surname | html %], [% i.firstname | html %] ( Remove ) -
    [% END %]
    -
    - -
    - - +
    +
    + [% FOREACH i IN instructors %] +
    [% i.surname | html %], [% i.firstname | html %] ( Remove ) + +
    + [% END %] +
    +

    + + +

    -
    +
  • @@ -174,7 +186,7 @@ }); function AddInstructor( name, borrowernumber ) { - div = "
    " + name + " ( " + _("Remove")+ " )
    "; + div = "
    " + name + " ( " + _("Remove")+ " )
    "; $('#instructors').append( div ); $('#find_instructor').val('').focus(); -- 2.1.4