slot-presentation-cleanups
authorDrew Crampsie <drewc@tech.coop>
Fri, 5 Aug 2005 21:00:55 +0000 (14:00 -0700)
committerDrew Crampsie <drewc@tech.coop>
Fri, 5 Aug 2005 21:00:55 +0000 (14:00 -0700)
darcs-hash:20050805210055-5417e-663ffd37df6c091c927bd8bc634141f281547b11.gz

src/mewa/mewa.lisp
src/mewa/presentations.lisp
src/mewa/slot-presentations.lisp

index 7cdb073..4434039 100644 (file)
@@ -141,7 +141,8 @@ attributes is an alist keyed on the attribute name."
 
 
 (defcomponent mewa ()
-  ((attributes
+  ((ucw::instance :accessor instance :initarg :instance) 
+   (attributes
     :initarg :attributes
     :accessor attributes
     :initform nil)
index 15f0e16..95e4977 100644 (file)
 (defmethod render-criteria ((res response) (s mewa-presentation-search))
   (setf (criteria-input s) "")
   (<:ul
-   (dolist (c (criteria s))
+   (dolist (c (ucw::criteria s))
      (<:li (render-on res c)
           (let ((c c))
             (<ucw:input :action (ucw::drop-criteria s c) :type "submit" :value "eliminate"))))
index cbd2525..2ed5b32 100644 (file)
@@ -46,7 +46,6 @@ When T, only the default value for primary keys and the joins are updated."))
   integer
   currency)
 
-
 (defslot-presentation clsql-wall-time-slot-presentation (mewa-relation-slot-presentation)
        ()
        (:type-name clsql-sys:wall-time))
@@ -82,8 +81,6 @@ When T, only the default value for primary keys and the joins are updated."))
         ifFormat       :    \"%m/%d/%Y\",
       });" input-id))))))
 
-
-
 (defslot-presentation  mewa-relation-slot-presentation (mewa-slot-presentation slot-presentation)
   ((foreign-instance :accessor foreign-instance)
    (linkedp :accessor linkedp :initarg :linkedp :initform t)
@@ -287,15 +284,9 @@ When T, only the default value for primary keys and the joins are updated."))
            (present (presentation slot)))
          (<:as-html "--"))))
 
-(defslot-presentation inline-slot-presentation (mewa-relation-slot-presentation)
-  ()
-  (:type-name inline))
 
-(defmethod present-slot ((slot inline-slot-presentation) instance)
-  (<:fieldset 
-   (<:legend (<:as-html (label slot)))
-  (<ucw:render-component :component (mewa:make-presentation (meta-model::explode-foreign-key instance (slot-name slot)) :type :editor))))
 
-(defmethod mewa::present-slot-as-row ((self mewa::mewa-object-presentation) (slot inline-slot-presentation))
-  (<:td :colspan 2
-       (present-slot slot (instance self))))
\ No newline at end of file
+
+
+
+