```
<%= f.text_field :quantity_available, :readonly => "readonly",:class=>"mg-text-field" %>

```

error:

> 
> *undefined method `quantity\_available' for #<:0xaf32b824>*
> 
> 
> 

In the new form I have shown "quantity\_available" whose value I am getting through jquery and this field is only for displaying purpose so this has not been saved in model but I want to do same in edit form in which I am getting error as 

how to resolve this?