Announcement

Collapse
No announcement yet.

How to disable Action Menu while creating custom module (extension) ?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to disable Action Menu while creating custom module (extension) ?

    Hi,
    I have created one custom module (extension). Now for this module i need to set custom permission like. Only System User can add, edit and delete the entity data while other user who just logged in the system can just read or see the data. so how can i set this thing in extension by default.

  • #2
    You can add this possibility in the Controller
    PHP Code:
    public function actionUpdate($params$data$request)
    {
        if (!
    $this->getUser()->isAdmin()) {
            throw new 
    \Espo\Core\Exceptions\Forbidden();
        }

    Job Offers and Requests

    Comment


    • #3
      You can also define Roles in metadata > app.acl
      "solid" section. Set all to no.

      Comment

      Working...
      X