As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
var carpeta = document; var doc; var i, j; var esta; var tipos = new Array(); var faltan = new Array(); var tiposDesc = new Array(); tipos[0] = "tdk:Solicitud1"; tipos[1] = "tdk:Solicitud2"; tipos[2] = "tdk:Solicitud3"; tipos[3] = "tdk:Solicitud4"; tipos[4] = "tdk:Fotocopias"; tiposDesc[0] = "Solicitud 1ra Hoja"; tiposDesc[1] = "Solicitud 2da Hoja"; tiposDesc[2] = "Solicitud 3ra Hoja"; tiposDesc[3] = "Solicitud 4ta Hoja"; tiposDesc[4] = "Fotocopia de DNI"; for (j = 0; j < tipos.length; j++) { esta = false; for (i = 0; i < carpeta.children.length; i++) { doc = carpeta.children; if(doc.isSubType(tipos[j])){ esta = true; } } if (!esta){ faltan[faltan.length] = tipos[j]; } } esta = false; for (i = 0; i < carpeta.children.length; i++) { doc = carpeta.children; if(doc.isSubType(tipos[4])){ if (doc.properties["tdk:Fotocopias-TipoDNI"] == "SI"){ esta = true; } } } if (!esta){ faltan[faltan.length] = tiposDesc[4]; } var carpetaFinal; if (faltan.length == 0){ carpetaFinal = space.childByNamePath("Sitios/empresa/documentLibrary/Empresa/Legajos_Revisar"); logger.log("Estan todos"); } else{ carpetaFinal = space.childByNamePath("Sitios/eadicard/documentLibrary/Empresa/Legajos_Incompletos"); carpeta.properties.description = "Faltan los siguientes tipos de documentos: " + faltan; logger.log("Faltan los siguientes tipos de documentos: " + faltan); } carpeta.move(carpetaFinal);