Forum

July 12th, 2025
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
Editoptions it´s possible to add a textbox and a link image??
27/08/2009
16:59
Avatar
edgar9000
Member
Members
Forum Posts: 14
Member Since:
22/08/2009
sp_UserOfflineSmall Offline

I'm using the jqgrid with editform but I want to add a textbox and a link image in the same option, it´s possible??

I mean when I'm editing the selected row I want to display a textbox to write the value and a image that when I click on this, display a popup menu that let me choose some default values for this box.

colModel: [
                            { name: 'Id', index: 'Id', width: 60,hidden:true, align: 'left', editable:false },
                            { name: 'Concepto', index: 'Concepto', width: 50, align: 'left', editable:true, edittype: "select"},
                            { name: 'Descripcion', index: 'Descripcion', width: 90, align: 'left', editable:true, editoptions:{size:10}, editrules: { required: true }},                          
                            { name: 'Cant', index: 'Cant', width: 10, align: 'right', editable:true, editoptions:{size:10}, editrules: { required: true, minValue: 0, number: true } },
                            { name: 'Vlr_unit', index: 'Vlr_unit', width: 18, align: 'right', editable:true, editoptions:{size:10, image+onclick event }, editrules: { required: true, minValue: 0, number: true  } },
                            { name: 'Vlr_parc', index: 'Vlr_parc', width: 20, align: 'right', editable:false, editoptions:{size:10} },
                         ],

I have resalted the piece of code that I'm interested in. Any help will be very appreciate

Thanks in advance...

31/08/2009
05:38
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Use dataInit event (see docs) to adda image and a click event to this image.

Best 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.

04/12/2009
18:36
Avatar
edgar9000
Member
Members
Forum Posts: 14
Member Since:
22/08/2009
sp_UserOfflineSmall Offline

Hi,

I've seen the documentation about the datainit event but I'm not sure about how I can add the image with the onclick event at the side of my textbox, I've tried adding the html code to show the image using the functions .html() and .append() of jquery but it didn't worked, please can you show me how I  have to do to accomplish what I want to do.

Thanks in advance ...

05/12/2009
15:49
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

You can use the newly option custom element.

More you can find here:

http://www.trirand.com/jqgridw.....m#edittype

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: 994

Currently Online:
43 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