Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: railscard/engine
...
head fork: railscard/engine
Checking mergeability… Don't worry, you can still create the pull request.
  • 12 commits
  • 13 files changed
  • 0 commit comments
  • 5 contributors
Commits on Apr 10, 2012
@mariovisic mariovisic Require the engine on gem load. 4bf16b0
Commits on Apr 11, 2012
@willcosgrove willcosgrove Added new buttons and styling cd70397
@willcosgrove willcosgrove Fixed my css and javascript problems 560afc6
Commits on Apr 13, 2012
Didier Lafforgue fix issue #338 7a59520
@did did Merge pull request #345 from locomotivecms/no_require
Require the engine on gem load.
e2b73d7
@alexsanford alexsanford Changed iframe resize function
Instead of resizing the iframe based on the height of the body element
of the iframe content, do it based on the entire content height. Also,
don't compare the inner content height to the body height of the outer
page, but use the iframe height instead.
56a0aff
Didier Lafforgue fix issue #348 d0698b1
@did did Merge pull request #351 from willcosgrove/spinny-toggle-buttons
Spinny toggle buttons
9dc3f77
@mariovisic mariovisic Fixed a regression when updating javascript stringify. Fixes #355. edca632
@mariovisic mariovisic Merge remote-tracking branch 'origin/master' ebd3081
@mariovisic mariovisic Merge pull request #356 from colibri-software/inline_editor_firefox_fix
Inline editor bug in Firefox
f7388d1
@railscard Merge branch 'master' of https://github.com/locomotivecms/engine 5bf15a0
View
31 Gemfile.lock
@@ -48,9 +48,9 @@ PATH
httparty (~> 0.8.1)
jquery-rails (~> 1.0.16)
kaminari (~> 0.13.0)
- locomotive-aloha-rails (~> 0.20.1.1)
+ locomotive-aloha-rails (~> 0.20.1.2)
locomotive-mongoid-tree (~> 0.6.2)
- locomotive-tinymce-rails (~> 3.4.7.1)
+ locomotive-tinymce-rails (~> 3.4.7.2)
locomotive_liquid (= 2.2.2)
mimetype-fu (~> 0.1.2)
mongo (~> 1.5.2)
@@ -112,7 +112,7 @@ GEM
rack-test (>= 0.5.4)
selenium-webdriver (~> 2.0)
xpath (~> 0.1.4)
- carrierwave (0.6.0)
+ carrierwave (0.6.2)
activemodel (>= 3.2.0)
activesupport (>= 3.2.0)
carrierwave-mongoid (0.1.3)
@@ -132,7 +132,7 @@ GEM
coffee-script (2.2.0)
coffee-script-source
execjs
- coffee-script-source (1.2.0)
+ coffee-script-source (1.3.1)
cucumber (1.1.9)
builder (>= 2.1.2)
diff-lcs (>= 1.1.2)
@@ -149,7 +149,7 @@ GEM
orm_adapter (~> 0.0.3)
warden (~> 1.1)
diff-lcs (1.1.3)
- dragonfly (0.9.11)
+ dragonfly (0.9.12)
rack
ejs (1.0.0)
erubis (2.7.0)
@@ -177,13 +177,13 @@ GEM
formatador (0.2.1)
formtastic (2.0.2)
rails (~> 3.0)
- fssm (0.2.8.1)
+ fssm (0.2.9)
gherkin (2.9.3)
json (>= 1.4.6)
haml (3.1.4)
highline (1.6.11)
hike (1.2.1)
- httparty (0.8.1)
+ httparty (0.8.2)
multi_json
multi_xml
i18n (0.6.0)
@@ -199,12 +199,14 @@ GEM
kgio (2.7.4)
launchy (2.1.0)
addressable (~> 2.2.6)
- locomotive-aloha-rails (0.20.1.1)
+ libwebsocket (0.1.3)
+ addressable
+ locomotive-aloha-rails (0.20.1.2)
actionpack (~> 3.2.1)
locomotive-mongoid-tree (0.6.2)
mongoid (~> 2.0)
- locomotive-tinymce-rails (3.4.7.1)
- actionpack (~> 3.2.1)
+ locomotive-tinymce-rails (3.4.7.2)
+ actionpack (~> 3.0)
locomotive_liquid (2.2.2)
mail (2.4.4)
i18n (>= 0.4.0)
@@ -215,7 +217,7 @@ GEM
mocha (0.9.12)
mongo (1.5.2)
bson (= 1.5.2)
- mongoid (2.4.7)
+ mongoid (2.4.8)
activemodel (~> 3.1)
mongo (~> 1.3)
tzinfo (~> 0.3.22)
@@ -280,7 +282,7 @@ GEM
railties (>= 3.0)
rspec (~> 2.8.0)
ruby-hmac (0.4.0)
- rubyzip (0.9.6.1)
+ rubyzip (0.9.7)
sanitize (2.0.3)
nokogiri (>= 1.4.4, < 1.6)
sass (3.1.15)
@@ -288,9 +290,10 @@ GEM
railties (~> 3.2.0)
sass (>= 3.1.10)
tilt (~> 1.3)
- selenium-webdriver (2.20.0)
+ selenium-webdriver (2.21.0)
childprocess (>= 0.2.5)
ffi (~> 1.0)
+ libwebsocket (~> 0.1.3)
multi_json (~> 1.0)
rubyzip
shoulda-matchers (1.0.0)
@@ -304,7 +307,7 @@ GEM
treetop (1.4.10)
polyglot
polyglot (>= 0.3.1)
- tzinfo (0.3.32)
+ tzinfo (0.3.33)
uglifier (1.2.4)
execjs (>= 0.3.0)
multi_json (>= 1.0.2)
View
BIN  app/assets/images/locomotive/list/icons/toggle.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  app/assets/images/locomotive/list/icons/toggle_off.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
2  app/assets/javascripts/locomotive/utils/core_ext.js
@@ -18,7 +18,7 @@
String.prototype.slugify = function(sep) {
if (typeof sep == 'undefined') sep = '_';
- var alphaNumRegexp = new RegExp('[^\w\\' + sep + ']', 'g');
+ var alphaNumRegexp = new RegExp('[^\\w\\' + sep + ']', 'g');
var avoidDuplicateRegexp = new RegExp('[\\' + sep + ']{2,}', 'g');
return this.replace(/\s/g, sep).replace(alphaNumRegexp, '').replace(avoidDuplicateRegexp, sep).toLowerCase()
}
View
2  app/assets/javascripts/locomotive/views/content_types/custom_field_entry_view.js.coffee
@@ -78,8 +78,10 @@ class Locomotive.Views.ContentTypes.CustomFieldEntryView extends Backbone.View
form = @$('ol')
if form.is(':hidden')
+ @$('a.toggle').addClass('open')
form.slideDown()
else
+ @$('a.toggle').removeClass('open')
form.slideUp()
show_error: (message) ->
View
4 app/assets/javascripts/locomotive/views/inline_editor/application_view.js.coffee
@@ -30,11 +30,11 @@ class Locomotive.Views.InlinEditor.ApplicationView extends Backbone.View
if @_$('meta[name=inline-editor]').size() > 0
# bind the resize event. When the iFrame's size changes, update its height
- iframe_content = iframe.contents().find('body')
+ iframe_content = iframe.contents()
iframe_content.resize ->
elem = $(this)
- if elem.outerHeight(true) > $('body').outerHeight(true) # Resize the iFrame.
+ if elem.outerHeight(true) > iframe.outerHeight(true) # Resize the iFrame.
iframe.css height: elem.outerHeight(true)
# Resize the iFrame immediately.
View
4 app/assets/stylesheets/locomotive/backoffice/formtastic_changes.css.scss
@@ -157,6 +157,10 @@ form.formtastic {
&:hover {
background-image: image-url("locomotive/list/icons/toggle.png");
}
+ &.open {
+ @include rotate(180deg);
+ }
+ @include single-transition(transform, 0.5s);
}
&.drag {
View
4 app/mailers/locomotive/notifications.rb
@@ -3,8 +3,8 @@ class Notifications < ActionMailer::Base
default :from => Locomotive.config.mailer_sender
- def new_content_entry(account, entry)
- @account, @entry, @type = account, entry.to_presenter, entry.content_type
+ def new_content_entry(entry, account)
+ @account, @entry, @type = account, entry, entry.content_type
subject = t('locomotive.notifications.new_content_entry.subject', :type => @type.name, :locale => account.locale)
View
2  app/models/locomotive/content_entry.rb
@@ -146,7 +146,7 @@ def send_notifications
return if !self.content_type.public_submission_enabled? || self.content_type.public_submission_accounts.blank?
self.site.accounts.each do |account|
- next unless self.content_type.public_submission_accounts.include?(account._id)
+ next unless self.content_type.public_submission_accounts.map(&:to_s).include?(account._id.to_s)
Locomotive::Notifications.new_content_entry(account, self).deliver
end
View
17 app/views/locomotive/notifications/new_content_entry.html.haml
@@ -10,13 +10,20 @@
%hr
%ul
- - @type.entries_custom_fields.each do |field|
- - value = @entry.value_for(field)
+ - @type.ordered_entries_custom_fields.each do |field|
+ - value = @entry.send(field.name)
%li
%strong= field.label
&nbsp;-&nbsp;
%i
- - if field.type == 'file'
- = link_to File.basename(value), value
- - else
+ - case field.type.to_s
+ - when 'string', 'text', 'boolean', 'date'
= value
+ - when 'file'
+ = link_to File.basename(value.to_s), value.to_s
+ - when 'select'
+ = value
+ - when 'belongs_to'
+ = value.try(:_label)
+ - when 'has_many', 'many_to_many'
+ = value.map(&:_label).join(', ')
View
1  lib/locomotive_cms.rb
@@ -0,0 +1 @@
+require 'locomotive/engine'
View
4 locomotive_cms.gemspec
@@ -38,8 +38,8 @@ Gem::Specification.new do |s|
s.add_dependency 'jquery-rails', '~> 1.0.16'
s.add_dependency 'rails-backbone', '~> 0.6.1'
s.add_dependency 'codemirror-rails', '~> 2.21'
- s.add_dependency 'locomotive-tinymce-rails', '~> 3.4.7.1'
- s.add_dependency 'locomotive-aloha-rails', '~> 0.20.1.1'
+ s.add_dependency 'locomotive-tinymce-rails', '~> 3.4.7.2'
+ s.add_dependency 'locomotive-aloha-rails', '~> 0.20.1.2'
s.add_dependency 'flash_cookie_session', '~> 1.1.1'
s.add_dependency 'locomotive_liquid', '2.2.2'
View
2  spec/models/locomotive/content_entry_spec.rb
@@ -202,7 +202,7 @@
@account_2 = FactoryGirl.build('frenchy user', :id => fake_bson_id('2'))
@content_type.public_submission_enabled = true
- @content_type.public_submission_accounts = ['', @account_1._id, @account_2._id]
+ @content_type.public_submission_accounts = ['', @account_1._id, @account_2._id.to_s]
site = FactoryGirl.build(:site)
site.stubs(:accounts).returns([@account_1, @account_2])

No commit comments for this range

Something went wrong with that request. Please try again.