Giter Club home page Giter Club logo

seems_rateable's People

Contributors

jogaco avatar pcarvalho197 avatar petertoth avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

seems_rateable's Issues

seems_rateable raises unknown method in Model

I have added gem to Gemfile and then installed it. All migrations have been run as well.

When I include seems_rateable in Product Model, it throws this error -
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/activerecord-4.1.1/lib/active_record/dynamic_matchers.rb:26:in method_missing': undefined local variable or methodseems_rateable' for Product (call 'Product.connection' to establish a connection):Class (NameError)
from /var/www/marketplace/app/models/product.rb:23:in <class:Product>' from /var/www/marketplace/app/models/product.rb:1:in<top (required)>'

Any pointers on what I am missing?

I am using Rails 4.1.1

Not compatible with Rails 3.2.x

Thanks for this gem.
However, I'm having problems in making it work with Rails 3.2.x.

When loading an object with seems_rateable from database:

 ArgumentError: wrong number of arguments (3 for 2)
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activerecord-3.2.16/lib/active_record/associations.rb:1197:in `has_many'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/seems_rateable-1.0.12/lib/seems_rateable/model.rb:84:in `seems_rateable'
from .../rails/sti_test/app/models/vehicle.rb:4:in `<class:Vehicle>'
from .../rails/sti_test/app/models/vehicle.rb:1:in `<top (required)>'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:469:in `load'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:469:in `block in load_file'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:639:in `new_constants_in'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:468:in `load_file'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:353:in `require_or_load'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:502:in `load_missing_constant'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:192:in `block in const_missing'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:190:in `each'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activesupport-3.2.16/lib/active_support/dependencies.rb:190:in `const_missing'
from (irb):1
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.16/lib/rails/commands/console.rb:47:in `start'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.16/lib/rails/commands/console.rb:8:in `start'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.16/lib/rails/commands.rb:41:in `<top (required)>'
from .../rails/sti_test/script/rails:6:in `require'
from .../sti_test/script/rails:6:in `<top (required)>'
from -e:1:in `load'
from -e:1:in `<main>'

I already implemented a fix, so a pull request will follow.

No spec files

There are no spec files in the repo. Are there any spec tests available?

not showing

I have inserted <%= rating_for c, dimension: :crating %> in a view (c is a comment), and it's not showing up. I do get this in the code:

I tried another gem and I had a problem - the stars were not showing(image thumbnails instead). - Saying this maybe it's a clue. (Rails 4.2.0beta4, Ruby 2.0.0p195)

Otherwise, keep up the good work! I'm a fan! Maybe we'll have a chat some day about "changing the world."

DEPRECATION WARNING - Rails 4

When I use seems_rateable in my model and run rails c command and try to manipulated this model, a warning appears. I'm using rails 4 e ruby 2.

DEPRECATION WARNING: The following options in your Question.has_many :rates_without_dimension
declaration are deprecated: :conditions. Please use a scope block instead. For example, the following:

    has_many :spam_comments, conditions: { spam: true }, class_name: 'Comment'

Little Help Needed

It's a great gem, it's working fine. But i am using it in a form more precisely in a New Post Form, there i am able to rate it. But what i want is to display those rating in my show action how would i do it. ? ii tried but not working please help me ASAP

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.