2009-02-06 02:06:12 +01:00
|
|
|
class Service < CouchRest::ExtendedDocument
|
|
|
|
# Include the validation module to get access to the validation methods
|
|
|
|
include CouchRest::Validation
|
2009-02-11 01:10:35 +01:00
|
|
|
auto_validate!
|
2009-02-06 02:06:12 +01:00
|
|
|
# Set the default database to use
|
2009-05-28 03:16:50 +02:00
|
|
|
use_database DB
|
2009-02-06 02:06:12 +01:00
|
|
|
|
|
|
|
# Official Schema
|
|
|
|
property :name, :length => 4...20
|
|
|
|
property :price, :type => Integer
|
|
|
|
|
|
|
|
end
|