Nagarjuna G. wrote:
Hello,

The product I am developing (Archetypes product) requires each content
object to have a site wide unique id, where the id is based on the
user supplied title string.
 The statement  " _at_rename_after_creation = True" takes care of
creating unique ids.  However when the user supplies same title next
time the object still gets created with 'supliedtitle-1',
suppliedtitle-2 etc.  I want to inform Plone that title is unique.  I
looked at the documentation, but could find any clue.  Can some one
give me a direction.  It will be very nice if the schema definition
allows an option like "unique=1".  Is this possible?

The best way I can think of is to set up a custom validator for that field, then do the check yourself.

I haven't done this yet myself, but the entry for 'validators' in the common field attribute list here: http://plone.org/documentation/manual/archetypes-developer-manual/fields/fields-reference is a good place to start.

JJ


_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers

Reply via email to