Changeset 672 for trunk


Ignore:
Timestamp:
Oct 3, 2010, 10:57:45 PM (14 years ago)
Author:
gav
Message:

Small change to custom jasperButtons taglib.

Location:
trunk/grails-app
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/taglib/CustomTagLib.groovy

    r667 r672  
    201201    def jasperButtons = {attrs ->
    202202        if(!attrs['format']){throw new Exception(message(code:"jasper.taglib.missingAttribute", args:'format'))}
    203         if(!attrs['formName']){throw new Exception(message(code:"jasper.taglib.missingAttribute", args:'formName'))}
    204         String formName = attrs['formName']
     203        if(!attrs['jasper']){throw new Exception(message(code:"jasper.taglib.missingAttribute", args:'jasper'))}
     204        String jasper = attrs['jasper']
    205205        String buttonClass = attrs['class'] ?:  "jasperButton"
    206206        String format = attrs['format'].toUpperCase()
     
    230230            def fmt = it.trim()
    231231            out << """
    232                         <a href="#" class="${buttonClass}" title="${it.trim()}" onClick="return submit_jasperForm('${formName}', '${fmt}')">
     232                        <a href="#" class="${buttonClass}" title="${it.trim()}" onClick="return submit_jasperForm('${jasper}', '${fmt}')">
    233233                        <img border="0" src="${imgSrc}"${heightAttr} /></a>
    234234                        """
  • trunk/grails-app/views/report/inventoryValueDetailed.gsp

    r671 r672  
    6767                                </td>
    6868                                <td valign="top" class="value">
    69                                     <custom:jasperButtons formName="inventoryValueDetailed" format="PDF, XLS" text="PDF" />
     69                                    <custom:jasperButtons jasper="inventoryValueDetailed" format="PDF, XLS" text="PDF" />
    7070                                </td>
    7171                            </tr>
Note: See TracChangeset for help on using the changeset viewer.