Open hayksaakian opened 11 years ago
Okay, can you test it anyway? Just add to your Gemfile line
gem 'best_in_place_mongoid', github: 'bartekd/best_in_place_mongoid', branch: 'mongoid_2_4_2'
Let me know is it work.
I'll try it in the morning (8-10 he's from now), thanks for being quick to respond :-)
bundle worked without complaining, but now i cant seem to follow the install instructions. Here's what I did:
add gem 'best_in_place_mongoid', github: 'bartekd/best_in_place_mongoid', branch: 'mongoid_2_4_2' to gemfile
bundle
try to do rails g best_in_place:setup but this fails because 'Could not find generator best_in_place:steup.'
do i need to add the normal 'best_in_place' gem too?
whoops, typo. trying again now. -- Nope still didnt work
How did you install a new gem version?
at first i did a regular bundle install, i also tried a bundle update
source 'https://rubygems.org'
gem 'rails', '3.1.0'
gem "mongoid", "~> 2.4.0" gem "bson_ext", "1.6.2" gem "mongo" gem 'mongoid_fulltext', "~> 0.5" gem "will_paginate_mongoid", "~> 1.0.0" gem "will_paginate", "~> 3.0.3" gem 'bootstrap-will_paginate'
gem "delayed_job", "~> 3.0.2" gem "delayed_job_mongoid", "~> 1.0.8" gem "foreman"
gem 'twilio-ruby'
gem "therubyracer" gem "less-rails" gem "twitter-bootstrap-rails", "~> 2.1.2"
gem 'best_in_place_mongoid', github: 'bartekd/best_in_place_mongoid', branch: 'mongoid_2_4_2' gem 'best_in_place'
gem 'fullcontact'
group :assets do gem 'sass-rails', '~> 3.1.0' gem 'coffee-rails', '~> 3.1.0'
gem 'uglifier', '>= 1.0.3' end group :development do gem 'binding_of_caller' gem "better_errors" end gem 'jquery-rails'
gem "heroku"
You cannot use both best_in_place gems..
gem 'best_in_place_mongoid', github: 'bartekd/best_in_place_mongoid', branch: 'mongoid_2_4_2'
# gem 'best_in_place' # <- remove this line
second thing
try setup best in place by bundle exec rails g best_in_place:setup
let me make that change now. the install instructions on the readme told me to add gem best_in_place to the gemfile though
same problem with using bundle exec as normal 'Could not find generator best_in_place:setup.'
Eh the readme doesn't tell the truth.. looks like the generator has been removed from main repository (best_in_place). Installation process is easy, you have to just add
//= require best_in_place.purr
into your application.js
Then it should work out of the box.
ok, i added //= require best_in_place (the .purr version was causing errors: 'couldn't find file 'best_in_place.purr' ') but now it just won't work, for example: <%= best_in_place @lead, :first_name, :nil => "Click here to add one" %> which turns into
<span class="best_in_place" id="best_in_place_lead_50b7f02d2efc122126000008_first_name" data-url="/leads/50b7f02d2efc122126000008" data-object="lead" data-attribute="first_name" data-nil="Click here to add one" data-type="input">abnother</span>
for example, but this behaves like a normal span, and is not editable
my application.js, for reference //= require jquery //= require jquery_ujs //= require twitter/bootstrap //= require bootstrap //= require best_in_place //= require_tree .
Thanks! I'm going to fix it tomorrow.
thanks
any success? :)
I'm still working on best solution... give me more time (it should be ready in saturday).
if this is too time consuming / difficult, are there alternatives you can suggest in the mean time?
any news on this?
given that they're on 3.x now, supporting to most up-to-date minor version would be nice
this specifically conflicts with the will_paginate_mongoid gem, which DOES support 2.4.2