can-has-permission 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,14 @@
1
+ class CanHasPermissionCreatePermissions < ActiveRecord::Migration
2
+ def self.up
3
+ create_table :permission do |t|
4
+ t.string :name, :null => false
5
+ t.timestamps
6
+ end
7
+ add_index :permission, :name, :unique => true
8
+ end
9
+
10
+ def self.down
11
+ remove_index :permission, :name
12
+ drop_table :permission
13
+ end
14
+ end
@@ -0,0 +1,14 @@
1
+ class CanHasPermissionCreateRoles < ActiveRecord::Migration
2
+ def self.up
3
+ create_table :roles do |t|
4
+ t.string :name, :null => false
5
+ t.timestamps
6
+ end
7
+ add_index :roles, :name, :unique => true
8
+ end
9
+
10
+ def self.down
11
+ remove_index :roles, :name
12
+ drop_table :roles
13
+ end
14
+ end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: can-has-permission
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 31
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 3
10
- version: 0.2.3
9
+ - 4
10
+ version: 0.2.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Chris Rode
@@ -45,7 +45,9 @@ files:
45
45
  - generators/can_has_permission_generator.rb
46
46
  - generators/templates/can_has_permission_create_anonymous.rb
47
47
  - generators/templates/can_has_permission_create_permission_maps.rb
48
+ - generators/templates/can_has_permission_create_permissions.rb
48
49
  - generators/templates/can_has_permission_create_role_maps.rb
50
+ - generators/templates/can_has_permission_create_roles.rb
49
51
  - lib/can-has-permission.rb
50
52
  - lib/can-has-permission/anonymous.rb
51
53
  - lib/can-has-permission/permission.rb