cancel
Showing results for 
Search instead for 
Did you mean: 

programatically declare a record?

gnyce
Champ in-the-making
Champ in-the-making
Can  you programatically declare a file as a Record?  I managed to to create a content rule (via javascript 'execute script') to populate the required metadata fields - and want to see about taking it to the next step, for a bulk upload.  Is that do-able via javascript?  Or, should I instead make it part of the content rule - I see that there is a "declare record" within the rules - as long as it executes in sequence, that is - e.g. metadata rules fire first.

thanks
1 REPLY 1

croc
Champ in-the-making
Champ in-the-making
Hi,

Since you said you are able to populate the required metadata, I think you just need to run onActionDeclare action which is found under dod5015-actions.js. I am sure you also need to add the script inside you <filename>.get.head.ftl like

<@script type="text/javascript" src="${page.url.context}/res/components/documentlibrary/dod5015-actions.js"></@script>

I think that should do it.

Thnx,
Croc