Pastebin launched a little side project called HostCabi.net, check it out ;-)Don't like ads? PRO users don't see any ads ;-)
Guest

Form con problemi.......

By: MdreW on Jul 3rd, 2012  |  syntax: Ruby  |  size: 1.10 KB  |  hits: 37  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. %div{:id => @email.div_details}
  2.   %dl
  3.     %dt Stato
  4.     %dd= @email.status || "non inviata"
  5.     .clear.p10
  6.  
  7.     %dt Ogetto
  8.     %dd= best_in_place [@email.campaign, @email], :subject
  9.     .clear.p10
  10.  
  11.     %dt Testo
  12.     %dd= best_in_place [@email.campaign, @email], :body, :type => :textarea, :sanitize => false
  13.  
  14. %div{:id => "attachments"}
  15.   %h3{:class => "tcenter"} Allegati
  16.   %ul
  17.     %li{:class => "list"}
  18.       = form_for( [@campaign, @email, @attachment_new], :html => { :multipart => true}, :remote => true ) do |f|
  19.         = f.file_field :file
  20.         %span{:class => "fright"}
  21.           = f.submit
  22.  
  23.     = render :partial => 'attachment', :collection => @attachments
  24.  
  25. .tcenter= button_to("Invia", tosend_campaign_email_path(@email.campaign, @email), :remote => true)
  26.  
  27. - if @email.status == "inviata"
  28.   %div{:id => "statistics"}
  29.     %h3{:class => "tcenter"} Statistiche
  30.     %dl
  31.       %dt Indirizzi
  32.       %dd= @email.addresses.count
  33.  
  34.       %dt Inviate:
  35.       %dd= @email.postings.sended.count
  36.       .clear.p10
  37.  
  38.       %dt Fallite:
  39.       %dd= @email.postings.failed.count
  40.       .clear.p10