]> git.evergreen-ils.org Git - working/Evergreen.git/commit
Toward a new look for XUL Record Summary. bib_brief.xul modified for existing instan...
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 7 Oct 2009 15:56:12 +0000 (15:56 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 7 Oct 2009 15:56:12 +0000 (15:56 +0000)
commit0687d223cc3d77b9c29168cfb5c3caacc8786651
tree1ef281c28e86aa0eb844f290ef95eeeb7127f372
parentcf5a6103a440a05555c17b4b92abb3f067fcae43
Toward a new look for XUL Record Summary.  bib_brief.xul modified for existing instances of Record Summary, but the alternate Item Details interface is doing it differently.

The old Record Summary is a dedicated XUL file that typically lives in an iframe.  It would fetch its own data if fed some ID's either via xulG or URL parameters.

The new way (which is really an old way that was tried before and is used with bill summaries) involves a XUL overlay, and a render function matching the overlay name.  A caller can feed it already fetched objects or have it fetch
its own objects given ID's.

To do this,

Include these in your XUL file:
<?xul-overlay href="/xul/server/cat/bib_brief_overlay.xul"?>
<grid id="bib_brief_grid"/>

This pulls in the overlay, which merges with the <grid/> in your XUL and loads bib_brief_overlay.js.

In your javascript, call bib_brief_overlay():

bib_brief_overlay( { 'mvr' : details.mvr, 'acp' : details.copy } );

Different options include mvr, mvr_id, bre, bre_id, and acp.  This will render values into the grid.

Since this is an overlay, you can mix-in your own elements.  The new Item Details is doing this:

<grid id="bib_brief_grid">
    <rows id="bib_brief_grid_rows">
<row>
    <label value="&staff.circ.alternate_copy_summary.Call_Number.label;" accesskey="&staff.circ.alternate_copy_summary.call_number.accesskey;" control="call_number"/>
    <textbox name="call_number" readonly="true" context="clipboard"/>
</row>
    </rows>
</grid>

This is adding a custom/local row to the bottom of the Record Summary grid.

git-svn-id: svn://svn.open-ils.org/ILS/trunk@14292 dcc99617-32d9-48b4-a31d-7c20da2025e4
Open-ILS/web/opac/locale/en-US/lang.dtd
Open-ILS/xul/staff_client/server/cat/bib_brief.js [new file with mode: 0644]
Open-ILS/xul/staff_client/server/cat/bib_brief.xul
Open-ILS/xul/staff_client/server/cat/bib_brief_overlay.js [new file with mode: 0644]
Open-ILS/xul/staff_client/server/cat/bib_brief_overlay.xul [new file with mode: 0644]
Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.js
Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.xul
Open-ILS/xul/staff_client/server/locale/en-US/circ.properties