Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1046767
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T16:11:52+00:00 2026-05-16T16:11:52+00:00

When I am making a call first time it shows data in my details

  • 0

When I am making a call first time it shows data in my details grid from master grid but when selecting other row its not populating the new data in the details grid..

jQuery("#list10").jqGrid({
    sortable: true,
    url: '/cpsb/unprocessedOrders.do?method=getInitialUnprocessedList',
    datatype: 'json',
    colNames: ['Order', 'Load', 'Gate Time', 'Stop', 'Customer', 'Status'],
    colModel: [
        { name: 'orderNumber', index: 'orderNumber', width: 120, align: "center",
          sorttype: "int", key: true },
        { name: 'loadNumber', index: 'loadNumber', width: 100, align: "center",
          sorttype: "int" },
        { name: 'latestTime', index: 'latestTime', width: 160, align: "center",
          align: "center" },
        { name: 'stopSeq', index: 'stopSeq', width: 80, align: "center",
          sorttype: "int" },
        { name: 'customerNumber', index: 'customerNumber', width: 60,
          align: "center", sorttype: "int" },
        { name: 'orderStatus', index: 'orderStatus', width: 120, align: "center" }
    ],
    rowNum: 10,
    rowList: [10, 20, 30],
    jsonReader: { repeatitems: false,
        root: function (obj) {
            return obj;
        },
        page: function (obj) { return 1; },
        total: function (obj) { return 1; },
        records: function (obj) { return obj.length; }
    },
    pager: '#pager10',
    sortname: 'Gate Time',
    sortorder: "desc",
    gridview: true,
    loadonce: true,
    viewrecords: true,
    multiselect: true,
    multikey: 'ctrlKey',
    caption: "Order Header",
    onSelectRow: function (ids) {
        if (ids == null) {
            ids = 0;
            if (jQuery("#list10_d").jqGrid('getGridParam', 'records') > 0) {
                jQuery("#list10_d").jqGrid('setGridParam', { url:
"/cpsb/unprocessedOrders.do?method=getUnprocessedOrderDetails&orderNum=" + ids });
                jQuery("#list10_d").jqGrid('setCaption',
                        "Order Header: " + ids).trigger('reloadGrid');
            }
        }
        else {
            jQuery("#list10_d").jqGrid('setGridParam', { url:
"/cpsb/unprocessedOrders.do?method=getUnprocessedOrderDetails&orderNum=" + ids });
            jQuery("#list10_d").jqGrid('setCaption',
                      "Order Details: " + ids).trigger('reloadGrid');
        }
    },
    height: '100%'
}); 
jQuery("#list10").jqGrid('navGrid','#pager10',
       {view:true,add:false,edit:false,del:false,searchtext:"Filter"},
       {},{},{},{multipleSearch:true});
$("#list10").jqGrid('hideCol', 'cb');

2nd grid for order details

jQuery("#list10").jqGrid('reloadGrid');
jQuery("#list10_d").jqGrid({
    height: 100,
    url: "/cpsb/unprocessedOrders.do?method=getUnprocessedOrderDetails&orderNum=",
    datatype: "json",
    colNames: ['Order', 'SKU', 'UPC', 'Item Description', 'Quantity Ordered',
               'Teach in Hold?'],
    colModel: [
        { name: 'orderNumber', index: 'orderNumber', width: 55 },
        { name: 'sku', index: 'sku', width: 55 },
        { name: 'upc', index: 'upc', width: 40, align: "right" },
        { name: 'itemDescription', index: 'itemDescription', width: 150,
          align: "right" },
        { name: 'quantityOrdered', index: 'quantityOrdered', width: 150,
          align: "right", sortable: false, search: false },
        { name: 'teachInId', index: 'teachInId', width: 150,
          align: "right", editable: true, edittype: "checkbox",
          formatter: 'checkbox', editoptions: { value: "true:false"} }],
    rowNum: 5,
    rowList: [5, 10, 20],
    jsonReader: { repeatitems: false,
        root: function (obj) {
            return obj;
        },
        page: function (obj) { return 1; },
        total: function (obj) { return 1; },
        records: function (obj) { return obj.length; }
    },
    pager: '#pager10_d',
    sortname: 'SKU',
    loadonce: true,
    viewrecords: true,
    sortorder: "asc",
    multiselect: true,
    multikey: 'ctrlKey',
    caption: "Order Detail",
    height: '100%'
}).navGrid('#pager10_d', { view: true, add: false, edit: false, del: false },
            {}, {}, {}, { multipleSearch: true });
$("#list10_d").jqGrid('hideCol', 'cb');
jQuery("#ms1").click(function () {
    var s;
    s = jQuery("#list10_d").jqGrid('getGridParam', 'selarrrow');
    alert(s);
});

Edit: I am able view different records once I refresh the page…But after one selection other selection don’t work

edit2: after debugging i saw that I am appending the orderNum parameter correctly but this is not making any call to the action class….any idea? thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T16:11:53+00:00Added an answer on May 16, 2026 at 4:11 pm

    It seems to me that the answer on your main problem you find here: JqGrid Reload not working.

    Because you use loadonce:true in both grids, the datatype in every grid will be changed from "json" to "local" after the first load. It seems to me that you should just remove loadonce:true for the second (detailed) grid. If you do want use loadonce:true for example for local sorting or local paging, then you should reset datatype to "json" in the same call jQuery("#list10_d").jqGrid('setGridParam',{url:"...", datatype: "json"}); .

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.