Wareneingang bugfix abschliessen, removed edit from minidetail

This commit is contained in:
OpenXE 2023-10-01 19:48:21 +02:00
parent b613a99791
commit bdb05c747a
2 changed files with 13 additions and 27 deletions

View File

@ -1,7 +1,11 @@
<!--
<table id="table[MD5]">
<tr><td>{|Lieferschein|}:</td><td><input type="checkbox" onchange="lsclick[MD5]();" id="beiback_lieferschein[MD5]" disabled value="1" [BEIPACK_LIEFERSCHEIN] /></td><td><span id="lsnr[MD5]">[LSNR]</span></td><td><input type="button" value="{|Belege &auml;ndern|}" style="cursor:hand;" onclick="editclick[MD5]();" /></td></tr>
<tr><td>{|Lieferschein|}:</td><td><input type="checkbox" onchange="lsclick[MD5]();" id="beiback_lieferschein[MD5]" disabled value="1" [BEIPACK_LIEFERSCHEIN] /></td><td><span id="lsnr[MD5]">[LSNR]</span></td>
<td><input type="button" value="{|Belege &auml;ndern|}" style="cursor:hand;" onclick="editclick[MD5]();" /></td>
</tr>
<tr><td>{|Rechnung|}:</td><td><input type="checkbox" onchange="reclick[MD5]();" id="beiback_rechnung[MD5]" disabled value="1" [BEIPACK_RECHNUNG] /></td><td><span id="renr[MD5]">[RENR]</span></td><td></td></tr>
</table>
-->
<table width="100%">
<tr><td width="100%">[ARTIKEL]</td></tr>
@ -110,4 +114,4 @@ $(document).ready(function() {
});
});
</script>
</script>

View File

@ -1843,6 +1843,12 @@ class Wareneingang {
}
break;
case 'abschliessen':
// Save header and finish
$sql = "UPDATE paketannahme SET status='abgeschlossen' WHERE id='$id'";
$this->app->DB->Update($sql);
$this->app->erp->RunHook('wareneinang_paketannahme_abschliessen', 1, $id);
$this->app->Location->execute('index.php?module=wareneingang&action=list');
break;
}
@ -2001,31 +2007,7 @@ class Wareneingang {
$this->app->Tpl->Set('MESSAGE1',$msg);
$this->app->Tpl->Parse('PAGE', 'wareneingang_paketinhalt.tpl');
$returnordergeprueft = $this->app->Secure->GetPOST('returnordergeprueft');
$abschliessen = $this->app->Secure->GetPOST('abschliessen');
if ($abschliessen != '' || $returnordergeprueft != '') {
// paketannahme auf abgeschlossen setzten
$returnOrderId = empty($returnordergeprueft) ? null : $this->app->DB->Select(
sprintf(
'SELECT return_order_id FROM receiptdocument WHERE parcel_receipt_id = %d',
$id
)
);
// Save header and finish
$this->app->DB->Update(
"UPDATE paketannahme SET
status='abgeschlossen',
lsnr='" . $lsnr . "',
renr='" . $renr . "',
bemerkung='" . $bemerkung . "'
WHERE id='$id' LIMIT 1");
$this->app->erp->RunHook('wareneinang_paketannahme_abschliessen', 1, $id);
$this->app->Location->execute('index.php?module=wareneingang&action=list');
}
}
// END WareneingangPaketDistriInhalt