Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » Content Authors

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 1086 Views
  • tvachon
    Avatar
    Community Member
    3 Posts

    Content Authors Link to this post

    Hi folks

    I feel like I'm missing something basic here. Please let me know if this has been covered somewhere, a fairly decent amount of Googling forum reading hasn't turned up anything yet.

    We'd like to have several users who have permission to only edit certain pages on our site (say, our job postings site). When I create user accounts via the security tab and give them the appropriate permissions (that is, add them to the Job Posting Editor group and configure the Job Posting page to be editable only by people in the Job Posting Editor group) they aren't able to log into the admin UI (I go to http://server/admin, log in, and get "I'm sorry, but you can't access that part of the CMS. ").

    I've also tried editing the PHP underlying this page like:

    <?php

    class CareerPage extends Page {

    static $db = array(
    );
    static $has_one = array(
    );
    static $allowed_children = array('JobPosting');

    function canEdit() {
    return Permission::check("ADD_JOB_POSTING");
    }

    }

    class CareerPage_Controller extends Page_Controller implements PermissionProvider {
    function providePermissions() {
    return array(
    "ADD_JOB_POSTING" => "Add job postings",
    );
    }
    }

    ?>

    with the same result.

    It seems like the problem is that I haven't given this group appropriate permission to even view the site tree. It's fine if they can do this as long as they can't edit pages we haven't specifically given them access to. I've tried giving this group a number of permissions from the Security tab, to no avail.

    Any thoughts?

    Thanks in advance!

  • tvachon
    Avatar
    Community Member
    3 Posts

    Re: Content Authors Link to this post

    Ah, believe I've solved my own problem. I suspect I was neglecting to hit the "save" button at the bottom of the page when assigning new permissions before. For the record, it looks like the problem was that I hadn't given these users "CMSMain" permission.

    thanks!

    1086 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.