Allow user with only contact_view permission to click on contact record to view numbers etc. (#5153)
* Update contacts.php Added contact_view permission to allow users with only contact view to open contact record to see numbers addresses etc. See also update to contact_edit.php to remove save buttons if user only has contact view. * Update contact_edit.php Added permissions to only show save button if user has permissions contact_add or contact_edit. This is in conjunction with the update to contacts.php
This commit is contained in:
@@ -495,7 +495,9 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
echo button::create(['type'=>'button','label'=>$text['button-save'],'icon'=>$_SESSION['theme']['button_icon_save'],'style'=>($action != 'update' ?: 'margin-left: 15px;'),'collapse'=>'hide-sm-dn','onclick'=>"document.getElementById('frm').submit();"]);
|
||||
if (permission_exists('contact_edit') || permission_exists('contact_add')) {
|
||||
echo button::create(['type'=>'button','label'=>$text['button-save'],'icon'=>$_SESSION['theme']['button_icon_save'],'style'=>($action != 'update' ?: 'margin-left: 15px;'),'collapse'=>'hide-sm-dn','onclick'=>"document.getElementById('frm').submit();"]);
|
||||
}
|
||||
echo " </div>\n";
|
||||
echo " <div style='clear: both;'></div>\n";
|
||||
echo "</div>\n";
|
||||
@@ -858,4 +860,4 @@
|
||||
//include the footer
|
||||
require_once "resources/footer.php";
|
||||
|
||||
?>
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user