Changeset 4511


Ignore:
Timestamp:
1 Aug 2009, 08:35:04 (15 years ago)
Author:
uli
Message:
  • Add missing imports.
  • Fix error message when duplication errors occur.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • waeup/branches/ulif-rewrite/src/waeup/university/department.py

    r4499 r4511  
    44import grok
    55from zope.component import createObject
    6 from zope.component.interfaces import IFactory
     6from zope.component.interfaces import IFactory, Invalid
     7from zope.exceptions import DuplicationError
    78from zope.interface import implementedBy
    89from waeup.interfaces import IDepartment, ICourse, ICertificate
     
    153154            self.context.courses.addCourse(course)
    154155        except DuplicationError:
    155             self.status = Invalid('The name chosen already exists '
     156            self.status = Invalid('The code chosen already exists '
    156157                                  'in the database')
    157158            return
Note: See TracChangeset for help on using the changeset viewer.