[open-ils-commits] r9411 -
branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/templates/oils/default/acq/financial
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon Apr 21 15:26:45 EDT 2008
Author: erickson
Date: 2008-04-21 14:47:45 -0400 (Mon, 21 Apr 2008)
New Revision: 9411
Modified:
branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/templates/oils/default/acq/financial/list_funding_sources.html
Log:
offsetting the loading of perm orgs and currency types until needed
Modified: branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/templates/oils/default/acq/financial/list_funding_sources.html
===================================================================
--- branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/templates/oils/default/acq/financial/list_funding_sources.html 2008-04-21 18:47:16 UTC (rev 9410)
+++ branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/templates/oils/default/acq/financial/list_funding_sources.html 2008-04-21 18:47:45 UTC (rev 9411)
@@ -20,8 +20,6 @@
function createFS(fields) {
/** Creates a new funding source */
- var tree = dijit.byId('oils-acq-funding_source-owner-tree');
- fields.owner = tree.selected;
openils.acq.FundingSource.create(
fields,
function(fsId) {
@@ -41,7 +39,13 @@
<div class='oils-acq-actions-div'>
<div dojoType="dijit.form.DropDownButton">
<span>${('New Funding Source')}</span>
+
<div dojoType="dijit.TooltipDialog" execute="createFS(arguments[0]);">
+ <script type='dojo/connect' event='onOpen'>
+ openils.acq.CurrencyType.loadSelectWidget(fsCurrencySelector);
+ openils.User.buildPermOrgSelector('ADMIN_FUNDING_SOURCE', fsOwnerSelect);
+ </script>
+
<table class='dijitTooltipTable'>
<tr>
<td><label for="name">${_('Name:')} </label></td>
@@ -51,7 +55,7 @@
<td><label for="currency_type">${_('Currency Type:')}</label></td>
<td>
<input jsId='fsCurrencySelector' name="currency_type"
- dojoType="dijit.form.FilteringSelect" searchAttr='code'>
+ dojoType="dijit.form.FilteringSelect" searchAttr='code' labelAttr='code'>
</input>
</td>
</tr>
@@ -78,29 +82,15 @@
</button>
</div>
-<!-- The actual grid lives here -->
+<!-- The main grid lives here -->
<div id="oils-acq-funding-source-list-grid" jsId='fundingSourceListGrid' dojoType="dojox.Grid"></div>
<script>
- function loadCurrencyTypes() {
- openils.acq.CurrencyType.fetchAll(
- function(ctypes) {
- fsCurrencySelector.store =
- new dojo.data.ItemFileReadStore(
- {data:acqct.toStoreData(ctypes, 'code', {identifier:'code'})}
- );
- fsCurrencySelector.labelAttr = 'code';
- fsCurrencySelector.setValue(ctypes[0].code()); /* XXX get from setting */
- }
- );
- }
-
function loadFSGrid() {
openils.User.getBySession();
- loadCurrencyTypes();
- openils.User.buildPermOrgSelector('ADMIN_FUNDING_SOURCE', fsOwnerSelect);
+ /** define how the primary grid is rendered */
function getOrgInfo(rowIndex) {
data = fundingSourceListGrid.model.getRow(rowIndex);
More information about the open-ils-commits
mailing list