Is there a way to represent a JSON field in EasyAdmin 3?

I’m new to Symfony and still learning. I’m working currently on a Symfony application where I have a table that represents projects and every project have id, title, startDate, endDate and fields where fields is a JSON field that contains data representing differents columns that are custom to the project and can be added, updated or deleted by a user.

The data inside that field is like this:

{
  "columns": {
    "column1": "string",
    "column2": "integer"
  },
  "rows": [
    {
      "column1": "foo",
      "column2": 22
    },
    {
      "column1": "bar",
      "column2": 23
    }
  ]
}

"columns" represents custom columns added to a specific project and "rows" represents the data in every column. "string" and "integer" represent data type in every column.

My Question:

I’m using EasyAdmin 3 and I want to know if there any easy way to extract the columns with their values when viewing project details? Thank you in advance!

Source: Symfony Questions

Was this helpful?

0 / 0

Leave a Reply 0

Your email address will not be published. Required fields are marked *