Compare commits

...

2 Commits

Author SHA1 Message Date
Arthur Poulet
4ee4ff9d03 Merge branch 'master' into glyph 2015-06-18 03:46:51 +02:00
Arthur Poulet
c61dbfea14 play with glyphicon 2015-06-18 02:43:32 +02:00
8 changed files with 36 additions and 32 deletions

View File

@ -32,9 +32,9 @@ table.table.table-condensed.table-striped
td.bg-danger = distance_of_time_in_words_to_now(bill.due_date) + " - " + bill.due_date.to_s(:long)
- else
td.bg-info = distance_of_time_in_words_to_now(bill.due_date).to_s + " - " + bill.due_date.to_s(:long)
td = link_to 'Show', bill
td = link_to 'Edit', edit_bill_path(bill)
td = link_to 'Destroy', bill, data: {:confirm => 'Are you sure?'}, :method => :delete
td = link_to '', bill, class: 'glyphicon glyphicon-eye-open'
td = link_to '', edit_bill_path(bill), class: 'glyphicon glyphicon-pencil'
td = link_to '', bill, data: {:confirm => 'Are you sure?'}, :method => :delete, class: 'glyphicon glyphicon-remove-sign'
br

View File

@ -30,6 +30,6 @@ table.table.table-condensed.table-striped
td.bg-danger = distance_of_time_in_words_to_now(bill.due_date) + " - " + bill.due_date.to_s(:long)
- else
td.bg-info = distance_of_time_in_words_to_now(bill.due_date).to_s + " - " + bill.due_date.to_s(:long)
td = link_to 'Show', bill
td = link_to '', bill, class: 'glyphicon glyphicon-eye-open'
br

View File

@ -28,14 +28,14 @@ table.table.table-condensed.table-striped
td.bg-success = ticket.state
td = ticket.updated_at.to_s(:long)
td = ticket.last_response ? distance_of_time_in_words_to_now(ticket.last_response.updated_at) : "never"
td = link_to 'Show', ticket
td = link_to 'Edit', edit_client_ticket_path(ticket)
/ td = link_to 'Destroy', ticket, data: {:confirm => 'Are you sure?'}, :method => :delete
td = link_to 'Respond', ticket_respond_path(ticket) if ticket.open?
td = link_to '', ticket, class: 'glyphicon glyphicon-eye-open'
td = link_to '', edit_client_ticket_path(ticket), class: 'glyphicon glyphicon-pencil'
/ td = link_to '', ticket, data: {:confirm => 'Are you sure?'}, :method => :delete, class: 'glyphicon glyphicon-remove-sign'
td = link_to '', ticket_respond_path(ticket), class: 'glyphicon glyphicon-comment' if ticket.open?
- if ticket.open?
td = link_to 'Close', client_ticket_close_path(ticket), data: {:confirm => 'Are you sure?'}, :method => :patch
td = link_to '', client_ticket_close_path(ticket), data: {:confirm => 'Are you sure to CLOSE this ticket?'}, method: :patch, class: 'glyphicon glyphicon-ok-circle'
- elsif ticket.close?
td = link_to 'Reopen', client_ticket_open_path(ticket), data: {:confirm => 'Are you sure?'}, :method => :patch
td = link_to '', client_ticket_open_path(ticket), data: {:confirm => 'Are you sure to REOPEN this ticket?'}, method: :patch, class: 'glyphicon glyphicon-remove-circle'
br

View File

@ -32,9 +32,9 @@ table.table.table-condensed.table-striped
td = client.retard
td = client.weight
td = client.next
td = link_to 'Show', client
td = link_to 'Edit', edit_client_path(client)
td = link_to 'Destroy', client, data: {:confirm => 'Are you sure?'}, :method => :delete
td = link_to '', client, class: 'glyphicon glyphicon-eye-open'
td = link_to '', edit_client_path(client), class: 'glyphicon glyphicon-pencil'
td = link_to '', client, data: {:confirm => 'Are you sure?'}, :method => :delete, class: 'glyphicon glyphicon-remove-sign'
br

View File

@ -32,9 +32,9 @@ table.table.table-condensed.table-striped
td = contact.department
td = contact.postal_code
td = contact.address
td = link_to 'Show', contact
td = link_to 'Edit', edit_contact_path(contact)
td = link_to 'Destroy', contact, data: {:confirm => 'Are you sure?'}, :method => :delete
td = link_to '', contact, class: 'glyphicon glyphicon-eye-open'
td = link_to '', edit_contact_path(contact), class: 'glyphicon glyphicon-pencil'
td = link_to '', contact, data: {:confirm => 'Are you sure?'}, :method => :delete, class: 'glyphicon glyphicon-remove-sign'
br

View File

@ -3,7 +3,9 @@
.space-client.col-xs-4
.panel.panel-success
.panel-heading
h3 Se connecter comme client
h3
| Client
.glyphicon.glyphicon-log-in
.panel-body
- if user_signed_in?
= link_to "Log out", destroy_user_session_path, method: :delete
@ -12,7 +14,9 @@
.space-admin.col-xs-4
.panel.panel-danger
.panel-heading
h3 Se connecter comme admin
h3
| Administration
.glyphicon.glyphicon-log-in
.panel-body
- if admin_signed_in?
= link_to "Log out", destroy_admin_session_path, method: :delete

View File

@ -16,17 +16,17 @@ html
- if user_signed_in?
.nav.navbar-nav.navbar-left
| #{current_user.name} 
= link_to "bills", client_bills_url, class: 'btn btn-lg btn-success narbar-btn'
= link_to "tickets", client_tickets_url, class: 'btn btn-lg btn-warning narbar-btn'
= link_to "logout", destroy_user_session_path, method: :delete, class: 'btn btn-lg btn-default narbar-btn'
= link_to " bills ", client_bills_url, class: 'btn btn-lg btn-success narbar-btn'
= link_to " tickets ", client_tickets_url, class: 'btn btn-lg btn-warning narbar-btn glyphicon glyphicon-envelope'
= link_to "", destroy_user_session_path, method: :delete, class: 'btn btn-lg btn-default narbar-btn glyphicon glyphicon-log-out'
- if admin_signed_in?
.nav.navbar-nav.navbar-right
| #{current_admin.email} 
= link_to "clients", clients_url, class: 'btn btn-lg btn-primary narbar-btn'
= link_to "contacts", contacts_url, class: 'btn btn-lg btn-info narbar-btn'
= link_to "bills", bills_url, class: 'btn btn-lg btn-success narbar-btn'
= link_to "tickets", tickets_url, class: 'btn btn-lg btn-warning narbar-btn'
= link_to "logout", destroy_admin_session_path, method: :delete, class: 'btn btn-lg btn-default narbar-btn'
= link_to " clients ", clients_url, class: 'btn btn-lg btn-primary narbar-btn glyphicon glyphicon-user'
= link_to " contact ", contacts_url, class: 'btn btn-lg btn-info narbar-btn glyphicon glyphicon-duplicate'
= link_to " bills ", bills_url, class: 'btn btn-lg btn-success narbar-btn glyphicon glyphicon-eur'
= link_to " tickets", tickets_url, class: 'btn btn-lg btn-warning narbar-btn glyphicon-envelope'
= link_to "", destroy_admin_session_path, method: :delete, class: 'btn btn-lg btn-default narbar-btn glyphicon glyphicon-log-out'
.yield
.container-fluid

View File

@ -29,14 +29,14 @@ table.table.table-condensed.table-striped
td.bg-success = ticket.state
td = ticket.updated_at.to_s(:long)
td = ticket.last_response ? distance_of_time_in_words_to_now(ticket.last_response.updated_at) : "never"
td = link_to 'Show', ticket
td = link_to 'Edit', edit_ticket_path(ticket)
td = link_to 'Destroy', ticket, data: {:confirm => 'Are you sure?'}, :method => :delete
td = link_to 'Respond', ticket_respond_path(ticket) if ticket.open?
td = link_to '', ticket, class: 'glyphicon glyphicon-eye-open'
td = link_to '', edit_ticket_path(ticket), class: 'glyphicon glyphicon-pencil'
td = link_to '', ticket, data: {:confirm => 'Are you sure to REMOVE this ticket?'}, :method => :delete, class: 'glyphicon glyphicon-remove-sign'
td = link_to '', ticket_respond_path(ticket), class: 'glyphicon glyphicon-comment' if ticket.open?
- if ticket.open?
td = link_to 'Close', ticket_close_path(ticket), data: {:confirm => 'Are you sure?'}, :method => :patch
td = link_to '', ticket_close_path(ticket), data: {:confirm => 'Are you sure to CLOSE this ticket?'}, method: :patch, class: 'glyphicon glyphicon-ok-circle'
- elsif ticket.close?
td = link_to 'Reopen', ticket_open_path(ticket), data: {:confirm => 'Are you sure?'}, :method => :patch
td = link_to '', ticket_open_path(ticket), data: {:confirm => 'Are you sure to REOPEN this ticket?'}, method: :patch, class: 'glyphicon glyphicon-remove-circle'
br