Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
3339 mandeep.dh 1
<script>
2
$(document).ready(function() {
3
    $("#create-ticket-form").validate();
4
});
5
</script>
6
#set($messages = $action.getActionErrors())
7
#if($messages && $messages.size() != 0)
8
    #foreach($message in $messages)
9
        $message <br/>
10
    #end
11
#else
12
<div>
13
    <h1>Create new Ticket</h1>
14
    <form id="create-ticket-form" name="f" action="">
15
        <table>
16
            <colgroup>
17
                <col width="200px"/>
18
                <col width="250px"/>
19
                <col width="120px"/>
20
                <col width="200px"/>
21
                <col width="300px"/>
22
            </colgroup>
3405 mandeep.dh 23
            #if($action.getUserId())
24
            #else
3339 mandeep.dh 25
            <tr >
3405 mandeep.dh 26
                <td >Customer Name: </td>
27
                <td ><input type="text" name="customerName"/> </td>
28
                <td ></td>
29
                <td >Customer Email Id: </td>
30
                <td ><input type="text" name="customerEmailId"/></td>
31
            </tr>
32
            #end
33
            <tr >
3339 mandeep.dh 34
                <td ><label>Assignee:</label></td>
3405 mandeep.dh 35
                #if($action.isAssigneeEditable())
3339 mandeep.dh 36
                    <td >
37
                    <select name="assigneeEmailId" class="width10">
38
                        #foreach( $agent in $action.getAllAgents() )
39
                            #if($agent.getEmailId() == $action.getCurrentAgentEmailId())
40
                                <option value="$agent.getEmailId()" selected="selected">$agent.getEmailId()</option>
41
                            #else
42
                                <option value="$agent.getEmailId()">$agent.getEmailId()</option>
43
                            #end
44
                        #end
45
                    </select>
3405 mandeep.dh 46
                    </td>                    
47
                #else
48
                    <td >$action.getCurrentAgentEmailId()
49
                        <input type="hidden" name="assigneeEmailId" value="$action.getCurrentAgentEmailId()"/>
3339 mandeep.dh 50
                    </td>
51
                #end
3405 mandeep.dh 52
                #if($action.getUserId())
53
                    <td colspan="3"></td>
54
                #else
55
                    <td ></td>
56
                    <td >Customer Mobile No: </td>
57
                    <td ><input type="text" name="customerMobileNumber"/></td>
58
                #end                
3339 mandeep.dh 59
            </tr>
60
            <tr >
61
                <td ><label>Description:</label></td>
3405 mandeep.dh 62
                <td colspan="4"><textarea id="description" name="description"  class="required" rows="3" cols="90"></textarea></td>
3339 mandeep.dh 63
            </tr>
64
            <tr >
65
                <td ><label>Priority:</label></td>
66
                <td >
67
                <select name="priority" class="width10">
68
                    #foreach( $priority in $action.getTicketPriorities() )
69
                        #if($priority.name() == "MEDIUM")
70
                            <option value="$priority.name()" selected="selected">$priority.name()</option>
71
                        #else
72
                            <option value="$priority.name()">$priority.name()</option>
73
                        #end
74
                    #end
75
                </select>
76
                </td>
77
                <td ></td>
78
                <td ><label>Category:</label></td>
79
                <td >
80
                <select name="category" class="width10">
81
                    #foreach( $category in $action.getTicketCategories() )
82
                        #if($category.name() == "RETURN_FORM")
83
                            <option value="$category.name()" selected="selected">$category.name()</option>
84
                        #else
85
                            <option value="$category.name()">$category.name()</option>
86
                        #end
87
                    #end
88
                </select>
89
                </td>
90
            </tr>
91
            #set($userId = $action.getUserId())
92
            <tr >
93
                <td ><label>Order Id:</label></td>
3405 mandeep.dh 94
                <td colspan="4"><input type="text" name="orderId" value=""/></td>
3339 mandeep.dh 95
            </tr>
96
            <tr >
97
                <td colspan="2"></td>
98
                <td colspan="2"><input type="submit" value="Create" /></td>
3405 mandeep.dh 99
                <td >
100
                    #if($userId)
101
                    <input type="hidden" name="userId" value="$userId"/>
102
                    #end
103
                </td>
3339 mandeep.dh 104
            </tr>
105
        </table>
106
    </form>
107
</div>
108
#end