I have created a ZClass, "BookReview", as a subclass of ZDTMLDocument to hold book reviews. The document ("raw" property) contains the review, and I have created a property sheet, "Properties", to contain variables such as: -bookTitle -bookAuthor -bookPageLength -reviewer The BookReview class has a method, "index_html", that orchestrates this information into a standardized presentation. I would like to add the ability to add an image of the book cover to the property sheet, similar to the way that someone can add an icon to a ZClass in the basic view. The closest thing I have seen is adding the ObjectManager class to the base of "BookReview" and creating a method to upload a file into it. This however does not allow our writers/editors to accomplish this task from within the Properties view of the instance of "BookReview" they just created. Any advice, direction, or better method would be appreciated.
Nathan Clark wrote at 2004-10-20 13:25 -0700:
... I would like to add the ability to add an image of the book cover to the property sheet, similar to the way that someone can add an icon to a ZClass in the basic view.
PropertySheets are for elementary data only. You cannot store an image there...
The closest thing I have seen is adding the ObjectManager class to the base of "BookReview" and creating a method to upload a file into it.
That's indeed the usual approach...
This however does not allow our writers/editors to accomplish this task from within the Properties view of the instance of "BookReview" they just created.
This means that you must create your own form (which adds an "input type=file" tag) and your own action (which updates the property sheet and handles the uploaded image). -- Dieter
participants (2)
-
Dieter Maurer -
Nathan Clark