Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

162
Views
how to pass data from antdesgin modal to grid component reactjs

I've a grid component(table) made using Antdesign in React. On clicking a button ,it opens a modal which has multiple checkboxes .The challenge is to maintain the different checkbox values for different rows and pass all the selected checkboxes as a column in the same row.

This is the checkbox code :

<div><Checkbox name="length" onChange={this.handleCheck}>{listType.po_qc.metal[0].label}</Checkbox></div>
                  <div><Checkbox name="locking"onChange={this.handleCheck}>{listType.po_qc.metal[1].label}</Checkbox></div>
 

HandleChange -

 handleCheck = (event) => {
    var updatedList = [...this.state.checked];
    console.log(event.target.checked)
    if (event.target.checked) {
      updatedList = [...this.state.checked, event.target.name];
    } else {
      updatedList.splice(this.state.checked.indexOf(event.target.name), 1);
    }
    this.setState({
      checked:updatedList
    });
    console.log(this.state.checked)
  };

Need to access the sleected checkbox values for different rows .(Suppose i selected 2 checkbox in row one after opening modal then those 2 values should be here in comma separated form in row one and selected 4 checkbox in row 2 then 4 checkbox value shoould be in row 2 in comma separated form)

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!