Subversion Repositories SmartDukaan

Rev

Rev 3390 | Rev 3422 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

#set($messages = $action.getActionErrors())
#if($messages && $messages.size() != 0)
    #foreach($message in $messages)
        $message <br/>
    #end
#else
<div id="top-infopane">
    <table id="tickets" class="display">
        <thead>
            <tr>
                <th>Ticket Id</th>
                #if(!$action.getUserId())
                 <th>Customer Id</th>
                #end
                <th>Category</th>
                <th>Date Opened</th>
                <th>Date Closed</th>
                <th>Assignee</th>
                <th>Status</th>
                <th>Priority</th>
            </tr>
        </thead>
        <tbody>
            #foreach($ticket in $action.getTickets())
            #set( $ticketId = $ticket.getId() )
            #set($openDate = $action.convertDate($ticket.getOpenDate()))
            #set($closeDate = $action.convertDate($ticket.getCloseDate()))
            <tr id="ticket-row-$ticketId">
                <td>
                    <a alt="Show Ticket Details" title="Show Ticket Details" href="#" userEmailId="$ticket.getCustomerEmailId()" userId="$action.getUserId()" ticketId="$ticketId" class="show-ticket-details">
                        $ticketId
                    </a>
                </td>

                #if(!$action.getUserId())
                <td>
                    #if($ticket.isSetCustomerId())
                    #set( $user = $action.getUser($ticket.getCustomerId()) )
                    <a alt="Show Customer Details" title="Show Customer Details" href="/crm?email=$user.getEmail()">
                        <span class="truncated-text">
                            $user.getEmail()
                        </span>
                    </a>
                    #else
                    <span class="truncated-text">
                        $ticket.getCustomerEmailId()
                    </span>
                    #end
                </td>
                #end
                <td class="truncated-text">$ticket.getCategory().name()</td>
                <td title="$openDate"  class="truncated-text">$openDate</td>
                <td title="$closeDate" class="truncated-text">$closeDate</td>
                <td class="truncated-text">
                    #if($ticket.isSetAssigneeId() && $ticket.getAssigneeId() != 0)
                        $action.getAgent($ticket.getAssigneeId()).getEmailId()
                    #else
                        N/A
                    #end
                </td>
                <td >$ticket.getStatus().name()</td>
                <td >$ticket.getPriority().name()</td>
            </tr>
            #end
        </tbody>
    </table>
</div>
<div id="bottom-infopane">
</div>
#end
<script>
$(document).ready(truncateText(75));
</script>