initial commit from rev. 632

This commit is contained in:
Erik Amaru Ortiz
2010-12-02 23:34:41 +00:00
commit 0525681d79
5410 changed files with 864427 additions and 0 deletions

View File

@@ -0,0 +1,45 @@
var plugin;
/**
* function showMessage
* @author gustavo cruz gustavo-at-colosa-dot-com
* @param message the message to show
* @param pluginUid pluginUid or plugin name
* @desc function that invoques a msgBox call with the removePlugin function
* as argument.
**/
function showMessage(message, pluginUid){
plugin = pluginUid;
msgBox(message, "confirm", removePlugin);
}
/**
* function removePlugin
* @author gustavo cruz gustavo-at-colosa-dot-com
* @desc function that executes a rpc and takes the server response into
* another message.
**/
function removePlugin(){
var callServer = new leimnud.module.rpc.xmlhttp({
url : 'pluginsRemove',
async : false,
method : 'POST',
args : 'pluginUid=' + plugin
});
callServer.make();
var response = callServer.xmlhttp.responseText;
msgBox(response, 'alert', refresh);
}
/**
* function refresh
* @author gustavo cruz gustavo-at-colosa-dot-com
* @desc a trivial but necesary function that reload a page, since the msgBox
* can only take functions with no arguments attached.
**/
function refresh(){
location.href = "pluginsList";
}

View File

@@ -0,0 +1,25 @@
/*upgrade system routine*/
function upgradeSystem(wsCount) {
document.getElementById("form[THETITLE3]").innerHTML = wsCount + " workspaces to update.";
document.getElementById("form[SUBTITLE4]").innerHTML = "&nbsp;&nbsp;<img src='/images/alert.gif' width='13' height='13' border='0'> Please wait...";
updateWorkspace(wsCount);
};
function updateWorkspace(id) {
if(id < 0){
return false;
}
var oRPC = new leimnud.module.rpc.xmlhttp({
async : true,
method: "POST",
url: "../setup/upgrade_SystemAjax",
args : "id=" + id
});
oRPC.callback = function(rpc) {
document.getElementById("form[SUBTITLE4]").innerHTML = rpc.xmlhttp.responseText;
updateWorkspace(id-1)
}.extend(this);
oRPC.make();
};