~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/filesystem/browser/media/browser.js

When submitting, query the server about the latest revision of the path.

Show diffs side-by-side

added added

removed removed

Lines of Context:
852
852
        else
853
853
            stat = current_file;
854
854
        path = stat.svnurl.substr(svn_base.length);
855
 
        window.location = path_join(app_path('+submit'), path) + '?revision=' + stat.svnrevision;
 
855
 
 
856
        /* The working copy might not have an up-to-date version of the
 
857
         * directory. While submitting like this could yield unexpected
 
858
         * results, we should really submit the latest revision to minimise
 
859
         * terrible mistakes - so we run off and ask fileservice for the
 
860
         * latest revision.*/
 
861
        $.post(app_path(service_app, current_path),
 
862
            {"action": "svnrepostat", "path": path},
 
863
            function(result)
 
864
            {
 
865
                window.location = path_join(app_path('+submit'), path) + '?revision=' + result.svnrevision;
 
866
            },
 
867
            "json");
 
868
 
856
869
        break;
857
870
    case "rename":
858
871
        action_rename(filename);