本文整理匯總了PHP中eZInformationCollection::definition方法的典型用法代碼示例。如果您正苦於以下問題:PHP eZInformationCollection::definition方法的具體用法?PHP eZInformationCollection::definition怎麽用?PHP eZInformationCollection::definition使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類eZInformationCollection
的用法示例。
在下文中一共展示了eZInformationCollection::definition方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: fetchCollectionsCount
static function fetchCollectionsCount( $contentObjectID = false, $creatorID = false, $userIdentifier = false )
{
$conditions = array();
if ( is_numeric( $contentObjectID ) )
$conditions = array( 'contentobject_id' => $contentObjectID );
if ( is_numeric( $creatorID ) )
$conditions['creator_id'] = $creatorID ;
if ( $userIdentifier )
$conditions['user_identifier'] = $userIdentifier;
$resultSet = eZPersistentObject::fetchObjectList( eZInformationCollection::definition(),
array(),
$conditions,
false,
null,
false,
false,
array( array( 'operation' => 'count( id )',
'name' => 'count' ) ) );
return $resultSet[0]['count'];
}
示例2: set_time_limit
set_time_limit($exportExecutionTimeLimit);
$object = false;
$exportCreationDate = false;
$exportModificationDate = false;
if (is_numeric($objectID)) {
$object = eZContentObject::fetch($objectID);
}
if (!$object) {
return $module->handleError(EZ_ERROR_KERNEL_NOT_AVAILABLE, 'kernel');
}
$conditions = array('contentobject_id' => $objectID);
$dateConditions = bccieExportUtils::getDateConditions($http);
if ($dateConditions['conditions'] != null) {
$conditions['created'] = $dateConditions['conditions'];
}
$collections = eZPersistentObject::fetchObjectList(eZInformationCollection::definition(), null, $conditions, false, false);
// TODO: change error handler
if (!$collections) {
return $module->handleError(EZ_ERROR_KERNEL_NOT_AVAILABLE, 'kernel');
}
$counter = 0;
$attributesToExport = array();
while (true) {
$currentattribute = $http->postVariable("field_{$counter}");
if (!$currentattribute) {
break;
}
$attributesToExport[] = $currentattribute;
$counter++;
}
if ($http->hasPostVariable("creation_date")) {