Commit c7a8030e authored by Dominik Hebeler's avatar Dominik Hebeler

Updated the donation form

parent 64780f51
This diff is collapsed.
...@@ -15,11 +15,12 @@ class Spende extends Mailable ...@@ -15,11 +15,12 @@ class Spende extends Mailable
* *
* @return void * @return void
*/ */
public function __construct($from, $message) public function __construct($from, $message, $name)
{ {
$this->subject = "MetaGer - Spende"; $this->subject = "MetaGer - Spende";
$this->reply = $from; $this->reply = $from;
$this->message = $message; $this->message = $message;
$this->name = $name;
} }
/** /**
...@@ -29,7 +30,7 @@ class Spende extends Mailable ...@@ -29,7 +30,7 @@ class Spende extends Mailable
*/ */
public function build() public function build()
{ {
return $this->from($this->reply) return $this->from($this->reply, $this->name)
->subject($this->subject) ->subject($this->subject)
->text('kontakt.mail') ->text('kontakt.mail')
->with('messageText', $this->message); ->with('messageText', $this->message);
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
"require": { "require": {
"php": "^7.1.3", "php": "^7.1.3",
"fideloper/proxy": "^4.0", "fideloper/proxy": "^4.0",
"globalcitizen/php-iban": "^2.6",
"jenssegers/agent": "^2.6", "jenssegers/agent": "^2.6",
"laravel/framework": "5.7.*", "laravel/framework": "5.7.*",
"laravel/tinker": "^1.0", "laravel/tinker": "^1.0",
...@@ -64,4 +65,4 @@ ...@@ -64,4 +65,4 @@
"@php artisan key:generate --ansi" "@php artisan key:generate --ansi"
] ]
} }
} }
\ No newline at end of file
...@@ -13,7 +13,7 @@ return [ ...@@ -13,7 +13,7 @@ return [
| |
*/ */
'fetch' => PDO::FETCH_OBJ, 'fetch' => PDO::FETCH_OBJ,
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
...@@ -26,7 +26,7 @@ return [ ...@@ -26,7 +26,7 @@ return [
| |
*/ */
'default' => env('DB_CONNECTION', 'mysql'), 'default' => env('DB_CONNECTION', 'mysql'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
...@@ -47,36 +47,52 @@ return [ ...@@ -47,36 +47,52 @@ return [
'connections' => [ 'connections' => [
'sqlite' => [ 'sqlite' => [
'driver' => 'sqlite', 'driver' => 'sqlite',
'database' => database_path(env('DB_DATABASE', 'database.sqlite')), 'database' => database_path(env('DB_DATABASE', 'database.sqlite')),
'prefix' => '', 'prefix' => '',
], ],
'mysql' => [ 'mysql' => [
'driver' => 'mysql', 'driver' => 'mysql',
'host' => env('DB_HOST', 'localhost'), 'host' => env('DB_HOST', 'localhost'),
'port' => env('DB_PORT', '3306'), 'port' => env('DB_PORT', '3306'),
'database' => env('DB_DATABASE', 'forge'), 'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'), 'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''), 'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8', 'charset' => 'utf8',
'collation' => 'utf8_unicode_ci',
'prefix' => '',
'strict' => true,
'engine' => null,
],
'spenden' => [
'driver' => 'mysql',
'host' => env('DB_HOST_SPENDEN', 'localhost'),
'port' => env('DB_PORT_SPENDEN', '3306'),
'database' => env('DB_DATABASE_SPENDEN', 'forge'),
'username' => env('DB_USERNAME_SPENDEN', 'forge'),
'password' => env('DB_PASSWORD_SPENDEN', ''),
'charset' => 'utf8',
'collation' => 'utf8_unicode_ci', 'collation' => 'utf8_unicode_ci',
'prefix' => '', 'prefix' => '',
'strict' => true, 'strict' => true,
'engine' => null, 'engine' => null,
], ],
'pgsql' => [ 'pgsql' => [
'driver' => 'pgsql', 'driver' => 'pgsql',
'host' => env('DB_HOST', 'localhost'), 'host' => env('DB_HOST', 'localhost'),
'port' => env('DB_PORT', '5432'), 'port' => env('DB_PORT', '5432'),
'database' => env('DB_DATABASE', 'forge'), 'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'), 'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''), 'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8', 'charset' => 'utf8',
'prefix' => '', 'prefix' => '',
'schema' => 'public', 'schema' => 'public',
'sslmode' => 'prefer', 'sslmode' => 'prefer',
], ],
], ],
...@@ -92,7 +108,7 @@ return [ ...@@ -92,7 +108,7 @@ return [
| |
*/ */
'migrations' => 'migrations', 'migrations' => 'migrations',
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
...@@ -105,26 +121,26 @@ return [ ...@@ -105,26 +121,26 @@ return [
| |
*/ */
'redis' => [ 'redis' => [
'cluster' => false, 'cluster' => false,
'default' => [ 'default' => [
'host' => env('REDIS_HOST', 'localhost'), 'host' => env('REDIS_HOST', 'localhost'),
'password' => env('REDIS_PASSWORD', null), 'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379), 'port' => env('REDIS_PORT', 6379),
'database' => 0, 'database' => 0,
], ],
'redisLogs' => [ 'redisLogs' => [
'host' => env('REDIS_LOGS_HOST', 'localhost'), 'host' => env('REDIS_LOGS_HOST', 'localhost'),
'password' => env('REDIS_LOGS_PASSWORD', env('REDIS_PASSWORD', null)), 'password' => env('REDIS_LOGS_PASSWORD', env('REDIS_PASSWORD', null)),
'port' => env('REDIS_LOGS_PORT', 6379), 'port' => env('REDIS_LOGS_PORT', 6379),
'database' => 1, 'database' => 1,
], ],
'redisCache' => [ 'redisCache' => [
'host' => env('REDIS_CACHE_HOST', 'localhost'), 'host' => env('REDIS_CACHE_HOST', 'localhost'),
'password' => env('REDIS_CACHE_PASSWORD', env('REDIS_PASSWORD', null)), 'password' => env('REDIS_CACHE_PASSWORD', env('REDIS_PASSWORD', null)),
'port' => env('REDIS_CACHE_PORT', 6379), 'port' => env('REDIS_CACHE_PORT', 6379),
'database' => 2, 'database' => 2,
], ],
......
This diff is collapsed.
...@@ -22,11 +22,11 @@ ...@@ -22,11 +22,11 @@
</tr> </tr>
<tr> <tr>
<td>{{ trans('spende.iban') }}</td> <td>{{ trans('spende.iban') }}</td>
<td>{{ $data['kontonummer'] }}</td> <td>{{ $data['iban'] }}</td>
</tr> </tr>
<tr> <tr>
<td>{{ trans('spende.bic') }}</td> <td>{{ trans('spende.bic') }}</td>
<td>{{ $data['bankleitzahl'] }}</td> <td>{{ $data['bic'] }}</td>
</tr> </tr>
<tr> <tr>
<td>{{ trans('spende.betrag') }}</td> <td>{{ trans('spende.betrag') }}</td>
......
...@@ -19,29 +19,29 @@ ...@@ -19,29 +19,29 @@
<form id="donate" method="POST"> <form id="donate" method="POST">
<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 donation-form-group"> <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') !!}" value="{{ old('Name') }}" /> <input type="text" class="form-control" id="Name" required="" name="Name" placeholder="{!! trans('spende.lastschrift.3.placeholder') !!}" @if(isset($data['name'])) value="{{$data['name']}}" @endif />
</div> </div>
<div class="form-group donation-form-group"> <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" value="{{ old('email') }}"> <input type="email" class="form-control" id="email" name="email" placeholder="Email" @if(isset($data['email'])) value="{{$data['email']}}" @endif>
</div> </div>
<div class="form-group donation-form-group"> <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="iban" placeholder="IBAN" @if(isset($data['iban'])) value="{{$data['iban']}}" @endif>
</div> </div>
<div class="form-group donation-form-group"> <div class="form-group donation-form-group">
<label for="bic">{!! trans('spende.lastschrift.7') !!}</label> <label for="bic">{!! trans('spende.lastschrift.7') !!}</label>
<input type="text" class="form-control" id="bic" required="" name="Bankleitzahl" placeholder="BIC" value="{{ old('Bankleitzahl') }}"> <input type="text" class="form-control" id="bic" name="bic" placeholder="BIC" @if(isset($data['bic'])) value="{{$data['bic']}}" @endif>
</div> </div>
<div class="form-group donation-form-group"> <div class="form-group donation-form-group">
<label for="value">{!! trans('spende.lastschrift.8.value')!!} </label> <label for="value">*{!! trans('spende.lastschrift.8.value')!!} </label>
<input type="number" class="form-control" id="value" required="" name="Betrag" placeholder="{!! trans('spende.lastschrift.8.value.placeholder') !!}" value="{{ old('Bankleitzahl') }}"> <input type="number" class="form-control" id="value" required="" name="Betrag" min="1" step="0.01" placeholder="{!! trans('spende.lastschrift.8.value.placeholder') !!}" @if(isset($data['betrag'])) value="{{$data['betrag']}}" @endif>
</div> </div>
<div class="form-group donation-form-group"> <div class="form-group donation-form-group">
<label for="msg">{!! trans('spende.lastschrift.8.message')!!}</label> <label for="msg">{!! trans('spende.lastschrift.8.message')!!}</label>
<p>{!! trans('spende.bankinfo.3')!!}</p> <p>{!! trans('spende.bankinfo.3')!!}</p>
<textarea class="form-control" id="msg" name="Nachricht" placeholder="{!! trans('spende.lastschrift.8.message.placeholder') !!}">{{ old('Nachricht') }}</textarea> <textarea class="form-control" id="msg" name="Nachricht" placeholder="{!! trans('spende.lastschrift.8.message.placeholder') !!}">@if(isset($data['nachricht'])){{$data['nachricht']}}@endif</textarea>
</div> </div>
<button type="submit" form="donate" class="btn btn-default">{!! trans('spende.lastschrift.9') !!}</button> <button type="submit" form="donate" class="btn btn-default">{!! trans('spende.lastschrift.9') !!}</button>
</form> </form>
......
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