Subversion Repositories SmartDukaan

Rev

Rev 31568 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
27873 amit.gupta 1
<style>
28270 tejbeer 2
.grab {
3
	cursor: grab;
4
}
26732 amit.gupta 5
 
28270 tejbeer 6
.grabbed {
7
	box-shadow: 0 0 13px #000;
8
}
26732 amit.gupta 9
 
28270 tejbeer 10
.grabCursor, .grabCursor * {
11
	cursor: grabbing !important;
12
}
13
</style>
26732 amit.gupta 14
 
28270 tejbeer 15
<script>
16
	$(".edit-web-listing").click(function() {
17
		$("#web-editable-container").modal({
18
			backdrop : false
19
		});
20
 
21
	});
22
</script>
23
 
26732 amit.gupta 24
<section class="wrapper">
25
	<div class="row">
26
		<div class="col-lg-12">
28270 tejbeer 27
			<h3 class="page-header">
28
				<i class="icon_document_alt"></i>Web Listing
29
			</h3>
26732 amit.gupta 30
			<ol class="breadcrumb">
28270 tejbeer 31
				<li><i class="fa fa-home"></i><a
32
					href="${rc.contextPath}/dashboard">Home</a></li>
26732 amit.gupta 33
				<li><i class="icon_document_alt"></i>Web Listing</li>
34
			</ol>
35
		</div>
36
	</div>
37
	<div class="col-lg-6">
38
		<div class="row">
28270 tejbeer 39
			<form class="form-inline"
40
				onsubmit="event.preventDefault();addWebListing();">
41
				<div class="form-group">
42
					<label for="web-listing-title">Title</label> <input type="text"
43
						class="form-control" id="web-listing-title"
44
						placeholder="Best Sellers">
45
				</div>
46
				<div class="form-group">
47
					<label for="web-listing-url">Url</label> <input
48
						class="form-control" id="web-listing-url"
49
						placeholder="best-sellers">
50
				</div>
31570 tejbeer 51
 
52
				<div class="form-group">
53
					<label for="web-listing-solrQuery">Solr Query</label> <input
54
						class="form-control" id="web-listing-solrQuery"
55
						placeholder="Solr Query">
56
				</div>
28270 tejbeer 57
 
31447 tejbeer 58
 
59
				<div class="form-group" style="margin-top: 15px">
60
 
61
			      <div class="form-group">
28270 tejbeer 62
					<label for="web-listing-url">Rank</label> <input
63
						class="form-control" id="web-listing-rank" placeholder="Rank">
31447 tejbeer 64
				  </div>
65
					<div class="form-group">
66
					  	<label for="web-listing-source">Source</label>
67
					    <select class="form-control" id="listingSource"
68
                                            name="listingSource" placeholder="Source">
69
                                        <option value="" disabled selected>Source</option>
70
                                        #foreach($source in $sources)
71
                                            <option value="$source">$source</option>
72
                                        #end
73
                                    </select>
74
                    </div>
31568 tejbeer 75
 
76
                    	<div class="form-group">
77
					  	<label for="web-listing-type">Type</label>
78
					    <select class="form-control" id="webType"
79
                                            name="webType" placeholder="Type">
80
                                        <option value="" disabled selected>Type</option>
81
                                        #foreach($type in $types)
82
                                            <option value="$type">$type</option>
83
                                        #end
84
                                    </select>
85
                    </div>
31447 tejbeer 86
 
87
			    </div>
88
 
28301 tejbeer 89
				<div class="form-group" style="margin-top: 15px">
31447 tejbeer 90
 
91
 
28301 tejbeer 92
					<div class="form-group">
28567 tejbeer 93
						<label for="web-listing-bannerurl">Banner Url</label>(365*183)<input
28301 tejbeer 94
							class="form-control" id="web-listing-bannerurl"
95
							placeholder="Banner Url">
96
					</div>
28566 tejbeer 97
 
98
					<div class="form-group">
28567 tejbeer 99
						<label for="web-listing-headerurl">Header Url</label>(272*405)<input
28566 tejbeer 100
							class="form-control" id="web-listing-headerurl"
101
							placeholder="Header Url">
102
					</div>
