Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X
Hi
I am building a network based on a 'CustomerName' user extension of a user that is accessing a mashup (this is bound in the Data tab correctly).
However on my script I have attempted to add runtime permissions to the network I want to display but when I test this service I get an error saying:
Wrapped java.lang.Exception: This entity does not support property permissions Cause: This entity does not support property permissions
This is my script:
var NetworkName = "Atlas.Customer." + CustomerName + ".Network";
var params = {
principal: CustomerName /* STRING */,
allow: true /* BOOLEAN */,
resource: "*" /* STRING */,
type: "PropertyRead" /* STRING */,
principalType: "Group" /* STRING */
};
// no return
Networks[NetworkName].AddRunTimePermission(params);
Note: This entity was created beforehand programmatically. I know Things have to be enabled to use runtime permissions but I cannot find a way to do that with Networks.
Any help you could give me would be highly appreciated.
Many Thanks
Ashley
For Networks all that is needed/provided is to secure the services, if there are nodes that a user can see or can not see, either you use Visibility on the Things or you use a custom service to retrieve the network information.
Generally we recommend wrapped services for anything that would otherwise rely on the base services, an exceptions would be valuestream interactions.
Hi Pai
Many thanks for the swift response.
Unfortunately this doesn't really solve the problem we're having.
We have created a network which currently contains one parent node and 3 child nodes. (User has full permissions on all NODES but not the Network Entity itself). At runtime we have a network connected to a tree widget in a mashup. At runtime however this tree will not populate.
After assigning runtime permissions manually in the composer the tree then populates at runtime.
We have written a service (see above) to automatically assign the runtime permissions on the network entity which then gave us the error you can see above.
What we want to achieve is the tree being visible at runtime without the need to manually assign runtime permissions in the composer.
Thanks
Ashley
How are you retrieving the nodes? Are you using a wrapped service? That would be the best practice, vs. invoking services directly.
I would approach this as follows.
1. apply the system user to all runtime services of all networks
2. create a wrapped service that retrieves the appropriate nodes
3. set visibility security on any nodes that need to be hidden, beyond what you want to do programmatically
If that is not working, check your application log, but I don't believe you need any property read permissions to make this work.
Is there any possibility we could set up some kind of remote connection/WebEx/Skype for Business meeting so I could show my screen and talk through the problem I have or is this not feasible?
Hi Ashley I would recommend contacting Technical Support for that.