Ignore:
Timestamp:
03/21/11 17:46:35 (14 years ago)
Author:
alexandrecorreia
Message:

Ticket #1657 - Correcao de layout para exibicao do historico do arquivo

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2/filemanager/js/draw_api.js

    r3879 r3885  
    1515} 
    1616 
    17 function loadHistory(filename){ 
    18         cExecute_('./index.php?menuaction=filemanager.uifilemanager.history&file='+base64_encode(filename)+"&path="+base64_encode(currentPath),draw_window); 
     17function loadHistory(filename) 
     18{ 
     19        var handlerLoadHistory = function(data) 
     20        { 
     21                loadXtools(); 
     22 
     23                var response =  unserialize(data); 
     24                var _xml                = Xtools.xml('file'); 
     25                var _historyFile        = _xml.documentElement;  
     26 
     27                for( var i = 0; i < response.length; i++ ) 
     28                { 
     29                        var _info = _historyFile.appendChild(  _xml.createElement("info") ); 
     30                         
     31                        var     _created = _xml.createElement('created');  
     32                                _created.appendChild( _xml.createTextNode(response[i]['created']) ); 
     33                                _info.appendChild( _created ); 
     34                         
     35                        var     _version = _xml.createElement('version'); 
     36                                _version.appendChild( _xml.createTextNode(response[i]['version']) ); 
     37                                _info.appendChild(_version); 
     38                         
     39                        var     _who = _xml.createElement('who'); 
     40                                _who.appendChild( _xml.createTextNode(response[i]['who']) ); 
     41                                _info.appendChild( _who ); 
     42                         
     43                        var _operation  = _xml.createElement('operation'); 
     44                                _operation.appendChild( _xml.createTextNode( response[i]['operation']) ); 
     45                                _info.appendChild( _operation ); 
     46                } 
     47 
     48                var pArgs =  
     49                { 
     50                        'lang_created'  : get_lang("Created"), 
     51                        'lang_operation'        : get_lang("Operation"), 
     52                        'lang_version'  : get_lang("Version"), 
     53                        'lang_who'              : get_lang("Who"), 
     54                        'lang_history'  : get_lang("File history"), 
     55                        'height'                                : 300, 
     56                        'path_filemanager'      : path_filemanager, 
     57                        'width'                         : 450                    
     58                }; 
     59                 
     60                var code = Xtools.parse( _historyFile, "historyFile.xsl", pArgs ); 
     61                 
     62                draw_window( code , 450, 300 ); 
     63        }; 
     64         
     65        cExecute_('./index.php?menuaction=filemanager.uifilemanager.history&file=' 
     66                                + base64_encode(filename)+"&path="+base64_encode(currentPath), handlerLoadHistory ); 
    1967} 
    2068 
Note: See TracChangeset for help on using the changeset viewer.