X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=manufacturing%2Fwork_order_issue.php;h=025a91258c2dcfb7f76c398c90927b23c7ea9951;hb=406fee129771496f26ef91c0a25d487c7a77c054;hp=dfe11060557d844b293b7003ffd3a7d1f4075d00;hpb=e6f7c4e9bb2b0854ffdc9e1f6b4b6beb6cefe4e6;p=fa-stable.git diff --git a/manufacturing/work_order_issue.php b/manufacturing/work_order_issue.php index dfe11060..025a9125 100644 --- a/manufacturing/work_order_issue.php +++ b/manufacturing/work_order_issue.php @@ -71,30 +71,20 @@ function handle_new_order() //----------------------------------------------------------------------------------------------- function can_process() { - global $Refs; - - if (!is_date($_POST['date_'])) + if (!is_date($_POST['date_'])) { display_error(_("The entered date for the issue is invalid.")); set_focus('date_'); return false; } - elseif (!is_date_in_fiscalyear($_POST['date_'])) + elseif (!is_date_in_fiscalyear($_POST['date_'])) { display_error(_("The entered date is out of fiscal year or is closed for further data entry.")); set_focus('date_'); return false; } - if (!$Refs->is_valid($_POST['ref'])) - { - display_error(_("You must enter a reference.")); - set_focus('ref'); - return false; - } - - if (!is_new_reference($_POST['ref'], ST_MANUISSUE)) + if (!check_reference($_POST['ref'], ST_MANUISSUE)) { - display_error(_("The entered reference is already in use.")); set_focus('ref'); return false; }