bank changes
This commit is contained in:
parent
b97cc9813a
commit
8afe99da53
@ -226,6 +226,7 @@ $route['addNewIncomeExpense'] = "cashbook/addNewIncomeExpenseLoad";
|
|||||||
$route['addIncomeExpense'] = "cashbook/addIncomeExpense";
|
$route['addIncomeExpense'] = "cashbook/addIncomeExpense";
|
||||||
$route['updateExpense'] = "cashbook/updateExpense";
|
$route['updateExpense'] = "cashbook/updateExpense";
|
||||||
|
|
||||||
|
//<----------Cashbook page - Bank statement-------------->
|
||||||
//<----------Cashbook page - Bank statement-------------->
|
//<----------Cashbook page - Bank statement-------------->
|
||||||
$route['Bankingview']= "cashbook/bankfileview";
|
$route['Bankingview']= "cashbook/bankfileview";
|
||||||
$route['Bankfiletostatement']= "cashbook/bankfileupload";
|
$route['Bankfiletostatement']= "cashbook/bankfileupload";
|
||||||
@ -235,16 +236,22 @@ $route['Cashstatement']= "cashbook/cashreceipt";
|
|||||||
$route['BankingFile']= "cashbook/bankfileupload";
|
$route['BankingFile']= "cashbook/bankfileupload";
|
||||||
//$route['Filelist']="cashbook/filelist";
|
//$route['Filelist']="cashbook/filelist";
|
||||||
//$route['Bankingrecord']= "cashbook/bankdata";
|
//$route['Bankingrecord']= "cashbook/bankdata";
|
||||||
$route['Bankamountpaid']= "cashbook/amountpaid";
|
//$route['Bankamountpaid']= "cashbook/amountpaid";
|
||||||
|
$route['Bankamountpaid']= "cashbook/amountpaidsupplier";
|
||||||
$route['Bankamountunpaid']= "cashbook/amountunpaid";
|
$route['Bankamountunpaid']= "cashbook/amountunpaid";
|
||||||
$route['Bankamountreceived']= "cashbook/amountreceived";
|
//$route['Bankamountreceived']= "cashbook/amountreceived";
|
||||||
|
$route['Bankamountreceived']= "cashbook/bankreceivedsupp";
|
||||||
|
$route['Bankamountunreceived']= "cashbook/bankunreceivedsupp";
|
||||||
|
$route['Receiptamount']="cashbook/receipt";
|
||||||
$route['Receipt']= "cashbook/cashreceipt";
|
$route['Receipt']= "cashbook/cashreceipt";
|
||||||
$route['Payment']= "cashbook/cashpayment";
|
$route['Payment']= "cashbook/cashpayment";
|
||||||
$route['Invoice']= "cashbook/bankinvoice";
|
$route['Invoice']= "cashbook/bankinvoice";
|
||||||
$route['Bankcash']= "cashbook/cashbanking";
|
$route['Bankcash']= "cashbook/cashbanking";
|
||||||
|
$route['Amountreceived']="cashbook/amountreceived";
|
||||||
$route['DeleteInvoice']="cashbook/deletemappingiv";
|
$route['DeleteInvoice']="cashbook/deletemappingiv";
|
||||||
$route['DeletePo']="cashbook/Deletemappingporeport";
|
$route['DeletePo']="cashbook/Deletemappingporeport";
|
||||||
$route['MappingInvoice']="cashbook/mappinginvoice";
|
$route['MappingInvoice']="cashbook/mappinginvoice";
|
||||||
|
//$route['Deleteinvoiceurl']="cashbook/Deletemappingcashbookcredit";
|
||||||
$route['qualityreportlist'] = "quality/reportList";
|
$route['qualityreportlist'] = "quality/reportList";
|
||||||
$route['qualityreportlistinward'] = "quality/reportListInward";
|
$route['qualityreportlistinward'] = "quality/reportListInward";
|
||||||
//<-------------Store page----------------->
|
//<-------------Store page----------------->
|
||||||
|
|||||||
@ -317,7 +317,7 @@ class cashbook extends BaseController
|
|||||||
$balance=$sheet->getCell('H'.$x)->getValue();
|
$balance=$sheet->getCell('H'.$x)->getValue();
|
||||||
|
|
||||||
// $IsActive=0;
|
// $IsActive=0;
|
||||||
$filedataupload= array('reportdate'=>$Date1,'valuedate'=>$Date2,'chequeNo'=>$cod,'Narration'=>$narration,'Cod'=> $chqno,'Debit'=>$debit,'Credit'=>$credit,'cbalancetocleared'=>$credit,'Balance'=>$balance,'Bankname'=>$bank);
|
$filedataupload= array('reportdate'=>$Date1,'valuedate'=>$Date2,'chequeNo'=>$cod,'Narration'=>$narration,'Cod'=> $chqno,'Debit'=>$debit,'Credit'=>$credit,'cbalancetocleared'=>$credit,'Balance'=>$balance,'Bankname'=>$bank);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -986,8 +986,10 @@ class cashbook extends BaseController
|
|||||||
//$data['bankid'] = $_GET['d'];
|
//$data['bankid'] = $_GET['d'];
|
||||||
$data['bankdepit'] = $this->cashbook_model->debitbankstatemet($Supplierid,$fdate,$tdate);
|
$data['bankdepit'] = $this->cashbook_model->debitbankstatemet($Supplierid,$fdate,$tdate);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
// print_r($data['bankdepit']);
|
{
|
||||||
|
$data['bankdepit'] = $this->cashbook_model->debitbankstatemet1();
|
||||||
|
}
|
||||||
$data['getsupplier'] = $this->cashbook_model->getsupplier();
|
$data['getsupplier'] = $this->cashbook_model->getsupplier();
|
||||||
$this->loadViews("bankdebit",$this->global,$data,NULL);
|
$this->loadViews("bankdebit",$this->global,$data,NULL);
|
||||||
//die();
|
//die();
|
||||||
@ -1028,6 +1030,7 @@ class cashbook extends BaseController
|
|||||||
public function filelist()
|
public function filelist()
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|
||||||
$igrno= $this->input->post('igrno');
|
$igrno= $this->input->post('igrno');
|
||||||
$pono =$this->input->post('pono');
|
$pono =$this->input->post('pono');
|
||||||
$data = $this->cashbook_model->debitimage($igrno,$pono);
|
$data = $this->cashbook_model->debitimage($igrno,$pono);
|
||||||
@ -1073,13 +1076,7 @@ class cashbook extends BaseController
|
|||||||
$tdate = $this->input->post('to_date');
|
$tdate = $this->input->post('to_date');
|
||||||
$bankid= $_GET['d'];
|
$bankid= $_GET['d'];
|
||||||
$data['clearbalance']=$_GET['cb'];
|
$data['clearbalance']=$_GET['cb'];
|
||||||
// if($data['clearbalance']==0)
|
|
||||||
// {
|
|
||||||
// echo "<script>alert('No Mapped Amount!')</script>";
|
|
||||||
// redirect('Bankingstatement','refresh');
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
$data['balancetoclear']=$_GET['btc'];
|
$data['balancetoclear']=$_GET['btc'];
|
||||||
$data['mappingcashbook']=$this->cashbook_model->mappingcash($SupplierName,$fdate,$tdate,$bankid);
|
$data['mappingcashbook']=$this->cashbook_model->mappingcash($SupplierName,$fdate,$tdate,$bankid);
|
||||||
$data['mappingiv'] = $this->cashbook_model->creditinvoicelist($bankid);
|
$data['mappingiv'] = $this->cashbook_model->creditinvoicelist($bankid);
|
||||||
@ -1088,7 +1085,7 @@ class cashbook extends BaseController
|
|||||||
$data['supplier'] = $this->cashbook_model->getsupplier();
|
$data['supplier'] = $this->cashbook_model->getsupplier();
|
||||||
//redirect('Bankingstatement','refresh');
|
//redirect('Bankingstatement','refresh');
|
||||||
$this->loadViews("bankinvoicesettlement", $this->global,$data,NULL);
|
$this->loadViews("bankinvoicesettlement", $this->global,$data,NULL);
|
||||||
//}
|
|
||||||
}
|
}
|
||||||
public function mappingdebit()
|
public function mappingdebit()
|
||||||
{
|
{
|
||||||
@ -1099,8 +1096,8 @@ class cashbook extends BaseController
|
|||||||
$SupplierName = $this->input->post('SupplierName');
|
$SupplierName = $this->input->post('SupplierName');
|
||||||
$fdate = $this->input->post('from_date');
|
$fdate = $this->input->post('from_date');
|
||||||
$tdate = $this->input->post('to_date');
|
$tdate = $this->input->post('to_date');
|
||||||
$pono= $_GET['sid'];
|
$igrlineitem= $_GET['sid'];
|
||||||
$data['debitmapping'] = $this->cashbook_model->debitlistpo($pono);
|
$data['debitmapping'] = $this->cashbook_model->debitlistpo($igrlineitem);
|
||||||
$this->loadViews("bankposettlement", $this->global,$data,NULL);
|
$this->loadViews("bankposettlement", $this->global,$data,NULL);
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1212,7 +1209,7 @@ class cashbook extends BaseController
|
|||||||
|
|
||||||
$podata1 = array('Podate'=>$date,'PONO'=>$pono,'IGRNO'=>$igrno,'Suppliername'=>$sname,'Totalpoamount'=>$tot,'Amountpaid'=>$ip,'Balancetopay'=>$balancetopay,'mid'=>$bankid,'IGRLineItemNo'=>$igrlineitem,'IsActive'=>$IsActive);
|
$podata1 = array('Podate'=>$date,'PONO'=>$pono,'IGRNO'=>$igrno,'Suppliername'=>$sname,'Totalpoamount'=>$tot,'Amountpaid'=>$ip,'Balancetopay'=>$balancetopay,'mid'=>$bankid,'IGRLineItemNo'=>$igrlineitem,'IsActive'=>$IsActive);
|
||||||
|
|
||||||
$podata = array('Podate'=>$date,'PONO'=>$pono,'IGRNO'=>$igrno,'Suppliername'=>$sname,'Totalpoamount'=>$tot,'Amountpaid'=>$amtpaid,'Balancetopay'=>$balancetopay,'mid'=>$bankid,'IGRLineItemNo'=>$igrlineitem);
|
$podata = array('Podate'=>$date,'PONO'=>$pono,'IGRNO'=>$igrno,'Suppliername'=>$sname,'Totalpoamount'=>$tot,'Amountpaid'=>$amtpaid,'Balancetopay'=>$balancetopay,'mid'=>$bankid,'IGRLineItemNo'=>$igrlineitem,'IsActive'=>$IsActive);
|
||||||
//die();
|
//die();
|
||||||
|
|
||||||
$result3 = $this->cashbook_model->getpono($igrlineitem);
|
$result3 = $this->cashbook_model->getpono($igrlineitem);
|
||||||
@ -1337,7 +1334,7 @@ class cashbook extends BaseController
|
|||||||
|
|
||||||
$updateamount=($totalpaidamount+$eRec);
|
$updateamount=($totalpaidamount+$eRec);
|
||||||
$IsActive=1;
|
$IsActive=1;
|
||||||
$invoicedata1 = array('indate'=>$date,'invoiceno'=>$invid,'customername'=>$cname,'totinvoiceamount'=>$invamount,'balancetoreceived'=>$balancetoreceived1,'amountreceived'=>$amtpaid,'bankid'=>$bankid);
|
$invoicedata1 = array('indate'=>$date,'invoiceno'=>$invid,'customername'=>$cname,'totinvoiceamount'=>$invamount,'balancetoreceived'=>$balancetoreceived1,'amountreceived'=>$amtpaid,'bankid'=>$bankid,'IsActive'=>$IsActive);
|
||||||
|
|
||||||
$invoicedata = array('indate'=>$date,'invoiceno'=>$invid,'customername'=>$cname,'totinvoiceamount'=>$invamount,'balancetoreceived'=>$balancetoreceived1,'amountreceived'=>$ip,'bankid'=>$bankid,'IsActive'=>$IsActive);
|
$invoicedata = array('indate'=>$date,'invoiceno'=>$invid,'customername'=>$cname,'totinvoiceamount'=>$invamount,'balancetoreceived'=>$balancetoreceived1,'amountreceived'=>$ip,'bankid'=>$bankid,'IsActive'=>$IsActive);
|
||||||
|
|
||||||
@ -1386,22 +1383,87 @@ class cashbook extends BaseController
|
|||||||
$tdate = $this->input->post('to_date');
|
$tdate = $this->input->post('to_date');
|
||||||
$data['bankdebit'] = $this->cashbook_model->debitpolistfilter($SupplierName,$fdate,$tdate);
|
$data['bankdebit'] = $this->cashbook_model->debitpolistfilter($SupplierName,$fdate,$tdate);
|
||||||
}
|
}
|
||||||
$data['amountpaid'] = $this->cashbook_model->paided();
|
else
|
||||||
|
{
|
||||||
|
$suppliername= $_GET['sid'];
|
||||||
|
$data['bankdebit'] = $this->cashbook_model->paided($suppliername);
|
||||||
|
}
|
||||||
$data['supplier'] = $this->cashbook_model->getsupplier();
|
$data['supplier'] = $this->cashbook_model->getsupplier();
|
||||||
|
// $this->loadViews("bankpaidsupp", $this->global,$data, NULL);
|
||||||
$this->loadViews("bankamountpaid", $this->global,$data, NULL);
|
$this->loadViews("bankamountpaid", $this->global,$data, NULL);
|
||||||
|
|
||||||
|
}
|
||||||
|
public function amountreceivednew()
|
||||||
|
{
|
||||||
|
|
||||||
|
//$this->global['pageTitle'] = 'Siddharth : amountpaid';
|
||||||
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Amount Payment Details';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
$SupplierName = $this->input->post('SupplierName');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
$data['bankreceivable'] = $this->cashbook_model->creditinvoicewisefilter($SupplierName,$fdate,$tdate);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$suppliername= $_GET['sid'];
|
||||||
|
$data['bankreceivable'] = $this->cashbook_model->creditinvoicesupplierwise($suppliername);
|
||||||
|
}
|
||||||
|
$data['supplier'] = $this->cashbook_model->getsupplier();
|
||||||
|
// $this->loadViews("bankpaidsupp", $this->global,$data, NULL);
|
||||||
|
$this->loadViews("bankamountreceived", $this->global,$data, NULL);
|
||||||
|
|
||||||
|
}
|
||||||
|
public function amountpaidsupplier()
|
||||||
|
{
|
||||||
|
|
||||||
|
//$this->global['pageTitle'] = 'Siddharth : amountpaid';
|
||||||
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Amount Payment Details';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
$data['bankdebitsupp'] = $this->cashbook_model->amountpaidsupplierwisefilter($fa,$aa,$m,$fdate,$tdate);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
$data['bankdebitsupp'] = $this->cashbook_model->amountpaidsupplierwise();
|
||||||
|
}
|
||||||
|
$data['finyear']=$this->cashbook_model->report_finyear();
|
||||||
|
$data['supplier'] = $this->cashbook_model->getsupplier();
|
||||||
|
$this->loadViews("bankpaidsupp", $this->global,$data, NULL);
|
||||||
|
//$this->loadViews("bankamountpaid", $this->global,$data, NULL);
|
||||||
|
|
||||||
}
|
}
|
||||||
public function amountunpaid()
|
public function amountunpaid()
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->global['pageTitle'] = 'Siddharth : Bank Debit Report';
|
$this->global['pageTitle'] = 'Siddharth : Bank Debit Report';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
|
||||||
$data['bankdepit'] = $this->cashbook_model->suppliertotal();
|
$data['bankunpaid'] = $this->cashbook_model->suppliertotalfilter($fa,$aa,$m,$fdate,$tdate);
|
||||||
// }
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$data['bankunpaid'] = $this->cashbook_model->suppliertotal();
|
||||||
|
}
|
||||||
$data['finyear']=$this->cashbook_model->report_finyear();
|
$data['finyear']=$this->cashbook_model->report_finyear();
|
||||||
$data['getsupplier'] = $this->cashbook_model->getsupplier();
|
$data['getsupplier'] = $this->cashbook_model->getsupplier();
|
||||||
$this->loadViews("bankunpaidsupp",$this->global,$data,NULL);
|
$this->loadViews("bankunpaidsupp",$this->global,$data,NULL);
|
||||||
//die();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
public function supplierwise()
|
public function supplierwise()
|
||||||
@ -1418,12 +1480,12 @@ class cashbook extends BaseController
|
|||||||
$m=$this->input->post('month');
|
$m=$this->input->post('month');
|
||||||
$fdate = $this->input->post('from_date');
|
$fdate = $this->input->post('from_date');
|
||||||
$tdate = $this->input->post('to_date');
|
$tdate = $this->input->post('to_date');
|
||||||
$data['bankdepit'] = $this->cashbook_model->amountunpaidfilter($sd,$fa,$aa,$m,$fdate,$tdate);
|
$data['bankunpaid'] = $this->cashbook_model->amountunpaidfilter($sd,$fa,$aa,$m,$fdate,$tdate);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$supplierid1 = $_GET['sid'];
|
$supplierid1 = $_GET['sid'];
|
||||||
$data['bankdepit'] = $this->cashbook_model->amountunpaid($supplierid1);
|
$data['bankunpaid'] = $this->cashbook_model->amountunpaid($supplierid1);
|
||||||
}
|
}
|
||||||
$data['finyear']=$this->cashbook_model->report_finyear();
|
$data['finyear']=$this->cashbook_model->report_finyear();
|
||||||
// $data['getsupplier'] = $this->cashbook_model->getsupplier();
|
// $data['getsupplier'] = $this->cashbook_model->getsupplier();
|
||||||
@ -1441,15 +1503,104 @@ class cashbook extends BaseController
|
|||||||
$this->global['pageTitle'] = 'Siddharth : Bank Report - Received Amount Details';
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Received Amount Details';
|
||||||
if ($this->input->post('btn_submit'))
|
if ($this->input->post('btn_submit'))
|
||||||
{
|
{
|
||||||
$Customer = $this->input->post('Customer');
|
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
$data['amountreceived'] = $this->cashbook_model->creditinvoicelistfilter($fdate,$tdate,$fa,$aa,$m);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$clientname= $_GET['sid'];
|
||||||
|
$data['amountreceived'] = $this->cashbook_model->received($clientname);
|
||||||
|
}
|
||||||
|
$data['finyear']=$this->cashbook_model->report_finyearamountreceived();
|
||||||
|
$data['getcustomer'] = $this->cashbook_model->getcustomer();
|
||||||
|
$this->loadViews("bankamountreceived", $this->global,$data, NULL);
|
||||||
|
|
||||||
|
}
|
||||||
|
public function bankreceivedsupp()
|
||||||
|
{
|
||||||
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Received Amount Details supplierwise';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
//$Customer = $this->input->post('CustomerName');
|
||||||
$fdate = $this->input->post('from_date');
|
$fdate = $this->input->post('from_date');
|
||||||
$tdate = $this->input->post('to_date');
|
$tdate = $this->input->post('to_date');
|
||||||
|
|
||||||
$data['bankcredit'] = $this->cashbook_model->creditinvoicelistfilter($Customer,$fdate,$tdate);
|
$data['amountreceivedsupplier'] = $this->cashbook_model->creditinvoicewisefilter($fdate,$tdate,$fa,$aa,$m);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$data['amountreceivedsupplier'] = $this->cashbook_model->creditinvoicesupplierwise();
|
||||||
|
}
|
||||||
|
$data['finyear']=$this->cashbook_model->report_finyearamountreceived();
|
||||||
$data['getcustomer'] = $this->cashbook_model->getcustomer();
|
$data['getcustomer'] = $this->cashbook_model->getcustomer();
|
||||||
$data['amountreceived'] = $this->cashbook_model->received();
|
$this->loadViews("bankreceivedsupp", $this->global,$data, NULL);
|
||||||
$this->loadViews("bankamountreceived", $this->global,$data, NULL);
|
|
||||||
|
}
|
||||||
|
public function bankunreceivedsupp()
|
||||||
|
{
|
||||||
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Received Amount Details supplierwise';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
//$Customer = $this->input->post('CustomerName');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
|
||||||
|
$data['amountunreceivedsupplier'] = $this->cashbook_model->uncreditinvoicewisefilter($fdate,$tdate,$fa,$aa,$m);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
$data['amountunreceivedsupplier'] = $this->cashbook_model->unreceivedsupplier();
|
||||||
|
}
|
||||||
|
$data['finyear']=$this->cashbook_model->report_finyearamountreceived();
|
||||||
|
$data['getcustomer'] = $this->cashbook_model->getcustomer();
|
||||||
|
$this->loadViews("bankunreceivedsupp", $this->global,$data, NULL);
|
||||||
|
|
||||||
|
}
|
||||||
|
public function amountunreceived()
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
// $this->load->model('cashbook_model');
|
||||||
|
//$this->global['pageTitle'] = 'Siddharth : Cashbook Listing';
|
||||||
|
$this->global['pageTitle'] = 'Siddharth : Bank Report - Received Amount Details';
|
||||||
|
if ($this->input->post('btn_submit'))
|
||||||
|
{
|
||||||
|
$ab=$this->input->post('financialyear');
|
||||||
|
$fa=substr($ab,0,-5);
|
||||||
|
$aa=substr($ab,5,5);
|
||||||
|
$m=$this->input->post('month');
|
||||||
|
$fdate = $this->input->post('from_date');
|
||||||
|
$tdate = $this->input->post('to_date');
|
||||||
|
echo $fa;
|
||||||
|
echo $aa;
|
||||||
|
$data['clientname']=$_GET['sid'];
|
||||||
|
$data['amountunreceived'] = $this->cashbook_model->uncreditinvoicelistfilter($fdate,$tdate,$fa,$aa,$m);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$clientname=$_GET['sid'];
|
||||||
|
$data['amountunreceived'] = $this->cashbook_model->unreceived($clientname);
|
||||||
|
}
|
||||||
|
$data['finyear']=$this->cashbook_model->report_finyearamountunreceived();
|
||||||
|
$data['getcustomer'] = $this->cashbook_model->getcustomer();
|
||||||
|
$this->loadViews("bankamountunreceived", $this->global,$data, NULL);
|
||||||
|
|
||||||
}
|
}
|
||||||
public function cashbanking()
|
public function cashbanking()
|
||||||
@ -1468,6 +1619,7 @@ class cashbook extends BaseController
|
|||||||
$totalamount =$this->input->post('Totalpoamount');
|
$totalamount =$this->input->post('Totalpoamount');
|
||||||
$Amount = $this->input->post('paidamount');
|
$Amount = $this->input->post('paidamount');
|
||||||
$id=$this->input->post('mappingid');
|
$id=$this->input->post('mappingid');
|
||||||
|
|
||||||
$igrno = $this->input->post('IGRItemNo');
|
$igrno = $this->input->post('IGRItemNo');
|
||||||
$Bankid = $this->input->post('bankid');
|
$Bankid = $this->input->post('bankid');
|
||||||
$balancetoclear=$this->input->post('balancetobankingclear');
|
$balancetoclear=$this->input->post('balancetobankingclear');
|
||||||
@ -1498,7 +1650,7 @@ class cashbook extends BaseController
|
|||||||
$result2= $this->cashbook_model->deleteBankmappingpo($id,$IsActive);
|
$result2= $this->cashbook_model->deleteBankmappingpo($id,$IsActive);
|
||||||
//for update mapping amount inT_Bankporeport table//
|
//for update mapping amount inT_Bankporeport table//
|
||||||
//die();
|
//die();
|
||||||
$result3= $this->cashbook_model->updateBankporeportpo($igrno,$totalbalancetopay,$updatebankpoamount,$Bankid);
|
$result3= $this->cashbook_model->updateBankporeportpo($igrno,$totalbalancetopay,$updatebankpoamount,$Bankid,$IsActive);
|
||||||
$this->loadViews("bankstatement", $this->global,$data, NULL);
|
$this->loadViews("bankstatement", $this->global,$data, NULL);
|
||||||
}
|
}
|
||||||
public function Deletemappingpo()
|
public function Deletemappingpo()
|
||||||
@ -1511,19 +1663,13 @@ class cashbook extends BaseController
|
|||||||
//for T_Bankreport IsActive//
|
//for T_Bankreport IsActive//
|
||||||
$bankdebit=$_GET['debit'];
|
$bankdebit=$_GET['debit'];
|
||||||
$mapped= $Amount+$balancetoclear;
|
$mapped= $Amount+$balancetoclear;
|
||||||
if( $bankdebit==$mapped)
|
|
||||||
{
|
|
||||||
$active=0;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$active=1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/////////////////
|
/////////////////
|
||||||
|
|
||||||
$id=$_GET['id'];
|
$id=$_GET['id'];
|
||||||
|
|
||||||
|
|
||||||
$bankamount=$_GET['bankamount'];
|
$bankamount=$_GET['bankamount'];
|
||||||
$updateamount=$bankamount-$Amount;
|
$updateamount=$bankamount-$Amount;
|
||||||
$updatebalancetoclear=$Amount+$balancetoclear;
|
$updatebalancetoclear=$Amount+$balancetoclear;
|
||||||
@ -1544,7 +1690,7 @@ class cashbook extends BaseController
|
|||||||
}
|
}
|
||||||
|
|
||||||
$result= $this->cashbook_model->IgrDetailsStatusUpdate($igrno,$BankStatus);
|
$result= $this->cashbook_model->IgrDetailsStatusUpdate($igrno,$BankStatus);
|
||||||
$result1= $this->cashbook_model->deletemapping($Bankid,$updateamount,$updatebalancetoclear,$active);
|
$result1= $this->cashbook_model->deletemapping($Bankid,$updateamount,$updatebalancetoclear);
|
||||||
//for update mapping amount in t_bankmappingpo table//
|
//for update mapping amount in t_bankmappingpo table//
|
||||||
$balancetopay=$_GET['balancetopay'];
|
$balancetopay=$_GET['balancetopay'];
|
||||||
$totalbalancetopay=$Amount + $balancetopay;
|
$totalbalancetopay=$Amount + $balancetopay;
|
||||||
@ -1583,16 +1729,7 @@ class cashbook extends BaseController
|
|||||||
$updateclearbalance=$bankingclear-$amountreceived;//450-650
|
$updateclearbalance=$bankingclear-$amountreceived;//450-650
|
||||||
}
|
}
|
||||||
|
|
||||||
// if($amountreceived<0)
|
|
||||||
// {
|
|
||||||
// $updatebalancetoclear=$amountreceived+$bankingbalclear;
|
|
||||||
// $updateclearbalance=$amountreceived+$bankingclear;
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
// $updatebalancetoclear=$bankingbalclear+$amountreceived;
|
|
||||||
// $updateclearbalance=$bankingclear+$amountreceived;
|
|
||||||
// }
|
|
||||||
|
|
||||||
//update Isactive field in T_Bankreport //////
|
//update Isactive field in T_Bankreport //////
|
||||||
$mapped=$balancetoreceived+$amountreceived;
|
$mapped=$balancetoreceived+$amountreceived;
|
||||||
@ -1606,14 +1743,9 @@ class cashbook extends BaseController
|
|||||||
}
|
}
|
||||||
$bankstatement=array('cbalancetocleared'=>$updatebalancetoclear,'cclearbalance'=>$updateclearbalance,'IsActive'=>$active);
|
$bankstatement=array('cbalancetocleared'=>$updatebalancetoclear,'cclearbalance'=>$updateclearbalance,'IsActive'=>$active);
|
||||||
$result1= $this->cashbook_model->updatebankreportiv($bankid,$bankstatement);
|
$result1= $this->cashbook_model->updatebankreportiv($bankid,$bankstatement);
|
||||||
if($totinvoiceamount==$amountreceived)
|
|
||||||
{
|
|
||||||
$receivedstatus=NO_RECEIVED;
|
$receivedstatus=NO_RECEIVED;
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$receivedstatus=PARTIALLY_RECEIVED;
|
|
||||||
}
|
|
||||||
$IsActive=0;
|
$IsActive=0;
|
||||||
//$data['$latestamount'] = $this->cashbook_model->getlatestamount($invoiceno);
|
//$data['$latestamount'] = $this->cashbook_model->getlatestamount($invoiceno);
|
||||||
//print_r($data['$latestamount']);
|
//print_r($data['$latestamount']);
|
||||||
@ -1621,7 +1753,7 @@ class cashbook extends BaseController
|
|||||||
//$balancetoreceived1=$data['$latestamount'][0]->balancetoreceived;
|
//$balancetoreceived1=$data['$latestamount'][0]->balancetoreceived;
|
||||||
$updatebalancetoreceived=$balancetoreceived+$amountreceived;
|
$updatebalancetoreceived=$balancetoreceived+$amountreceived;
|
||||||
$updateamountreceived=$totinvoiceamount-$updatebalancetoreceived;
|
$updateamountreceived=$totinvoiceamount-$updatebalancetoreceived;
|
||||||
$result3= $this->cashbook_model->updatebankinvoicereport($invoiceno,$bankid,$updatebalancetoreceived,$updateamountreceived);
|
$result3= $this->cashbook_model->updatebankinvoicereport($invoiceno,$bankid,$updatebalancetoreceived,$updateamountreceived,$IsActive);
|
||||||
if(count($result3)>0)
|
if(count($result3)>0)
|
||||||
{
|
{
|
||||||
$result1=$this->cashbook_model->UpdateIpinvoiceStatus($invoiceno,$receivedstatus);
|
$result1=$this->cashbook_model->UpdateIpinvoiceStatus($invoiceno,$receivedstatus);
|
||||||
@ -1676,7 +1808,7 @@ class cashbook extends BaseController
|
|||||||
if(count($result1)>0)
|
if(count($result1)>0)
|
||||||
{
|
{
|
||||||
// $this->loadViews("Bankingstatement", $this->global,$result1, NULL);
|
// $this->loadViews("Bankingstatement", $this->global,$result1, NULL);
|
||||||
//echo "<script>alert('Deleted Successfully!');window.location.href='Bankingstatement';</script>";
|
// echo "<script>alert('Deleted Successfully!');window.location.href='Bankingstatement';</script>";
|
||||||
redirect('Bankingstatement','refresh');
|
redirect('Bankingstatement','refresh');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -290,12 +290,40 @@ GROUP BY financial_year";
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
function report_finyearamountreceived(){
|
||||||
|
|
||||||
|
|
||||||
|
$sql="SELECT
|
||||||
|
CASE WHEN MONTH(indate)>=4 THEN
|
||||||
|
concat(YEAR(indate), '-',YEAR(indate)+1)
|
||||||
|
ELSE concat(YEAR(indate)-1,'-', YEAR(indate)) END AS financial_year
|
||||||
|
FROM T_Bankinvoicereport
|
||||||
|
GROUP BY financial_year";
|
||||||
|
$query = $this->db->query($sql);
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
function report_finyearamountunreceived(){
|
||||||
|
|
||||||
|
|
||||||
|
$sql="SELECT
|
||||||
|
CASE WHEN MONTH(invoice_date_created)>=4 THEN
|
||||||
|
concat(YEAR(invoice_date_created), '-',YEAR(invoice_date_created)+1)
|
||||||
|
ELSE concat(YEAR(invoice_date_created)-1,'-', YEAR(invoice_date_created)) END AS financial_year
|
||||||
|
FROM ip_invoices
|
||||||
|
GROUP BY financial_year";
|
||||||
|
$query = $this->db->query($sql);
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function bankstatement($fdate,$tdate,$fa,$aa){
|
function bankstatement($fdate,$tdate,$fa,$aa){
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$sql="SELECT *,date_format(reportdate,'%d-%m-%Y')as date,tie.total,date_format(valuedate,'%d-%m-%Y')as valuedate from T_bankreport as br left join t_income_expense as tie on tie.bankid=br.ID where br.reportdate !=0 ";
|
$sql="SELECT *,date_format(reportdate,'%d-%m-%Y')as date,tie.total,date_format(valuedate,'%d-%m-%Y')as valuedate from T_bankreport as br left join t_income_expense as tie on tie.bankid=br.ID where br.reportdate !=0 ";
|
||||||
|
|
||||||
|
|
||||||
@ -417,6 +445,64 @@ if ($Supplierid!= ''){
|
|||||||
|
|
||||||
|
|
||||||
$sql.="group by id.IGRItemNo";
|
$sql.="group by id.IGRItemNo";
|
||||||
|
//echo $sql;
|
||||||
|
$query = $this->db->query($sql);
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
function debitbankstatemet1(){
|
||||||
|
|
||||||
|
|
||||||
|
$sql="select im.IGRNO as igrn,pm.POType as potype,im.PONO as PONO,im.IGRNO,id.IGRItemNo,im.MaterialRcvdDate as CreatedDate,br.Balancetopay,br.Amountpaid,sd.SupplierName as SupplierName,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.SGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.SGST /100))),0),2) as sgst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.CGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.CGST /100))),0),2) as cgst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.IGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.IGST /100))),0),2) as igst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)- (rt.AfterDiscount),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)- (st.Afterdiscountval)),0),2) as discount,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) + (rt.AfterFreightValue),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) + (st.AfterFreightValue)),0),2) as freight,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) +(rt.AfterPackagingValue),0),0),2) as Package,
|
||||||
|
|
||||||
|
round((
|
||||||
|
if(POType = 'IMPORT',(pm.ExchangeRate * (id.QuantityAsPerInvoice * pl.Rate)),
|
||||||
|
if(POType = 'CAPITAL' && CapitalRange = 0,(pm.ExchangeRate * (id.QuantityAsPerInvoice * pl.Rate)),
|
||||||
|
ifnull((id.QuantityAsPerInvoice * pl.Rate),0)))
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterSGST / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.After_SGST / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterCGST / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.After_CGST / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterIGST / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.After_IGST / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterFreightValue / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.AfterFreightValue / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterPackagingValue / pl.Quantity),0),0),2)
|
||||||
|
- round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterDiscount / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.Afterdiscountval / pl.Quantity)),0),2)),2) as total
|
||||||
|
from T_IGR_Master im
|
||||||
|
left join T_PurchaseOrder_LineItem pl on pl.PONO = im.PONO
|
||||||
|
join T_IGR_Details id on id.IGRNO = im.IGRNO and id.MaterialCode = pl.MaterialCode
|
||||||
|
join T_PurchaseOrder_Master pm on pm.PONO = pl.PONO
|
||||||
|
left join T_SupplierDetailsN sd on sd.SupplierID = pm.SupplierID
|
||||||
|
left join T_Service_Tax st on st.LineItemNo = pl.LineItemNo
|
||||||
|
left join T_Revenue_Tax rt on rt.LineItemNo = pl.LineItemNo
|
||||||
|
left join T_Bankporeport br on br.IGRLineItemNo=id.IGRItemNo
|
||||||
|
where im.IGRStatus = 'ST027' and id.BankStatus!='ST072' and br.IsActive=1" ;
|
||||||
|
|
||||||
|
$sql.=" group by id.IGRItemNo";
|
||||||
//echo $sql;
|
//echo $sql;
|
||||||
$query = $this->db->query($sql);
|
$query = $this->db->query($sql);
|
||||||
return $query->result();
|
return $query->result();
|
||||||
@ -550,22 +636,98 @@ $sql.="group by sd.SupplierName";
|
|||||||
return $query->result();
|
return $query->result();
|
||||||
|
|
||||||
}
|
}
|
||||||
// function seperatesupplier($supplierid)
|
function suppliertotalfilter($fa,$aa,$m,$fdate,$tdate)
|
||||||
|
{
|
||||||
|
$sql="select sd.SupplierName as SupplierName,sd.SupplierID,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.SGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.SGST /100))),0),2) as sgst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.CGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.CGST /100))),0),2) as cgst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(rt.IGST/100)),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)+((id.QuantityAsPerInvoice * pl.Rate)*(st.IGST /100))),0),2) as igst,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)- (rt.AfterDiscount),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate)- (st.Afterdiscountval)),0),2) as discount,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) + (rt.AfterFreightValue),
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) + (st.AfterFreightValue)),0),2) as freight,
|
||||||
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * pl.Rate) +(rt.AfterPackagingValue),0),0),2) as Package,
|
||||||
|
|
||||||
// {
|
sum(round((
|
||||||
// $this->db->select('pom.PONO,supp.SupplierName,pom.TotalOrderValue');
|
if(POType = 'IMPORT',(pm.ExchangeRate * (id.QuantityAsPerInvoice * pl.Rate)),
|
||||||
// $this->db->from ('T_SupplierDetailsN supp');
|
if(POType = 'CAPITAL' && CapitalRange = 0,(pm.ExchangeRate * (id.QuantityAsPerInvoice * pl.Rate)),
|
||||||
// $this->db->join('T_PurchaseOrder_Master pom','pom.SupplierID=supp.SupplierID');
|
ifnull((id.QuantityAsPerInvoice * pl.Rate),0)))
|
||||||
// $this->db->where_in('pom.Status',[ST044,ST056]);
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
// $this->db->where('supp.SupplierID',$supplierid);
|
(id.QuantityAsPerInvoice * rt.AfterSGST / pl.Quantity),
|
||||||
// //$this->db->group_by('supp.SupplierName');
|
(id.QuantityAsPerInvoice * st.After_SGST / pl.Quantity)),0),2)
|
||||||
// $query = $this->db->get();
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
// return $query->result();
|
(id.QuantityAsPerInvoice * rt.AfterCGST / pl.Quantity),
|
||||||
// }
|
(id.QuantityAsPerInvoice * st.After_CGST / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterIGST / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.After_IGST / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterFreightValue / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.AfterFreightValue / pl.Quantity)),0),2)
|
||||||
|
+ round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterPackagingValue / pl.Quantity),0),0),2)
|
||||||
|
- round(ifnull(if(POType = 'REVENUE',
|
||||||
|
(id.QuantityAsPerInvoice * rt.AfterDiscount / pl.Quantity),
|
||||||
|
(id.QuantityAsPerInvoice * st.Afterdiscountval / pl.Quantity)),0),2)),2)) as total
|
||||||
|
from T_IGR_Master im
|
||||||
|
left join T_PurchaseOrder_LineItem pl on pl.PONO = im.PONO
|
||||||
|
join T_IGR_Details id on id.IGRNO = im.IGRNO and id.MaterialCode = pl.MaterialCode
|
||||||
|
join T_PurchaseOrder_Master pm on pm.PONO = pl.PONO
|
||||||
|
left join T_SupplierDetailsN sd on sd.SupplierID = pm.SupplierID
|
||||||
|
left join T_Service_Tax st on st.LineItemNo = pl.LineItemNo
|
||||||
|
left join T_Revenue_Tax rt on rt.LineItemNo = pl.LineItemNo
|
||||||
|
left join T_Bankporeport br on br.IGRLineItemNo=id.IGRItemNo
|
||||||
|
where im.IGRStatus = 'ST027' and id.BankStatus ='ST072'";
|
||||||
|
|
||||||
|
|
||||||
|
// if ($Supplierid!= ''){
|
||||||
|
|
||||||
|
// $sql.="and sd.SupplierID = '".$Supplierid."'";
|
||||||
|
|
||||||
|
// }
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$sql.=" and (im.MaterialRcvdDate >= '".$fa."-04-01' and im.MaterialRcvdDate <= '".$aa."-03-31')";
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
|
||||||
|
//$sql.="and monthname(im.CreatedDate) = '".$m."'";
|
||||||
|
$sql.="and monthname(im.MaterialRcvdDate) = '".$m."'";
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if ($fdate and $tdate != ''){
|
||||||
|
$fromd= date("Y-m-d",strtotime($fdate));
|
||||||
|
$tod=date("Y-m-d",strtotime($tdate));
|
||||||
|
|
||||||
|
$sql.="and date(im.MaterialRcvdDate) >= '".$fromd."'
|
||||||
|
and date(im.MaterialRcvdDate) <= '".$tod."'";
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$sql.="group by sd.SupplierName";
|
||||||
|
//echo $sql;
|
||||||
|
$query = $this->db->query($sql);
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
}
|
||||||
function amountunpaid($supplierid)
|
function amountunpaid($supplierid)
|
||||||
{
|
{
|
||||||
|
|
||||||
$sql="select im.IGRNO as igrn,pm.POType as potype,im.PONO as PONO,im.IGRNO,id.IGRItemNo,im.MaterialRcvdDate,br.Balancetopay,br.Amountpaid,sd.SupplierName as SupplierName,sd.SupplierID,im.DeliveryChellanOrInvoiceNo,
|
$sql="select im.IGRNO as igrn,pm.POType as potype,im.PONO as PONO,im.IGRNO,id.IGRItemNo,im.MaterialRcvdDate,im.DeliveryChellanDate,im.CreatedDate,br.Balancetopay,br.Amountpaid,sd.SupplierName as SupplierName,bu.FilePath,bu.BillNo,inward.FilePath as Fpath, sd.SupplierID,im.DeliveryChellanOrInvoiceNo,DATEDIFF(CURDATE(),id.CreatedDate)as days,
|
||||||
round(ifnull(if(POType = 'REVENUE',
|
round(ifnull(if(POType = 'REVENUE',
|
||||||
(id.QuantityAsPerInvoice * pl.Rate)+(rt.AfterSGST),
|
(id.QuantityAsPerInvoice * pl.Rate)+(rt.AfterSGST),
|
||||||
(id.QuantityAsPerInvoice * pl.Rate)+(st.After_SGST )),0),2) as sgst,
|
(id.QuantityAsPerInvoice * pl.Rate)+(st.After_SGST )),0),2) as sgst,
|
||||||
@ -613,6 +775,8 @@ left join T_SupplierDetailsN sd on sd.SupplierID = pm.SupplierID
|
|||||||
left join T_Service_Tax st on st.LineItemNo = pl.LineItemNo
|
left join T_Service_Tax st on st.LineItemNo = pl.LineItemNo
|
||||||
left join T_Revenue_Tax rt on rt.LineItemNo = pl.LineItemNo
|
left join T_Revenue_Tax rt on rt.LineItemNo = pl.LineItemNo
|
||||||
left join T_Bankporeport br on br.IGRLineItemNo=id.IGRItemNo
|
left join T_Bankporeport br on br.IGRLineItemNo=id.IGRItemNo
|
||||||
|
left join T_Inwardgateregister_fileupload inward on inward.IGRNO =im.IGRNO
|
||||||
|
left join T_PurchaseOrder_BillUpload bu on bu.PONO=pm.PONO
|
||||||
where im.IGRStatus = 'ST027' and id.BankStatus ='ST072' and sd.SupplierID='".$supplierid."'";
|
where im.IGRStatus = 'ST027' and id.BankStatus ='ST072' and sd.SupplierID='".$supplierid."'";
|
||||||
$sql.="group by id.IGRItemNo";
|
$sql.="group by id.IGRItemNo";
|
||||||
//echo $sql;
|
//echo $sql;
|
||||||
@ -786,6 +950,7 @@ function receiptdata()
|
|||||||
$this->db->join ('T_bankreport br','br.ID=bm.mid');
|
$this->db->join ('T_bankreport br','br.ID=bm.mid');
|
||||||
$this->db->join('T_Inwardgateregister_fileupload inward','inward.IGRNO =igrm.IGRNO','left');
|
$this->db->join('T_Inwardgateregister_fileupload inward','inward.IGRNO =igrm.IGRNO','left');
|
||||||
$this->db->join ('T_PurchaseOrder_BillUpload bu','bm.PONO=bu.PONO','left');
|
$this->db->join ('T_PurchaseOrder_BillUpload bu','bm.PONO=bu.PONO','left');
|
||||||
|
$this->db->where('bm.IsActive',1);
|
||||||
if($fdate!='' && $tdate!='')
|
if($fdate!='' && $tdate!='')
|
||||||
{
|
{
|
||||||
$this->db->where('igrm.MaterialRcvdDate BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"');
|
$this->db->where('igrm.MaterialRcvdDate BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"');
|
||||||
@ -795,8 +960,7 @@ function receiptdata()
|
|||||||
$this->db->where('sd.SupplierID',$SupplierName);
|
$this->db->where('sd.SupplierID',$SupplierName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$this->db->group_by('bm.IGRLineItemNo');
|
||||||
$this->db->group_by('bm.id');
|
|
||||||
$query = $this->db->get();
|
$query = $this->db->get();
|
||||||
return $query->result();
|
return $query->result();
|
||||||
|
|
||||||
@ -860,8 +1024,8 @@ function receiptdata()
|
|||||||
function creditinvoicelist($bankid)
|
function creditinvoicelist($bankid)
|
||||||
{
|
{
|
||||||
$this->db->select('bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,
|
$this->db->select('bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,
|
||||||
bm.balancetoreceived,bm.amountreceived,bm.ID,br.Credit');
|
bm.balancetoreceived,bm.amountreceived,bm.ID,br.Credit,br.cclearbalance,br.cbalancetocleared');
|
||||||
$this->db->from ('T_Bankmappingiv bm');
|
$this->db->from ('T_Bankinvoicereport bm');
|
||||||
$this->db->join('T_bankreport br','br.ID=bm.bankid');
|
$this->db->join('T_bankreport br','br.ID=bm.bankid');
|
||||||
$this->db->where('bm.bankid',$bankid);
|
$this->db->where('bm.bankid',$bankid);
|
||||||
$this->db->where('bm.IsActive',1);
|
$this->db->where('bm.IsActive',1);
|
||||||
@ -870,27 +1034,77 @@ function receiptdata()
|
|||||||
return $query->result();
|
return $query->result();
|
||||||
|
|
||||||
}
|
}
|
||||||
function creditinvoicelistfilter($Customer,$fdate,$tdate)
|
function creditinvoicelistfilter($fdate,$tdate,$fa,$aa,$m)
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->db->select('bm.ID,bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,
|
$this->db->select('bm.ID,bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,
|
||||||
bm.balancetoreceived,bm.amountreceived,br.cclearbalance,br.cbalancetocleared');
|
bm.balancetoreceived,bm.amountreceived,br.cclearbalance,br.cbalancetocleared');
|
||||||
$this->db->from ('T_Bankmappingiv bm');
|
$this->db->from ('T_Bankinvoicereport bm');
|
||||||
$this->db->where('bm.IsActive',1);
|
|
||||||
$this->db->join ('ip_clients ic','ic.client_name = bm.customername','left');
|
$this->db->join ('ip_clients ic','ic.client_name = bm.customername','left');
|
||||||
$this->db->join('T_bankreport br','br.ID = bm.bankid');
|
$this->db->join('T_bankreport br','br.ID = bm.bankid');
|
||||||
|
$this->db->where('bm.IsActive',1);
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$year="(bm.indate >= '".$fa."-04-01' and bm.indate <= '".$aa."-03-31')";
|
||||||
|
$this->db->where($year);
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
|
||||||
|
//$sql.="and monthname(im.CreatedDate) = '".$m."'";
|
||||||
|
$month="monthname(bm.indate) = '".$m."'";
|
||||||
|
$this->db->where($month);
|
||||||
|
|
||||||
|
}
|
||||||
if($fdate!='' && $tdate!='')
|
if($fdate!='' && $tdate!='')
|
||||||
{
|
{
|
||||||
$this->db->where('bm.indate BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"');
|
$this->db->where('bm.indate BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"');
|
||||||
}
|
}
|
||||||
if($Customer!='')
|
|
||||||
{
|
|
||||||
$this->db->where('ic.client_id',$Customer);
|
|
||||||
}
|
|
||||||
//$this->db->group_by('invoiceno');
|
//$this->db->group_by('invoiceno');
|
||||||
|
|
||||||
$query = $this->db->get();
|
$query = $this->db->get();
|
||||||
return $query->result();
|
return $query->result();
|
||||||
|
|
||||||
|
}
|
||||||
|
function uncreditinvoicelistfilter($fdate,$tdate,$fa,$aa,$m)
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
$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','iva.invoice_id = iv.invoice_id');
|
||||||
|
$this->db->join ('ip_clients ic','iv.client_id = ic.client_id','left');
|
||||||
|
$this->db->join ('T_Bankinvoicereport BI',' iv.invoice_number =BI.invoiceno','left');
|
||||||
|
|
||||||
|
$this->db->where('iv.invoice_status_id','2');
|
||||||
|
$this->db->where('iv.receivedstatus','ST066');
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$year="(iv.invoice_date_created >= '".$fa."-04-01' and iv.invoice_date_created <= '".$aa."-03-31')";
|
||||||
|
$this->db->where($year);
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
|
||||||
|
//$sql.="and monthname(im.CreatedDate) = '".$m."'";
|
||||||
|
$month="monthname(iv.invoice_date_created) = '".$m."'";
|
||||||
|
$this->db->where($month);
|
||||||
|
|
||||||
|
}
|
||||||
|
if($fdate!='' && $tdate!='')
|
||||||
|
{
|
||||||
|
$this->db->where('iv.invoice_date_created BETWEEN "'. date('Y-m-d', strtotime($fdate)). '" and "'. date('Y-m-d', strtotime($tdate)).'"');
|
||||||
|
}
|
||||||
|
// $this->db->group_by('iva.invoice_id');
|
||||||
|
//$this->db->where('inc.type','PAYMENT');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
//for cashbook edit screen and update bankreport//
|
//for cashbook edit screen and update bankreport//
|
||||||
function invoiceamonut($bankid)
|
function invoiceamonut($bankid)
|
||||||
@ -952,17 +1166,16 @@ function receiptdata()
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function debitlistpo($pono)
|
function debitlistpo($igrlineitem)
|
||||||
{
|
{
|
||||||
$this->db->select('bmp.mid,bmp.PONO,bmp.IGRLineItemNo,bmp.Amountpaid,br.Narration');
|
$this->db->select('bmp.mid,bmp.PONO,bmp.IGRLineItemNo,bmp.Amountpaid,br.Narration');
|
||||||
$this->db->from ('T_Bankmappingpo as bmp');
|
$this->db->from ('T_Bankmappingpo as bmp');
|
||||||
$this->db->join('T_bankreport br','br.ID = bmp.mid');
|
$this->db->join('T_bankreport br','br.ID = bmp.mid');
|
||||||
$this->db->where('bmp.PONO',$pono);
|
$this->db->where('bmp.IGRLineItemNo',$igrlineitem);
|
||||||
$this->db->where('bmp.IsActive',1);
|
$this->db->where('bmp.IsActive',1);
|
||||||
$query = $this->db->get();
|
$query = $this->db->get();
|
||||||
return $query->result();
|
return $query->result();
|
||||||
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function creditlistinv($invno)
|
function creditlistinv($invno)
|
||||||
{
|
{
|
||||||
@ -1181,13 +1394,65 @@ function receiptdata()
|
|||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
function paided()
|
function paided($suppliername)
|
||||||
{
|
{
|
||||||
$this->db->select('*');
|
$this->db->select('bm.id,bm.mid,bm.PONO,bm.Suppliername,bm.Totalpoamount,
|
||||||
$this->db->from('T_Bankmappingpo');
|
bm.Balancetopay,bm.Amountpaid,bm.IGRNO,bm.IGRLineItemNo,br.Balancetocleared,br.Clearbalance');
|
||||||
$query = $this->db->get();
|
$this->db->from ('T_Bankporeport bm');
|
||||||
$result = $query->result();
|
$this->db->join('T_Inwardgateregister_fileupload inward','inward.IGRNO =bm.IGRNO','left');
|
||||||
return $result;
|
$this->db->join('T_PurchaseOrder_BillUpload bu','bm.PONO=bu.PONO','left');
|
||||||
|
$this->db->join('T_bankreport br','br.ID=bm.mid','left');
|
||||||
|
$this->db->where('bm.Suppliername',$suppliername);
|
||||||
|
$this->db->where('bm.IsActive',1);
|
||||||
|
$this->db->group_by('bm.IGRLineItemNo');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
}
|
||||||
|
function amountpaidsupplierwise()
|
||||||
|
{
|
||||||
|
$this->db->select('bm.id,bm.mid,bm.PONO,bm.Suppliername,bm.Totalpoamount,
|
||||||
|
bm.Balancetopay,sum(bm.Amountpaid) as Amountpaid,bm.IGRNO,bm.IGRLineItemNo');
|
||||||
|
$this->db->from ('T_Bankporeport bm');
|
||||||
|
$this->db->group_by('bm.Suppliername');
|
||||||
|
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
|
}
|
||||||
|
function amountpaidsupplierwisefilter($fa,$aa,$m,$fdate,$tdate)
|
||||||
|
{
|
||||||
|
$this->db->select('bm.id,bm.mid,bm.PONO,bm.Suppliername,sum(bm.Totalpoamount)as Totalpoamount,
|
||||||
|
bm.Balancetopay,sum(bm.Amountpaid) as Amountpaid,bm.Podate,bm.IGRLineItemNo');
|
||||||
|
$this->db->from ('T_Bankporeport bm');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$year="(bm.Podate >= '".$fa."-04-01' and bm.Podate <= '".$aa."-03-31')";
|
||||||
|
$this->db->where($year);
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
//$this->db->where('MONTH(pel.tgl_pembelian)',$bulan);
|
||||||
|
$month="monthname(bm.Podate) = '".$m."'";
|
||||||
|
$this->db->where($month);
|
||||||
|
// $sql.="and monthname(bm.Podate) = '".$m."'";
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($fdate and $tdate != ''){
|
||||||
|
$fromdate= date("Y-m-d",strtotime($fdate));
|
||||||
|
$todate=date("Y-m-d",strtotime($tdate));
|
||||||
|
$date = "date(bm.Podate) >= '".$fromdate."'
|
||||||
|
and date(bm.Podate) <= '".$todate."'";
|
||||||
|
$this->db->where($date);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$this->db->group_by('bm.Suppliername');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
}
|
}
|
||||||
// function unpaided()
|
// function unpaided()
|
||||||
@ -1204,16 +1469,141 @@ function receiptdata()
|
|||||||
// // return $result;
|
// // return $result;
|
||||||
|
|
||||||
// }
|
// }
|
||||||
function received()
|
function received($clientname)
|
||||||
{
|
{
|
||||||
$this->db->select('*');
|
$this->db->select('bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,
|
||||||
$this->db->from('T_Bankmappingiv');
|
bm.balancetoreceived,bm.amountreceived,bm.ID,br.Credit,br.cclearbalance,br.cbalancetocleared');
|
||||||
$query = $this->db->get();
|
$this->db->from ('T_Bankinvoicereport bm');
|
||||||
$result = $query->result();
|
$this->db->join('T_bankreport br','br.ID=bm.bankid');
|
||||||
return $result;
|
$this->db->where('bm.IsActive',1);
|
||||||
|
$this->db->where('bm.customername',$clientname);
|
||||||
|
//$this->db->group_by('invoiceno');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function creditinvoicesupplierwise()
|
||||||
|
{
|
||||||
|
$this->db->select('bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,ic.client_id,
|
||||||
|
bm.balancetoreceived,sum(bm.amountreceived)as amountreceived,bm.ID,br.Credit,br.cclearbalance,br.cbalancetocleared');
|
||||||
|
$this->db->from ('T_Bankinvoicereport bm');
|
||||||
|
$this->db->join('T_bankreport br','br.ID=bm.bankid');
|
||||||
|
$this->db->join('ip_clients ic','ic.client_name=bm.customername','left');
|
||||||
|
$this->db->where('bm.IsActive',1);
|
||||||
|
$this->db->group_by('bm.customername');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
function creditinvoicewisefilter($fdate,$tdate,$fa,$aa,$m)
|
||||||
|
{
|
||||||
|
$this->db->select('bm.indate,bm.invoiceno,bm.customername,bm.totinvoiceamount,bm.bankid,ic.client_id,
|
||||||
|
bm.balancetoreceived,sum(bm.amountreceived)as amountreceived,bm.ID,br.Credit,br.cclearbalance,br.cbalancetocleared');
|
||||||
|
$this->db->from ('T_Bankinvoicereport bm');
|
||||||
|
$this->db->join('T_bankreport br','br.ID=bm.bankid');
|
||||||
|
$this->db->join('ip_clients ic','ic.client_name=bm.customername','left');
|
||||||
|
$this->db->where('bm.IsActive',1);
|
||||||
|
// $this->db->where('bm.customername',$Customer);
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$year="(bm.indate >= '".$fa."-04-01' and bm.indate <= '".$aa."-03-31')";
|
||||||
|
$this->db->where($year);
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
//$this->db->where('MONTH(pel.tgl_pembelian)',$bulan);
|
||||||
|
$month="monthname(bm.indate) = '".$m."'";
|
||||||
|
$this->db->where($month);
|
||||||
|
// $sql.="and monthname(bm.Podate) = '".$m."'";
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($fdate and $tdate != ''){
|
||||||
|
$fromdate= date("Y-m-d",strtotime($fdate));
|
||||||
|
$todate=date("Y-m-d",strtotime($tdate));
|
||||||
|
$date = "date(bm.indate) >= '".$fromdate."'
|
||||||
|
and date(bm.indate) <= '".$todate."'";
|
||||||
|
$this->db->where($date);
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->db->group_by('bm.customername');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
function unreceived($clientname)
|
||||||
|
{
|
||||||
|
$this->db->distinct();
|
||||||
|
$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','iva.invoice_id = iv.invoice_id','left');
|
||||||
|
$this->db->join ('ip_clients ic','iv.client_id = ic.client_id','left');
|
||||||
|
$this->db->join ('T_Bankinvoicereport BI',' iv.invoice_number =BI.invoiceno','left');
|
||||||
|
$this->db->where('iv.receivedstatus ','ST066');
|
||||||
|
$this->db->where('iv.invoice_status_id','2');
|
||||||
|
$this->db->where('ic.client_name',$clientname);
|
||||||
|
// $this->db->where('iv.receivedstatus','ST066');
|
||||||
|
|
||||||
|
$this->db->group_by('iva.invoice_id');
|
||||||
|
//$this->db->where('inc.type','PAYMENT');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
function unreceivedsupplier()
|
||||||
|
{
|
||||||
|
|
||||||
|
$this->db->select('iva.invoice_id,sum(iva.invoice_total)as invoice_total,iv.invoice_date_created,iv.invoice_number,iva.invoice_paid,ic.client_name,BI.balancetoreceived,sum(BI.amountreceived)as amountreceived');
|
||||||
|
$this->db->from ('ip_invoice_amounts iva');
|
||||||
|
$this->db->join ('ip_invoices iv','iva.invoice_id = iv.invoice_id','left');
|
||||||
|
$this->db->join ('ip_clients ic','iv.client_id = ic.client_id','left');
|
||||||
|
$this->db->join ('T_Bankinvoicereport BI',' iv.invoice_number =BI.invoiceno','left');
|
||||||
|
$this->db->where('iv.receivedstatus','ST066');
|
||||||
|
$this->db->where('iv.invoice_status_id','2');
|
||||||
|
|
||||||
|
|
||||||
|
$this->db->group_by('ic.client_name');
|
||||||
|
//$this->db->where('inc.type','PAYMENT');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
function uncreditinvoicewisefilter($fdate,$tdate,$fa,$aa,$m)
|
||||||
|
{
|
||||||
|
|
||||||
|
$this->db->select('iva.invoice_id,sum(iva.invoice_total)as invoice_total,iv.invoice_date_created,iv.invoice_number,iva.invoice_paid,ic.client_name,BI.balancetoreceived,sum(BI.amountreceived)as amountreceived');
|
||||||
|
$this->db->from ('ip_invoice_amounts iva');
|
||||||
|
$this->db->join ('ip_invoices iv','iva.invoice_id = iv.invoice_id','left');
|
||||||
|
$this->db->join ('ip_clients ic','iv.client_id = ic.client_id','left');
|
||||||
|
$this->db->join ('T_Bankinvoicereport BI',' iv.invoice_number =BI.invoiceno','left');
|
||||||
|
// $this->db->where('bm.customername',$Customer);
|
||||||
|
if ($fa and $aa != ''){
|
||||||
|
|
||||||
|
//$sql.=" and (im.CreatedDate >= '".$fa."-04-01' and im.CreatedDate <= '".$aa."-03-31')";
|
||||||
|
$year="(iv.invoice_date_created >= '".$fa."-04-01' and iv.invoice_date_created <= '".$aa."-03-31')";
|
||||||
|
$this->db->where($year);
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($m!= ''){
|
||||||
|
//$this->db->where('MONTH(pel.tgl_pembelian)',$bulan);
|
||||||
|
$month="monthname(iv.invoice_date_created) = '".$m."'";
|
||||||
|
$this->db->where($month);
|
||||||
|
// $sql.="and monthname(bm.Podate) = '".$m."'";
|
||||||
|
|
||||||
|
}
|
||||||
|
if ($fdate and $tdate != ''){
|
||||||
|
$fromdate= date("Y-m-d",strtotime($fdate));
|
||||||
|
$todate=date("Y-m-d",strtotime($tdate));
|
||||||
|
$date = "date(iv.invoice_date_created) >= '".$fromdate."'
|
||||||
|
and date(iv.invoice_date_created) <= '".$todate."'";
|
||||||
|
$this->db->where($date);
|
||||||
|
}
|
||||||
|
$this->db->where('iv.receivedstatus','ST066');
|
||||||
|
$this->db->where('iv.invoice_status_id','2');
|
||||||
|
|
||||||
|
|
||||||
|
$this->db->group_by('ic.client_name');
|
||||||
|
//$this->db->where('inc.type','PAYMENT');
|
||||||
|
$query = $this->db->get();
|
||||||
|
return $query->result();
|
||||||
|
}
|
||||||
|
|
||||||
function igrdetailstatus($igrdetails,$igrlineitem)
|
function igrdetailstatus($igrdetails,$igrlineitem)
|
||||||
{
|
{
|
||||||
@ -1276,11 +1666,10 @@ function receiptdata()
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
function deletemapping($Bankid,$updateamount,$updatebalancetoclear,$active)
|
function deletemapping($Bankid,$updateamount,$updatebalancetoclear)
|
||||||
{
|
{
|
||||||
$this->db->set('Clearbalance',$updateamount);
|
$this->db->set('Clearbalance',$updateamount);
|
||||||
$this->db->set('Balancetocleared',$updatebalancetoclear);
|
$this->db->set('Balancetocleared',$updatebalancetoclear);
|
||||||
$this->db->set('IsActive',$active);
|
|
||||||
$this->db->where('ID',$Bankid);
|
$this->db->where('ID',$Bankid);
|
||||||
$this->db->update('T_bankreport');
|
$this->db->update('T_bankreport');
|
||||||
$r = $this->db->affected_rows();
|
$r = $this->db->affected_rows();
|
||||||
@ -1328,10 +1717,11 @@ function receiptdata()
|
|||||||
$r = $this->db->affected_rows();
|
$r = $this->db->affected_rows();
|
||||||
return $r;
|
return $r;
|
||||||
}
|
}
|
||||||
function updateBankporeportpo($igrno,$totalbalancetopay,$updatebankpoamount,$Bankid)
|
function updateBankporeportpo($igrno,$totalbalancetopay,$updatebankpoamount,$Bankid,$IsActive)
|
||||||
{
|
{
|
||||||
$this->db->set('Balancetopay',$totalbalancetopay);
|
$this->db->set('Balancetopay',$totalbalancetopay);
|
||||||
$this->db->set('Amountpaid',$updatebankpoamount);
|
$this->db->set('Amountpaid',$updatebankpoamount);
|
||||||
|
$this->db->set('IsActive',$IsActive);
|
||||||
$this->db->where('IGRLineItemNo',$igrno);
|
$this->db->where('IGRLineItemNo',$igrno);
|
||||||
$this->db->where('mid',$Bankid);
|
$this->db->where('mid',$Bankid);
|
||||||
$this->db->update('T_Bankporeport');
|
$this->db->update('T_Bankporeport');
|
||||||
@ -1339,10 +1729,11 @@ function receiptdata()
|
|||||||
return $r;
|
return $r;
|
||||||
|
|
||||||
}
|
}
|
||||||
function updatebankinvoicereport($invoiceno,$bankid,$updatebalancetoreceived,$updateamountreceived)
|
function updatebankinvoicereport($invoiceno,$bankid,$updatebalancetoreceived,$updateamountreceived,$IsActive)
|
||||||
{
|
{
|
||||||
$this->db->set('balancetoreceived',$updatebalancetoreceived);
|
$this->db->set('balancetoreceived',$updatebalancetoreceived);
|
||||||
$this->db->set('amountreceived',$updateamountreceived);
|
$this->db->set('amountreceived',$updateamountreceived);
|
||||||
|
$this->db->set('IsActive',$IsActive);
|
||||||
$this->db->where('invoiceno',$invoiceno);
|
$this->db->where('invoiceno',$invoiceno);
|
||||||
$this->db->where('bankid',$bankid);
|
$this->db->where('bankid',$bankid);
|
||||||
$this->db->update('T_Bankinvoicereport');
|
$this->db->update('T_Bankinvoicereport');
|
||||||
|
|||||||
@ -50,8 +50,8 @@ if(!empty($amountpaid))
|
|||||||
</div>-->
|
</div>-->
|
||||||
|
|
||||||
|
|
||||||
<div class="content-wrapper">
|
<div class="content-wrapper">
|
||||||
<section class ="content">
|
<section class ="content">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
||||||
<!-- Left col -->
|
<!-- Left col -->
|
||||||
@ -103,7 +103,7 @@ if(!empty($amountpaid))
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<center><h4 style="color:#3c8dbc"><?php echo $ap->Suppliername?></h4></center>
|
<center><h4 style="color:#3c8dbc"><?php echo $ap->Suppliername?></h4></center>
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -163,6 +163,7 @@ if(!empty($amountpaid))
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
<center><h4 style="color:#3c8dbc"><?php echo $ap->Suppliername?></h4></center>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
@ -188,12 +189,14 @@ if(!empty($amountpaid))
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<?php
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
$i=1;
|
$i=1;
|
||||||
$ti=0.00;
|
$ti=0.00;
|
||||||
$tvt=0.00;
|
$tvt=0.00;
|
||||||
if(!empty($bankdebit)){
|
if(!empty($bankdebit)){
|
||||||
foreach($bankdebit as $ap)
|
foreach($bankdebit as $ap)
|
||||||
{
|
{
|
||||||
|
$rate=$ap->Amountpaid;
|
||||||
// $id=$ap->id;
|
// $id=$ap->id;
|
||||||
//print_r($ap);
|
//print_r($ap);
|
||||||
?>
|
?>
|
||||||
@ -206,14 +209,14 @@ if(!empty($amountpaid))
|
|||||||
<input type="hidden" name="bankingid" id="bankingid<?php echo $i ?>" value="<?php echo $ap->mid; ?>"/>
|
<input type="hidden" name="bankingid" id="bankingid<?php echo $i ?>" value="<?php echo $ap->mid; ?>"/>
|
||||||
|
|
||||||
<td align="left" id="date<?php echo $i ?>"><span><?php echo date_format(date_create($ap->MaterialRcvdDate),'d-m-Y'); ?></span></td>
|
<td align="left" id="date<?php echo $i ?>"><span><?php echo date_format(date_create($ap->MaterialRcvdDate),'d-m-Y'); ?></span></td>
|
||||||
<td align="left" id="pono<?php echo $i ?>"><a href="<?= base_url() ?>cashbook/mappingdebit?sid=<?php echo $ap->PONO;?>"><span><?php echo $ap->PONO?></span></a></td>
|
<td align="left" id="pono"><span><?php echo $ap->PONO?></span></td>
|
||||||
<!--<td align="left"><a href="<?= base_url() ?>cashbook/bankreceipt?sid=<?php echo $t->PONO;?>"><span><?php echo $t->PONO?></span></a></td>-->
|
<!--<td align="left"><a href="<?= base_url() ?>cashbook/bankreceipt?sid=<?php echo $t->PONO;?>"><span><?php echo $t->PONO?></span></a></td>-->
|
||||||
<td align="left" id="igrno<?php echo $i ?>"><span><?php echo $ap->IGRNO?></span></td>
|
<td align="left" id="igrno<?php echo $i ?>"><span><?php echo $ap->IGRNO?></span></td>
|
||||||
<td align="left" id="igritemno<?php echo $i ?>"><span><?php echo $ap->IGRLineItemNo?></span></td>
|
<td align="left" id="igritemno<?php echo $i ?>"><a href="<?= base_url() ?>cashbook/mappingdebit?sid=<?php echo $ap->IGRLineItemNo;?>"><span><?php echo $ap->IGRLineItemNo?></span></a></td>
|
||||||
<td align="left" id="sn<?php echo $i ?>"><span><?php echo $ap->Suppliername?></span></td>
|
<td align="left" id="sn<?php echo $i ?>"><span><?php echo $ap->Suppliername?></span></td>
|
||||||
<td align="left" id="tpoa<?php echo $i ?>"><span><?php echo $ap->Totalpoamount?></span></td>
|
<td align="left" id="tpoa<?php echo $i ?>"><span><?php echo $ap->Totalpoamount?></span></td>
|
||||||
<td align="left" id="btp<?php echo $i ?>"><span><?php echo $ap->Balancetopay?></span></td>
|
<td align="left" id="btp<?php echo $i ?>"><span><?php echo $ap->Balancetopay?></span></td>
|
||||||
<td align="left" id="ap<?php echo $i ?>"><span><?php echo $ap->Amountpaid?></span></td>
|
<td align="left" id="ap<?php echo $i ?>"><span><?php $tot_amount=$tot_amount+round($rate)?> <?php echo round($rate,2)?></span></td>
|
||||||
<?php
|
<?php
|
||||||
if($ap->file !='')
|
if($ap->file !='')
|
||||||
{
|
{
|
||||||
@ -272,16 +275,38 @@ if(!empty($amountpaid))
|
|||||||
<?php
|
<?php
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
</tbody>
|
</tbody>
|
||||||
|
<tfoot width="100%">
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td class="amount"><strong>
|
||||||
|
<?php echo $tot_amount; ?>
|
||||||
|
</strong></td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
</tr>
|
||||||
|
</tfoot>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</section></div>
|
</section>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -319,10 +344,7 @@ var mappingid=$('#mapid'+i).val();
|
|||||||
|
|
||||||
|
|
||||||
var bankingclear=$('#bankingbalclear'+i).val();
|
var bankingclear=$('#bankingbalclear'+i).val();
|
||||||
|
|
||||||
var clearedbalance=$('#clearbal'+i).val();
|
var clearedbalance=$('#clearbal'+i).val();
|
||||||
|
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
data:{mappingid:mappingid,Totalpoamount:totalamount,paidamount:paidamount,balancetopay:balancetopay,IGRItemNo:Igritemno,bankid:bankid,balancetobankingclear:bankingclear,clearbalance:clearedbalance},
|
data:{mappingid:mappingid,Totalpoamount:totalamount,paidamount:paidamount,balancetopay:balancetopay,IGRItemNo:Igritemno,bankid:bankid,balancetobankingclear:bankingclear,clearbalance:clearedbalance},
|
||||||
type:"POST",
|
type:"POST",
|
||||||
@ -332,9 +354,9 @@ $.ajax({
|
|||||||
|
|
||||||
if(data)
|
if(data)
|
||||||
{
|
{
|
||||||
|
$('#content').loader('hide');
|
||||||
|
|
||||||
|
window.location.href ="amountpaid";
|
||||||
window.location.href ="Bankingstatement";
|
|
||||||
//location.reload();
|
//location.reload();
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -416,7 +438,7 @@ $( function() {
|
|||||||
|
|
||||||
})
|
})
|
||||||
.on( "change", function() {
|
.on( "change", function() {
|
||||||
to.datepicker("option", "minDate", getDate( this ) );
|
to.datepicker("option", "minDate", getDate( this ));
|
||||||
}),
|
}),
|
||||||
to = $( "#max-date" ).datepicker({
|
to = $( "#max-date" ).datepicker({
|
||||||
dateFormat: "dd-mm-yy",
|
dateFormat: "dd-mm-yy",
|
||||||
|
|||||||
@ -65,11 +65,86 @@ foreach($financialyear as $item)
|
|||||||
|
|
||||||
|
|
||||||
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Bank Credit Amount Received Report</b></p></h3></center>
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Amount Received Reports</b></p></h3></center>
|
||||||
<div class="box-body">
|
<?php
|
||||||
|
if(!empty($amountreceived)){
|
||||||
|
foreach($amountreceived as $ap)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
<center><h4 style="color:#3c8dbc"><?php echo $ap->customername?></h4></center>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
<div class="box-body">
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;">-->
|
||||||
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div style=" ;margin-left:0%;margin-top: -55px;"> -->
|
||||||
|
<!-- <p style="margin-left:25px;" id="bid" value="">Payment ID: </p> -->
|
||||||
|
<!--<p style="margin-left:25px;" id="debit1amount" value="">Total Amount: </p>-->
|
||||||
|
<!-- <p style="margin-left:25px;">Payment Mode: Bank</p>
|
||||||
|
<p style="margin-left:25px;" id="bamount" </p>
|
||||||
|
<p style="margin-left:25px;" id="bdate" value="">Payment Amount Date: </p> -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </div> -->
|
||||||
|
<!-- </div> -->
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
<label for="from_date">
|
<label for="from_date">
|
||||||
<?php echo 'From Date'; ?>
|
<?php echo 'From Date'; ?>
|
||||||
</label>
|
</label>
|
||||||
@ -82,7 +157,7 @@ foreach($financialyear as $item)
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
<label for="to_date">
|
<label for="to_date">
|
||||||
<?php echo 'To Date'; ?>
|
<?php echo 'To Date'; ?>
|
||||||
</label>
|
</label>
|
||||||
@ -90,35 +165,45 @@ foreach($financialyear as $item)
|
|||||||
<input name="to_date" id="min-date" class="form-control datepicker">
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
<span class="input-group-addon">
|
<span class="input-group-addon">
|
||||||
<i class="fa fa-calendar fa-fw"></i>
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-3" >
|
<!--<div class="col-md-2" >
|
||||||
<label for="from_date">
|
<label for="from_date">
|
||||||
<?php echo 'Customer'; ?>
|
<?php echo 'Customer'; ?>
|
||||||
</label>
|
</label>
|
||||||
<select class="form-control" id="Customer" name="Customer">
|
<select class="form-control" id="CustomerName" name="CustomerName">
|
||||||
<option value="">Select Customer</option>
|
<option value="">Select Customer</option>
|
||||||
<?php
|
<?php
|
||||||
foreach($getcustomer as $gs):
|
foreach($getcustomer as $gc):
|
||||||
|
|
||||||
{?>
|
{
|
||||||
|
|
||||||
<option value="<?php echo $gs->client_id;?>"><?php echo $gs->client_name ; ?></option>
|
?>
|
||||||
|
|
||||||
|
<option value="<?php echo $gc->client_id;?>"><?php echo $gc->client_name ;?></option>
|
||||||
|
|
||||||
|
|
||||||
<?php } endforeach; ?>
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>-->
|
||||||
<div class="col-md-2" style="margin-top:24px;">
|
|
||||||
<input type="submit" class="btn btn-success" name="btn_submit"
|
|
||||||
value="View Report">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2" style="margin-top:23px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase" >
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</div>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
@ -140,11 +225,12 @@ foreach($financialyear as $item)
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<?php
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
$i=1;
|
$i=1;
|
||||||
$ti=0.00;
|
$ti=0.00;
|
||||||
$tvt=0.00;
|
$tvt=0.00;
|
||||||
if(!empty($bankcredit)){
|
if(!empty($amountreceived)){
|
||||||
foreach($bankcredit as $ap)
|
foreach($amountreceived as $ap)
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
@ -166,7 +252,7 @@ foreach($financialyear as $item)
|
|||||||
<td align="left" id="sn<?php echo $i ?>"><span><?php echo $ap->customername?></span></td>
|
<td align="left" id="sn<?php echo $i ?>"><span><?php echo $ap->customername?></span></td>
|
||||||
<td align="left" id="totinvoiceamount<?php echo $i ?>"><span><?php echo $ap->totinvoiceamount?></span></td>
|
<td align="left" id="totinvoiceamount<?php echo $i ?>"><span><?php echo $ap->totinvoiceamount?></span></td>
|
||||||
<td align="left" id="balancetoreceived<?php echo $i ?>"><span><?php echo $ap->totinvoiceamount- $ap->amountreceived?></span></td>
|
<td align="left" id="balancetoreceived<?php echo $i ?>"><span><?php echo $ap->totinvoiceamount- $ap->amountreceived?></span></td>
|
||||||
<td align="left" id="amountreceived<?php echo $i ?>"><span><?php echo $ap->amountreceived?></span></td>
|
<td align="left" id="amountreceived<?php echo $i ?>"><span><?php $tot_amount=$tot_amount+round( $ap->amountreceived)?><?php echo $ap->amountreceived?></span></td>
|
||||||
<td>
|
<td>
|
||||||
<a data-toggle="tooltip" ><i class="fa fa-trash" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Delete details" onclick="invoice(<?php echo $i ?>)"></i> </a>
|
<a data-toggle="tooltip" ><i class="fa fa-trash" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Delete details" onclick="invoice(<?php echo $i ?>)"></i> </a>
|
||||||
</td>
|
</td>
|
||||||
@ -186,40 +272,21 @@ foreach($financialyear as $item)
|
|||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</tbody>
|
</tbody>
|
||||||
<!--<tfoot width="100%">
|
<tfoot width="100%">
|
||||||
<tr>
|
<tr>
|
||||||
<td style="text-align:left;"><strong>Total</strong></td>
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
<td> </td>
|
<td> </td>
|
||||||
<td> </td>
|
<td> </td>
|
||||||
<td> </td>
|
<td> </td>
|
||||||
<td> </td>
|
<td> </td>
|
||||||
<td style="text-align:right"><strong>
|
|
||||||
<?php
|
|
||||||
{
|
|
||||||
echo number_format($ti,2,'.','');
|
|
||||||
|
|
||||||
}
|
<td class="amount"><strong>
|
||||||
?>
|
<?php echo $tot_amount; ?>
|
||||||
</strong>
|
</strong></td>
|
||||||
</td>
|
<td> </td>
|
||||||
<td style="text-align:right"><strong>
|
|
||||||
<?php
|
|
||||||
{
|
|
||||||
echo number_format($tvt,2,'.','');
|
|
||||||
|
|
||||||
}
|
</tr>
|
||||||
?>
|
</tfoot>
|
||||||
</strong>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<td> </td>
|
|
||||||
<td> </td>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
</tfoot>-->
|
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@ -237,86 +304,16 @@ foreach($financialyear as $item)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- <script src="https://cdn.datatables.net/1.10.16/js/jquery.dataTables.min.js"></script> -->
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
function invoice(i)
|
|
||||||
{
|
|
||||||
|
|
||||||
$('#content').loader('show');
|
|
||||||
var totinvoiceamount=$('#totinvoiceamount'+i).text();
|
|
||||||
var balancetoreceived=$('#balancetoreceived'+i).text();
|
|
||||||
var invoiceno=$('#invno'+i).text();
|
|
||||||
var amountreceived=$('#amountreceived'+i).text();
|
|
||||||
var bankid=$('#bankid'+i).val();
|
|
||||||
var mappingid=$('#mapid'+i).val();
|
|
||||||
|
|
||||||
var bankingclear=$('#ccbalance'+i).val();
|
|
||||||
var bankingbalclear=$('#btc'+i).val();
|
|
||||||
|
|
||||||
$.ajax(
|
|
||||||
|
|
||||||
{
|
|
||||||
data:{mappingid:mappingid,invoiceno:invoiceno,bankid:bankid,amountreceived:amountreceived,bankingclear:bankingclear,bankingbalclear:bankingbalclear,totinvoiceamount:totinvoiceamount,balancetoreceived:balancetoreceived},
|
|
||||||
type:"POST",
|
|
||||||
url:"<?php echo base_url() ?>DeleteInvoice",
|
|
||||||
success:function(data)
|
|
||||||
{
|
|
||||||
|
|
||||||
if(data)
|
|
||||||
{
|
|
||||||
|
|
||||||
|
|
||||||
window.location.href ="Bankingstatement";
|
|
||||||
//location.reload();
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
$(document).ready(function() {
|
|
||||||
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
|
||||||
|
|
||||||
table = $('#req').DataTable( {
|
|
||||||
|
|
||||||
"aaSorting": [[ 0, "desc" ]],
|
|
||||||
"info": true,
|
|
||||||
|
|
||||||
"autoWidth": false,
|
|
||||||
orderCellsTop: true,
|
|
||||||
|
|
||||||
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
|
||||||
"<'row'<'col-md-6'><'col-md-6'>>" +
|
|
||||||
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
|
||||||
buttons: [
|
|
||||||
|
|
||||||
{
|
|
||||||
extend: 'excelHtml5',
|
|
||||||
footer: 'true',
|
|
||||||
messageTop: $('h3').text(),
|
|
||||||
title: 'cashbook Overall Report',
|
|
||||||
exportOptions: {
|
|
||||||
columns: ':visible'
|
|
||||||
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
'colvis'
|
|
||||||
]
|
|
||||||
} );
|
|
||||||
} );
|
|
||||||
|
|
||||||
$( function() {
|
$( function() {
|
||||||
//var dateFormat = "mm/dd/yy",
|
//var dateFormat = "mm/dd/yy",
|
||||||
from = $( "#min-date" )
|
from = $( "#min-date" )
|
||||||
@ -354,8 +351,78 @@ $( function() {
|
|||||||
return date;
|
return date;
|
||||||
}
|
}
|
||||||
} );
|
} );
|
||||||
|
function invoice(i)
|
||||||
|
{
|
||||||
|
|
||||||
|
$('#content').loader('show');
|
||||||
|
var totinvoiceamount=$('#totinvoiceamount'+i).text();
|
||||||
|
var balancetoreceived=$('#balancetoreceived'+i).text();
|
||||||
|
var invoiceno=$('#invno'+i).text();
|
||||||
|
var amountreceived=$('#amountreceived'+i).text();
|
||||||
|
var bankid=$('#bankid'+i).val();
|
||||||
|
var mappingid=$('#mapid'+i).val();
|
||||||
|
|
||||||
|
var bankingclear=$('#ccbalance'+i).val();
|
||||||
|
var bankingbalclear=$('#btc'+i).val();
|
||||||
|
|
||||||
|
$.ajax(
|
||||||
|
|
||||||
|
{
|
||||||
|
data:{mappingid:mappingid,invoiceno:invoiceno,bankid:bankid,amountreceived:amountreceived,bankingclear:bankingclear,bankingbalclear:bankingbalclear,totinvoiceamount:totinvoiceamount,balancetoreceived:balancetoreceived},
|
||||||
|
type:"POST",
|
||||||
|
url:"<?php echo base_url() ?>DeleteInvoice",
|
||||||
|
success:function(data)
|
||||||
|
{
|
||||||
|
|
||||||
|
if(data)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
window.location.href ="Bankingstatement";
|
||||||
|
//location.reload();
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$(document).ready(function() {
|
||||||
|
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||||
|
|
||||||
|
table = $('#req').DataTable( {
|
||||||
|
|
||||||
|
"aaSorting": [[ 0, "desc" ]],
|
||||||
|
"info": true,
|
||||||
|
|
||||||
|
"autoWidth": false,
|
||||||
|
orderCellsTop: true,
|
||||||
|
|
||||||
|
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||||
|
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||||
|
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||||
|
buttons: [
|
||||||
|
|
||||||
|
{
|
||||||
|
extend: 'excelHtml5',
|
||||||
|
footer: 'true',
|
||||||
|
messageTop: $('h4').text(),
|
||||||
|
title: 'Amount Received Reports',
|
||||||
|
exportOptions: {
|
||||||
|
columns: ':visible'
|
||||||
|
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
'colvis'
|
||||||
|
]
|
||||||
|
} );
|
||||||
|
} );
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -33,6 +33,37 @@ foreach($financialyear as $item)
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<!-- Left col -->
|
<!-- Left col -->
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
|
<div class="modal fade" id="Fileshow" role="dialog">
|
||||||
|
<div class="modal-dialog">
|
||||||
|
<!-- Modal content-->
|
||||||
|
<form>
|
||||||
|
<div class="modal-content" style="width:800px;">
|
||||||
|
|
||||||
|
<!-- Table to show the line item of po -->
|
||||||
|
<div id="content" > </div>
|
||||||
|
<table class="table table-bordered" id="Inwardgateregistertable1" style="font-size:12px;">
|
||||||
|
<thead style="background-color:#ddf">
|
||||||
|
<tr>
|
||||||
|
<th>SNo</th>
|
||||||
|
<th>BillNO</th>
|
||||||
|
<th>PONO</th>
|
||||||
|
<th>FileName</th>
|
||||||
|
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="tbleAppend1">
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<div class="modal-footer">
|
||||||
|
<a class="btn btn-primary" data-dismiss="modal" value="Cancel">Cancel</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<!-- TABLE: LATEST ORDERS -->
|
<!-- TABLE: LATEST ORDERS -->
|
||||||
<div class="box box-info" id="content">
|
<div class="box box-info" id="content">
|
||||||
<br>
|
<br>
|
||||||
@ -175,24 +206,27 @@ foreach($financialyear as $item)
|
|||||||
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
||||||
<th>Invoice Date</th>
|
|
||||||
<th>Invoice No</th>
|
<th>Invoice No</th>
|
||||||
|
<th>Invoice Date</th><!--delivery challandate /igrmaster -->
|
||||||
<th>PONO</th>
|
<th>PONO</th>
|
||||||
|
<th>Inward Date</th><!--CreatedDate /igrmaster -->
|
||||||
<th>IGRNO</th>
|
<th>IGRNO</th>
|
||||||
<th>IGR Item No</th>
|
<th>IGR Item No</th>
|
||||||
<th>Supplier Name</th>
|
|
||||||
<th>IGR Amount (₹)</th>
|
<th>IGR Amount (₹)</th>
|
||||||
|
<th>IGR File</th>
|
||||||
|
<th>PO File</th>
|
||||||
|
<th>Over Due Days</th><!--DATEDIFF(CURDATE(),igrdetails.CreatedDate)as days-->
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<?php
|
<?php
|
||||||
|
$i=1;
|
||||||
$tot_amount = 0;
|
$tot_amount = 0;
|
||||||
$ti=0.00;
|
$ti=0.00;
|
||||||
$tvt=0.00;
|
$tvt=0.00;
|
||||||
if(!empty($bankdepit)){
|
if(!empty($bankunpaid)){
|
||||||
foreach($bankdepit as $t)
|
foreach($bankunpaid as $t)
|
||||||
{
|
{
|
||||||
|
|
||||||
$status=$t->Paymentstatus;
|
$status=$t->Paymentstatus;
|
||||||
@ -201,14 +235,11 @@ foreach($financialyear as $item)
|
|||||||
$rate=$t->total;
|
$rate=$t->total;
|
||||||
|
|
||||||
|
|
||||||
if($status !='ST057')
|
|
||||||
{
|
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
||||||
|
<?php
|
||||||
<td align="left" id="date<?php echo $i ?>"><span><?php echo date_format(date_create($t->MaterialRcvdDate),'d-m-Y');?></span></td>
|
|
||||||
<?php
|
|
||||||
if($t->DeliveryChellanOrInvoiceNo=='')
|
if($t->DeliveryChellanOrInvoiceNo=='')
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
@ -222,11 +253,58 @@ foreach($financialyear as $item)
|
|||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<td align="left" id="pono"><span><?php echo $t->PONO?></span></a></td>
|
<td align="left" id="date<?php echo $i ?>"><span><?php echo date_format(date_create($t->DeliveryChellanDate),'d-m-Y');?></span></td>
|
||||||
<td align="left" id="igrno"><span><?php $tot_amount= $tot_amount + round($rate)?><?php echo $t->IGRNO?></span></a></td>
|
|
||||||
|
<td align="left" id="pono<?php echo $i ?>"><span><?php echo $t->PONO?></span></a></td>
|
||||||
|
<td align="left" id="date<?php echo $i ?>"><span><?php echo date_format(date_create($t->CreatedDate),'d-m-Y');?></span></td>
|
||||||
|
<td align="left" id="igrno<?php echo $i ?>"><span><?php $tot_amount= $tot_amount + round($rate)?><?php echo $t->IGRNO?></span></a></td>
|
||||||
<td align="left" id="igrlineitem<?php echo $i ?>" ><span><?php echo $t->IGRItemNo?></span></td>
|
<td align="left" id="igrlineitem<?php echo $i ?>" ><span><?php echo $t->IGRItemNo?></span></td>
|
||||||
<td align="left" id="sn<?php echo $i ?>" ><span><?php echo $t->SupplierName?></span></td>
|
|
||||||
<td align="left" id="tov<?php echo $i ?>" ><span><?php echo round($rate,2)?></span></td>
|
<td align="left" id="tov<?php echo $i ?>" ><span><?php echo round($rate,2)?></span></td>
|
||||||
|
<?php
|
||||||
|
if($t->file !='')
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<td> <a data-toggle="tooltip"><i class="fa fa-download" data-toggle="tooltip" title="<?php echo $record->pono; ?> -Attachment Available for Download/View" onclick="igrno(<?php echo $i ?>)"></i></a> </td>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
|
else if($t->Fpath !='')
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
||||||
|
<td> <a data-toggle="tooltip"><i class="fa fa-download" data-toggle="tooltip" title="<?php echo $record->pono; ?> -Attachment Available for Download/View" onclick="igrno(<?php echo $i ?>)"></i></a> </td>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
} else
|
||||||
|
{ ?>
|
||||||
|
<td>N/A</td>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<?php }
|
||||||
|
|
||||||
|
if($t->FilePath=='')
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
<td>N/A</td>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
<td>
|
||||||
|
<a data-toggle="tooltip" ><i class="fa fa-download" data-toggle="tooltip" title="<?php echo $record->pono; ?> - Click here to Delete details" onclick="pono(<?php echo $i ?>)"></i> </a>
|
||||||
|
</td>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
<td align="left" id="tov<?php echo $i ?>" ><span><?php echo $t->days?></span></td>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -234,7 +312,7 @@ foreach($financialyear as $item)
|
|||||||
<?php
|
<?php
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</tbody>
|
</tbody>
|
||||||
<tfoot width="100%">
|
<tfoot width="100%">
|
||||||
@ -249,10 +327,11 @@ foreach($financialyear as $item)
|
|||||||
<td class="amount"><strong>
|
<td class="amount"><strong>
|
||||||
<?php echo $tot_amount; ?>
|
<?php echo $tot_amount; ?>
|
||||||
</strong></td>
|
</strong></td>
|
||||||
|
<td> </td>
|
||||||
</tr>
|
</tr>
|
||||||
</tfoot>
|
</tfoot>
|
||||||
|
|
||||||
<?php } ?>
|
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
||||||
@ -275,6 +354,119 @@ foreach($financialyear as $item)
|
|||||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
function pono(i)
|
||||||
|
{
|
||||||
|
var igrno=$('#igrno'+i).text();
|
||||||
|
var pono =$('#pono'+i).text();
|
||||||
|
|
||||||
|
$("#Fileshow").modal('show');
|
||||||
|
$.ajax(
|
||||||
|
|
||||||
|
{
|
||||||
|
data:{igrno:igrno,pono:pono},
|
||||||
|
type:"POST",
|
||||||
|
url:"<?php echo base_url() ?>cashbook/filelist",
|
||||||
|
success:function(data)
|
||||||
|
{
|
||||||
|
|
||||||
|
var trHTML = '';
|
||||||
|
$.each($.parseJSON(data),function (i, item) {
|
||||||
|
i=i+1;
|
||||||
|
trHTML += '<tr>' +
|
||||||
|
'<td align="right">' + i + '</td>' +
|
||||||
|
|
||||||
|
'<td>' + item.BillNo+ '</td>' +
|
||||||
|
'<td>' + item.PONO+ '</td>' +
|
||||||
|
|
||||||
|
'<td><a target="_blank" href = <?php echo base_url()?>uploads/BillFiles/'+item.FilePath+'>'+ item.FilePath +'</a></td>' +
|
||||||
|
|
||||||
|
// '<td>' +item.FilePath+"<?php echo base_url().'uploads/BillFiles/'?>"> +'</td>'
|
||||||
|
|
||||||
|
'</tr>';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
$("#tbleAppend1").empty();
|
||||||
|
$('#Inwardgateregistertable1 > tbody').append(trHTML);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
function igrno(i)
|
||||||
|
{
|
||||||
|
var igrno=$('#igrno'+i).text();
|
||||||
|
var pono=$('#pono'+i).text();
|
||||||
|
$("#Fileshow").modal('show');
|
||||||
|
$.ajax(
|
||||||
|
|
||||||
|
{
|
||||||
|
data:{igrno:igrno,pono:pono},
|
||||||
|
type:"POST",
|
||||||
|
url:"<?php echo base_url()?>cashbook/IGRFilelist",
|
||||||
|
success:function(data)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
var trHTML = '';
|
||||||
|
var FilePath ='';
|
||||||
|
var Filename = '';
|
||||||
|
var PONO ='';
|
||||||
|
var BillNO ='';
|
||||||
|
i=0;
|
||||||
|
$.each($.parseJSON(data),function (i, item) {
|
||||||
|
|
||||||
|
if(item.file == null)
|
||||||
|
{ if(item.Remarks ==null)
|
||||||
|
{
|
||||||
|
//alert()
|
||||||
|
PONO =item.PONO;
|
||||||
|
BillNO =item.BillNo;
|
||||||
|
Filename =item.FilePath;
|
||||||
|
FilePath = "<?php echo base_url()?>uploads/Igrfiles/"+item.FilePath;
|
||||||
|
}else{
|
||||||
|
Filename ="BillDetails";
|
||||||
|
PONO =item.PONO;
|
||||||
|
BillNO =item.BillNo;
|
||||||
|
FilePath = item.FilePath;
|
||||||
|
}
|
||||||
|
|
||||||
|
}else{
|
||||||
|
Filename = item.file;
|
||||||
|
PONO =item.pono;
|
||||||
|
BillNO = '-';
|
||||||
|
|
||||||
|
FilePath ="<?php echo base_url()?>"+item.file;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if(Filename != null)
|
||||||
|
{
|
||||||
|
i=i+1;
|
||||||
|
i=i-1;
|
||||||
|
trHTML += '<tr id='+i+'>' +
|
||||||
|
'<td align="right">' + i + '</td>' +
|
||||||
|
'<td id="billno'+i+'">' + BillNO+ '</td>' +
|
||||||
|
'<td>' + PONO+ '</td>' +
|
||||||
|
|
||||||
|
'<td id="file'+i+'"><a target="_blank" href = '+FilePath+'>'+ Filename +'</a></td>' +
|
||||||
|
|
||||||
|
// '<td name="filepathname" id="filepathname" onclick="openbillmodel('+i+');"><i class="fa fa-pencil"></i></td>' +
|
||||||
|
'</tr>';
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
$("#tbleAppend1").empty();
|
||||||
|
$('#Inwardgateregistertable1 > tbody').append(trHTML);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
/** jquery on ready for DataPicker. */
|
/** jquery on ready for DataPicker. */
|
||||||
$( function() {
|
$( function() {
|
||||||
//var dateFormat = "mm/dd/yy",
|
//var dateFormat = "mm/dd/yy",
|
||||||
|
|||||||
269
application/views/bankamountunreceived.php
Normal file
269
application/views/bankamountunreceived.php
Normal file
@ -0,0 +1,269 @@
|
|||||||
|
<?php
|
||||||
|
foreach($financialyear as $item)
|
||||||
|
{
|
||||||
|
$finyear = $item->financial_year;
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||||
|
<style>
|
||||||
|
.dataTables_filter input {padding: 4px;}
|
||||||
|
|
||||||
|
.dataTables_filter {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.dataTables_paginate {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
div.dt-buttons {
|
||||||
|
position: relative;
|
||||||
|
float: right;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="content-wrapper">
|
||||||
|
<section class="content">
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
<!-- Left col -->
|
||||||
|
<div class="col-md-12">
|
||||||
|
<!-- TABLE: LATEST ORDERS -->
|
||||||
|
<div class="box box-info" id="content">
|
||||||
|
<br>
|
||||||
|
<div class="col-md-1 col-md-offset-11">
|
||||||
|
<a href="<?php base_url() ?>Bankingstatement" class="btn btn-primary" value="Back"/>Back</a>
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Un Receivable Invoice Report</b></p></h3></center>
|
||||||
|
<?php
|
||||||
|
if(!empty($amountunreceived)){
|
||||||
|
foreach($amountunreceived as $t)
|
||||||
|
|
||||||
|
{
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
<center><h4 style="color:#3c8dbc"><?php echo $t->client_name?></h4></center>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
|
|
||||||
|
|
||||||
|
<div class="box-body">
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;"> -->
|
||||||
|
|
||||||
|
<input type="hidden" id="debitamount" value="<?php echo $cash; ?>" placeholder="Debit Amount" readonly>
|
||||||
|
|
||||||
|
<input type="hidden" id="bankid" value="<?php echo $bankid; ?>" placeholder="Bank Id" readonly>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="from_date">
|
||||||
|
<?php echo 'From Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'To Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2" style="margin-top:20px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<input type="hidden" name="Rowid" id="Rowid" placeholder="Row Id" readonly >
|
||||||
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
<th>Date</th>
|
||||||
|
<th>Invoice Number</th>
|
||||||
|
<th>Customer Name</th>
|
||||||
|
<th>Invoice Amount (₹)</th>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
|
$i=1;
|
||||||
|
$ti=0.00;
|
||||||
|
$tvt=0.00;
|
||||||
|
if(!empty($amountunreceived)){
|
||||||
|
foreach($amountunreceived as $t)
|
||||||
|
|
||||||
|
{
|
||||||
|
//print_r($bankinvoicedata);
|
||||||
|
$status=$t->Paymentstatus;
|
||||||
|
$balancetopay=$t->Balancetopay;
|
||||||
|
if($status !='ST057')
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
|
||||||
|
<td align="left" id="invoicedate<?php echo $i ?>"><span><?php echo date_format(date_create($t->invoice_date_created),'d-m-Y');?></span></td>
|
||||||
|
<td align="left" id="invoice_id<?php echo $i ?>"><span><?php echo $t->invoice_number?></span></td>
|
||||||
|
<td align="left" id="client_name<?php echo $i ?>"><span><?php echo $t->client_name?></span></td>
|
||||||
|
<td align="left" id="invoice_paid<?php echo $i ?>"><span><?php $tot_amount=$tot_amount+$t->invoice_total?><?php echo $t->invoice_total?></span></td>
|
||||||
|
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
<?php
|
||||||
|
$i++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</tbody>
|
||||||
|
<tfoot width="100%">
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
|
<td> </td>
|
||||||
|
<td> </td>
|
||||||
|
|
||||||
|
<td class="amount"><strong>
|
||||||
|
<?php echo $tot_amount; ?>
|
||||||
|
</strong></td>
|
||||||
|
</tr>
|
||||||
|
</tfoot>
|
||||||
|
|
||||||
|
<?php } ?>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div><!-- / .box-body closed -->
|
||||||
|
</div><!-- /.box box-info closed-->
|
||||||
|
|
||||||
|
</div><!--/ .col (col-md-12)-->
|
||||||
|
|
||||||
|
</div><!-- /. 1st row closed -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
|
||||||
|
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||||
|
table = $('#req').DataTable( {
|
||||||
|
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||||
|
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||||
|
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||||
|
buttons: [
|
||||||
|
{
|
||||||
|
extend: 'excelHtml5',
|
||||||
|
footer: 'true',
|
||||||
|
messageTop: $('h3').text(),
|
||||||
|
title: 'Unpaid Purchase Order Report',
|
||||||
|
exportOptions: {
|
||||||
|
columns: ':visible'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
'colvis'
|
||||||
|
]
|
||||||
|
} );/** datatable closed */
|
||||||
|
} );/** ready closed */
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
@ -244,7 +244,7 @@ foreach($financialyear as $item)
|
|||||||
<td align="left" id="aa"><span><?php echo $mc->total?></span></td>
|
<td align="left" id="aa"><span><?php echo $mc->total?></span></td>
|
||||||
<td align="left" id="aa"><span><?php echo $mc->cashtype?></span></td>
|
<td align="left" id="aa"><span><?php echo $mc->cashtype?></span></td>
|
||||||
<td>
|
<td>
|
||||||
<a data-toggle="tooltip" href="<?php echo base_url().'cashbook/Deletemappingcashbookcredit?bankid='.$mc->bankid; ?>&id=<?php echo $mc->id?>&amount=<?php echo $mc->total?>&balancetoclear=<?php echo $balancetoclear?>&clearbalance=<?php echo $bankclear?>&accountname=<?php echo $mc->name?>&amounttype=<?php echo $mc->amounttype?>"><i class="fa fa-trash" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Delete details"></i> </a>
|
<a data-toggle="tooltip" href="<?php echo base_url().'Deleteinvoiceurl?bankid='.$mc->bankid; ?>&id=<?php echo $mc->id?>&amount=<?php echo $mc->total?>&balancetoclear=<?php echo $balancetoclear?>&clearbalance=<?php echo $bankclear?>&accountname=<?php echo $mc->name?>&amounttype=<?php echo $mc->amounttype?>"><i class="fa fa-trash" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Delete details"></i> </a>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
291
application/views/bankpaidsupp.php
Normal file
291
application/views/bankpaidsupp.php
Normal file
@ -0,0 +1,291 @@
|
|||||||
|
<?php
|
||||||
|
foreach($financialyear as $item)
|
||||||
|
{
|
||||||
|
$finyear = $item->financial_year;
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||||
|
<style>
|
||||||
|
.dataTables_filter input {padding: 4px;}
|
||||||
|
|
||||||
|
.dataTables_filter {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.dataTables_paginate {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
div.dt-buttons {
|
||||||
|
position: relative;
|
||||||
|
float: right;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="content-wrapper">
|
||||||
|
<section class="content">
|
||||||
|
<div class="row">
|
||||||
|
<!-- Left col -->
|
||||||
|
<div class="col-md-12">
|
||||||
|
<!-- TABLE: LATEST ORDERS -->
|
||||||
|
<div class="box box-info" id="content">
|
||||||
|
<br>
|
||||||
|
<div class="col-md-1 col-md-offset-11">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Sundry Debitors</b></p></h3></center>
|
||||||
|
<div class="box-body">
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;">-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div style=" ;margin-left:0%;margin-top: -55px;"> -->
|
||||||
|
<!-- <p style="margin-left:25px;" id="bid" value="">Payment ID: </p> -->
|
||||||
|
<!--<p style="margin-left:25px;" id="debit1amount" value="">Total Amount: </p>-->
|
||||||
|
<!-- <p style="margin-left:25px;">Payment Mode: Bank</p>
|
||||||
|
<p style="margin-left:25px;" id="bamount" </p>
|
||||||
|
<p style="margin-left:25px;" id="bdate" value="">Payment Amount Date: </p> -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </div> -->
|
||||||
|
<!-- </div> -->
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="from_date">
|
||||||
|
<?php echo 'From Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'To Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-3" style="margin-top:20px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<input type="hidden" name="Rowid" id="Rowid" placeholder="Row Id" readonly>
|
||||||
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
<th>Supplier Name</th>
|
||||||
|
<th>Paid Amount (₹)</th>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
|
$ti=0.00;
|
||||||
|
$tvt=0.00;
|
||||||
|
if(!empty($bankdebitsupp)){
|
||||||
|
foreach($bankdebitsupp as $t)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$rate=$t->Amountpaid;
|
||||||
|
$supplierid=$t->SupplierID;
|
||||||
|
|
||||||
|
|
||||||
|
?>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<td align="left" id="sn<?php echo $i ?>" ><a href="<?= base_url() ?>cashbook/amountpaid?sid=<?php echo $t->Suppliername;?>"><span><?php echo $t->Suppliername?></span></a></td>
|
||||||
|
<td align="left" id="tov<?php echo $i ?>" ><span><?php $tot_amount=$tot_amount+round($rate)?><?php echo round($rate,2)?></span></td>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
<?php
|
||||||
|
$i++;
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</tbody>
|
||||||
|
<tfoot width="100%">
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
|
|
||||||
|
|
||||||
|
<td class="amount"><strong>
|
||||||
|
<?php echo $tot_amount; ?>
|
||||||
|
</strong></td>
|
||||||
|
</tr>
|
||||||
|
</tfoot>
|
||||||
|
|
||||||
|
<?php } ?>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><!-- /.box -->
|
||||||
|
</div><!-- /.col -->
|
||||||
|
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$( function() {
|
||||||
|
//var dateFormat = "mm/dd/yy",
|
||||||
|
from = $( "#min-date" )
|
||||||
|
.datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
to.datepicker("option", "minDate", getDate( this ) );
|
||||||
|
}),
|
||||||
|
to = $( "#max-date" ).datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
from.datepicker( "option", "maxDate", getDate( this ) );
|
||||||
|
});
|
||||||
|
|
||||||
|
function getDate( element ) {
|
||||||
|
var date;
|
||||||
|
|
||||||
|
try {
|
||||||
|
date = $.datepicker.parseDate( dateFormat, element.value );
|
||||||
|
|
||||||
|
} catch( error ) {
|
||||||
|
date = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
} );
|
||||||
|
|
||||||
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
|
||||||
|
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||||
|
table = $('#req').DataTable( {
|
||||||
|
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||||
|
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||||
|
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||||
|
buttons: [
|
||||||
|
{
|
||||||
|
extend: 'excelHtml5',
|
||||||
|
footer: 'true',
|
||||||
|
messageTop: $('h3').text(),
|
||||||
|
title: 'Unpaid Purchase Order Report',
|
||||||
|
exportOptions: {
|
||||||
|
columns: ':visible'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
'colvis'
|
||||||
|
]
|
||||||
|
} );/** datatable closed */
|
||||||
|
} );/** ready closed */
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
291
application/views/bankreceivedsupp.php
Normal file
291
application/views/bankreceivedsupp.php
Normal file
@ -0,0 +1,291 @@
|
|||||||
|
<?php
|
||||||
|
foreach($financialyear as $item)
|
||||||
|
{
|
||||||
|
$finyear = $item->financial_year;
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||||
|
<style>
|
||||||
|
.dataTables_filter input {padding: 4px;}
|
||||||
|
|
||||||
|
.dataTables_filter {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.dataTables_paginate {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
div.dt-buttons {
|
||||||
|
position: relative;
|
||||||
|
float: right;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="content-wrapper">
|
||||||
|
<section class="content">
|
||||||
|
<div class="row">
|
||||||
|
<!-- Left col -->
|
||||||
|
<div class="col-md-12">
|
||||||
|
<!-- TABLE: LATEST ORDERS -->
|
||||||
|
<div class="box box-info" id="content">
|
||||||
|
<br>
|
||||||
|
<div class="col-md-1 col-md-offset-11">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Sundry Creditors</b></p></h3></center>
|
||||||
|
<div class="box-body">
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;">-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div style=" ;margin-left:0%;margin-top: -55px;"> -->
|
||||||
|
<!-- <p style="margin-left:25px;" id="bid" value="">Payment ID: </p> -->
|
||||||
|
<!--<p style="margin-left:25px;" id="debit1amount" value="">Total Amount: </p>-->
|
||||||
|
<!-- <p style="margin-left:25px;">Payment Mode: Bank</p>
|
||||||
|
<p style="margin-left:25px;" id="bamount" </p>
|
||||||
|
<p style="margin-left:25px;" id="bdate" value="">Payment Amount Date: </p> -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </div> -->
|
||||||
|
<!-- </div> -->
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="from_date">
|
||||||
|
<?php echo 'From Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'To Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2" style="margin-top:20px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<input type="hidden" name="Rowid" id="Rowid" placeholder="Row Id" readonly>
|
||||||
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
<th>Supplier Name</th>
|
||||||
|
<th>Paid Amount (₹)</th>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
|
$ti=0.00;
|
||||||
|
$tvt=0.00;
|
||||||
|
if(!empty($amountreceivedsupplier)){
|
||||||
|
foreach($amountreceivedsupplier as $t)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$amountreceived=$t->amountreceived;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
?>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<td align="left" id="sn<?php echo $i ?>" ><a href="<?= base_url() ?>Amountreceived?sid=<?php echo $t->customername;?>"><span><?php echo $t->customername?></span></a></td>
|
||||||
|
<td align="left" id="tov<?php echo $i ?>" ><span><?php $tot_amount=$tot_amount+round($amountreceived)?><?php echo round($amountreceived,2)?></span></td>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
<?php
|
||||||
|
$i++;
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</tbody>
|
||||||
|
<tfoot width="100%">
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
|
|
||||||
|
|
||||||
|
<td class="amount"><strong>
|
||||||
|
<?php echo $tot_amount; ?>
|
||||||
|
</strong></td>
|
||||||
|
</tr>
|
||||||
|
</tfoot>
|
||||||
|
|
||||||
|
<?php } ?>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><!-- /.box -->
|
||||||
|
</div><!-- /.col -->
|
||||||
|
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$( function() {
|
||||||
|
//var dateFormat = "mm/dd/yy",
|
||||||
|
from = $( "#min-date" )
|
||||||
|
.datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
to.datepicker("option", "minDate", getDate( this ) );
|
||||||
|
}),
|
||||||
|
to = $( "#max-date" ).datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
from.datepicker( "option", "maxDate", getDate( this ) );
|
||||||
|
});
|
||||||
|
|
||||||
|
function getDate( element ) {
|
||||||
|
var date;
|
||||||
|
|
||||||
|
try {
|
||||||
|
date = $.datepicker.parseDate( dateFormat, element.value );
|
||||||
|
|
||||||
|
} catch( error ) {
|
||||||
|
date = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
} );
|
||||||
|
|
||||||
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
|
||||||
|
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||||
|
table = $('#req').DataTable( {
|
||||||
|
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||||
|
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||||
|
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||||
|
buttons: [
|
||||||
|
{
|
||||||
|
extend: 'excelHtml5',
|
||||||
|
footer: 'true',
|
||||||
|
messageTop: $('h3').text(),
|
||||||
|
title: 'Receivable Report',
|
||||||
|
exportOptions: {
|
||||||
|
columns: ':visible'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
'colvis'
|
||||||
|
]
|
||||||
|
} );/** datatable closed */
|
||||||
|
} );/** ready closed */
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
0
application/views/bankreport.php
Executable file → Normal file
0
application/views/bankreport.php
Executable file → Normal file
0
application/views/bankreportprint.php
Executable file → Normal file
0
application/views/bankreportprint.php
Executable file → Normal file
@ -42,6 +42,104 @@ foreach($financialyear as $item)
|
|||||||
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Sundry Creditors</b></p></h3></center>
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Sundry Creditors</b></p></h3></center>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;">-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div style=" ;margin-left:0%;margin-top: -55px;"> -->
|
||||||
|
<!-- <p style="margin-left:25px;" id="bid" value="">Payment ID: </p> -->
|
||||||
|
<!--<p style="margin-left:25px;" id="debit1amount" value="">Total Amount: </p>-->
|
||||||
|
<!-- <p style="margin-left:25px;">Payment Mode: Bank</p>
|
||||||
|
<p style="margin-left:25px;" id="bamount" </p>
|
||||||
|
<p style="margin-left:25px;" id="bdate" value="">Payment Amount Date: </p> -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </div> -->
|
||||||
|
<!-- </div> -->
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<input type="hidden" id="supplierid" name="supplierid" value="<?php echo $t->SupplierID?>">
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="from_date">
|
||||||
|
<?php echo 'From Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'To Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-3" style="margin-top:20px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@ -66,8 +164,8 @@ foreach($financialyear as $item)
|
|||||||
$tot_amount=0;
|
$tot_amount=0;
|
||||||
$ti=0.00;
|
$ti=0.00;
|
||||||
$tvt=0.00;
|
$tvt=0.00;
|
||||||
if(!empty($bankdepit)){
|
if(!empty($bankunpaid)){
|
||||||
foreach($bankdepit as $t)
|
foreach($bankunpaid as $t)
|
||||||
{
|
{
|
||||||
|
|
||||||
$status=$t->Paymentstatus;
|
$status=$t->Paymentstatus;
|
||||||
@ -129,6 +227,44 @@ foreach($financialyear as $item)
|
|||||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
$( function() {
|
||||||
|
//var dateFormat = "mm/dd/yy",
|
||||||
|
from = $( "#min-date" )
|
||||||
|
.datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
to.datepicker("option", "minDate", getDate( this ) );
|
||||||
|
}),
|
||||||
|
to = $( "#max-date" ).datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
from.datepicker( "option", "maxDate", getDate( this ) );
|
||||||
|
});
|
||||||
|
|
||||||
|
function getDate( element ) {
|
||||||
|
var date;
|
||||||
|
|
||||||
|
try {
|
||||||
|
date = $.datepicker.parseDate( dateFormat, element.value );
|
||||||
|
|
||||||
|
} catch( error ) {
|
||||||
|
date = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
} );
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
291
application/views/bankunreceivedsupp.php
Normal file
291
application/views/bankunreceivedsupp.php
Normal file
@ -0,0 +1,291 @@
|
|||||||
|
<?php
|
||||||
|
foreach($financialyear as $item)
|
||||||
|
{
|
||||||
|
$finyear = $item->financial_year;
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||||
|
<style>
|
||||||
|
.dataTables_filter input {padding: 4px;}
|
||||||
|
|
||||||
|
.dataTables_filter {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
.dataTables_paginate {
|
||||||
|
width: 50%;
|
||||||
|
float: right;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
div.dt-buttons {
|
||||||
|
position: relative;
|
||||||
|
float: right;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="content-wrapper">
|
||||||
|
<section class="content">
|
||||||
|
<div class="row">
|
||||||
|
<!-- Left col -->
|
||||||
|
<div class="col-md-12">
|
||||||
|
<!-- TABLE: LATEST ORDERS -->
|
||||||
|
<div class="box box-info" id="content">
|
||||||
|
<br>
|
||||||
|
<div class="col-md-1 col-md-offset-11">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||||
|
<center><h3 class="box-title"><p style="color:#3c8dbc"><b>Sundry Creditors</b></p></h3></center>
|
||||||
|
<div class="box-body">
|
||||||
|
<div class="row">
|
||||||
|
<!-- <div class="col-md-3" style=" border: 2px solid black;font-size:14px;background-color:#ccc;">-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <div style=" ;margin-left:0%;margin-top: -55px;"> -->
|
||||||
|
<!-- <p style="margin-left:25px;" id="bid" value="">Payment ID: </p> -->
|
||||||
|
<!--<p style="margin-left:25px;" id="debit1amount" value="">Total Amount: </p>-->
|
||||||
|
<!-- <p style="margin-left:25px;">Payment Mode: Bank</p>
|
||||||
|
<p style="margin-left:25px;" id="bamount" </p>
|
||||||
|
<p style="margin-left:25px;" id="bdate" value="">Payment Amount Date: </p> -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </div> -->
|
||||||
|
<!-- </div> -->
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Year'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="financialyear" name="financialyear">
|
||||||
|
<option value="">Select Year</option>
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
foreach($finyear as $item):
|
||||||
|
|
||||||
|
{?>
|
||||||
|
|
||||||
|
<option value="<?php echo $item->financial_year;?>"><?php echo $item->financial_year ; ?></option>
|
||||||
|
|
||||||
|
|
||||||
|
<?php } endforeach; ?>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'Month'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<select class="form-control" id="month" name="month">
|
||||||
|
<option value="">Select Month</option>
|
||||||
|
<option value="January">January</option>
|
||||||
|
<option value="February">February</option>
|
||||||
|
<option value="March">March</option>
|
||||||
|
<option value="April">April</option>
|
||||||
|
<option value="May">May</option>
|
||||||
|
<option value="June">June</option>
|
||||||
|
<option value="July">July</option>
|
||||||
|
<option value="August">August</option>
|
||||||
|
<option value="September">September</option>
|
||||||
|
<option value="October">October</option>
|
||||||
|
<option value="November">November</option>
|
||||||
|
<option value="December">December</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="from_date">
|
||||||
|
<?php echo 'From Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-3">
|
||||||
|
<label for="to_date">
|
||||||
|
<?php echo 'To Date'; ?>
|
||||||
|
</label>
|
||||||
|
<div class="input-group">
|
||||||
|
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||||
|
<span class="input-group-addon">
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-md-2" style="margin-top:20px;">
|
||||||
|
<!-- <div class="col-md-1 col-md-offset-10" style="margin-top:20px;"> -->
|
||||||
|
<input type="submit" class="btn btn-success" name="btn_submit" value="View Purchase">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<input type="hidden" name="Rowid" id="Rowid" placeholder="Row Id" readonly>
|
||||||
|
<table class="table table-bordered table-hover" id="req" style="table-layout:auto;">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
<th>Supplier Name</th>
|
||||||
|
<th>Paid Amount (₹)</th>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<?php
|
||||||
|
$tot_amount=0;
|
||||||
|
$ti=0.00;
|
||||||
|
$tvt=0.00;
|
||||||
|
if(!empty($amountunreceivedsupplier)){
|
||||||
|
foreach($amountunreceivedsupplier as $t)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$invoice_total=$t->invoice_total;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
?>
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<td align="left" id="sn<?php echo $i ?>" ><a href="<?= base_url() ?>cashbook/amountunreceived?sid=<?php echo $t->client_name;?>"><span><?php echo $t->client_name?></span></a></td>
|
||||||
|
<td align="left" id="tov<?php echo $i ?>" ><span><?php $tot_amount=$tot_amount+round($invoice_total)?><?php echo round($invoice_total,2)?></span></td>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
<?php
|
||||||
|
$i++;
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</tbody>
|
||||||
|
<tfoot width="100%">
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:left;"><strong>Total</strong></td>
|
||||||
|
|
||||||
|
|
||||||
|
<td class="amount"><strong>
|
||||||
|
<?php echo $tot_amount; ?>
|
||||||
|
</strong></td>
|
||||||
|
</tr>
|
||||||
|
</tfoot>
|
||||||
|
|
||||||
|
<?php } ?>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><!-- /.box -->
|
||||||
|
</div><!-- /.col -->
|
||||||
|
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||||
|
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$( function() {
|
||||||
|
//var dateFormat = "mm/dd/yy",
|
||||||
|
from = $( "#min-date" )
|
||||||
|
.datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
to.datepicker("option", "minDate", getDate( this ) );
|
||||||
|
}),
|
||||||
|
to = $( "#max-date" ).datepicker({
|
||||||
|
dateFormat: "dd-mm-yy",
|
||||||
|
defaultDate: "+0d",
|
||||||
|
changeMonth: true,
|
||||||
|
//numberOfMonths: 1
|
||||||
|
|
||||||
|
})
|
||||||
|
.on( "change", function() {
|
||||||
|
from.datepicker( "option", "maxDate", getDate( this ) );
|
||||||
|
});
|
||||||
|
|
||||||
|
function getDate( element ) {
|
||||||
|
var date;
|
||||||
|
|
||||||
|
try {
|
||||||
|
date = $.datepicker.parseDate( dateFormat, element.value );
|
||||||
|
|
||||||
|
} catch( error ) {
|
||||||
|
date = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
} );
|
||||||
|
|
||||||
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
|
||||||
|
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||||
|
table = $('#req').DataTable( {
|
||||||
|
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||||
|
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||||
|
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||||
|
buttons: [
|
||||||
|
{
|
||||||
|
extend: 'excelHtml5',
|
||||||
|
footer: 'true',
|
||||||
|
messageTop: $('h3').text(),
|
||||||
|
title: 'Receivable Report',
|
||||||
|
exportOptions: {
|
||||||
|
columns: ':visible'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
'colvis'
|
||||||
|
]
|
||||||
|
} );/** datatable closed */
|
||||||
|
} );/** ready closed */
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue
Block a user