-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added links to first page and logout
- Loading branch information
Showing
13 changed files
with
124 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,15 @@ | ||
%h2 Sign up | ||
%h2 Cadastrar usuário | ||
= form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f| | ||
= devise_error_messages! | ||
%div | ||
= f.label :email | ||
%br/ | ||
= f.email_field :email | ||
%div | ||
= f.label :password | ||
%br/ | ||
= f.password_field :password | ||
%div | ||
= f.label :password_confirmation | ||
%br/ | ||
= f.password_field :password_confirmation | ||
%div= f.submit "Sign up" | ||
%p | ||
= f.label :email, 'Login: ' | ||
= f.email_field :email, :placeholder => 'informe um email válido', :maxlength => 50, :size => 50 | ||
%p | ||
= f.label :password, 'Senha: ' | ||
= f.password_field :password, :placeholder => 'com mais de seis caracteres', :maxlength => 30, :size => 30 | ||
%p | ||
= f.label :password_confirmation, 'Confirme a senha: ' | ||
= f.password_field :password_confirmation, :placeholder => 'repita sua senha', :maxlength => 30, :size => 30 | ||
%p= f.submit "Cadastrar" | ||
= render :partial => "devise/shared/links" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,11 @@ | ||
%h2 Entrar no sistema | ||
= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| | ||
%div | ||
= f.label :email | ||
%br/ | ||
= f.email_field :email | ||
%div | ||
= f.label :password | ||
%br/ | ||
= f.password_field :password | ||
- if devise_mapping.rememberable? | ||
%div | ||
= f.check_box :remember_me | ||
= f.label :remember_me | ||
%div= f.submit "Sign in" | ||
%p | ||
= f.label :email, 'Login:', :maxlength => 50, :size => 50 | ||
= f.email_field :email, :placeholder => 'informe seu email' | ||
%p | ||
= f.label :password, 'Senha: ', :maxlength => 30, :size => 30 | ||
= f.password_field :password, :placeholder => 'informe sua senha' | ||
%div= f.submit "Entrar" | ||
= render :partial => "devise/shared/links" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,6 @@ | ||
- if controller_name != 'sessions' | ||
= link_to "Sign in", new_session_path(resource_name) | ||
= link_to "Entrar", new_session_path(resource_name) | ||
%br/ | ||
- if devise_mapping.registerable? && controller_name != 'registrations' | ||
= link_to "Sign up", new_registration_path(resource_name) | ||
%br/ | ||
- if devise_mapping.recoverable? && controller_name != 'passwords' | ||
= link_to "Forgot your password?", new_password_path(resource_name) | ||
%br/ | ||
- if devise_mapping.confirmable? && controller_name != 'confirmations' | ||
= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) | ||
%br/ | ||
- if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' | ||
= link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) | ||
%br/ | ||
- if devise_mapping.omniauthable? | ||
- resource_class.omniauth_providers.each do |provider| | ||
= link_to "Sign in with #{provider.to_s.titleize}", omniauth_authorize_path(resource_name, provider) | ||
%br/ | ||
= link_to "Cadastre-se", new_registration_path(resource_name) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
%p | ||
%label='Data: ' | ||
%b=ticket.created_at | ||
%p | ||
%label='Responsável: ' | ||
%b=ticket.user.email | ||
%p | ||
%label='Status: ' | ||
%b=Ticket::Status[ticket.status - 0][0] | ||
%p | ||
Histórico: | ||
%ul | ||
-@comments.each do |comment| | ||
%li | ||
%b=comment.created_at.strftime('%d/%m/%Y %H:%M:%S') | ||
%br | ||
=comment.comment | ||
%p | ||
=link_to 'Voltar', tickets_url | ||
=' | ' | ||
=link_to 'Sair', destroy_user_session_url | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
%h2 Visualizar ticket | ||
|
||
- if @ticket | ||
= render :partial => 'view_ticket', :locals => {:ticket => @ticket} | ||
- else | ||
Ticket não encontrado | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,46 @@ | ||
# encoding: UTF-8 | ||
# This file is auto-generated from the current state of the database. Instead | ||
# of editing this file, please use the migrations feature of Active Record to | ||
# incrementally modify your database, and then regenerate this schema definition. | ||
# | ||
# Note that this schema.rb definition is the authoritative source for your | ||
# database schema. If you need to create the application database on another | ||
# system, you should be using db:schema:load, not running all the migrations | ||
# from scratch. The latter is a flawed and unsustainable approach (the more migrations | ||
# you'll amass, the slower it'll run and the greater likelihood for issues). | ||
# | ||
# It's strongly recommended to check this file into your version control system. | ||
|
||
ActiveRecord::Schema.define(:version => 20111007020150) do | ||
|
||
create_table "comments", :force => true do |t| | ||
t.integer "ticket_id" | ||
t.text "comment" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
create_table "tickets", :force => true do |t| | ||
t.integer "user_id" | ||
t.string "description" | ||
t.integer "status" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
create_table "users", :force => true do |t| | ||
t.string "email", :default => "", :null => false | ||
t.string "encrypted_password", :limit => 128, :default => "", :null => false | ||
t.integer "sign_in_count", :default => 0 | ||
t.datetime "current_sign_in_at" | ||
t.datetime "last_sign_in_at" | ||
t.string "current_sign_in_ip" | ||
t.string "last_sign_in_ip" | ||
t.string "password_salt" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
add_index "users", ["email"], :name => "index_users_on_email", :unique => true | ||
|
||
end | ||
# encoding: UTF-8 | ||
# This file is auto-generated from the current state of the database. Instead | ||
# of editing this file, please use the migrations feature of Active Record to | ||
# incrementally modify your database, and then regenerate this schema definition. | ||
# | ||
# Note that this schema.rb definition is the authoritative source for your | ||
# database schema. If you need to create the application database on another | ||
# system, you should be using db:schema:load, not running all the migrations | ||
# from scratch. The latter is a flawed and unsustainable approach (the more migrations | ||
# you'll amass, the slower it'll run and the greater likelihood for issues). | ||
# | ||
# It's strongly recommended to check this file into your version control system. | ||
|
||
ActiveRecord::Schema.define(:version => 20111007020150) do | ||
|
||
create_table "comments", :force => true do |t| | ||
t.integer "ticket_id" | ||
t.text "comment" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
create_table "tickets", :force => true do |t| | ||
t.integer "user_id" | ||
t.string "description" | ||
t.integer "status" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
create_table "users", :force => true do |t| | ||
t.string "email", :default => "", :null => false | ||
t.string "encrypted_password", :limit => 128, :default => "", :null => false | ||
t.integer "sign_in_count", :default => 0 | ||
t.datetime "current_sign_in_at" | ||
t.datetime "last_sign_in_at" | ||
t.string "current_sign_in_ip" | ||
t.string "last_sign_in_ip" | ||
t.string "password_salt" | ||
t.datetime "created_at" | ||
t.datetime "updated_at" | ||
end | ||
|
||
add_index "users", ["email"], :name => "index_users_on_email", :unique => true | ||
|
||
end |