X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=manufacturing%2Fwork_order_add_finished.php;h=757f304ce4128df7f2b5befe80179412ad462adf;hb=93d7b68e2736d199b052c61d36deac23309b92f4;hp=fefbf1b5eb8abc83e216201f4059171e56d87e23;hpb=d1babda7c01b314d35fb89f2d195553b55936532;p=fa-stable.git diff --git a/manufacturing/work_order_add_finished.php b/manufacturing/work_order_add_finished.php index fefbf1b5..757f304c 100644 --- a/manufacturing/work_order_add_finished.php +++ b/manufacturing/work_order_add_finished.php @@ -69,18 +69,10 @@ if (strlen($wo_details[0]) == 0) function can_process($wo_details) { - global $SysPrefs, $Refs; + global $SysPrefs; - if (!$Refs->is_valid($_POST['ref'])) + if (!check_reference($_POST['ref'], ST_MANURECEIVE)) { - display_error(_("You must enter a reference.")); - set_focus('ref'); - return false; - } - - if (!is_new_reference($_POST['ref'], 29)) - { - display_error(_("The entered reference is already in use.")); set_focus('ref'); return false; } @@ -182,7 +174,6 @@ display_wo_details($_POST['selected_id']); start_form(); hidden('selected_id', $_POST['selected_id']); -//hidden('WOReqQuantity', $_POST['WOReqQuantity']); $dec = get_qty_dec($wo_details["stock_id"]); if (!isset($_POST['quantity']) || $_POST['quantity'] == '') @@ -191,7 +182,8 @@ if (!isset($_POST['quantity']) || $_POST['quantity'] == '') start_table(TABLESTYLE2); br(); -ref_row(_("Reference:"), 'ref', '', $Refs->get_next(29)); +ref_row(_("Reference:"), 'ref', '', $Refs->get_next(ST_MANURECEIVE, null, get_post('date_')), false, ST_MANURECEIVE); +date_row(_("Date:"), 'date_'); if (!isset($_POST['ProductionType'])) $_POST['ProductionType'] = 1; @@ -201,8 +193,6 @@ yesno_list_row(_("Type:"), 'ProductionType', $_POST['ProductionType'], small_qty_row(_("Quantity:"), 'quantity', null, null, null, $dec); -date_row(_("Date:"), 'date_'); - textarea_row(_("Memo:"), 'memo_', null, 40, 3); end_table(1);