From 247153b2db27f556cf8fd1dc91883abb872dbfdf Mon Sep 17 00:00:00 2001 From: Mika Smith Date: Mon, 12 Dec 2016 22:16:40 +0000 Subject: [PATCH] Bug 17855 - Implemented basic and advanced setup modes in the web installer avalable on the MARC flavour selection page of step 3. The two setup modes change how the data installation page of step 3 looks: Basic setup displays all default data values with bulletpoints, and optional data values with a checkbox. Advanced setup displays default and optional data values with a checkbox. Conflicts: koha-tmpl/intranet-tmpl/prog/en/modules/installer/step3.tt --- installer/install.pl | 6 + .../prog/en/modules/installer/step3.tt | 183 +++++++++++---------- 2 files changed, 105 insertions(+), 84 deletions(-) diff --git a/installer/install.pl b/installer/install.pl index 512ca3c..17d01e9 100755 --- a/installer/install.pl +++ b/installer/install.pl @@ -199,6 +199,7 @@ elsif ( $step && $step == 3 ) { # The installer will have to relogin since we do not pass cookie to redirection. $template->param( "$op" => 1 ); } + elsif ( $op && $op eq 'addframeworks' ) { # # 1ST install, 3rd sub-step : insert the SQL files the user has selected @@ -250,6 +251,10 @@ elsif ( $step && $step == 3 ) { $template->param( "en_sample_data" => $sample_defaulted_to_en); $template->param( "levelloop" => $levellist ); $template->param( "$op" => 1 ); + + my $setup = $query->param('setup'); + $template->param( "setup"=> $setup ); + } elsif ( $op && $op eq 'choosemarc' ) { # @@ -270,6 +275,7 @@ elsif ( $step && $step == 3 ) { # But could also be useful to have some Authorised values data set prepared here. # Marcflavour Selection is achieved through radiobuttons. my $langchoice = $query->param('fwklanguage'); + $langchoice = $query->cookie('KohaOpacLanguage') unless ($langchoice); $langchoice =~ s/[^a-zA-Z_-]*//g; my $dir = diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/installer/step3.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/installer/step3.tt index a601443..e4e5d1a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/installer/step3.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/installer/step3.tt @@ -6,72 +6,85 @@ [% IF ( selectframeworks ) %] +function Hide(link) +{ + // Toggle the display of a given element on the page. + // + subfield = document.getElementById('bloc'+link); + var initstyle = subfield.style.display; + if (initstyle == 'block') subfield.style.display = 'none' ; + if (initstyle == 'none') subfield.style.display = 'block' ; +} + +//]]> + [% END %] + + [% IF ( finish ) %]

Congratulations, installation complete

If this page does not redirect in 5 seconds, click here.

[% END %] + + [% IF ( choosemarc ) %] -

Select your MARC flavor

-

MARC stands for Machine Readable Cataloging, containing information about a bibliographic record. MARC21 is more commonly used globally, whereas UNIMARC tends to be used in Europe.

+

Choose your setup

+

Basic setup selects recommended settings by default.

+ +
+ Basic
+ Advanced
+
+ +

Select your MARC flavor

+

MARC stands for Machine Readable Cataloging, containing information about a bibliographic record. MARC21 is more commonly used globally, whereas UNIMARC tends to be used in Europe.

+

[% FOREACH flavourloo IN flavourloop %]

@@ -82,13 +95,19 @@ [% END %]
[% END %] -

-

Click 'Next' to continue

+ +

+

Click 'Next' to continue

+
+ [% END %] + [% IF ( selectframeworks ) %] +

[% setup %] setup

Selecting Default Settings

+