Ignore:
Timestamp:
17 Jun 2012, 06:42:20 (12 years ago)
Author:
Henrik Bettermann
Message:

Let's use the msave helper function also in university and other packages. msave applies applyData to the view and writes a view-specific log message. The context object of the view must have a writeLogMessage method.

In the students package writeLogMessage is now provided by all classes which implement IStudentNavigation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/students/viewlets.py

    r8476 r8735  
    3535    VALIDATED)
    3636from waeup.kofa.students.browser import (
    37     StudentClearanceManageFormPage, write_log_message,
     37    StudentClearanceManageFormPage,
    3838    StudentBaseManageFormPage, StudentFilesUploadPage,
    3939    ExportPDFClearanceSlipPage, StudentsContainerPage,
     
    568568    store = getUtility(IExtFileStore)
    569569    store.deleteFileByContext(context, attr=download_name)
    570     write_log_message(view, 'deleted: %s' % download_name)
     570    context.writeLogMessage(view, 'deleted: %s' % download_name)
    571571    view.flash(_('${a} deleted.', mapping = {'a':download_name}))
    572572    return
     
    607607    file_id = IFileStoreNameChooser(context).chooseName(attr=download_name)
    608608    store.createFile(file_id, upload)
    609     write_log_message(view, 'uploaded: %s (%s)' % (
     609    context.writeLogMessage(view, 'uploaded: %s (%s)' % (
    610610        download_name,upload.filename))
    611611    view.flash(_('File ${a} uploaded.', mapping = {'a':download_name}))
Note: See TracChangeset for help on using the changeset viewer.