--- OSAS/OSA_system/OSAS_show.py 2004/04/15 20:48:01 1.20 +++ OSAS/OSA_system/OSAS_show.py 2004/04/17 15:09:09 1.22 @@ -106,7 +106,7 @@ class OSAS_StoreOnline(SimpleItem): def rescaleThumbs(self,path): """rescale thumbs of images in path""" - os.popen("ssh nausikaa2.rz-berlin.mpg.de /usr/local/mpiwg/scripts/scaleomat.pl %s /mpiwg/temp/online/scaled/thumb 90 --replace >> /tmp/sc.out &"% re.sub('/mpiwg/online/','',self.REQUEST['path'])) + os.popen("ssh archive@nausikaa2.rz-berlin.mpg.de /usr/local/mpiwg/scripts/scaleomat.pl %s /mpiwg/temp/online/scaled/thumb 90 --replace >> /tmp/sc.out &"% re.sub('/mpiwg/online/','',self.REQUEST['path'])) self.REQUEST.SESSION['path']=self.REQUEST['path'] #return self.REQUEST.RESPONSE.redirect(self.REQUEST['URL1']) @@ -230,8 +230,13 @@ class OSAS_StoreOnline(SimpleItem): dom=xml.dom.minidom.parse(path+"/index.meta") node=dom.getElementsByTagName('texttool')[0] #getNode subnode=node.getElementsByTagName(name)[0] - - return getText(subnode.childNodes) + + # bei text wird nur der Folder gebraucht + if name=="text": + splitted=getText(subnode.childNodes).split("/") + return splitted[len(splitted)-2] + else: + return getText(subnode.childNodes) except: return default @@ -258,14 +263,12 @@ class OSAS_StoreOnline(SimpleItem): - def changeTemplates(self,path): + def changeTemplates(self,path,RESPONSE=None): """Andere alle Eintraege in index.meta""" - #os.path.walk(path,OSAS_helpers.changeIndexMeta,startpage,xslt,thumbtemplate,topbar,digiLibTemplate) - print self.REQUEST.form - - os.path.walk(path,OSAS_helpers.changeIndexMeta,self.REQUEST.form) - + if RESPONSE is not None: + RESPONSE.redirect(self.REQUEST['URL1']+"?path="+self.REQUEST.SESSION['path']) + InitializeClass(OSAS_StoreOnline)