lieferschein umlagern repeat

This commit is contained in:
OpenXE 2023-12-05 11:47:15 +01:00
parent a6f742ccc0
commit 8b9969176c
2 changed files with 9 additions and 2 deletions

View File

@ -19,6 +19,7 @@
<tr><td><b>{|Ziellager|}:</b></td><td><input type="text" id="ziellager" name="ziellager" value="[ZIELLAGER]" size="27" style="width:200px"></td></tr>
<tr>
<td>
<p [ERNEUT_UMLAGERN_HIDDEN]><input type="checkbox" name="erneut" id="erneut" value="1" size="20" [ERNEUT_CHECKED]>{|Erneut umlagern|}</input></p>
</td>
<td>
<button name="submit" value="umlagern" class="ui-button-icon" style="width:200px;">

View File

@ -478,9 +478,13 @@ class Lieferschein extends GenLieferschein
exit();
}
if ($umgelagert) {
$this->app->Tpl->AddMessage('error',"Lieferschein wurde bereits umgelagert.");
$submit = $this->app->Secure->GetPOST('submit');
$erneut = $this->app->Secure->GetPOST('erneut');
if ($umgelagert && !$erneut) {
$this->app->Tpl->AddMessage('warning',"Lieferschein wurde bereits umgelagert.");
} else {
$this->app->Tpl->Set('ERNEUT_UMLAGERN_HIDDEN','hidden');
$submit = $this->app->Secure->GetPOST('submit');
if ($submit == 'umlagern') {
@ -545,6 +549,8 @@ class Lieferschein extends GenLieferschein
$this->app->Tpl->Set('ZIELLAGER',$this->app->erp->ReplaceLagerPlatz(false, $ziellager_id, false));
$this->app->Tpl->Set('ERNEUT_CHECKED',$erneut?'checked':'');
$this->app->Tpl->Parse('PAGE',"lieferschein_umlagern.tpl");
}