<?php

/**
 * 	Dear developer!
 *	Never modify events.php file, it is autogenerated.
 *  Modify PHP/EventTemplates/events.txt instead.
 *
 */

 class eventclass_dashboard  extends eventsBase
{
	function __construct()
	{
	// fill list of events

	}

//	handlers


		// dashboatd snippets function
	function event_Dashboard_snippet( &$header, &$icon )
	{
		

// Place event code here.
// Use "Add Action" button to add code snippets.

// Put your code here.
$header = "Your header here";
echo "Your text here";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet1( &$header, &$icon )
	{
		

// Place event code here.
// Use "Add Action" button to add code snippets.

// Put your code here.
$header = "Your header here";
echo "Your text here";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet2( &$header, &$icon )
	{
		$header = "Your header here";
echo "Your text here";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet3( &$header, &$icon )
	{
		$header = "Your header here";
echo "Your text here";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet4( &$header, &$icon )
	{
		$header = "Your header here";
echo "Your text here";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet11( &$header, &$icon )
	{
		
$header = "<strong>Total socios titulares </strong>";

$res=DB::query("SELECT
	count( id_Socio ) AS socios 
FROM
	socio
	
	where  tipo_accionista = 29 ");

$data = $res->fetchAssoc();

$res= $data["socios"];



echo "<h2 style=\"text-algin: center:\"><strong>Total Socios:  ".$res." </strong></h2>";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet111( &$header, &$icon )
	{
		
$header = "<strong>Total de acciones asignadas </strong>";

$res=DB::query("SELECT
	sum( nro_Acciones ) AS Nro_acciones
FROM
	derecho_propietario");

$data = $res->fetchAssoc();

$res= $data["Nro_acciones"];

echo "<h2 style=\"text-algin: center:\"><strong> Total Acciones:  ".number_format( $res, 2 )." </strong></h2>";;
	}
		// dashboatd snippets function
	function event_Dashboard_snippet1111( &$header, &$icon )
	{
		
$header = "<strong>Total Bs. de acciones Asignadas </strong>";

$res=DB::query("SELECT
	
	(sum( nro_Acciones ) *  100 ) AS Nro_accionesb
FROM
	derecho_propietario");

$data = $res->fetchAssoc();

$res= $data["Nro_accionesb"];


echo "<h2 style=\"text-algin: center:\"><strong> Total Bs.:  ".number_format( $res, 2 ). " </strong></h2>";;
	}

}
?>
