EasyUI Forum
May 04, 2024, 05:40:06 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Tabs Loading-Message  (Read 6832 times)
Max Lamda
Newbie
*
Posts: 48


View Profile
« on: November 24, 2015, 09:05:17 AM »

How to I change the message which is displayed when the tabs add-function is called with an URL?

         $('#maintabs').tabs('add',{
            id: 'rectab-' + uni,
            border:false,
            title: 'rectab-' + uni,
            href: url,
            loadMsg: 'Daten werden vom Server geladen.',
            closable:true
         });

does not display the message.
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #1 on: November 24, 2015, 07:08:30 PM »

Please use the 'loadingMessage' property to display the loading message.
Logged
arma
Full Member
***
Posts: 110


View Profile
« Reply #2 on: November 26, 2015, 04:07:29 AM »

Hi Jarry,

Rather than displaying loadingMessage text, can i simply use one large animated icon only in the of tab content centered vertically and horizontally ?

Thanks.
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #3 on: November 26, 2015, 11:57:35 PM »

You can call 'showMask' method to display a centered message before loading the panel content, and then call 'hideMask' method to hide it after loaded the panel content successfully. These two methods are extended from http://www.jeasyui.com/forum/index.php?topic=3641.0

Code:
$('#tt').tabs('add',{
    id: 'rectab-',
    border:false,
    title: 'rectab-',
    href: url,
    loadingMessage: '',
    closable:true,
    onBeforeLoad: function(){
        $(this).panel('showMask','<div class="panel-loading">Daten werden vom Server geladen.</div>')
    },
    onLoad: function(){
        $(this).panel('hideMask')
    }
});
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!