Merge branch 'master' of git://github.com/Chill-project/Main

This commit is contained in:
Marc Ducobu
2014-11-25 15:53:05 +01:00
15 changed files with 355 additions and 13 deletions

View File

@@ -28,6 +28,10 @@ chill_main_admin_central:
order: 20
label: Admin Menu
icons: [gears]
chill_main_search:
pattern: /{_locale}/person/search
defaults: { _controller: ChillMainBundle:Search:search }
login:
path: /login

View File

@@ -54,3 +54,7 @@ services:
- "@request_stack"
tags:
- { name: form.type, alias: select2_chill_country }
chill.main.search_provider:
class: Chill\MainBundle\Search\SearchProvider

View File

@@ -1,4 +1,5 @@
Search a person: Rechercher une personne
Search: Rechercher
'Search persons, ...': 'Recherche des personnes, ...'
Person name: Nom / Prénom de la personne
Login: Connexion
Logout: Se déconnecter

View File

@@ -35,7 +35,7 @@
<input type="password" name="_password" />
<input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}" />
<br/>
<button type="submit">{{ 'Login'|trans }}</button>
<button type="submit" name="login">{{ 'Login'|trans }}</button>
</form>

View File

@@ -0,0 +1,25 @@
{#
* Copyright (C) 2014, Champs Libres Cooperative SCRLFS, <http://www.champs-libres.coop>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
#}
{% extends "ChillMainBundle::layout.html.twig" %}
{% block content %}
{% for result in results %}
{{ result|raw }}
{% endfor %}
{% endblock %}

View File

@@ -32,8 +32,8 @@
</ul>
</div>
<div class="grid-4 navigation-search">
<form action="{{ path('chill_person_search') }}" method="get">
<input name="q" type="search" placeholder="{{ 'Search a person'|trans }}" />
<form action="{{ path('chill_main_search') }}" method="get">
<input name="q" type="search" placeholder="{{ 'Search'|trans }}" />
<button type="submit" class="sc-button white border"><i class="fa fa-search"></i></button>
</form>
</div>
@@ -98,12 +98,12 @@
{% block content %}
<div class="container">
<div class="grid-8 centered">
<h2>{{ 'Search a person'|trans }}</h2>
<h2>{{ 'Search'|trans }}</h2>
<form action="{{ path('chill_person_search') }}" method="get">
<input name="q" type="search" placeholder="{{ 'Person name'|trans }}" />
<form action="{{ path('chill_main_search') }}" method="get">
<input name="q" type="search" placeholder="{{ 'Search persons, ...'|trans }}" />
<center>
<button type="submit" class="sc-button orange"><i class="fa fa-search"></i> {{ 'Search a person'|trans }}</button>
<button type="submit" class="sc-button orange"><i class="fa fa-search"></i> {{ 'Search'|trans }}</button>
</center>
</form>
</div>