如何在 SugarCRM 中有条件地隐藏详细信息 View 上的按钮?
具体细节:
假设在帐户模块中我想有条件地从详细 View 页面隐藏删除按钮, 那么我可以在哪里放置显示/隐藏的条件。
提前致谢。
最佳答案
您应该能够在/custom/modules/Account/metadata/detailviewdefs.php 中修改此内容
添加如下内容:
if (your condition) {
unset($viewdefs['Accounts']['DetailView']['templateMeta']['form']['buttons'][2])
//2 being the index of the DELETE button
}
然后您需要运行: 管理->修复->快速修复和重建
关于sugarcrm - 如何在 SugarCRM 中有条件地隐藏详细 View 上的按钮?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12364406/