No announcement yet.

Field Level Security

  • Filter
  • Time
  • Show
Clear All
new posts

  • Field Level Security

    I would love to see field level security, such as can view the field,can update the field, ect, ect, by user and group.

  • #2
    There is no reason why you cant do this in scriptcase, you have the ability to know the groups the logged in user belongs to and of course the users themselves.
    You can turn off and on fields upon validation.
    Check out these macros:
    sc_field_disabled ("Field_Name = True/False", "Parameter")
    sc_field_display ({My_Field}, on/off)

    As some additional help I just tested the process:
    The following code will look up a specific group and if the user is within that group it will disable a field.
    I added additional code to show that if the user logged in is within that group you can re-enable the field by the users login:

    Understandable I hope:

    * Check for specific group

    // Check for record
    $check_sql = "SELECT login"
    . " FROM intranet.prismreporting_sec_users_groups"
    . " WHERE group_id = '1'";

    sc_lookup(rs, $check_sql);

    if (isset({rs[0][0]})) // Row found
    $security = 'off';

    else // No row found
    $security = 'on';


    if ($security == 'off')
    {echo 'This is group I want to disable fields for';
    sc_field_disabled ("bat_invoice = True");
    {echo 'This is another group';
    sc_field_disabled ("bat_invoice = False");

    if ([usr_login] == 'kdriscoll')
    {echo 'This is Kevin';
    sc_field_disabled ("bat_invoice = False");

    Last edited by Kdriscoll; 01-22-2016, 01:30 PM.


    • #3
      Thank You very much for this it helps a lot, I was hoping they could add like check boxes to the field to be able to this in future releases.