Description:
modernize to HAML
Commit status:
[Not Reviewed]
References:
Comments:
0 Commit comments 0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
Add another comment

r580:a054bb8a99e5 - - 8 files changed: 85 inserted, 115 deleted

@@ -0,0 +1,24
1 + %h1 Editing site
2 + = error_messages_for :site
3 + = form_for(@site) do |f|
4 + %p
5 + %b Name
6 + %br/
7 + = f.text_field :name
8 + %p
9 + %b Password
10 + %br/
11 + = f.text_field :password
12 + %p
13 + %b Started
14 + %br/
15 + = f.check_box :started
16 + %p
17 + %b Start time
18 + %br/
19 + = f.datetime_select :start_time, :include_blank => true
20 + %p
21 + = f.submit "Update"
22 + = link_to 'Show', @site
23 + |
24 + = link_to 'Back', sites_path
@@ -0,0 +1,24
1 + %h1 Listing sites
2 + %table.table.table-striped
3 + %tr
4 + %th Name
5 + %th Password
6 + %th Started
7 + %th Start time
8 + %th
9 + %th
10 + %th
11 + - for site in @sites
12 + - background = "white"
13 + - background = "grey" if (site.started==true) and (site.finished? == true)
14 + - background = "lightgreen" if (site.started==true) and (site.finished? != true)
15 + %tr{:style => "background: #{background};"}
16 + %td= h site.name
17 + %td= h site.password
18 + %td= h site.started
19 + %td= h site.start_time
20 + %td= link_to 'Show', site, class: 'btn btn-default'
21 + %td= link_to 'Edit', edit_site_path(site), class: 'btn btn-default'
22 + %td= link_to 'Destroy', site, :confirm => 'Are you sure?', :method => :delete, class: 'btn btn-default'
23 + %br/
24 + = link_to '+ New site', new_site_path, class: 'btn btn-success'
@@ -0,0 +1,22
1 + %h1 New site
2 + = error_messages_for :site
3 + = form_for(@site) do |f|
4 + %p
5 + %b Name
6 + %br/
7 + = f.text_field :name
8 + %p
9 + %b Password
10 + %br/
11 + = f.text_field :password
12 + %p
13 + %b Started
14 + %br/
15 + = f.check_box :started
16 + %p
17 + %b Start time
18 + %br/
19 + = f.datetime_select :start_time
20 + %p
21 + = f.submit "Create"
22 + = link_to 'Back', sites_path
@@ -0,0 +1,15
1 + %p
2 + %b Name:
3 + = h @site.name
4 + %p
5 + %b Password:
6 + = h @site.password
7 + %p
8 + %b Started:
9 + = h @site.started
10 + %p
11 + %b Start time:
12 + = h @site.start_time
13 + = link_to 'Edit', edit_site_path(@site)
14 + |
15 + = link_to 'Back', sites_path
deleted file
deleted file
deleted file
deleted file
You need to be logged in to leave comments. Login now