31447 tejbeer 103
 
104
 
28301 tejbeer 105
					<button type="submit" class="btn btn-default">Add</button>
106
				</div>
26732 amit.gupta 107
			</form>
28270 tejbeer 108
 
109
			<div class="col-lg-4" style="padding: 15px">
110
				<button id="weblisting-update-rank" disabled class="btn btn-default"
111
					type="button">Update Rank</button>
112
			</div>
113
 
26732 amit.gupta 114
		</div>
28270 tejbeer 115
 
26732 amit.gupta 116
		<div class="row">
28270 tejbeer 117
			<table class="table table-border table-condensed table-bordered"
118
				id="catalog-feature-table">
26732 amit.gupta 119
				<thead>
120
					<tr>
26738 amit.gupta 121
						<th>Id</th>
122
						<th>Title</th>
123
						<th>Rank</th>
124
						<th>Url</th>
28301 tejbeer 125
						<th>Banner Url</th>
31447 tejbeer 126
						<th>Source</th>
127
 
28270 tejbeer 128
						<th>Active</th>
129
						<th>Edit</th>
26732 amit.gupta 130
					</tr>
131
				</thead>
28270 tejbeer 132
				<tbody id="web-listing-tbody">
133
					#foreach($webListing in $webListings)
27873 amit.gupta 134
					<tr class="grab" data-id="$webListing.getId()">
26738 amit.gupta 135
						<td>$webListing.getId()</td>
28270 tejbeer 136
						<td><a href="javascript:void(0)"
137
							data-id="$webListing.getId()" class="listing-details">$webListing.getTitle()</a></td>
26738 amit.gupta 138
						<td>$webListing.getRank()</td>
28301 tejbeer 139
						<td>$webListing.getUrl()</td> #if($webListing.getBannerUrl())
140
						<td>$webListing.getBannerUrl()</td> #else
31447 tejbeer 141
						<td></td> #end 
142
 
31449 tejbeer 143
						  <td>$webListing.getTargetSource()</td>
31447 tejbeer 144
 
145
						#if($webListing.isActive())
28270 tejbeer 146
						<td><a data-id="$webListing.getId()"
28342 tejbeer 147
							data-active="$webListing.isActive()" class="web-listing-active">Mark
148
								InActive</a></td> #else
28270 tejbeer 149
						<td><a data-id="$webListing.getId()"
28342 tejbeer 150
							data-active="$webListing.isActive()" class="web-listing-active">Mark
151
								Active</a></td> #end
28270 tejbeer 152
						<td><a data-id="$webListing.getId()"
153
							data-target="#web-listing-edit-modal" data-toggle="modal"
154
							class="web-listing-id">edit</a></td>
26732 amit.gupta 155
					</tr>
28270 tejbeer 156
					#end
157
 
158
 
26732 amit.gupta 159
				</tbody>
160
			</table>
161
		</div>
162
	</div>
31447 tejbeer 163
	<div class="col-lg-5" style="float:right">
26738 amit.gupta 164
		<div id="feature-table">
165
			<div class="row">
28270 tejbeer 166
				<div class="col-lg-12 web-products-container"></div>
167
			</div>
26738 amit.gupta 168
		</div>
169
	</div>
28270 tejbeer 170
</section>
26732 amit.gupta 171
 
28270 tejbeer 172
<div class="web-listing-edit-container">
26732 amit.gupta 173
 
28270 tejbeer 174
	<div id="web-listing-edit-modal" class="modal"
175
		id="web-editable-container" role="dialog">
176
		<div class="modal-dialog modal-md">
177
			<!-- Modal content-->
28343 tejbeer 178
			<div class="modal-content" style="width: 800px; height: 200px;"></div>
28270 tejbeer 179
		</div>
180
	</div>
181
</div>
182
 
183
<script type="text/javascript">
184
	$(document).ready(function() {
185
		$('#catalog-feature-table').DataTable({
186
			"bPaginate" : true,
187
			"bLengthChange" : true,
188
			"bFilter" : true,
189
			"bInfo" : false,
190
			"bAutoWidth" : false,
191
			"pageLength" : 100
192
		});
193
	});
194
</script>