X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=manifold%2Fjs%2Fmanifold.js;h=5c43e71fec442c3b24bb7b33197dc1a6dd87d806;hb=28994fa4ca7312850f9899adc67e71660a4a753d;hp=c3aac9fbdf997c26f5b44755078df0408f213259;hpb=07411e389a9d39ddccfd93cd53ac895393a8ae3a;p=unfold.git diff --git a/manifold/js/manifold.js b/manifold/js/manifold.js index c3aac9fb..5c43e71f 100644 --- a/manifold/js/manifold.js +++ b/manifold/js/manifold.js @@ -247,6 +247,7 @@ var manifold = { if (!!callback) { callback(data); return; } if (data.code == 2) { // ERROR + // We need to make sense of error codes here alert("Your session has expired, please log in again"); window.location="/logout/"; return; @@ -255,6 +256,15 @@ var manifold = { messages.error("Some errors have been received from the manifold backend at " + MANIFOLD_URL + " [" + data.description + "]"); // publish error code and text message on a separate channel for whoever is interested jQuery.publish("/results/" + publish_uuid + "/failed", [data.code, data.description] ); + + $("#notifications").notify("create", "sticky", { + title: 'Warning', + text: data.description + },{ + expires: false, + speed: 1000 + }); + } // once everything is checked we can use the 'value' part of the manifoldresult var result=data.value;