[kforge-dev] Changeset [100]: Simplify 'new' package action and improve by adding proper validation. ...

28: Timeline admin at okfn.org
Mon Feb 26 19:07:26 UTC 2007


Simplify 'new' package action and improve by adding proper validation. * trunk/ckan/forms/init.py, 

> trunk/ckan/tests/forms/test_package.py: 

  * [UniquePackageName?][1]: new validator 
  * [LowerCase?][2]: new lower case validator 
  * package_name_validator: string a bunch of validators together using All 
  * [PackageNameSchema?][3]: schema using package_name_validator 

* trunk/ckan/controllers/package.py, 

> trunk/ckan/templates/package/create.html, trunk/ckan/templates/package/new.html, trunk/ckan/tests/functional/test_package.py: 'new' and 'create' action just require name. 

  * create page now gives link to edit page after a succesful create. 

    [1]: http://project.knowledgeforge.net/ckan/trac/wiki/UniquePackageName
    [2]: http://project.knowledgeforge.net/ckan/trac/wiki/LowerCase
    [3]: http://project.knowledgeforge.net/ckan/trac/wiki/PackageNameSchema

URL: http://project.knowledgeforge.net/ckan/trac/changeset/100




More information about the kforge-dev mailing list