koha-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Koha-cvs] koha installer/install.pl koha-tmpl/intranet-tm... [rel_3_0]


From: Henri-Damien LAURENT
Subject: [Koha-cvs] koha installer/install.pl koha-tmpl/intranet-tm... [rel_3_0]
Date: Fri, 09 Feb 2007 21:10:49 +0000

CVSROOT:        /cvsroot/koha
Module name:    koha
Branch:         rel_3_0
Changes by:     Henri-Damien LAURENT <hdl>      07/02/09 21:10:49

Modified files:
        installer      : install.pl 
Added files:
        koha-tmpl/intranet-tmpl/prog/en/installer: step1.tmpl step2.tmpl 
                                                   step3.tmpl 

Log message:
        + Adding a script to list ALL modules used in Koha Scripts and provide 
user with a list of the scripts using these modules.
        + kohastructure.sql is the structure of my database for koha3.0 (could 
be used as a ground before update.)
        + list of language as ISO-639-2
        + Adding a new InstallAuth.pm which should only be used for install. 
Since I could not suppose that there was a database, this authentication could 
not match with a borrower. It still relies on cookies but Only super 
superlibrarian (the one described in koha.xml) can acheive this.
        Adding Web Installer 3 steps :
        step 1: checking database exists and access (table creation insert....)
        Step 2: checking database structure and updating database if need be.
        Step 3: importing datasets which are supposed to be in 
misc/sql-datas/<language>/<level>
        where <language> is international abbreviation of a language.
        and <level> is to qualify the criticity of the import :
        required : necessary for Koha to work.
        recommended : very helpful.
        additionals : would be to "ease the pain" in configuring Koha.
        each <level> directory contains a list of sql files which have 
meaningful names. and the same list txt files which contains a little 
description in the <language> to explain what sql file is aimed at.
        This can be VERY helpfull if we put there some normalised data such as 
position authorised values, code5 authorised value, frameworks, language 
authorised value list, CDU or CDD description, depending on which one is 
"free"... 
        We still can go further :
        - We could allow people to get only subsets of international normalised 
set of datas.
        - this installer doesnot help people in creating their zebra 
configuration files. But this would be a BIG tricky part.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/installer/install.pl?cvsroot=koha&only_with_tag=rel_3_0&r1=1.1.2.1&r2=1.1.2.2
http://cvs.savannah.gnu.org/viewcvs/koha/koha-tmpl/intranet-tmpl/prog/en/installer/step1.tmpl?cvsroot=koha&only_with_tag=rel_3_0&rev=1.1.2.1
http://cvs.savannah.gnu.org/viewcvs/koha/koha-tmpl/intranet-tmpl/prog/en/installer/step2.tmpl?cvsroot=koha&only_with_tag=rel_3_0&rev=1.1.2.1
http://cvs.savannah.gnu.org/viewcvs/koha/koha-tmpl/intranet-tmpl/prog/en/installer/step3.tmpl?cvsroot=koha&only_with_tag=rel_3_0&rev=1.1.2.1

Patches:
Index: installer/install.pl
===================================================================
RCS file: /cvsroot/koha/koha/installer/Attic/install.pl,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -u -b -r1.1.2.1 -r1.1.2.2
--- installer/install.pl        9 Feb 2007 21:04:17 -0000       1.1.2.1
+++ installer/install.pl        9 Feb 2007 21:10:49 -0000       1.1.2.2
@@ -31,7 +31,7 @@
   setlanguagecookie($query,$language,"install.pl?step=1");
 }
 ($template, $loggedinuser, $cookie)
