Limit class choice in admin

Author Message

Jérôme Vieilledent

Friday 12 October 2007 8:34:07 am

Hello,

Il would like to know if it was possible to limit the choice of classes for creation, depending on the parent object type, or the node...
I saw in the admin that when you're on the user accounts tab, the system forces you to create only user groups or users. Is it possible to do the same in the content tree ?

Thanks :-)

Mark Marsiglio

Friday 12 October 2007 9:03:47 am

You can do this with the roles and policies. The only caveat is that you cannot change it for admin level users because their permissions are set to all access.

We do this for our editors by setting parent node based permissions. So, users can create an Event only if the parent class is Calendar. What happens is we end up with a limited list of class choices that are the containers, and then separate lists of choices depending on the type of container the user to attempting to add a sub-item to.

http://www.thinkcreative.com
Turning Ideas Into Strategic Solutions

Mark Marsiglio

Friday 12 October 2007 9:06:06 am

Our policies look like this:
content create Class( FAQ Question ) , ParentClass( FAQ List )
content create Class( Event ) , ParentClass( Calendar )
content create Class( Forum topic ) , ParentClass( Forum )
content create Class( Forum reply ) , ParentClass( Forum topic )

The editing rights are much more basic, but the content create module allows very fine control. We then apply these rules with subtree limitations to control where different user groups can create new content.

http://www.thinkcreative.com
Turning Ideas Into Strategic Solutions

Jérôme Vieilledent

Friday 12 October 2007 9:22:12 am

Thanks Mark, now I understand :-)

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 03:23:26
Script start
Timing: Jan 19 2025 03:23:26
Module start 'layout'
Timing: Jan 19 2025 03:23:26
Module start 'content'
Timing: Jan 19 2025 03:23:27
Module end 'content'
Timing: Jan 19 2025 03:23:27
Script end

Main resources:

Total runtime1.3660 sec
Peak memory usage4,096.0000 KB
Database Queries60

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0066 589.1563152.6250
Module start 'layout' 0.00660.0035 741.781339.4453
Module start 'content' 0.01011.3545 781.2266560.1172
Module end 'content' 1.36460.0014 1,341.343812.4766
Script end 1.3660  1,353.8203 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.2365160.0002
Check MTime0.00130.0980160.0001
Mysql Total
Database connection0.00060.043910.0006
Mysqli_queries1.313096.1213600.0219
Looping result0.00060.0437580.0000
Template Total1.322496.820.6612
Template load0.00160.120420.0008
Template processing1.320896.688520.6604
Template load and register function0.00010.009610.0001
states
state_id_array0.00150.112710.0015
state_identifier_array0.00130.098720.0007
Override
Cache load0.00140.0989230.0001
Sytem overhead
Fetch class attribute can translate value0.00070.053520.0004
Fetch class attribute name0.00110.084060.0002
XML
Image XML parsing0.00140.099620.0007
class_abstraction
Instantiating content class attribute0.00000.001080.0000
General
dbfile0.00130.0923220.0001
String conversion0.00000.000640.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
4content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/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: 17
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs