recommit
This commit is contained in:
commit
d7002df737
3 changed files with 58 additions and 35 deletions
|
@ -36,4 +36,5 @@ security:
|
|||
# Note: Only the *first* access control that matches will be used
|
||||
access_control:
|
||||
# - { path: ^/admin, roles: ROLE_ADMIN }
|
||||
- { path: ^/admin, roles: ROLE_ADMIN }
|
||||
- { path: ^(?!/(login|register|reset-password)), roles: ROLE_USER }
|
|
@ -3,7 +3,40 @@
|
|||
{% block title %}User{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<div class="mb-3">
|
||||
<h1>Hello {{ user.username }}!</p>
|
||||
</div>
|
||||
{% for message in app.flashes('success') %}
|
||||
<div class="alert alert-success" role="alert">
|
||||
{{ message }}
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
<div class="mb-3">
|
||||
<h1>Hello {{ user.username }}!</p>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<form method="post">
|
||||
<h3 class="mb-3 font-weight-normal">Change your user data</h3>
|
||||
<div class="mb-3">
|
||||
<label for="inputEmail" class="form-label">Email address</label>
|
||||
<input name="email" type="email" class="form-control" id="inputEmail" aria-describedby="emailHelp" placeholder="{{ app.user.email }}" required>
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="inputPassword">Password</label>
|
||||
<input type="password" name="password" id="inputPassword" class="form-control" required>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="_csrf_token"
|
||||
value="{{ csrf_token('authenticate') }}"
|
||||
>
|
||||
|
||||
<button class="btn btn-lg btn-primary" type="submit">
|
||||
Save
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<h3 class="mb-3">Delete Account</h3>
|
||||
<button class="btn btn-danger">Delete Account</button>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
|
|
@ -16,37 +16,26 @@
|
|||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
</head>
|
||||
<body>
|
||||
<nav class="navbar navbar-expand-lg navbar-light bg-light">
|
||||
<a class="navbar-brand" href="{{ path('homepage') }}"><i class="fas fa-seedling"></i>Plantex</a>
|
||||
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
<nav class="navbar navbar-expand-lg navbar-light bg-light">
|
||||
<a class="navbar-brand" href="#"><i class="fas fa-seedling"></i>Plantex</a>
|
||||
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href=" {{ path('homepage') }} ">Listings</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="{{ path('user_page') }}">User</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="nav-link" href="{{ path('new_listing') }}"><i class="fas fa-plus-square"></i> New</a>
|
||||
</li>
|
||||
</ul>
|
||||
<form class="form-inline my-2 my-lg-0">
|
||||
<div class="dropdown-menu" aria-labelledby="navbarDropdown">
|
||||
<a class="dropdown-item" href="#">Action</a>
|
||||
<a class="dropdown-item" href="#">Another action</a>
|
||||
<div class="dropdown-divider"></div>
|
||||
<a class="dropdown-item" href="#">Something else here</a>
|
||||
</div>
|
||||
<input class="form-control mr-sm-2" type="search" placeholder="Search" aria-label="Search">
|
||||
<button class="btn btn-outline-success my-2 my-sm-0" type="submit">Search</button>
|
||||
</form>
|
||||
</div>
|
||||
</nav>
|
||||
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href=" {{ path('homepage') }} ">Listings</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="{{ path('user_page') }}">User</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="nav-link" href="{{ path('new_listing') }}">New Offer</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container listings-container">
|
||||
{% block body %}{% endblock %}
|
||||
|
|
Reference in a new issue