-        = get_template_and_user({template_name => 
"install/step".($step?$step:1).".tmpl",
+        = get_template_and_user({template_name => 
"installer/step".($step?$step:1).".tmpl",
                 query => $query,
                 type => "intranet",
                 authnotrequired => 0,

Index: koha-tmpl/intranet-tmpl/prog/en/installer/step1.tmpl
===================================================================
RCS file: koha-tmpl/intranet-tmpl/prog/en/installer/step1.tmpl
diff -N koha-tmpl/intranet-tmpl/prog/en/installer/step1.tmpl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ koha-tmpl/intranet-tmpl/prog/en/installer/step1.tmpl        9 Feb 2007 
21:10:49 -0000       1.1.2.1
@@ -0,0 +1,93 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+
+  <meta content="text/html; charset=UTF-8" http-equiv="content-type">
+  <title>Koha Installer</title>
+
+
+</head>
+<body>
+
+<h1>Welcome to Koha Installer</h1>
+
+<!--TMPL_UNLESS Name="language"-->
+<p>You are about to install Koha.</p>
+<form name="language" method="POST">
+<p>Pick up your language :<br />
+
+<select name="language">
+  <!--TMPL_LOOP Name="languages"-->
+  <option value="<!--TMPL_VAR Name="value" -->""><!--TMPL_VAR 
Name="description"-->
+<!--   </option> -->
+  <!--/TMPL_LOOP -->
+</select>
+</p>
+
+<p> And click Next to continue <input value="Next &gt;&gt;" type="submit"></p>
+</form>
+<!--/TMPL_UNLESS-->
+<!--TMPL_IF Name="language"-->
+  <!--TMPL_UNLESS Name="checkmodule"-->
+  <!--TMPL_IF Name="missing"-->
+  <p>Some perl modules are missing.<br />
+  <ul>
+  <!--TMPL_LOOP Name="missing"-->
+    <li><!--TMPL_VAR Name="name"-->
+    <!--TMPL_IF Name="usagemail"-->
+      <br/> This module is used whenever Koha has to send a mail.
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="usagebarcode"-->
+      <br/> This module is needed if you intend to print barcodes.
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="usagespine"-->
+      <br/> This module is needed if you intend to print spine labels.
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="usageLDAP"-->
+      <br/> This module is needed if you intend to use LDAP connexions.
+    <!--/TMPL_IF-->
+    </li>
+  <!--/TMPL_LOOP-->
+  Please consider installing them using these commands before getting further.
+  <pre>
+  <!--TMPL_LOOP Name="missing"-->
+    perl -MCPAN -e "install <!--TMPL_VAR Name="name"-->";
+  <!--/TMPL_LOOP-->
+  </pre>
+  <!--/TMPL_IF-->
+  <!--TMPL_IF Name="problems"-->
+  <p>Some problems occured.<br />
+    <!--TMPL_IF Name="perlversion"-->
+      <p>Your perl version seems to be obsolete.<br />
+      Consider upgrading</p>
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="perllocation"-->
+      <p>Your perl installation is not in /usr/bin/.<br />
+      You may have problems.</p>
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="zebra"-->
+      <p>Zebra server doesnot seem to be installed.<br />
+      Please consider installing it before getting further.</p>
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="mysql"-->
+      <p>Mysql server doesnot seem to be installed.<br />
+      Please consider installing it before getting further.</p>
+    <!--/TMPL_IF-->
+    <!--TMPL_IF Name="yaz"-->
+      <p>YAZ doesnot seem to be installed.<br />
+      It is required for research.<br />
+      Please consider installing it before getting further.</p>
+    <!--/TMPL_IF-->
+  <!--/TMPL_IF-->
+  <!--/TMPL_UNLESS-->
+  <!--TMPL_IF Name="checkmodule"-->
+<form name="checkmodules" action="install.pl">
+<p> All Modules and third-party softwares installed OK
+</p>
+<input type="hidden" name="step" value="2" />
+<p> Click next to continue<input value="Next &gt;&gt;" type="submit"></p>
+</form>
+  <!--/TMPL_IF-->
+<!--/TMPL_IF-->
+</body>
+</html>

Index: koha-tmpl/intranet-tmpl/prog/en/installer/step2.tmpl
===================================================================
RCS file: koha-tmpl/intranet-tmpl/prog/en/installer/step2.tmpl
diff -N koha-tmpl/intranet-tmpl/prog/en/installer/step2.tmpl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ koha-tmpl/intranet-tmpl/prog/en/installer/step2.tmpl        9 Feb 2007 
21:10:49 -0000       1.1.2.1
@@ -0,0 +1,73 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+
+  <meta content="text/html; charset=UTF-8" http-equiv="content-type">
+  <title>Koha Installer</title>
+
+
+</head>
+<body>
+<style type="text/css">
+#bloc25, .bloc25 {
+       float:left;
+       border:1px solid #000000;
+       margin:0px;
+       padding:0px;
+}
+</style>
+<h1>Welcome to Koha Installer</h1>
+
+<div id="bloc25"><h2 align="center">Mysql connection information</h2>
+<p>
+<em>database name : </em><!--TMPL_VAR Name="dbname"-->
+</p>
+<p>
+<em>database host : </em><!--TMPL_VAR Name="hostname"-->
+</p>
+<p>
+<em>database port : </em><!--TMPL_VAR Name="port"-->
+</p>
+<p>
+<em>database user : </em><!--TMPL_VAR Name="user"-->
+</p>
+</div>
+<div id="bloc25">
+<!--TMPL_IF Name="mysqlconnection"-->
+<form name="checkmysqlparameters" type="POST" action="install.pl">
+  <!--TMPL_IF Name="checkdatabaseaccess"-->
+  <p>Can Connect OK</p>
+     <!--TMPL_IF Name="checkdatabasecreated"-->
+  <p>database <!--TMPL_VAR Name="dbname"--> created OK</p>
+        <!--TMPL_IF Name="checkgrantaccess"-->
+  <p>user <!--TMPL_VAR Name="user"--> has all required privileges on database 
<!--TMPL_VAR Name="dbname"--> OK</p>
+        <!--TMPL_ELSE-->
+  <p class="error">user <!--TMPL_VAR Name="user"--> doesnot have enough 
privilege on database <!--TMPL_VAR Name="dbname"--> </p>
+  <p class="tip"> Ask for or make a change in user privileges <br />see <a 
href=http://dev.mysql.com/doc/refman/4.1/en/grant.html>this page</a> and ask 
for usage insert update delete drop and create access for user <!--TMPL_VAR 
Name="user"-->  on <!--TMPL_VAR Name="dbname"--></p>
+        <!--/TMPL_IF-->
+      <!--TMPL_ELSE-->
+  <p class="error">No database <!--TMPL_VAR Name="dbname"--> detected on 
system</p>
+  <p class="tip">Ask for or create Database in mysql database management 
system</p>
+      <!--/TMPL_IF-->
+   <!--TMPL_ELSE-->
+    <div class="error"><!--TMPL_VAR name="error"--> : <!--TMPL_VAR 
Name="message"-->
+    </div>
+    <div class="tip">Problem can come out from various reasons :
+      <ul><li> Check mysql server is up and running.</li>
+      <li>Check data entered in koha.xml </li>
+      <li>Check hostname in koha.xml.<br /> Some Linux mysql servers donot use 
localhost but ip adress :127.0.0.1</li>
+      </div>
+  <!--/TMPL_IF-->
+<input type="hidden" name="step" value="3" />
+<p> Click Next to continue <input value="Next &gt;&gt;" type="submit"></p>
+</form>
+<!--TMPL_ELSE-->
+<form name="checkinformation" type="POST" action="install.pl">
+<input type="hidden" name="step" value="2" />
+<input type="hidden" name="checkmysql" value="1" />
+<p> Click Next to continue if information are valid <input value="Next 
&gt;&gt;" type="submit"></p>
+</form>
+<!--/TMPL_IF-->
+</div>
+</body>
+</html>

Index: koha-tmpl/intranet-tmpl/prog/en/installer/step3.tmpl
===================================================================
RCS file: koha-tmpl/intranet-tmpl/prog/en/installer/step3.tmpl
diff -N koha-tmpl/intranet-tmpl/prog/en/installer/step3.tmpl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ koha-tmpl/intranet-tmpl/prog/en/installer/step3.tmpl        9 Feb 2007 
21:10:49 -0000       1.1.2.1
@@ -0,0 +1,177 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+
+  <meta content="text/html; charset=UTF-8" http-equiv="content-type">
+  <title>Koha Installer</title>
+
+
+<!--TMPL_IF Name="selectframeworks"-->
+<script language="JavaScript">
+<!--
+
+var sURL = unescape(window.location.pathname);
+
+function doLoad()
+{
+    // the timeout value should be the same as in the "refresh" meta-tag
+    setTimeout( "refresh()", 2*1000 );
+}
+
+function refresh(value)
+{
+    //  This version of the refresh function will cause a new
+    //  entry in the visitor's history.  It is provided for
+    //  those browsers that only support JavaScript 1.0.
+    //
+    sURL=sURL+'?step=3&op=selectframeworks&fwklanguage='+value;
+    window.location.href = sURL;
+}
+
+//-->
+</script>
+
+<script language="JavaScript1.1">
+<!--
+function refresh(value)
+{
+    //  This version does NOT cause an entry in the browser's
+    //  page view history.  Most browsers will always retrieve
+    //  the document from the web-server whether it is already
+    //  in the browsers page-cache or not.
+    //  
+    sURL=sURL+'?step=3&op=selectframeworks&fwklanguage='+value;
+    window.location.replace( sURL );
+}
+//-->
+</script>
+
+<script language="JavaScript1.2">
+<!--
+function refresh(value)
+{
+    //  This version of the refresh function will be invoked
+    //  for browsers that support JavaScript version 1.2
+    //
+    
+    //  The argument to the location.reload function determines
+    //  if the browser should retrieve the document from the
+    //  web-server.  In our example all we need to do is cause
+    //  the JavaScript block in the document body to be
+    //  re-evaluated.  If we needed to pull the document from
+    //  the web-server again (such as where the document contents
+    //  change dynamically) we would pass the argument as 'true'.
+    //  
+    sURL=sURL+'?step=3&op=selectframeworks&fwklanguage='+value;
+    window.location.replace( sURL );
+}
+//-->
+</script>
+</head>
+<body>
+<script language="JavaScript">
+function Hide(link) {
+       subfield = document.getElementById('bloc'+link);
+    var initstyle=subfield.style.display;
+       if (initstyle == 'block') subfield.style.display = 'none' ;
+       if (initstyle == 'none') subfield.style.display = 'block' ;
+}
+</script>
+<!--/TMPL_IF-->
+<style type="text/css">
+#bloc25, .bloc25 {
+       float:left;
+       border:1px solid #000000;
+       margin:0px;
+       padding:0px;
+}
+</style>
+<h1>Welcome to Koha Installer</h1>
+
+<!--TMPL_IF Name="selectframeworks"-->
+  <h2 align="center">Select Dataset</h2>
+  <form name="frameworkselection" method="POST" action="install.pl">
+  <input type="hidden" name="step" value="3" />
+  <input type="hidden" name="op" value="addframeworks" />
+  <p>Select Language first :</p>
+  <p><select name="fwklanguage" onchange="javascript:refresh(this.value)">
+  <!--TMPL_LOOP Name="languagelist" -->
+  <!--TMPL_IF Name="checked"--><option value="<!--TMPL_VAR Name="dirname"-->" 
selected ><!--TMPL_VAR Name="languagedescription"--></option>
+  <!--TMPL_ELSE--><option value="<!--TMPL_VAR Name="dirname"-->"><!--TMPL_VAR 
Name="languagedescription"--></option>
+  <!--/TMPL_IF-->
+  <!--/TMPL_LOOP-->
+  </select>
+  </p>
+  <p><!--TMPL_LOOP Name="levelloop"-->
+  <a id="link<!--TMPL_VAR Name="code"-->" style="color: grey; font-size: 80%; 
cursor: se-resize;"  onclick="Hide('<!--TMPL_VAR Name="code"-->')">
+  <!--TMPL_VAR Name="label"--></a>
+  <!--/TMPL_LOOP-->
+  </p>
+  <p>
+  <!--TMPL_LOOP Name="levelloop"-->
+  <div id="bloc<!--TMPL_VAR Name="code"-->" style="display:none" 
class="bloc25">
+  <h3><!--TMPL_VAR Name="label"--></h3>
+  <!--TMPL_LOOP Name="frameworks"-->
+    <p><em><!--TMPL_VAR Name="fwkname"--></em>
+    <!--TMPL_IF Name="mandatory"--><input type="checkbox" Name="framework" 
value="<!--TMPL_VAR Name="fwkfile"-->" checked />
+    <!--TMPl_ELSE--><input type="checkbox" Name="framework" 
value="<!--TMPL_VAR Name="fwkfile"-->" />
+    <!--/TMPL_IF--><br />
+    <!--TMPL_VAR Name="fwkdescription"-->
+    </p>
+  <!--/TMPL_LOOP-->
+  </div>
+  </p>
+  <!--/TMPL_LOOP-->
+  <p><input type="submit" value="import" />
+  </p>
+  </form>
+  </p>
+<!--/TMPL_IF-->
+<!--TMPL_IF Name="addframeworks"-->
+  <h2 align="center">Data added</h2>
+  <p>Language :<!--TMPL_VAR Name="fwklanguage"--></p>
+  <!--TMPL_LOOP Name="list"-->
+  <h3> <!--TMPL_VAR Name="level"--></h3>
+  <p>
+  <ul>
+  <!--TMPL_LOOP Name="fwklist"-->
+    <li><!--TMPL_VAR Name="fwkname"--><!--TMPL_IF Name="error"--><br /><font 
color="red"><b></b><!--TMPL_VAR Name="error"--></font><!--/TMPL_IF--> </li>
+  <!--/TMPL_LOOP-->
+  </ul>
+  </p>
+  <!--/TMPL_LOOP-->
+  <p>Installation complete.<br/>
+    <p>Click on Finish to close the process, change access lists so that these 
operations are unreachable, and get to Koha Interface.
+    <form name="finish">
+    <input type="hidden" name="step" value="3" />
+    <input type="hidden" name="op" value="finish" />
+    <input type="submit" value="Finish" /></form>
+    </p>
+  </p>
+<!--/TMPL_IF-->
+<!--TMPL_IF Name="proposeimport"-->
+  <div id="bloc25"><h2 align="center">Import the database structure ?</h2>
+<a href="install.pl?step=3&amp;op=importdatastructure" 
class="button">Import</a>
+  </div>
+<!--/TMPL_IF-->
+<!--TMPL_IF Name="default"-->
+  <div id="bloc25"><h2 align="center">Update</h2>
+  <p>Database structure OK</p>
+<a href="install.pl?step=3&amp;op=updatestructure" class="button">update</a><a 
href="install.pl?step=3&amp;op=selectframeworks" class="button">Skip to 
datasets Import</a>
+  </div>
+<!--/TMPL_IF-->
+<!--TMPL_IF Name="updatestructure"-->
+  <div id="bloc25"><h2 align="center">Updating Mysql database</h2>
+  <!--TMPL_IF Name="updatereport"-->
+    <p>Update report :</p>
+    <p>
+    <!--TMPL_VAR Name="updatereport"-->
+    </p>
+  <!--TMPL_ELSE-->
+    <p>Everything went OK.</p>
+  <!--/TMPL_IF-->
+<a href="install.pl?step=3&amp;op=selectframeworks" class="button">Nex Step is 
Framework Selection</a>
+  </div>
+<!--/TMPL_IF-->
+</body>
+</html>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]