From 1fee552beadbe614665281f2094000629334f88a Mon Sep 17 00:00:00 2001 From: dnmeid Date: Mon, 16 Sep 2002 09:10:26 +0000 Subject: [PATCH] Initial revision --- .../intranet-tmpl/default/en/boraccount.tmpl | 57 +++++ .../en/catalogue/cmsdsearchresults.tmpl | 29 +++ .../default/en/catalogue/searchresults.tmpl | 27 +++ .../intranet-tmpl/default/en/charges.tmpl | 32 +++ koha-tmpl/intranet-tmpl/default/en/cmsd.tmpl | 33 +++ .../intranet-tmpl/default/en/default.tmpl | 28 +++ .../default/en/imemberentry.tmpl | 156 +++++++++++++ .../default/en/jmemberentry.tmpl | 128 +++++++++++ .../intranet-tmpl/default/en/member.tmpl | 52 +++++ .../intranet-tmpl/default/en/memberentry.tmpl | 207 ++++++++++++++++++ .../intranet-tmpl/default/en/newimember.tmpl | 30 +++ .../default/en/searchheader.tmpl | 2 + koha-tmpl/templates.readme | 76 +++++++ 13 files changed, 857 insertions(+) create mode 100644 koha-tmpl/intranet-tmpl/default/en/boraccount.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/catalogue/cmsdsearchresults.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/catalogue/searchresults.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/charges.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/cmsd.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/default.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/imemberentry.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/jmemberentry.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/member.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/memberentry.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/newimember.tmpl create mode 100644 koha-tmpl/intranet-tmpl/default/en/searchheader.tmpl create mode 100644 koha-tmpl/templates.readme diff --git a/koha-tmpl/intranet-tmpl/default/en/boraccount.tmpl b/koha-tmpl/intranet-tmpl/default/en/boraccount.tmpl new file mode 100644 index 0000000000..6078f0f258 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/boraccount.tmpl @@ -0,0 +1,57 @@ + + + + + + + + +Account for

+ +  + +

+

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FINES & CHARGESAMOUNTSTILL OWING
Total Due
+ +
+

 

+ + + + + + + + diff --git a/koha-tmpl/intranet-tmpl/default/en/catalogue/cmsdsearchresults.tmpl b/koha-tmpl/intranet-tmpl/default/en/catalogue/cmsdsearchresults.tmpl new file mode 100644 index 0000000000..62650ba124 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/catalogue/cmsdsearchresults.tmpl @@ -0,0 +1,29 @@ + +Search Results + + + + + + + + + + + + + +
TitleAuthorDewey
+ + +
+ &startfrom=>Previous Records + + &startfrom=>Next Records +
+
+
+Results through of records. +
+ + diff --git a/koha-tmpl/intranet-tmpl/default/en/catalogue/searchresults.tmpl b/koha-tmpl/intranet-tmpl/default/en/catalogue/searchresults.tmpl new file mode 100644 index 0000000000..8a3e3dfecd --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/catalogue/searchresults.tmpl @@ -0,0 +1,27 @@ + + + + + + + + + + + + + +
TitleAuthorItem CountBiblionumber
+ + +
+ &startfrom=>Previous Records + + &startfrom=>Next Records +
+
+
+Results through of records. +
+ + diff --git a/koha-tmpl/intranet-tmpl/default/en/charges.tmpl b/koha-tmpl/intranet-tmpl/default/en/charges.tmpl new file mode 100644 index 0000000000..4b81b66fef --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/charges.tmpl @@ -0,0 +1,32 @@ + + + + +

+Each box needs to be filled in with fine,time to start charging,charging cycle
+eg 1,7,7 = $1 fine, after 7 days, every 7 days.

+ + + + + + + + + + + + + + + + +
+ + + + + + + + \ No newline at end of file diff --git a/koha-tmpl/intranet-tmpl/default/en/cmsd.tmpl b/koha-tmpl/intranet-tmpl/default/en/cmsd.tmpl new file mode 100644 index 0000000000..723f5250f1 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/cmsd.tmpl @@ -0,0 +1,33 @@ + + + +

+ + + + + + + + + + + + + + + + +
TitleAuthorDewey
>>
+ + +
+ &startfrom=>Previous Records + + &startfrom=>Next Records +
+
+
+Results through of records. +
+ diff --git a/koha-tmpl/intranet-tmpl/default/en/default.tmpl b/koha-tmpl/intranet-tmpl/default/en/default.tmpl new file mode 100644 index 0000000000..8b50b016ec --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/default.tmpl @@ -0,0 +1,28 @@ + +
+ + + + + + + + + + + + + +
TitleAuthorItem CountBiblionumber
>
+ + +
+ &startfrom=>Previous Records + + &startfrom=>Next Records +
+
+
+Results through of records. +
+ diff --git a/koha-tmpl/intranet-tmpl/default/en/imemberentry.tmpl b/koha-tmpl/intranet-tmpl/default/en/imemberentry.tmpl new file mode 100644 index 0000000000..1733984903 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/imemberentry.tmpl @@ -0,0 +1,156 @@ + + + + + + + + +
+ +Add New Institution
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ Member# , Card Number* +
 
