ajout d'un joli message d'erreur.
darcs-hash:20070131000904-f46e9-311acc4b1e8206748e1a1bca6287389bd2ba4cbf.gz
This commit is contained in:
parent
a9839b576b
commit
7ae76132b7
2 changed files with 35 additions and 0 deletions
|
@ -211,6 +211,20 @@ div.visualClear {clear:both;}
|
|||
background: center left no-repeat url('/static/images/crans_mini_warning.png');
|
||||
}
|
||||
|
||||
.crans_ajax_error {
|
||||
font-weight: bold;
|
||||
font-size: 1em;
|
||||
border-bottom : thin gray solid;
|
||||
display: block;
|
||||
width:100%;
|
||||
position: absolute;
|
||||
top:0;
|
||||
left:0;
|
||||
padding:1em 1em 1em 25px;
|
||||
z-index:100;
|
||||
background: #fff88f center left no-repeat url('/static/images/crans_mini_warning.png');
|
||||
}
|
||||
|
||||
.crans_signature {
|
||||
text-align: right;
|
||||
display: block;
|
||||
|
|
21
intranet/static/scripts/AJAX.js
Normal file
21
intranet/static/scripts/AJAX.js
Normal file
|
@ -0,0 +1,21 @@
|
|||
/*****************************
|
||||
Impression.AJAX
|
||||
*****************************/
|
||||
AJAX = {};
|
||||
|
||||
|
||||
AJAX.call = function(page, callBack) {
|
||||
logDebug("calling AJAX : " + page);
|
||||
var e = loadJSONDoc(page);
|
||||
e.addCallback(callBack);
|
||||
e.addErrback(AJAX.errorHandler);
|
||||
}
|
||||
|
||||
AJAX.errorHandler = function(d) {
|
||||
appendChildNodes(document.body,
|
||||
DIV({"class":"crans_ajax_error"}, "Erreur de communication, essayez de vous ", A({"href":"do_logout"}, "reconnecter"), "."));
|
||||
logError("AJAX Error: " + d);
|
||||
//Impression.AJAX.modifPrix("Erreur...", false);
|
||||
}
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue