Hello, people!
I am developing a website admin system using DirectToWeb.
The website has a product catalog, where products are organized by categories:
ProductCategory <--->> Product
Each Product has a 'specifications' property, where I'm storing technical specs
in XML form, which will be formatted on the website through a XSLT stylesheet.
But I want the interface in the admin system to be easy to use. So, I got this
idea...
Product has a 'specTemplate' property, where an XML 'template' will be stored.
So, let's suppose I have a ProductCategory, "Tablets". The XML for
specsTemplate would be something like (just an example, it will be defined
later on):
<specs>
<section name="Physical Characteristics">
<item name="Form Factor" type="NSString" />
<subsection name="Dimensions">
<item name="Width" type="NSNumber" unit="mm" />
<item name="Height" type="NSNumber" unit="mm" />
<item name="Depth" type="NSNumber" unit="mm" />
</subsection>
<item name="Weight" type="NSNumber" unit="g" />
</section>
[...]
</specs>
When the admin creates a ProductCategory, the structure is defined. This
ensures all my products have the same information structure for the
specifications, making it easy to create comparison tables and the like. Admins
would fill this information in a simpler and faster way. Searching for products
by feature would be easy, using PostgreSQL's XML datatype.
When the admin creates or edits a Product, the XML stored in the
'specifications' property would be like:
<specs>
<section name="Physical Characteristics">
<item name="Form Factor" type="NSString">Rugged Compact
Tablet</item>
<subsection name="Dimensions">
<item name="Width" type="NSNumber"
unit="mm">145.5</item>
<item name="Height" type="NSNumber" unit="mm">109</item>
<item name="Depth" type="NSNumber" unit="mm">12</item>
</subsection>
<item name="Weight" type="NSNumber" unit="g">200</item>
</section>
[...]
</specs>
So, how would you guys do this?
Regards,
Flavio
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]