Best practise - privacy rules

Hi, I’m curious what the best way is.

I’ve got a data type called “position” and I want to make a rule, that only members of my ‘company’ can see/edit them.

Now the problem:
The data structure is as following:
company has a list of type ‘A’ and a list of type ‘B’. Every item of both lists have themselves a list of ‘positions’.

Since I can’t check (in the privacy rule) whether the ‘current position’ is contained by at least one item of the 2 lists, my idea was to add a field ‘positions’ in company, where all items are stored. Then i would only check, whether it is contained in this company’s positions.

BUT, I’ve read, that this type of lists is only allowed till 10.000 items in a 1:n relationship which I might reach at some time. What is the best way?
I’ve though about a link-data type with 2 fields ‘company’ and ‘position’, but in the privacy rules I can’t ‘Do a search for’ these Link-items…

Hope it’s understandable :slight_smile:

Thanks!

Hi there, @robin_rob96… if I understand your post correctly, it seems like you could add a company field on the position data type, and you’d be good to go by constructing a privacy rule that says when This position's company is Current User's company. True, with that structure in place, you have to add the company to each thing in the position data type, but unless I am missing something, it really does seem like the most “direct” route.

Hope this helps.

Best…
Mike

1 Like

Well, Thats an easy way… could’ve come up with it on my own.
Thx
Robin

1 Like

Well, then, great job solving your own issue. :wink:

1 Like

I wish I had :smiley: Thanks!

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.