]> git.evergreen-ils.org Git - working/Evergreen.git/blob - docs/TechRef/KidsOPAC.txt
LP1288938 - stamping upgrade script
[working/Evergreen.git] / docs / TechRef / KidsOPAC.txt
1 Kid's OPAC
2 ==========
3
4 Configuration
5 -------------
6
7 Apache
8 ~~~~~~
9
10 [source, bash]
11 ------------------------------------------------------------------------------
12 <Location /eg/kpac>
13     PerlSetVar OILSWebContextLoader "OpenILS::WWW::EGKPacLoader"
14     PerlSetVar KPacConfigFile "/openils/conf/kpac.xml.example"
15 </Location>
16 ------------------------------------------------------------------------------
17
18 XML Configuration File
19 ~~~~~~~~~~~~~~~~~~~~~~
20
21     * The XML configuration file defines the layout of the kid's OPAC.
22     * It is read with each restart/reload of the Apache web server.
23     * The file lives by default at /openils/conf/kpac.xml.example
24     * There are two top-level elements: <pages> and <layout>.
25     * The layout defines the owning org unit and the start page, both by ID.
26     * At runtime, the layout is determined by the context org unit.  If no 
27       configuration is defined for the context org unit, the layout for the 
28       closest ancestor is used.
29
30 [source, xml]
31 ------------------------------------------------------------------------------
32 <layout owner="1" page="1"/>
33 ------------------------------------------------------------------------------
34
35     * The pages section is a container for <page> elements.
36     * Each page defines an ID, the number of columns to display for the page, 
37       the page name, and an icon.
38
39 [source, xml]
40 ------------------------------------------------------------------------------
41 <page id="1" columns="5" name="Home" img="/images/home.jpg">
42 ------------------------------------------------------------------------------
43
44     * Each page is a container of cells
45     * Each cell defines
46         ** type (topic, search, link)
47         ** name
48         ** icon
49         ** content
50     * The content for type="topic" cells is the ID of the page this topic
51       jumps to.  The name and img for the referenced page is used as the 
52       display content.
53
54 [source, xml]
55 ------------------------------------------------------------------------------
56 <cell type="topic">12</cell>
57 ------------------------------------------------------------------------------
58
59     * The content for type="search" cells is the search query.  The name and 
60       img are used for the display content.
61
62 [source, xml]
63 ------------------------------------------------------------------------------
64 <cell name="Piano" img="category.png" type="search">su:piano</cell>
65 ------------------------------------------------------------------------------
66
67     * The content for type="link" cells is the URL.  The name and img are used 
68     for the display content.
69
70 [source, xml]
71 ------------------------------------------------------------------------------
72 <cell name="Clarinet" img="category.png" 
73     type="link">http://en.wikipedia.org/wiki/Clarinet</cell>
74 ------------------------------------------------------------------------------
75
76
77 Considerations for Community Adoption
78 -------------------------------------
79
80 The templates for the Kid's OPAC were developed long before the TPAC was 
81 integrated into Evergreen and it has many of the same limitations that 
82 were part of the TPAC.  
83
84     * Fixed width elements (divs, images, etc.), which complicates the 
85       addition of new features and local customizations.  
86     * Images with text, which prevents l10n/i18n.
87     * While the KPAC does not attempt to match the color scheme of any one
88       institution, it's inconsistent with the standard Evergreen color 
89       palette.  Creating an additional skin to act as the Evergreen default
90       my be necessary.
91
92 Outstanding Development (Unsponsored)
93 -------------------------------------
94
95     ** Port the XML configuration file to a DB structure, complete with UI for
96        managing the various components and upgrade path.
97