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 7874645
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T02:50:45+00:00 2026-06-03T02:50:45+00:00

I Have problem in use jqGrid,Before discussing the question of explain tables. i have

  • 0

I Have problem in use jqGrid,Before discussing the question of explain tables.
i have 4 tables CostType,CurrencyUnit , Request,RequestCost .
CostType Table structure

CostId       CostName 
-------      ----------
  1           permit
  2           Warehouse receipt
  3           Warehousing

and Request structure

RequestId         RequestNo     WaybillNo
------------------------------------------
1                    100          120Ac30
2                    101           400CA852

and CurrencyUnit table stracture:

UnitId    UnitName
------------------
1           Dollar
2           Pound
3           Rial

and CostRequest table stracture

requestId   CostId  Amount    CurrencyUnitId     Remark
--------------------------------------------------------
1             2        200      3
1             1        400      1

i want in fill page load grid As follows:

enter image description here
Afterwards user can enter request No in top textbox and click button search As follows:
enter image description here
user can change or enter some Cost Amount for this request As follows:
enter image description here
and click in save button to save in database.
Notes: i’m starter in jqGrid i can fill first Grid other two-step i can not implemet.
please help me . thanks all

  • 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-06-03T02:50:46+00:00Added an answer on June 3, 2026 at 2:50 am

    It’s a little difficult to answer on your question without writing the code for you.

    The input field for “RequestNo” (having id=”requestNo” for example) and the “Search” button could be simple controls in <fieldset> over the grid. click handler of the “Search” button can just call $("#grid").trigger("reloadGrid", [{page:1}]). Inside of grid definition you can use postData like

    var $grid = $("#grid"),
        editingRowId,
        myEditParam = {
            keys: true,
            oneditfunc: function (id) { editingRowId = id; },
            afterrestorefunc: function (id) { editingRowId = undefined; },
            aftersavefunc: function (id) { editingRowId = undefined; }
        }; 
    
    $grid.jqGrid({
        ...
        postData: {
            // add requestNo parameter to the request
            requestNo: function () { return $("#requestNo").val(); }
        },
        beforeRequest: function () {
            // stop request to the server for empty requestNo
            return $("#requestNo").val() !== "" ? true : false;
        },
        onSelectRow: function (id) {
            if (id !== editingRowId) {
                if (typeof editingRowId !== "undefined") {
                    // save previously editing row
                    $(this).jqGrid("saveRow", editingRowId, myEditParam);
                }
                // start inline editing. The user should save the row by pressing ENTER
                $(this).jqGrid("editRow", id, myEditParam);
            }
        }
        ...
    });
    

    You can add additionally “Save” button which would call $("#grid").jqGrid("saveRow", editingRowId); to save the last editing row if editingRowId is not undefined.

    It is important to add editable: true to all columns which you want to see in editing mode. If you want to have all editing columns in the grid you can use cmTemplate: {editable: true} jqGrid option. It changes the defaults for column definitions defined in colModel.

    To have dropdown in the “CurrencyUnit” column you should include additional properties in the column definition:

    edittype: "select", editoptions: { value: "Dollar:Dollar; Pound:Pound; Rial:Rial" }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a problem with the jqgrid Date formatter. in my DB table i
I have a problem with multiple cascade path error. Here are my tables: Table
I have a jqGrid table, the same one from this problem , which I
regarding to this question , i have a problem if use that query for
i have problem use link_to_remote link_to_remote document example say link_to_remote Delete this post, :update
I'm new in codeigniter I have problem I use my OS X Lion, and
I have problem with setting proper charset on my jsf pages. I use MySql
In a couple of scripts that I use I have problem that is intermittent.
recently I started to use XNA with MonoMac. I have problem with classes. I
I have a problem when try to use hashtable with large data. I have

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.