Giter Club home page Giter Club logo

Comments (10)

crivadavi avatar crivadavi commented on August 15, 2024 1

Use the method getRowId(index) available on editablegrid

from editablegrid.

crivadavi avatar crivadavi commented on August 15, 2024 1

in your method

function updateCellValue(editableGrid, rowIndex, columnIndex, oldValue, newValue, row, onResponse) {

the variable rowIndex represent what you have to use to get the id so, write this:

id: editableGrid.getRowId(rowIndex)

from editablegrid.

crivadavi avatar crivadavi commented on August 15, 2024 1

I see that from your php method you return a json like this

{
    "metadata" : [...],
    "paginator" : [...],
     "data" : [
          {
              id : null,
              values : [52, ...]
          },
          {
              id : null,
              values : [53, ...]
          }, ...
      ]
}

You have to set the id in the "id" property of the object in the array too like this:

{
     "data" : [
          {
              id : 52,
              values : [52, ...]
          },
          {
              id : 53,
              values : [53, ...]
          }, ...
}

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024 1

That problem solved by your kindly help, but now it seems that responsive or mobile friendly does not work
Thanks in advance
you are great

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024

Hi, I do not know how can I Thanks for your answer, I added this
id: editableGrid.getRowId(index),
in the updateCellValue function, but I get the following error:
ReferenceError: index is not defined[Learn More]

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024

This is the link
http://kafebaz.ir/editablegrid/editablegrid-mysql-example-master/

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024

Would you please help me?

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024

Thanks a lot but this will post the row id that starts from 1, not my product id in my product table, so i can not update product table, I want to post product id from each product as a row
for example I will update first product's price, so when i change the price, these data will be post:
`

colname price
coltype integer
id 1
newvalue 2222
oldvalue 1460
tablename demo

`

as you see the id is 1 but the ID of that product is 52, I should send 52 as id not row index or row id that is 1.

thanks a lot for your help

from editablegrid.

4moradi avatar 4moradi commented on August 15, 2024

Thanks Thanks a lot,
About this:

You have to set the id in the "id" property of the object in the array

How can I do this? I do not understand exactly that where i should make changes, which file?
Would you please help me more?
May i send you my ftp account? would you please send me your email address to send ftp information?

from editablegrid.

paashukhan avatar paashukhan commented on August 15, 2024

id: editableGrid.getValueAt(rowIndex,0) you can select column index for value.

from editablegrid.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.