Package jease.cms.domain

Examples of jease.cms.domain.Role


    }
  }

  private void setupRoles() {
    if (Database.query(Role.class).isEmpty()) {
      Role administrator = new Role();
      administrator.setName(I18N.get("Administrator"));
      administrator.setAdministrator(true);
      administrator.setTypes(Contents.getClassNamesForAvailableTypes());
      Database.save(administrator);

      Role editor = new Role();
      editor.setName(I18N.get("Editor"));
      editor.setTypes(Functors.filter(
          Contents.getClassNamesForAvailableTypes(),
          new Predicate<String>() {
            public boolean test(String type) {
              return !(type.equals(Factory.class.getName())
                  || type.equals(Script.class.getName()) || type
View Full Code Here


    }
  }

  private void setupAdministrator() {
    if (Users.queryAdministrators().isEmpty()) {
      Role role = Database.queryUnique(Role.class, new Predicate<Role>() {
        public boolean test(Role role) {
          return role.getName().equals(I18N.get("Administrator"));
        }
      });
      final User administrator = new User();
      administrator.setRole(role);
      administrator.setRoots(new Folder[] { (Folder) Nodes.getRoot() });
View Full Code Here

import jfix.zk.ObjectTableModel;

public class TableModel extends ObjectTableModel<Role> {

  public Role newObject() {
    return new Role();
  }
View Full Code Here

TOP

Related Classes of jease.cms.domain.Role

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.