Subversion Repositories SmartDukaan

Rev

Rev 28567 | Rev 31449 | Go to most recent revision | 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>
51
 
31447 tejbeer 52
 
53
				<div class="form-group" style="margin-top: 15px">
54
 
55
			      <div class="form-group">
28270 tejbeer 56
					<label for="web-listing-url">Rank</label> <input
57
						class="form-control" id="web-listing-rank" placeholder="Rank">
31447 tejbeer 58
				  </div>
59
					<div class="form-group">
60
					  	<label for="web-listing-source">Source</label>
61
					    <select class="form-control" id="listingSource"
62
                                            name="listingSource" placeholder="Source">
63
                                        <option value="" disabled selected>Source</option>
64
                                        #foreach($source in $sources)
65
                                            <option value="$source">$source</option>
66
                                        #end
67
                                    </select>
68
                    </div>
69
 
70
			    </div>
71
 
28301 tejbeer 72
				<div class="form-group" style="margin-top: 15px">
31447 tejbeer 73
 
74
 
28301 tejbeer 75
					<div class="form-group">
28567 tejbeer 76
						<label for="web-listing-bannerurl">Banner Url</label>(365*183)<input
28301 tejbeer 77
							class="form-control" id="web-listing-bannerurl"
78
							placeholder="Banner Url">
79
					</div>
28566 tejbeer 80
 
81
					<div class="form-group">
28567 tejbeer 82
						<label for="web-listing-headerurl">Header Url</label>(272*405)<input
28566 tejbeer 83
							class="form-control" id="web-listing-headerurl"
84
							placeholder="Header Url">
85
					</div>
31447 tejbeer 86
 
87
 
28301 tejbeer 88
					<button type="submit" class="btn btn-default">Add</button>
89
				</div>
26732 amit.gupta 90
			</form>
28270 tejbeer 91
 
92
			<div class="col-lg-4" style="padding: 15px">
93
				<button id="weblisting-update-rank" disabled class="btn btn-default"
94
					type="button">Update Rank</button>
95
			</div>
96
 
26732 amit.gupta 97
		</div>
28270 tejbeer 98
 
26732 amit.gupta 99
		<div class="row">
28270 tejbeer 100
			<table class="table table-border table-condensed table-bordered"
101
				id="catalog-feature-table">
26732 amit.gupta 102
				<thead>
103
					<tr>
26738 amit.gupta 104
						<th>Id</th>
105
						<th>Title</th>
106
						<th>Rank</th>
107
						<th>Url</th>
28301 tejbeer 108
						<th>Banner Url</th>
31447 tejbeer 109
						<th>Source</th>
110
 
28270 tejbeer 111
						<th>Active</th>
112
						<th>Edit</th>
26732 amit.gupta 113
					</tr>
114
				</thead>
28270 tejbeer 115
				<tbody id="web-listing-tbody">
116
					#foreach($webListing in $webListings)
27873 amit.gupta 117
					<tr class="grab" data-id="$webListing.getId()">
26738 amit.gupta 118
						<td>$webListing.getId()</td>
28270 tejbeer 119
						<td><a href="javascript:void(0)"
120
							data-id="$webListing.getId()" class="listing-details">$webListing.getTitle()</a></td>
26738 amit.gupta 121
						<td>$webListing.getRank()</td>
28301 tejbeer 122
						<td>$webListing.getUrl()</td> #if($webListing.getBannerUrl())
123
						<td>$webListing.getBannerUrl()</td> #else
31447 tejbeer 124
						<td></td> #end 
125
 
126
						  <td>$webListing.getSource()</td>
127
 
128
						#if($webListing.isActive())
28270 tejbeer 129
						<td><a data-id="$webListing.getId()"
28342 tejbeer 130
							data-active="$webListing.isActive()" class="web-listing-active">Mark
131
								InActive</a></td> #else
28270 tejbeer 132
						<td><a data-id="$webListing.getId()"
28342 tejbeer 133
							data-active="$webListing.isActive()" class="web-listing-active">Mark
134
								Active</a></td> #end
28270 tejbeer 135
						<td><a data-id="$webListing.getId()"
136
							data-target="#web-listing-edit-modal" data-toggle="modal"
137
							class="web-listing-id">edit</a></td>
26732 amit.gupta 138
					</tr>
28270 tejbeer 139
					#end
140
 
141
 
26732 amit.gupta 142
				</tbody>
143
			</table>
144
		</div>
145
	</div>
31447 tejbeer 146
	<div class="col-lg-5" style="float:right">
26738 amit.gupta 147
		<div id="feature-table">
148
			<div class="row">
28270 tejbeer 149
				<div class="col-lg-12 web-products-container"></div>
150
			</div>
26738 amit.gupta 151
		</div>
152
	</div>
28270 tejbeer 153
</section>
26732 amit.gupta 154
 
28270 tejbeer 155
<div class="web-listing-edit-container">
26732 amit.gupta 156
 
28270 tejbeer 157
	<div id="web-listing-edit-modal" class="modal"
158
		id="web-editable-container" role="dialog">
159
		<div class="modal-dialog modal-md">
160
			<!-- Modal content-->
28343 tejbeer 161
			<div class="modal-content" style="width: 800px; height: 200px;"></div>
28270 tejbeer 162
		</div>
163
	</div>
164
</div>
165
 
166
<script type="text/javascript">
167
	$(document).ready(function() {
168
		$('#catalog-feature-table').DataTable({
169
			"bPaginate" : true,
170
			"bLengthChange" : true,
171
			"bFilter" : true,
172
			"bInfo" : false,
173
			"bAutoWidth" : false,
174
			"pageLength" : 100
175
		});
176
	});
177
</script>