Commit 5c997339 authored by Dominik Hebeler's avatar Dominik Hebeler

Telefonnummer

aus dem Spendenformular entfernt.
Spenden gehen jetzt an spenden@suma-ev.de
parent 72db5a2c
...@@ -82,7 +82,6 @@ class MailController extends Controller ...@@ -82,7 +82,6 @@ class MailController extends Controller
$messageType = "error"; $messageType = "error";
} else { } else {
$message = "\r\nName: " . $request->input('Name', 'Keine Angabe'); $message = "\r\nName: " . $request->input('Name', 'Keine Angabe');
$message .= "\r\nTelefon: " . $request->input('Telefon', 'Keine Angabe');
$message .= "\r\nKontonummer: " . $request->input('Kontonummer'); $message .= "\r\nKontonummer: " . $request->input('Kontonummer');
$message .= "\r\nBankleitzahl: " . $request->input('Bankleitzahl'); $message .= "\r\nBankleitzahl: " . $request->input('Bankleitzahl');
$message .= "\r\nBetrag: " . $request->input('Betrag'); $message .= "\r\nBetrag: " . $request->input('Betrag');
...@@ -92,12 +91,15 @@ class MailController extends Controller ...@@ -92,12 +91,15 @@ class MailController extends Controller
$message .= "\r\nUser-Agent: " . $request->header('User-Agent', ""); $message .= "\r\nUser-Agent: " . $request->header('User-Agent', "");
$replyTo = $request->input('email', 'anonymous-user@metager.de'); $replyTo = $request->input('email', 'anonymous-user@metager.de');
if($replyTo == ""){
$replyTo = "noreply@metager.de";
}
if (!filter_var($replyTo, FILTER_VALIDATE_EMAIL)) { if (!filter_var($replyTo, FILTER_VALIDATE_EMAIL)) {
$messageToUser .= "Die eingegebene Email-Addresse ($replyTo) scheint nicht korrekt zu sein."; $messageToUser .= "Die eingegebene Email-Addresse ($replyTo) scheint nicht korrekt zu sein.";
} }
try { try {
Mail::to("dominik@suma-ev.de") Mail::to("spenden@suma-ev.de")
->send(new Spende($replyTo, $message)); ->send(new Spende($replyTo, $message));
$messageType = "success"; $messageType = "success";
...@@ -115,7 +117,7 @@ class MailController extends Controller ...@@ -115,7 +117,7 @@ class MailController extends Controller
->with('title', 'Kontakt') ->with('title', 'Kontakt')
->with($messageType, $messageToUser); ->with($messageType, $messageToUser);
} else { } else {
$data = ['name' => $request->input('Name', 'Keine Angabe'), 'telefon' => $request->input('Telefon', 'Keine Angabe'), 'kontonummer' => $request->input('Kontonummer'), 'bankleitzahl' => $request->input('Bankleitzahl'), 'email' => $request->input('email', 'anonymous-user@metager.de'), 'betrag' => $request->input('Betrag'), 'nachricht' => $request->input('Nachricht')]; $data = ['name' => $request->input('Name', 'Keine Angabe'), 'kontonummer' => $request->input('Kontonummer'), 'bankleitzahl' => $request->input('Bankleitzahl'), 'email' => $request->input('email', 'anonymous-user@metager.de'), 'betrag' => $request->input('Betrag'), 'nachricht' => $request->input('Nachricht')];
$data = base64_encode(serialize($data)); $data = base64_encode(serialize($data));
return redirect(LaravelLocalization::getLocalizedURL(LaravelLocalization::getCurrentLocale(), route("danke", ['data' => $data]))); return redirect(LaravelLocalization::getLocalizedURL(LaravelLocalization::getCurrentLocale(), route("danke", ['data' => $data])));
} }
......
...@@ -16,10 +16,6 @@ ...@@ -16,10 +16,6 @@
<td>{{ trans('spende.lastschrift.3.placeholder')}}</td> <td>{{ trans('spende.lastschrift.3.placeholder')}}</td>
<td>{{ $data['name'] }}</td> <td>{{ $data['name'] }}</td>
</tr> </tr>
<tr>
<td>{{ trans('spende.telefonnummer') }}</td>
<td>{{ $data['telefon'] }}</td>
</tr>
<tr> <tr>
<td>Email</td> <td>Email</td>
<td>{{ $data['email'] }}</td> <td>{{ $data['email'] }}</td>
......
...@@ -24,10 +24,6 @@ ...@@ -24,10 +24,6 @@
<input type="email" class="form-control" id="email" name="email" placeholder="Email" value="{{ old('email') }}"> <input type="email" class="form-control" id="email" name="email" placeholder="Email" value="{{ old('email') }}">
</div> </div>
<div class="form-group donation-form-group"> <div class="form-group donation-form-group">
<label for="tel">{!! trans('spende.lastschrift.5') !!}</label>
<input type="tel" class="form-control" id="tel" name="Telefon" placeholder="xxxx-xxxxx" value="{{ old('Telefon') }}">
</div>
<div class="form-group donation-form-group">
<label for="iban">{!! trans('spende.lastschrift.6') !!}</label> <label for="iban">{!! trans('spende.lastschrift.6') !!}</label>
<input type="text" class="form-control" id="iban" required="" name="Kontonummer" placeholder="IBAN" value="{{ old('Kontonummer') }}"> <input type="text" class="form-control" id="iban" required="" name="Kontonummer" placeholder="IBAN" value="{{ old('Kontonummer') }}">
</div> </div>
......
...@@ -68,37 +68,37 @@ ...@@ -68,37 +68,37 @@
<div class="clearfix"></div> <div class="clearfix"></div>
<hr> <hr>
<div class="col-md-6"> <div class="col-md-6">
<h2 id="lastschrift">{{ trans('spende.lastschrift.1') }}</h2> <h3 id="lastschrift">{!! trans('spende.lastschrift.1') !!}</h3>
<p>{{ trans('spende.lastschrift.2') }}</p> <p>{!! trans('spende.lastschrift.2') !!}</p>
<form role="form" method="POST" action="{{ action('MailController@donation') }}"> <form id="donate" role="form" method="POST" action="/spende">
<input type="hidden" name="dt" value="{{ md5(date('Y') . date('m') . date('d')) }}" /> <input type="hidden" name="dt" value="{{ md5(date('Y') . date('m') . date('d')) }}">
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="Name">{{ trans('spende.lastschrift.3') }}</label> <label for="Name">{!! trans('spende.lastschrift.3') !!}</label>
<input type="text" class="form-control" id="Name" required="" name="Name" placeholder="{{ trans('spende.lastschrift.3.placeholder') }}"> <input type="text" class="form-control" id="Name" required="" name="Name" placeholder="{!! trans('spende.lastschrift.3.placeholder') !!}" value="{{ old('Name') }}" />
</div> </div>
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="email">{{ trans('spende.lastschrift.4') }}</label> <label for="email">{!! trans('spende.lastschrift.4') !!}</label>
<input type="email" class="form-control" id="email" name="email" placeholder="Email"> <input type="email" class="form-control" id="email" name="email" placeholder="Email" value="{{ old('email') }}">
</div> </div>
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="tel">{{ trans('spende.lastschrift.5') }}</label> <label for="iban">{!! trans('spende.lastschrift.6') !!}</label>
<input type="tel" class="form-control" id="tel" name="Telefon" placeholder="xxxx-xxxxx"> <input type="text" class="form-control" id="iban" required="" name="Kontonummer" placeholder="IBAN" value="{{ old('Kontonummer') }}">
</div> </div>
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="iban">{{ trans('spende.lastschrift.6') }}</label> <label for="bic">{!! trans('spende.lastschrift.7') !!}</label>
<input type="text" class="form-control" id="iban" required="" name="Kontonummer" placeholder="IBAN"> <input type="text" class="form-control" id="bic" required="" name="Bankleitzahl" placeholder="BIC" value="{{ old('Bankleitzahl') }}">
</div> </div>
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="bic">{{ trans('spende.lastschrift.7') }}</label> <label for="value">{!! trans('spende.lastschrift.8.value')!!} </label>
<input type="text" class="form-control" id="bic" required="" name="Bankleitzahl" placeholder="BIC"> <input type="number" class="form-control" id="value" required="" name="Betrag" placeholder="{!! trans('spende.lastschrift.8.value.placeholder') !!}" value="{{ old('Bankleitzahl') }}">
</div> </div>
<div class="form-group" style="text-align:left;"> <div class="form-group donation-form-group">
<label for="msg">{{ trans('spende.lastschrift.8') }}</label> <label for="msg">{!! trans('spende.lastschrift.8.message')!!}</label>
<textarea class="form-control" id="msg" required="" name="Nachricht" placeholder="{{ trans('spende.lastschrift.8.placeholder') }}"></textarea> <label for="msg"><u>{!! trans('spende.bankinfo.3')!!}</u></label>
</div> <textarea class="form-control" id="msg" name="Nachricht" placeholder="{!! trans('spende.lastschrift.8.message.placeholder') !!}">{{ old('Nachricht') }}</textarea>
<button type="submit" class="btn btn-default">{{ trans('spende.lastschrift.9') }}</button> </div>
</form> <button type="submit" form="donate" class="btn btn-default">{!! trans('spende.lastschrift.9') !!}</button>
<p>{{ trans('spende.lastschrift.10') }}</p> </form>
</div> </div>
<div class="col-md-6"> <div class="col-md-6">
<h2 id="mails">Aus den EMails vorheriger Spender:</h2> <h2 id="mails">Aus den EMails vorheriger Spender:</h2>
......
Markdown is supported
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