- ?csdkZdklZdklZdklZdklZ dk l Z  dk l Z  defdYZ =e e ?d ZDed ZLd efd YZe ed ZedZdZdkTdkZdkZdkZdkZdk l Z dklZdklZdk lZdkl Z dkl!Z!dkZdk"Zdk#Z#dk$Z%dklZdklZdk&Z&de&_'dddddgZ(deeefdYZ).deeefdYZ*d eeefd!YZ+'d"eeefd#YZ,_d$Z-ed%Z.kd&Z/yd'd(Z0d)Z1d*Z2d+Z3d,Z4d-eeefd.YZ5d/eeefd0YZ6d1eeefd2YZ73d3Z86d4Z9=d5Z:Ad6Z;Id7Z<Qd8Z=Vd9Z>[d:Z?cd;Z@nd<ZAd=ZBd>ZCd?ZDd@ZEdAZFdBZGdCeeefdDYZHdEeeefdFYZIQdGZJVdHZKZdIZL^dJZMadKZNedLZOwdMklPZPl!Z!ydNZQdS(ON(sFolder(s SimpleItem(sPageTemplateFile(s PageTemplate(sClassSecurityInfo(sInitializeClasssOSAS_ShowOnlinecs tZ eZdZdZeidddZddZ"dZ 'd Z +d Z /d Z 2d Z 5d Z8dZRS(Ncs||_dS(sinitialize a new instanceN(sidsself(sselfsid((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__ssOSAS_ShowOnlinesViews index_htmlcs,tdi|}|SdS(s main views&Products/OSA_system/OSAS_ViewFiles.zptN(sPageTemplateFiles__of__sselfspt(sselfspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys index_htmlsics#t|d} |SdS(sload filesystemiN(s filesystem2sstartsk(sselfsstartsreloadsk((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetfilesystem2scs "#$t|}%|SdS(sget the filetreeN(sbrowsesstartsk(sselfsstartsk((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pystree"scs!'()t|id|SdS(s&generates navigation bar for viewfilessURLN(spath_to_link_viewsselfsREQUESTspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pyspath_to_link_view'scs+,-t|SdS(scheck if digilibN(s isdigilib2spath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isdigilib2+scs/0t|SdS(N(s changeNamesname(sselfsname((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys changeName/scs23t|SdS(N(s hasMetafilespath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys hasMetafile2scs56t|SdS(N(s getMetafilespath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys getMetafile5scsK89:|i|i||;|iii|idd|SdS(s%Oeffnen bzw. schlieen der SubfolderssURL1s?path=N(sselfstreespathstogglesfilesREQUESTsRESPONSEsredirect(sselfspathsfile((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys toggle_view8s(s__name__s __module__sClassSecurityInfossecuritys__init__s meta_typesdeclareProtecteds index_htmlsgetfilesystem2streespath_to_link_views isdigilib2s changeNames hasMetafiles getMetafiles toggle_view(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysOSAS_ShowOnline s           cs,?@Atdi|}B|SdS(s"interface for adding the OSAS_roots*Products/OSA_system/AddOSAS_ShowOnline.zptN(sPageTemplateFiles__of__sselfspt(sselfspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmanage_AddOSAS_ShowOnlineForm?scsPDEFt|}G|i||H|tj oI|idndS(sadd the OSAS_roots manage_mainN(sOSAS_ShowOnlinesidsnewObjsselfs _setObjectsRESPONSEsNonesredirect(sselfsidsRESPONSEsnewObj((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmanage_AddOSAS_ShowOnlineDs sOSAS_StoreOnlinecs;LtZdZMNeZPdZTdZVeiddWdZ\dZ fdZ kdd Z qd Z vd Z zd Z~d ZdZdZdZdZdZdZdZdZdZdZdZdZRS(s!Webfrontend fr das StoragesystemcsPQR||_dS(sinitialize a new instanceN(sidsself(sselfsid((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__PssOSAS_StoreOnlinesViews index_htmlcs,WXYtdi|}Z|SdS(s main views'Products/OSA_system/OSAS_StoreFiles.zptN(sPageTemplateFiles__of__sselfspt(sselfspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys index_htmlWscs<\]^tii|do`t|SndgSdS(sZeige Contextes /index.metaN(sosspathsexistss readContexts(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys readContexts\scs4fgitidtidd|iddS(s!rescale thumbs of imeages in paths{ssh nausikaa2.rz-berlin.mpg.de /usr/local/mpiwg/scripts/scaleomat.pl %s /mpiwg/temp/online/scaled/thumb 90 >> /tmp/sc.out &s/mpiwg/online/sspathN(sosspopensressubsselfsREQUEST(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys rescaleThumbsfsics#klnt|d}o|SdS(sload filesystemiN(s filesystem2sstartsk(sselfsstartsreloadsk((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetfilesystem2kscs qrst|}t|SdS(sget the filetreeN(sbrowsesstartsk(sselfsstartsk((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pystreeqscs!vwxt|id|SdS(s&generates navigation bar for viewfilessURLN(spath_to_link_storesselfsREQUESTspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pyspath_to_link_storevscsz{|t|SdS(scheck if digilibN(s isdigilib2spath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isdigilib2zscs~t|SdS(N(s changeNamesname(sselfsname((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys changeName~scst|SdS(N(s hasMetafilespath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys hasMetafilescst|SdS(N(s getMetafilespath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys getMetafilescsK|i|i|||iii|idd|SdS(s%Oeffnen bzw. schlieen der SubfolderssURL1s?path=N(sselfstreespathstogglesfilesREQUESTsRESPONSEsredirect(sselfspathsfile((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys toggle_viewscst||SdS(sTest ob Eintrag ein Folder istN(sisFoldersselfspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysisFolderscst||SdS(sTest ob Eintrag ein Folder istN(sisScannedDocumentsselfspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysisScannedDocumentscst||SdS(sTest ob Eintrag ein Folder istN(s isFullTextspaths folder_name(sselfspaths folder_name((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isFullTextscs,tdi|}|SdS(sadd a new paths&Products/OSA_system/OSAS_addFolder.zptN(sPageTemplateFiles__of__sselfspt(sselfspathspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys addFolderFormscstdtSdS(Ns%d.%m.%Y(sstrftimes localtime(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysdatescs)ti||||||SdS(s=add the folder to the filesystem and write the metadata filesN(s addFoldersselfspaths folder_names descriptionsarchive_creation_datescreator(sselfspaths folder_names descriptionsarchive_creation_datescreator((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys addFolderscsy/tiii|d}|i}Wnd}nX||ii d<||ii d<t di |}|SdS(sEditiere das Index Metafiles /index.metass indexmetaspathsProducts/OSA_system/editindexN( sxmlsdomsminidomsparsespathstoxmls indexmetasselfsREQUESTsSESSIONsPageTemplateFiles__of__s newtemplate(sselfspathsdoms newtemplates indexmeta((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys EditIndexs cs|iid o|id}n'|idi|_|id}t|iiddd}|i ||ii i |idd|iidSdS( s%Sichern der Aenderungen in Index.metas fileuploads indexmetaspaths /index.metaswsURL1s?path=N( sselfsREQUESTshas_keysnewtextsfilenames file_namesfilesSESSIONs indexmetas writelinessresponsesredirect(sselfsnewtexts indexmeta((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys EditIndex2s cs,tdi|}|SdS(snothings(Products/OSA_system/OSAS_addmetadata.zptN(sPageTemplateFiles__of__sselfspt(sselfspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys add_metafiles(s__name__s __module__s__doc__sClassSecurityInfossecuritys__init__s meta_typesdeclareProtecteds index_htmls readContextss rescaleThumbssgetfilesystem2streespath_to_link_stores isdigilib2s changeNames hasMetafiles getMetafiles toggle_viewsisFoldersisScannedDocuments isFullTexts addFolderFormsdates addFolders EditIndexs EditIndex2s add_metafile(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysOSAS_StoreOnlineLs2                   cs,tdi|}|SdS(s"interface for adding the OSAS_roots+Products/OSA_system/AddOSAS_StoreOnline.zptN(sPageTemplateFiles__of__sselfspt(sselfspt((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmanage_AddOSAS_StoreOnlineFormscsPt|}|i|||tj o|idndS(sadd the OSAS_roots manage_mainN(sOSAS_StoreOnlinesidsnewObjsselfs _setObjectsRESPONSEsNonesredirect(sselfsidsRESPONSEsnewObj((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmanage_AddOSAS_StoreOnlines cstiii|d}|id}g}x||D]q}yXt |iddi }t |iddi }|i ||fWn nXqGW|SdS(sReadContext from index.metas /index.metascontextslinkisnameN(sxmlsdomsminidomsparsespathsgetElementsByTagNamesnodessretsnodesgetTexts childNodesslinksnamesappend(spathsnodeslinksdomsnodessretsname((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys readContextss   (s*(s RoleManager(sImplicit(s Persistent(sstrptime(sstrftimes/var/tmp/archivers .HSResources lost+foundsNetwork Trash FoldersTheFindByContentFoldersTheVolumeSettingsFoldersfsentrycstZdZdZdZdZdZdZeZ dZ e i ddZ e i ddZ e i ddZ e i d!d Z%e i d &d Z)e i d *d ZRS(sFile entry classscsp  tiitid|id} ||_ ||_ d|_ tii ||_ dS(sinitialize classs(.*)\nisN( sosspathsabspathsressearchsextpathsgroupsselfsallsusersgetmtimesmtime(sselfsextpath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__s *   sgetPathcs|iSdS(sAusgabe von pathN(sselfspath(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetPathssgetUsercs|iSdS(sAusgabe von userN(sselfsuser(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetUserssgetDatecs&tdti|iSdS(sAusgabe von Dates %Y%m%d%H%MN(sstrftimestimesgmtimesselfsmtime(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetDatescs!!"#|i|iSdS(s)Ausgabe einer eindeutigen Sortierbaren IDN(sselfsgetDatesgetPath(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetID!ssgetTimecs&'(|iSdS(sAusgabe von pathN(sselfstime(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetTime&ssgetAllcs*+,|iSdS(sAusgabe von pathN(sselfsall(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetAll*s(s__name__s __module__s__doc__spathsusersmonthsdatestimesClassSecurityInfossecuritys__init__s declarePublicsgetPathsgetUsersgetDatesgetIDsgetTimesgetAll(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysfsentrys(            s filesystemcsm.tZdZ/0hZ1hZ2eZ4dZ;dZLddZ Sei dTdZ Wei dXdZ [ei d \d Z `ei d ad Zfd ZtdZei ddZei ddZei ddZei ddZei ddZRS(sstore filesystemcs=456tid|dd}7|i}9|SdS(sload filessystemsfind s -name '*' srN(sosspopensstartsfs readlinesslines(sselfsstartslinessf((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetfs4scs;<=x|i|D=]}?tid|}@|tj oA|id}B|id}C|i i |o4D|i |}E|i|F||i ||i|SdS(N(sselfstreeshas_keyspathsfilterExcludedsdircacheslistdir(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetTree9s"s isDirectorycs.ABtiitii|d|SdS(Ns/(sosspathsisdirsabspathsfile(sselfspathsfile((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isDirectoryAsstogglecs}EF|d|}H|ii|o?I|i|djoJd|i||d||dd||dd}|d}qW|SdS( s&generates navigation bar for showfilessiiiss/N( sstringsosspathsdirnamestmppathsisbasenamespathesslensappend(spathstmppathspathessstringsi((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys path_to_links"   "-cs1d}tii|}d}|tii|gg}xxt|dj o`|d}|djoPn|i |tii|gtii|}qQWxW|djoF|d|d||dd||dd}|d}qW|Sd S( s&generates navigation bar for viewfilessiiiss/N( sstringsosspathsdirnamestmppathsisbasenamespathesslensappendsURL(sURLspathsispathessstringstmppath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pyspath_to_link_views"   "5cs1d}tii|}d}|tii|gg}xxt|dj o`|d}|djoPn|i |tii|gtii|}qQWxW|djoF|d|d||dd||dd}|d}qW|Sd S( s&generates navigation bar for viewfilessiiiss/N( sstringsosspathsdirnamestmppathsisbasenamespathesslensappendsURL(sURLspathsispathessstringstmppath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pyspath_to_link_stores"   "5sErrorcsHtZgZeZdZeiddZRS(Ncs|d|_dS(Ni(s initerrorsselfserror(sselfs initerror((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__ssgetErrorcs|iSdS(N(sselfserror(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetErrors(s__name__s __module__serrorsClassSecurityInfossecuritys__init__s declarePublicsgetError(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysErrors    s metacheckcsTtZgZeZdZdZeiddZRS(Ncsd}t|dj ox"|D]}||d}q0Wtid|}|iddjo d}n0|iddjo d }n d }||gSndd gSd S( sparse for errorsis
s (.*):(.*)isABORTserrorsDONEsoksrunningN( sretstrslensstrslinesressearchschecksgroupserror(sselfsstrserrorslinesretstrscheck((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys parsearchives     csg|_t|tjoKtid|d}|iit ||i |i gn_xX|D]M}tid|d}|iit ||i |i gq}WdS(sarchive the documents in paths#/usr/local/mpiwg/archive/metacheck srN( sselfslinesstypespaths StringTypesosspopensfsappendsErrors parsearchives readliness singlepath(sselfspaths singlepathsf((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__s 2 smessagescs|iSdS(N(sselfslines(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmessagess( s__name__s __module__slinessClassSecurityInfossecuritys parsearchives__init__s declarePublicsmessages(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys metachecks     sarchivecsTtZgZeZdZdZ*eid+dZRS(Ncs  d} t|dj o x"|D ]}||d}q0Wtid|}|iddjo d}n0|iddjo d }n d }||gSndd gSd S( sparse for errorsis
s (.*):(.*)isABORTserrorsDONEsoksrunningN( sretstrslensstrslinesressearchschecksgroupserror(sselfsstrserrorslinesretstrscheck((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys parsearchives     csg|_h|_||d<"t|tjoF#ti|i|<$t i d|d|i|dd}nZ&xS|D&]H}'ti|i|<(t i d|d|i|dd}qWdS(sarchive the documents in pathsarchivers"/usr/local/mpiwg/archive/archiver s > s &srN( sselfsliness filenamesssessionstypespaths StringTypestempfilesmktempsosspopensfs singlepath(sselfspathssessions singlepathsf((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__s   0 smessagescs{+,g|_-xX|iiD-]D}/|iit||it|i|di gq"W0|iSdS(Nsr( sselfsliness filenamesskeysspathsappendsErrors parsearchivesopens readlines(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmessages+s   B( s__name__s __module__slinessClassSecurityInfossecuritys parsearchives__init__s declarePublicsmessages(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysarchives     cs34t|SdS(N(sevalsstr(sstr((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysevalext3scsC67|ii}8||d|<9||d|<;d|SdS(Nserror%ispath%iserror?number=%i(scontextsREQUESTsSESSIONssessionsretsispath(sretspathscontextsissession((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys storeerror6scs!=>|ii}?||SdS(N(scontextsREQUESTsSESSIONssessionsstr(sstrscontextssession((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgeterror=scsSACd}Dt|d}Ex$|iDE]}F||}q.WG|SdS(Nssr(sretsopenspathsfs readlinessg(spathsgsretsf((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysreadfileAs   csRIJt|d}K|i|L|iM|id}N|SdS(Nswsarchive2( sopenspathsfswritestxtsclosesselfs aq_acquiresrval(sselfspathstxtsREQUESTsrvalsf((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys writefileIs  cs1QRS|id|iid<Tt|SdS(s(check the metadata the documents in pathspathN(sselfsREQUESTsSESSIONs metacheckspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys metacheckerQscs8VWXt||ii}Y|iiidSdS(sarchive the documents in pathsarchive4N(sarchivespathsselfsREQUESTsSESSIONstmpsRESPONSEsredirect(sselfspathstmp((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysarchiverVscsX[]d}^x;|D^]0}_|i|ijo`||i}nqWa|SdS(Ns(srcsnodelistsnodesnodeTypes TEXT_NODEsdata(snodelistsnodesrc((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetText[s   cs~cdd}fx]|Df]R}h|i|ijo6ij|dt|idt|id}nqWl|dSdS(Nsss
s : s
( srcsnodelistsnodesnodeTypes ELEMENT_NODEsstrsnodeNamesgetTexts childNodes(snodelistsnodesrc((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetBibcs  7c s_nopg}qtii|d o sdSn'utid|dd}v|i}wti i i |}xt |i ddi}yt |i ddi}zt |i ddi}{t |i d di} |y#}t |i d di}Wn~d }nX|d jod |d}n7|djod|d}nd |d}|d|d|d}|d| d}y|i ddi dd} | iido#|d| idid}n|d}|t| i}Wn nX|SdS(sget index.metas /index.metas NO_METADATAscat srsnameiscreatorsarchive-creation-dates descriptions content-typessscanned documents

Document: s

sfolders

Folder: s

created by: s at: s

s

Description

s

smetasbibstypes

Info (s)

s

Info

N(shtmlsosspathsexistsspopensfsreadslinessxmlsdomsminidoms parseStringsgetTextsgetElementsByTagNames childNodessnamescreators creation_dates descriptionstypesbibs attributesshas_keysvaluesgetBib( spathsfsnamescreatorstypesdomsliness creation_dateshtmlsbibs description((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys getMetafilens>  # ## cs!tii|dSdS(sget index.metas /index.metaN(sosspathsexists(spath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys hasMetafilesc sygti|}ddddddddd g }d }xE|D]:}tii|}|d |jo d SnqUWyt i i i tii |d d }x|idD]q}t|idd idjoEt|idd itii |d jo d SnnqWd SWnd SnXWnd SnXdS(s9check if folder is candidate for digilib without metadatas.gifs.jpgs.jpegs.pngs.tiffs.tifs.JPGs.TIFFs.TIFsiis /index.metasdirs content-typesimagessnameN(sosslistdirspathsdirs imagesuffixessretsassplitextssuffixsxmlsdomsminidomsparsessplitsgetElementsByTagNamesnodesgetTexts childNodes(spathsasnodessuffixsdomsrets imagesuffixessdir((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isdigilib2s,$  , &6 csytiii|d}xu|idD]a}t|iddidjo5t|iddi|jo dSnnq;WdSWndSnXdS( s(check if foldername in path is full texts /index.metasdirs content-typeisfulltextsnameiN( sxmlsdomsminidomsparsespathsgetElementsByTagNamesnodesgetTexts childNodess folder_name(spaths folder_namesnodesdom((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys isFullTexts && csytiii|d}x|idD]x}y_t|iddidjo5t|iddi|jo dSnnWn nXq;WdSWndSnXdS( s(check if foldername in path is full texts /index.metasdirs content-typeis presentationsnameiN( sxmlsdomsminidomsparsespathsgetElementsByTagNamesdirnodesgetTexts childNodess folder_name(spaths folder_namesdomsdirnode((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysisPresentations &&  cs{y]tid|}|tjo$dtid|idSn|idSWndSnXdS(Ns(.*)/mpiwg/online/(.*)s digifiles/s%(.*)/mpiwg/production/docuserver/(.*)isNO(sressearchspathstemp2sNonesgroup(spathstemp2((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys changeNames$csPd|_|ididd|ididddSdS(NisOFSPsneusHELLOsok(sselfsismanage_addProductsmanage_addDTMLMethodsgetattrs manage_edit(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pystests slscstZdZdZdZdZdZdZeZ dZ e i d dZ  e i d dZ e i ddZe i d d ZRS( sFile entry classscsDti|_||d<tid|idddS(Nsoutfiles ls -R / >s &sr(stempfilesmktempsselfsoutfilesstartsosspopen(sselfsstart((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys__init__s sreadcs  |iiSdS(N(sselfsfsread(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysread ssretselfcs  |SdS(N(sself(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysretself ssallcs>d}x!|iD]}||}qW|SdS(Ns(sretsselfsfsg(sselfsgsret((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysalls   s printOutfilecsEx"tii|i oq Wt|iiSdS(N(sosspathsexistssselfsoutfilesopens readlines(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys printOutfiles(s__name__s __module__s__doc__spathsusersmonthsdatestimesClassSecurityInfossecuritys__init__s declarePublicsreadsretselfsalls printOutfile(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pyslss           soverviewcstZgZhZeZ dZ'dZ1dZDei dEdZ Mei dNdZ RS(NcsT !ti|}#x5|D#]*}$|d||i|i||d }@||gSnBdd gSd S( sparse for errorsis
s (.*):(.*)isABORTserrorsDONEsoksrunningN( sretstrslensstrslinesressearchschecksgroupserror(sselfsstrserrorslinesretstrscheck((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys parsearchive1s     smessagescsEFg|_Gxa|iiDG]M}H|i|}J|iit||it |di gq"WK|iSdS(Nsr( sselfsliness resourcesskeyssnamespathsappendsErrors parsearchivesopens readlines(sselfspathsname((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysmessagesEs   ;s printResourcecsNO|iSdS(N(sselfs resources(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys printResourceNs( s__name__s __module__sdirs resourcessClassSecurityInfossecuritys__init__s getResources parsearchives declarePublicsmessagess printResource(((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysoverviews       csQSt|SdS(N(soverviewspath(spath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys getoverviewQscs2VWt|ii}X|iiidSdS(Nsnext(slssselfsREQUESTsSESSIONstmpsRESPONSEsredirect(sselfstmp((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysls_testVscs!Z[||iid<\dSdS(Ns somethingi(s somethingsselfsREQUESTsSESSION(sselfs something((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys storeFileZscs^_|iidSdS(Ns something(sselfsREQUESTsSESSION(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysgetFile^scsabct|| SdS(shreturns TRUE, wenn path ein Folder ist in den weitere Objekte Folder oder Dokumente gelegt werden drfenN(sisScannedDocumentsselfspath(sselfspath((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysisFolderascsefgyht|dd}i|i}kyjltiii|}mt |i ddi }n|djp |djo odSnqdSWnrsdSnXWntudSnXdS( sFreturns TRUE, wenn path der Stammordner eines gescannten Documents ists /index.metasrs content-typeisscanned-documentsscanned documentiN( sfilespathsfsreadslinessxmlsdomsminidoms parseStringsgetTextsgetElementsByTagNames childNodess content_type(sselfspaths content_typesdomsfslines((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysisScannedDocumentes  (s localtimesstrftimecsyztdtSdS(Ns%d.%m.%Y(sstrftimes localtime(sself((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pysdateys(Rs addFolders OFS.FoldersFoldersOFS.SimpleItems SimpleItems'Products.PageTemplates.PageTemplateFilesPageTemplateFiles#Products.PageTemplates.PageTemplates PageTemplates AccessControlsClassSecurityInfosGlobalssInitializeClasssOSAS_ShowOnlinesmanage_AddOSAS_ShowOnlineFormsNonesmanage_AddOSAS_ShowOnlinesOSAS_StoreOnlinesmanage_AddOSAS_StoreOnlineFormsmanage_AddOSAS_StoreOnlines readContextsstypessurllibsosssyssresAccessControl.Roles RoleManagers AcquisitionsImplicits Persistentstimesstrptimesstrftimesos.pathsdircachesxml.dom.minidomsxmlstempfilestempdirs exclusionsfsentrys filesystems filesystem2sbrowsesgetfssshowallsentriess getfilesystems sort_by_dates path_to_linkspath_to_link_viewspath_to_link_storesErrors metachecksarchivesevalexts storeerrorsgeterrorsreadfiles writefiles metacheckersarchiversgetTextsgetBibs getMetafiles hasMetafiles isdigilib2s isFullTextsisPresentations changeNamestestslssoverviews getoverviewsls_tests storeFilesgetFilesisFoldersisScannedDocuments localtimesdate(Es hasMetafilestempfilesOSAS_ShowOnlinesoverviewsshowalls getfilesystemslss RoleManagers getoverviewsmanage_AddOSAS_StoreOnlineFormsisScannedDocumentsFolders PageTemplatesarchivesxmls addFolders exclusionspath_to_link_viewsbrowsesstrptimesmanage_AddOSAS_StoreOnlinesurllibs sort_by_datesevalextsgetfssgetTextsarchiversmanage_AddOSAS_ShowOnlinestimestests storeFiles isdigilib2sImplicitsPageTemplateFilesisFolders metachecksOSAS_StoreOnlines storeerrorsreadfiles path_to_linksClassSecurityInfos PersistentsInitializeClassssyss SimpleItems writefilesgeterrors filesystem2sErrorsdatesres isFullTexts getMetafilesls_tests localtimesmanage_AddOSAS_ShowOnlineFormsgetBibsfsentrysdircachespath_to_link_stores changeNamesisPresentations filesystems readContextssgetFilesentriess metacheckersossstrftime((sS/Users/dwinter/install/CVSZOPE/Zope_old/lib/python/Products/OSA_system/OSAS_show.pys?s1  y              /U8        (.         *  "   #6