Subversion Repositories SmartDukaan

Rev

Rev 3947 | Blame | Compare with Previous | Last modification | View Log | RSS feed

<div id="top-infopane">
#set($messages = $action.getActionErrors())
#if($messages && $messages.size() != 0)
    #foreach($message in $messages)
        $message <br/>
    #end
#else
<div id="action-messages">
#set($messages = $action.getActionMessages())
#if($messages && $messages.size() != 0)
    #foreach($message in $messages)
        $message <br />
    #end
#end
</div>
    <table id="tickets" class="display">
        <thead>
            <tr>
                <th>Ticket Id</th>
                #if(!$action.getUserId())
                                        <th>Customer Id</th>
                                #else
                                        <th>Description</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="#" 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" truncatedTextWidth="125">
                            $user.getEmail()
                        </span>
                    </a>
                    #else
                    <span class="truncated-text" truncatedTextWidth="125">
                        $ticket.getCustomerEmailId()
                    </span>
                    #end
                </td>
                                #else
                                        <td class="truncated-text" truncatedTextWidth="125">
                                                $ticket.getDescription()
                                        </td>
                #end
                <td class="truncated-text" truncatedTextWidth="155">$ticket.getCategory().name()</td>
                <td title="$openDate"  class="truncated-text" truncatedTextWidth="90">$openDate</td>
                <td title="$closeDate" class="truncated-text" truncatedTextWidth="90">$closeDate</td>
                <td class="truncated-text" truncatedTextWidth="85">
                    #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