`(:initargs
'(,@ (mapcan #'identity args)))))))
-(defmethod make-view (object &rest args &key (type :viewer) (attributes nil)
+(defmethod make-view (object &rest args &key (type :viewer)
&allow-other-keys )
- (warn "~A ~A ~A" attributes type object)
- (remf args :type )
- (remf args :attributes)
- (apply #'make-presentation object (cddr (%make-view object type attributes args))))
+ (remf args :type)
+ ;(warn "~A ~A" args `(:type ,type :initargs ,@args))
+ (apply #'make-presentation object `(:type ,type ,@ (when args
+ `(:initargs ,args)))))
(defmacro present-view ((object &optional (type :viewer) (parent 'self))
&body attributes-and-args)
(arnesi:with-unique-names (view)
`(let ((,view (lol:make-view ,object
:type ,type
- :attributes ,(car attributes-and-args)
+ ,@(when (car attributes-and-args)
+ `(:attributes ',(car attributes-and-args)))
,@ (cdr attributes-and-args))))
(setf (ucw::parent ,view) ,parent)
(lol:present ,view))))
(defmethod make-presentation ((object t) &key (type :viewer) (initargs nil))
-
+ ;(warn "Initargs : ~A" initargs)
(let* ((p (make-instance 'mewa-object-presentation))
(a (progn (setf (slot-value p 'instance) object)
:mewa-list-presentation
:mewa-search-presentation
:mewa-presentation-search
+
+ :editablep
+ :global-properties
;; SLOT presentations
:defslot-presentation
:slot-name
:mewa-string-slot-presentation
:has-many-slot-presentation
:present-slot
+
+ :has-a
+ :has-many
+ :has-very-many
+ :many-to-many
+
;; CRUD
:instance-is-stored-p