From 30a0063409847d8611405561994d21ff88a9fdb0 Mon Sep 17 00:00:00 2001 From: gayathri1990 Date: Wed, 11 Apr 2018 19:42:48 +0530 Subject: [PATCH] bankstatement issues solved --- application/controllers/cashbook.php | 7 ++- application/models/cashbook_model.php | 13 ++--- application/views/bankcashnew.php | 68 ++++++------------------ application/views/bankdebit.php | 2 +- application/views/bankinvoice.php | 16 +++--- application/views/editincomeexpenses.php | 64 ++++++++++++++++++---- 6 files changed, 90 insertions(+), 80 deletions(-) diff --git a/application/controllers/cashbook.php b/application/controllers/cashbook.php index 7a53dd25..bf83b9fc 100755 --- a/application/controllers/cashbook.php +++ b/application/controllers/cashbook.php @@ -231,6 +231,9 @@ class cashbook extends BaseController $accounttype = $this->input->post('myradio'); + //$accounttype1 = $this->input->post('myrad'); + //echo $accounttype; + //echo $accounttype1; if($accounttype == 1) { $accounttype = 'RECEIPT'; @@ -239,6 +242,7 @@ class cashbook extends BaseController { $accounttype = 'PAYMENT'; } + $accountcode = $this->input->post('accode'); $date = $this->input->post('Date'); $date = date_create($date);//,'Y-m-d'); @@ -564,6 +568,7 @@ class cashbook extends BaseController { $id1=$this->input->post('id1'); $myradio1= $this->input->post('myradio'); + //$myradio2= $this->input->post('myrad'); $option=''; if($myradio1==1) { @@ -724,7 +729,7 @@ class cashbook extends BaseController $fdate = $this->input->post('from_date'); $tdate = $this->input->post('to_date'); $data['bankinvoicedata'] = $this->cashbook_model->bankinvoice($Customer,$fdate,$tdate); - $data['supplier'] = $this->cashbook_model->getsupplier(); + //$data['supplier'] = $this->cashbook_model->getsupplier(); } $data['getcustomer'] = $this->cashbook_model->getcustomer(); diff --git a/application/models/cashbook_model.php b/application/models/cashbook_model.php index de9e277b..7008d086 100755 --- a/application/models/cashbook_model.php +++ b/application/models/cashbook_model.php @@ -19,7 +19,7 @@ class cashbook_model extends CI_Model } function getAccounTypes1() { - $this->db->select('name'); + $this->db->select('name.type'); $r = $this->db->get('t_accountcode'); return $r->result(); @@ -184,11 +184,12 @@ class cashbook_model extends CI_Model { $this->db->distinct(); - $this->db->select('iva.invoice_id,iva.invoice_total,iv.invoice_date_created,iva.invoice_paid,ic.client_name,BI.balancetoreceived,BI.amountreceived'); + $this->db->select('iva.invoice_id,iva.invoice_total,iv.invoice_date_created,iv.invoice_number,iva.invoice_paid,ic.client_name,BI.balancetoreceived,BI.amountreceived'); $this->db->from ('ip_invoice_amounts iva'); $this->db->join ('ip_invoices iv','iv.invoice_id = iva.invoice_id','left'); $this->db->join ('ip_clients ic','ic.client_id = iv.client_id','left'); - $this->db->join ('T_Bankinvoicereport BI','BI.invoiceno = iva.invoice_id','left'); + $this->db->join ('T_Bankinvoicereport BI','BI.invoiceno = iv.invoice_number','left'); + $this->db->where('iv.invoice_status_id','2'); $this->db->where('iva.receivedstatus !=','ST065'); $this->db->where('ic.client_name',$Customer); $this->db->or_where('iv.invoice_date_created BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"'); @@ -438,7 +439,7 @@ function debitlistpo($SupplierName,$fdate,$tdate,$pono) } public function cashbankupdate($cashbookstatus,$bankid) { - echo $bankid; + // echo $bankid; $this->db->where('ID',$bankid); $this->db->update('T_bankreport',$cashbookstatus); return TRUE; @@ -547,8 +548,8 @@ function debitlistpo($SupplierName,$fdate,$tdate,$pono) } function poamountstatus($pomaster,$pono) { - echo $pomaster; - echo $pono; + //echo $pomaster; + //echo $pono; $this->db->where('PONO', $pono); $this->db->update('T_PurchaseOrder_Master',$pomaster); $r = $this->db->affected_rows(); diff --git a/application/views/bankcashnew.php b/application/views/bankcashnew.php index 02481896..a53f62d2 100644 --- a/application/views/bankcashnew.php +++ b/application/views/bankcashnew.php @@ -1,5 +1,12 @@ - +type; + //print_r($atype); + } + +?>