Changeset 1383


Ignore:
Timestamp:
Sep 13, 2010, 7:48:49 PM (10 years ago)
Author:
roux
Message:

ordre rss par date corrigé

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpc/trunk/project/apps/frontend/modules/parlementaire/actions/actions.class.php

    r1378 r1383  
    370370
    371371  public static function dateSort($a, $b) {
    372     return str_replace('-', '', $b->updated_at) - str_replace('-', '', $a->updated_at);
     372    $datea = $a->updated_at;
     373    $dateb = $b->updated_at;
     374    if (get_class($a) === 'Texteloi')
     375      $datea = $a->date;
     376    if (get_class($b) === 'Texteloi')
     377      $datea = $b->date;
     378    return str_replace('-', '', $dateb) - str_replace('-', '', $datea);
    373379  }
    374380  public function executeRss(sfWebRequest $request) {
Note: See TracChangeset for help on using the changeset viewer.