[*] BO : HelpAccess helper

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@12179 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
fBrignoli
2012-01-05 10:54:42 +00:00
parent e5535f61c0
commit 7a655974d8
12 changed files with 179 additions and 132 deletions
+23 -25
View File
@@ -1,25 +1,23 @@
$(document).ready(function(){
if($('.help-context'))
{
$.ajax({
type: 'POST',
url: 'index.php',
data: {
'ajax' : '1',
'action' : 'helpAccess',
'item' : class_name,
'isoUser' : iso_user,
'country' : country_iso_code,
'version' : _PS_VERSION_
},
async : true,
success: function(msg) {
if(msg.status == 'ok' && msg.content != 'none')
{
$(".help-context").html(msg.content);
$(".help-context").fadeIn("slow").show();
}
}
});
}
});
function getHelpButton(label){
var button = '';
$.ajax({
type: 'POST',
url: 'index.php',
data: {
'ajax' : 1,
'action' : 'helpAccess',
'item' : label,
'isoUser' : iso_user,
'country' : country_iso_code,
'version' : _PS_VERSION_
},
dataType: "json",
async : false,
success: function(msg) {
if(msg.content != 'none' && msg.content != '')
button = msg.content;
}
});
return button;
}