Object relation list question

Author Message

Glenn MacGregor

Monday 17 November 2003 8:15:40 am

Hello,

I am thinking about changing the builtin Product class. Currently the Product class contains:
Title
Product nr
Intro
Description
Price
Photo

I want to add a list of bullet points and a conclusion to this.

First question: Is it better to modify the existing Product class or create a new one?

Second: I was going to create a class for the list of bullet points because I don't know how many there are per product so I can't just have (say) 3 Text Line's for bullet 1 2 and 3 because there may be 100 bullets. So I was going to create a class which contains a Text Line and a URL (because each bullet could be a link as well) and have an object relation list of those as part of the product. Is there any docs on getting the object relation list working and is this the correct solution?

Thanks!

 

Tore Skobba

Monday 17 November 2003 8:37:13 am

Hi

Hmm why dont you just have an HTML or XML textfield in order to represent your list? Then simply add link tag in order to make links. For instance check out the online editor demo at : http://www.ez.no/products/ez_publish_3/demos

Alternitively I would opt for making an new product class and not modify the existing classes. This in order to hopefully run future updates of the system easier.

Cheers
Tore

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 04:28:04
Script start
Timing: Jan 19 2025 04:28:04
Module start 'layout'
Timing: Jan 19 2025 04:28:04
Module start 'content'
Timing: Jan 19 2025 04:28:06
Module end 'content'
Timing: Jan 19 2025 04:28:06
Script end

Main resources:

Total runtime1.4358 sec
Peak memory usage4,096.0000 KB
Database Queries54

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0052 589.1563152.6250
Module start 'layout' 0.00520.0034 741.781339.4453
Module start 'content' 0.00851.4258 781.2266459.7891
Module end 'content' 1.43430.0015 1,241.01568.1641
Script end 1.4358  1,249.1797 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.2245160.0002
Check MTime0.00140.0958160.0001
Mysql Total
Database connection0.00070.046910.0007
Mysqli_queries1.390296.8216540.0257
Looping result0.00110.0744520.0000
Template Total1.400397.520.7002
Template load0.00190.134220.0010
Template processing1.398497.391820.6992
Template load and register function0.00040.025210.0004
states
state_id_array0.00210.145110.0021
state_identifier_array0.00190.135720.0010
Override
Cache load0.00160.1117220.0001
Sytem overhead
Fetch class attribute can translate value0.00150.102020.0007
Fetch class attribute name0.00340.234420.0017
XML
Image XML parsing0.00030.017820.0001
class_abstraction
Instantiating content class attribute0.00000.000720.0000
General
dbfile0.00060.0410100.0001
String conversion0.00000.000740.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
4content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 10
 Number of unique templates used: 5

Time used to render debug report: 0.0002 secs