892 lines
24 KiB
PHP
Executable File
892 lines
24 KiB
PHP
Executable File
<?php if(!defined('BASEPATH')) exit('No direct script access allowed');
|
|
|
|
require APPPATH . '/libraries/BaseController.php';
|
|
|
|
/**
|
|
* Class :report (Report Details - Controller)
|
|
* User Class to control all user related operations.
|
|
* @author : Venba Info Tech - Saravana kumar
|
|
* @version : 1.1
|
|
* @since : 18 November 2017
|
|
*/
|
|
class report extends BaseController
|
|
{
|
|
/**
|
|
* This is default constructor of the class
|
|
*/
|
|
|
|
public function __construct()
|
|
{
|
|
parent::__construct();
|
|
$this->load->model('dahsboard_Model');
|
|
|
|
$this->isLoggedIn();
|
|
}
|
|
public function pending_report()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Total Pending Requests Reports -';
|
|
|
|
$data['pending_list']=$this->dahsboard_Model->req_list();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("report_pendingreqst",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function releasedPO()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Order Value - Released Reports - ';
|
|
|
|
|
|
|
|
$data['rel_po']=$this->dahsboard_Model->report_relpo();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_POreleased",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function openorderPO()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Open Orders - Pending Reports - ';
|
|
|
|
|
|
|
|
$data['open_po']=$this->dahsboard_Model->report_openpending();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
|
|
$this->loadviews("Report_openorder",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function TotalOrd()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Total Orders Reports';
|
|
|
|
if ($this->input->post('financialyear')) {
|
|
$ab = $this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['Total']=$this->dahsboard_Model->report_total($fa,$aa);
|
|
}
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_totalorders",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function ccr()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Cost Center Reports -';
|
|
|
|
if ($this->input->post('financialyear')) {
|
|
$ab = $this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['ccrpt']=$this->dahsboard_Model->report_ccr($fa,$aa);
|
|
|
|
}
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_costcenter",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
|
|
}
|
|
|
|
public function MM_Supplier()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Material Master - Supplier Wise Reports -';
|
|
|
|
|
|
|
|
$data['mms']=$this->dahsboard_Model->report_MMSupplier();
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_Material_Master_SupplierWise",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function MM_Item()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Material Master - Item Wise Reports-';
|
|
|
|
|
|
|
|
$data['mmi']=$this->dahsboard_Model->report_MMItem();
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_Material_Master_ItemWise",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function MM_ReceiptValue()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Material Master - Receipt Value Reports-';
|
|
|
|
|
|
|
|
$data['mmr']=$this->dahsboard_Model->report_MMReceiptValue();
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_Material_Master_ReceiptValue",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
|
|
public function purchase()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports ';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$prod = $this->input->post('item_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->report_purchase($cname,$prod,$fa,$aa,$m,$frm,$t);
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_purchase",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function link_purchase()
|
|
{
|
|
if ($this->input->post('btn_submit')) {
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$prod = $this->input->post('item_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->report_purchase($cname,$prod,$fa,$aa,$m,$frm,$t);
|
|
|
|
|
|
} else{
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->get('cname');
|
|
$prod = $this->input->get('prod');
|
|
$ab=$this->input->get('ab');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->get('month');
|
|
$frm = $this->input->get('frm');
|
|
$t = $this->input->get('t');
|
|
$sid=$this->input->get('sid');
|
|
$mid = $this->input->get('mid');
|
|
$d = $this->input->get('d');
|
|
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->report_purchase_link($cname,$prod,$fa,$aa,$m,$frm,$t,$sid,$mid,$d);
|
|
}
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_purchase",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function year_wise()
|
|
{
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
|
|
if ($this->input->post('financialyear')) {
|
|
|
|
$data['year']=$this->dahsboard_Model->report_year_wise();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
|
|
//$this->loadviews("Report_year_wise",$this->global,$data, NULL);
|
|
}
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_year_wise",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
|
|
public function month_wise()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
|
|
$month=$this->input->get('dat');
|
|
$mon= date("F",strtotime($month));
|
|
//print_r($month);
|
|
$data['mont']=$mon;
|
|
$data['month']=$this->dahsboard_Model->report_month_wise($month);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_month_wise",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function year_wise_total()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
$last = $this->uri->total_segments();
|
|
$month=$this->uri->segment($last);
|
|
$a=substr($month,0,-5);
|
|
$b=substr($month,5,5);
|
|
//print_r($month);
|
|
$data['year']=$month;
|
|
$data['ytotal']=$this->dahsboard_Model->report_year_wise_total($a,$b);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_year_wise_total",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
|
|
public function purchase_supplier()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Supplier-wise Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['spurchse']=$this->dahsboard_Model->report_supplier($cname,$fa,$aa,$m,$frm,$t);
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_supplier",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function consolidate()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Consolidated Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['spurchse']=$this->dahsboard_Model->report_consolidate($cname,$fa,$aa);
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_consolidate",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cumulative()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Cumulative Reports';
|
|
|
|
//print_r($prod);
|
|
|
|
$data['cum']=$this->dahsboard_Model->report_cumulative();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cum_month()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Cumulative Month-wise Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
//print_r($prod);
|
|
|
|
$data['cum_month']=$this->dahsboard_Model->report_cum_month($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_month",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cum_year()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Cumulative Year-wise Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
|
|
//print_r($sup);
|
|
|
|
$data['cum_year']=$this->dahsboard_Model->report_cum_year($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_year",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cum_day()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Cumulative Day-wise Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
//print_r($prod);
|
|
|
|
$data['cum_day']=$this->dahsboard_Model->report_cum_day($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_day",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function ipurchase()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$prod = $this->input->post('item_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->ireport_purchase($cname,$prod,$fa,$aa,$m,$frm,$t);
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_purchase_inward",$this->global,$data, NULL);
|
|
}
|
|
|
|
else
|
|
{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
|
|
|
|
}
|
|
public function ilink_purchase()
|
|
{
|
|
if ($this->input->post('btn_submit')) {
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$prod = $this->input->post('item_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->ireport_purchase($cname,$prod,$fa,$aa,$m,$frm,$t);
|
|
|
|
|
|
} else{
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->get('cname');
|
|
$prod = $this->input->get('prod');
|
|
$ab=$this->input->get('ab');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->get('month');
|
|
$frm = $this->input->get('frm');
|
|
$t = $this->input->get('t');
|
|
$sid=$this->input->get('sid');
|
|
$mid = $this->input->get('mid');
|
|
$d = $this->input->get('d');
|
|
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['purchase']=$this->dahsboard_Model->ireport_purchase_link($cname,$prod,$fa,$aa,$m,$frm,$t,$sid,$mid,$d);
|
|
}
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_purchase_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function iyear_wise()
|
|
{
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
|
|
if ($this->input->post('financialyear')) {
|
|
|
|
$data['year']=$this->dahsboard_Model->ireport_year_wise();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
|
|
//$this->loadviews("Report_year_wise",$this->global,$data, NULL);
|
|
}
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("Report_year_wise_inward",$this->global,$data, NULL);
|
|
}
|
|
|
|
else
|
|
{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
|
|
public function imonth_wise()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
|
|
$month=$this->input->get('dat');
|
|
$mon= date("F",strtotime($month));
|
|
//print_r($month);
|
|
$data['mont']=$mon;
|
|
$data['month']=$this->dahsboard_Model->ireport_month_wise($month);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_month_wise_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function iyear_wise_total()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
$last = $this->uri->total_segments();
|
|
$month=$this->uri->segment($last);
|
|
$a=substr($month,0,-5);
|
|
$b=substr($month,5,5);
|
|
//print_r($month);
|
|
$data['year']=$month;
|
|
$data['ytotal']=$this->dahsboard_Model->ireport_year_wise_total($a,$b);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_year_wise_total_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
|
|
public function ipurchase_supplier()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
$m=$this->input->post('month');
|
|
$frm = $this->input->post('from_date');
|
|
$t = $this->input->post('to_date');
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['spurchse']=$this->dahsboard_Model->ireport_supplier($cname,$fa,$aa,$m,$frm,$t);
|
|
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("Report_supplier_inward",$this->global,$data, NULL);
|
|
|
|
}
|
|
|
|
else
|
|
{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
|
|
|
|
}
|
|
public function iconsolidate()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
//$this->input->post('btn_submit');
|
|
$cname = $this->input->post('client_name');
|
|
$ab=$this->input->post('financialyear');
|
|
$fa=substr($ab,0,-5);
|
|
$aa=substr($ab,5,5);
|
|
//print_r($prod);
|
|
$data['material']=$this->dahsboard_Model->material_name();
|
|
$data['cust']=$this->dahsboard_Model->customer_name();
|
|
$data['finyear']=$this->dahsboard_Model->report_finyear();
|
|
$data['spurchse']=$this->dahsboard_Model->ireport_consolidate($cname,$fa,$aa);
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_consolidate_inward",$this->global,$data, NULL);
|
|
}
|
|
else
|
|
{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function icumulative()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
|
|
//print_r($prod);
|
|
|
|
$data['cum']=$this->dahsboard_Model->ireport_cumulative();
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_inward",$this->global,$data, NULL);
|
|
}
|
|
|
|
else
|
|
{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
|
|
}
|
|
public function icum_month()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
//print_r($prod);
|
|
|
|
$data['cum_month']=$this->dahsboard_Model->ireport_cum_month($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("Report_cumulative_month_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function icum_year()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
|
|
//print_r($sup);
|
|
|
|
$data['cum_year']=$this->dahsboard_Model->ireport_cum_year($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_year_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function icum_day()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Resico : Reports';
|
|
$last = $this->uri->segment_array();
|
|
|
|
$sup = $last[3];
|
|
$mat = $last[4];
|
|
//print_r($prod);
|
|
|
|
$data['cum_day']=$this->dahsboard_Model->ireport_cum_day($sup,$mat);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Report_cumulative_day_inward",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cashbook()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Cashbook - Cashbook Reports - ';
|
|
|
|
|
|
$data['getTotalServicePoCount'] = $this->dahsboard_Model->getTotalServicePoCount();
|
|
$data['getTotalimportPoCount'] = $this->dahsboard_Model->getTotalimportPoCount();
|
|
$data['getTotalcapitalPoCount'] = $this->dahsboard_Model->getTotalcapitalPoCount();
|
|
$data['getTotalrevenuePoCount'] = $this->dahsboard_Model->getTotalrevenuePoCount();
|
|
$data['cashbook']=$this->dahsboard_Model->cashbook();
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
|
|
|
|
$income="INCOME";
|
|
$expense="EXPENSE";
|
|
$data['monthlywiseincome']=$this->dahsboard_Model->monthwise_data($income);
|
|
$data['monthlywiseexpense']=$this->dahsboard_Model->monthwise_data($expense);
|
|
$data['todayincome']=$this->dahsboard_Model->today_data($income);
|
|
$data['todayexpense']=$this->dahsboard_Model->today_data($expense);
|
|
$data['yearincome']=$this->dahsboard_Model->yearwise_data($income);
|
|
$data['yearexpense']=$this->dahsboard_Model->yearwise_data($expense);
|
|
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("Reportcashbook",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function monthexpenses()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Cashbook - monthly expenses Reports - ';
|
|
|
|
|
|
|
|
$data['monthlyreport']=$this->dahsboard_Model->monthexpensereport();
|
|
// $data['monthlyincreport']=$this->dahsboard_Model->monthincomereport();
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
$this->loadviews("cashbookmonthlyexpenses",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function yearexpenses()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Cashbook - yearly expenses Reports - ';
|
|
|
|
|
|
//$data['yearlyincreport']=$this->dahsboard_Model->yearincomereport();
|
|
$data['yearlyreport']=$this->dahsboard_Model->yearexpensereport();
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("cashbookyearlyexpenses",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
|
|
}
|
|
public function cashbookdepartment()
|
|
{
|
|
$sid=$_GET['sid'];
|
|
$d=$_GET['d'];
|
|
$this->global['pageTitle'] = 'Cashbook - department - ';
|
|
$data['departmentwise']=$this->dahsboard_Model->departmentwise($sid,$d);
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
//print_r($data['departmentwise']);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("cashbookmonthlydep",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
//for cashbook menu link//
|
|
public function cashbookmonthmenu()
|
|
{
|
|
|
|
$this->global['pageTitle'] = 'Cashbook - department - ';
|
|
$data['monthlymenupayments']=$this->dahsboard_Model->monthlypayments();
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
//print_r($data['departmentwise']);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("cashbookmonthmenu",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
public function yearmonthwise()
|
|
{
|
|
$sid=$_GET['sid'];
|
|
$this->global['pageTitle'] = 'Cashbook - yearmonthwise - ';
|
|
$data['yearmonthwise']=$this->dahsboard_Model->yearmonthwise($sid);
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
//print_r($data['departmentwise']);
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("cashbookyearmonthwise",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
public function Viewtoday()
|
|
{
|
|
$this->global['pageTitle'] = 'Cashbook - viewtoday ';
|
|
$data['tdy']=$this->dahsboard_Model->today();
|
|
$data['Indiancurrency']=$this->dahsboard_Model->INRSymbol();
|
|
if($this->DEPCode == MANAGEMENT)
|
|
{
|
|
|
|
$this->loadviews("cashbooktoday",$this->global,$data, NULL);
|
|
}
|
|
else{
|
|
$this->loadViews("access", $this->global, $data, NULL);
|
|
}
|
|
}
|
|
|
|
}
|
|
?>
|