<type name="custom:proforma">
<title>Proforma</title>
<parent>cm:content</parent></type>
for (var i = 0; i < bpm_package.children.length; i++)
{
if (bpm_package.children[i].hasAspect("custom:proforma"))
{
var document= bpm_package.children[i];
var workflow = actions.create("start-workflow");
workflow.parameters.workflowName = "jbpm$Process3";
workflow.parameters["bpm:groupAssignee"] ="Adquisiciones";
workflow.parameters["bpm:workflowDescription"] =bpm_package.children[i].name;
workflow.execute(document);
}
}
El problema es que no me reconoce el bpm_package.children.hasAspect("customroforma") por lo que necesito consejo.if (bpm_package.children[i].type == "{Namespace de custom}proforma")
No sé cual es el FQN (fully qualified qname) de tu tipo, pues es el namspace junto con el nombre del tipo (y solo muestras en el ejemplo el prefijo junto con el nombre del tipo). Si el namespace fuera "http://www.alfresco.org/model/content/1.0" el fqn sería: {http://www.alfresco.org/model/content/1.0}proforma.
for (var i = 0; i < bpm_package.children.length; i++)
{
if (bpm_package.children[i].type == "{custom.model}proforma")
{
ddd = ddd+1;
}
}
Content from pre 2016 and from language groups that have been closed.
Content is read-only.
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.