Changeset 2954

Show
Ignore:
Timestamp:
07/24/08 15:33:53 (1 month ago)
Author:
gcroes
Message:

Possibilité de réinitialiser l'arbre, ajout d'une méthode pour créer une arbo de test

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/project/modules/devel/cms3/heading/classes/headingservices.class.php

    r2949 r2954  
    9696        return $path; 
    9797    } 
     98     
     99    /** 
     100     * Supression de l'ensemble de la table des rubriques 
     101     */ 
     102    public function reset (){ 
     103        CopixDB::begin (); 
     104        try { 
     105            _dao ('heading')->deleteBy (_daoSp ()->addCondition ('id_head', '<>', 0)); 
     106            _dao ('headingelementinformation')->deleteBy (_daoSp ()->addCondition ('type_hei', '=', 'heading')); 
     107        }catch (CopixException $e){ 
     108            CopixDb::rollback (); 
     109            throw $e; 
     110        } 
     111        CopixDB::commit (); 
     112    } 
    98113}