     <?require_once('hakati.php');
require_once('ha.php');
    $dbc=mysqli_connect("localhost", "theulti4_p302", "@@@6050@@tyi#&!#","theulti4_point");
?>
     <div class="content-page">
      <div class="container-fluid">
     <div class="container-fluid add-form-list">
         
        <div class="row">
            <div class="col-sm-12">

               
               
               
           <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
    <script type="text/javascript">
   
      google.charts.load('current', {'packages':['corechart']});
      google.charts.setOnLoadCallback(drawChart);

      function drawChart() {

        var data = google.visualization.arrayToDataTable([
          ['NAME', 'TOTAL SALES'],
          <?php 
		// $mn='KELYZA';
			$query = "SELECT  
   MONTHNAME(date) month,  
   sum(total_p) total
FROM sales where YEAR(date)=YEAR(NOW())
GROUP BY MONTH (date)
ORDER BY MONTH (date); ";

			 $exec = mysqli_query($dbc,$query);
			 while($row = mysqli_fetch_array($exec)){

			 echo "['".$row['month']."',".round($row['total'])."],";
			 }
			 ?> 
        ]);

        var options = {
          title: 'COLUMN CHART  REPORT OF SALES FOR THE CURRENT YEAR',
		  //pieHole: 0.4,
		  // is3D: true
        };

        var chart = new google.visualization.ColumnChart(document.getElementById('today'));

        chart.draw(data, options);
      }

    </script>
    <?mysqli_close($dbc);?>
         <div class="container">
  <div class="row">
    <div class="col">   
    <div align="left">
  <div id="today" style="width: 100%;height:400px;" >
                                                   </div>
                                                     </div></div>
                                                      
                                   
                                                </div>
                                            </div>
                                                                    
                    </div></div>  </div></div>   </div>   </div></div>  </div>                          
													
       
       </div>
      </div>
    </div>
    <!-- Wrapper End-->
    <footer class="iq-footer">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-6">
                    <ul class="list-inline mb-0">
                        <li class="list-inline-item"><a href="../backend/privacy-policy.html">Privacy Policy</a></li>
                        <li class="list-inline-item"><a href="../backend/terms-of-service.html">Terms of Use</a></li>
                    </ul>
                </div>
                <div class="col-lg-6 text-right">
                    <span class="mr-1">
                        Copyright
                        <script>document.write(new Date().getFullYear())</script>© <a href="#" class="">Datum</a>
                        All Rights Reserved.
                    </span>
                </div>
            </div>
        </div>
    </footer>    <!-- Backend Bundle JavaScript -->
    <script src="js/backend-bundle.min.js"></script>
    <!-- Chart Custom JavaScript -->
    <script src="js/customizer.js"></script>
    
    <script src="js/sidebar.js"></script>
    
    <!-- Flextree Javascript-->
    <script src="js/flex-tree.min.js"></script>
    <script src="js/tree.js"></script>
    
    <!-- Table Treeview JavaScript -->
    <script src="js/table-treeview.js"></script>
    
    <!-- SweetAlert JavaScript -->
    <script src="js/sweetalert.js"></script>
    
    <!-- Vectoe Map JavaScript -->
    <script src="js/vector-map-custom.js"></script>
    
    <!-- Chart Custom JavaScript -->
    <script src="js/chart-custom.js"></script>
    <script src="js/charts/01.js"></script>
    <script src="js/charts/02.js"></script>
    
    <!-- slider JavaScript -->
    <script src="js/slider.js"></script>
    
    <!-- Emoji picker -->
    <script src="vendor/emoji-picker-element/index.js" type="module"></script>
    
    
    <!-- app JavaScript -->
    <script src="js/app.js"></script>  </body>
</html>