Hi,
I was wondering how can I get the values of the properties I've created on a custom aspect from a JS script that will be executed by a rule.
So, for example, I have the mc:refinterna aspect which has three properties: ambito, ano and ultimonumero. I've added this aspect to a space and I want to retrieve the three properties from a script and change the name of the document I'm uploading based on those properties.
Here is my script:
ambito = space.properties["refinterna:ambito];
ano = space.properties["refinterna:ano];
ultimonumero = space.properties["refinterna:ultimonumero];
document.name = ambito + "_" + ano + "_" + ultimonumero + ".pdf";
document.save()
When I upload a document it is saved as null_null_null.pdf, so clearly I'm not referencing the properties correctly.
Can anyone please help me with this?
Regards,
Pedro