Skip to content

how to add comment column to the table #243

@mrpiotr-dev

Description

@mrpiotr-dev

@jnjagtap commented on Mon Jul 02 2018

how to add comment column to table a and previous comments should remain unchanged .in angularjs
using handsontable


@AMBudnik commented on Mon Jul 02 2018

Hi @jnjagtap

Can you share a draft? I am not sure what you would like to achieve. And just to confirm - are you using the AngularJS, not Angular 2+?


@jnjagtap commented on Mon Jul 02 2018

yes i am using angularjs.
can we add comment to whole table?
screenshot from 2018-07-02 15-11-29

in this at last there should be colunn comment and whenver data updated but comment should e remained as it is .


@jnjagtap commented on Mon Jul 02 2018

I could able to create tables using nghandsontable syntax. But I want to add some comment to table . So that while opening table definition from catalog, the same comment should be present.


@AMBudnik commented on Tue Jul 03 2018

Hi @jnjagtap

Comments are an array of objects provided via cell property

cell: [
    {row: 1, col: 1, comment: {value: 'Some comment'}},
    {row: 2, col: 2, comment: {value: 'More comments'}}
  ]

you can add comment to each cell, you just need to define then in the array. If user adds a comment manually you should also push it to the array of comments for further use. Without it the comment will be lost after you load the data again.


@jnjagtap commented on Tue Jul 03 2018

but i don't want add comments to cell .i want to add comment column in table where i can read comments even if data updated or page is refreshed
comments should remain as it is.


@AMBudnik commented on Tue Jul 03 2018

We do not have any option like comment column, If you think of a column that is editable and you want the user to post there anything and then remain the data after you load yours from the database you need to pass this data to the server via afterChange hook.

Sorry if I do not get the idea.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions