<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Cascade of INBOUND Rules are not working in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16151#M7128</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You can found a subtle bug in the scripting service Node class.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The issue is that if the script falls through to the 'else' case then the properties collection on the Node has not yet been initialised when it then calls document.save(). The reason it's working when you run the script by hand is that I would assume the document already has the aspect applied by then, so the 'if' case is executed instead which will work ok.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've fixed the issue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kevin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 31 May 2006 13:43:23 GMT</pubDate>
    <dc:creator>kevinr</dc:creator>
    <dc:date>2006-05-31T13:43:23Z</dc:date>
    <item>
      <title>Cascade of INBOUND Rules are not working</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16150#M7127</link>
      <description>Hi,I want to cascade some INBOUND Rule:- folder A (drop zone)&amp;nbsp; rule R1: import all incoming ACP files in folder B- folder B (incoming files)&amp;nbsp; rule R2: set a custom property to "new document"Steps:1) Using FTP, I post one ACP file in folder A.2) The rule 1 is well played, the ACP is imported&amp;nbsp;&amp;nbsp;&amp;nbsp; in th</description>
      <pubDate>Wed, 31 May 2006 12:50:29 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16150#M7127</guid>
      <dc:creator>sbroussi</dc:creator>
      <dc:date>2006-05-31T12:50:29Z</dc:date>
    </item>
    <item>
      <title>Re: Cascade of INBOUND Rules are not working</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16151#M7128</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You can found a subtle bug in the scripting service Node class.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The issue is that if the script falls through to the 'else' case then the properties collection on the Node has not yet been initialised when it then calls document.save(). The reason it's working when you run the script by hand is that I would assume the document already has the aspect applied by then, so the 'if' case is executed instead which will work ok.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've fixed the issue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kevin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 May 2006 13:43:23 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16151#M7128</guid>
      <dc:creator>kevinr</dc:creator>
      <dc:date>2006-05-31T13:43:23Z</dc:date>
    </item>
    <item>
      <title>Re: Cascade of INBOUND Rules are not working</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16152#M7129</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;FYI to get round the problem for now, change you script thus:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;&lt;BR /&gt;if (document != null)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp; // add the "myAspect" aspect and set the "stampStatus" to: "ToBeStamped"&lt;BR /&gt;&amp;nbsp;&amp;nbsp; if (document.hasAspect("corp:myAspect"))&lt;BR /&gt;&amp;nbsp;&amp;nbsp; {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; document.properties["corp:stampStatus"] = "ToBeStamped";&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; document.save();&lt;BR /&gt;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;&amp;nbsp; else&lt;BR /&gt;&amp;nbsp;&amp;nbsp; {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var props = new Array(1);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; props["corp:stampStatus"] = "ToBeStamped";&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; document.addAspect("corp:myAspect", props);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;}&lt;BR /&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;SPAN&gt;Moving the document.save() solves the problem as it is not required anyway after the addAspect() call.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kevin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 May 2006 17:12:49 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/cascade-of-inbound-rules-are-not-working/m-p/16152#M7129</guid>
      <dc:creator>kevinr</dc:creator>
      <dc:date>2006-05-31T17:12:49Z</dc:date>
    </item>
  </channel>
</rss>

