app/controllers/products_controller.rb
# Never trust parameters from the scary internet, only allow the white list through.
Never trust parameters from the scary internet, only allow the white list through.
Never trust parameters from the scary internet only allow the white list through .
def product_params
      params.require(:product).permit(  :name, 
                                        :description, 
                                        :model, 
                                        :manufacturer, 
                                        :link, 
                                        :image, 
                                        :tags, 
                                        :apms, 
                                        :tag_list, 
                                        :apm_list, 
                                        :category_id, 
                                        attachments_attributes: [:file, :id, :_destroy], 
                                        documents_attributes: [:doc, :id, :_destroy]
                                        )
    end
def product_params params . require ( :product ) . permit ( :name , :description , :model , :manufacturer , :link , :image , :tags , :apms , :tag_list , :apm_list , :category_id , attachments_attributes : [ :file , :id , :_destroy ] , documents_attributes : [ :doc , :id , :_destroy ] ) end
Never trust parameters from the scary internet, only allow the white list through.
Never trust parameters from the scary internet only allow the white list through .