diff options
| author | Robert | 2017-05-03 16:23:57 +0200 |
|---|---|---|
| committer | Robert | 2017-05-03 16:23:57 +0200 |
| commit | 9c1ce95c49b7410bd5e28ec13f9a8ed86b75dbc8 (patch) | |
| tree | a6c96d64d09b023b930d6c20318e3ed1581c7b29 | |
| parent | b84f888ca9bd5b708def0c4cd2f34f3a94b0251f (diff) | |
| parent | 434ebbc37848384b28c0aedc3ca90cd56e34e08e (diff) | |
| download | chouette-core-9c1ce95c49b7410bd5e28ec13f9a8ed86b75dbc8.tar.bz2 | |
Merge branch 'master' of github.com:af83/stif-boiv
7 files changed, 55 insertions, 99 deletions
diff --git a/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/CreateModal.js b/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/CreateModal.js index 3d2251753..1e121b473 100644 --- a/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/CreateModal.js +++ b/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/CreateModal.js @@ -69,7 +69,7 @@ class CreateModal extends Component { </div> <div className='col-lg-6 col-md-6 col-sm-6 col-xs-12'> <div className='form-group'> - <label className='control-label is-required'>ID de la mission</label> + <label className='control-label is-required'>Nom public de la mission</label> <MissionSelect2 onSelect2JourneyPattern={this.props.onSelect2JourneyPattern} isFilter={false} diff --git a/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/EditVehicleJourney.js b/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/EditVehicleJourney.js index a0ef19ecd..3ccc8b4d8 100644 --- a/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/EditVehicleJourney.js +++ b/app/assets/javascripts/es6_browserified/vehicle_journeys/components/tools/EditVehicleJourney.js @@ -54,14 +54,13 @@ class EditVehicleJourney extends Component { <div className='row'> <div className='col-lg-6 col-md-6 col-sm-6 col-xs-12'> <div className='form-group'> - <label className='control-label is-required'>Intitulé de la course</label> + <label className='control-label'>Nom de la course</label> <input type='text' ref='published_journey_name' className='form-control' defaultValue={this.props.modal.modalProps.vehicleJourney.published_journey_name} onKeyDown={(e) => actions.resetValidation(e.currentTarget)} - required /> </div> </div> @@ -81,14 +80,13 @@ class EditVehicleJourney extends Component { <div className='row'> <div className='col-lg-6 col-md-6 col-sm-6 col-xs-12'> <div className='form-group'> - <label className='control-label is-required'>Numéro de train</label> + <label className='control-label'>Numéro de train</label> <input type='text' ref='published_journey_identifier' className='form-control' defaultValue={this.props.modal.modalProps.vehicleJourney.published_journey_identifier} onKeyDown={(e) => actions.resetValidation(e.currentTarget)} - required /> </div> </div> diff --git a/app/views/devise/sessions/new.html.slim b/app/views/devise/sessions/new.html.slim index 5f4fec741..0ed17e24a 100644 --- a/app/views/devise/sessions/new.html.slim +++ b/app/views/devise/sessions/new.html.slim @@ -1,34 +1,36 @@ -#sessions_new.row - = render 'devise/shared/intro' - - .col-md-4.login - .panel.panel-default - .panel-body - = simple_form_for(resource, :as => resource_name, :url => session_path(resource_name), html: { :class => 'form-horizontal session_new' } ) do |form| - - = form.input :email, :label => false, input_html: { :class => "form-control" } - - .row - .col-md-6 - = form.input :password, :as => :password, :label => false, input_html: { :class => "form-control" } - - .col-md-6 - = form.button :submit, t("devise.sessions.new.commit"), :class => "btn-primary" - - .row.options - .col-md-6 - - if devise_mapping.rememberable? - = form.input :remember_me, :as => :boolean if devise_mapping.rememberable? - - .col-md-6.new_password - = link_to t("devise.links.new_password"), new_password_path(resource_name) - - / FIXME ref #819 - - if false - - if devise_mapping.confirmable? && controller_name != 'confirmations' - br - = link_to t("devise.links.new_confirmation"), new_confirmation_path(resource_name) - - / FIXME ref #819 - - if false - = render partial: 'devise/shared/form_registration', locals: { organisation: (resource.organisation || Organisation.new) } +.page_content#devise + .container-fluid + #sessions_new.row + = render 'devise/shared/intro' + + .col-md-4.login + .panel.panel-default + .panel-body + = simple_form_for(resource, :as => resource_name, :url => session_path(resource_name), html: { :class => 'form-horizontal session_new' } ) do |form| + + = form.input :email, :label => false, input_html: { :class => "form-control" } + + .row + .col-md-6 + = form.input :password, :as => :password, :label => false, input_html: { :class => "form-control" } + + .col-md-6 + = form.button :submit, t("devise.sessions.new.commit"), :class => "btn-primary" + + .row.options + .col-md-6 + - if devise_mapping.rememberable? + = form.input :remember_me, :as => :boolean if devise_mapping.rememberable? + + .col-md-6.new_password + = link_to t("devise.links.new_password"), new_password_path(resource_name) + + / FIXME ref #819 + - if false + - if devise_mapping.confirmable? && controller_name != 'confirmations' + br + = link_to t("devise.links.new_confirmation"), new_confirmation_path(resource_name) + + / FIXME ref #819 + - if false + = render partial: 'devise/shared/form_registration', locals: { organisation: (resource.organisation || Organisation.new) } diff --git a/app/views/layouts/devise.html.slim b/app/views/layouts/devise.html.slim deleted file mode 100644 index e72748d10..000000000 --- a/app/views/layouts/devise.html.slim +++ /dev/null @@ -1,41 +0,0 @@ -doctype html -html lang=I18n.locale - head - meta charset="utf-8" - meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" - meta content="IE=EmulateIE7" http-equiv="X-UA-Compatible" - - title = "STIF BOIV - #{title}" - - = favicon_link_tag "logo_chouette_small.ico" - = favicon_link_tag 'logo_chouette_small.png', rel: 'apple-touch-icon', type: 'image/png' - - = stylesheet_link_tag :application - = javascript_include_tag :application - - - if defined?(@map) - = javascript_include_tag "http://maps.google.com/maps/api/js?v=3.2&sensor=false" - = javascript_include_tag "http://openlayers.org/api/OpenLayers.js" - - / Todo from @jpl: check if it works... - <script type="text/JavaScript"> - OpenLayers.ImgPath = polymorphic_path_patch('/assets/openlayers/') - </script> - - = analytics_init if Rails.env.production? - = csrf_meta_tag - - body#devise - #header - = render partial: "shared/header" - - .front_bg - #devise_middle.container - .row - div class=("#{content_for?(:sidebar) ? 'col-md-9' : 'col-md-12'}") - #workspace class=("#{controller_name} #{action_name}") - = render partial: "shared/flash_messages", flash: flash - = render partial: "shared/breadcrumb" - = yield - #footer - = render partial: "shared/footer"
\ No newline at end of file diff --git a/app/views/layouts/navigation/_main_nav_top.html.slim b/app/views/layouts/navigation/_main_nav_top.html.slim index 095fbca0b..4cdd5f053 100644 --- a/app/views/layouts/navigation/_main_nav_top.html.slim +++ b/app/views/layouts/navigation/_main_nav_top.html.slim @@ -5,17 +5,18 @@ .menu-item = render 'layouts/navigation/breadcrumb' - .menu-item-group.pull-right - = link_to '#', class: 'menu-item', data: { panel: 'toggle', target: '#operations_panel' }, title: 'Opérations' do - span.fa.fa-lg.fa-tasks + - if user_signed_in? + .menu-item-group.pull-right + = link_to '#', class: 'menu-item', data: { panel: 'toggle', target: '#operations_panel' }, title: 'Opérations' do + span.fa.fa-lg.fa-tasks - = link_to '#', class: 'menu-item', data: { panel: 'toggle', target: '#profile_panel' }, title: 'Profil' do - span = current_user.username - span.fa.fa-lg.fa-user + = link_to '#', class: 'menu-item', data: { panel: 'toggle', target: '#profile_panel' }, title: 'Profil' do + span = current_user.username + span.fa.fa-lg.fa-user - = link_to destroy_user_session_path, method: :delete, class: 'menu-item', title: 'Se déconnecter' do - span.fa.fa-lg.fa-sign-out + = link_to destroy_user_session_path, method: :delete, class: 'menu-item', title: 'Se déconnecter' do + span.fa.fa-lg.fa-sign-out = render 'layouts/navigation/nav_panel_operations' - = render 'layouts/navigation/nav_panel_profile' + = render 'layouts/navigation/nav_panel_profile' if user_signed_in? diff --git a/config/initializers/devise.rb b/config/initializers/devise.rb index 057d4b215..ccce16f5f 100644 --- a/config/initializers/devise.rb +++ b/config/initializers/devise.rb @@ -327,12 +327,3 @@ Devise.setup do |config| # logger: Rails.logger # } end - -Rails.application.config.to_prepare do - Devise::SessionsController.layout "devise" - Devise::RegistrationsController.layout proc{ |controller| ( action_name == "edit" || action_name == "update") ? "application" : "devise" } - Devise::InvitationsController.layout proc{ |controller| ( action_name == "new") ? "application" : "devise" } - Devise::ConfirmationsController.layout "devise" - Devise::UnlocksController.layout "devise" - Devise::PasswordsController.layout "devise" -end diff --git a/lib/tasks/ci.rake b/lib/tasks/ci.rake index 926d10aca..658e4e04e 100644 --- a/lib/tasks/ci.rake +++ b/lib/tasks/ci.rake @@ -27,6 +27,11 @@ namespace :ci do sh "bundle exec bundle-audit check --update" end + task :teaspoon do + sh "RAILS_ENV=test bundle exec rake teaspoon" + end + + desc "Deploy after CI" task :deploy do sh "cap #{deploy_env} deploy:migrations" @@ -39,4 +44,4 @@ namespace :ci do end desc "Run continuous integration tasks (spec, ...)" -task :ci => ["ci:setup", "spec", "teaspoon", "cucumber", "ci:check_security", "ci:deploy", "ci:clean"] +task :ci => ["ci:setup", "spec", "ci:teaspoon", "cucumber", "ci:check_security", "ci:deploy", "ci:clean"] |
