@@ 63-73 (lines=11) @@ | ||
60 | * |
|
61 | * @return Response |
|
62 | */ |
|
63 | public function newAction(Request $request) |
|
64 | { |
|
65 | $countryMapping = new CountryMapping(); |
|
66 | $form = $this->getForm($countryMapping); |
|
67 | $res = $this->handleUpdate($form, $countryMapping, $request); |
|
68 | if ($res) { |
|
69 | return $res; |
|
70 | } |
|
71 | ||
72 | return $this->updateResponse($countryMapping, $form); |
|
73 | } |
|
74 | ||
75 | /** |
|
76 | * @Method({"GET", "POST"}) |
|
@@ 84-93 (lines=10) @@ | ||
81 | * |
|
82 | * @return Response |
|
83 | */ |
|
84 | public function editAction(CountryMapping $countryMapping, Request $request) |
|
85 | { |
|
86 | $form = $this->getForm($countryMapping); |
|
87 | $res = $this->handleUpdate($form, $countryMapping, $request); |
|
88 | if ($res) { |
|
89 | return $res; |
|
90 | } |
|
91 | ||
92 | return $this->updateResponse($countryMapping, $form); |
|
93 | } |
|
94 | ||
95 | /** |
|
96 | * @param Form $form |
@@ 64-74 (lines=11) @@ | ||
61 | * |
|
62 | * @return Response |
|
63 | */ |
|
64 | public function newAction(Request $request) |
|
65 | { |
|
66 | $shippingMethodMapping = new ShippingMethodMapping(); |
|
67 | $form = $this->getForm($shippingMethodMapping); |
|
68 | $res = $this->handleUpdate($form, $shippingMethodMapping, $request); |
|
69 | if ($res) { |
|
70 | return $res; |
|
71 | } |
|
72 | ||
73 | return $this->updateResponse($shippingMethodMapping, $form); |
|
74 | } |
|
75 | ||
76 | /** |
|
77 | * @Method({"GET", "POST"}) |
|
@@ 85-94 (lines=10) @@ | ||
82 | * |
|
83 | * @return Response |
|
84 | */ |
|
85 | public function editAction(ShippingMethodMapping $shippingMethodMapping, Request $request) |
|
86 | { |
|
87 | $form = $this->getForm($shippingMethodMapping); |
|
88 | $res = $this->handleUpdate($form, $shippingMethodMapping, $request); |
|
89 | if ($res) { |
|
90 | return $res; |
|
91 | } |
|
92 | ||
93 | return $this->updateResponse($shippingMethodMapping, $form); |
|
94 | } |
|
95 | ||
96 | /** |
|
97 | * @param Form $form |