08-04-2007 01:39 PM
08-04-2007 01:44 PM
08-05-2007 12:13 PM
08-06-2007 05:54 AM
08-06-2007 05:57 AM
08-07-2007 07:11 AM
08-07-2007 01:51 PM
01-09-2008 08:27 AM
script: {
var sandbox = args.sb;
var form = args.form;
var path = url.extension;
var storeRoot = avm.lookupStore(sandbox);
var folder = storeRoot.lookupNode("ROOT/" + path);
var files = folder.children;
var updated = new Array();
for (var i=0; i<files.length;i++){
var file = files[i];
if (file.isDocument && file.properties.content.mimetype == "text/xml"){
// add aspect to associate the xml file with its form
if (!hasAspect(file.aspects, "{http://www.alfresco.org/model/wcmappmodel/1.0}forminstancedata")){
var props = new Array(2);
props["{http://www.alfresco.org/model/wcmappmodel/1.0}parentformname"] = form;
props["{http://www.alfresco.org/model/wcmappmodel/1.0}originalparentpath"] = file.parentPath;
file.addAspect("{http://www.alfresco.org/model/wcmappmodel/1.0}forminstancedata", props);
updated[updated.length] = file;
}
}
}
model.folder = folder;
model.updated = updated;
}
function hasAspect(aspects, aspect){
if (aspects.length == undefined){
aspects = aspects.toArray();
}
for (var i=0; i< aspects.length; i++){
if (aspects[i] == aspect){
return true;
}
}
return false;
}
01-10-2008 05:20 AM
02-13-2008 06:14 PM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.