[Bese-devel] yet another question (suggestion?)

Friedrich Dominicus frido at q-software-solutions.de
Fri Aug 26 10:21:28 UTC 2005


Well for the moment I have find at least a way to proceed. But there
are a still a lot of open questions. Does anyone here have used UCW
together with CLSQL? for the time beeing it seems on needs quite few
extra classed to get them going together. e.g you like to read an
object from a database and "display" it. That's the "easy" part, but
then you migh want to change the display so you have to put e.g an
text-field out for a field you like to change. to initialize the view
it seems on has to write:

  (let ((address (adr adr)))
    ;; (inspect adr)
    (when address 
      (setf (ucw::client-value (zip adr)) (zip address)
            (ucw::client-value (street adr)) (street address)
            (ucw::client-value (city adr)) (city address)
            (ucw::client-value (country adr)) (country address)
            (ucw::client-value (email adr)) (email address)))
...

so me seems this isn't an unusual request you want to initialze the
few from a database objects,but one has to use a "private" feature of
ucw to achieve that. I think client-value should be an exported
function.

Ok now let's see further. You got your view, now you change the value
now you have to propagate the changes in the view to the database so
you have to use code like this IIUC.

(defun update-db-address-from-view (slot-name address)
  (setf (slot-value  (adr address) slot-name) 
        (read-client-value (slot-value address slot-name))))

Of course one can generalize it but me things at least this back/forth
between has to be code explicitly. Am I missing something or is that a
correct impression? 


As I understand lisp-on-lines, the author there has worked for
autmating this task. Is anyone using lisp-on-lines and can confirm
that?

Thanks
Friedrich



More information about the bese-devel mailing list