- $delivery = get_customer_trans($type_no, $type);
- if ($delivery['trans_link'] != 0)
- {
- if (get_voided_entry(ST_SALESINVOICE, $delivery['trans_link']) === false)
+ $childs = get_sales_child_trans($type_no, $type);
+ if ($childs && db_num_rows($childs))