+ INSTITUTION DETAILS + +
Institution Name
 
+ INSTITUTION ADDRESS +
+ +
Postal Address*Town*Area
 
+ CONTACT DETAILS +
Contact Name*
Phone (day)FaxEmail
 
Notes
 
LIBRARY USE
 
Notes
+ +
+
+ +
+ +
+

 

+ + + + + \ No newline at end of file diff --git a/koha-tmpl/intranet-tmpl/default/en/jmemberentry.tmpl b/koha-tmpl/intranet-tmpl/default/en/jmemberentry.tmpl new file mode 100644 index 0000000000..995157aa5c --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/jmemberentry.tmpl @@ -0,0 +1,128 @@ + + + + + + + + +
+ +Add New Junior Member
+
+ + + + + + + + + + + + + + "> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ PARENT OR GUARDIAN
+ +
TitleGiven Names*Surname*Membership No.
 
+ CHILD +
+ Member# , Card Number* + + size=20 value="">
+ value=""> +
size=20 value=""> size=20 value=""> size=10 value=""> + F + M* + size=20 value="">
Given Names*Surname*Date of Birth
(dd/mm/yy)*
 School
Notes
 
+ +
+
+ + + + + + diff --git a/koha-tmpl/intranet-tmpl/default/en/member.tmpl b/koha-tmpl/intranet-tmpl/default/en/member.tmpl new file mode 100644 index 0000000000..5ea63d6f86 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/member.tmpl @@ -0,0 +1,52 @@ + + + + +Member Search
+ +
+ + +
+ +You Searched for

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CardSurnameFirstnameCategoryAddressOD/IssuesChargesNotes
+ +

+
+Adult +Organisation +
+ + + + + diff --git a/koha-tmpl/intranet-tmpl/default/en/memberentry.tmpl b/koha-tmpl/intranet-tmpl/default/en/memberentry.tmpl new file mode 100644 index 0000000000..4973cbbe2e --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/memberentry.tmpl @@ -0,0 +1,207 @@ + + + + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Member# , Card Number*
MEMBER PERSONAL DETAILS* + checked>F + checked>M +     Date of Birth (dd/mm/yy) + +
+ +
TitleInitialsGiven Names*Surname*Prefered Name
 
+ +  
EthnicityEthnicity Notes  Membership Category*
 
MEMBER ADDRESS
+ +
Postal Address*Town*Area
 
Street Address if differentTown
 
MEMBER CONTACT DETAILS
Phone (Home)Phone (day)FaxEmail
 
ALTERNATE CONTACT DETAILS
+ +
Name*PhoneRelationship*
 
Notes
 
LIBRARY USE
Notes
 
FLAGS
Yes + No +
+
+ + + + + \ No newline at end of file diff --git a/koha-tmpl/intranet-tmpl/default/en/newimember.tmpl b/koha-tmpl/intranet-tmpl/default/en/newimember.tmpl new file mode 100644 index 0000000000..7062bd2275 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/newimember.tmpl @@ -0,0 +1,30 @@ + + + + + + The following compulsary fields have been left blank. Please push the back button and try again.

+

    + +
  • + +

+ + + +Invalid cardnumber.

+ + + +

