Move user related views to FAB Auth manager:

- List users
- Edit user
- Create user
- View user
"""
        Admin should have all the permissions, except the dag permissions.
        because Admin already has Dags permission.
        Add the missing ones to the table for admin.
        :return: None.
        """
        session = self.appbuilder.get_session
        dag_resources = session.query(Resource).filter(
            Resource.name.like(f"{permissions.RESOURCE_DAG_PREFIX}%")
        )
        resource_ids = [resource.id for resource in dag_resources]
        perms = session.query(Permission).filter(~Permission.resource_id.in_(resource_ids))
        perms = [p for p in perms if p.action and p.resource]
        admin = self.find_role("Admin")
        admin.permissions = list(set(admin.permissions) | set(perms))
        session.commit()
    def sync_roles(self) -> None: