(defun multiple-value-funcall->list (function &rest args)
"The function to be called by m-v-bf"
(multiple-value-call #'list (apply function args)))
(defun multiple-value-funcall->list (function &rest args)
"The function to be called by m-v-bf"
(multiple-value-call #'list (apply function args)))
(creatablep :accessor creatablep :initarg :creatablep :initform t))
(:documentation "The superclass of all Mewa slot presentations"))
(creatablep :accessor creatablep :initarg :creatablep :initform t))
(:documentation "The superclass of all Mewa slot presentations"))
;;;; this has to be in the eval when i would think
(eval-when (:compile-toplevel :load-toplevel :execute)
(defun generate-slot-presentation-definition-for-type (type)
;;;; this has to be in the eval when i would think
(eval-when (:compile-toplevel :load-toplevel :execute)
(defun generate-slot-presentation-definition-for-type (type)
(default-to-now-p :accessor default-to-now-p :initarg :default-to-now-p :initform nil))
(:type-name clsql-sys:wall-time))
(default-to-now-p :accessor default-to-now-p :initarg :default-to-now-p :initform nil))
(:type-name clsql-sys:wall-time))
(let ((date (call-next-method)))
(when date (multiple-value-bind (y m d) (clsql:time-ymd date)
(format nil "~a/~a/~a" m d y)))))
(let ((date (call-next-method)))
(when date (multiple-value-bind (y m d) (clsql:time-ymd date)
(format nil "~a/~a/~a" m d y)))))
(let ((new-time (clsql:parse-date-time (remove #\Space value)))
(old-time (when (slot-boundp instance (slot-name slot))
(slot-value instance (slot-name slot)))))
(let ((new-time (clsql:parse-date-time (remove #\Space value)))
(old-time (when (slot-boundp instance (slot-name slot))
(slot-value instance (slot-name slot)))))
(defmethod label :around ((slot clsql-wall-time-slot-presentation))
(concatenate 'string (call-next-method) " (m/d/y)"))
(defmethod label :around ((slot clsql-wall-time-slot-presentation))
(concatenate 'string (call-next-method) " (m/d/y)"))
-(defmethod present-slot ((slot clsql-wall-time-slot-presentation) instance)
- (let ((date (presentation-slot-value slot instance)))
+(defmethod lol::present-slot ((slot clsql-wall-time-slot-presentation) instance)
+ (let ((date (lol::presentation-slot-value slot instance)))
(defmethod present-slot :around ((slot foreign-key-slot-presentation) instance)
(setf (foreign-instance slot)
(defmethod present-slot :around ((slot foreign-key-slot-presentation) instance)
(setf (foreign-instance slot)
(meta-model:explode-foreign-key instance (slot-name slot))))
(flet ((render () (when (foreign-instance slot)(call-next-method))))
(if (slot-boundp slot 'ucw::place)
(meta-model:explode-foreign-key instance (slot-name slot))))
(flet ((render () (when (foreign-instance slot)(call-next-method))))
(if (slot-boundp slot 'ucw::place)
(get-foreign-instances slot instance))
(defslot-presentation has-very-many-slot-presentation (has-many-slot-presentation)
(get-foreign-instances slot instance))
(defslot-presentation has-very-many-slot-presentation (has-many-slot-presentation)
(when (allow-nil-p slot)
(<ucw:option :value nil (<:as-html "none")))
(dolist (option (get-foreign-instances slot instance))
(<ucw:option :value (find-foreign-slot-value slot option)
(when (allow-nil-p slot)
(<ucw:option :value nil (<:as-html "none")))
(dolist (option (get-foreign-instances slot instance))
(<ucw:option :value (find-foreign-slot-value slot option)
:type :as-string
:initargs
`(:attributes ,(attributes slot)))
))))
(when (creatablep slot)
(<ucw:submit :action (create-record-on-foreign-key slot instance) :value "Add New" :style "display:inline")))
:type :as-string
:initargs
`(:attributes ,(attributes slot)))
))))
(when (creatablep slot)
(<ucw:submit :action (create-record-on-foreign-key slot instance) :value "Add New" :style "display:inline")))
(lol:make-presentation (meta-model:explode-foreign-key instance (slot-name slot))
:type :one-line
:initargs
`(:attributes ,(attributes slot)))
))
(lol:make-presentation (meta-model:explode-foreign-key instance (slot-name slot))
:type :one-line
:initargs
`(:attributes ,(attributes slot)))
))
(defslot-presentation many-to-many-slot-presentation (mewa-relation-slot-presentation)
((list-view :accessor list-view :initarg :list-view :initform :one-line)
(defslot-presentation many-to-many-slot-presentation (mewa-relation-slot-presentation)
((list-view :accessor list-view :initarg :list-view :initform :one-line)