90 lines
3.8 KiB
PHP
Raw Permalink Normal View History

<?php
/*********************************************************************************
* The contents of this file are subject to the SugarCRM Public License Version 1.1.2
* ("License"); You may not use this file except in compliance with the
* License. You may obtain a copy of the License at http://www.sugarcrm.com/SPL
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
* the specific language governing rights and limitations under the License.
* The Original Code is: SugarCRM Open Source
* The Initial Developer of the Original Code is SugarCRM, Inc.
* Portions created by SugarCRM are Copyright (C) SugarCRM, Inc.;
* All Rights Reserved.
* Contributor(s): ______________________________________.
********************************************************************************/
/*********************************************************************************
* $Header: /var/cvs/vtigercrm_aegon/modules/Dashboard/homestuff.php,v 1.2 2007/03/01 17:47:16 jerrydgeorge Exp $
* Description: Main file for the Home module.
* Portions created by SugarCRM are Copyright (C) SugarCRM, Inc.
* All Rights Reserved.
* Contributor(s): ______________________________________..
********************************************************************************/
function dashboardDisplayCall($type,$Chart_Type,$from_page)
{
global $app_strings;
global $app_list_strings;
global $mod_strings;
global $currentModule;
global $theme;
$theme_path="themes/".$theme."/";
$image_path=$theme_path."images/";
require_once('modules/Vtiger/layout_utils.php');
require_once('include/logging.php');
$graph_array = Array(
"leadsource" => $mod_strings['leadsource'],
"leadstatus" => $mod_strings['leadstatus'],
"leadindustry" => $mod_strings['leadindustry'],
"salesbyleadsource" => $mod_strings['salesbyleadsource'],
"salesbyaccount" => $mod_strings['salesbyaccount'],
"salesbyuser" => $mod_strings['salesbyuser'],
"salesbyteam" => $mod_strings['salesbyteam'],
"accountindustry" => $mod_strings['accountindustry'],
"productcategory" => $mod_strings['productcategory'],
"productbyqtyinstock" => $mod_strings['productbyqtyinstock'],
"productbypo" => $mod_strings['productbypo'],
"productbyquotes" => $mod_strings['productbyquotes'],
"productbyinvoice" => $mod_strings['productbyinvoice'],
"sobyaccounts" => $mod_strings['sobyaccounts'],
"sobystatus" => $mod_strings['sobystatus'],
"pobystatus" => $mod_strings['pobystatus'],
"quotesbyaccounts" => $mod_strings['quotesbyaccounts'],
"quotesbystage" => $mod_strings['quotesbystage'],
"invoicebyacnts" => $mod_strings['invoicebyacnts'],
"invoicebystatus" => $mod_strings['invoicebystatus'],
"ticketsbystatus" => $mod_strings['ticketsbystatus'],
"ticketsbypriority" => $mod_strings['ticketsbypriority'],
"ticketsbycategory" => $mod_strings['ticketsbycategory'],
"ticketsbyuser" => $mod_strings['ticketsbyuser'],
"ticketsbyteam" => $mod_strings['ticketsbyteam'],
"ticketsbyproduct"=> $mod_strings['ticketsbyproduct'],
"contactbycampaign"=> $mod_strings['contactbycampaign'],
"ticketsbyaccount"=> $mod_strings['ticketsbyaccount'],
"ticketsbycontact"=> $mod_strings['ticketsbycontact'],
);
$log = LoggerManager::getLogger('dashboard');
if(isset($type) && $type != '')
{
$dashboard_type = $type;
}else
{
$dashboard_type = 'DashboardHome';
}
if(!isset($type))
{
}else
{
require_once('modules/Dashboard/display_charts.php');
$_REQUEST['type'] = $type;
$_REQUEST['Chart_Type'] = $Chart_Type;
$_REQUEST['from_page'] = 'HomePage';
$dashval=dashBoardDisplayChart();
return $dashval;
}
}
?>