ruby on rails - ActionController::ParameterMissing Don't know whats wrong -


I am getting this error, I have not used Ruby in some time, so I do not know how to fix it. To do . Is missing on the ultimate or value is empty: sch removed source (around line # 72): 70 71 72 73 74 # Do not trust the criteria from scary internet, only through white list. def sch_params params.require (: sch) .permit (: date, time, user_id) end-end Rails.root: C: / sites / web application trace | Framework trace | Full Trace App / Controller / Scache_Controller RB: 72: `SCAPRAM 'app / controller / skill_controller RB: 27: Request parameter to 'create' in: {"UTF8" = "gtc:" A "???," Authentication_token "=> gt; cHq54V7aVCjeBz0udZAYjGiojgrqDANx / BS + OmQ + N +0 =", "Ski "= & gt; {"Date (1a)" =>, 2014 "," Date (2) "=>," 4 "," Date "(3i)" = & gt; " 21 "," time (1i) "= => = "," Time "," time "(" 4i ")," time (4i) "=" 21 "," time "

Class SchesController & lt; ApplicationController before_action: set_sch, only: [: show,: edit, update: deleted] #gET / sches #gET /sches.json dnf index @sches = Sche.all end # gET / sches / 1 # gET / sches / 1. Jason Diff Show End # GET / Scase / New Diff New @ SCH = Ski New End # GET / Skesh / 1 / Edit Ed Edit End # POST / Sketch # POST /sches.json DRF @ SEC = SEF (Sch_params) response_to do | Format | If @ sch.save format.html {redirect_to @sch, notice: 'The plan was successfully created.' } format.json {render: show, position :: created, location: @ sce} other formats: {render: new} format.json {json: @ sch.errors, status :: unprocessable_entity} end-end # PATCH / put / skes / 1 # Patch / Pt / Ceske / 1.Jason Diff Update Reply-Do-it-Yourself Format | If @ sch.update (sch_params) format.html {redirect_to @sch, notice: 'The plan was updated successfully.' } Format.json {Render: Show, Position :: OK, Location: @SEC} Other formats: {Render: edit} format.json {Render Jason: @ SAROrors, Status: Unrestricted_Entity} End & # DELETE / SCES / 1 # Delete / Cess / 1.Delete Jason Def / @ Reply to Skadrooy. Format Format.html {redirect_to sches_url} format.json {head: no_content} Use Callback to share common setup or barriers between end-end personal # tasks def set_sch @sch = Sche.find (params [: id]) Never endorse the scandal with the internet; Do not believe the norms only through the white list, def sch_params params.require (: sch) .permit (: date, time, user) and end

Its Use: <

Your controller name is SchesController then you have the key sche and sch not found.

If you see the generated parameter, notice sche

"sche" = & gt; {"Date (1i)" = = = "2014", "Time (2i)" = & gt; 4 "," Date (3i) "=>," 21 "," Time (1i) "=>" 2014 "," Time (2) "=> , "4", "time (3i)" = = "21", "time (4i)" = = gt; "17", "Time (5i)" =>, "37", "User" => "Steve"}

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -