How to force a datatype Selection with required?

Author Message

christian bencivenni

Tuesday 20 March 2007 2:51:23 am

Hi to you all.
Working with new classes and templates of my installation of ez 3.9rc1 I noted a strange thing.
I created a new class object for a form to compile.
Many of the attributes are Selection datatype type. I added options in this way:
1. Select from the list
2. Option a
3. Option b
4. Option c
and so on.
The problem is that the attribute is required, but with the line 1 if the user don't make a selection the object is stored anyway.
There is some trick to change this fact?
Something like a template code block?
Thanks in advance.

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 18 2025 18:25:33
Script start
Timing: Jan 18 2025 18:25:33
Module start 'layout'
Timing: Jan 18 2025 18:25:33
Module start 'content'
Timing: Jan 18 2025 18:25:34
Module end 'content'
Timing: Jan 18 2025 18:25:34
Script end

Main resources:

Total runtime1.0597 sec
Peak memory usage4,096.0000 KB
Database Queries46

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0061 589.1563152.6406
Module start 'layout' 0.00610.0067 741.796939.4766
Module start 'content' 0.01281.0456 781.2734400.9766
Module end 'content' 1.05840.0013 1,182.25008.1250
Script end 1.0597  1,190.3750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00330.3080160.0002
Check MTime0.00130.1273160.0001
Mysql Total
Database connection0.00110.099810.0011
Mysqli_queries1.020496.2902460.0222
Looping result0.00050.0429440.0000
Template Total0.988193.220.4940
Template load0.00200.189120.0010
Template processing0.986193.050120.4930
Template load and register function0.00030.023910.0003
states
state_id_array0.00230.220310.0023
state_identifier_array0.00240.229420.0012
Override
Cache load0.00170.1559160.0001
Sytem overhead
Fetch class attribute can translate value0.00080.071510.0008
Fetch class attribute name0.00090.084010.0009
XML
Image XML parsing0.00010.012310.0001
class_abstraction
Instantiating content class attribute0.00000.003210.0000
General
dbfile0.00070.0659100.0001
String conversion0.00000.000840.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
1content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 5
 Number of unique templates used: 5

Time used to render debug report: 0.0001 secs