similar to: LoadError: Expected X to define on gem upgrade

Displaying 20 results from an estimated 200 matches similar to: "LoadError: Expected X to define on gem upgrade"

2008 Aug 05
1
Rails controller specs and private helper methods
Hello guys, Been a while since last time I worked with Rails so is taking me a while get back to full speed. For a specific scenario I''m facing right now, I required to implement a generic REST controller that accept any kind of resource and provide a @collection or @record to work with. I take from the route requirements the name of the resource
2011 Jul 14
0
subclasses with inherited_resources?
I''m trying out inherited_resources and so far so good. However, one problem I''ve run into is that it''s very difficult to customize inherited_resource behaviour in subclasses. Looking through the source I see it uses things like undef_method and class_attribute. For example, if I have the following controllers: class ItemsController inherit_resources actions :new,
2012 Oct 18
0
unexpected return (LocalJumpError) only when executing this code within autoloaded classes?
Posted on stackoverflow but no traction yet: http://stackoverflow.com/questions/12942505/why-does-using-set-trace-func-work-in-some-places-but-cause-unexpected-return-l The following is a generified part of the code in a gem I''m working on: module SomeModule class << self attr_accessor :procedure def log_events(*args) args.flatten!
2013 Mar 20
2
Rspec + Devise + BaseController
Hello there, I''m creating a base controller for the admin section of a project. All controllers whitin the admin section will inherit from it. ##################################################### #app/controllers/admins/base_controller.rb class Admins::BaseController < ApplicationController layout "admin_cms" before_filter :authenticate_admin! end
2005 Dec 28
3
Module loading
I''ve looked high and low for the answer to this and can''t seem to find anything that helps. I have an admin section (much like Typo) where all controllers are based on the Admin::BaseController. My directory structure is [RAILS] -app --controllers ---admin ----base_controller.rb ----products_controller.rb Products controller is: class Admin::ProductsController <
2012 Jan 26
2
Problem while creating new resource on ActiveAdmin
HI All, I have installed the Active Admin successfully, but facing the following error while restarting the server after generating an resource. *rails generate active_admin:resource item* /home/logs/Desktop/training/RAILS/courier/app/admin/items.rb:1:in `<top (required)>'': uninitialized constant Item (NameError) from
2012 Jan 23
0
Problem loading modules through ActiveSupport on_load
Working with modules to group certain methods. Currently I have this set up and it works: **# app/models/a.rb** class A has_history end **# lib/history.rb** module History module Model def self.included(base) base.send :extend, ClassMethods end module ClassMethods def has_history(options = {}) send :include,
2006 Aug 08
2
Extending rails with plugins
I''ve been looking at bottling some functionality up into a plugin, but I''m having some problems including it. The structure I have is: /app/controllers/admin/base_controller.rb: class Admin::BaseController > ApplicationController #snip# end /vendor/plugins/myplugin/lib/my_module.rb: module MyModule def new_func "New Function" end end
2011 Mar 30
0
Anonymous Subclass of ActionController::Base
I''m trying to spec a subclass of ActionController::Base using an anonymous subclass but I am running into errors but I am receiving a uninitialized constant StubResource Here is my base class class Admin::BaseController < ApplicationController before_filter :etherweb_site load_and_authorize_resource layout "admin/admin" protected def etherweb_site end end
2010 Nov 30
2
Did I miss a meeting?!
I''ve just stumbled (literally, while I was trying to fix a glitch I was having after upgrading Aegis...) on the Inherited Resources gem... why did no-one tell me?! ;-) Is everyone else using some form of controller base-class? Am I the last on this bus! https://github.com/josevalim/inherited_resources -- You received this message because you are subscribed to the Google Groups
2012 Sep 16
1
“Routing Error No route matches {}” when omniauth failed on registration
(Original question was asked here: http://stackoverflow.com/questions/11506734/routing-error-no-route-matches-when-omniauth-failed-on-registration ) I am using omniauth-identity and configure its "fail on registration". My files: config/initializers/omniauth.rb OmniAuth.config.logger = Rails.logger Rails.application.config.middleware.use OmniAuth::Builder do #... provider
2012 Jan 29
0
ActiveAdmin: Nested attributes not working for STI
HI All, I am having Model "Customer" using STI for sender and receiver, and i am unable to save the both sender and receiver by nested attribute. Below are my model and active admin resource codes, correct me if i am wrong nested attribute on concept. CUSTOMER MODEL: class Customer < ActiveRecord::Base belongs_to :sender, :class_name => "Customer" has_many
2009 May 03
0
HTTP Auth 401 Even on Valid Login
I can''t understand why authenticate_or_request_with_http_basic keeps failing even though I am entering the correct info. If I try to access /admin/items/new, I enter the correct info but I keep getting prompted. The strange part is that when I cancel out, I get "HTTP Basic: Acce". Here''s the controllers: class Admin::BaseController < ApplicationController
2007 Aug 27
0
Want to Move RestfulAuthentication's UsersController to Admin::UsersController
I''m trying to move RestfulAuthentication''s UsersController to an Admin module--Admin::UsersController--as I''m also adding roles and permissions for an app I''m building. I would like this all to be within a single user interface with a standard security level required for all these pieces as defined in Admin::BaseController. So far, I''ve been able to
2012 Oct 23
0
route problem
Hello I have this routes.rb Tamara::Application.routes.draw do ActiveAdmin.routes(self) devise_for :admin_users, ActiveAdmin::Devise.config resources :users resources :category do resources :berichten end end So I thought that localhost:3000/<category>/bericht/new I could write a new bericht which is stored in the <categoryname> But when I look at rake routes
2011 Sep 21
1
Active Admin
Hello comrades Can i use Active Admin on Rails 2.3.5 ? http://activeadmin.info/ Thanks Tsolmon -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to
2013 Oct 18
3
before_action - performing an action to prevent
class WebsocketController < WebsocketRails::BaseController private def authenticate? unless current_user.token == message[:token] current_redirect_to ''home/index'' false # that here we need to do to stop the further execution? end end end class WorldsController < WebsocketController before_action :authenticate? def index
2008 Nov 11
1
Admin controller
This is very weird behavior for rails. 1. When I visit my app http://localhost:3000/admin/base/login class Admin::BaseController < ApplicationController def login render :text => "running" end end 2. but when I go here http://localhost:3000/ I get error because login.html.erb not found 3. even though my route looks like this. map.root :controller =>
2006 Apr 04
3
How to use in_place_editor_field ?
Hello, I really don''t understand how to use in_place_editor_field In my controller : class Admin::CategoriesController < Admin::BaseController in_place_edit_for :category, :title def list @categories = Category.find_all end end In the view list.rhtml <% @categories.each do |c| %> <td><%= in_place_editor_field :c, c.title %></td> # snip <%
2011 Apr 06
2
Puppetdashboard 1.1.0 spec file
Hello, Does anyone have a good spec file for puppet dashboard 1.1.0, as the one supplied in the sourcecode is for 1.0.4 and tries to copy some directories, that don''t exist anymore. I did some remodelling in the file, so it creates a rpm now, but I''m not sure whether my "fix" is the only change needed. my change: replace -------------------- for plugin in