
        <h1>
            <g:if test="${entryList[0].entryType.id == 1}">
                Faults
            </g:if>
            <g:if test="${entryList[0].entryType.id == 2}">
                Causes
            </g:if>
            <g:if test="${entryList[0].entryType.id == 3}">
                Work Done
            </g:if>
            <g:if test="${entryList[0].entryType.id == 6}">
                PM Entries
            </g:if>
        </h1>
        <div class="list">
            <table>
                <thead>
                    <tr>
                        <g:if test="${entryList[0].entryType.id == 6}">
                            <th>
                                <img src="${resource(dir:'images/skin',file:'award_star_silver_3.png')}"
                                        alt="Severity"
                                        title="Highest Severity"  />
                            </th>
                        </g:if>
                        <th>Comment</th>
                        <th>Date Done</th>
                        <g:if test="${(entryList[0].entryType.id == 3) || (entryList[0].entryType.id == 6)}">
                            <th>Duration</th>
                        </g:if>
                        <g:if test="${entryList[0].entryType.id == 1}">
                            <th>Production</th>
                            <th>Down Time</th>
                        </g:if>
                        <th>Entered By</th>
                        <th></th>
                    </tr>
                </thead>
                <tbody>
                    <g:each in="${entryList}" status="i" var="entry">
                            <tr class="${(i % 2) == 0 ? 'clickableOdd' : 'clickableEven'}">

                                <g:if test="${entryList[0]?.entryType?.id == 6}">
                                    <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                        ${entry.highestSeverity.code.encodeAsHTML()}
                                    </td>
                                </g:if>

                                <td width="65%" onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                    ${entry.comment.encodeAsHTML()}
                                </td>

                                <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                    <g:formatDate date="${entry.dateDone}" format="EEE, dd-MMM-yyyy"/>
                                </td>

                                <g:if test="${(entryList[0].entryType.id == 3) || (entryList[0].entryType.id == 6)}">
                                    <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                        ${entry.durationHour}:${entry.durationMinute}
                                    </td>
                                </g:if>

                                <g:if test="${entryList[0].entryType.id == 1}">
                                    <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                        ${fieldValue(bean:entry, field:'productionReference')}
                                    </td>
                                    <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                        ${entry.durationHour}:${entry.durationMinute}
                                    </td>
                                </g:if>

                                <td onclick='window.location = "${request.getContextPath()}/entryDetailed/edit/${entry.id}"'>
                                    ${entry.enteredBy.encodeAsHTML()}
                                </td>

                                <td class="notClickable">
                                    <g:link controller="entryDetailed" action="edit" id="${entry.id}">
                                        <img  src="${resource(dir:'images/skin',file:'database_edit.png')}" alt="Edit" title="Edit" />
                                    </g:link>
                                </td>

                            </tr>
                    </g:each>
                </tbody>
            </table>
        </div>
