oxerpcompatability.php

Go to the documentation of this file.
00001 <?php
00002 
00006 class oxERPCompatability
00007 {
00008 
00014     public function __construct()
00015     {
00016     }
00017 
00025     public function getPkgRevision($sBasePath = null)
00026     {
00027         $sFile = (!$sBasePath?getShopBasePath():$sBasePath).'/pkg.rev';
00028 
00029         if (is_readable($sFile)) {
00030             return (int) trim(file_get_contents($sFile));
00031         }
00032         // TODO: return newest (HEAD)
00033         return 999999999; //13895;
00034     }
00035 
00041     public function getShopRevision()
00042     {
00043         $oConfig   = oxConfig::getInstance();
00044 
00045         if (method_exists( $oConfig, 'getRevision' )) {
00046             $sRevision = $oConfig->getRevision();
00047             if ($sRevision !== false) {
00048                 return $sRevision;
00049             }
00050         }
00051 
00052         return $this->getPkgRevision();
00053     }
00054 
00062     public function isPasswordSaltSupported($iRev = null)
00063     {
00064         if (!$iRev) {
00065             $iRev = $this->getShopRevision();
00066         }
00067         return $iRev >= 14455;
00068     }
00069 
00078     public function isPasswordSaltInOxUser($iRev = null)
00079     {
00080         if (!$iRev) {
00081             $iRev = $this->getShopRevision();
00082         }
00083         return $iRev >= 14842;
00084     }
00085 
00093     public function isOrderArticleStockAsDouble($iRev = null)
00094     {
00095         if (!$iRev) {
00096             $iRev = $this->getShopRevision();
00097         }
00098         return $iRev >= 14260;
00099     }
00100 
00108     public function isArticleNullLongDescComatable($iRev = null)
00109     {
00110         if (!$iRev) {
00111             $iRev = $this->getShopRevision();
00112         }
00113         return $iRev >= 14036;
00114     }
00115 
00123     public function isArticleVariantMinPriceAllwaysUpdated($iRev = null)
00124     {
00125         if (!$iRev) {
00126             $iRev = $this->getShopRevision();
00127         }
00128         return $iRev < 14260;
00129     }
00130 
00131 }

Generated on Mon Oct 26 20:07:16 2009 for OXID eShop CE by  doxygen 1.5.5