[Vtigercrm-developers] Correct way to all permitted entity modules?
Alan Lord
alanslists at gmail.com
Tue Feb 18 11:11:03 GMT 2020
Just FYI, adding "owner" to the fieldTypeList array does improve things
but I stlll have ModComments, SMSNotifier and PBXManager.
Al
On 18/02/2020 11:00, Alan Lord wrote:
> In a custom module I am developing I want to get a list of all permitted
> entity modules for the current_user.
>
> Using vtws_listtypes and filtering on types with isEntity = 1 is a bit
> rubbish to be honest:
>
> [0] => Campaigns
> [1] => Invoice
> [2] => SalesOrder
> [3] => PurchaseOrder
> [4] => Quotes
> [5] => Faq
> [6] => Vendors
> [7] => PriceBooks
> [8] => Calendar
> [9] => Leads
> [10] => Accounts
> [11] => Contacts
> [12] => Potentials
> [13] => Products
> [14] => Documents
> [15] => Emails
> [16] => HelpDesk
> [17] => Events
> [18] => Users
> [19] => Services
> [20] => PBXManager
> [21] => ServiceContracts
> [22] => SMSNotifier
> [23] => ModComments
> [24] => ProjectMilestone
> [25] => ProjectTask
> [26] => Project
> [27] => Assets
>
> PriceBooks, Emails, Users. PBXManager, SMSNotifier and ModComments
> shouldn't really be in my list. Obviously I can hardcode to remove
> these, but, for example if another custom module was installed which was
> an Entity type but not really a "normal" module it would also be in this
> list which is not really what I am looking for.
>
> In the Vtiger_Module_Model the method getSearchableModules() appears to
> be much closer to what I want but this is not available via the server
> API...
>
>
> Al
>
> _______________________________________________
> http://www.vtiger.com/
>
More information about the vtigercrm-developers
mailing list