Diff for /MPIWGWeb/MPIWGStaff.py between versions 1.10.2.16 and 1.10.2.17

version 1.10.2.16, 2005/11/11 15:02:27 version 1.10.2.17, 2005/11/11 19:42:36
Line 54  class MPIWGStaff(CatalogAware,ZSQLExtend Line 54  class MPIWGStaff(CatalogAware,ZSQLExtend
         else:          else:
             return False              return False
                   
     def createNewDBEntry(self,publish_the_data,id,name,vorname,username,title,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by="",e_mail2="",txt="",txt_p="no",stay_at_mpiwg=""):      def createNewDBEntry(self,publish_the_data,id,name,vorname,username,title,position,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by="",e_mail2="",txt="",txt_p="no",stay_at_mpiwg=""):
         """lege person in der datenbank an"""          """lege person in der datenbank an"""
         msg=""          msg=""
         #test ob id schon existiert          #test ob id schon existiert
Line 68  class MPIWGStaff(CatalogAware,ZSQLExtend Line 68  class MPIWGStaff(CatalogAware,ZSQLExtend
         if self.ZSQLQuery("select username from personal_www where username='%s' and not publish_the_data='yes'"%username):          if self.ZSQLQuery("select username from personal_www where username='%s' and not publish_the_data='yes'"%username):
             msg="WARNING:username %s not unique but id=%s added"%(username,id)              msg="WARNING:username %s not unique but id=%s added"%(username,id)
         #eintragen          #eintragen
         columnlist="publish_the_data,id,name,vorname,username,title,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by,e_mail2,stay_at_mpiwg"          columnlist="publish_the_data,id,name,vorname,username,title,position,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by,e_mail2,stay_at_mpiwg"
         insertTuple=(publish_the_data,id,name,vorname,username,title,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by,e_mail2,stay_at_mpiwg)          insertTuple=(publish_the_data,id,name,vorname,username,title,position,e_mail,e_mail_p,date_from,date_to,abteilung,heimat_inst,funded_by,e_mail2,stay_at_mpiwg)
                   
         insert=[]          insert=[]
         for element in insertTuple:          for element in insertTuple:
Line 77  class MPIWGStaff(CatalogAware,ZSQLExtend Line 77  class MPIWGStaff(CatalogAware,ZSQLExtend
                   
         insertStr=",".join(insert)          insertStr=",".join(insert)
         queryStr="INSERT INTO personal_www (%s) VALUES (%s)"%(columnlist,insertStr)          queryStr="INSERT INTO personal_www (%s) VALUES (%s)"%(columnlist,insertStr)
                   self.ZSQLQuery("SET DATESTYLE TO 'German'")
         self.ZSQLQuery(queryStr)          self.ZSQLQuery(queryStr)
                   
         #currentwork          #currentwork
         if not (txt==""):          if not (txt==""):
             queryStr="INSERT INTO current_work (id_main,current,publish) VALUES ('%s','%s','%s')"%(id,txt,txt_p)              queryStr="INSERT INTO current_work (id_main,current,publish) VALUES ('%s','%s','%s')"%(id,txt,txt_p)
   
             self.ZSQLQuery(queryStr)              self.ZSQLQuery(queryStr)
                   
         return True,msg          return True,msg

Removed from v.1.10.2.16  
changed lines
  Added in v.1.10.2.17


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>