Started work on User Edit Form

This commit is contained in:
TorstenS 2020-09-17 09:50:11 +02:00
parent d13e5f4df0
commit 4c2630696c
6 changed files with 133 additions and 92 deletions

View file

@ -45,9 +45,10 @@ class UserController extends Controller
* @param \App\User $user * @param \App\User $user
* @return \Illuminate\Http\Response * @return \Illuminate\Http\Response
*/ */
public function show(User $user) public function show($user_id)
{ {
// $user=User::find($user_id);
return view('member_show',compact('user'));
} }
/** /**

View file

@ -4597,7 +4597,7 @@ readers do not read off random characters that represent icons */
--white: #fff; --white: #fff;
--gray: #6c757d; --gray: #6c757d;
--gray-dark: #343a40; --gray-dark: #343a40;
--primary: #000; --primary: #3490dc;
--secondary: #6c757d; --secondary: #6c757d;
--success: #38c172; --success: #38c172;
--info: #6cb2eb; --info: #6cb2eb;
@ -4746,13 +4746,13 @@ sup {
} }
a { a {
color: #000; color: #3490dc;
text-decoration: none; text-decoration: none;
background-color: transparent; background-color: transparent;
} }
a:hover { a:hover {
color: black; color: #1d68a7;
text-decoration: underline; text-decoration: underline;
} }
@ -6404,23 +6404,23 @@ pre code {
.table-primary, .table-primary,
.table-primary > th, .table-primary > th,
.table-primary > td { .table-primary > td {
background-color: #b8b8b8; background-color: #c6e0f5;
} }
.table-primary th, .table-primary th,
.table-primary td, .table-primary td,
.table-primary thead th, .table-primary thead th,
.table-primary tbody + tbody { .table-primary tbody + tbody {
border-color: #7a7a7a; border-color: #95c5ed;
} }
.table-hover .table-primary:hover { .table-hover .table-primary:hover {
background-color: #ababab; background-color: #b0d4f1;
} }
.table-hover .table-primary:hover > td, .table-hover .table-primary:hover > td,
.table-hover .table-primary:hover > th { .table-hover .table-primary:hover > th {
background-color: #ababab; background-color: #b0d4f1;
} }
.table-secondary, .table-secondary,
@ -6726,9 +6726,9 @@ pre code {
.form-control:focus { .form-control:focus {
color: #495057; color: #495057;
background-color: #fff; background-color: #fff;
border-color: #404040; border-color: #a1cbef;
outline: 0; outline: 0;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.form-control::-moz-placeholder { .form-control::-moz-placeholder {
@ -7230,7 +7230,7 @@ textarea.form-control.is-invalid {
.btn:focus, .btn:focus,
.btn.focus { .btn.focus {
outline: 0; outline: 0;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.btn.disabled, .btn.disabled,
@ -7249,43 +7249,43 @@ fieldset:disabled a.btn {
.btn-primary { .btn-primary {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.btn-primary:hover { .btn-primary:hover {
color: #fff; color: #fff;
background-color: black; background-color: #227dc7;
border-color: black; border-color: #2176bd;
} }
.btn-primary:focus, .btn-primary:focus,
.btn-primary.focus { .btn-primary.focus {
color: #fff; color: #fff;
background-color: black; background-color: #227dc7;
border-color: black; border-color: #2176bd;
box-shadow: 0 0 0 0.2rem rgba(38, 38, 38, 0.5); box-shadow: 0 0 0 0.2rem rgba(82, 161, 225, 0.5);
} }
.btn-primary.disabled, .btn-primary.disabled,
.btn-primary:disabled { .btn-primary:disabled {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.btn-primary:not(:disabled):not(.disabled):active, .btn-primary:not(:disabled):not(.disabled):active,
.btn-primary:not(:disabled):not(.disabled).active, .btn-primary:not(:disabled):not(.disabled).active,
.show > .btn-primary.dropdown-toggle { .show > .btn-primary.dropdown-toggle {
color: #fff; color: #fff;
background-color: black; background-color: #2176bd;
border-color: black; border-color: #1f6fb2;
} }
.btn-primary:not(:disabled):not(.disabled):active:focus, .btn-primary:not(:disabled):not(.disabled):active:focus,
.btn-primary:not(:disabled):not(.disabled).active:focus, .btn-primary:not(:disabled):not(.disabled).active:focus,
.show > .btn-primary.dropdown-toggle:focus { .show > .btn-primary.dropdown-toggle:focus {
box-shadow: 0 0 0 0.2rem rgba(38, 38, 38, 0.5); box-shadow: 0 0 0 0.2rem rgba(82, 161, 225, 0.5);
} }
.btn-secondary { .btn-secondary {
@ -7576,24 +7576,24 @@ fieldset:disabled a.btn {
} }
.btn-outline-primary { .btn-outline-primary {
color: #000; color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.btn-outline-primary:hover { .btn-outline-primary:hover {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.btn-outline-primary:focus, .btn-outline-primary:focus,
.btn-outline-primary.focus { .btn-outline-primary.focus {
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.5); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.5);
} }
.btn-outline-primary.disabled, .btn-outline-primary.disabled,
.btn-outline-primary:disabled { .btn-outline-primary:disabled {
color: #000; color: #3490dc;
background-color: transparent; background-color: transparent;
} }
@ -7601,14 +7601,14 @@ fieldset:disabled a.btn {
.btn-outline-primary:not(:disabled):not(.disabled).active, .btn-outline-primary:not(:disabled):not(.disabled).active,
.show > .btn-outline-primary.dropdown-toggle { .show > .btn-outline-primary.dropdown-toggle {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.btn-outline-primary:not(:disabled):not(.disabled):active:focus, .btn-outline-primary:not(:disabled):not(.disabled):active:focus,
.btn-outline-primary:not(:disabled):not(.disabled).active:focus, .btn-outline-primary:not(:disabled):not(.disabled).active:focus,
.show > .btn-outline-primary.dropdown-toggle:focus { .show > .btn-outline-primary.dropdown-toggle:focus {
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.5); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.5);
} }
.btn-outline-secondary { .btn-outline-secondary {
@ -7865,12 +7865,12 @@ fieldset:disabled a.btn {
.btn-link { .btn-link {
font-weight: 400; font-weight: 400;
color: #000; color: #3490dc;
text-decoration: none; text-decoration: none;
} }
.btn-link:hover { .btn-link:hover {
color: black; color: #1d68a7;
text-decoration: underline; text-decoration: underline;
} }
@ -8176,7 +8176,7 @@ input[type=button].btn-block {
.dropdown-item:active { .dropdown-item:active {
color: #fff; color: #fff;
text-decoration: none; text-decoration: none;
background-color: #000; background-color: #3490dc;
} }
.dropdown-item.disabled, .dropdown-item.disabled,
@ -8539,22 +8539,22 @@ input[type=button].btn-block {
.custom-control-input:checked ~ .custom-control-label::before { .custom-control-input:checked ~ .custom-control-label::before {
color: #fff; color: #fff;
border-color: #000; border-color: #3490dc;
background-color: #000; background-color: #3490dc;
} }
.custom-control-input:focus ~ .custom-control-label::before { .custom-control-input:focus ~ .custom-control-label::before {
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-control-input:focus:not(:checked) ~ .custom-control-label::before { .custom-control-input:focus:not(:checked) ~ .custom-control-label::before {
border-color: #404040; border-color: #a1cbef;
} }
.custom-control-input:not(:disabled):active ~ .custom-control-label::before { .custom-control-input:not(:disabled):active ~ .custom-control-label::before {
color: #fff; color: #fff;
background-color: #595959; background-color: #cce3f6;
border-color: #595959; border-color: #cce3f6;
} }
.custom-control-input[disabled] ~ .custom-control-label, .custom-control-input[disabled] ~ .custom-control-label,
@ -8606,8 +8606,8 @@ input[type=button].btn-block {
} }
.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::before { .custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::before {
border-color: #000; border-color: #3490dc;
background-color: #000; background-color: #3490dc;
} }
.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::after { .custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::after {
@ -8615,11 +8615,11 @@ input[type=button].btn-block {
} }
.custom-checkbox .custom-control-input:disabled:checked ~ .custom-control-label::before { .custom-checkbox .custom-control-input:disabled:checked ~ .custom-control-label::before {
background-color: rgba(0, 0, 0, 0.5); background-color: rgba(52, 144, 220, 0.5);
} }
.custom-checkbox .custom-control-input:disabled:indeterminate ~ .custom-control-label::before { .custom-checkbox .custom-control-input:disabled:indeterminate ~ .custom-control-label::before {
background-color: rgba(0, 0, 0, 0.5); background-color: rgba(52, 144, 220, 0.5);
} }
.custom-radio .custom-control-label::before { .custom-radio .custom-control-label::before {
@ -8631,7 +8631,7 @@ input[type=button].btn-block {
} }
.custom-radio .custom-control-input:disabled:checked ~ .custom-control-label::before { .custom-radio .custom-control-input:disabled:checked ~ .custom-control-label::before {
background-color: rgba(0, 0, 0, 0.5); background-color: rgba(52, 144, 220, 0.5);
} }
.custom-switch { .custom-switch {
@ -8667,7 +8667,7 @@ input[type=button].btn-block {
} }
.custom-switch .custom-control-input:disabled:checked ~ .custom-control-label::before { .custom-switch .custom-control-input:disabled:checked ~ .custom-control-label::before {
background-color: rgba(0, 0, 0, 0.5); background-color: rgba(52, 144, 220, 0.5);
} }
.custom-select { .custom-select {
@ -8689,9 +8689,9 @@ input[type=button].btn-block {
} }
.custom-select:focus { .custom-select:focus {
border-color: #404040; border-color: #a1cbef;
outline: 0; outline: 0;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-select:focus::-ms-value { .custom-select:focus::-ms-value {
@ -8754,8 +8754,8 @@ input[type=button].btn-block {
} }
.custom-file-input:focus ~ .custom-file-label { .custom-file-input:focus ~ .custom-file-label {
border-color: #404040; border-color: #a1cbef;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-file-input[disabled] ~ .custom-file-label, .custom-file-input[disabled] ~ .custom-file-label,
@ -8819,15 +8819,15 @@ input[type=button].btn-block {
} }
.custom-range:focus::-webkit-slider-thumb { .custom-range:focus::-webkit-slider-thumb {
box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-range:focus::-moz-range-thumb { .custom-range:focus::-moz-range-thumb {
box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-range:focus::-ms-thumb { .custom-range:focus::-ms-thumb {
box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 1px #f8fafc, 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.custom-range::-moz-focus-outer { .custom-range::-moz-focus-outer {
@ -8838,7 +8838,7 @@ input[type=button].btn-block {
width: 1rem; width: 1rem;
height: 1rem; height: 1rem;
margin-top: -0.25rem; margin-top: -0.25rem;
background-color: #000; background-color: #3490dc;
border: 0; border: 0;
border-radius: 1rem; border-radius: 1rem;
-webkit-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; -webkit-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
@ -8855,7 +8855,7 @@ input[type=button].btn-block {
} }
.custom-range::-webkit-slider-thumb:active { .custom-range::-webkit-slider-thumb:active {
background-color: #595959; background-color: #cce3f6;
} }
.custom-range::-webkit-slider-runnable-track { .custom-range::-webkit-slider-runnable-track {
@ -8871,7 +8871,7 @@ input[type=button].btn-block {
.custom-range::-moz-range-thumb { .custom-range::-moz-range-thumb {
width: 1rem; width: 1rem;
height: 1rem; height: 1rem;
background-color: #000; background-color: #3490dc;
border: 0; border: 0;
border-radius: 1rem; border-radius: 1rem;
-moz-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; -moz-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
@ -8888,7 +8888,7 @@ input[type=button].btn-block {
} }
.custom-range::-moz-range-thumb:active { .custom-range::-moz-range-thumb:active {
background-color: #595959; background-color: #cce3f6;
} }
.custom-range::-moz-range-track { .custom-range::-moz-range-track {
@ -8907,7 +8907,7 @@ input[type=button].btn-block {
margin-top: 0; margin-top: 0;
margin-right: 0.2rem; margin-right: 0.2rem;
margin-left: 0.2rem; margin-left: 0.2rem;
background-color: #000; background-color: #3490dc;
border: 0; border: 0;
border-radius: 1rem; border-radius: 1rem;
-ms-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; -ms-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
@ -8923,7 +8923,7 @@ input[type=button].btn-block {
} }
.custom-range::-ms-thumb:active { .custom-range::-ms-thumb:active {
background-color: #595959; background-color: #cce3f6;
} }
.custom-range::-ms-track { .custom-range::-ms-track {
@ -9050,7 +9050,7 @@ input[type=button].btn-block {
.nav-pills .nav-link.active, .nav-pills .nav-link.active,
.nav-pills .show > .nav-link { .nav-pills .show > .nav-link {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
} }
.nav-fill > .nav-link, .nav-fill > .nav-link,
@ -9805,14 +9805,14 @@ input[type=button].btn-block {
padding: 0.5rem 0.75rem; padding: 0.5rem 0.75rem;
margin-left: -1px; margin-left: -1px;
line-height: 1.25; line-height: 1.25;
color: #000; color: #3490dc;
background-color: #fff; background-color: #fff;
border: 1px solid #dee2e6; border: 1px solid #dee2e6;
} }
.page-link:hover { .page-link:hover {
z-index: 2; z-index: 2;
color: black; color: #1d68a7;
text-decoration: none; text-decoration: none;
background-color: #e9ecef; background-color: #e9ecef;
border-color: #dee2e6; border-color: #dee2e6;
@ -9821,7 +9821,7 @@ input[type=button].btn-block {
.page-link:focus { .page-link:focus {
z-index: 3; z-index: 3;
outline: 0; outline: 0;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.25);
} }
.page-item:first-child .page-link { .page-item:first-child .page-link {
@ -9838,8 +9838,8 @@ input[type=button].btn-block {
.page-item.active .page-link { .page-item.active .page-link {
z-index: 3; z-index: 3;
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.page-item.disabled .page-link { .page-item.disabled .page-link {
@ -9923,19 +9923,19 @@ a.badge:focus {
.badge-primary { .badge-primary {
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
} }
a.badge-primary:hover, a.badge-primary:hover,
a.badge-primary:focus { a.badge-primary:focus {
color: #fff; color: #fff;
background-color: black; background-color: #2176bd;
} }
a.badge-primary:focus, a.badge-primary:focus,
a.badge-primary.focus { a.badge-primary.focus {
outline: 0; outline: 0;
box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.5); box-shadow: 0 0 0 0.2rem rgba(52, 144, 220, 0.5);
} }
.badge-secondary { .badge-secondary {
@ -10105,17 +10105,17 @@ a.badge-dark.focus {
} }
.alert-primary { .alert-primary {
color: black; color: #1b4b72;
background-color: #cccccc; background-color: #d6e9f8;
border-color: #b8b8b8; border-color: #c6e0f5;
} }
.alert-primary hr { .alert-primary hr {
border-top-color: #ababab; border-top-color: #b0d4f1;
} }
.alert-primary .alert-link { .alert-primary .alert-link {
color: black; color: #113049;
} }
.alert-secondary { .alert-secondary {
@ -10254,7 +10254,7 @@ a.badge-dark.focus {
color: #fff; color: #fff;
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
background-color: #000; background-color: #3490dc;
transition: width 0.6s ease; transition: width 0.6s ease;
} }
@ -10345,8 +10345,8 @@ a.badge-dark.focus {
.list-group-item.active { .list-group-item.active {
z-index: 2; z-index: 2;
color: #fff; color: #fff;
background-color: #000; background-color: #3490dc;
border-color: #000; border-color: #3490dc;
} }
.list-group-item + .list-group-item { .list-group-item + .list-group-item {
@ -10519,20 +10519,20 @@ a.badge-dark.focus {
} }
.list-group-item-primary { .list-group-item-primary {
color: black; color: #1b4b72;
background-color: #b8b8b8; background-color: #c6e0f5;
} }
.list-group-item-primary.list-group-item-action:hover, .list-group-item-primary.list-group-item-action:hover,
.list-group-item-primary.list-group-item-action:focus { .list-group-item-primary.list-group-item-action:focus {
color: black; color: #1b4b72;
background-color: #ababab; background-color: #b0d4f1;
} }
.list-group-item-primary.list-group-item-action.active { .list-group-item-primary.list-group-item-action.active {
color: #fff; color: #fff;
background-color: black; background-color: #1b4b72;
border-color: black; border-color: #1b4b72;
} }
.list-group-item-secondary { .list-group-item-secondary {
@ -11533,14 +11533,14 @@ a.close.disabled {
} }
.bg-primary { .bg-primary {
background-color: #000 !important; background-color: #3490dc !important;
} }
a.bg-primary:hover, a.bg-primary:hover,
a.bg-primary:focus, a.bg-primary:focus,
button.bg-primary:hover, button.bg-primary:hover,
button.bg-primary:focus { button.bg-primary:focus {
background-color: black !important; background-color: #2176bd !important;
} }
.bg-secondary { .bg-secondary {
@ -11669,7 +11669,7 @@ button.bg-dark:focus {
} }
.border-primary { .border-primary {
border-color: #000 !important; border-color: #3490dc !important;
} }
.border-secondary { .border-secondary {
@ -15267,12 +15267,12 @@ button.bg-dark:focus {
} }
.text-primary { .text-primary {
color: #000 !important; color: #3490dc !important;
} }
a.text-primary:hover, a.text-primary:hover,
a.text-primary:focus { a.text-primary:focus {
color: black !important; color: #1d68a7 !important;
} }
.text-secondary { .text-secondary {

View file

@ -1,4 +1,4 @@
$theme-colors: ( $theme-colors: (
"primary": #000, /*"primary": #000, */
"danger": #ff4136 "danger": #ff4136
); );

View file

@ -0,0 +1,38 @@
@extends('layouts.app')
@section('content')
<div class="container text-center text-light mt-5">
<h1 class="text-center">{{$user->name}}</h1>
<form style="background-color: #fff;" class="text-dark" method="POST" action="/store_user">
{{ csrf_field() }}
<div class="form-group" style="display:flex;">
<label class="ml-2 mt-4" style="width:150px; text-align:left;" for="name"><h4>Vorname:</h4></label>
<input class="mt-3 mr-2 form-control" type="text" id="name" style="font-size:20px;" name="firstname" value="{{ $user->name }}"required>
</div>
<div class="form-group" style="display:flex;">
<label class="ml-2 mt-4" style="width:150px; text-align:left;" for="name" ><h4>Nachname:</h4></label>
<input type="text" class="mt-3 mr-2 form-control" id="lastname" style="font-size:20px;" name="lastname" required>
</div>
<div class="dropdown mb-2">
<button class="btn btn-secondary dropdown-toggle bg-primary" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{{$user->role}}
</button>
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
<a class="dropdown-item" href="#">GUEST</a>
<a class="dropdown-item" href="#">MEMBER</a>
<a class="dropdown-item" href="#">ADMIN</a>
</div>
</div>
<div class="form-group text-light">
<button type="submit" class="btn btn-primary mb-2">Speichern</button>
</div>
</form>
</div>
@endsection

View file

@ -8,7 +8,7 @@
.<ul class="list-group offset-3 col-6"> .<ul class="list-group offset-3 col-6">
@foreach($users as $user) @foreach($users as $user)
<li class="list-group-item d-flex justify-content-between align-items-center"> <li class="list-group-item d-flex justify-content-between align-items-center">
{{$user->name}} {{$user->name}},{{$user->id}}
@if($user->role=='ADMIN') @if($user->role=='ADMIN')
<span class="badge badge-danger badge-pill">Admin</span> <span class="badge badge-danger badge-pill">Admin</span>
@elseif($user->role=='MEMBER') @elseif($user->role=='MEMBER')

View file

@ -20,9 +20,11 @@ Route::get('/', function () {
Route::get('/activities', function () { return view('activities'); }); Route::get('/activities', function () { return view('activities'); });
Route::get('/become_member', function () { return view('become_member'); }); Route::get('/become_member', function () { return view('become_member'); });
Route::get('/meetings', function () { return view('meetings'); }); Route::get('/meetings', function () { return view('meetings'); });
Route::get('/memberlist','UserController@index');
Route::get('/tourplan', function () { return view('tourplan'); }); Route::get('/tourplan', function () { return view('tourplan'); });
Route::get('/memberlist','UserController@index');
Route::get('/member/{user_id}','UserController@show');
Auth::routes(); Auth::routes();
Route::get('/home', 'HomeController@index')->name('home'); Route::get('/home', 'HomeController@index')->name('home');