Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
navigate in add inline form
30/11/2009
13:35
Avatar
Cyril
Guest
Guests
vote down star

Hi !

I'm trying to add next/prev buttons in the default add in form of a jqgrid. Do you have any idea or example to help me? I could add my own buttons, but I'd like to call the same function as framework to navigate...

Another solution would be to simulate that, opening the edit form  when user click previous.

Well, I'm stuck.

Thanks in advance.

Cyril

30/11/2009
13:56
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Did you mean to see the buttons prev/next in Form editing when we are in add mode?

This is possible, but you will have trouble when you use them.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

30/11/2009
14:09
Avatar
Cyril
Guest
Guests

(thanks for your fast answer).

Yes, this is what I mean. Having prev and next button in this case.

I was able to add buttons, doing something like that

                                navButtons = '<img style="cursor:pointer" onclick="browseSample('+(parseInt(msg)+1)+')" src="design/themes/basic/images/'+imgPrev+'" style="display: inline;"/>';
                                navButtons += '<img style="cursor:pointer"  onclick="browseSample('+(parseInt(msg)+1)+')" src="design/themes/basic/images/'+imgNext+'" style="display: inline;"/>';
                                $("#Act_Buttons td").eq(0).html(navButtons);

But I tried several ways to simulate navigation in my browseSample() function without success. Then I thought that maybe the best way is to call the same code than framework.

I'm getting lost. THe final goal is to be able to browse the data just after add a new record.

30/11/2009
14:14
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Use beforeShowForm in add mode like this

beforeShowForm : function (formid) {

$("#pData, #nData",formid).show();

}

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

30/11/2009
15:18
Avatar
Cyril
Guest
Guests

Ok! Great!

My navigation arrows appear on my add form. But nothing append (of course) when I press them.

I guess that's why you wrote

"but you will have trouble when you use them."

Do you have an idea of the best way to make them work?

Thanks again for your help and you time.

Cyril

30/11/2009
17:59
Avatar
Cyril
Guest
Guests

Or maybe there a trick to turn the mode's form on the fly?

I suspect that next/prev buttons could work with just a lie Laugh Yes! you are in edit mode !

no?!

02/12/2009
09:45
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

They work well, but since there is no value in the add form for the id we can  not determine where to move.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
60 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information