filtering order by salesperson

julkifli33julkifli33 Member Posts: 1,087
hi all...
can we filtering order by sales person
for example salesperson A can only open the order which are created by himself,
salesperson B can only open the order which are created by himself... and so on
but their manager can open order from salesperson A and B
but cannot open salesperson C and D which are not his staffs

do we have standard function from NAV like that?
thanks

Comments

  • mohana_cse06mohana_cse06 Member Posts: 5,504
    There is no standard functionality like this..you need to customize..

    something like
    IF UserMgt.GetSalesPersFilter <> '' THEN BEGIN
      FILTERGROUP(2);
      SETRANGE("Sales Person",UserMgt.GetSalesPersFilter);
      FILTERGROUP(0);
    END;
    
  • julkifli33julkifli33 Member Posts: 1,087
    There is no standard functionality like this..you need to customize..

    something like
    IF UserMgt.GetSalesPersFilter <> '' THEN BEGIN
      FILTERGROUP(2);
      SETRANGE("Sales Person",UserMgt.GetSalesPersFilter);
      FILTERGROUP(0);
    END;
    
    that's what i'm afraid of...
    so every page and table should add customization like this
  • mohana_cse06mohana_cse06 Member Posts: 5,504
    julkifli33 wrote:
    There is no standard functionality like this..you need to customize..

    something like
    IF UserMgt.GetSalesPersFilter <> '' THEN BEGIN
      FILTERGROUP(2);
      SETRANGE("Sales Person",UserMgt.GetSalesPersFilter);
      FILTERGROUP(0);
    END;
    
    that's what i'm afraid of...
    so every page and table should add customization like this

    Unfortunately, Yes :cry:
  • julkifli33julkifli33 Member Posts: 1,087
    julkifli33 wrote:
    There is no standard functionality like this..you need to customize..

    something like
    IF UserMgt.GetSalesPersFilter <> '' THEN BEGIN
      FILTERGROUP(2);
      SETRANGE("Sales Person",UserMgt.GetSalesPersFilter);
      FILTERGROUP(0);
    END;
    
    that's what i'm afraid of...
    so every page and table should add customization like this

    Unfortunately, Yes :cry:

    it must be a huge customization then
    i though we can create new role or something like that
    by the way thanks for your share
  • jglathejglathe Member Posts: 639
    Hi,

    "huge" is something else... :mrgreen: Just add a filter in OnOpenForm and OnOpenPage. In User Setup, add a Field for the Team leader. Less than a day, even with written documentation.

    With best regards

    Jens
  • mkeurmkeur Member Posts: 13
    What you can do is create a role per salesperson.
    Within these roles add table Sales Header with a value in the Column "Security Filter". The value should be "Salesheader: Salesperson=[here you enter the code of the salesperson] "
    I guess this should work
  • julkifli33julkifli33 Member Posts: 1,087
    ok thanks for the advice
Sign In or Register to comment.