On 23 fév, 17:18, "Sergio Cambra .:: entreCables S.L. ::."
<[email protected]> wrote:
> > On 23 fév, 12:27, "Sergio Cambra .:: entreCables S.L. ::."
>
>
> > This is my controller as you asked me for the third issue. The
> > associated column that has the file upload column is
> > "pjoffreservices". The file upload works well in "pjoffreservices
> > controller" views, but not in "offreservices controller" views in
> > which it is an associated column.
>
> for file upload? Do you have that column in config.subform.columns?
I had in config.columns. But i have tried to add it in
config.subform.columns after your post, but it doesn't have any
change.
> Then we need pjoffreservices controller code. Are you using a virtual column
Here is my "pjoffreservices controller":
class PjoffreservicesController < ApplicationController
before_filter :login_required, :only => [:create, :update]
active_scaffold :pjoffreservice do |config|
config.create.multipart = true
config.update.multipart = true
#config.create.formats << :pdf
config.create.columns = [:typepj, :description, :filename]
config.update.columns = [:typepj, :description, :filename]
config.list.columns = [:auteur, :typepj, :description, :filename]
config.create.columns.exclude(:user, :auteur, :created_at, :updated_at)
config.update.columns.exclude(:user, :auteur, :created_at, :updated_at)
config.columns[:typepj].form_ui = :select
config.list.label = "Pièces jointes"
config.columns[:filename].label = "Fichier"
config.columns[:auteur].label = "Auteur"
config.columns[:typepj].label = "Type"
config.columns[:created_at].label = "Créé le"
config.columns[:updated_at].label = "Mis à jour le"
#config.update.link.inline = false
end
end
> Which helper have you added it in?
I in pjoffreservices Helper. And in "offreservices Helper" because
the first one didn't work.
I have a "has_and_belongs_to_many" association.
--
You received this message because you are subscribed to the Google Groups
"ActiveScaffold : Ruby on Rails plugin" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/activescaffold?hl=en.