function class_report_showWastes_() {

	var from =document.getElementById("class_report_from").value;
	var to =document.getElementById("class_report_to").value;
	console.log( from ,"  " ,  to );
        
	$.ajax({
		type : 'GET',
		url : 'create/ajaxclass_wastes/' +from+"/"+to ,
		/*data : {
			'_token' : $('meta[name="csrf-token"]').attr('content')
		},
		headers: {
			'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
		  },*/
		
		success : function(data) {
			console.log("data.wastes_", data.wastes_);
			var sel = $('#class_waste_id').empty();
			 $('#class_waste_id').empty();
			 $('#class_supplier_id').empty();
			var wastes = data.wastes_ ;
			sel.append('<option> Choose Waste</option>');
			for (var i = 0; i < wastes.length; ++i) {
				sel.append('<option value="' + wastes[i].waste.id + '">' + wastes[i].waste.name + '</option>');			
			}
	  console.log(data); 
	  
		},
		error : function(request, status, error) {
			console.log(error);
		}
	});
  
		 
	}


function class_report_showSuppliers_() {

	var from =document.getElementById("class_report_from").value;
	var to =document.getElementById("class_report_to").value;
	console.log( from ,"  " ,  to );

	var arr_of_wastes=$("#class_waste_id").val();
    console.log(arr_of_wastes);
        
	$.ajax({
		type : 'GET',
		url : 'create/ajaxclass_suppliers/'+ arr_of_wastes +"/"+from+"/"+to ,
		/*data : {
			'_token' : $('meta[name="csrf-token"]').attr('content')
		},
		headers: {
			'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
		  },*/
		
		success : function(data) {
			console.log("data.suppliers_", data.suppliers_);
			var sel = $('#class_supplier_id').empty();
			 $('#class_supplier_id').empty();
			var suppliers = data.suppliers_ ;
			sel.append('<option> Choose Supplier</option>');
			for (var i = 0; i < suppliers.length; ++i) {
				sel.append('<option value="' + suppliers[i].supplier.id + '">' + suppliers[i].supplier.name + '</option>');			
			}
	  console.log(data); 
	  
		},
		error : function(request, status, error) {
			console.log(error);
		}
	});
  
		 
	}
	