From e8c0d439000bb5f9b593065b83ad0871e85186c3 Mon Sep 17 00:00:00 2001 From: pascal simon Date: Sun, 3 Jul 2016 20:55:51 +0200 Subject: [PATCH 1/8] fix clipboard js --- app/assets/javascripts/application.js.coffee | 5 ++--- app/assets/javascripts/modules/account.js.coffee | 2 +- .../modules/{helper.js.coffee => account_helper.js.coffee} | 5 +---- app/assets/javascripts/modules/search.js.coffee | 2 +- 4 files changed, 5 insertions(+), 9 deletions(-) rename app/assets/javascripts/modules/{helper.js.coffee => account_helper.js.coffee} (94%) diff --git a/app/assets/javascripts/application.js.coffee b/app/assets/javascripts/application.js.coffee index bef0e8e50..1b0736cbe 100644 --- a/app/assets/javascripts/application.js.coffee +++ b/app/assets/javascripts/application.js.coffee @@ -6,13 +6,12 @@ #= require jquery #= require jquery_ujs #= require jquery-ui +#= require clipboard.js #= require twitter/bootstrap #= require handlebars.runtime +#= require turbolinks #= require_tree ./modules #= require_tree ./templates -#= require turbolinks -#= require clipboard.js -#= require clipboard.min.js # scope for global functions diff --git a/app/assets/javascripts/modules/account.js.coffee b/app/assets/javascripts/modules/account.js.coffee index b53b52392..470a48b55 100644 --- a/app/assets/javascripts/modules/account.js.coffee +++ b/app/assets/javascripts/modules/account.js.coffee @@ -42,7 +42,7 @@ class app.Account showPassword(e) $(document).on 'click', '.clip_button', (e) -> - app.Helper.showCopyMessage(e, '.clip_button') + app.AccountHelper.showCopyMessage(e, '.clip_button') $(document).on 'click', '.result-username input', (e) -> $(this).select() diff --git a/app/assets/javascripts/modules/helper.js.coffee b/app/assets/javascripts/modules/account_helper.js.coffee similarity index 94% rename from app/assets/javascripts/modules/helper.js.coffee rename to app/assets/javascripts/modules/account_helper.js.coffee index 490d5a23a..231a117ad 100644 --- a/app/assets/javascripts/modules/helper.js.coffee +++ b/app/assets/javascripts/modules/account_helper.js.coffee @@ -1,6 +1,6 @@ app = window.App ||= {} -class app.Helper +class app.AccountHelper @showCopyMessage: (e, name) -> parent = $(e.target.closest(name)).parent() @@ -17,6 +17,3 @@ class app.Helper $(div).find($('.copied')).remove() return ), 2000 - - - new Helper diff --git a/app/assets/javascripts/modules/search.js.coffee b/app/assets/javascripts/modules/search.js.coffee index 49fa5ec75..65f9c37fb 100644 --- a/app/assets/javascripts/modules/search.js.coffee +++ b/app/assets/javascripts/modules/search.js.coffee @@ -66,6 +66,6 @@ class app.Search showPassword(e) $(document).on 'click', '.clip_button', (e) -> - app.Helper.showCopyMessage(e, '.clip_button') + app.AccountHelper.showCopyMessage(e, '.clip_button') new Search From 52ffbd900c40a71284db53c5b25b8e4105ff1afc Mon Sep 17 00:00:00 2001 From: Felix Ammann Date: Wed, 6 Jul 2016 15:55:19 +0200 Subject: [PATCH 2/8] Javascripts Test + add rake test:feature Task 16661 --- Gemfile | 2 + lib/tasks/features.rake | 13 +++++++ test/features/auto_logoff_feature_test.rb | 16 ++++++++ test/features/quicksearch_feature_test.rb | 38 +++++++++++++++++++ test/features/teammember_feature_test.rb | 20 ++++++++++ test/features/user_feature_test.rb | 16 ++++++++ .../feature_test/feature_helper_test.rb | 22 +++++++++++ 7 files changed, 127 insertions(+) create mode 100644 lib/tasks/features.rake create mode 100644 test/features/auto_logoff_feature_test.rb create mode 100644 test/features/quicksearch_feature_test.rb create mode 100644 test/features/teammember_feature_test.rb create mode 100644 test/features/user_feature_test.rb create mode 100644 test/support/feature_test/feature_helper_test.rb diff --git a/Gemfile b/Gemfile index de5de462c..5db313d53 100644 --- a/Gemfile +++ b/Gemfile @@ -21,6 +21,8 @@ gem 'less-rails' gem 'turbolinks' gem 'jquery-ui-rails' gem 'active_model_serializers', '0.10.0' +gem 'capybara' +gem 'capybara-webkit' group :development, :test do diff --git a/lib/tasks/features.rake b/lib/tasks/features.rake new file mode 100644 index 000000000..c1fa94f66 --- /dev/null +++ b/lib/tasks/features.rake @@ -0,0 +1,13 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. + +Rake::TestTask.new do |t| + t.libs = ["test"] + t.name = "test:features" + t.warning = false + t.test_files = FileList['test/features/*_test.rb'] +end diff --git a/test/features/auto_logoff_feature_test.rb b/test/features/auto_logoff_feature_test.rb new file mode 100644 index 000000000..d2297d9c7 --- /dev/null +++ b/test/features/auto_logoff_feature_test.rb @@ -0,0 +1,16 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. + +require 'test_helper' +class AutoLogoffFeatureTest < ActionController::TestCase + + test 'automatic auto-logoff after 300 seconds' do + + end + + +end diff --git a/test/features/quicksearch_feature_test.rb b/test/features/quicksearch_feature_test.rb new file mode 100644 index 000000000..dfa024949 --- /dev/null +++ b/test/features/quicksearch_feature_test.rb @@ -0,0 +1,38 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. + +require 'capybara/rails' +require 'test_helper' +class QuickSearchFeatureTest < ActionController::TestCase + include FeatureTest::FeatureHelper + include Capybara::DSL + + + test 'search with not available keyword does not show any results' do + Capybara.default_driver = :webkit + Capybara.javascript_driver = :webkit + login_as_user(:bob) + within('div.form-group') do + fill_in 'search_string', :with => 'lkj' + end + assert_not(page.has_css?('li.result')) + logout + end + + test 'after copy a username or password with the clipboad it shows a message' do + login_as_user(:bob) + + logout + + end + + test 'show password after clicking on password field' do + + end + + +end diff --git a/test/features/teammember_feature_test.rb b/test/features/teammember_feature_test.rb new file mode 100644 index 000000000..bf8094cff --- /dev/null +++ b/test/features/teammember_feature_test.rb @@ -0,0 +1,20 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. +require 'test_helper' +class TeammemberFeatureTest < ActionController::TestCase + + test 'render hbl to show all teammembers' do + + end + + test 'shows new added member' do + + + end + + +end diff --git a/test/features/user_feature_test.rb b/test/features/user_feature_test.rb new file mode 100644 index 000000000..f82bdaf8d --- /dev/null +++ b/test/features/user_feature_test.rb @@ -0,0 +1,16 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. + +require 'test_helper' +class UserFeatureTest < ActionController::TestCase + + test 'render hbl to show all teams where user is last teammember' do + + end + + +end diff --git a/test/support/feature_test/feature_helper_test.rb b/test/support/feature_test/feature_helper_test.rb new file mode 100644 index 000000000..15238446d --- /dev/null +++ b/test/support/feature_test/feature_helper_test.rb @@ -0,0 +1,22 @@ +# encoding: utf-8 + +# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of +# Cryptopus and licensed under the Affero General Public License version 3 or later. +# See the COPYING file at the top-level directory or at +# https://github.com/puzzle/cryptopus. +module FeatureTest + module FeatureHelper + def login_as_user(username, password = 'password') + visit('/en/login/login') + fill_in('username', :with => username) + fill_in('password', :with => password) + find('input[name="commit"]').click + visit('/en/search') + end + + def logout + visit('/en/login/login') + end + + end +end From 47170a9cf250202bd6caac51a5b986b738946edd Mon Sep 17 00:00:00 2001 From: Felix Ammann Date: Wed, 6 Jul 2016 16:29:31 +0200 Subject: [PATCH 3/8] add Gemfile.lock --- Gemfile.lock | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Gemfile.lock b/Gemfile.lock index 8c230c428..967e354e9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -40,6 +40,7 @@ GEM minitest (~> 5.1) thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) + addressable (2.4.0) arel (6.0.3) ast (2.2.0) binding_of_caller (0.7.2) @@ -58,6 +59,16 @@ GEM terminal-table (~> 1.4) breadcrumbs_on_rails (2.3.1) builder (3.2.2) + capybara (2.7.1) + addressable + mime-types (>= 1.16) + nokogiri (>= 1.3.3) + rack (>= 1.0.0) + rack-test (>= 0.5.4) + xpath (~> 2.0) + capybara-webkit (1.11.1) + capybara (>= 2.3.0, < 2.8.0) + json choice (0.2.0) chunky_png (1.3.5) clipboard (1.1.0) @@ -261,6 +272,8 @@ GEM execjs (>= 0.3.0) json (>= 1.8.0) unicode-display_width (0.3.1) + xpath (2.0.0) + nokogiri (~> 1.3) PLATFORMS ruby @@ -269,6 +282,8 @@ DEPENDENCIES active_model_serializers (= 0.10.0) brakeman breadcrumbs_on_rails + capybara + capybara-webkit clipboard compass-rails dynamic_form @@ -300,3 +315,6 @@ DEPENDENCIES turbolinks twitter-bootstrap-rails uglifier + +BUNDLED WITH + 1.12.5 From 3024a8aa3a412bf6d714f1d9d8f61d432547efc0 Mon Sep 17 00:00:00 2001 From: Felix Ammann Date: Wed, 6 Jul 2016 16:53:52 +0200 Subject: [PATCH 4/8] revert: Javascripts Test + add rake test:feature Task 16661 --- Gemfile | 2 - test/features/auto_logoff_feature_test.rb | 16 -------- test/features/quicksearch_feature_test.rb | 38 ------------------- test/features/teammember_feature_test.rb | 20 ---------- test/features/user_feature_test.rb | 16 -------- .../feature_test/feature_helper_test.rb | 22 ----------- 6 files changed, 114 deletions(-) delete mode 100644 test/features/auto_logoff_feature_test.rb delete mode 100644 test/features/quicksearch_feature_test.rb delete mode 100644 test/features/teammember_feature_test.rb delete mode 100644 test/features/user_feature_test.rb delete mode 100644 test/support/feature_test/feature_helper_test.rb diff --git a/Gemfile b/Gemfile index 5db313d53..de5de462c 100644 --- a/Gemfile +++ b/Gemfile @@ -21,8 +21,6 @@ gem 'less-rails' gem 'turbolinks' gem 'jquery-ui-rails' gem 'active_model_serializers', '0.10.0' -gem 'capybara' -gem 'capybara-webkit' group :development, :test do diff --git a/test/features/auto_logoff_feature_test.rb b/test/features/auto_logoff_feature_test.rb deleted file mode 100644 index d2297d9c7..000000000 --- a/test/features/auto_logoff_feature_test.rb +++ /dev/null @@ -1,16 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. - -require 'test_helper' -class AutoLogoffFeatureTest < ActionController::TestCase - - test 'automatic auto-logoff after 300 seconds' do - - end - - -end diff --git a/test/features/quicksearch_feature_test.rb b/test/features/quicksearch_feature_test.rb deleted file mode 100644 index dfa024949..000000000 --- a/test/features/quicksearch_feature_test.rb +++ /dev/null @@ -1,38 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. - -require 'capybara/rails' -require 'test_helper' -class QuickSearchFeatureTest < ActionController::TestCase - include FeatureTest::FeatureHelper - include Capybara::DSL - - - test 'search with not available keyword does not show any results' do - Capybara.default_driver = :webkit - Capybara.javascript_driver = :webkit - login_as_user(:bob) - within('div.form-group') do - fill_in 'search_string', :with => 'lkj' - end - assert_not(page.has_css?('li.result')) - logout - end - - test 'after copy a username or password with the clipboad it shows a message' do - login_as_user(:bob) - - logout - - end - - test 'show password after clicking on password field' do - - end - - -end diff --git a/test/features/teammember_feature_test.rb b/test/features/teammember_feature_test.rb deleted file mode 100644 index bf8094cff..000000000 --- a/test/features/teammember_feature_test.rb +++ /dev/null @@ -1,20 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. -require 'test_helper' -class TeammemberFeatureTest < ActionController::TestCase - - test 'render hbl to show all teammembers' do - - end - - test 'shows new added member' do - - - end - - -end diff --git a/test/features/user_feature_test.rb b/test/features/user_feature_test.rb deleted file mode 100644 index f82bdaf8d..000000000 --- a/test/features/user_feature_test.rb +++ /dev/null @@ -1,16 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. - -require 'test_helper' -class UserFeatureTest < ActionController::TestCase - - test 'render hbl to show all teams where user is last teammember' do - - end - - -end diff --git a/test/support/feature_test/feature_helper_test.rb b/test/support/feature_test/feature_helper_test.rb deleted file mode 100644 index 15238446d..000000000 --- a/test/support/feature_test/feature_helper_test.rb +++ /dev/null @@ -1,22 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. -module FeatureTest - module FeatureHelper - def login_as_user(username, password = 'password') - visit('/en/login/login') - fill_in('username', :with => username) - fill_in('password', :with => password) - find('input[name="commit"]').click - visit('/en/search') - end - - def logout - visit('/en/login/login') - end - - end -end From 7a058bd711d692ad2a0e5b08023bf72ed071cdb2 Mon Sep 17 00:00:00 2001 From: Felix Ammann Date: Wed, 6 Jul 2016 16:55:15 +0200 Subject: [PATCH 5/8] revert: Javascripts Test + add rake test:feature Task 16661 --- lib/tasks/features.rake | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 lib/tasks/features.rake diff --git a/lib/tasks/features.rake b/lib/tasks/features.rake deleted file mode 100644 index c1fa94f66..000000000 --- a/lib/tasks/features.rake +++ /dev/null @@ -1,13 +0,0 @@ -# encoding: utf-8 - -# Copyright (c) 2008-2016, Puzzle ITC GmbH. This file is part of -# Cryptopus and licensed under the Affero General Public License version 3 or later. -# See the COPYING file at the top-level directory or at -# https://github.com/puzzle/cryptopus. - -Rake::TestTask.new do |t| - t.libs = ["test"] - t.name = "test:features" - t.warning = false - t.test_files = FileList['test/features/*_test.rb'] -end From ba03d228db2fbc69bbfa497411140964e86181b0 Mon Sep 17 00:00:00 2001 From: Felix Ammann Date: Thu, 7 Jul 2016 12:09:45 +0200 Subject: [PATCH 6/8] rails upgrade to 4.2.6. #18626 --- Gemfile | 2 +- Gemfile.lock | 97 +++++++++++++++++++++++----------------------------- 2 files changed, 44 insertions(+), 55 deletions(-) diff --git a/Gemfile b/Gemfile index de5de462c..46a37d5d5 100644 --- a/Gemfile +++ b/Gemfile @@ -1,6 +1,6 @@ source 'http://rubygems.org' -gem 'rails', '4.2.5.1' +gem 'rails', '4.2.6' gem 'mysql2' gem 'sqlite3' diff --git a/Gemfile.lock b/Gemfile.lock index 967e354e9..68bff51d9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,21 +1,21 @@ GEM remote: http://rubygems.org/ specs: - actionmailer (4.2.5.1) - actionpack (= 4.2.5.1) - actionview (= 4.2.5.1) - activejob (= 4.2.5.1) + actionmailer (4.2.6) + actionpack (= 4.2.6) + actionview (= 4.2.6) + activejob (= 4.2.6) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 1.0, >= 1.0.5) - actionpack (4.2.5.1) - actionview (= 4.2.5.1) - activesupport (= 4.2.5.1) + actionpack (4.2.6) + actionview (= 4.2.6) + activesupport (= 4.2.6) rack (~> 1.6) rack-test (~> 0.6.2) rails-dom-testing (~> 1.0, >= 1.0.5) rails-html-sanitizer (~> 1.0, >= 1.0.2) - actionview (4.2.5.1) - activesupport (= 4.2.5.1) + actionview (4.2.6) + activesupport (= 4.2.6) builder (~> 3.1) erubis (~> 2.7.0) rails-dom-testing (~> 1.0, >= 1.0.5) @@ -24,23 +24,22 @@ GEM actionpack (>= 4.0) activemodel (>= 4.0) railties (>= 4.0) - activejob (4.2.5.1) - activesupport (= 4.2.5.1) + activejob (4.2.6) + activesupport (= 4.2.6) globalid (>= 0.3.0) - activemodel (4.2.5.1) - activesupport (= 4.2.5.1) + activemodel (4.2.6) + activesupport (= 4.2.6) builder (~> 3.1) - activerecord (4.2.5.1) - activemodel (= 4.2.5.1) - activesupport (= 4.2.5.1) + activerecord (4.2.6) + activemodel (= 4.2.6) + activesupport (= 4.2.6) arel (~> 6.0) - activesupport (4.2.5.1) + activesupport (4.2.6) i18n (~> 0.7) json (~> 1.7, >= 1.7.7) minitest (~> 5.1) thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) - addressable (2.4.0) arel (6.0.3) ast (2.2.0) binding_of_caller (0.7.2) @@ -59,16 +58,6 @@ GEM terminal-table (~> 1.4) breadcrumbs_on_rails (2.3.1) builder (3.2.2) - capybara (2.7.1) - addressable - mime-types (>= 1.16) - nokogiri (>= 1.3.3) - rack (>= 1.0.0) - rack-test (>= 0.5.4) - xpath (~> 2.0) - capybara-webkit (1.11.1) - capybara (>= 2.3.0, < 2.8.0) - json choice (0.2.0) chunky_png (1.3.5) clipboard (1.1.0) @@ -138,22 +127,26 @@ GEM libv8 (3.16.14.13) loofah (2.0.3) nokogiri (>= 1.5.9) - mail (2.6.3) - mime-types (>= 1.16, < 3) + mail (2.6.4) + mime-types (>= 1.16, < 4) metaclass (0.0.4) method_source (0.8.2) - mime-types (2.99.1) - mini_portile2 (2.0.0) - minitest (5.8.4) + mime-types (3.1) + mime-types-data (~> 3.2015) + mime-types-data (3.2016.0521) + mini_portile2 (2.1.0) + minitest (5.9.0) mocha (1.1.0) metaclass (~> 0.0.1) - multi_json (1.11.2) + multi_json (1.12.1) mysql2 (0.4.2) net-ldap (0.12.1) - nokogiri (1.6.7.2) - mini_portile2 (~> 2.0.0.rc2) + nokogiri (1.6.8) + mini_portile2 (~> 2.1.0) + pkg-config (~> 1.1.7) parser (2.3.0.2) ast (~> 2.2) + pkg-config (1.1.7) power_assert (0.2.6) powerpack (0.1.1) pry (0.10.3) @@ -166,16 +159,16 @@ GEM rack (1.6.4) rack-test (0.6.3) rack (>= 1.0) - rails (4.2.5.1) - actionmailer (= 4.2.5.1) - actionpack (= 4.2.5.1) - actionview (= 4.2.5.1) - activejob (= 4.2.5.1) - activemodel (= 4.2.5.1) - activerecord (= 4.2.5.1) - activesupport (= 4.2.5.1) + rails (4.2.6) + actionmailer (= 4.2.6) + actionpack (= 4.2.6) + actionview (= 4.2.6) + activejob (= 4.2.6) + activemodel (= 4.2.6) + activerecord (= 4.2.6) + activesupport (= 4.2.6) bundler (>= 1.3.0, < 2.0) - railties (= 4.2.5.1) + railties (= 4.2.6) sprockets-rails rails-deprecated_sanitizer (1.0.3) activesupport (>= 4.2.0.alpha) @@ -190,13 +183,13 @@ GEM ruby-graphviz (~> 1.2) rails-html-sanitizer (1.0.3) loofah (~> 2.0) - railties (4.2.5.1) - actionpack (= 4.2.5.1) - activesupport (= 4.2.5.1) + railties (4.2.6) + actionpack (= 4.2.6) + activesupport (= 4.2.6) rake (>= 0.8.7) thor (>= 0.18.1, < 2.0) rainbow (2.1.0) - rake (10.5.0) + rake (11.2.2) rb-fsevent (0.9.6) rb-inotify (0.9.5) ffi (>= 0.5.0) @@ -272,8 +265,6 @@ GEM execjs (>= 0.3.0) json (>= 1.8.0) unicode-display_width (0.3.1) - xpath (2.0.0) - nokogiri (~> 1.3) PLATFORMS ruby @@ -282,8 +273,6 @@ DEPENDENCIES active_model_serializers (= 0.10.0) brakeman breadcrumbs_on_rails - capybara - capybara-webkit clipboard compass-rails dynamic_form @@ -301,7 +290,7 @@ DEPENDENCIES net-ldap pry pry-stack_explorer - rails (= 4.2.5.1) + rails (= 4.2.6) rails-erd rubocop rubocop-checkstyle_formatter From 1158e21d8e6ab4bb27b2cafafff33312bb96b564 Mon Sep 17 00:00:00 2001 From: Patrick Wenger Date: Thu, 14 Jul 2016 10:34:49 +0200 Subject: [PATCH 7/8] edited deployment configurations for production #18534 --- Gemfile.lock | 3 --- config/database.yml | 11 ++--------- config/environments/production.rb | 2 +- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 68bff51d9..9a7c5bc34 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -304,6 +304,3 @@ DEPENDENCIES turbolinks twitter-bootstrap-rails uglifier - -BUNDLED WITH - 1.12.5 diff --git a/config/database.yml b/config/database.yml index c24ba1007..f0aeade71 100644 --- a/config/database.yml +++ b/config/database.yml @@ -43,12 +43,5 @@ test: database: <%= ENV['RAILS_DB_NAME'] || "#{Rails.root}/db/test.sqlite3" %> production: - database: <%= ENV['RAILS_DB_NAME'] || "cryptopus_production" %> - adapter: <%= ENV['RAILS_DB_ADAPTER'] || 'mysql2' %> - host: <%= ENV['RAILS_DB_HOST'] || '127.0.0.1' %> - port: <%= ENV['RAILS_DB_PORT'] || 3306 %> - username: <%= ENV['RAILS_DB_USERNAME'] %> - password: <%= ENV['RAILS_DB_PASSWORD'] %> - pool: 5 - timeout: 5000 - encoding: utf8 + <<: *generic + database: <%= ENV['RAILS_DB_NAME'] || "#{Rails.root}/db/development.sqlite3" %> diff --git a/config/environments/production.rb b/config/environments/production.rb index 4ab2841d3..14b3265e9 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -16,7 +16,7 @@ config.action_controller.perform_caching = true # Disable Rails's static asset server (Apache or nginx will already do this) - config.serve_static_files = false + config.serve_static_files = true # Compress JavaScripts and CSS config.assets.compress = true From 20eba02d0a08d208efc5fbec4e4eced8a97f7824 Mon Sep 17 00:00:00 2001 From: Patrick Wenger Date: Mon, 18 Jul 2016 15:26:58 +0200 Subject: [PATCH 8/8] fixed missing images in procompiled version refs #18534 --- app/assets/javascripts/modules/team_members.js.coffee | 3 +-- app/assets/javascripts/templates/team_member_entry.hbs.erb | 4 ++-- app/assets/stylesheets/teammember.scss | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/app/assets/javascripts/modules/team_members.js.coffee b/app/assets/javascripts/modules/team_members.js.coffee index 5a0d5e52d..a36e07a3f 100644 --- a/app/assets/javascripts/modules/team_members.js.coffee +++ b/app/assets/javascripts/modules/team_members.js.coffee @@ -90,8 +90,7 @@ class app.TeamMembers toggle_members() load_members() - $(document).on 'click', '.members li #remove_member', (e) -> + $(document).on 'click', '.members li .remove_member', (e) -> delete_member(e) new TeamMembers - diff --git a/app/assets/javascripts/templates/team_member_entry.hbs.erb b/app/assets/javascripts/templates/team_member_entry.hbs.erb index b2801964a..165461bb1 100644 --- a/app/assets/javascripts/templates/team_member_entry.hbs.erb +++ b/app/assets/javascripts/templates/team_member_entry.hbs.erb @@ -3,12 +3,12 @@
  • {{label}} {{#if admin}} - Remove + <%= image_tag("penguin.svg", class: "admin", alt:"Admin" ) %> {{/if}} {{#if deletable}} - Remove + <%= image_tag("remove.svg", class: "remove_member", alt:"Remove" ) %> {{/if}}
  • diff --git a/app/assets/stylesheets/teammember.scss b/app/assets/stylesheets/teammember.scss index d3dbe86dd..80cbafcae 100644 --- a/app/assets/stylesheets/teammember.scss +++ b/app/assets/stylesheets/teammember.scss @@ -37,6 +37,6 @@ float: right; } -li #penguin{ +li .admin{ float: right; }