public function DeleteFile(PluginReceptiondesk_ModuleTools_EntityFile $oFile)
 {
     $sql = "DELETE FROM " . Config::Get('db.table.receptiondesk_files') . " WHERE file_id=?d;";
     if ($aRow = $this->oDb->query($sql, $oFile->getId()) != false) {
         return true;
     }
     return false;
 }
Example #2
0
 public function RemoveAdditionalData(PluginReceptiondesk_ModuleTools_EntityFile $oFile)
 {
     $this->Image_RemoveFile($this->Image_GetServerPath($oFile->getWebPath()));
     foreach (Config::Get('plugin.receptiondesk.receptiondesk_create_file_array_size') as $aSize) {
         $sSize = $aSize['w'];
         if ($aSize['crop']) {
             $sSize .= 'crop';
         }
         $this->Image_RemoveFile($this->Image_GetServerPath($oFile->getWebPath($sSize)));
     }
 }