question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How do you access multiple values in single cell?

See original GitHub issue

I am using formatter to create a button in a cell which uses the collection’s id and payor_id attributes. How do I get the payor_id attribute into the formatter?

  renderButtons(cell, row) {
    return (
      <span>
        <Link
          to={{
            pathname: `/user/${cell}/record/new`,
            state: { payor_id: payor_id }
          }}
          className="btn btn btn-primary btn-sm"
          type="button"
          data-toggle="tooltip"
          title="Add Person Record"
          recordable_id={cell}
        >
          <i className="fa fa-plus" aria-hidden="true" /> Record
        </Link>
      </span>
    );
  }

  renderUsersTable(users) {
    const columns = [
      {
        dataField: 'id',
        formatter: this.renderButtons,
        text: '',
        headerTitle: false
      }
    ];
    
    return (
      <BootstrapTable
        keyField="id"
        data={users}
        columns={columns}
        striped
        hover
      />
    );
  }

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
hunterxxxcommented, Aug 9, 2020

@sidthekidder use formatter

const columns = [
        {
            dataField: 'Product.name',
            formatter: (value, row) => {
                return value + " " + Product.image_url
            },
            text: 'Price',
        }
1reaction
AllenFangcommented, Feb 10, 2018
Read more comments on GitHub >

github_iconTop Results From Across the Web

How do you put multiple values in one cell in Excel? - Quora
You can do this by activating Iterative calculations in excel. Go to File>Excel options>Formula and enable iterative calculation · now you have to...
Read more >
Creating value lists with multiple values in same cell
I need to create value lists for fields from large tables of data where there are multiple values within the same cell separate...
Read more >
How to Calculate Multiple Values in the Same Cell - Medium
The standard way of storing data in Excel is to have one cell for one value. However, a value might be composed of...
Read more >
How to vlookup to return multiple values in one cell in Excel?
Vlookup to return multiple values into one cell with a useful feature · Click the key column name to be combined based on,...
Read more >
Get multiple values in a single cell with array formula
2019 you can. 2019 has TEXTJOIN() . Try array formula =TEXTJOIN(", ",TRUE,IF(A2:A9<4,B2:B9,"")) . For 2016 you need custom textjoin() vba UDF.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found