Add/Manage/Delete record references. Also updates to document picker to show correct icons and filter out specific types. TODO: documentpicker should probably filter out current record and already referenced records to avoid cyclic and duplicate errors when adding new references

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@16059 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Lawrence Carvalho
2009-09-03 09:16:05 +00:00
parent f7e7334e83
commit 288f42fec6

View File

@@ -46,7 +46,24 @@ function main()
var query = "+PARENT:\"" + parent.nodeRef + "\""; var query = "+PARENT:\"" + parent.nodeRef + "\"";
if (argsFilterType != null) if (argsFilterType != null)
{ {
query += " +TYPE:\"" + argsFilterType + "\""; //map short name to long name
var types = {
'rma:dispositionSchedule': '{http://www.alfresco.org/model/recordsmanagement/1.0}dispositionSchedule',
'rma:dispositionActionDefinition': '{http://www.alfresco.org/model/recordsmanagement/1.0}dispositionActionDefinition',
'rma:dispositionAction': '{http://www.alfresco.org/model/recordsmanagement/1.0}dispositionAction',
'rma:hold':'{http://www.alfresco.org/model/recordsmanagement/1.0}hold',
'rma:transfer':'{http://www.alfresco.org/model/recordsmanagement/1.0}transfer'
};
var filterTypes = argsFilterType.split(',');
for (var i=0,len=filterTypes.length; i<len; i++)
{
var identifier = filterTypes[i];
if (types[identifier])
{
query += " -TYPE:\"" + types[identifier] + "\"";
}
}
} }
if (logger.isLoggingEnabled()) if (logger.isLoggingEnabled())