Yii Framework Forum: Display Tooltip After Gridview Updates Using Ajax - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Display Tooltip After Gridview Updates Using Ajax Rate Topic: -----

#1 User is offline   SnitramDev 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 21-August 13

Posted 21 August 2013 - 09:50 AM

Hi,

I use yiiGridView javascript function to automatically update a gridview with contacts for every 4 seconds (using setInterval).
When the mouse is over one of the "view", "edit" or "delete" buttons, there is always a tooltip that shows up (I'm using yii bootstrap extension to have a better graphic design for the tooltips). However, when the ajax request updates the gridview, the tooltip disappears and never shows again in google chrome, unless I move the mouse again. In firefox and IE, the tooltip hides but then it automatically shows up again. Is there any function I can call in order to force the tooltip that was displaying to display again if the mouse continues in the same position as before? I guess I would have to call such function in the complete function of yiiGridView right? Can anyone please help me?

Here is the JS code that I use to automatically update the grid view:

setInterval(function(){
	$('#contact-grid').yiiGridView('update', {
	        data: $(this).serialize(),
		complete: function(jqXHR, status) {

		}
	});
},4000)


Thank you very much.
0

#2 User is offline   Ankit Modi 

  • Master Member
  • PipPipPipPip
  • Yii
  • Group: Members
  • Posts: 873
  • Joined: 19-February 13
  • Location:India

Posted 22 August 2013 - 12:16 AM

Hi,
i am not sure it's use for that because i am not use the boostrap extesion..
but i hope it's may be some little help..please see it..

http://www.yiiframew...idview-dynamic/

and one thing id you can page render or renderPartial pass a processOutput.. (false and true)

like..
$this->rendePartial('admin',array('model'=>$model),false,true)

Thanks,
Ankit Modi
Skype : amodi06
0

#3 User is offline   SnitramDev 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 21-August 13

Posted 22 August 2013 - 06:22 AM

View PostAnkit Modi, on 22 August 2013 - 12:16 AM, said:

Hi,
i am not sure it's use for that because i am not use the boostrap extesion..
but i hope it's may be some little help..please see it..

http://www.yiiframew...idview-dynamic/

and one thing id you can page render or renderPartial pass a processOutput.. (false and true)

like..
$this->rendePartial('admin',array('model'=>$model),false,true)



Hi,

Thank you for your answer. I did what you said, but unfortunately, in google chrome the tooltip disappears and doesn't show up again unless I move the mouse or click the tooltip. I even tried to simulate a click event on the tooltips class after the grid is updated, but the tooltip still don't show again. The only way for now is to move the mouse a little bit or just click the tooltip and it shows up... It's a bit annoying for the user to have the tooltips closed every time, because the update has to be done every 4 seconds.

If anyone has any suggestions to solve this issue please tell me.

Thank you.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users