</class>
<class id="chddv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::hard_due_date_values" oils_persist:tablename="config.hard_due_date_values" reporter:label="Hard Due Date Values">
- <fields oils_persist:primary="id" oils_persist:sequence="config.hard_due_date_vales_id_seq">
+ <fields oils_persist:primary="id" oils_persist:sequence="config.hard_due_date_values_id_seq">
<field reporter:label="ID" name="id" reporter:datatype="id"/>
<field reporter:label="Hard Due Date" name="hard_due_date" reporter:datatype="link"/>
<field reporter:label="Ceiling Date" name="ceiling_date" reporter:datatype="timestamp"/>
<link field="owner" reltype="has_a" key="id" map="" class="au"/>
</links>
<permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+ <actions>
+ <create permission="ADMIN_HARD_DUE_DATE" global_required="true" />
+ <retrieve />
+ <update permission="ADMIN_HARD_DUE_DATE" global_required="true" />
+ <delete permission="ADMIN_HARD_DUE_DATE" global_required="true" />
+ </actions>
</permacrud>
</class>
<!ENTITY staff.main.menu.admin.server_admin.conify.circulation_modifier.label "Circulation Modifiers">
<!ENTITY staff.main.menu.admin.server_admin.conify.org_unit_setting_type "Organization Unit Setting Types">
<!ENTITY staff.main.menu.admin.server_admin.conify.usr_setting_type "User Setting Types">
+<!ENTITY staff.main.menu.admin.server_admin.conify.config_hard_due_date "Hard Due Date Changes">
<!ENTITY staff.main.menu.admin.server_admin.conify.config_rule_circ_duration "Circulation Duration Rules">
<!ENTITY staff.main.menu.admin.server_admin.conify.config_rule_recurring_fine "Circulation Recurring Fine Rules">
<!ENTITY staff.main.menu.admin.server_admin.conify.config_rule_max_fine "Circulation Max Fine Rules">
'acqligad','acqliuad','acqlipad','acqphsm','acqlilad','acqedi','acqedim','acqdf','acqdfe','acqdfa','acqda','cnal',
'acqclt','acqclet','acqcl','acqcle','acqscl','acqscle','acqclp','acqclpa','acqlisum','acqft','acqftm','actsce','actscecm',
'jub','sdist','ssub','sstr','scap','bre','siss','act', 'acpl', 'ccm', 'aiit', 'atevdef', 'ath', 'atreact','atclean','atenv','atevparam','atcol','actsc','cit',
-'atval','crahp','crmf','crrf','crcd','cust','coust','cgf','czs','cbt','csp','brt','brsrc','bra','bram','brav','vaq','vbq','vqar','ccmm','ccmcmtm','citm','cifm','cvrfm','chmm','chdd']};
+'atval','crahp','crmf','crrf','crcd','cust','coust','cgf','czs','cbt','csp','brt','brsrc','bra','bram','brav','vaq','vbq','vqar','ccmm','ccmcmtm','citm','cifm','cvrfm','chmm','chdd','chddv']};
</script>
<script type="text/javascript" src="[% ctx.media_prefix %]/js/dojo/dojo/dojo.js"></script>
<script type="text/javascript" src="[% ctx.media_prefix %]/js/dojo/dojo/openils_dojo.js"></script>
</div>
<div dojoType="dijit.layout.ContentPane" layoutAlign="client">
<table jsId="cmGrid"
- autoHeight='true'
+ style="height: 600px;"
dojoType="openils.widget.AutoGrid"
fieldOrder="['org_unit', 'active', 'grp', 'circ_modifier', 'marc_type', 'marc_form', 'marc_vr_format']"
defaultCellWidth='"auto"'
editOnEnter='true'
showColumnPicker='true'
columnPickerPrefix='"conify.config.circ_matrix_matchpoint"'>
+ <thead>
+ <tr>
+ <th field="hard_due_date" formatter="format_hard_due_date">
+ </th>
+ </tr>
+ </thead>
</table>
</div>
<div class='hidden'><div dojoType='openils.widget.ProgressDialog' jsId='progressDialog'/></div>
+<script type="text/javascript">
+ function format_hard_due_date(name) {
+ return "<a href='" + oilsBasePath +
+ "/conify/global/config/hard_due_date?name=" +
+ encodeURIComponent(name) + "'>" + name + "</a>";
+ }
+</script>
[% END %]
--- /dev/null
+[% WRAPPER default/base.tt2 %]
+[% ctx.page_title = "Hard Due Dates" %]
+<script type="text/javascript">
+ dojo.require("openils.CGI");
+ dojo.require("openils.Util");
+ dojo.require("openils.widget.AutoGrid");
+
+ function get_chdd_name(rowIndex, item) {
+ if (!item) return null;
+ else return {
+ "id": this.grid.store.getValue(item, "id"),
+ "name": this.grid.store.getValue(item, "name")
+ };
+ }
+
+ function format_chdd_name(blob) {
+ if (blob) {
+ return "<a href='" + oilsBasePath +
+ "/conify/global/config/hard_due_date_values?chdd=" +
+ blob.id + "'>" + blob.name + "</a>";
+ } else {
+ return "";
+ }
+ }
+
+ openils.Util.addOnLoad(
+ function() {
+ var cgi = new openils.CGI();
+ var filter = null;
+ var id = cgi.param("id");
+ var name = cgi.param("name");
+ if (id) {
+ filter = {"id": id};
+ openils.Util.show("one_only");
+ } else if (name) {
+ filter = {"name": name};
+ openils.Util.show("one_only");
+ }
+ chddGrid.loadAll({"order_by": {"chdd": "name"}}, filter);
+ }
+ );
+</script>
+<div dojoType="dijit.layout.ContentPane" layoutAlign="client">
+ <div dojoType="dijit.layout.ContentPane"
+ layoutAlign="top" class="oils-header-panel">
+ <div>Hard Due Dates</div>
+ <div>
+ <button
+ dojoType="dijit.form.Button"
+ onClick="chddGrid.showCreateDialog();">New Hard Due Date</button>
+ <button
+ dojoType="dijit.form.Button"
+ onClick="chddGrid.deleteSelected();">Deleted Selected</button>
+ </div>
+ </div>
+ <div id="one_only" class="hidden">
+ <em>Showing only one hard due date.</em> [
+ <a href="./hard_due_date">Show them all</a>
+ ]
+ </div>
+ <div>
+ <table jsId="chddGrid"
+ dojoType="openils.widget.AutoGrid"
+ showPaginator="true"
+ query="{name: '*'}"
+ defaultCellWidth="'auto'"
+ fieldOrder="['name', 'owner', 'ceiling_date', 'forceto']"
+ fmClass="chdd"
+ hideSelector="true"
+ editOnEnter="true">
+ <thead>
+ <tr>
+ <th field="name" get="get_chdd_name"
+ formatter="format_chdd_name"></th>
+ </tr>
+ </thead>
+ </table>
+ </div>
+</div>
+[% END %]
--- /dev/null
+[% WRAPPER default/base.tt2 %]
+[% ctx.page_title = "Hard Due Date Values" %]
+<script type="text/javascript">
+ dojo.require("openils.CGI");
+ dojo.require("openils.PermaCrud");
+ dojo.require("openils.Util");
+ dojo.require("openils.widget.AutoGrid");
+ dojo.require("dijit.form.TextBox");
+
+ openils.Util.addOnLoad(
+ function() {
+ var filter = null;
+ var chdd_id = (new openils.CGI()).param("chdd");
+
+ if (chdd_id) {
+ filter = {"hard_due_date": chdd_id};
+ var hard_due_date =
+ (new openils.PermaCrud()).retrieve("chdd", chdd_id);
+
+ dojo.byId("linked_chdd_name").innerHTML = hard_due_date.name();
+ dojo.byId("linked_chdd_link").innerHTML = hard_due_date.id();
+ dojo.byId("linked_chdd_link").onclick = function() {
+ location.href = oilsBasePath +
+ "/conify/global/config/hard_due_date?id=" +
+ hard_due_date.id();
+ };
+ openils.Util.show("linked_chdd");
+ }
+
+ chddvGrid.overrideEditWidgets.hard_due_date =
+ new dijit.form.TextBox({"disabled": true});
+ chddvGrid.overrideEditWidgets.hard_due_date.shove = {
+ "create": chdd_id
+ };
+
+ chddvGrid.loadAll({"order_by": {"chddv": "active_date"}}, filter);
+ }
+ );
+</script>
+<div dojoType="dijit.layout.ContentPane" layoutAlign="client">
+ <div dojoType="dijit.layout.ContentPane"
+ layoutAlign="top" class="oils-header-panel">
+ <div>Hard Due Date Values</div>
+ <div>
+ <button
+ dojoType="dijit.form.Button"
+ onClick="chddvGrid.showCreateDialog();">New Hard Due Date Value</button>
+ <button
+ dojoType="dijit.form.Button"
+ onClick="chddvGrid.deleteSelected();">Deleted Selected</button>
+ </div>
+ </div>
+ <div class="hidden" id="linked_chdd">
+ <em>Showing only hard due date values related to hard due date object</em>
+ <strong id="linked_chdd_name"></strong> (#
+ <a href="javascript:void(0);" id="linked_chdd_link"></a>)
+ </div>
+ <div>
+ <table jsId="chddvGrid"
+ dojoType="openils.widget.AutoGrid"
+ showPaginator="true"
+ query="{name: '*'}"
+ defaultCellWidth="'auto'"
+ fieldOrder="['hard_due_date', 'ceiling_date', 'active_date']"
+ suppressFields="['hard_due_date']"
+ suppressEditFields="['id']"
+ fmClass="chddv"
+ hideSelector="true"
+ editOnEnter="true">
+ </table>
+ </div>
+</div>
+[% END %]
['oncommand'],
function() { open_eg_web_page('conify/global/config/rule_circ_duration'); }
],
+ 'cmd_server_admin_config_hard_due_date' : [
+ ['oncommand'],
+ function() { open_eg_web_page('conify/global/config/hard_due_date'); }
+ ],
'cmd_server_admin_config_rule_recurring_fine' : [
['oncommand'],
function() { open_eg_web_page('conify/global/config/rule_recurring_fine'); }
<command id="cmd_server_admin_global_flag"/>
<command id="cmd_server_admin_org_unit_setting_type"/>
<command id="cmd_server_admin_usr_setting_type"/>
+ <command id="cmd_server_admin_config_hard_due_date"/>
<command id="cmd_server_admin_config_rule_circ_duration"/>
<command id="cmd_server_admin_config_rule_recurring_fine"/>
<command id="cmd_server_admin_config_rule_max_fine"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.global_flag.label;" command="cmd_server_admin_global_flag"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.org_unit_setting_type;" command="cmd_server_admin_org_unit_setting_type"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.usr_setting_type;" command="cmd_server_admin_usr_setting_type"/>
+ <menuitem label="&staff.main.menu.admin.server_admin.conify.config_hard_due_date;" command="cmd_server_admin_config_hard_due_date"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.config_rule_circ_duration;" command="cmd_server_admin_config_rule_circ_duration"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.config_rule_recurring_fine;" command="cmd_server_admin_config_rule_recurring_fine"/>
<menuitem label="&staff.main.menu.admin.server_admin.conify.config_rule_max_fine;" command="cmd_server_admin_config_rule_max_fine"/>