load->model('dahsboard_Model'); $this->isLoggedIn(); } public function pending_report() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : Reports'; $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'); $agf = $this->input->post('aging_from'); $agt = $this->input->post('aging_to'); $data['finyear']=$this->dahsboard_Model->report_finyear(); $data['pending_list']=$this->dahsboard_Model->req_list($fa,$aa,$m,$frm,$t,$agf,$agt); //print_r($data); } $data['finyear']=$this->dahsboard_Model->report_finyear(); //print_r($data); $this->loadviews("report_pendingreqst",$this->global,$data, NULL); } public function releasedPO() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : Reports'; $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'); $agf = $this->input->post('total_order_value_From'); $agt = $this->input->post('total_order_value_To'); $data['finyear']=$this->dahsboard_Model->report_finyear(); $data['rel_po']=$this->dahsboard_Model->report_relpo($fa,$aa,$m,$frm,$t,$agf,$agt); //print_r($data); } $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_POreleased",$this->global,$data, NULL); } public function openorderPO() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : Reports'; $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'); $agf = $this->input->post('total_order_value_From'); $agt = $this->input->post('total_order_value_To'); $data['finyear']=$this->dahsboard_Model->report_finyear(); $data['open_po']=$this->dahsboard_Model->report_openpending($fa,$aa,$m,$frm,$t,$agf,$agt); //print_r($data); } $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_openorder",$this->global,$data, NULL); } public function TotalOrd() { $this->global['pageTitle'] = 'Siddharth : 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(); $this->loadviews("Report_totalorders",$this->global,$data, NULL); } public function ccr() { $this->global['pageTitle'] = 'Siddharth : 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(); $this->loadviews("Report_costcenter",$this->global,$data, NULL); //print_r($data); } public function MM_Supplier() { $this->global['pageTitle'] = 'Siddharth : Reports'; $data['mms']=$this->dahsboard_Model->report_MMSupplier(); $this->loadviews("Report_Material_Master_SupplierWise",$this->global,$data, NULL); } public function MM_Item() { $this->global['pageTitle'] = 'Siddharth : Reports'; $data['mmi']=$this->dahsboard_Model->report_MMItem(); $this->loadviews("Report_Material_Master_ItemWise",$this->global,$data, NULL); } public function MM_ReceiptValue() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : Reports'; $ab=$this->input->post('financialyear'); $fa=substr($ab,0,-5); $aa=substr($ab,5,5); $m=$this->input->post('month'); $data['finyear']=$this->dahsboard_Model->report_finyear(); $data['mmr']=$this->dahsboard_Model->report_MMReceiptValue($fa,$aa,$m); } $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_Material_Master_ReceiptValue",$this->global,$data, NULL); } public function purchase() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_purchase",$this->global,$data, NULL); } public function link_purchase() { if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : 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'] = 'Siddharth : 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); } $this->loadviews("Report_purchase",$this->global,$data, NULL); } public function year_wise() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('financialyear')) { $ab=$this->input->post('financialyear'); $a=substr($ab,0,-5); $b=substr($ab,5,5); $data['year']=$this->dahsboard_Model->report_year_wise($a,$b); $data['finyear']=$this->dahsboard_Model->report_finyear(); //$this->loadviews("Report_year_wise",$this->global,$data, NULL); } $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_year_wise",$this->global,$data, NULL); } public function month_wise() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_month_wise",$this->global,$data, NULL); } public function year_wise_total() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_year_wise_total",$this->global,$data, NULL); } public function purchase_supplier() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_supplier",$this->global,$data, NULL); } public function consolidate() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_consolidate",$this->global,$data, NULL); } public function consolidate_month() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $sid=$this->input->get('sid'); $mid = $this->input->get('mid'); $cname = $this->input->get('cname'); $prod = $this->input->get('prod'); //$mat = $this->input->get('mid'); $m = $this->input->get('m'); $ab=$this->input->get('ab'); $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->consolidate_month($m,$sid,$mid,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_m",$this->global,$data, NULL); } public function consolidate_year() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $sid=$this->input->get('sid'); $mid = $this->input->get('mid'); $cname = $this->input->get('cname'); $prod = $this->input->get('prod'); //$mat = $this->input->get('mid'); $ab=$this->input->get('ab'); $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->consolidate_year($sid,$mid,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_y",$this->global,$data, NULL); } public function cumulative() { $this->global['pageTitle'] = 'Siddharth : Reports'; //print_r($prod); $data['cum']=$this->dahsboard_Model->report_cumulative(); $this->loadviews("Report_cumulative",$this->global,$data, NULL); } public function cum_month() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_month",$this->global,$data, NULL); } public function cum_year() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_year",$this->global,$data, NULL); } public function cum_day() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_day",$this->global,$data, NULL); } public function ipurchase() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $cname = $this->input->post('client_name'); $prod = $this->input->post('item_name'); $ab=$this->input->post('financialyear'); $cat = $this->input->get('cat'); $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,$cat); $data['cashbookdatas']=$this->dahsboard_Model->report_inwardcashbook($cname,$fa,$aa,$m,$frm,$t,$cat); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_purchase_inward",$this->global,$data, NULL); } public function ilink_purchase() { if ($this->input->post('btn_submit')) { $this->global['pageTitle'] = 'Siddharth : 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'); $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($cname,$prod,$fa,$aa,$m,$frm,$t,$sid,$mid,$d); } else{ $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $cat = $this->input->get('cat'); $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('m'); $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'); $da = $this->input->get('da'); $po = $this->input->get('po'); //print_r($m);die(); $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,$cat,$da,$po); } $this->loadviews("Report_purchase_inward",$this->global,$data, NULL); } public function iattach() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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['purchase']=$this->dahsboard_Model->ireport_attachment($cname,$fa,$aa,$m,$frm,$t); } $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); if($this->DEPCode == MANAGEMENT) { $this->loadviews("Report_attach_inward",$this->global,$data, NULL); } else { $this->loadViews("access", $this->global, $data, NULL); } } public function iyear_wise() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('financialyear')) { $ab=$this->input->post('financialyear'); $a=substr($ab,0,-5); $b=substr($ab,5,5); $data['year']=$this->dahsboard_Model->ireport_year_wise($a,$b); $data['finyear']=$this->dahsboard_Model->report_finyear(); //$this->loadviews("Report_year_wise",$this->global,$data, NULL); } $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_year_wise_inward",$this->global,$data, NULL); } public function imonth_wise() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_month_wise_inward",$this->global,$data, NULL); } public function iyear_wise_total() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_year_wise_total_inward",$this->global,$data, NULL); } public function ipurchase_supplier() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_supplier_inward",$this->global,$data, NULL); } public function iconsolidate() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_consolidate_inward",$this->global,$data, NULL); } public function i_consolidate_month() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $sid=$this->input->get('sid'); $mid = $this->input->get('mid'); $cname = $this->input->get('cname'); $prod = $this->input->get('prod'); //$mat = $this->input->get('mid'); $m = $this->input->get('m'); $ab=$this->input->get('ab'); $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->i_consolidate_month($m,$sid,$mid,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_month_inward",$this->global,$data, NULL); } public function i_consolidate_year() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $sid=$this->input->get('sid'); $mid = $this->input->get('mid'); $cname = $this->input->get('cname'); $prod = $this->input->get('prod'); //$mat = $this->input->get('mid'); $ab=$this->input->get('ab'); $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->i_consolidate_year($sid,$mid,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_year_inward",$this->global,$data, NULL); // } // else // { // $this->loadViews("access", $this->global, $data, NULL); // } } public function icumulative() { $this->global['pageTitle'] = 'Siddharth : Reports'; //print_r($prod); $data['cum']=$this->dahsboard_Model->ireport_cumulative(); $this->loadviews("Report_cumulative_inward",$this->global,$data, NULL); } public function icum_month() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_month_inward",$this->global,$data, NULL); } public function icum_year() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_year_inward",$this->global,$data, NULL); } public function icum_day() { $this->global['pageTitle'] = 'Siddharth : 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); $this->loadviews("Report_cumulative_day_inward",$this->global,$data, NULL); } public function rawi_cumulative() { $this->global['pageTitle'] = 'Siddharth : Reports'; //print_r($prod); $data['cum']=$this->dahsboard_Model->rawi_report_cumulative(); $this->loadviews("Report_cumulative_raw",$this->global,$data, NULL); } public function rawi_cum_year() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$mat=$this->input->get('mid'); $cat=$this->input->get('cat'); //print_r($sup); $data['cum_year']=$this->dahsboard_Model->rawi_report_cum_year($cat); $this->loadviews("Report_cumulative_year_raw",$this->global,$data, NULL); } public function rawi_cum_month() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$mat=$this->input->get('mid'); $cat=$this->input->get('cat'); //print_r($prod); $data['cum_month']=$this->dahsboard_Model->rawi_report_cum_month($cat); $this->loadviews("Report_cumulative_month_raw",$this->global,$data, NULL); } public function rawi_cum_day() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$mat=$this->input->get('mid'); $cat=$this->input->get('cat'); //print_r($prod); $data['cum_day']=$this->dahsboard_Model->rawi_report_cum_day($cat); $this->loadviews("Report_cumulative_day_raw",$this->global,$data, NULL); } public function rawi_consolidate() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($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->category(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $data['spurchse']=$this->dahsboard_Model->rawi_report_consolidate($cname,$fa,$aa); } $data['material']=$this->dahsboard_Model->category(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); $this->loadviews("Report_consolidate_raw",$this->global,$data, NULL); } public function rawi_consolidate_month() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $cat = $this->input->get('cat'); $sup = $this->input->get('sup'); //$mat = $this->input->get('mid'); $m = $this->input->get('m'); $ab=$this->input->get('ab'); $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->rawi_consolidate_month($m,$cat,$sup,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_month",$this->global,$data, NULL); } public function rawi_consolidate_year() { $this->global['pageTitle'] = 'Siddharth : Reports'; //$this->input->post('btn_submit'); $cat = $this->input->get('cat'); $sup = $this->input->get('sup'); //$mat = $this->input->get('mid'); $ab=$this->input->get('ab'); $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->rawi_consolidate_year($cat,$sup,$fa,$aa); // print_r( $data['spurchse']); $this->loadviews("Report_consolidate_year",$this->global,$data, NULL); } public function pending_purchase() { $this->global['pageTitle'] = 'Siddharth : Reports'; if ($this->input->post('btn_submit')) { $cname = $this->input->post('client_name'); $prod = $this->input->post('item_name'); $ab=$this->input->post('financialyear'); $cat = $this->input->get('cat'); $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['ppurchse']=$this->dahsboard_Model->pending_purchase($cname,$prod,$fa,$aa,$m,$frm,$t); } $data['material']=$this->dahsboard_Model->material_name(); $data['cust']=$this->dahsboard_Model->customer_name(); $data['finyear']=$this->dahsboard_Model->report_finyear(); // print_r( $data['spurchse']); $this->loadviews("Report_pending_purchase",$this->global,$data, NULL); } public function per() { $this->global['pageTitle'] = 'Siddharth : Reports'; $ab=$this->input->post('financialyear'); $fa=substr($ab,0,-5); $aa=substr($ab,5,5); $m=$this->input->post('month'); //print_r($prod); $data['fy']=$this->dahsboard_Model->fy(); $data['per']=$this->dahsboard_Model->per($fa,$aa,$m); // print_r( $data['spurchse']); $this->loadviews("report_emp",$this->global,$data, NULL); } public function cashbook() { $this->global['pageTitle'] = 'Cashbook - Cashbook Reports - '; $data['gettoptotal1'] = $this->dahsboard_Model->gettoptotal(); $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(); $income="RECEIPT"; $expense="PAYMENT"; $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); $data['gettoptotal1'] = $this->dahsboard_Model->gettoptotal(); $data['tdy']=$this->dahsboard_Model->today(); //echo ($data['tdy']); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); //print_r($data['gettoptotal1']); // $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(); $now = new DateTime(); $currentdate = $now->format('Y-m-d'); // MySQL datetime format $yesterday = date('Y-m-d', strtotime("-1 day")); $month = $now->format('m') ; $year = $now->format('y'); $premonth = $month-1; $premonth = $premonth < 10 ? '0'.$premonth : ''.$premonth; $premonth = $premonth == '00' ? '12' : $premonth; $yearvalue = $premonth == '12' ? $year-1 : $year; $preyear = $yearvalue-1; $data['b4finyeartotal']=$this->dahsboard_Model->yearbeforetotal($preyear,$yearvalue); $data['prevmonthtotal']=$this->dahsboard_Model->monthbeforetotal($premonth,$yearvalue); $data['yesterdaytotal'] = $this->dahsboard_Model->daybeforetotal($yesterday); $this->loadviews("reportcashbook",$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(); $this->loadviews("cashbookmonthlyexpenses",$this->global,$data, NULL); } public function yearexpenses() { $this->global['pageTitle'] = 'Cashbook - yearly expenses Reports - '; $fyear = $this->input->post('financialyear'); $fa=substr( $fyear,0,-5); $aa=substr( $fyear,5,5); //echo $fyear; //$data['yearlyincreport']=$this->dahsboard_Model->yearincomereport(); $data['yearlyreport']=$this->dahsboard_Model->yearexpensereport($fa,$aa); $data['financialyear']=$this->dahsboard_Model->cashbookfinyear(); //print_r($data['finyear']); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); $this->loadviews("cashbookyearlyexpenses",$this->global,$data, NULL); } public function cashbookdepartment() { $this->global['pageTitle'] = 'Cashbook - department - '; $sid=$_GET['sid']; //echo $sid; $d=$_GET['d']; $c=$_GET['c']; if ($c=='PAYMENT') { $data['departmentwise']=$this->dahsboard_Model->departmentwise($sid,$d,$c); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); //print_r($data['departmentwise']); $this->loadviews("cashbookmonthlydep",$this->global,$data, NULL); } else{ $data['departmentwise']=$this->dahsboard_Model->departmentwise($sid,$d,$c); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); $this->loadviews("cashbookmonthlyexp",$this->global,$data, NULL); } } public function cashbookdepartmentexp() { $sid=$_GET['sid']; $d=$_GET['d']; $c=$_GET['c']; $this->global['pageTitle'] = 'Cashbook - department - '; $data['departmentwise']=$this->dahsboard_Model->departmentwise($sid,$d,$c); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); //print_r($data['departmentwise']); $this->loadviews("cashbookmonthlyexp",$this->global,$data, NULL); } //for cashbook menu link// // public function cashbookmonthmenu() // { // $this->global['pageTitle'] = 'Cashbook monthly '; // $data['yearmonthwise']=$this->dahsboard_Model->yearmonthwise(); // $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); // //print_r($data['departmentwise']); // $this->loadviews("cashbookyearmonthwise",$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']); $this->loadviews("cashbookyearmonthwise",$this->global,$data, NULL); } //this function used to today menu option// public function Viewtoday() { $this->global['pageTitle'] = 'Cashbook - viewtoday '; $data['tdy']=$this->dahsboard_Model->today(); //print_r($data['tdy']); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); $this->loadviews("cashbooktoday",$this->global,$data, NULL); } public function depmenu() { $this->global['pageTitle'] = 'Cashbook - AllReport '; $fdate = $this->input->post('from_date'); $tdate = $this->input->post('to_date'); $finyear = $this->input->post('financialyear'); $fa=substr( $finyear,0,-5); $aa=substr( $finyear,5,5); $data['depmenu']=$this->dahsboard_Model->departmentmenu($fdate,$tdate,$fa,$aa); $data['financialyear']=$this->dahsboard_Model->cashbookfinyear(); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); $this->loadviews("cashbookall",$this->global,$data, NULL); } public function cashbookmenudepartment() { $sid=$_GET['sid']; $this->global['pageTitle'] = 'Cashbook - department - '; $data['menudepartmentwise']=$this->dahsboard_Model->menudepartmentwise($sid); $data['Indiancurrency']=$this->dahsboard_Model->INRSymbol(); //print_r($data['departmentwise']); $this->loadviews("cashbookdepday",$this->global,$data, NULL); } public function cashbook_cumulative_report() { $this->global['pageTitle'] = 'Cashbook Cumulative - report '; $data['datas']=$this->dahsboard_Model->report_cumulative_cashbook(); $this->loadviews("cashbook_cumulative_report",$this->global,$data, NULL); } public function cashbook_month_cumulative_report() { $this->global['pageTitle'] = 'Cashbook Cumulative(Monthwise) - report '; if (date('m') >= 4) { $yearl = date('Y').'-'.(date('Y')+1); } else { $yearl = (date('Y')-1).'-'.date('Y'); } $ab=$yearl; $fa=substr($ab,0,-5); $aa=substr($ab,5,5); $data['datas'] = $this->dahsboard_Model->report_cumulative_month_cashbook(); $this->loadviews("cashbook_cumulative_month_report",$this->global,$data, NULL); } } ?>