[Koha-patches] [PATCH] Fix for Bug 6753, Markup corrections and improvements for label export window

Owen Leonard oleonard at myacpl.org
Fri Aug 19 16:02:15 CEST 2011


The most visible change in this patch is the conversion of image-only
links to text links combined with icons. Other changes include
markup corrections and standardization and language corrections.

To test, go to Labels > Manage Batches. Select a batch and click
'Export' to see the revised interface.
---
 .../intranet-tmpl/prog/en/css/staff-global.css     |   18 +++
 .../prog/en/modules/labels/label-print.tt          |  162 ++++++-------------
 .../prog/img/famfamfam/silk/page_white_acrobat.png |  Bin 0 -> 591 bytes
 .../prog/img/famfamfam/silk/page_white_code.png    |  Bin 0 -> 603 bytes
 .../prog/img/famfamfam/silk/page_white_excel.png   |  Bin 0 -> 663 bytes
 5 files changed, 69 insertions(+), 111 deletions(-)
 create mode 100644 koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_acrobat.png
 create mode 100644 koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_code.png
 create mode 100644 koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_excel.png

diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css
index 7f6a55f..817f9ed 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css
+++ b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css
@@ -1199,6 +1199,24 @@ div.dialog {
   text-align : center;
 }
 
+a.document {
+	background-position : left middle;
+	background-repeat : no-repeat;
+	padding-left : 20px;
+}
+
+a.pdf {
+	background-image : url("../../img/famfamfam/silk/page_white_acrobat.png");
+}
+
+a.csv {
+	background-image : url("../../img/famfamfam/silk/page_white_excel.png");
+}
+
+a.xml {
+	background-image : url("../../img/famfamfam/silk/page_white_code.png");
+}
+
 div.message {
 	background : white url("../../img/message-bg.gif") repeat-x left 0;
   	border : 1px solid #bcbcbc;
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-print.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-print.tt
index 89e5d97..91f5d41 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-print.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-print.tt
@@ -1,7 +1,7 @@
     [% INCLUDE 'doc-head-open.inc' %]
     <title>Koha &rsaquo; Tools &rsaquo; Labels &rsaquo; Label Printing/Exporting</title>
     [% INCLUDE 'doc-head-close.inc' %]
-    <script type="text/JavaScript" language="JavaScript">
+    <script type="text/javascript">
         //<![CDATA[
             function Done() {
                 window.location = "[% referer %]";
@@ -16,95 +16,49 @@
         <div id="bd">
             [% IF ( batches ) %]
             <form>
-                <div align="center">
-                    <div class="message">
-                        <b>Click on the following link(s) to download the exported batch(es).</b>
-                    </div>
-                </div>
-                <fieldset class="rows">
-                    <table class="borderless">
+                <h3>Click on the following links to download the exported batch(es).</h3>
                         [% FOREACH batche IN batches %]
-                        <tr>
+                        <fieldset>
                             [% IF ( batche.label_ids ) %]
-                            <td class="borderless">
-                                [% batche.label_count %] Single Labels
-                            </td>
-                            <td class="borderless">
-                                <h1 id="pdf">
-                                    <a href="/cgi-bin/koha/labels/[% batche.create_script %]?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.label_ids %]">label_single_[% batche.label_count %].pdf</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="csv">
-                                    <a href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">label_single_[% batche.label_count %].csv</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="xml">
-                                    <a href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">label_single_[% batche.label_count %].xml</a>
-                                </h1>
-                            </td>
+                                <legend>[% IF ( batche.label_count == 1 ) %][% batche.label_count %] single label[% ELSE %][% batche.label_count %] single labels[% END %]</legend>
+                                    <p><a class="document pdf" href="/cgi-bin/koha/labels/[% batche.create_script %]?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.label_ids %]">Download as PDF</a></p>
+
+                                    <p><a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">Download as CSV</a></p>
+
+                                    <p><a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">Download as XML</a></p>
                             [% ELSIF ( batche.item_numbers ) %]
-                            <td class="borderless">
-                                [% batche.label_count %] Single Labels
-                            </td>
-                            <td class="borderless">
-                                <h1 id="pdf">
-                                    <a href="/cgi-bin/koha/labels/[% batche.create_script %]?template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.item_numbers %]">label_single_[% batche.label_count %].pdf</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="csv">
-                                    <a href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">label_single_[% batche.label_count %].csv</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="xml">
-                                    <a href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">label_single_[% batche.label_count %].xml</a>
-                                </h1>
-                            </td>
+                            <legend>[% IF ( batche.label_count == 1 ) %][% batche.label_count %] single label[% ELSE %][% batche.label_count %] single labels[% END %]</legend>
+                                    <p><a class="document pdf" href="/cgi-bin/koha/labels/[% batche.create_script %]?template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.item_numbers %]">Download as PDF</a></p>
+
+                                    <p><a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">Download as CSV</a></p>
+
+                                    <p><a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">Download as XML</a></p>
                             [% ELSE %]
-                            <td class="borderless">
-                                Label Batch Number [% batche.batch_id %]
-                            </td>
-                            <td class="borderless">
-                                <h1 id="pdf">
-                                    <a href="/cgi-bin/koha/labels/label-create-pdf.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %]">label_batch_[% batche.batch_id %].pdf</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="csv">
-                                    <a href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">label_batch_[% batche.batch_id %].csv</a>
-                                </h1>
-                            </td>
-                            <td class="borderless">
-                                <h1 id="xml">
-                                    <a href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">label_batch_[% batche.batch_id %].xml</a>
-                                </h1>
-                            </td>
+                            <legend>Label Batch Number [% batche.batch_id %]</legend>
+                                    <p><a class="document pdf" href="/cgi-bin/koha/labels/label-create-pdf.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %]">Download as PDF</a>
+                                </p>
+                                <p>
+                                    <a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">Download as CSV</a>
+                                </p>
+                                <p>
+                                    <a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">Download as XML</a></p>
                             [% END %]
-                        </tr>
+                        </fieldset>
                         [% END %]
-                    </table>
-                </fieldset>
                 <fieldset class="action">
-                    <div style="margin: 10px 10px 10px 0px;">
-                        <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="done" onclick="parent.parent.GB_hide();" value="Done"></span></span>
-                    </div>
+                    <input type="button" id="done" onclick="parent.parent.GB_hide();" class="submit" value="Done" />
                 </fieldset>
             </form>
             [% ELSE %]
-            <div align="center">
-                <div class="message">
-                    [% IF ( label_ids ) %]
-                    <b>Exporting [% label_count %] label(s).</b>
-                    [% ELSIF ( item_numbers ) %]
-                    <b>Exporting [% item_count %] label(s).</b>
-                    [% ELSE %]
-                    <b>[% multi_batch_count %] batch(es) to export.</b>
-                    [% END %]
-                </div>
-            </div>
+            <h3>
+                [% IF ( label_ids ) %]
+                    [% IF ( label_count == 1 ) %]Exporting [% label_count %] label[% ELSE %]Exporting [% label_count %] labels[% END %]
+                [% ELSIF ( item_numbers ) %]
+                    [% IF ( item_count == 1 ) %]Exporting [% item_count %] label[% ELSE %]Exporting [% item_count %] labels[% END %]
+                [% ELSE %]
+                    [% IF ( multi_batch_count == 1 ) %][% multi_batch_count %] batch to export[% ELSE %][% multi_batch_count %] batches to export[% END %]
+                [% END %]
+            </h3>
             <form name="exporting" method="post" action="/cgi-bin/koha/labels/label-print.pl">
                 <input type="hidden" name="op" value="export" />
                 <input type="hidden" name="referer" value="[% referer %]" />
@@ -118,48 +72,34 @@
                     <input type="hidden" name="item_number" value="[% item_number.item_number %]" />
                 [% END %]
                 <fieldset class="rows">
-                    <table class="borderless">
-                        <tr>
-                            <td class="borderless">
-                                <label for="template">Select a template to be applied: </label>
-                            </td>
-                            <td class="borderless">
-                                <select name="template_id">
+                    <ol>
+                        <li>
+                            <label for="template_id" style="width:9em">Select a template to be applied: </label>
+                            <select name="template_id" id="template_id">
                                     [% FOREACH template IN templates %]
                                     <option value="[% template.template_id %]">[% template.template_code %]</option>
                                     [% END %]
                                 </select>
-                            </td>
-                        </tr>
-                        <tr>
-                            <td class="borderless">
-                                <label for="layout">Select a layout to be applied: </label>
-                            </td>
-                            <td class="borderless">
-                                <select name="layout_id">
+                        </li>
+                        <li>
+                            <label for="layout_id" style="width:9em">Select a layout to be applied: </label>
+                            <select name="layout_id" id="layout_id">
                                     [% FOREACH layout IN layouts %]
                                     <option value="[% layout.layout_id %]">[% layout.layout_name %]</option>
                                     [% END %]
                                 </select>
-                            </td>
-                        </tr>
-                        <tr>
-                            <td class="borderless">
-                                <label for="start_label">Enter starting label number: </label>
-                            </td>
-                            <td class="borderless">
-                                <input type="text" size="5" id="start_label" name="start_label" class="focus" title="Starting label number" value="1"/>
-                            </td>
-                        </tr>
-                    </table>
+                        </li>
+                        <li>
+                            <label for="start_label" style="width:9em">Enter starting label number: </label>
+                            <input type="text" size="5" id="start_label" name="start_label" class="focus" title="Starting label number" value="1"/>
+                        </li>
+                    </ol>
                 </fieldset>
                 <fieldset class="action">
-                    <div style="margin: 10px 10px 10px 0px;">
-                        <span class="yui-button yui-link-button"><span class="first-child"><input type="submit" value="Export" /></span></span>
-                        <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="done" onclick="parent.parent.GB_hide();" value="Cancel"></span></span>
-                    </div>
+                    <input type="submit" class="submit" value="Export" />
+                    <a href="#" class="cancel" id="done" onclick="parent.parent.GB_hide();return false;">Cancel</a>
                 </fieldset>
             </form>
             [% END %]
         </div>
-    [% INCLUDE 'intranet-bottom.inc' %]
+[% INCLUDE 'popup-bottom.inc' %]
diff --git a/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_acrobat.png b/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_acrobat.png
new file mode 100644
index 0000000000000000000000000000000000000000..8f8095e46fa4965700afe1f9d065d8a37b101676
GIT binary patch
literal 591
zcmV-V0<iswP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV00004XF*Lt006JZ
zHwB960000PbVXQnQ*UN;cVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBUz;Ymb6R5;6x
zlgmpRQ51*OWfxY9N(BY~fvyyB<<ga4p}4fTQL0!MK4KLm2!iWELJ5{C6m%i(y3mzE
zyJ=Mvd>~O9lw>B8WRlD)Gm}Jrz31u-X&&gn2lvjs=i{7nIaL6v2==uw+8Lcs(8j27
z;|c`rmSv at Lx!heopGP^^Ieb3f=R!%Lpp$}iMS-&P3EJ)s48wrJ_Ni0~k|c47D2nj=
z{jS6bt|kFpFf|p5cM`_&0Zh|`rfEp0(}=}lT#(6RpzAsUfxv^LSYX>WlAaN$>)*J5
z0#sE+JRUD8iT9*fz{)_<I|XfPov*2Gr<6n@!7~vAp|XI8eHcK(GX_WKNGKEPhb+sL
z1=imy2=Ct^IywmR{PaHwl|wxtQAL3`{SorlFEFn!5gB2Ut02Fe&1QLjNJ5kq*pi4)
ze=n>^7 at 6P&!sEjTcD+I9Z4YjT1`wH at fV{cEvneYGFU%maIEU2s55&K(LixD|{p<w7
z@*-}=h7g|jKw4WV75r*`RUc at m^<MV(!A{EVGg0jXrB9er6gKMttzE(4>-uiS@?KNj
zk-Go8<gFb^F|OcGW9<rK$M^Dum;Jo2GzVq4b4z&aLkH`!K?lzXW_L9{y#<0+l00La
d9cc7h{{bX9v)}>G$hH6g002ovPDHLkV1hVj1#|!a

literal 0
HcmV?d00001

diff --git a/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_code.png b/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_code.png
new file mode 100644
index 0000000000000000000000000000000000000000..0c76bd1297751b66230f74719504b2adb02b1615
GIT binary patch
literal 603
zcmV-h0;K(kP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV00004XF*Lt006JZ
zHwB960000PbVXQnQ*UN;cVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBUz?MXyIR5;6x
zlRZz{P!xtKLzj*)5~W+GmLUkKYs6nbq#%Sq3aOY16$mC4en49#LkcQYL6Ei*pjMPh
zojYVgqzf!S6l}*|wVl|p^8s&tZm at AkP_gvL(mnS)KIiz}E&yGG`}Da)Tn7KcW0!6}
zFCd6Gj-%J>^~*-1fljz_B$LUvK}k?BNXe#Y!m=zM!!V#}8bncK5<w7<N~L^>m;8VP
zw86G*RI63?Cd%b9bX|ueNlZ|wR6rj|r_)VIP at r2imh3?SN+^{|kY%~8B{maJ at F*OK
z&VH9LwOeGt#DRjj0~v~8`>iO7!Ybi;zE$va`A^T#yW`y44;k^#O~K5*jD=qcUhPSc
zv<j0 at B{UCJRc{2(R!(DMUqyR%UqXDl2u^iakk_i1-Vs6T<C!A%vMOtbW<nxgFtRNe
zOFtFFHo3;pnc31~E^lFMi^u#o5u+b2U|J575We8a>yy~<I%m&(DPm&n0-W5efGU~#
z#DUgF)(Y7Dt@^{I^UyMb at I<!f`Ql+NzQJKUnP<Vtj~rfR1SD1qkaY*OT8%-;Z36lW
z4}1Hg at l+neZ_Zip#rpyh=>q;5H_1WT1l~cqje9yfa+l!hu6xjdOJ8s;8E^+=QQ$tw
p?%p!Hy#YapB=@+^9(46X{{RQg%9y;OKjr`c002ovPDHLkV1g7l326WT

literal 0
HcmV?d00001

diff --git a/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_excel.png b/koha-tmpl/intranet-tmpl/prog/img/famfamfam/silk/page_white_excel.png
new file mode 100644
index 0000000000000000000000000000000000000000..b977d7e52e2446ea01201c5c7209ac3a05f12c9f
GIT binary patch
literal 663
zcmV;I0%-k-P)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV00004XF*Lt006JZ
zHwB960000PbVXQnQ*UN;cVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBU!DM>^@R5;6x
zlTS!gQ5431_q{u#M2<ShOw%997S$$-!hxcNL=i;cvIw^+Edn<|ww0(B5s4B}+Ywp>
zg&W%y6a}>qj1Z|7Vu&-DW6d~k-n;jnHsjb-q#u0C^W!_5^C=MlKq<8oNCQ6qS00!X
z5eI;XP=g!^f}j{hku}E1zZ?XCjE;`p19k(Rh%^AQQ54xysU+ocx$c#f6<J<hmc_+I
zF~-Qk!h(#AjnyG)aI#m{vN<P+bvP$DD_G-j)?tm~_UUnw$s}PI;+!Lw%Z&^S4BTaK
zvR5`z- at _g$6bgT>1Z4HnT#3u~FR(3>BnZniMIF4DouI8Hi4u>cAK%EN)5PO(ip3(%
zIgBx+QYirR){Z8QwV$9Z(Mpt=L-Or3#bf-G at 66}txq0yc*T(zNTBDT0T8r<mAIgiW
zhQ6MDK75&?G}FSo%+Q>O^JeNbSI-Tzf5!pBioy4NwAN^?iN#{;fH1Jke4Xa`^fR8m
z%h6dq%xX)S?7`zae))(Xst^Scp6B8FejQW?RLTM8 at 0=vnnntuRGBM2dpo>gbCnTD=
z^<;=JuqdSf at O>Z8^XdR?s+KEfhDdB_#ahFj^giCtzT(s8kA$AViyTqaAR;KGaLzUU
z<=GqA4bRwpX|IG~*x>pZ!@zLr`XQ`od>m(`;jz|M_*1GDO#$7;n74ppb8=eiqh760
x0yt}J1#p`gw$`o!R{d7zU9~!Un at nJV{4bstt4Au+Up at c;002ovPDHLkV1kWhGjjj{

literal 0
HcmV?d00001

-- 
1.7.3



More information about the Koha-patches mailing list