<?php

function view_dashboard_transport_utility_expenses_details($vehicle_id, $from_date, $to_date, $expense_type_id=0) {
    

    $sql = dashboard_get_sql_for_transport_utility_expense_vehicles($from_date, $to_date, $expense_type_id, $vehicle_id);
    
    $sql = "SELECT ub.trans_type, ub.trans_date, ub.trans_no, ub.expense_type_id, ub.amount, ub.project_id, ub.bill_no, ub.bill_reference, ub.description, ub.expense_category_id, 
                    uet.description expense_type_name 
            FROM ($sql) ub 
                JOIN ".TB_PREF."utility_expense_types uet 
                    ON uet.id = ub.expense_type_id 
            ORDER BY trans_date DESC";
                
        return db_query($sql, "dashboard_get_transport_utility_expense_vehicles"); 
     
}
