nextcloud / tables

🍱 Nextcloud tables app
https://apps.nextcloud.com/apps/tables
GNU Affero General Public License v3.0
133 stars 21 forks source link

Sunset V1Api.php #1180

Open blizzz opened 4 days ago

blizzz commented 4 days ago

It is only used by Api1Controller::indexTableRowsSimple() (now that the analytics datasource moved away from it in https://github.com/nextcloud/tables/pull/877). Also it is an awkward thing and not the way we deal with PHP APIs in Nextcloud. It is having only one strange method anyways.

juliushaertl commented 3 days ago

Would be good to check back with @stefan-niedermann if that is used in the Android app

stefan-niedermann commented 3 days ago

Thanks for the hint, I'll have a look tomorrow...

blizzz commented 3 days ago

FWIW, this is not a Controller, just some loose PHP class: https://github.com/nextcloud/tables/blob/main/lib/Api/V1Api.php

stefan-niedermann commented 3 days ago

Looks like the Tables Android app is not affected by this change at all - as @blizzz mentioned, this is not a controller, so I assume as long as Api1Controller (or its functionality) doesn't vanish, nothing should break. Those are the endpoints used by Tables Android:

GET
/index.php/apps/tables/api/1/tables
/index.php/apps/tables/api/1/tables
/index.php/apps/tables/api/1/tables
/index.php/apps/tables/api/1/tables/{tableId}
/index.php/apps/tables/api/1/tables/{tableId}/columns
/index.php/apps/tables/api/1/columns/{columnId}
/index.php/apps/tables/api/1/tables/{tableId}/rows
/index.php/apps/tables/api/1/tables/{tableId}/rows
/index.php/apps/tables/api/1/rows/{rowId}

POST
/index.php/apps/tables/api/1/tables
/index.php/apps/tables/api/1/tables/{tableId}/columns
/index.php/apps/tables/api/1/tables/{tableId}/rows

PUT
/index.php/apps/tables/api/1/tables/{tableId}
/index.php/apps/tables/api/1/tables/{tableId}
/index.php/apps/tables/api/1/columns/{columnId}
/index.php/apps/tables/api/1/columns/{columnId}
/index.php/apps/tables/api/1/rows/{rowId}

DELETE
/index.php/apps/tables/api/1/tables/{tableId}
/index.php/apps/tables/api/1/columns/{columnId}
/index.php/apps/tables/api/1/rows/{rowId}
blizzz commented 2 days ago

Yes, the Api1Controller will not change. indexTableRowsSimple() needs internal adjustments, but shall not be broken – it is not in the list either, the endpoint would have been index.php/apps/tables/api/1/tables/{tableId}/rows/simple.