Changeset 467

Show
Ignore:
Timestamp:
03/30/10 19:29:54 (3 years ago)
Author:
gav
Message:

Only show table headers in search views if there actually are results.

Location:
trunk/grails-app/views
Files:
7 modified

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/views/assetDetailed/search.gsp

    r450 r467  
    9494            </g:if> 
    9595 
    96             <div class="list"> 
    97                 <table> 
    98                     <thead> 
    99                         <tr> 
    100                          
    101                                 <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
     96            <g:if test="${assetInstanceList.size() > 0}"> 
     97                <div class="list"> 
     98                    <table> 
     99                        <thead> 
     100                            <tr> 
     101                             
     102                                <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
    102103 
    103                              <g:sortableColumn property="name" title="Name" params="${filterParams}" /> 
    104                          
    105                             <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
     104                                <g:sortableColumn property="name" title="Name" params="${filterParams}" /> 
     105                             
     106                                <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
    106107 
    107                             <g:sortableColumn property="isActive" title="Is Active" params="${filterParams}" /> 
    108                          
    109                             <g:sortableColumn property="section" title="Section" params="${filterParams}" /> 
     108                                <g:sortableColumn property="isActive" title="Is Active" params="${filterParams}" /> 
     109                             
     110                                <g:sortableColumn property="section" title="Section" params="${filterParams}" /> 
    110111 
    111                             <th></th> 
    112                              
    113                         </tr> 
    114                     </thead> 
    115                     <tbody> 
    116                     <g:each in="${assetInstanceList}" status="i" var="assetInstance"> 
    117                         <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/assetDetailed/show/${assetInstance.id}"'/> 
    118                          
    119                             <td>${fieldValue(bean:assetInstance, field:'id')}</td> 
     112                                <th></th> 
     113                             
     114                            </tr> 
     115                        </thead> 
     116                        <tbody> 
     117                        <g:each in="${assetInstanceList}" status="i" var="assetInstance"> 
     118                            <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/assetDetailed/show/${assetInstance.id}"'/> 
     119                             
     120                                <td>${fieldValue(bean:assetInstance, field:'id')}</td> 
    120121 
    121                             <td>${fieldValue(bean:assetInstance, field:'name')}</td>                         
     122                                <td>${fieldValue(bean:assetInstance, field:'name')}</td> 
    122123 
    123                             <td>${fieldValue(bean:assetInstance, field:'description')}</td> 
     124                                <td>${fieldValue(bean:assetInstance, field:'description')}</td> 
    124125 
    125                             <td>${fieldValue(bean:assetInstance, field:'isActive')}</td> 
     126                                <td>${fieldValue(bean:assetInstance, field:'isActive')}</td> 
    126127 
    127                             <td>${fieldValue(bean:assetInstance, field:'section')}</td> 
     128                                <td>${fieldValue(bean:assetInstance, field:'section')}</td> 
    128129 
    129                             <td> 
    130                                 <g:link action="show" id="${assetInstance.id}"> 
    131                                     <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    132                                 </g:link> 
    133                             </td> 
    134                          
    135                         </tr> 
    136                     </g:each> 
    137                     </tbody> 
    138                 </table> 
    139             </div> 
     130                                <td> 
     131                                    <g:link action="show" id="${assetInstance.id}"> 
     132                                        <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     133                                    </g:link> 
     134                                </td> 
     135                             
     136                            </tr> 
     137                        </g:each> 
     138                        </tbody> 
     139                    </table> 
     140                </div> 
     141            </g:if> 
    140142            <div class="paginateButtons"> 
    141143                <g:paginate total="${assetInstanceTotal}" params="${filterParams}" /> 
  • trunk/grails-app/views/assetSubItemDetailed/search.gsp

    r450 r467  
    7575            </g:if> 
    7676 
    77             <div class="list"> 
    78                 <table> 
    79                     <thead> 
    80                         <tr> 
    81                          
    82                                 <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
     77            <g:if test="${assetSubItemInstanceList.size() > 0}"> 
     78                <div class="list"> 
     79                    <table> 
     80                        <thead> 
     81                            <tr> 
     82                             
     83                                <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
    8384 
    84                              <g:sortableColumn property="name" title="Name" params="${filterParams}" /> 
    85                          
    86                             <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
     85                                <g:sortableColumn property="name" title="Name" params="${filterParams}" /> 
     86                             
     87                                <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
    8788 
    88                             <g:sortableColumn property="isActive" title="Is Active" params="${filterParams}" /> 
     89                                <g:sortableColumn property="isActive" title="Is Active" params="${filterParams}" /> 
    8990 
    90                             <th></th> 
    91                              
    92                         </tr> 
    93                     </thead> 
    94                     <tbody> 
    95                     <g:each in="${assetSubItemInstanceList}" status="i" var="assetSubItemInstance"> 
    96                         <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/assetSubItemDetailed/show/${assetSubItemInstance.id}"'/> 
    97                          
    98                             <td>${fieldValue(bean:assetSubItemInstance, field:'id')}</td> 
     91                                <th></th> 
     92                             
     93                            </tr> 
     94                        </thead> 
     95                        <tbody> 
     96                        <g:each in="${assetSubItemInstanceList}" status="i" var="assetSubItemInstance"> 
     97                            <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/assetSubItemDetailed/show/${assetSubItemInstance.id}"'/> 
     98                             
     99                                <td>${fieldValue(bean:assetSubItemInstance, field:'id')}</td> 
    99100 
    100                             <td>${fieldValue(bean:assetSubItemInstance, field:'name')}</td> 
     101                                <td>${fieldValue(bean:assetSubItemInstance, field:'name')}</td> 
    101102 
    102                             <td>${fieldValue(bean:assetSubItemInstance, field:'description')}</td> 
     103                                <td>${fieldValue(bean:assetSubItemInstance, field:'description')}</td> 
    103104 
    104                             <td>${fieldValue(bean:assetSubItemInstance, field:'isActive')}</td> 
     105                                <td>${fieldValue(bean:assetSubItemInstance, field:'isActive')}</td> 
    105106 
    106                             <td> 
    107                                 <g:link action="show" id="${assetSubItemInstance.id}"> 
    108                                     <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    109                                 </g:link> 
    110                             </td> 
    111                          
    112                         </tr> 
    113                     </g:each> 
    114                     </tbody> 
    115                 </table> 
    116             </div> 
     107                                <td> 
     108                                    <g:link action="show" id="${assetSubItemInstance.id}"> 
     109                                        <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     110                                    </g:link> 
     111                                </td> 
     112                             
     113                            </tr> 
     114                        </g:each> 
     115                        </tbody> 
     116                    </table> 
     117                </div> 
     118            </g:if> 
    117119            <div class="paginateButtons"> 
    118120                <g:paginate total="${assetSubItemInstanceTotal}" params="${filterParams}" /> 
  • trunk/grails-app/views/person/list.gsp

    r450 r467  
    2424 
    2525        <div class="paginateButtons"> 
     26            Results: ${personList.size()} / ${personTotal} 
    2627            <span class="searchButtons"> 
    2728                <filterpane:filterButton text="Search" appliedText="Change Search" /> 
    2829            </span> 
    29             Results:${personTotal} 
    3030        </div> 
    3131 
     
    6767        <br /> 
    6868 
    69         <div class="list"> 
    70             <table> 
    71             <thead> 
    72                 <tr> 
    73                     <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
    74                     <g:sortableColumn property="loginName" title="Login Name" params="${filterParams}" /> 
    75                     <g:sortableColumn property="firstName" title="First Name" params="${filterParams}" /> 
    76                     <g:sortableColumn property="lastName" title="Last Name" params="${filterParams}" /> 
    77                     <g:sortableColumn property="isActive" title="Active" params="${filterParams}" /> 
    78                     <th></th> 
    79                 </tr> 
    80             </thead> 
    81             <tbody> 
    82             <g:each in="${personList}" status="i" var="person"> 
    83                 <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/person/show/${person.id}"'/> 
     69        <g:if test="${personList.size() > 0}"> 
     70            <div class="list"> 
     71                <table> 
     72                <thead> 
     73                    <tr> 
     74                        <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
     75                        <g:sortableColumn property="loginName" title="Login Name" params="${filterParams}" /> 
     76                        <g:sortableColumn property="firstName" title="First Name" params="${filterParams}" /> 
     77                        <g:sortableColumn property="lastName" title="Last Name" params="${filterParams}" /> 
     78                        <g:sortableColumn property="isActive" title="Active" params="${filterParams}" /> 
     79                        <th></th> 
     80                    </tr> 
     81                </thead> 
     82                <tbody> 
     83                <g:each in="${personList}" status="i" var="person"> 
     84                    <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/person/show/${person.id}"'/> 
    8485 
    85                     <td>${person.id}</td> 
    86                     <td>${person.loginName?.encodeAsHTML()}</td> 
    87                     <td>${person.firstName?.encodeAsHTML()}</td> 
    88                     <td>${person.lastName?.encodeAsHTML()}</td> 
    89                     <td>${person.isActive?.encodeAsHTML()}</td> 
    90                     <td> 
    91                         <g:link action="show" id="${person.id}"> 
    92                             <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    93                         </g:link> 
    94                     </td> 
    95                 </tr> 
    96             </g:each> 
    97             </tbody> 
    98             </table> 
    99         </div> 
     86                        <td>${person.id}</td> 
     87                        <td>${person.loginName?.encodeAsHTML()}</td> 
     88                        <td>${person.firstName?.encodeAsHTML()}</td> 
     89                        <td>${person.lastName?.encodeAsHTML()}</td> 
     90                        <td>${person.isActive?.encodeAsHTML()}</td> 
     91                        <td> 
     92                            <g:link action="show" id="${person.id}"> 
     93                                <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     94                            </g:link> 
     95                        </td> 
     96                    </tr> 
     97                </g:each> 
     98                </tbody> 
     99                </table> 
     100            </div> 
     101        </g:if> 
    100102 
    101103        <div class="paginateButtons"> 
  • trunk/grails-app/views/taskDetailed/budget.gsp

    r324 r467  
    2727            <div class="paginateButtons"> 
    2828                <a href='' onclick="showElement('searchPane'); return false;">Quick</a> 
    29                 Results:${taskInstanceTotal} 
     29                Results: ${taskInstanceList.size()} / ${taskInstanceTotal} 
    3030            </div> 
    3131 
    32             <div class="list"> 
    33                 <table> 
    34                     <thead> 
    35                         <tr> 
     32            <g:if test="${taskInstanceList.size() > 0}"> 
     33                <div class="list"> 
     34                    <table> 
     35                        <thead> 
     36                            <tr> 
    3637 
    37                             <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
     38                                <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
    3839 
    39                             <g:sortableColumn property="targetStartDate" title="Target Start Date" params="${filterParams}" /> 
     40                                <g:sortableColumn property="targetStartDate" title="Target Start Date" params="${filterParams}" /> 
    4041 
    41                             <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
     42                                <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
    4243 
    43                             <g:sortableColumn  property="leadPerson" title="Lead Person" params="${filterParams}" /> 
     44                                <g:sortableColumn  property="leadPerson" title="Lead Person" params="${filterParams}" /> 
    4445 
    45                             <g:sortableColumn  property="taskPriority" title="Task Priority" params="${filterParams}" /> 
     46                                <g:sortableColumn  property="taskPriority" title="Task Priority" params="${filterParams}" /> 
    4647 
    47                             <g:sortableColumn  property="taskStatus" title="Task Status" params="${filterParams}" /> 
     48                                <g:sortableColumn  property="taskStatus" title="Task Status" params="${filterParams}" /> 
    4849 
    49                             <th></th> 
     50                                <th></th> 
    5051 
    51                         </tr> 
    52                     </thead> 
    53                     <tbody> 
    54                     <g:each in="${taskInstanceList}" status="i" var="taskInstance"> 
    55                     <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskDetailed/show/${taskInstance.id}"'/> 
     52                            </tr> 
     53                        </thead> 
     54                        <tbody> 
     55                        <g:each in="${taskInstanceList}" status="i" var="taskInstance"> 
     56                        <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskDetailed/show/${taskInstance.id}"'/> 
    5657 
    57                             <td>${fieldValue(bean:taskInstance, field:'id')}</td> 
     58                                <td>${fieldValue(bean:taskInstance, field:'id')}</td> 
    5859 
    59                             <td><g:formatDate date="${taskInstance.targetStartDate}" format="EEE, dd-MMM-yyyy"/></td> 
     60                                <td><g:formatDate date="${taskInstance.targetStartDate}" format="EEE, dd-MMM-yyyy"/></td> 
    6061 
    61                             <td>${fieldValue(bean:taskInstance, field:'description')}</td> 
     62                                <td>${fieldValue(bean:taskInstance, field:'description')}</td> 
    6263 
    63                             <td>${fieldValue(bean:taskInstance, field:'leadPerson')}</td> 
     64                                <td>${fieldValue(bean:taskInstance, field:'leadPerson')}</td> 
    6465 
    65                             <td>${fieldValue(bean:taskInstance, field:'taskPriority')}</td> 
     66                                <td>${fieldValue(bean:taskInstance, field:'taskPriority')}</td> 
    6667 
    67                             <td>${fieldValue(bean:taskInstance, field:'taskStatus')}</td> 
     68                                <td>${fieldValue(bean:taskInstance, field:'taskStatus')}</td> 
    6869 
    69                             <td> 
    70                                 <g:link action="show" id="${taskInstance.id}"> 
    71                                     <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    72                                 </g:link> 
    73                             </td> 
     70                                <td> 
     71                                    <g:link action="show" id="${taskInstance.id}"> 
     72                                        <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     73                                    </g:link> 
     74                                </td> 
    7475 
    75                         </tr> 
    76                     </g:each> 
    77                     </tbody> 
    78                 </table> 
    79             </div> 
     76                            </tr> 
     77                        </g:each> 
     78                        </tbody> 
     79                    </table> 
     80                </div> 
     81            </g:if> 
    8082            <div class="paginateButtons"> 
    8183                <g:paginate total="${taskInstanceTotal}" params="${filterParams}" /> 
  • trunk/grails-app/views/taskDetailed/search.gsp

    r466 r467  
    8484            </g:if> 
    8585 
    86             <div class="list"> 
    87                 <table> 
    88                     <thead> 
    89                         <tr> 
    90  
    91                             <custom:sortableColumnWithImg property="attentionFlag" 
    92                                                                                             imgSrc="${resource(dir:'images/skin',file:'flag_red.png')}" 
    93                                                                                             imgAlt="Flag" params="${filterParams}" /> 
    94  
    95                             <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
    96  
    97                             <g:sortableColumn property="targetStartDate" title="Target Start Date" params="${filterParams}" /> 
    98  
    99                             <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
    100  
    101                             <g:sortableColumn  property="taskPriority" title="Task Priority" params="${filterParams}" /> 
    102  
    103                             <g:sortableColumn  property="taskStatus" title="Task Status" params="${filterParams}" /> 
    104  
    105                             <th></th> 
    106  
    107                         </tr> 
    108                     </thead> 
    109                     <tbody> 
    110                     <g:each in="${taskInstanceList}" status="i" var="taskInstance"> 
    111                     <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskDetailed/show/${taskInstance.id}"'/> 
    112  
    113                             <td class="idColumn"> 
    114                                 <g:if test="${taskInstance.attentionFlag}"> 
    115                                     <img  src="${resource(dir:'images/skin',file:'flag_red.png')}" alt="Flag" /> 
    116                                 </g:if> 
    117                             </td> 
    118  
    119                             <td class="idColumn">${fieldValue(bean:taskInstance, field:'id')}</td> 
    120  
    121                             <td><g:formatDate date="${taskInstance.targetStartDate}" format="EEE, dd-MMM-yyyy"/></td> 
    122  
    123                             <td>${fieldValue(bean:taskInstance, field:'description')}</td> 
    124  
    125                             <td>${fieldValue(bean:taskInstance, field:'taskPriority')}</td> 
    126  
    127                             <td>${fieldValue(bean:taskInstance, field:'taskStatus')}</td> 
    128  
    129                             <td> 
    130                                 <g:link action="show" id="${taskInstance.id}"> 
    131                                     <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    132                                 </g:link> 
    133                             </td> 
    134  
    135                         </tr> 
    136                     </g:each> 
    137                     </tbody> 
    138                 </table> 
    139             </div> 
     86            <g:if test="${taskInstanceList.size() > 0}"> 
     87                <div class="list"> 
     88                    <table> 
     89                        <thead> 
     90                            <tr> 
     91 
     92                                <custom:sortableColumnWithImg property="attentionFlag" 
     93                                                                                                imgSrc="${resource(dir:'images/skin',file:'flag_red.png')}" 
     94                                                                                                imgAlt="Flag" params="${filterParams}" /> 
     95 
     96                                <g:sortableColumn property="id" title="Id" params="${filterParams}" /> 
     97 
     98                                <g:sortableColumn property="targetStartDate" title="Target Start Date" params="${filterParams}" /> 
     99 
     100                                <g:sortableColumn property="description" title="Description" params="${filterParams}" /> 
     101 
     102                                <g:sortableColumn  property="taskPriority" title="Task Priority" params="${filterParams}" /> 
     103 
     104                                <g:sortableColumn  property="taskStatus" title="Task Status" params="${filterParams}" /> 
     105 
     106                                <th></th> 
     107 
     108                            </tr> 
     109                        </thead> 
     110                        </tbody> 
     111                        <tbody> 
     112                        <g:each in="${taskInstanceList}" status="i" var="taskInstance"> 
     113                        <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskDetailed/show/${taskInstance.id}"'/> 
     114 
     115                                <td class="idColumn"> 
     116                                    <g:if test="${taskInstance.attentionFlag}"> 
     117                                        <img  src="${resource(dir:'images/skin',file:'flag_red.png')}" alt="Flag" /> 
     118                                    </g:if> 
     119                                </td> 
     120 
     121                                <td class="idColumn">${fieldValue(bean:taskInstance, field:'id')}</td> 
     122 
     123                                <td><g:formatDate date="${taskInstance.targetStartDate}" format="EEE, dd-MMM-yyyy"/></td> 
     124 
     125                                <td>${fieldValue(bean:taskInstance, field:'description')}</td> 
     126 
     127                                <td>${fieldValue(bean:taskInstance, field:'taskPriority')}</td> 
     128 
     129                                <td>${fieldValue(bean:taskInstance, field:'taskStatus')}</td> 
     130 
     131                                <td> 
     132                                    <g:link action="show" id="${taskInstance.id}"> 
     133                                        <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     134                                    </g:link> 
     135                                </td> 
     136 
     137                            </tr> 
     138                        </g:each> 
     139                        </tbody> 
     140                    </table> 
     141                </div> 
     142            </g:if> 
    140143            <div class="paginateButtons"> 
    141144                <g:paginate total="${taskInstanceTotal}" params="${filterParams}" /> 
  • trunk/grails-app/views/taskDetailed/searchCalendar.gsp

    r450 r467  
    1414 
    1515        <div class="body"> 
    16             <g:if test="${flash.message}"> 
    17                 <div class="message">${flash.message}</div> 
    18             </g:if> 
    1916            <g:if test="${params.message}"> 
    2017                <div class="message">${params.message}</div> 
    2118            </g:if> 
     19            <g:render template="/shared/messages" /> 
    2220            <g:hasErrors bean="${appCore}"> 
    2321                <div class="errors"> 
     
    3735                    <a href='' onclick="showElement('searchPane'); return false;">Quick</a> 
    3836                </span> 
    39                 Results:${taskInstanceTotal} 
     37                Results: ${taskInstanceList.size()} / ${taskInstanceTotal} 
    4038                <span class="searchButtons"> 
    4139                    <filterpane:filterButton text="Advanced" appliedText="Advanced" /> 
    4240                </span> 
    4341            </div> 
    44             <richui:calendarMonthView items="${taskInstanceList}" 
    45                                                                     createLink="true" 
    46                                                                     constraintDateFields="['targetStartDate']" 
    47                                                                     month="${new Date()}" 
    48                                                                     controller="taskDetailed" 
    49                                                                     action="show" 
    50                                                                     dayAction="create"/> 
     42            <g:if test="${taskInstanceList.size() > 0}"> 
     43                <richui:calendarMonthView items="${taskInstanceList}" 
     44                                                                        createLink="true" 
     45                                                                        constraintDateFields="['targetStartDate']" 
     46                                                                        month="${new Date()}" 
     47                                                                        controller="taskDetailed" 
     48                                                                        action="show" 
     49                                                                        dayAction="create"/> 
     50            </g:if> 
     51 
    5152            <filterpane:filterPane domainBean="Task" 
    5253                                    title="Advanced Search" 
     
    113114                        <input type="button" value="${g.message(code:'fp.tag.filterPane.button.cancel.text', default:'Cancel')}" onclick="return hideElement('searchPane');" /> 
    114115                    </span> 
    115 <!--                    <span class="button"> 
    116                         <input type="button" value="${g.message(code:'fp.tag.filterPane.button.clear.text', default:'Clear')}" onclick="return clearFilterPane('searchForm');" /> 
    117                     </span> 
    118                     <span class="button"> 
    119                         <g:actionSubmit class="search" value="Search" /> 
    120                     </span>--> 
    121116                </div> 
    122117            </g:form> 
    123118        </div> <!-- end search pane --> 
    124          
     119 
    125120    </body> 
    126121</html> 
  • trunk/grails-app/views/taskProcedureDetailed/list.gsp

    r450 r467  
    2828                    <filterpane:filterButton text="Search" appliedText="Change Search" /> 
    2929                </span> 
    30                 Results:${taskProcedureInstanceTotal} 
     30                Results: ${taskProcedureInstanceList.size()} / ${taskProcedureInstanceTotal} 
    3131            </div> 
    3232 
    33             <div class="list"> 
    34                 <table> 
    35                     <thead> 
    36                         <tr> 
    37                          
    38                                 <g:sortableColumn property="id" title="Id"  params="${filterParams}" /> 
    39                          
    40                                 <g:sortableColumn property="name" title="Name"  params="${filterParams}" /> 
    41                          
    42                                 <g:sortableColumn property="description" title="Description"  params="${filterParams}" /> 
    43                          
    44                                 <g:sortableColumn property="isActive" title="Is Active"  params="${filterParams}" /> 
    4533 
    46                             <th></th> 
    47                          
    48                         </tr> 
    49                     </thead> 
    50                     <tbody> 
    51                     <g:each in="${taskProcedureInstanceList}" status="i" var="taskProcedureInstance"> 
    52                         <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskProcedureDetailed/show/${taskProcedureInstance.id}"'/> 
    53                          
    54                             <td>${fieldValue(bean:taskProcedureInstance, field:'id')}</td> 
    55                          
    56                             <td>${fieldValue(bean:taskProcedureInstance, field:'name')}</td> 
    57                          
    58                             <td>${fieldValue(bean:taskProcedureInstance, field:'description')}</td> 
    59                          
    60                             <td>${fieldValue(bean:taskProcedureInstance, field:'isActive')}</td> 
     34            <g:if test="${taskProcedureInstanceList.size() > 0}"> 
     35                <div class="list"> 
     36                    <table> 
     37                        <thead> 
     38                            <tr> 
    6139                             
    62                             <td> 
    63                                 <g:link action="show" id="${taskProcedureInstance.id}"> 
    64                                     <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
    65                                 </g:link> 
    66                             </td> 
    67                          
    68                         </tr> 
    69                     </g:each> 
    70                     </tbody> 
    71                 </table> 
    72             </div> 
     40                                <g:sortableColumn property="id" title="Id"  params="${filterParams}" /> 
     41                             
     42                                <g:sortableColumn property="name" title="Name"  params="${filterParams}" /> 
     43                             
     44                                <g:sortableColumn property="description" title="Description"  params="${filterParams}" /> 
     45                             
     46                                <g:sortableColumn property="isActive" title="Is Active"  params="${filterParams}" /> 
     47 
     48                                <th></th> 
     49                             
     50                            </tr> 
     51                        </thead> 
     52                        <tbody> 
     53                        <g:each in="${taskProcedureInstanceList}" status="i" var="taskProcedureInstance"> 
     54                            <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}" onclick='window.location = "${request.getContextPath()}/taskProcedureDetailed/show/${taskProcedureInstance.id}"'/> 
     55                             
     56                                <td>${fieldValue(bean:taskProcedureInstance, field:'id')}</td> 
     57                             
     58                                <td>${fieldValue(bean:taskProcedureInstance, field:'name')}</td> 
     59                             
     60                                <td>${fieldValue(bean:taskProcedureInstance, field:'description')}</td> 
     61                             
     62                                <td>${fieldValue(bean:taskProcedureInstance, field:'isActive')}</td> 
     63                                 
     64                                <td> 
     65                                    <g:link action="show" id="${taskProcedureInstance.id}"> 
     66                                        <img  src="${resource(dir:'images/skin',file:'database_go.png')}" alt="Show" /> 
     67                                    </g:link> 
     68                                </td> 
     69                             
     70                            </tr> 
     71                        </g:each> 
     72                        </tbody> 
     73                    </table> 
     74                </div> 
     75            </g:if> 
    7376 
    7477            <div class="paginateButtons">