</span>
<span style="white-space: nowrap;">
<label for="searchOrNot">[% l('Search instead of browse: ') %]</label>
- <input type="checkbox" name="searchOrNot" value="1" dojoType="dijit.form.Checkbox" id="searchOrNot"/>
+ <input type="checkbox" name="searchOrNot" value="1" dojoType="dijit.form.CheckBox" id="searchOrNot"/>
</span>
<!-- Not currently useful - see authOUListInit() above -->
<!-- <label for="authOU">[% l('Library: ') %]</label><select dojoType="openils.widget.OrgUnitFilteringSelect" id="authOU" name="authOU" searchAttr="shortname" labelAttr="shortname"></select> -->
dojo.require('dijit.Dialog');
+dojo.require('dijit.form.CheckBox');
dojo.require('dijit.form.Button');
dojo.require('dijit.form.DropDownButton');
dojo.require('dijit.form.FilteringSelect');
dojo.query("#authlist-div").query("div").orphan();
+ var search_type = dijit.byId('searchOrNot').attr('checked') ? '.search' : '';
var url = '/opac/extras/browse/marcxml/authority.'
+ dijit.byId('authAxis').attr('value')
- + dijit.byId('searchOrNot').attr('checked') ? '.search' : ''
- // + '/' + dijit.byId('authOU').attr('value')
+ + search_type
+ // + '/' + dijit.byId('authOU').attr('value')
+ '/1' // replace with preceding line if OUs gain some meaning
+ '/' + encodeURIComponent(dijit.byId('authTerm').attr('value'))
+ '/' + dijit.byId('authPage').attr('value')
+ '/' + '20' // 20 results per page
;
+alert(url);
+alert(dijit.byId('searchOrNot').attr('checked'));
dojo.xhrGet({"url":url, "handleAs":"xml", "content":{"format":"marcxml"}, "preventCache": true, "load":displayAuthorities });
}