couchrest_model/spec/fixtures/more/service.rb
2009-07-21 03:17:27 +06:00

12 lines
No EOL
326 B
Ruby

class Service < CouchRest::ExtendedDocument
# Include the validation module to get access to the validation methods
include CouchRest::Validation
auto_validate!
# Set the default database to use
use_database DB
# Official Schema
property :name, :length => 4...20
property :price, :type => 'Integer'
end