mirror of
https://github.com/internetee/registry.git
synced 2025-08-02 16:02:03 +02:00
Lock down the controllers
This commit is contained in:
parent
3045c08b3e
commit
3b1e632ab7
36 changed files with 166 additions and 97 deletions
|
@ -3,4 +3,10 @@ class Role < ActiveRecord::Base
|
|||
# rubocop: disable Rails/HasAndBelongsToMany
|
||||
has_and_belongs_to_many :rights
|
||||
# rubocop: enbale Rails/HasAndBelongsToMany
|
||||
|
||||
validates :code, uniqueness: true
|
||||
|
||||
def to_s
|
||||
code
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue