Bugzilla – Attachment 14327 Details for
Bug 9310
Patron image upload template corrections
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 9310 - Patron image upload template corrections
SIGNED-OFF-Bug-9310---Patron-image-upload-template.patch (text/plain), 8.37 KB, created by
Marc Véron
on 2012-12-29 09:28:50 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 9310 - Patron image upload template corrections
Filename:
MIME Type:
Creator:
Marc Véron
Created:
2012-12-29 09:28:50 UTC
Size:
8.37 KB
patch
obsolete
>From 6f20e2ee5bd4c8da70416b0fe7a5139eebe3b651 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Mon, 26 Nov 2012 08:41:57 -0500 >Subject: [PATCH] [SIGNED-OFF] Bug 9310 - Patron image upload template corrections >Content-Type: text/plain; charset="utf-8" > >This patch fixes some template structure problems and makes some >improvements: > >- Correct grid structure so that page isn't narrower than it needs > to be. >- Move image upload messages out of message/error dialog and into > table so that lines are distinct and legible. >- Expand breadcrumbs specificity >- Capitalization corrections > >To test: Upload patron images using both single images and zip files. >Test zip file upload with a file which contains valid and invalid >contents (non-existant patron numbers, invalid image files, etc). In all >cases image uploads should work correctly and errors should be legibly >displayed. > >Signed-off-by: Marc Veron <veron@veron.ch> > >With patch, error messages are displayed in a nice table. >--- > .../prog/en/modules/tools/picture-upload.tt | 67 +++++++++++--------- > 1 files changed, 37 insertions(+), 30 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt >index 51a78c5..ef22fe1 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tt >@@ -17,26 +17,27 @@ > [% INCLUDE 'header.inc' %] > [% INCLUDE 'patron-search.inc' %] > >-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> › Upload patron images </div> >+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> › [% IF ( TOTAL ) %]<a href="/cgi-bin/koha/tools/picture-upload.pl">Upload patron images</a> › Results[% ELSE %]Upload patron images[% END %] </div> > > <div id="doc3" class="yui-t2"> > <div id="bd"> > <div id="yui-main"> > [% IF ( TOTAL ) %] > <div class="yui-b"> >- <div class="yui-g"> >- <div class="yui-u first"> > [% IF ( ERRORS ) %] > [% IF ( TCOUNTS ) %] > <div class="dialog alert"> >- <h3>Patron Image(s) Uploaded with some errors</h3> >+ <h3>Patron image(s) uploaded with some errors</h3> >+ </div> > [% ELSE %] > <div class="dialog alert"> > <h3>Patron image failed to upload</h3> >+ </div> > [% END %] > [% ELSE %] > <div class="dialog message"> > <h3>Patron image(s) successfully uploaded</h3> >+ </div> > [% END %] > <ul class="data"> > <li>Unpacking completed</li> >@@ -45,41 +46,49 @@ > </ul> > > [% FOREACH COUNT IN COUNTS %] >- <ul class="data"> >+ <div class="container"> >+ <table> >+ <caption>Results</caption> >+ <thead> >+ <tr><th>File name</th><th>Card number</th><th>Result</th></tr> >+ </thead> >+ <tbody> > [% IF ( COUNT.TCOUNTS ) %]<li>[% COUNT.TCOUNTS %] image(s) moved into the database:</li>[% END %] > [% FOREACH filename IN COUNT.filenames %] >- <li>[% filename.source %] - Cardnumber: [% filename.cardnumber %] >- [% IF ( filename.filerrors ) %] >+ <tr> >+ <td>[% filename.source %]</td> >+ <td><a href="/cgi-bin/koha/circ/circulation.pl?findborrower=[% filename.cardnumber %]">[% filename.cardnumber %]</a></td> >+ <td> >+ [% IF ( filename.filerrors ) %] > [% FOREACH filerror IN filename.filerrors %] >- [% IF ( filerror.DBERR ) %]<br /><b>ERROR:</b> Image not imported because the database returned an error. Please refer to the error log for more details. >- [% ELSIF ( filerror.IMGEXISTS ) %]<br /><b>ERROR:</b> Image not imported because this patron does not exist in the database. >- [% ELSIF ( filerror.MIMERR ) %]<br /><b>ERROR:</b> Image not imported because the image format is unrecognized. >- [% ELSIF ( filerror.CORERR ) %]<br /><b>ERROR:</b> Image not imported because the image file is corrupted. >- [% ELSIF ( filerror.OPNERR ) %]<br /><b>ERROR:</b> Image not imported because Koha was unable to open the image for reading. >- [% ELSIF ( filerror.OVRSIZ ) %]<br /><b>ERROR:</b> Image not imported because the image file is too big (see online help for maximum size). >- [% ELSIF ( filerror.CRDFIL ) %]<br /><b>ERROR:</b> Image not imported ([% filerror.CRDFIL %] missing). >- [% ELSE %]<br /><b>ERROR:</b> Image not imported because of an unknown error. Please refer to the error log for more details. >+ [% IF ( filerror.DBERR ) %]<b>ERROR:</b> Image not imported because the database returned an error. Please refer to the error log for more details. >+ [% ELSIF ( filerror.IMGEXISTS ) %]<b>ERROR:</b> Image not imported because this patron does not exist in the database. >+ [% ELSIF ( filerror.MIMERR ) %]<b>ERROR:</b> Image not imported because the image format is unrecognized. >+ [% ELSIF ( filerror.CORERR ) %]<b>ERROR:</b> Image not imported because the image file is corrupted. >+ [% ELSIF ( filerror.OPNERR ) %]<b>ERROR:</b> Image not imported because Koha was unable to open the image for reading. >+ [% ELSIF ( filerror.OVRSIZ ) %]<b>ERROR:</b> Image not imported because the image file is too big (see online help for maximum size). >+ [% ELSIF ( filerror.CRDFIL ) %]<b>ERROR:</b> Image not imported ([% filerror.CRDFIL %] missing). >+ [% ELSE %]<b>ERROR:</b> Image not imported because of an unknown error. Please refer to the error log for more details. > [% END %] > [% END %] > [% ELSE %] imported successfully. >- [% END %] >- </li> >+ [% END %]</td> >+ </tr> > [% END %] >- </ul> >+ </tbody> >+ </table> >+ </div> > [% END %] >- >- </div> >- [% IF ( borrowernumber ) %] >- <a id="member" href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% borrowernumber %]">Return to patron detail</a> >- [% ELSE %] >- <a id="uploadmore" href="/cgi-bin/koha/tools/picture-upload.pl">Upload more images</a> >- <a id="doneupload" href="/cgi-bin/koha/tools/tools-home.pl">Return to tools</a> >- [% END %] >+<ul> >+ [% IF ( borrowernumber ) %] >+ <li><a id="member" href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% borrowernumber %]">Return to patron detail</a></li> >+ [% ELSE %] >+ <li><a id="uploadmore" href="/cgi-bin/koha/tools/picture-upload.pl">Upload more images</a></li> >+ <li><a id="doneupload" href="/cgi-bin/koha/tools/tools-home.pl">Return to tools</a></li> >+ [% END %]</ul> > </div> > [% ELSE %] > <div class="yui-b"> >- <div class="yui-g"> >- <div class="yui-u first"> > <h1>Upload patron images</h1> > [% IF ( ERRORS ) %] > <div class="dialog alert"> >@@ -122,8 +131,6 @@ > > </div> > [% END %] >- </div> >- </div> > </div> > <div class="yui-b noprint"> > [% INCLUDE 'tools-menu.inc' %] >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 9310
:
14212
|
14327
|
14598