static function fetchExpiryNotificationPendingList()
    {
        $currentTime = time();
        $conds = array( 'expirationnotification_sent' => 0,
                        'passwordlifetime' => array( '>', 0 ) );

        $customConds = ' AND (passwordlifetime *86400 - (' . $currentTime . ' - password_last_updated ) ) < expirationnotification ';

        $userClassIDs = array();
        foreach ( eZUser::fetchUserClassList( true ) as $userClass )
        {
            $userClassIDs[] = $userClass->attribute( 'id' );
        }
        if ( empty( $userClassIDs ) )
        {
            return array();
        }
        $customConds .= ' AND ezcontentobject.id = contentobject_id ';
        $customConds .= ' AND ' . eZDB::instance()->generateSQLINStatement( $userClassIDs, 'ezcontentobject.contentclass_id' );

        return eZPersistentObject::fetchObjectList( eZPaEx::definition(),
                                                    null,
                                                    $conds,
                                                    null,
                                                    null,
                                                    true,
                                                    false,
                                                    null,
                                                    array( 'ezcontentobject' ),
                                                    $customConds );
    }
static function fetchExpiryNotificationPendingList()
    {
        $currentTime = time();
        $conds = array( 'expirationnotification_sent' => 0,
                        'passwordlifetime' => array( '>', 0 ) );

        $customConds = ' AND (passwordlifetime *86400 - (' . $currentTime . ' - password_last_updated ) ) < expirationnotification ';

        $userClassIDs = array();
        foreach ( eZUser::fetchUserClassList( true ) as $userClass )
        {
            $userClassIDs[] = $userClass->attribute( 'id' );
        }
        if ( empty( $userClassIDs ) )
        {
            return array();
        }
        $customConds .= ' AND ezcontentobject.id = contentobject_id ';
        $customConds .= ' AND ' . eZDB::instance()->generateSQLINStatement( $userClassIDs, 'ezcontentobject.contentclass_id' );

        return eZPersistentObject::fetchObjectList( eZPaEx::definition(),
                                                    null,
                                                    $conds,
                                                    null,
                                                    null,
                                                    true,
                                                    false,
                                                    null,
                                                    array( 'ezcontentobject' ),
                                                    $customConds );
    }
static function fetchExpiryNotificationPendingList ( ) { $ currentTime = time ( ) ; $ conds = array ( 'expirationnotification_sent' => 0 , 'passwordlifetime' => array ( '>' , 0 ) ) ; $ customConds = ' AND (passwordlifetime *86400 - (' . $ currentTime . ' - password_last_updated ) ) < expirationnotification ' ; $ userClassIDs = array ( ) ; foreach ( eZUser :: fetchUserClassList ( true ) as $ userClass ) { $ userClassIDs [ ] = $ userClass -> attribute ( 'id' ) ; } if ( empty ( $ userClassIDs ) ) { return array ( ) ; } $ customConds .= ' AND ezcontentobject.id = contentobject_id ' ; $ customConds .= ' AND ' . eZDB :: instance ( ) -> generateSQLINStatement ( $ userClassIDs , 'ezcontentobject.contentclass_id' ) ; return eZPersistentObject :: fetchObjectList ( eZPaEx :: definition ( ) , null , $ conds , null , null , true , false , null , array ( 'ezcontentobject' ) , $ customConds ) ; }
Fetch the eZPaEx objects that have their password about to expire

@return array of eZPaEx objects corresponding to users that have to be notified
Fetch the eZPaEx objects that have their password about to expire