diff --git a/account/application/controllers/accounts/Ledger.php b/account/application/controllers/accounts/Ledger.php
index 7780f7e..cc7dfb9 100644
--- a/account/application/controllers/accounts/Ledger.php
+++ b/account/application/controllers/accounts/Ledger.php
@@ -54,7 +54,7 @@ class Ledger extends CI_Controller
$data['to_date'] = null;
}
if (isset($_GET)) {
- $data = $_GET;
+ $data = $_GET;
}
$data['pageTitle'] = "View Party Ledger";
$data['fiscalStart'] = NepaliToEnglishDate($data['fromDate'] ?? $this->session->userdata['FiscalYear']->fiscalyear_from);
diff --git a/account/application/controllers/accounts/Reports.php b/account/application/controllers/accounts/Reports.php
index e8a60b1..b238497 100644
--- a/account/application/controllers/accounts/Reports.php
+++ b/account/application/controllers/accounts/Reports.php
@@ -38,7 +38,7 @@ class Reports extends CI_Controller
$data['AccountGroups'] = $AccountGroups;
loadView("accounts/ledgerall", $data);
break;
- case 'getledgersummary':
+ case 'getledgersummary':
$account_id = $this->uri->segment(3);
$data['pageTitle'] = "Ledger";
$Transactions = $this->db->where("status", 1)->where("account_id", $account_id)->get("tbl_voucherdetails")->result();
@@ -52,6 +52,25 @@ class Reports extends CI_Controller
$data['account_id'] = $account_id;
$this->load->view("accounts/ledgersummary", $data);
break;
+
+ case 'ledgerCashBook':
+ // $data = $this->uri->segment(3);
+ // $data['pageTitle'] = "Ledger";
+ // $Transactions = $this->db->where("status", 1)->where("account_id", $account_id)->get("tbl_voucherdetails")->result();
+ // $Account = $this->db->where("status", 1)->where("account_id", $account_id)->get("tbl_accounts")->row();
+ // foreach ($Transactions as $T) {
+ // // $T->AccountCategory=$this->db->where("status",1)->where("accategory_id",$AccountGroup->acgroup_id)->get("tbl_accategories")->result();
+ // $T->Voucher = $this->db->where("status", 1)->where("voucher_id", $T->voucher_id)->get("tbl_vouchers")->row();
+ // }
+ // $data['Transactions'] = $Transactions;
+ // $data['Account'] = $Account;
+ // $data['account_id'] = $account_id;
+ $data['fiscalStart'] = NepaliToEnglishDate($data['fromDate'] ?? $this->session->userdata['FiscalYear']->fiscalyear_from);
+ $data['fiscalEnd'] = NepaliToEnglishDate($data['toDate'] ?? $this->session->userdata['FiscalYear']->fiscalyear_to);
+
+ $this->load->view("accounts/ledger/ledger_cash_book_details",$data);
+ break;
+
case 'trialbalance_old':
$data['pageTitle'] = "Trial Balance";
$AccountGroups = $this->db->where("status", 1)->get("tbl_acgroups")->result();
@@ -268,8 +287,6 @@ class Reports extends CI_Controller
case 'getledgersummary':
$account_id = $this->uri->segment(5);
$this->myaccounts->showLedger($account_id);
-
-
break;
case 'default':
//show_404();
diff --git a/account/application/helpers/accounts_helper.php b/account/application/helpers/accounts_helper.php
index 2cf9a3d..e28c86c 100644
--- a/account/application/helpers/accounts_helper.php
+++ b/account/application/helpers/accounts_helper.php
@@ -80,7 +80,7 @@ function linkVoucher($voucher_id)
$ci = &get_instance();
$Voucher = $ci->db->where("voucher_id", $voucher_id)->get("tbl_vouchers")->row();
$Name = $ci->db->where("vouchertype_id", $Voucher->voucher_type)->get("tbl_vouchertypes")->row()->voucher_type . " Voucher # " . $Voucher->voucher_no;
- echo "$Name";
+ echo "$Name";
} else {
echo "";
}
diff --git a/account/application/libraries/Myaccounts.php b/account/application/libraries/Myaccounts.php
index 4b81182..5ff1fce 100644
--- a/account/application/libraries/Myaccounts.php
+++ b/account/application/libraries/Myaccounts.php
@@ -129,7 +129,8 @@ class myaccounts
{
$CI = &get_instance();
$Account = $CI->db->query("select * from tbl_accounts where account_id='$account_id'")->row();
- $Account->Balance = $this->getBalance($account_id);
+ // $Account->Balance = $this->getBalance($account_id);
+ // echo"
";print_r($Account); die();
return $Account;
}
function getBalance($account_id)
@@ -179,7 +180,6 @@ class myaccounts
$Account->Category = $CI->db->query("select * from tbl_accategories where accategory_id = $Account->accategory_id")->row();
}
//$q=$CI->db->get_compiled_select();
- //print($q);
?>
@@ -684,7 +684,7 @@ class myaccounts