[open-ils-commits] r11177 - in trunk/Open-ILS: examples web/css/skin web/js/ui/default web/js/ui/default/conify web/js/ui/default/conify/global web/js/ui/default/conify/global/config web/templates/default web/templates/default/conify web/templates/default/conify/global web/templates/default/conify/global/config

svn at svn.open-ils.org svn at svn.open-ils.org
Thu Nov 13 17:30:13 EST 2008


Author: erickson
Date: 2008-11-13 17:30:06 -0500 (Thu, 13 Nov 2008)
New Revision: 11177

Added:
   trunk/Open-ILS/web/js/ui/default/conify/
   trunk/Open-ILS/web/js/ui/default/conify/global/
   trunk/Open-ILS/web/js/ui/default/conify/global/config/
   trunk/Open-ILS/web/js/ui/default/conify/global/config/billing_type.js
   trunk/Open-ILS/web/templates/default/conify/
   trunk/Open-ILS/web/templates/default/conify/global/
   trunk/Open-ILS/web/templates/default/conify/global/config/
   trunk/Open-ILS/web/templates/default/conify/global/config/billing_type.tt2
Modified:
   trunk/Open-ILS/examples/oils_web.xml.example
   trunk/Open-ILS/web/css/skin/default.css
Log:

In the interest of moving into the TT hierarchy, I started a config interface for billing types.  
It's part of conify, but it's living where the rest of conify will (presumably) be migrated for 2.0.

Clearly, we need to have some discussion of how we want to lay out the dojo menu.

Also, assuming trunk/2.0 will use dojo 1.2, using new-style dojo grid



Modified: trunk/Open-ILS/examples/oils_web.xml.example
===================================================================
--- trunk/Open-ILS/examples/oils_web.xml.example	2008-11-13 22:08:29 UTC (rev 11176)
+++ trunk/Open-ILS/examples/oils_web.xml.example	2008-11-13 22:30:06 UTC (rev 11177)
@@ -31,5 +31,7 @@
         <handler path='acq/po/search' template='acq/po/search.tt2'/>
         <handler path='acq/receiving/process' template='acq/receiving/process.tt2'/>
         <handler path='acq/settings/li_attr' template='acq/settings/li_attr.tt2'/>
+
+        <handler path='conify/global/config/billing_type' template='conify/global/config/billing_type.tt2'/>
     </handlers>
 </oils_web>

Modified: trunk/Open-ILS/web/css/skin/default.css
===================================================================
--- trunk/Open-ILS/web/css/skin/default.css	2008-11-13 22:08:29 UTC (rev 11176)
+++ trunk/Open-ILS/web/css/skin/default.css	2008-11-13 22:30:06 UTC (rev 11177)
@@ -5,8 +5,11 @@
 @import "/js/dojo/dojo/resources/dojo.css";
 @import "/js/dojo/dijit/themes/tundra/tundra.css";
 @import "/js/dojo/dojox/grid/_grid/Grid.css";
+ at import "/js/dojo/dojox/grid/resources/Grid.css";
+ at import "/js/dojo/dojox/grid/resources/tundraGrid.css";
 
 
+
 html, body, #oils-base-body-block {
     width:100%;
     height:100%;

Added: trunk/Open-ILS/web/js/ui/default/conify/global/config/billing_type.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/conify/global/config/billing_type.js	                        (rev 0)
+++ trunk/Open-ILS/web/js/ui/default/conify/global/config/billing_type.js	2008-11-13 22:30:06 UTC (rev 11177)
@@ -0,0 +1,28 @@
+dojo.require('dojox.grid.DataGrid');
+dojo.require('dojo.data.ItemFileReadStore');
+dojo.require('fieldmapper.OrgUtils');
+
+var btContextOrg;
+var btList;
+
+function buildBTGrid() {
+    if(btContextOrg == null)
+       btContextOrg = openils.User.user.ws_ou();
+    fieldmapper.standardRequest(
+        ['open-ils.circ', 'open-ils.circ.billing_type.ranged.retrieve.all'],
+        {   async: true,
+            params: [openils.User.authtoken, btContextOrg, fieldmapper.aou.findOrgDepth(btContextOrg)],
+            oncomplete: function(r) {
+                if(btList = openils.Util.readResponse(r)) {
+                    var store = new dojo.data.ItemFileReadStore({data:cbt.toStoreData(btList)});
+                    btGrid.setStore(store);
+                    btGrid.render();
+                }
+            }
+        }
+    );
+}
+
+openils.Util.addOnLoad(buildBTGrid);
+
+

Added: trunk/Open-ILS/web/templates/default/conify/global/config/billing_type.tt2
===================================================================
--- trunk/Open-ILS/web/templates/default/conify/global/config/billing_type.tt2	                        (rev 0)
+++ trunk/Open-ILS/web/templates/default/conify/global/config/billing_type.tt2	2008-11-13 22:30:06 UTC (rev 11177)
@@ -0,0 +1,20 @@
+[% WRAPPER default/base.tt2 %]
+<script src='[% ctx.media_prefix %]/js/ui/default/conify/global/config/billing_type.js'> </script>
+<h1>Billing Types</h1><br/>
+<div dojoType="dijit.layout.ContentPane" layoutAlign="top">
+    <div dojoType="dijit.layout.ContentPane" layoutAlign="client" style='height:600px;'>
+        <table jsId="btGrid" dojoType="dojox.grid.DataGrid" query="{id: '*'}" rowSelector='20px'>
+            <thead>
+                <tr>
+                    <th field="id">ID</th>
+                    <th field="name" width='300px;'>Name</th>
+                    <th field="owner">Owning Location</th>
+                    <th field="default_price">Default Price</th>
+                </tr>
+            </thead>
+        </table>    
+    </div>
+</div>
+[% END %]
+
+



More information about the open-ils-commits mailing list