ngocnicholas / airtable.net

Airtable .NET API Client
MIT License
141 stars 34 forks source link

maintainability #54

Closed lamanna-dev closed 2 years ago

lamanna-dev commented 2 years ago

Hi, one issue I have found, is that it becomes hard to maintain code when people go and change the name of columns in airtable. To work around this I have been changing the field names from what is defined in the column header, to the field ID. Eg each column in a table has both the name (column header) and the field ID, starting with "fld". similar to record ID yet for the columns. Even though I can specify the Field ID when querying the API, the returned List does not contain any reference to the ID of the column. This means that I have to use the Name rather than the ID when working with that data.

FYI if you add a new APP to your base (scripting block), and input this snip, you will see what I mean about the fld IDs: for (const table of base.tables) { output.text(table.name); output.table(table.fields) }

lamanna-dev commented 2 years ago

I noticed the other issue after I submitted this. it is the same issue that is found here: https://github.com/ngocnicholas/airtable.net/issues/53

ngocnicholas commented 2 years ago

Added support for returnFieldsByFieldId in ListRecords() of Airtable.net 1.2.0.