Commit 58134be2 authored by Phil Höfer's avatar Phil Höfer
Browse files

Allow custom donation amount

parent 44ef15f1
......@@ -92,9 +92,15 @@ class MailController extends Controller
$bic = $request->input('bic', '');
$email = $request->input('email', '');
$frequency = $request->input('frequency', '');
$betrag = $request->input('Betrag', '');
$betrag = $request->input('amount', '');
$nachricht = $request->input('Nachricht', '');
# Allow custom amounts
if ($betrag == "custom") {
$betrag = $request->input('custom-amount', '');
$data['betrag'] = $betrag;
}
# Der enthaltene String wird dem Benutzer nach der Spende ausgegeben
$messageToUser = "";
$messageType = ""; # [success|error]
......
......@@ -87,7 +87,7 @@
<input type="radio" value="300" class="amount-radio" name="amount" id="amount-300euro" required="required"><label for="amount-300euro" class="amount-label">300</label> <br>
</div>
<div class="custom-amount-container">
<input type="radio" name="amount" id="amount-custom" required="required"><label for="amount-custom" class="amount-custom">{!! trans('spende.wunschbetrag') !!}</label> <input id="custom-amount" type="number" min="0" step=".01" placeholder="Betrag in €" value="">
<input type="radio" name="amount" id="amount-custom" value="custom" required="required"><label for="amount-custom" class="amount-custom">{!! trans('spende.wunschbetrag') !!}</label> <input id="custom-amount" type="number" name="custom-amount" min="0" step=".01" placeholder="Betrag in €" value="">
</div>
<br>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment