tim

Forum Replies Created

Viewing 15 replies - 16 through 30 (of 41 total)
  • Author
    Replies
  • in reply to: New/Edit/Del in The Demo Possible? #94504
    tim
    Participant
    in reply to: How do I add post data to the dataUrl in editoptions? #94467
    tim
    Participant

    Tony,

    My js skills are non-existent so I will not even think about checking anything in github, but here's somethin to think about:

    grid.common.js : line 246

    – function createEl(eltype,options,vl,autowidth, ajaxso) {
    + function createEl(rowid,eltype,options,vl,autowidth, ajaxso) {

    grid.common.js : line 319

    – url: options.dataUrl,
    + url: options.dataUrl+'&rowId='+rowid,

    // may want to pass a variable into define the rowId arg name

    // handle '?' vs. '&' … dependant upon url? – all mine will not require it

    grid.celledit.js : line 75

    – var elc = createEl($t.p.colModel[iCol].edittype,opt,tmp,true,$.extend({},$.jgrid.ajaxOptions,$t.p.ajaxSelectOptions || {});
    + var elc = createEl($t.rows[iRow].id,$t.p.colModel[iCol].edittype,opt,tmp,true,$.extend({},$.jgrid.ajaxOptions,$t.p.ajaxSelectOptions || {});

    grid.inlineedit.js : line 41
    – var elc = createEl(cm.edittype,opt,tmp,true,$.extend({},$.jgrid.ajaxOptions,$t.p.ajaxSelectOptions || {}));
    + var elc = createEl(rowid,cm
    .edittype,opt,tmp,true,$.extend({},$.jgrid.ajaxOptions,$t.p.ajaxSelectOptions || {}));

    grid.formedit.js : line 738
    – elc = createEl(this.edittype,opt,tmp,false,$.extend({},$.jgrid.ajaxOptions,obj.p.ajaxSelectOptions || {}));
    + elc = createEl(rowid,this.edittype,opt,tmp,false,$.extend({},$.jgrid.ajaxOptions,obj.p.ajaxSelectOptions || {}));

    tim

    in reply to: add baseLinkUrl option for link formatter #94447
    tim
    Participant

    nevermind (obviously a hack since it will ignore showAction with appendCell, but it does the trick):

    $.fn.fmatter.showlink = function(cellval, opts) {var op = {baseLinkUrl: opts.baseLinkUrl,showAction:opts.showAction, addParam: opts.addParam || “”, target: opts.target, appendCell:opts.appendCell, idName: opts.idName }, target = “”, idUrl; afterUrl = “”; if(!isUndefined(opts.colModel.formatoptions)) { op = $.extend({},op,opts.colModel.formatoptions); } if(op.target) {target = 'target=' + op.target;} if(op.appendCell){afterUrl=cellval;}else{afterUrl=op.showAction+'?'+op.idName+'='+opts.rowId;} idUrl = op.baseLinkUrl+afterUrl+op.addParam; if(isString(cellval)) { //add this one even if its blank string return “” + cellval + ““; }else { return $.fn.fmatter.defaultFormat(cellval,opts); } };

    in reply to: How do I add post data to the dataUrl in editoptions? #94418
    tim
    Participant

    bump…..

    in reply to: How do I add post data to the dataUrl in editoptions? #94374
    tim
    Participant

    Hi Tony,

    I realize you're pretty busy, but if you could please look into this a little further.

    There are 2 issues with setColProp (I have to use it with formatCell to support dynamic selectboxes) :

    1. tabbing does not support the correct event sequences as posted here:

    http://www.trirand.com/blog/?p…..bing-over/

    2. When using formatCell with setColProp, pre-existing editoptions are lost – they do not work (example add 'size: 14' to the colModels editoptions, and you'll discover formatCell kills it.)

    This is a real problem. I would rather have the column model editoptions dataUrl support post data, and I think doing this would benefit everyone for other things, but I could live with any solution that has no bugs.

    Please and Thanks,

    tim

    tim
    Participant

    OK this is still a problem.

    Moving my dataUrl from the setColProp directly to the editoptions fixed the 'tabbing' issue, but editoptions does not allow me to append the currently selected rowid.

    Tony did you get a chance to look at this?Any feedback?

    Please and Thanks,

    Tim

    tim
    Participant
    tim
    Participant

    This is no longer a problem for me, I stopped using 'setColProp' and went to straight to editoptions.

    I will leave the example up for a bit, since I still think it's a bug that should be fixed.

    Also, I have noticed that using

    in reply to: Search Problem #94261
    tim
    Participant

    Well, I'm a little confused.

    Originally you said: “the JQGrid doesn't return me nothing”. Now you're saying “when i search some information returns me both”?

    At any rate,

    in reply to: Search Problem #94257
    tim
    Participant

    Using Firebug, go to the URL that is meant to return your data.

    Is it returning data? How does the data look (good or malformed)?

    tim

    tim
    Participant

    Hi Tony…. I created a link to the problem:

    http://blackstag.com/jqDemo/de…..;PAGE.html

    Some how the event's are not working between the mousclicking over and tabbing over.

    Note that the example post twice to the server, once is the onchange event and the other is the standard submitcell event… (The reason I need 2 post events is for chaining selectboxes. Although this example does not show it – the onchange event posts the change, so the second selectbox gets the update when mouseclicking over).

    Also here are some screen shots:

    Picture 1. Mouseclicking the next cell over.

    tim
    Participant

    OK I found the problem:

    http://blackstag.com/jqDemo/de…..;PAGE.html

    Do the following with the above example:

    1. Open the searchBar using the navbutton.

    2. Run a filter: say put 'F' into the caption column then hit enter!

    3. Open the MultiSearch dialog by clicking the very first nav button.

    4. Close the MultiSearch dialog.

    5. hit the reload navbutton.

    Notice it cleared the filterbar, but did not reload the grid data.

    6. Hit the reload button again.

    Now the all the data loads.

    This is a bug right?

    Thanks

    tim

    in reply to: How do I over-ride column model settings globally? #94245
    tim
    Participant

    That will do just fine.

    Thanks Tony.

    tim

    in reply to: How to send additional POST data when deleting a row? #94244
    tim
    Participant

    I would suggest you create a custom button:

    http://www.trirand.com/jqgridw…..om_buttons

    1. you can use the pre-submit events to store global variables holding the rowid and the cellvalue (your userid).

    2. then have a custom button function that triggers an ajax post:

    example….

    [edit: if your post already works then just read #1 and store the cellvalue in a variable]

    tim

    in reply to: add default parameters for url that loads data #94109
    tim
    Participant

    A good starting point would be to look at a similar example; check out the demo page:

Viewing 15 replies - 16 through 30 (of 41 total)

Stay connected with us in your favorite flavor!