Muito bom mesmo.
Parabens e obrigado por compartilhar
> Shairon Toledohttp://www.google.com/profiles/shairon.toledo <http://www.google.com/profiles/shairon.toledo>
| |||||
|
|
por exemplo:
Você tem o link:
http://127.0.0.1:3006/pacientes/?ordenar=nome
e no seu controller você tem mais ou menos assim (não testei):
@pacientes = Paciente.all :order => params[:ordenar]
Daí você pode criar vários links como ordenar por sobrenome (se tiver claro).
--
Dmitry Rocha
http://dmitry.eti.br/
|
Pessoal,
Estou colocando em produção uma aplicação, mas está dando um erro: superclass mismatch for class Boleto
Estou utilizando o passenger, acts_as_payment, paperclip, role_requirement, validates_as_cpf.
Na minha máquina local funciona numa boa e no servidor remoto já há uma aplicação rodando com sucesso.
Tenho a impressão de que falta a instalação de algo. Já dei freeze, e os comandos das gems.
Segue as informações do server:
These are the possible causes:
*
There may be a syntax error in the application's code. Please check for such errors and fix them. * A required library may not installed. Please install all libraries that this application requires. * The application may not be properly configured. Please check whether all configuration files are written correctly, fix any incorrect configurations, and restart this application. * A service that the application relies on (such as the database server or the Ferret search engine server) may not have been started. Please start that service. Further information about the error may have been written to the application's log file. Please check it in order to analyse the problem.
Error message:
superclass mismatch for class Boleto Exception class: TypeError Application root: /fred/sistemas/vestibular Backtrace: # File Line Location 0 /fred/sistemas/vestibular/app/models/boleto.rb 1 1 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb 31 in `gem_original_require' 2 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb 31 in `require' 3 /fred/sistemas/vestibular/vendor/rails/activesupport/lib/active_support/dependencies.rb 158 in `require' 4 /fred/sistemas/vestibular/vendor/rails/activesupport/lib/active_support/dependencies.rb 265 in `require_or_load' 5 /fred/sistemas/vestibular/vendor/rails/activesupport/lib/active_support/dependencies.rb 224 in `depend_on' 6 /fred/sistemas/vestibular/vendor/rails/activesupport/lib/active_support/dependencies.rb 136 in `require_dependency' 7 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 393 in `load_application_classes' 8 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 392 in `each' 9 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 392 in `load_application_classes' 10 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 390 in `each' 11 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 390 in `load_application_classes' 12 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 195 in `process' 13 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 113 in `send' 14 /fred/sistemas/vestibular/vendor/rails/railties/lib/initializer.rb 113 in `run' 15 ./config/environment.rb 20 16 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb 31 in `gem_original_require' 17 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb 31 in `require' 18 /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/phusion_passenger/railz/application_spawner.rb 303 in `preload_application' .....
| |||
|
|
Alguém sabe como referenciar a pasta raiz de um projeto?