Exemple #1
0
 def _sqlChanges(self):
     from Phoenix.Models import Privilege, Repository, Role
     Member.createTable(ifNotExists=True)
     Role.createTable(ifNotExists=True)
     Repository.createTable(ifNotExists=True)
     Privilege.createTable(ifNotExists=True)
     Hook.createTable(ifNotExists=True)
     Key.createTable(ifNotExists=True)
Exemple #2
0
 def _sqlChanges(self):
     from Phoenix.Models import Privilege, Repository, Role
     Member.createTable(ifNotExists=True)
     Role.createTable(ifNotExists=True)
     Repository.createTable(ifNotExists=True)
     Privilege.createTable(ifNotExists=True)
     Hook.createTable(ifNotExists=True)
     Key.createTable(ifNotExists=True)
Exemple #3
0
 def role(cls, gid):
     from Phoenix.Models import Role
     if Role.get(gid):
         return True
     return False
Exemple #4
0
 def addRole(self, name):
     from Phoenix.Models import Role
     role = Role(name=name, member=self)
     return role
Exemple #5
0
 def role(cls, gid):
     from Phoenix.Models import Role
     if Role.get(gid):
         return True
     return False