This repository has been archived on 2021-11-24. You can view files and clone it, but cannot push or open issues or pull requests.
phone_app/app/views/admin/societes/_form.html.haml
2021-08-23 10:26:02 +02:00

88 lines
4.0 KiB
Plaintext

=semantic_form_for [:admin, @societe], :remote => true do |f|
.content
=f.inputs do
-if current_admin.super_admin
= f.input :bon_type, :label => "Type de réduction :", :collection => [["Bon d'achat", "Bon d'achat", {:data => {:type => "ba"}}], ["Remise immédiate", "Remise immédiate", {:data => {:type => "ri"}}]], :as => :select, :input_html => {:onchange => "update_soc_select();", :id => "bon_type_select"}, :include_blank => false
.ba.soc_select
= f.input :seuil, :label => "Seuil de déclenchement (€) :"
= f.input :bon_amount, :label => "Montant du bon d'achat (€) :"
= f.input :send_via, :label => "Mode d'envoi bon d'achat :", :collection => ["Mail", "Courrier"], :as => :select, :include_blank => false
.ri.soc_select
= f.input :remise_percent, :label => "Remise immédiate (%) :"
:coffeescript
@update_soc_select = ->
type = $("#bon_type_select").children("option:selected").data("type")
$(".soc_select").hide()
$(".soc_select."+type).show()
update_soc_select()
=# f.input :socmanaginn, :label => "Code Net-Inn :"
= f.input :nom, :label => "Nom :"
= f.input :adresse1, :label => "Adresse :"
= f.input :adresse2, :label => "Adresse (suite) :"
= f.input :codepostal, :label => "Code postal :"
= f.input :ville, :label => "Ville :"
=# f.input :pays, :label => "Pays :"
= f.input :numtel, :label => "Tel :"
=# f.input :numfax, :label => "Fax :"
=# f.input :mobile, :label => "Mobile :"
-if current_admin.super_admin
= f.input :mail, :label => "Email :"
=# f.input :mailcc, :label => "Email (cc) :"
=# f.input :mailbcc, :label => "Email (bcc) :"
=# f.input :siteweb, :label => "Site web :"
=# f.input :statut, :label => "Forme juridique :"
=# f.input :rc, :label => "RC :"
=# f.input :naf, :label => "NAF :"
= f.input :soc_type, :label => "Type de société :"
= f.input :enseigne, :label => "Enseigne :"
=# f.input :datecreation, :label => "Date création :", :as => :date
=# f.input :activite1, :label => "Activité 1 :"
=# f.input :activite2, :label => "Activité 2 :"
=# f.input :activite3, :label => "Activité 3 :"
=# f.input :activite4, :label => "Activité 4 :"
=# f.input :activite5, :label => "Activité 5 :"
=# f.input :login, :label => "Login :"
=# f.input :password, :label => "password :"
=# f.input :photo, :label => "photo :"
=# f.input :typeuser, :label => "typeuser :"
=# f.input :codeproprietaire, :label => "Code propriétaire Net-Inn :"
=# f.input :typepartage, :label => "Type partage :"
=# f.input :libre1, :label => "Libre 1 :"
=# f.input :libre2, :label => "Libre 2 :"
=# f.input :libre3, :label => "Libre 3 :"
=# f.input :libre4, :label => "Libre 4 :"
= f.input :libre5, :label => "Libre 5 :"
=# f.input :accesbloque, :label => "Accès bloqué :"
=# f.input :corbeille, :label => "corbeille :"
=# f.input :codetpe, :label => "codetpe :"
=# f.input :codecreateur, :label => "codecreateur :"
=# f.input :partagedefaut, :label => "partagedefault :"
=# f.input :npai, :label => "npai :"
=# f.input :npaimail, :label => "npaimail :"
=# f.input :npaisms, :label => "napisms :"
=# f.input :ac_rate, :label => "ac_rate :"
=# f.input :cc_rate, :label => "cc_rate :"
=# f.input :ac_cagnotte, :label => "ac_cagnotte :"
= #f.input :cc_cagnotte, :label => "cc_cagnotte :"
=# f.input :ac_cumul, :label => "ac_cumul :"
= f.input :enabled, :label => "Activée ?"
=# f.input :last_volume_at, :label => "last_volume_at :"
.actions=f.submit "sauvegarder", :class => "btn btn-primary"