WIP Productchange
This commit is contained in:
@@ -380,7 +380,7 @@ class ContractController extends mfBaseController
|
||||
if (!$product->id) {
|
||||
$this->layout()->setFlash("Produkt nicht gefunden", "error");
|
||||
if($f == "o") {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id, "f" => $f]);
|
||||
$this->redirect("Order", "productchange", ["contract_id" => $id]);
|
||||
} else {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id]);
|
||||
}
|
||||
@@ -397,7 +397,7 @@ class ContractController extends mfBaseController
|
||||
} catch (Exception $e) {
|
||||
$this->layout()->setFlash("Ungültiges Kündigungsdateum", "error");
|
||||
if($f == "o") {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id, "f" => $f]);
|
||||
$this->redirect("Order", "productchange", ["contract_id" => $id]);
|
||||
} else {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id]);
|
||||
}
|
||||
@@ -420,7 +420,7 @@ class ContractController extends mfBaseController
|
||||
if (!$contract_data['termination_id'] || !$termination->id) {
|
||||
$this->layout()->setFlash("Produkt erfordert Anschluss.", "error");
|
||||
if($f == "o") {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id, "f" => $f]);
|
||||
$this->redirect("Order", "productchange", ["contract_id" => $id]);
|
||||
} else {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id]);
|
||||
}
|
||||
@@ -436,7 +436,7 @@ class ContractController extends mfBaseController
|
||||
if (!$new_contract_id) {
|
||||
$this->layout()->setFlash("Neuer Contract konnte nicht gespeichert werden", "error");
|
||||
if($f == "o") {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id, "f" => $f]);
|
||||
$this->redirect("Order", "productchange", ["contract_id" => $id]);
|
||||
} else {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id]);
|
||||
}
|
||||
@@ -463,9 +463,9 @@ class ContractController extends mfBaseController
|
||||
try {
|
||||
$cancel_date = DateTime::createFromFormat("d.m.Y", $link_data["cancel_date"], new DateTimeZone("Europe/Vienna"));
|
||||
} catch (Exception $e) {
|
||||
$this->layout()->setFlash("Ungültiges Kündigungsdateum", "error");
|
||||
$this->layout()->setFlash("Ungültiges Kündigungsdatum", "error");
|
||||
if($f == "o") {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id, "f" => $f]);
|
||||
$this->redirect("Order", "productchange", ["contract_id" => $id]);
|
||||
} else {
|
||||
$this->redirect("Contract", "productchange", ["contract_id" => $id]);
|
||||
}
|
||||
@@ -593,7 +593,7 @@ class ContractController extends mfBaseController
|
||||
$this->layout()->setFlash("Konnte Verknüpfung nicht speichern", "warn");
|
||||
}
|
||||
|
||||
$this->layout()->setFlash("Neuer Contract erfolgreich erstellt", "success");
|
||||
$this->layout()->setFlash("Produktwechsel erfolgreich erstellt", "success");
|
||||
if($f == "o") {
|
||||
$this->redirect("Order");
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user