Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
27556 tejbeer 1
<section>
2
 
3
 
4
<!--<style>
5
	.table-striped > tbody > tr:nth-child(odd) > td{
6
  		background: white;
7
  		background-color: white;
8
	}
9
	.table-striped > tbody > tr:nth-child(even) > td{
10
  		background: white;
11
  		background-color:white;
12
	}
13
	.table-striped > tbody > tr:hover > td,
14
	.table-striped > tbody > tr:hover {
15
		background-color: #e98c8f;
16
	  	color:white;
17
	}
18
	.btn:hover{
19
  		color: grey;
20
  		text-decoration: none;
21
	}
22
	.btn-primary:hover{
23
  		color: grey;
24
  		text-decoration: none;
25
	}
26
	.sale-details{
27
		cursor:pointer;
28
	}
29
</style>-->
30
<script type="text/javascript">
31
 
32
 
33
	</script>
34
<section class="wrapper">
35
	<div class="row">
36
		<div class="col-lg-12">
37
			<h3 class="page-header"><i class="icon_document_alt"></i>Details</h3>
38
			<ol class="breadcrumb">
39
				<li><i class="fa fa-home"></i><a href="${rc.contextPath}/dashboard">Home</a></li>
40
				<li><i class="icon_document_alt"></i>Warehouse Brand Stock  Detail</li>					  	
41
			</ol>
42
		</div>
43
	</div>
44
 
27670 tejbeer 45
<div class="col-lg-6">
27556 tejbeer 46
 	<table style="Width:100%; margin:15px">
47
		<tr>
48
			<td  style="Width:40%; float:left">
49
		     <div class = "row">
50
		       <div class="col-lg-12">
51
			    <div class="input-group">
27591 tejbeer 52
		    		<select class="form-control input-sm" id = "brands" name="brands" placeholder="Brand">
53
						<option value="" disabled selected>Brand</option>
54
						  #foreach($brand in $brands))
55
	                      #if($brand == $selectedbrand)
56
		             		<option value="$brand" selected>$brand</option>
27556 tejbeer 57
		             	  #else
27591 tejbeer 58
		             		<option value="$brand">$brand</option>
27556 tejbeer 59
		             	  #end
60
		             	  #end
61
		             	</select>
62
	    		<span class="input-group-btn">
63
	      			<button class="btn btn-primary submit" id="warehouse-partner-brand-sale" type="button">Go!</button>
64
	    		</span>
65
	          </div>
66
	          </div>
67
	         </div>
68
	        </td>
69
 
70
 
71
		</tr>
72
    </table>
73
<div class="row">
74
 
75
			<div class="col-lg-12">
76
				 <table id="warehousePartnerBrandSale" class="table table-striped table-advance table-hover">
77
				 <thead>
78
	    			<tr>
27591 tejbeer 79
	    			    <th> W/H Id</th>
80
	    				<th>W/H Location</th>
27574 tejbeer 81
	    			    <th>LMS</th>
82
	    			    <th>LMS Qty</th>
27556 tejbeer 83
	    			    <th>LMTD</th>
84
	    			    <th>LMTD Qty</th>
85
	    				<th>MTD</th>
86
	    				<th>MTD Qty</th>
27670 tejbeer 87
	    				 <th>MTD Activated</th>
27556 tejbeer 88
	    			 </tr>
89
				 </thead>
90
	    			<tbody>
27670 tejbeer 91
	    			    #foreach($sales in $warehouseWiseBrandPartnerSales.keySet())
27556 tejbeer 92
	    				<tr>
27670 tejbeer 93
	    				  <td>$sales</td>
94
	    	 		      <td>$warehouseMap.get($sales)</td>
95
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getLms()</td>
96
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getLmsQty()</td>
97
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getLmtd()</td>
98
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getLmtdQty()</td>
99
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getMtd()</td>
100
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getMtdQty()</td>
101
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getAmtd()</td>
27556 tejbeer 102
	    				</tr>
103
	    				 #end
104
 
105
	    		    </tbody>
106
	    		</table>
107
		    </div>
108
 
109
</div>
110
 
111
</div>
112
 
27670 tejbeer 113
	<div class="col-lg-6">
27556 tejbeer 114
		<div id="warehouse-table">
115
			<div class="row">
116
    			<div class="col-lg-12 warehouse-brand-item-sale-container">
117
	    		</div>
118
		    </div>
119
		</div>
120
	</div>
121
 
122
 
123
</section>
124
<script type="text/javascript">
125
$(document).ready(function() {
126
	 $('#warehousePartnerBrandSale thead tr').clone(true).appendTo( '#warehousePartnerBrandSale thead' );
127
	    $('#warehousePartnerBrandSale thead tr:eq(1) th').each( function (i) {
128
	        var title = $(this).text();
129
	        $(this).html( '<input type="text" style = "width:60%;" placeholder="Search '+title+'" />' );
130
 
131
	        $( 'input', this ).on( 'keyup change', function () {
132
	            if ( table.column(i).search() !== this.value ) {
133
	                table
134
	                    .column(i)
135
	                    .search( this.value )
136
	                    .draw();
137
	            }
138
	        });
139
	    })
140
	  var table = $('#warehousePartnerBrandSale').DataTable( {
141
	        orderCellsTop: true,
142
	        fixedHeader: true
143
	    });
144
 
145
 
146
     $('#warehousePartnerBrandSale tbody').on('click', 'tr', function () {
147
        var data = table.row( this ).data();
148
 
27591 tejbeer 149
       var brand = $('#brands').val();
150
       doGetAjaxRequestHandler(context + "/getWarehouseBrandWiseItemSale?warehouseId="+data[0]+"&brand="+brand,
27556 tejbeer 151
			function(response) {
152
				$('.warehouse-brand-item-sale-container').html(response);
153
				console.log(response)
154
 
155
		});
156
 
157
 
158
    });
159
 
160
});
161
 
162
 
163
$(document).ready(function() {
164
$("#warehouse-partner-brand-sale")
165
		.live(
166
			'click',
167
			function() {
27591 tejbeer 168
		var brand = $('#brands').val();
169
          doGetAjaxRequestHandler(context + "/getWarehouseWiseBrandPartnerSale?brand="+brand,
27556 tejbeer 170
			function(response) {
171
				$('#' + "main-content").html(response);
172
				console.log(response)
173
			});
174
	});
175
});
176
 
177
</script>