modified 进一步完善js加载机制,去除无用多余加载!

This commit is contained in:
zhaoxiang 2016-11-08 10:59:43 +08:00
parent f224c62b9e
commit 126e518f02

View File

@ -88,10 +88,15 @@ function refresh( url ) {
success: function(data){
if( data.code == 200 ){
if( data.data.tempType == 'table' ){
$.getScript('/static/js/template/table.js', function (){
if( $.buildTable ){
$('#content').html($.buildTable(data.data));
$('#tableBox').hide().fadeIn(800);
});
}else{
$.getScript('/static/js/template/table.js', function (){
$('#content').html($.buildTable(data.data));
$('#tableBox').hide().fadeIn(800);
});
}
}
}else{
$.alertMsg('请求失败!')