This commit is contained in:
Sampanna Rimal
2024-08-12 16:21:46 +05:45
parent 16246fbdeb
commit fe8786f03f
11 changed files with 195 additions and 112 deletions

View File

@ -26,9 +26,10 @@ function displayCategoryTree($tree)
{
echo '<table class="table table-bordered">';
foreach ($tree as $category) {
// print_r($category);die;
echo '<tr>';
echo '<td class="col-1">' . $category['accategory_id'] . '</td>';
echo '<td class="col-6"><a href="' . site_url("accounts/reports/balance_by_group") . "?category=" . $category['accategory_id'] . '">' . $category['accategory_name'] . '</a></td>';
echo '<td class="col-6">'. ($category['parent_category_id'] == 0 ? "<b>" : "") .'<a href="' . site_url("accounts/reports/balance_by_group") . "?category=" . $category['accategory_id'] . '">' . $category['accategory_name'] . '</a>' .( $category['parent_category_id'] == 0? "</b>" : "") . '</td>';
echo '<td class="col-2">' . myCurrency($category['dr']) . '</td>';
echo '<td class="col-2">' . myCurrency($category['cr']) . '</td>';
echo '</tr>';