We are creating an app with CRUD function as an exercise using rails.
As a simple explanation, the CRUD function is implemented without using scaffold.
Therefore, the following errors are displayed and clogged.
I would be pleased if you could find someone who knows.
In addition, we will add if there is insufficient information.
Applicable source code
NameError: undefined local variable or method `params' for UsersController: Class
# frozen_string_literal: true class UsersController
Supplemental information (FW/tool version etc.)
# frozen_string_literal: true class ListsController
ruby -v 2.6.4
rails -v 5.2.3
Answer # 1
It must be written in the method, not directly under the class.
- ruby on rails - about variable error of rails like function
- ruby on rails - uncaught reference error: $is not defined cannot be resolved
- ruby on rails - [docker] mysql2 :: error :: connectionerror: unknown mysql server host'db' (-2)
- ruby on rails - i get an error when i log in
- ruby on rails - about the error when trying to implement jquery with rails ($is not defined;please fix or add/* global * /)
- ruby on rails - i get an error in a program that changes over time
- ruby on rails - when i changed the data type, i got an sql error i don't know where the cause is
- ruby on rails - routing error when pressing rails submit button
- ruby - (rails) i want to eliminate the error "errno :: eacces in ~" and "permission denied @ rb_sysopen ~"
- ruby on rails - [docker] i get an error when i run rails db: migrate
- ruby on rails - error when vagrant up
- ruby on rails - error in controller when transitioning with rails6 destory action
- ruby on rails runtime error cannot be resolved
- ruby on rails - i want to resolve rails name error
- ruby on rails - pg :: datatypemismatch error when doing heroku run rails db: migrate
- ruby on rails - unknown action error when trying to post a comment
- ruby on rails - i get an error with rails db: create
- ruby on rails - i want to eliminate the error when deploying to heroku
- ruby on rails - syntax error cannot be resolved
- ruby on rails - heroku run rails db: migrate an error occurs in heroku run rails db: migrate
- ruby - creating a twitter clone on rails an error occurred when executing a like cancellation [routingerror]
- ruby - when you set up the server, a warning comes out
- ruby on rails data is not saved in db? ??
- ruby - the wrong number of arguments (given 5, expected 2) is not fixed
- ruby - if i accidentally do rails db: drop, the database disappears and i can't deploy it can i get it back?
- ruby - i can't edit all at once with unknown attribute'' for it
- ruby - i want to make the test successful
- ruby - [rails] actioncontroller::parametermissing is displayed and data is not saved
- ruby - rails micropost favorites