예제 #1
0
 /**
  * If the current version number is not set, it looks in DB
  * else it takes it from the static property current_version.
  * TODO: compare it with a document_id, because current_version is only independent from same document
  */
 public static function getCurrentVersionNb($id, $lang)
 {
     if (!isset(self::$current_version)) {
         self::$current_version = Document::getCurrentVersionNumberFromIdAndCulture($id, $lang);
     }
     return self::$current_version;
 }