Primer commit del sistema avantika sin cambios
This commit is contained in:
32
javascript/inventario-liberar.js
Executable file
32
javascript/inventario-liberar.js
Executable file
@@ -0,0 +1,32 @@
|
||||
function LiberarProductos(){
|
||||
|
||||
var resp = confirm("Esta seguro de liberar los productos para esta sucursal?");
|
||||
|
||||
if(!resp)
|
||||
return;
|
||||
|
||||
new Ajax.Request(WEB_ROOT+'/ajax/inventario.php',{
|
||||
method:'post',
|
||||
parameters: {type:"liberarProductos"},
|
||||
onLoading: function(){
|
||||
$("loader").innerHTML = LOADER2;
|
||||
},
|
||||
onSuccess: function(transport){
|
||||
var response = transport.responseText || "no response text";
|
||||
var splitResponse = response.split("[#]");
|
||||
|
||||
$("loader").innerHTML = '';
|
||||
|
||||
if(splitResponse[0] == "ok")
|
||||
ShowStatus(splitResponse[1]);
|
||||
else if(splitResponse[0] == "fail")
|
||||
ShowStatus(splitResponse[1]);
|
||||
else
|
||||
alert("Ocurrio un error al liberar los productos");
|
||||
|
||||
HideFview();
|
||||
},
|
||||
onFailure: function(){ alert('Something went wrong...') }
|
||||
});
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user