Summary: | Add ids to divs and spans with ids in opac-user.tt | ||
---|---|---|---|
Product: | Koha | Reporter: | Kyle M Hall <kyle.m.hall> |
Component: | OPAC | Assignee: | Owen Leonard <oleonard> |
Status: | CLOSED FIXED | QA Contact: | Ian Walls <koha.sekjal> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | chris, paul.poulain, wizzyrea |
Version: | 3.6 | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Attachments: |
Bug 7876 - Add ids to divs and spans with ids in opac-user.tt
Bug 7876 - Add ids to divs and spans with ids in opac-user.tt Bug 7876 - Followup - Fix closing span tag, add fine amount spans. Bug 7876 - Followup - Fix span tag position, add fine amount spans. Bug 7876 - Followup - Fix span tag position, add fine amount spans. |
Description
Kyle M Hall
2012-04-02 17:56:37 UTC
Created attachment 8784 [details] [review] Bug 7876 - Add ids to divs and spans with ids in opac-user.tt This commit adds an id to each div, and adds spans where there are no appropriate divs to add. In addition, non-static text such as the expiration date are wrapped in a special sub-span so that data can be pulled and reused when customizing via jQuery. Created attachment 8839 [details] [review] Bug 7876 - Add ids to divs and spans with ids in opac-user.tt This commit adds an id to each div, and adds spans where there are no appropriate divs to add. In addition, non-static text such as the expiration date are wrapped in a special sub-span so that data can be pulled and reused when customizing via jQuery. Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com> Span and Div ids are consistent with variable names, so they are easier to use. I'm not 100% sure a new tag is exactly required in all cases; some of those list elements could have gotten ids and kept the DOM a little simpler, but that's really not a big deal at all, and always using spans is consistent and simple. Marking Passed QA. unlucky man, you just come to prove that my pre-apply hook works perfectly fine: failed QA because = koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt contains a tab, must use 4 spaces (+ <span id="renewal_blocked_fines"><li><strong>Please note: </strong> You have <a href="/cgi-bin/koha/opac-account.pl">more than [% renewal_blocked_fines %]</a> in fines. </li></span>) please fix and resubmit (as passed QA directly) ( thanks because the "warn" in the templates helped me to improve the http://wiki.koha-community.org/wiki/Tips_and_tricks git pre-apply hook ) OK, with the help of http://blog.bigballofwax.co.nz/2011/12/15/fixing-whitespace-when-apply-patches-with-git/ I've found how to automatically change tabs into 4 spaces: git config --global core.whitespace trailing-space,space-before-tab,tab-in-indent,tabwidth=4 so, passed QA and pushed ! Created attachment 8877 [details] [review] Bug 7876 - Followup - Fix closing span tag, add fine amount spans. I decided to read the diff on my patch and noticed that the closing tag on one the spans for missing its slash ( <span> instead of </span> ). I also noticed that there were no sub-spans for the the fine amount, so that data wouldn't be re-usable with jQuery. Attached is a new patch to resolve those issues. One small bugfix, and one small enhancement. Applying: Bug 7876 - Followup - Fix closing span tag, add fine amount spans. fatal: sha1 information is lacking or useless (koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt). Repository lacks necessary blobs to fall back on 3-way merge. Cannot fall back to three-way merge. Patch failed at 0001 Bug 7876 - Followup - Fix closing span tag, add fine amount spans. Created attachment 9081 [details] [review] Bug 7876 - Followup - Fix span tag position, add fine amount spans. Span was outside, the if statement, could possible cause problems with jQuery customizations, moved span to inside the conditional. Also added span for the fine amount itself, so that it may be re-used for jQuery customizations. Created attachment 9094 [details] [review] Bug 7876 - Followup - Fix span tag position, add fine amount spans. Span was outside, the if statement, could possible cause problems with jQuery customizations, moved span to inside the conditional. Also added span for the fine amount itself, so that it may be re-used for jQuery customizations. Signed-off-by: Liz Rea <wizzyrea@gmail.com> Passed tests, spans appear to be correct. Template only changing moving <spans> around; marking as Passed QA. follow-up pushed (http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=9094) This bug will be included in the Koha 3.6.5 release. This bug will be included in the Koha 3.6.5 release. |