diff --git a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js index ecbdf95..87342da 100644 --- a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js +++ b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js @@ -33,6 +33,7 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) { hidePaginator : false, showLoadFilter : false, suppressLinkedFields : null, // list of fields whose linked display data should not be fetched from the server + showBackForward : true, /* by default, don't show auto-generated (sequence) fields */ showSequenceFields : false, @@ -85,32 +86,37 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) { this.paginator = new dijit.layout.ContentPane(); - var back = dojo.create('a', { - innerHTML : 'Back', // TODO i18n - style : 'padding-right:6px;', - href : 'javascript:void(0);', - onclick : function() { - self.cachedQueryOpts.offset = self.displayOffset -= self.displayLimit; - if(self.displayOffset < 0) - self.cachedQueryOpts.offset = self.displayOffset = 0; - self.refresh(); - } - }); - - var forw = dojo.create('a', { - innerHTML : 'Next', // TODO i18n - style : 'padding-right:6px;', - href : 'javascript:void(0);', - onclick : function() { - self.cachedQueryOpts.offset = self.displayOffset += self.displayLimit; - self.refresh(); - } - }); - dojo.place(this.paginator.domNode, this.domNode, 'before'); - dojo.place(back, this.paginator.domNode); - dojo.place(forw, this.paginator.domNode); + + if(this.showBackForward) { + if(this.displayLimit != null) { //Don't show back or forward if we are displaying all rows. + var back = dojo.create('a', { + innerHTML : 'Back', // TODO i18n + style : 'padding-right:6px;', + href : 'javascript:void(0);', + onclick : function() { + self.cachedQueryOpts.offset = self.displayOffset -= self.displayLimit; + if(self.displayOffset < 0) + self.cachedQueryOpts.offset = self.displayOffset = 0; + self.refresh(); + } + }); + var forw = dojo.create('a', { + innerHTML : 'Next', // TODO i18n + style : 'padding-right:6px;', + href : 'javascript:void(0);', + onclick : function() { + self.cachedQueryOpts.offset = self.displayOffset += self.displayLimit; + self.refresh(); + } + }); + + dojo.place(back, this.paginator.domNode); + dojo.place(forw, this.paginator.domNode); + } + } + if(this.showLoadFilter) { dojo.require('openils.widget.PCrudFilterDialog'); dojo.place( @@ -576,10 +582,14 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) { if(this.loadProgressIndicator) dojo.style(this.loadProgressIndicator, 'visibility', 'visible'); var self = this; - opts = dojo.mixin( - {limit : this.displayLimit, offset : this.displayOffset}, - opts || {} - ); + + if(this.displayLimit != null) { + opts = dojo.mixin( + {limit : this.displayLimit, offset : this.displayOffset}, + opts || {} + ); + } + opts = dojo.mixin(opts, { async : true, streaming : true, diff --git a/Open-ILS/web/js/ui/default/conify/global/config/circ_matrix_matchpoint.js b/Open-ILS/web/js/ui/default/conify/global/config/circ_matrix_matchpoint.js index 6e8dd50..b3ad60b 100644 --- a/Open-ILS/web/js/ui/default/conify/global/config/circ_matrix_matchpoint.js +++ b/Open-ILS/web/js/ui/default/conify/global/config/circ_matrix_matchpoint.js @@ -1,4 +1,5 @@ dojo.require('dijit.layout.ContentPane'); +dojo.require('dijit.layout.LayoutContainer'); dojo.require('dijit.form.Button'); dojo.require('openils.widget.AutoGrid'); dojo.require('openils.widget.AutoFieldWidget'); @@ -207,3 +208,17 @@ function applyCircModChanges() { openils.Util.addOnLoad(load); +function format_hard_due_date(name, id) { + var item=this.grid.getItem(id); + if(!item) return name; + switch (this.grid.store.getValue(this.grid.getItem(id), 'hard_due_date')) { + case null : + case undefined : + case 'unset' : + return name; + default: + return "" + name + ""; + } +} \ No newline at end of file diff --git a/Open-ILS/web/templates/default/conify/global/config/circ_matrix_matchpoint.tt2 b/Open-ILS/web/templates/default/conify/global/config/circ_matrix_matchpoint.tt2 index e3725a2..5866e5f 100644 --- a/Open-ILS/web/templates/default/conify/global/config/circ_matrix_matchpoint.tt2 +++ b/Open-ILS/web/templates/default/conify/global/config/circ_matrix_matchpoint.tt2 @@ -1,13 +1,14 @@ [% ctx.page_title = 'Circulation Policy Configuration' %] [% WRAPPER default/base.tt2 %] -
+
Circulation Policy Configuration
+
- +
-
-