Merged more conflicts
This commit is contained in:
parent
d3b8ad7222
commit
0bc5858101
3
Gemfile
3
Gemfile
|
@ -23,13 +23,10 @@ end
|
|||
|
||||
gem 'jquery-rails'
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
gem 'devise'
|
||||
|
||||
gem "cancan"
|
||||
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
# To use ActiveModel has_secure_password
|
||||
# gem 'bcrypt-ruby', '~> 3.0.0'
|
||||
|
||||
|
|
18
Gemfile.lock
18
Gemfile.lock
|
@ -29,13 +29,8 @@ GEM
|
|||
i18n (~> 0.6)
|
||||
multi_json (~> 1.0)
|
||||
arel (3.0.2)
|
||||
<<<<<<< HEAD
|
||||
builder (3.0.0)
|
||||
=======
|
||||
bcrypt-ruby (3.0.1)
|
||||
builder (3.0.0)
|
||||
cancan (1.6.8)
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
coffee-rails (3.2.2)
|
||||
coffee-script (>= 2.2.0)
|
||||
railties (~> 3.2.0)
|
||||
|
@ -43,14 +38,11 @@ GEM
|
|||
coffee-script-source
|
||||
execjs
|
||||
coffee-script-source (1.3.3)
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
devise (2.1.1)
|
||||
bcrypt-ruby (~> 3.0)
|
||||
orm_adapter (~> 0.1)
|
||||
railties (~> 3.1)
|
||||
warden (~> 1.2.1)
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
erubis (2.7.0)
|
||||
execjs (1.4.0)
|
||||
multi_json (~> 1.0)
|
||||
|
@ -68,10 +60,7 @@ GEM
|
|||
treetop (~> 1.4.8)
|
||||
mime-types (1.19)
|
||||
multi_json (1.3.6)
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
orm_adapter (0.1.0)
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
polyglot (0.3.3)
|
||||
rack (1.4.1)
|
||||
rack-cache (1.2)
|
||||
|
@ -119,23 +108,16 @@ GEM
|
|||
uglifier (1.2.7)
|
||||
execjs (>= 0.3.0)
|
||||
multi_json (~> 1.3)
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
warden (1.2.1)
|
||||
rack (>= 1.0)
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
<<<<<<< HEAD
|
||||
coffee-rails (~> 3.2.1)
|
||||
=======
|
||||
cancan
|
||||
coffee-rails (~> 3.2.1)
|
||||
devise
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
jquery-rails
|
||||
json
|
||||
rails (= 3.2.3)
|
||||
|
|
|
@ -1,10 +1,7 @@
|
|||
class DoorLogsController < ApplicationController
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
authorize_resource
|
||||
before_filter :authenticate_user!
|
||||
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
# GET /door_logs
|
||||
# GET /door_logs.json
|
||||
def index
|
||||
|
|
|
@ -1,10 +1,4 @@
|
|||
class UsersController < ApplicationController
|
||||
<<<<<<< HEAD
|
||||
# GET /users
|
||||
# GET /users.json
|
||||
def index
|
||||
@users = User.all
|
||||
=======
|
||||
load_and_authorize_resource
|
||||
before_filter :authenticate_user!
|
||||
|
||||
|
@ -13,7 +7,6 @@ class UsersController < ApplicationController
|
|||
def index
|
||||
#@users = User.all
|
||||
#authorize! :read, @users
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
respond_to do |format|
|
||||
format.html # index.html.erb
|
||||
|
@ -24,11 +17,7 @@ class UsersController < ApplicationController
|
|||
# GET /users/1
|
||||
# GET /users/1.json
|
||||
def show
|
||||
<<<<<<< HEAD
|
||||
@user = User.find(params[:id])
|
||||
=======
|
||||
#@user = User.find(params[:id])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
respond_to do |format|
|
||||
format.html # show.html.erb
|
||||
|
@ -38,11 +27,7 @@ class UsersController < ApplicationController
|
|||
|
||||
# PUT /users/1/upload
|
||||
def upload
|
||||
<<<<<<< HEAD
|
||||
@user = User.find(params[:id])
|
||||
=======
|
||||
#@user = User.find(params[:id])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
@upload_result = @user.upload_to_door
|
||||
|
||||
respond_to do |format|
|
||||
|
@ -64,11 +49,7 @@ class UsersController < ApplicationController
|
|||
# GET /users/new
|
||||
# GET /users/new.json
|
||||
def new
|
||||
<<<<<<< HEAD
|
||||
@user = User.new
|
||||
=======
|
||||
#@user = User.new
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
respond_to do |format|
|
||||
format.html # new.html.erb
|
||||
|
@ -78,21 +59,13 @@ class UsersController < ApplicationController
|
|||
|
||||
# GET /users/1/edit
|
||||
def edit
|
||||
<<<<<<< HEAD
|
||||
@user = User.find(params[:id])
|
||||
=======
|
||||
#@user = User.find(params[:id])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
end
|
||||
|
||||
# POST /users
|
||||
# POST /users.json
|
||||
def create
|
||||
<<<<<<< HEAD
|
||||
@user = User.new(params[:user])
|
||||
=======
|
||||
#@user = User.new(params[:user])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
respond_to do |format|
|
||||
if @user.save
|
||||
|
@ -108,11 +81,7 @@ class UsersController < ApplicationController
|
|||
# PUT /users/1
|
||||
# PUT /users/1.json
|
||||
def update
|
||||
<<<<<<< HEAD
|
||||
@user = User.find(params[:id])
|
||||
=======
|
||||
#@user = User.find(params[:id])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
respond_to do |format|
|
||||
if @user.update_attributes(params[:user])
|
||||
|
@ -128,11 +97,7 @@ class UsersController < ApplicationController
|
|||
# DELETE /users/1
|
||||
# DELETE /users/1.json
|
||||
def destroy
|
||||
<<<<<<< HEAD
|
||||
@user = User.find(params[:id])
|
||||
=======
|
||||
#@user = User.find(params[:id])
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
@user.destroy
|
||||
|
||||
respond_to do |format|
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
class User < ActiveRecord::Base
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
# Include default devise modules. Others available are:
|
||||
# :token_authenticatable, :confirmable,
|
||||
# :lockable, :timeoutable and :omniauthable
|
||||
|
@ -9,7 +7,6 @@ class User < ActiveRecord::Base
|
|||
|
||||
# Setup accessible (or protected) attributes for your model
|
||||
attr_accessible :email, :password, :password_confirmation, :remember_me
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
require 'open-uri'
|
||||
|
||||
attr_accessible :card_id, :card_number, :card_permissions, :name
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<<<<<<< HEAD
|
||||
<p id="notice"><%= notice %></p>
|
||||
=======
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
<p>
|
||||
<b>Download results:</b>
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<<<<<<< HEAD
|
||||
<p id="notice"><%= notice %></p>
|
||||
=======
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
<p>
|
||||
<b>Key:</b>
|
||||
|
|
|
@ -10,15 +10,11 @@
|
|||
<div id="header">
|
||||
<a href="/users">Users</a>
|
||||
<a href="/door_logs">Logs</a>
|
||||
<<<<<<< HEAD
|
||||
</div>
|
||||
=======
|
||||
<%= link_to 'Profile', edit_user_registration_path if user_signed_in? %>
|
||||
<%= link_to 'Sign out', destroy_user_session_path, :method => :delete if user_signed_in? %>
|
||||
</div>
|
||||
<p class="notice"><%= notice %></p>
|
||||
<p class="alert"><%= alert %></p>
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
<%= yield %>
|
||||
|
||||
</body>
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<<<<<<< HEAD
|
||||
<p id="notice"><%= notice %></p>
|
||||
=======
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
<p>
|
||||
<b>Name:</b>
|
||||
|
@ -23,10 +19,6 @@
|
|||
<%= @user.card_permissions %>
|
||||
</p>
|
||||
|
||||
<<<<<<< HEAD
|
||||
<%= link_to 'Upload to Door', upload_path(user) %>
|
||||
=======
|
||||
<%= link_to 'Upload to Door', upload_path(@user) %>
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
<%= link_to 'Edit', edit_user_path(@user) %> |
|
||||
<%= link_to 'Back', users_path %>
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<<<<<<< HEAD
|
||||
<p id="notice"><%= notice %></p>
|
||||
=======
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
<% if @upload_result %>
|
||||
<p>
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<<<<<<< HEAD
|
||||
<p id="notice"><%= notice %></p>
|
||||
=======
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
<p>
|
||||
<b>Upload results:</b>
|
||||
|
|
|
@ -34,9 +34,6 @@ Dooraccess::Application.configure do
|
|||
|
||||
# Expands the lines which load the assets
|
||||
config.assets.debug = true
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
|
||||
config.action_mailer.default_url_options = { :host => 'localhost:3000' }
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
end
|
||||
|
|
|
@ -14,12 +14,8 @@ Dooraccess::Application.configure do
|
|||
# Compress JavaScripts and CSS
|
||||
config.assets.compress = true
|
||||
|
||||
# Don't fallback to assets pipeline if a precompiled asset is missed
|
||||
<<<<<<< HEAD
|
||||
config.assets.compile = false
|
||||
=======
|
||||
# Fallback to assets pipeline if a precompiled asset is missed
|
||||
config.assets.compile = true
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
# Generate digests for assets URLs
|
||||
config.assets.digest = true
|
||||
|
|
|
@ -1,10 +1,7 @@
|
|||
Dooraccess::Application.routes.draw do
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
devise_for :users
|
||||
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
match 'users/upload_all' => 'users#upload_all', :as => :upload_all
|
||||
resources :users
|
||||
match 'users/:id/upload' => 'users#upload', :as => :upload
|
||||
|
@ -12,11 +9,8 @@ Dooraccess::Application.routes.draw do
|
|||
match 'door_logs/download' => 'door_logs#download', :as => :download
|
||||
resources :door_logs
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
root :to => "home#index"
|
||||
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
# The priority is based upon order of creation:
|
||||
# first created -> highest priority.
|
||||
|
||||
|
|
11
db/schema.rb
11
db/schema.rb
|
@ -10,11 +10,7 @@
|
|||
#
|
||||
# It's strongly recommended to check this file into your version control system.
|
||||
|
||||
<<<<<<< HEAD
|
||||
ActiveRecord::Schema.define(:version => 20120825041626) do
|
||||
=======
|
||||
ActiveRecord::Schema.define(:version => 20120904024426) do
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
|
||||
create_table "door_logs", :force => true do |t|
|
||||
t.string "key"
|
||||
|
@ -28,12 +24,6 @@ ActiveRecord::Schema.define(:version => 20120904024426) do
|
|||
t.integer "card_id"
|
||||
t.string "card_number"
|
||||
t.integer "card_permissions"
|
||||
<<<<<<< HEAD
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
=======
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.string "email", :default => "", :null => false
|
||||
|
@ -52,5 +42,4 @@ ActiveRecord::Schema.define(:version => 20120904024426) do
|
|||
add_index "users", ["email"], :name => "index_users_on_email", :unique => true
|
||||
add_index "users", ["reset_password_token"], :name => "index_users_on_reset_password_token", :unique => true
|
||||
|
||||
>>>>>>> 03d99741e5b661e63f6281115d2db333082a09b1
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user