Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.
-
1. For using an API as the Data source, there could be multiple ways depending how you format the source data :
1. If you link the table to a JSON file, this file has to have structure as we pointed out on this documentation. I will copy the important part here :
Currently, wpDataTables accepts this, and only this format of JSON (see example on the docs page):
a one-level array of same-structured objects where each object will be parsed as a row, and each field inside of the object as a cell.
-
If your software does not return this format, you would need to prepare, for example, some PHP adapter to return one of the formats that wpDataTables would accept.
-
2. If your JSON file has multiple levels, ( or needs authentication) then you will have to try our NESTED JSON method.
3. If you wish to use API, and to pull data from it, then you will have to adapt it to PHP Array, and make a table linked to PHP Array.
2. For having full CRUD options with a Table which is linked from an API Data Source :
If you mean to have this table Editable from our Plugin - it will not be possible.
We also have Gravity Forms integration which can be made editable in the Table.
But with the Gravity Tables - you won't be able to make easy SQL Query based Tables, while from our Manual Tables you can easily pull SQL Queries because they are stored in the DB as stand-alone table with 'columns and rows' format.
3. I see I can just use the json data source and where the URL is a custom page provides the data-driven CRUD engine.
It seems that you found a working solution in the end for your use-case, but we will be here if you encounter any issues or have any further questions.
Hi Richard,
Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.
-
1. For using an API as the Data source, there could be multiple ways depending how you format the source data :
1. If you link the table to a JSON file, this file has to have structure as we pointed out on this documentation. I will copy the important part here :
Currently, wpDataTables accepts this, and only this format of JSON (see example on the docs page):
a one-level array of same-structured objects where each object will be parsed as a row, and each field inside of the object as a cell.
-
If your software does not return this format, you would need to prepare, for example, some PHP adapter to return one of the formats that wpDataTables would accept.
-
2. If your JSON file has multiple levels, ( or needs authentication) then you will have to try our NESTED JSON method.
3. If you wish to use API, and to pull data from it, then you will have to adapt it to PHP Array, and make a table linked to PHP Array.
2. For having full CRUD options with a Table which is linked from an API Data Source :
If you mean to have this table Editable from our Plugin - it will not be possible.
You can only edit tables which as SQL Based, such as Manual Tables, and SQL Query Based Tables with our Plugin.
We also have Gravity Forms integration which can be made editable in the Table.
But with the Gravity Tables - you won't be able to make easy SQL Query based Tables, while from our Manual Tables you can easily pull SQL Queries because they are stored in the DB as stand-alone table with 'columns and rows' format.
3. I see I can just use the json data source and where the URL is a custom page provides the data-driven CRUD engine.
It seems that you found a working solution in the end for your use-case, but we will be here if you encounter any issues or have any further questions.
Thank you.
Kind Regards,
Miloš Jovanović
[email protected]
Rate my support
wpDataTables: FAQ | Facebook | Twitter | Instagram | Front-end and back-end demo | Docs
Amelia: FAQ | Facebook | Twitter | Instagram | Amelia demo sites | Docs | Discord Community
You can try wpDataTables add-ons before purchasing on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables