Subversion Repositories SmartDukaan

Rev

Rev 27840 | 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>
27676 tejbeer 87
 
88
	    				 <th>MTD UA</th>
89
	    				 	 <th>MTD UA Qty</th>
27556 tejbeer 90
	    			 </tr>
91
				 </thead>
92
	    			<tbody>
27670 tejbeer 93
	    			    #foreach($sales in $warehouseWiseBrandPartnerSales.keySet())
27556 tejbeer 94
	    				<tr>
27670 tejbeer 95
	    				  <td>$sales</td>
96
	    	 		      <td>$warehouseMap.get($sales)</td>
97
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getLms()</td>
98
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getLmsQty()</td>
99
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getLmtd()</td>
100
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getLmtdQty()</td>
101
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getMtd()</td>
102
	    	 		      <td>$warehouseWiseBrandPartnerSales.get($sales).getMtdQty()</td>
27676 tejbeer 103
 
104
	    	 		      <td class="currency">$warehouseWiseBrandPartnerSales.get($sales).getAmtd()</td>
105
	    	 		        <td>$warehouseWiseBrandPartnerSales.get($sales).getUamtdQty()</td>
106
 
27556 tejbeer 107
	    				</tr>
108
	    				 #end
109
 
110
	    		    </tbody>
111
	    		</table>
112
		    </div>
113
 
114
</div>
115
 
116
</div>
117
 
27670 tejbeer 118
	<div class="col-lg-6">
27556 tejbeer 119
		<div id="warehouse-table">
120
			<div class="row">
121
    			<div class="col-lg-12 warehouse-brand-item-sale-container">
122
	    		</div>
123
		    </div>
124
		</div>
125
	</div>
126
 
127
 
128
</section>
129
<script type="text/javascript">
130
$(document).ready(function() {
131
	 $('#warehousePartnerBrandSale thead tr').clone(true).appendTo( '#warehousePartnerBrandSale thead' );
132
	    $('#warehousePartnerBrandSale thead tr:eq(1) th').each( function (i) {
133
	        var title = $(this).text();
134
	        $(this).html( '<input type="text" style = "width:60%;" placeholder="Search '+title+'" />' );
135
 
136
	        $( 'input', this ).on( 'keyup change', function () {
137
	            if ( table.column(i).search() !== this.value ) {
138
	                table
139
	                    .column(i)
140
	                    .search( this.value )
141
	                    .draw();
142
	            }
143
	        });
144
	    })
145
	  var table = $('#warehousePartnerBrandSale').DataTable( {
146
	        orderCellsTop: true,
147
	        fixedHeader: true
27850 amit.gupta 148
	});
27556 tejbeer 149
 
150
 
27850 amit.gupta 151
    $('#warehousePartnerBrandSale tbody').on('click', 'tr', function () {
27838 amit.gupta 152
     	var data = table.row( this ).data();
153
     	var brand = $('#brands').val();
154
     	doGetAjaxRequestHandler(context + "/getWarehouseBrandWiseItemSale?warehouseId="+data[0]+"&brand="+brand, function(response) {
155
			$('.warehouse-brand-item-sale-container').html(response);
156
			console.log(response)
27556 tejbeer 157
		});
27838 amit.gupta 158
	});
159
	$("#warehouse-partner-brand-sale").click(function() {
27591 tejbeer 160
		var brand = $('#brands').val();
27840 amit.gupta 161
		doGetAjaxRequestHandler(context + "/getWarehouseWiseBrandPartnerSale?brand="+brand, function(response) {
27838 amit.gupta 162
			$('#' + "main-content").html(response);
163
			console.log(response)
164
		});
27556 tejbeer 165
	});
166
});
167
 
168
</script>