Zum Hauptinhalt gehen

Unable to change the state of "Define Permission" in CMS_INPUT_PERMISSION

Kommentare

1 Kommentar

  • Zendesk API User
    Author: marro - 1/24/2013 9:24

    Hello Vasandharaj,

    first of all you have to lock the StoreElement you want to edit:

    elem = context.getStoreElement();

    elem.setLock(true);

    Then you have to retrieve the FormData, apply your changes and set the FormData back to the StoreElement. You want to set inherited to true to uncheck the checkbox.

    formdata = elem.getMetaFormData();

    roles = formdata.get(context.getProject().getMasterLanguage (),"portal_roles").get();

    roles.setInherited(true);

    elem.setMetaFormData(formdata);

    The last step is to save and unlock the StoreElement:

    elem.save();

    elem.setLock(false);

    After refreshing the element in the GUI you will see your changes.

    Regards,

    Donato

    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.