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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T19:57:01+00:00 2026-05-26T19:57:01+00:00

Is it possible to have the inline editing in the raw data JSON response?

  • 0

Is it possible to have the inline editing in the raw data JSON response?

So, instead of having "editable:true" in the column Model, we could have "editable":"true" in JSON and it would work the same way.

What I want to do —

When I click on a row, I can inline edit that row. And the “editable” property is not at all set in the column model, but coming through JSON. The columns should not be editable on load, it’s only the click event that would fire inline editing.

I have the following JSON

{
    "rows":[
        {
            "id":"1",
            "editable":"true",
            "cell":[                
                "Column 1 Data",
                "Column 2 Data"

            ]
        },
        {
            "id":"2",
            "editable":"false",
            "cell":[                
                "Column 1 Data",
                "Column 2 Data"

            ]
        }
]}

How will the different form fields work in this case – input field, textarea and select field?

  • 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-26T19:57:01+00:00Added an answer on May 26, 2026 at 7:57 pm

    It’s interesting question! Yes, you can do this. Inside of loadComplete callback you have access to the data (JSON response converted to the object) which is the parameter of loadComplete. You can post the information about the rows, which should be set in inline editing mode directly after loading of the data. For example is should be rowids and the column names which can be edited. You can use setColProp method (see here) or getColProp (see here) to modify the editable property for the columns and call editRow method. In the way you can full implement all what you need.

    UPDATED: In case of inline editing you can set “not-editable-row” class on any row, then jqGrid will not allows to edit the row. So inside of loadComplete(data) you can enumerate items of the data.rows array and for every item which has editable property equal to false add “not-editable-row” class to the row. The code could be about the following:

    $("#list").jqGrid({
        // ... here all your other jqGrid options
        loadComplete: function (data) {
            var item, i, l = data && data.rows ? data.rows.length : 0;
            for (i = 0; i < l; i++) {
                item = data.rows[i];
                if (item.editable === false) {
                    $("#" + item.id).addClass("not-editable-row");
                }
            }
        }
    });
    

    UPDATED 2: The problem is very easy. Either you should modify in the code above if (item.editable === false) { to if (item.editable === "false") { or change "editable":"false" from the JSON data to "editable": false which corresponds JSON serialization of boolean data.

    How you can see from the demo the approach work.

    UPDATED 3. In more recent version of jqGrid is implemented rowattr. It’s much more effective to use rowattr now. See the answer for code example.

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

Sidebar

Related Questions

On my radgrid I have inline inserting and editing. It is possible for the
I have an inline on a model with data with a fixed length, that
Is it possible in Gtk+ to have an add-tab button inline with the tabs
Possible Duplicate: Pure virtual functions may not have an inline definition. Why? I've come
Possible Duplicate: Benefits of inline functions in C++? I have a confusion regarding the
I have the following models: class Bill(models.Model): date = models.DateTimeField(_(Date of bill),null=True,blank=True) class Item(models.Model):
Is it possible to have pseudo-classes using inline styles? Example: <a href=http://www.google.com style=hover:text-decoration:none;>Google</a> I
I have 2 models as follows. Now I need to inline Model A on
Is it possible have two projects with the same name in flex builder? Here
is possible to have a separator between elements of a GridView? Thanks

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.