+ + + + +
+
+ + + + + diff --git a/koha-tmpl/intranet-tmpl/default/en/searchheader.tmpl b/koha-tmpl/intranet-tmpl/default/en/searchheader.tmpl new file mode 100644 index 0000000000..1380160342 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/default/en/searchheader.tmpl @@ -0,0 +1,2 @@ +>Results with dewey | >Results with biblionumber +
diff --git a/koha-tmpl/templates.readme b/koha-tmpl/templates.readme new file mode 100644 index 0000000000..ad5c96ea5d --- /dev/null +++ b/koha-tmpl/templates.readme @@ -0,0 +1,76 @@ +This is a README-file for all interested in the templating system used by Koha. +It contains guidelines ans descriptions, please feel free to make comments and contributions to this file. + +1. Introduction + The advantage of a templating-system is the separation of code and design. + It is much easier to read the html and get an imagination of what it will look like without having it shattered by declarations and functions. + And it is also nicer being able to alter some functions without worrying about the webdesign. + On the other hand templating stands in contradiction on scripting the procedural way, it forces obect-oriented programming. + With templates Koha can be made fully skinnable, we speak of themes, and can support different languages. + +2. How does it work + The short version: Instead of printing html from your script you only define some template-parameters. + You design your html-page without code in it and where you need to insert data generated by the script you can pass this data from the template-parameters via special tags. + Indeed there is a little more to know. + I recomend reading the documentation to the HTML::Template-module. + You ca obtain it from http://www.perldoc.com/cpan/HTML/Template.html + +3. How is it implemented in Koha + Koha uses templates to handle different themes and languages. + There is a CVS-module for the design-files: koha-tmpl. + It contains two directories for the opac- and the intranet-templates: opac-tmpl and intranet-tmpl. + Each of this directories reflects the available themes and their languages. + The default theme is "default" and the default language is "en" (we use the 2letter-abbreviations, en => english, fr => french, de => german and so on). + If you for example want to write a template for the opac part of the "custommade"-theme in polish it has to go in koha-tmpl/opac-tmpl/custommade/pl/template.tmpl. + The template-files will not reside in your webtree, if you want to use a image you have to put this in your webtree, which is organized the same way as the templatetree (koha-html/opac-html/custommade/pl/images/image.gif). + If you have files (either templates or files in the webspace) which are the same for all themes or languages use the "all"-directory. For example the "background.jpg"-image, which is the same for all languages within a theme should go in koha-html/(intranet|opac)-html/custommade/all/images/background.jpg). + +4. How to use it + Simply add an entry to the systempreferences: name=theme, value=nameoftheme. + If you want your users be able to override your theme-settings enter name=allowthemeoverride value=customtheme1,customtheme2,... (names of themes you want to be allowed) to the preferences. + For the language you normally don't have to enter anything, the preferences of the user's browser will be used. + If anything is wrong you can specify a languageorder with the following entry: name=languageorder value=en,fr,de,es (or whatever comma-separated languages you want) + If you want to specify a directory for the templates you can do so in koha.conf with 'templatedirectory=younameit'. + +5. Rules and hints + 5.1 for the templates + -use absolut paths, relative paths in html-tags would be relative to the script's position and relative paths in would be relative to the template. + -you don't have to make templates for everything in your custom-theme or language. if you omit a template in a language the template of next available language is used (languages are tried in the order of the user's browser-settings). + if there is no template in the specified language in a theme a different language will be chosen and NOT a different theme. + if you omit a template in all languages the template of the default-theme will be used. + -include comments with useful information such as the template's location, this simplifies debugging + -use the same name for the template and the script (with different extensions of course) + 5.2 for the scripts + -use meaningfull english (abbreviations) as parameter-names + -if you fetch a list of data, pass it completely and let the designer decide which data to use. + -working with arrays and loops is always better, even if you have only three similar rows. + -don't let the script generate html and pass the output to the template + +6. Templating stuff in Koha + This section is to describe scripts, modules and functions within them to handle with themes, languages and other templating stuff. + If you write something which matches this, please add a brief description here (e.g. function calls and return values). + -function %path = pathtotemplate(%hash) in C4::Output + Takes a hash with the following keys: + -template: the name of the template-file (e.g. 'mytemplate.tmpl') + -type: 'opac', 'intranet', 'none' or something you specify, decides which directory to lookup, defaults to intranet + -'opac': /somedirs/opac-tmpl/theme/language/template.tmpl + -'interanet': /somedirs/intranet-tmpl/theme/language/template.tmpl + -'none': /somedirs/theme/language/template.tmpl + -'my own words': /somedirs/my own words/theme/language/template.tmpl + somedirs is 1. the path-parameter if specified 2. the templatedirectory in koha.conf, 3. the includes + '/templates', 4. the includes + -theme: you can manually set a theme (e.g. 'customtheme') only if 'allowthemeoverride' in systempreferences is set + -language: you can manually set a language (e.g. 'es') + -path: you can manually set the path to search for templates (e.g. '/usr/koha/sometesttemplates') + You only need to pass the last three parameters if you want to override the preferences for some reasons + Returns: + - $path{'path'}: the complete+absolute path of the template (e.g. '/somedirs.../opac-tmpl/customtheme/es/mytemplate.tmpl') + - $path{'fondlanguage'}: '1' if the requested template was available in the requested language + - $path{'fondtheme'}: '1' if the requested template was available in the requested theme + +7. Links + Do you have good links for the templater? + The HTML::Template documentation: http://www.perldoc.com/cpan/HTML/Template.html + + +Comments to dnmeid@gmx.de +Dorian \ No newline at end of file -- 2.39.5