Jump to content

Module: Matrix Fieldtype & Inputfield


kongondo

Recommended Posts

1 hour ago, Aleksey Popov said:

Thanks a lot! I tried to do this, but using the table, as in the instructions, it did not work, I will experiment a little later. But for myself, I made a solution (simplified here) like this that works:

It seems you were talking about the frontend? I was talking about the backend ?.

Link to comment
Share on other sites

  • 3 months later...

Hi @kongondo,
sorry if this is been answered before.

I know it's possibile to upload/paste a CSV to populate row and columns of the matrix, but is it possibile to skip row and columns definition upfront (via selector, etc.) and define them via the CSV itself?

I am asking this because I'd like to render on the frontend different tables whom have unique rows/columns definition.

Link to comment
Share on other sites

Hi @3fingers,

On 3/9/2021 at 11:28 AM, 3fingers said:

and define them via the CSV itself?

I don't understand the question I am afraid. However, you cannot define anything inside the CSV.

On 3/9/2021 at 11:28 AM, 3fingers said:

I am asking this because I'd like to render on the frontend different tables whom have unique rows/columns definition.

Are you talking about different tables from different pages or different tables from a single matrix on a single page?

Link to comment
Share on other sites

2 minutes ago, kongondo said:

Are you talking about different tables from different pages or different tables from a single matrix on a single page?

I'd like to have a single matrix field (yours) inside a RepeaterMatrix (pro-field). For each matrix(yours) I'd like to be able to upload/paste csv definitions and render a table accordingly.
Every csv might have different colums/row numbers and definitions.

Link to comment
Share on other sites

12 minutes ago, 3fingers said:

I'd like to have a single matrix field (yours) inside a RepeaterMatrix (pro-field). For each matrix(yours) I'd like to be able to upload/paste csv definitions and render a table accordingly.

I see.

12 minutes ago, 3fingers said:

Every csv might have different colums/row numbers and definitions.

Have you tried with the Custom PHP Code options? I haven't touched this in a while but (in my head) it seems like it is doable.

Link to comment
Share on other sites

1 minute ago, kongondo said:

Have you tried with the Custom PHP Code options? I haven't touched this in a while but (in my head) it seems like it is doable.

Nope. I'm just investigating upfront because I'm close to start a new project and yours matrix fieldtype looks like a good candidate.
Any advice on how to start with Custom PHP Code to do what I'm after? Thanks ?

Link to comment
Share on other sites

6 minutes ago, 3fingers said:

Any advice on how to start with Custom PHP Code to do what I'm after? Thanks

Just think ProcessWire page reference fields ?.

Quote

Use custom PHP code to return row/column pages. If used, this method overrides method #1 above. This allows you to specify valid PHP code to find pages for the matrix rows and/or columns. The PHP statement has access to the $page and $pages API variables, where $page refers to the page being edited. The snippet should only return a Page or PageArray. If it returns a Page, children of that Page are used as column pages.

 

Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...