Development

Changeset 5343

You must first sign up to be able to contribute.

Changeset 5343

Show
Ignore:
Timestamp:
10/02/07 18:03:58 (1 year ago)
Author:
xavier
Message:

made getComments more flexible - closes #2312

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • plugins/sfPropelActAsCommentableBehaviorPlugin/trunk/README

    r5292 r5343  
    201201== Changelog == 
    202202 
     203=== trunk === 
     204 * made getComments() more flexible (closes #2312, thanks to FrankStelzer) 
     205 
    203206=== version 0.2 - 2007-09-26 === 
    204207 * added a Symfony module for posting and displaying comments 
  • plugins/sfPropelActAsCommentableBehaviorPlugin/trunk/lib/sfPropelActAsCommentableBehavior.class.php

    r5290 r5343  
    9696   * @return     Array 
    9797   */ 
    98   public function getComments(BaseObject $object, $options = array()
     98  public function getComments(BaseObject $object, $options = array(), Criteria $criteria = null
    9999  { 
    100     $c = new Criteria(); 
     100    if ($criteria != null) 
     101    { 
     102      $c = clone $criteria; 
     103    } 
     104    else 
     105    { 
     106      $c = new Criteria(); 
     107    } 
     108 
    101109    $c->add(sfCommentPeer::COMMENTABLE_ID, $object->getPrimaryKey()); 
    102110    $c->add(sfCommentPeer::COMMENTABLE_MODEL, get_class($object));