<?php
/**********************************************************************
***********************************************************************/



function add_asset_valuation($trans_type, $trans_no, $trans_date, $asset_id, $current_value, $asset_total_qty, $ref_line_id) {
    $created_by = $_SESSION['wa_current_user']->user;
    $created_on = date('Y-m-d H:i:s');
    
        $sql = "INSERT INTO ".TB_PREF."asset_valuations (trans_type, trans_no, trans_date, asset_id, 
                                                         current_value, asset_total_qty, ref_line_id, 
                                                         created_by, created_on) 
                VALUES (".db_escape($trans_type).", ".db_escape($trans_no).", ".db_escape($trans_date).", ".db_escape($asset_id).", 
                        ".db_escape($current_value).", ".db_escape($asset_total_qty).", ".db_escape($ref_line_id).", 
                        ".db_escape($created_by).", ".db_escape($created_on).")";

            db_query($sql, "add_asset_valuation");
}

?>