set up rails
This commit is contained in:
parent
3854b1edfe
commit
1e2aecc21c
138 changed files with 9829 additions and 53 deletions
3
app/models/application_record.rb
Normal file
3
app/models/application_record.rb
Normal file
|
@ -0,0 +1,3 @@
|
|||
class ApplicationRecord < ActiveRecord::Base
|
||||
self.abstract_class = true
|
||||
end
|
3
app/models/authorized_application.rb
Normal file
3
app/models/authorized_application.rb
Normal file
|
@ -0,0 +1,3 @@
|
|||
class AuthorizedApplication < ApplicationRecord
|
||||
belongs_to :user
|
||||
end
|
0
app/models/concerns/.keep
Normal file
0
app/models/concerns/.keep
Normal file
9
app/models/user.rb
Normal file
9
app/models/user.rb
Normal file
|
@ -0,0 +1,9 @@
|
|||
class User < ApplicationRecord
|
||||
# Include default devise modules. Others available are:
|
||||
# :confirmable, :lockable, :timeoutable, :trackable and :omniauthable
|
||||
devise :database_authenticatable, :registerable,
|
||||
:recoverable, :rememberable, :validatable,
|
||||
:trackable, :confirmable
|
||||
|
||||
has_many :authorized_applications, dependent: :destroy
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue