fixed creating WarehouseArticles

This commit is contained in:
Luca Haid
2025-12-22 09:36:22 +01:00
parent 27a9996aef
commit cdb19c323d

View File

@@ -53,11 +53,11 @@ class WarehouseArticleController extends TTCrud {
$this->additionalJSVariables['WAREHOUSE_ADMIN'] = false;
}
protected function beforeCreate() {
protected function beforeCreate($postData): bool {
if (!in_array($this->user->id, [2, 5, 6, 145, 14]))
self::sendError("Sie haben keine Berechtigung, Artikel zu erstellen.");
$this->validateArticleNumber($_POST);
$this->validateArticleNumber($postData);
return true;
}