Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
27594 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
 
45
<div class="col-lg-4">
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">
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>
57
		             	  #else
58
		             		<option value="$brand">$brand</option>
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>
79
	    			    <th> W/H Id</th>
80
	    				<th>W/H Location</th>
81
	    			    <th>LMS</th>
82
	    			    <th>LMS Qty</th>
83
	    			    <th>LMTD</th>
84
	    			    <th>LMTD Qty</th>
85
	    				<th>MTD</th>
86
	    				<th>MTD Qty</th>
87
	    			 </tr>
88
				 </thead>
89
	    			<tbody>
90
	    			    #foreach($sales in $warehouseWiseBrandPartnerSales)
91
	    				<tr>
92
	    				  <td>$sales.getWarehouseId()</td>
93
	    	 		      <td>$warehouseMap.get($sales.getWarehouseId())</td>
94
	    	 		      <td class="currency">$sales.getLms()</td>
95
	    	 		      <td>$sales.getLmsQty()</td>
96
	    	 		      <td class="currency">$sales.getLmtd()</td>
97
	    	 		      <td>$sales.getLmtdQty()</td>
98
	    	 		      <td class="currency">$sales.getMtd()</td>
99
	    	 		      <td>$sales.getMtdQty()</td>
100
	    				</tr>
101
	    				 #end
102
 
103
	    		    </tbody>
104
	    		</table>
105
		    </div>
106
 
107
</div>
108
 
109
</div>
110
 
111
	<div class="col-lg-8">
112
		<div id="warehouse-table">
113
			<div class="row">
114
    			<div class="col-lg-12 warehouse-brand-item-sale-container">
115
	    		</div>
116
		    </div>
117
		</div>
118
	</div>
119
 
120
 
121
</section>
122
<script type="text/javascript">
123
$(document).ready(function() {
124
	 $('#warehousePartnerBrandSale thead tr').clone(true).appendTo( '#warehousePartnerBrandSale thead' );
27839 amit.gupta 125
	 $('#warehousePartnerBrandSale thead tr:eq(1) th').each( function (i) {
126
        var title = $(this).text();
127
        $(this).html( '<input type="text" style = "width:60%;" placeholder="Search '+title+'" />' );
128
 
129
        $( 'input', this ).on( 'keyup change', function () {
130
            if ( table.column(i).search() !== this.value ) {
131
                table
132
                    .column(i)
133
                    .search( this.value )
134
                    .draw();
135
            }
136
        });
137
    });
138
	    var table = $('#warehousePartnerBrandSale').DataTable( {
27594 tejbeer 139
	        orderCellsTop: true,
140
	        fixedHeader: true
141
	    });
142
 
27839 amit.gupta 143
    $('#warehousePartnerBrandSale tbody').find('tr').click(function () {
144
     	var data = table.row( this ).data();
145
     	var brand = $('#brands').val();
146
     	doGetAjaxRequestHandler(context + "/getWarehouseAccesoriesBrandWiseItemSale?warehouseId="+data[0]+"&brand="+brand, function(response) {
147
			$('.warehouse-brand-item-sale-container').html(response);
148
			console.log(response)
27594 tejbeer 149
		});
27839 amit.gupta 150
	});
151
	$("#warehouse-partner-brand-sale").click(function() {
27594 tejbeer 152
		var brand = $('#brands').val();
27839 amit.gupta 153
		doGetAjaxRequestHandler(context + "/getWarehouseWiseAccesoriesBrandPartnerSale?brand="+brand, function(response) {
154
			$('#' + "main-content").html(response);
155
			console.log(response)
156
		});
27594 tejbeer 157
	});
27839 amit.gupta 158
 
27594 tejbeer 159
});
160
</script>