Issam Mouzoun
|
Thursday 10 September 2009 4:03:30 am
Hello, I would like develop a code that create a hidden node in front-office, this is my code,
$nodeAssignment = eZNodeAssignment :: create(array (
'contentobject_id' => $object->attribute('id'),
'contentobject_version' => $object->attribute('current_version'),
'parent_node' => $catNodeId,
'is_main' => 1
));
$nodeAssignment->store();
//Publication de l'objet
$object->setAttribute('status', EZ_VERSION_STATUS_DRAFT);
$object->store();
$operationResult = eZOperationHandler :: execute('content', 'publish', array (
'object_id' => $object->attribute('id'),
'version' => $object->attribute('current_version')
));
|