Changeset 5076 for MILK


Ignore:
Timestamp:
09/03/09 09:51:33 (10 years ago)
Author:
cbyrom
Message:

Move mailer module to ndg common + tidy up code.

Location:
MILK/trunk/milk_server/milk_server
Files:
2 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • MILK/trunk/milk_server/milk_server/controllers/atom_editor/editatom.py

    r5020 r5076  
    1212from milk_server.lib.base import * 
    1313from milk_server.models.form import * 
    14 from milk_server.lib import mailer 
    1514import ndg.common.src.lib.htmlUtilities as utils 
    1615from ndg.common.src.models.Atom import Atom, Person, Link, Category 
  • MILK/trunk/milk_server/milk_server/controllers/browse/discovery.py

    r5013 r5076  
    99from ndg.common.src.models.ndgObject import ndgObject 
    1010from ndg.common.src.models.DIF import DIF 
     11from ndg.common.src.lib.mailer import mailHandler 
    1112from milk_server.lib.base import * 
    1213from milk_server.lib.Date import * 
    1314from milk_server.models.DiscoveryState import DiscoveryState,constraints 
    14 from milk_server.lib.mailer import mailHandler 
    1515 
    1616class DiscoveryController(BaseController): 
  • MILK/trunk/milk_server/milk_server/controllers/trackback/trackback.py

    r5023 r5076  
    1212''' 
    1313from milk_server.lib.base import * 
    14 from milk_server.lib.mailer import mailHandler  
    15 from milk_server.lib import mailer 
    1614from milk_server.models.ndgdoc import NDGDoc  
    1715from ndg.common.src.models.ndgObject import ndgObject 
    1816import ndg.common.src.clients.xmldb.eXist.dbconstants as dc 
     17from ndg.common.src.lib.mailer import mailHandler 
    1918 
    2019class TrackbackController(BaseController): 
     
    8180        else:  
    8281            logging.info("Sending notification mail to '%s'" %recipient) 
    83             status, message=mailHandler([recipient,], body, body, 
    84                                         xmlAttachments = [(payload, name),], 
    85                                         server = server) 
     82            status, message = mailHandler([recipient,], body, body, 
     83                                          xmlAttachments = [(payload, name),], 
     84                                          server = server) 
    8685            if status: 
    8786                c.err = 0 
     
    163162         
    164163        logging.info("Mailing corrections info to %s" %maintainer) 
    165         status,message=mailer.mailHandler([maintainer,], 
    166                        body,body,xmlAttachments=[(payload,name),], 
    167                        server=self.cf.get('DEFAULT','mailserver')) 
     164        status,message = mailHandler([maintainer,], 
     165                                     body,body,xmlAttachments=[(payload,name),], 
     166                                     server=self.cf.get('DEFAULT','mailserver')) 
    168167        if status: 
    169168            result = 'Your comments have been sent to the metadata maintainer and added to corrections feed for the metatadata database.' 
Note: See TracChangeset for help on using the changeset viewer.