ACL question on in custom view and menu actions [bug?]

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • igrp
    Junior Member
    • May 2017
    • 18

    ACL question on in custom view and menu actions [bug?]

    Hi!

    I made a simple custom entity and custom list view for it (/client/ ... /list.js)
    within the list.js I add some buttons into menu.

    Under root user everything works very well, however under non-admin user - i still could see & manage my custom entity,
    but custom buttons are not displayed at all (however acl is set to 'view' )

    Code:
    Espo.define('custom:views/certificate/list', 'views/list', function (Dep) {
    
        //recordView: 'custom:views/certificate/record/list',
    
        return Dep.extend({
    
            setup: function () {
                Dep.prototype.setup.call(this);
    
                this.menu.actions.push({
                    name: 'printPDFCertificates',
                    label: 'Print PDF Certificate (on selected)',
                    action: 'printPDFCertificates',
                     acl: 'view'
                });
    
                this.menu.actions.push({
                    name: 'printPDFCertificatesForm',
                    label: 'Print PDF Certificate (blank form)',
                    action: 'printPDFCertificatesForm',
                     acl: 'view'
                });
            },
    
    ..
  • tanya
    Senior Member
    • Jun 2014
    • 4308

    #2
    Hello
    Use acl: "read" . And don't forget to clear the cache

    Comment

    • igrp
      Junior Member
      • May 2017
      • 18

      #3
      Tanya, Thanks a lot !
      By the way is the any documentation \ how-to on JS definitions used in Espo ?

      Comment

      • tanya
        Senior Member
        • Jun 2014
        • 4308

        #4
        Full existing documentation is here https://github.com/espocrm/documentation
        You can extend it as well

        Comment

        Working...