(defmethod find-validation-functions (instance (attribute standard-attribute))
- (getf (attribute.plist attribute) :validate-using))
+ (getf (description.properties attribute) :validate-using))
;;;; ** Instances
(not (< 0 (length value))))
(signal 'attribute-validation-condition
:message (format nil "You must enter a value for ~A."
- (getf (attribute.plist attribute) :label))
+ (getf (description.properties attribute) :label))
:attribute attribute))))
-
+(defun validate-true (instance attribute)
+
+ (warn "validate ~A ~A" instance attribute)
+ (let ((value (lol::attribute-value instance attribute)))
+ (warn "value is ~A" value)
+ (unless value
+
+ (signal 'attribute-validation-condition
+ :message (format nil "~A must be true."
+ (getf (description.properties attribute) :label))
+ :attribute attribute))))