| 162 |
naveen |
1 |
<!DOCTYPE html PUBLIC
|
|
|
2 |
"-//W3C//DTD XHTML 1.1 Transitional//EN"
|
|
|
3 |
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
|
4 |
|
|
|
5 |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
|
6 |
<head>
|
|
|
7 |
<title>List of Entities</title>
|
| 4129 |
mandeep.dh |
8 |
<link rel="stylesheet" href="css/colorbox.css" type="text/css" />
|
| 4755 |
amit.gupta |
9 |
<link rel="stylesheet" href="css/datatable.css" type="text/css" />
|
| 242 |
naveen |
10 |
<script type="text/javascript" src="jquery/jquery-1.4.2.js"></script>
|
|
|
11 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.core.js"></script>
|
|
|
12 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.widget.js"></script>
|
|
|
13 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.position.js"></script>
|
|
|
14 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.autocomplete.js"></script>
|
|
|
15 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.dialog.js"></script>
|
|
|
16 |
<script type="text/javascript" src="jquery/validation/jquery.validate.js"></script>
|
| 4755 |
amit.gupta |
17 |
<script type="text/javascript" src="jquery/jquery.dataTables.js"></script>
|
| 242 |
naveen |
18 |
|
|
|
19 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.mouse.js"></script>
|
|
|
20 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.draggable.js"></script>
|
|
|
21 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.resizable.js"></script>
|
|
|
22 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.core.js"></script>
|
|
|
23 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.blind.js"></script>
|
|
|
24 |
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.drop.js"></script>
|
| 516 |
rajveer |
25 |
<script type="text/javascript" src="jquery/jquery.chained.js"></script>
|
| 579 |
rajveer |
26 |
<script type="text/javascript" src="jquery/jquery.tablesorter.js"></script>
|
| 4129 |
mandeep.dh |
27 |
<script type="text/javascript" src="jquery/thirdparty/jquery.colorbox-min.js"></script>
|
|
|
28 |
<script type="text/javascript" src="js/common.js"></script>
|
|
|
29 |
<script type="text/javascript" src="js/events.js"></script>
|
| 4755 |
amit.gupta |
30 |
<script type="text/javascript" src="js/entity-index.js"></script>
|
| 19601 |
amit.gupta |
31 |
<script type="text/javascript" src="js/tableExport.js"></script>
|
|
|
32 |
<script type="text/javascript" src="js/jquery.base64.js"></script>
|
| 4755 |
amit.gupta |
33 |
<script type="text/javascript">
|
|
|
34 |
Entity = {};
|
|
|
35 |
Entity.arr = #generateEntities($entitiesState);
|
|
|
36 |
Entity.arr.splice(-1,1);
|
|
|
37 |
Entity.arr.reverse();
|
|
|
38 |
Entity.start = $entitiesState.size();
|
| 579 |
rajveer |
39 |
|
| 516 |
rajveer |
40 |
</script>
|
|
|
41 |
|
| 579 |
rajveer |
42 |
|
| 198 |
naveen |
43 |
<link type="text/css" href="jquery/jqueryui/themes/ui-lightness/jquery.ui.all.css" rel="stylesheet" />
|
| 162 |
naveen |
44 |
<style type="text/css">
|
| 212 |
naveen |
45 |
|
|
|
46 |
* { font-family: Verdana; font-size: 96%; }
|
| 4755 |
amit.gupta |
47 |
fieldset.label { width: 10em; float: left; }
|
| 212 |
naveen |
48 |
label.error { float: none; color: red; padding-left: .5em; vertical-align: top; }
|
|
|
49 |
p { clear: both; }
|
|
|
50 |
.submit { margin-left: 12em; }
|
|
|
51 |
em { font-weight: bold; padding-right: 1em; vertical-align: top; }
|
|
|
52 |
|
| 162 |
naveen |
53 |
table {
|
|
|
54 |
border-width: 1px 1px 1px 1px;
|
|
|
55 |
border-spacing: 2px;
|
|
|
56 |
border-style: outset outset outset outset;
|
|
|
57 |
border-color: gray gray gray gray;
|
|
|
58 |
border-collapse: separate;
|
|
|
59 |
background-color: white;
|
|
|
60 |
}
|
|
|
61 |
th {
|
|
|
62 |
border-width: 1px 1px 1px 1px;
|
|
|
63 |
padding: 1px 1px 1px 1px;
|
|
|
64 |
border-style: inset inset inset inset;
|
|
|
65 |
border-color: gray gray gray gray;
|
|
|
66 |
background-color: white;
|
|
|
67 |
-moz-border-radius: 0px 0px 0px 0px;
|
|
|
68 |
}
|
|
|
69 |
td {
|
|
|
70 |
border-width: 1px 1px 1px 1px;
|
|
|
71 |
padding: 1px 1px 1px 1px;
|
|
|
72 |
border-style: inset inset inset inset;
|
|
|
73 |
border-color: gray gray gray gray;
|
|
|
74 |
background-color: white;
|
|
|
75 |
-moz-border-radius: 0px 0px 0px 0px;
|
|
|
76 |
}
|
| 242 |
naveen |
77 |
div.dialog {
|
|
|
78 |
padding:12px;
|
|
|
79 |
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif";
|
|
|
80 |
}
|
| 162 |
naveen |
81 |
</style>
|
| 242 |
naveen |
82 |
|
| 162 |
naveen |
83 |
</head>
|
|
|
84 |
<body>
|
| 208 |
naveen |
85 |
<div>
|
| 1051 |
rajveer |
86 |
<span align="right"> Welcome $action.getUsername() <a href="$request.contextPath/logout">logout</a></span>
|
|
|
87 |
</div>
|
|
|
88 |
<div>
|
| 2768 |
mandeep.dh |
89 |
<p/>
|
| 2838 |
mandeep.dh |
90 |
<span align="right"> <a href="$request.contextPath/special-page">Go to special pages</a></span>
|
| 6519 |
kshitij.so |
91 |
<span align="right"> <a href="$request.contextPath/tag-page">Create Tag</a></span>
|
| 5074 |
amit.gupta |
92 |
<span align="right"> <a href="$request.contextPath/synonym">Synonyms Map</a></span>
|
| 2768 |
mandeep.dh |
93 |
<p/>
|
| 2276 |
rajveer |
94 |
|
|
|
95 |
<p/>
|
|
|
96 |
<span align="right"> <a href="$request.contextPath/helpdoc">Go to helpdoc</a></span>
|
| 19601 |
amit.gupta |
97 |
<span align="right"> <a href="javascript:void(0)" onclick="exportEntities()">Export Entities</a></span>
|
| 19685 |
kshitij.so |
98 |
<span align="right"> <a href="$request.contextPath/entity-upload">Upload Entities</a></span>
|
| 2276 |
rajveer |
99 |
<p/>
|
| 162 |
naveen |
100 |
<h1>Entities</h1>
|
| 242 |
naveen |
101 |
|
| 1051 |
rajveer |
102 |
<div style="color:green;">
|
| 242 |
naveen |
103 |
#sactionmessage()
|
| 1051 |
rajveer |
104 |
</div>
|
|
|
105 |
<div style="color:red;">
|
|
|
106 |
#sactionerror()
|
|
|
107 |
</div>
|
| 2095 |
rajveer |
108 |
|
|
|
109 |
#set($inconsistententities = $action.getInconsistentEntities())
|
| 2097 |
rajveer |
110 |
|
|
|
111 |
#if($inconsistententities && !$inconsistententities.isEmpty())
|
|
|
112 |
<div style="color:red;">
|
| 2095 |
rajveer |
113 |
Following entities are not yet complete.
|
|
|
114 |
<ul>
|
|
|
115 |
#foreach($inconsistententity in $inconsistententities)
|
|
|
116 |
<li>$inconsistententity</li>
|
|
|
117 |
#end
|
|
|
118 |
</ul>
|
|
|
119 |
Please complete them before 2.45 PM. Otherwise these entities will be removed from www.saholic.com.
|
|
|
120 |
</div>
|
|
|
121 |
#end
|
| 1152 |
rajveer |
122 |
<!--
|
| 1051 |
rajveer |
123 |
<a href="$request.contextPath/entity/new">Create New</a>
|
| 1152 |
rajveer |
124 |
-->
|
| 162 |
naveen |
125 |
<p></p>
|
| 1152 |
rajveer |
126 |
#set ( $entitiesState = $action.getEntitiesState() )
|
| 1051 |
rajveer |
127 |
#set ( $users = $action.getAllUserNames() )
|
| 250 |
naveen |
128 |
|
|
|
129 |
<div>
|
| 4755 |
amit.gupta |
130 |
<table id="myTable" style="width:100%"></table>
|
| 250 |
naveen |
131 |
</div>
|
| 1051 |
rajveer |
132 |
</div>
|
| 250 |
naveen |
133 |
|
| 1051 |
rajveer |
134 |
<div id="dialog" title="">
|
|
|
135 |
</div>
|
| 579 |
rajveer |
136 |
|
| 1051 |
rajveer |
137 |
<div style="display:none;">
|
|
|
138 |
<div id="dialog-form" title="Select an user to assign">
|
|
|
139 |
<p class="validateTips">All form fields are required.</p>
|
|
|
140 |
<form>
|
|
|
141 |
<fieldset>
|
|
|
142 |
<label for="user">Username</label>
|
|
|
143 |
<select id="username" name="username">
|
|
|
144 |
#foreach($user in $users)
|
|
|
145 |
<option value="$user" class="text ui-widget-content ui-corner-all">$user</option>
|
| 579 |
rajveer |
146 |
#end
|
| 1051 |
rajveer |
147 |
</select>
|
| 579 |
rajveer |
148 |
|
| 1051 |
rajveer |
149 |
</fieldset>
|
|
|
150 |
</form>
|
|
|
151 |
</div>
|
| 5012 |
amit.gupta |
152 |
<div style="display:none;">
|
|
|
153 |
<div id="dialog-duplicate" title="Enter the entity id.">
|
|
|
154 |
<p class="validateTips">Import from existing entity.</p>
|
|
|
155 |
<form>
|
|
|
156 |
<fieldset>
|
|
|
157 |
<label for="entityId">Existing Entity id</label>
|
|
|
158 |
<input type="text" id="dup-entity" class="required number" name="dup-entity"/>
|
|
|
159 |
</fieldset>
|
|
|
160 |
</form>
|
|
|
161 |
</div>
|
| 250 |
naveen |
162 |
</div>
|
| 4129 |
mandeep.dh |
163 |
<div id="items">
|
|
|
164 |
</div>
|
| 250 |
naveen |
165 |
</body>
|
|
|
166 |
</html>
|
|
|
167 |
|
| 1152 |
rajveer |
168 |
#macro (drawAllEntities $entitiesState)
|
| 4755 |
amit.gupta |
169 |
<table id="myTable" style="display:none">
|
| 579 |
rajveer |
170 |
<thead>
|
|
|
171 |
<tr style="border: 1px">
|
| 4755 |
amit.gupta |
172 |
<th rowspan="2">#</th>
|
|
|
173 |
<th rowspan="2">Entity ID</th>
|
|
|
174 |
<th rowspan="2">Category</th>
|
|
|
175 |
<th rowspan="2">Brand</th>
|
|
|
176 |
<th rowspan="2">Model Name</th>
|
|
|
177 |
<th rowspan="2">Model Number</th>
|
|
|
178 |
<th rowspan="2">Item details</th>
|
|
|
179 |
<th rowspan="2">Current Status</th>
|
|
|
180 |
<th rowspan="2">Created By</th>
|
|
|
181 |
<th rowspan="2">Assigned To</th>
|
|
|
182 |
<th rowspan="2">Completed By</th>
|
|
|
183 |
<th rowspan="1" colspan="5">Actions</th>
|
| 579 |
rajveer |
184 |
</tr>
|
| 4755 |
amit.gupta |
185 |
<tr style="display:none">
|
|
|
186 |
<th rowspan="1" colspan="1"></th>
|
|
|
187 |
<th rowspan="1" colspan="1"></th>
|
|
|
188 |
<th rowspan="1" colspan="1"></th>
|
|
|
189 |
<th rowspan="1" colspan="1"></th>
|
|
|
190 |
<th rowspan="1" colspan="1"></th>
|
|
|
191 |
</tr>
|
| 579 |
rajveer |
192 |
</thead>
|
|
|
193 |
<tbody>
|
| 1152 |
rajveer |
194 |
|
|
|
195 |
|
|
|
196 |
#foreach ( $entityid in $entitiesState.keySet() )
|
|
|
197 |
#set($entityState = $entitiesState.get($entityid))
|
| 579 |
rajveer |
198 |
<tr style="border: 1px">
|
|
|
199 |
<td>$velocityCount</td>
|
|
|
200 |
<td><a href="/content/entity/$entityid/edit">$entityid</a></td>
|
| 1152 |
rajveer |
201 |
<td>$action.getCategoryName($entityState.getCategoryID())</td>
|
|
|
202 |
<td>$entityState.getBrand()</td>
|
| 2605 |
rajveer |
203 |
<td>$entityState.getModelName()</td>
|
| 1152 |
rajveer |
204 |
<td>$entityState.getModelNumber()</td>
|
| 4129 |
mandeep.dh |
205 |
<td>
|
|
|
206 |
<a class="details-from-catalog" entityId="$entityid" href="#">
|
|
|
207 |
see items
|
|
|
208 |
</a>
|
|
|
209 |
</td>
|
| 1051 |
rajveer |
210 |
<td>$entityState.getStatus()</td>
|
|
|
211 |
<td>$entityState.getCreatedBy()</td>
|
|
|
212 |
<td>#if($entityState.getAssignedTo())$entityState.getAssignedTo()#end</td>
|
|
|
213 |
<td>#if($entityState.getCompletedBy())$entityState.getCompletedBy()#end</td>
|
| 579 |
rajveer |
214 |
</tr>
|
|
|
215 |
#end
|
|
|
216 |
</tbody>
|
|
|
217 |
</table>
|
|
|
218 |
|
|
|
219 |
#end
|
| 4755 |
amit.gupta |
220 |
|
|
|
221 |
|
|
|
222 |
#macro (generateEntities $entitiesState)
|
|
|
223 |
[
|
|
|
224 |
#foreach ( $entityid in $entitiesState.keySet() )
|
|
|
225 |
#set($entityState = $entitiesState.get($entityid))
|
|
|
226 |
[$velocityCount,
|
|
|
227 |
$entityid,
|
|
|
228 |
"$action.getCategoryName($entityState.getCategoryID())",
|
| 5180 |
amit.gupta |
229 |
"$action.getJavascriptSafe($entityState.getBrand())",
|
|
|
230 |
"$action.getJavascriptSafe($entityState.getModelName())",
|
|
|
231 |
"$action.getJavascriptSafe($entityState.getModelNumber())",
|
| 4755 |
amit.gupta |
232 |
$entityid,
|
|
|
233 |
"$entityState.getStatus()",
|
| 6877 |
amit.gupta |
234 |
"#if($entityState.getMerkedReadyOn())$action.getFormattedDate($entityState.getMerkedReadyOn())#end",
|
| 4755 |
amit.gupta |
235 |
"#if($entityState.getAssignedTo())$entityState.getAssignedTo()#end",
|
|
|
236 |
"#if($entityState.getCompletedBy())$entityState.getCompletedBy()#end",
|
|
|
237 |
$entityid],
|
|
|
238 |
#end
|
|
|
239 |
0]
|
|
|
240 |
#end
|