Changeset 1154 for trunk

Show
Ignore:
Timestamp:
05/15/08 16:45:06 (7 months ago)
Author:
zothos
Message:

Fixed #1256

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/CHANGELOG

    r1153 r1154  
    55        - GUI: 
    66                * Fixed #1255: please commit these patches for an better useful/readable database update files 
     7                * Fixed #1256: admin's database update does not stop if there is an update failure 
    78 
    892008-05-15 Marc Pujol 
  • trunk/gui/admin/database_update.php

    r1153 r1154  
    7676                'TR_UPDATE_MESSAGE'             => tr('No database updates available'), 
    7777                'DATABASE_UPDATE_INFOS'         => '' 
    78         )); 
    79          
     78        ));      
    8079        $tpl->parse('DATABASE_UPDATE_MESSAGE', 'database_update_message');       
    8180} 
     
    8786} 
    8887 
    89  
    9088$tpl->parse('PAGE', 'page'); 
    9189$tpl->prnt(); 
  • trunk/gui/include/database-update-functions.php

    r1153 r1154  
    102102                } 
    103103 
    104                 // Prompt a error when a update fails 
    105                 if ($sql->HasFailedTrans()) { 
    106                         set_page_message(tr("Db update %s failed", $newRevision)); 
    107                 } 
    108  
    109                 $sql->CompleteTrans(); 
    110                 unset($queryArray);      
     104                // Prompt a error and break while-loop when a update fails 
     105                if ($sql->HasFailedTrans()) { 
     106                        set_page_message(tr("Db update %s failed", $newRevision));+                     $sql->CompleteTrans(); 
     107                         
     108                        unset($queryArray); 
     109                        break; 
     110                } else { 
     111                        $sql->CompleteTrans(); 
     112                        unset($queryArray); 
     113                } 
    111114        } 
    112115}