[Bug 35197] New: Expose additional fields through REST API
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Bug ID: 35197 Summary: Expose additional fields through REST API Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: REST API Assignee: koha-bugs@lists.koha-community.org Reporter: pedro.amorim@ptfs-europe.com CC: tomascohen@gmail.com Blocks: 32751 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32751 [Bug 32751] [Omnibus] Extend, improve and standardize additional fields -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #1 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 158112 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158112&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=35044 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |35044 See Also|https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=35044 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35044 [Bug 35044] Additional fields: Allow for repeatable fields -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |Sandbox CC| |martin.renvoize@ptfs-europe | |.com Assignee|koha-bugs@lists.koha-commun |pedro.amorim@ptfs-europe.co |ity.org |m -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158112|0 |1 is obsolete| | --- Comment #2 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 158511 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158511&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #3 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 158512 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158512&action=edit Bug 35197: Add tests prove t/db_dependent/api/v1/additional_fields.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158511|0 |1 is obsolete| | --- Comment #4 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 158514 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158514&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158512|0 |1 is obsolete| | --- Comment #5 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 158515 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158515&action=edit Bug 35197: Add tests prove t/db_dependent/api/v1/additional_fields.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |emily.lamancusa@montgomeryc | |ountymd.gov, | |katrin.fischer@bsz-bw.de, | |m.de.rooy@rijksmuseum.nl --- Comment #6 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Rebased on top of bug 35190 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158514|0 |1 is obsolete| | --- Comment #7 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 158577 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158577&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158515|0 |1 is obsolete| | --- Comment #8 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 158578 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158578&action=edit Bug 35197: Add tests prove t/db_dependent/api/v1/additional_fields.t Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|32751 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32751 [Bug 32751] [Omnibus] Extend, improve and standardize additional fields -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |35190 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35190 [Bug 35190] Additional_fields table should allow null values for authorised_value_category -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158577|0 |1 is obsolete| | --- Comment #9 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 159648 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=159648&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158578|0 |1 is obsolete| | --- Comment #10 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 159649 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=159649&action=edit Bug 35197: Add tests prove t/db_dependent/api/v1/additional_fields.t Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #11 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 159650 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=159650&action=edit Bug 35197: Field name consistency This patch adds a to_api_mapping and updates the yaml definitions to be ensure we are consistent with modern best practice for our api field names. Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #12 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- I updated the mappings to be more consistent with the communities agreed guidelines.. though it raised lots of little questions for me.. I'm wondering how often our embeded extended_attributes are going to really look like the spec here. Sending Tomas's way for final QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact| |tomascohen@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Expose additional fields |Expose additional_field |through REST API |definitions through REST | |API -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |victor@tuxayo.net -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #13 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Ping Tomas... -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #14 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- This is now the oldest bug waiting for QA according to the dashboard - can we please have QA? It also blocks a real nice enh for the ERM module that would be shiny in our release notes :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|Sandbox |RM_priority -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #15 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Partial QA (not sure enough on the functional side): Magic number here for the permission flag:
my $librarian = $builder->build_object( { class => 'Koha::Patrons', value => { flags => 2**13 } } );
--- https://wiki.koha-community.org/wiki/Coding_Guidelines_-_API#SWAGGER1.3.2:_r...
SWAGGER1.3.2: required All resources should have a list of required fields specified
Is it just that nullable fields should be defined with "null" in the type list? If so, it's ok. --- That's quite sus ↓↓↓↓↓ ↓↓↓↓↓
# Filtering works, two agreements sharing vendor_id $t->get_ok( "//$userid:$password@/api/v1/additional_fields?tablename=" . $additional_field->tablename ) ->status_is(200)->json_is( [ $additional_field->to_api, $another_additional_field->to_api ] );
--- It seems the `503:` section isn't necessary. After putting Koha in maintenance mode: `UPDATE systempreferences SET value = 1 WHERE variable = "version";` And removing the section and restarting. I still get the expected {"error":"System is under maintenance."} and the response 503 code. Sabotage confirmed that if I break that file and restart, it's taken into account. So it's not that my removal wasn't taken into account. Same with `500: ` section. I put a `die;` in Koha/REST/V1/AdditionalFields.pm#list And I still get {"errors":[{"message":"Internal Server Error.","path":"\/"}],"status":500} Looks like the same for 400 and 403, tests still pass after removing them. All these are in many other API routes. Maybe they are useful or maybe we have been adding dead API code for a while. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #16 from Victor Grousset/tuxayo <victor@tuxayo.net> --- There is no 404 case, it returns [ ] if tablename doesn't match an existing one. Leaving that info for someone QAing the functional side to tell if that's expected here. --- The param tablename should be table_name I think. That's what is shown from the examples here: https://wiki.koha-community.org/wiki/Coding_Guidelines_-_API#SWAGGER4.2:_Usi... They diverge from the DB and for city_id, it's not for terminology reason, it seems to be just to follow snake_case. And the JSON of the response has the key `table_name` --- Otherwise all seems conformant to the guidelines. --- Is the enhancement sponsored BTW? (QA script asks this now) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #17 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 165726 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165726&action=edit Bug 35197: (QA follow-up): Update tablename prove t/db_dependent/api/v1/additional_fields.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #18 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 165727 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165727&action=edit Bug 35197: (QA follow-up): Fix pasted comment -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #19 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 165728 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165728&action=edit Bug 35197: (QA follow-up): Fix permissions specification Sponsored-by: UKHSA - UK Health Security Agency Sponsored-by: PTFS Europe Ltd -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #20 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Thanks for the review, Victor. I believe my follow-ups address the issues you mentioned. Additional comments: I believe sub under at REST/V1/Auth.pm handles the use cases you mentioned, this is why removing e.g. HTTP code 400 from the additional_fields route spec specifically does not prevent a 400 response from that specific route, as that is "called before every request to API" as in the sub description. I believe we add this "dead API code" for every new endpoint for openAPI documentation purposes i.e. https://api.koha-community.org/ The above is only my interpretation of it, Martin and/or Tomas will be better suited to confirm or deny it. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #21 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Looking today. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #22 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 165769 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165769&action=edit Bug 35197: (QA follow-up) Add 'additional_fields' tag description in docs Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #23 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 165780 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165780&action=edit Bug 35197: Rename to 'Extended attribute types' Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com, | |nick@bywatersolutions.com --- Comment #24 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Hi all, I invested a fair amount of time today on this, and I'm not sure how to move it forward without this follow-ups. I submitted a follow-up that explains my thoughts on how this should be done. It is not 100% polished (e.g. we should find a better place for the mapping, etc). But it implements it as I would do it on a first attempt (i.e. no POST or PUT so reverse mapping oddities can be handled later as needed). Tests pass and all. I want to hear from Martin and Pedro (and Jonathan if he's back). I wouldn't like to block this, but I think we need to consider long term consequences on what we decide here. And my follow-up aligns it with the current codebase. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #25 from Tomás Cohen Arazi <tomascohen@gmail.com> --- (In reply to Victor Grousset/tuxayo from comment #16)
There is no 404 case, it returns [ ] if tablename doesn't match an existing one.
This is a plural endpoint. Meaning it is expected to return an array. An empty one if the query returns no results. With my follow-up, the (renamed to resource_type) table_name attribute will get its values validated beforehand, as Pedro said. So a 400 will get returned if the request doesn't conform to the spec. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #26 from Victor Grousset/tuxayo <victor@tuxayo.net> --- (In reply to Pedro Amorim from comment #20)
Thanks for the review, Victor. I believe my follow-ups address the issues you mentioned.
Confirmed :) After rereading, it seem to comply with coding guidelines.
Additional comments: I believe sub under at REST/V1/Auth.pm handles the use cases you mentioned, this is why removing e.g. HTTP code 400 from the additional_fields route spec specifically does not prevent a 400 response from that specific route, as that is "called before every request to API" as in the sub description. I believe we add this "dead API code" for every new endpoint for openAPI documentation purposes i.e. https://api.koha-community.org/
Good point, we can see that as documentation. (In reply to Tomás Cohen Arazi from comment #25)
This is a plural endpoint. Meaning it is expected to return an array. An empty one if the query returns no results.
Great, the rule is as simple as that. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |37180 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37180 [Bug 37180] Merge 'additional_fields' and 'borrower_attributes' features together -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #159648|0 |1 is obsolete| | --- Comment #27 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168057 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168057&action=edit Bug 35197: Add additional_fields REST API endpoint Test plan: 1) Apply patch, restart plack 'koha-plack --restart kohadev' 2) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice its empty 3) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqbasket and add a new additional field 4) Do step 2) again - Notice the newly created additional field is there 5) Visit /cgi-bin/koha/admin/additional-fields.pl?tablename=aqinvoices and add a new additional field for invoices 6) Do step 2) again - Notice both additional fields are there 7) Visit /api/v1/additional_fields?tablename=aqinvoices - Notice only the additional field for aqinvoices is listed Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #159649|0 |1 is obsolete| | --- Comment #28 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168058 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168058&action=edit Bug 35197: Add tests prove t/db_dependent/api/v1/additional_fields.t Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #159650|0 |1 is obsolete| | --- Comment #29 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168059 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168059&action=edit Bug 35197: Field name consistency This patch adds a to_api_mapping and updates the yaml definitions to be ensure we are consistent with modern best practice for our api field names. Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165726|0 |1 is obsolete| | --- Comment #30 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168060 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168060&action=edit Bug 35197: (QA follow-up): Update tablename prove t/db_dependent/api/v1/additional_fields.t Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165727|0 |1 is obsolete| | --- Comment #31 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168061 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168061&action=edit Bug 35197: (QA follow-up): Fix pasted comment Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165728|0 |1 is obsolete| | --- Comment #32 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168062 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168062&action=edit Bug 35197: (QA follow-up): Fix permissions specification Sponsored-by: UKHSA - UK Health Security Agency Sponsored-by: PTFS Europe Ltd Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165769|0 |1 is obsolete| | --- Comment #33 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168063 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168063&action=edit Bug 35197: (QA follow-up) Add 'additional_fields' tag description in docs Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165780|0 |1 is obsolete| | --- Comment #34 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168064 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168064&action=edit Bug 35197: Rename to 'Extended attribute types' Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #35 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 168065 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=168065&action=edit Bug 35197: (QA follow-up) Add note about intentions This is the beggining of a wider series of developments aimed at retifying overlapping features. Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #36 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Passing QA here.. but we do need to ensure we follow through on our plans to merge these features. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|RM_priority |additional_work_needed --- Comment #37 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Martin Renvoize from comment #36)
Passing QA here.. but we do need to ensure we follow through on our plans to merge these features.
Please file follow-ups or link to the bugs for the merge of features. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |24.11.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #38 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 24.11! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |37261 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37261 [Bug 37261] api/v1/extended_attribute_types does not return additional fields for unmapped tablenames -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |37262 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37262 [Bug 37262] api/v1/extended_attribute_types does not filter additional fields for unmapped tablenames -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|35044 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35044 [Bug 35044] Additional fields: Allow for repeatable fields -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com Status|Pushed to main |Needs documenting --- Comment #39 from Lucas Gass <lucas@bywatersolutions.com> --- Enhancement will not be backported to the 24.05.x series -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC|martin.renvoize@ptfs-europe | |.com | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 --- Comment #40 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- We don't need the additional_work_needed here anymore do we? Any follow-up work should be submitted and discussed in bug 37180 correct? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|additional_work_needed | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize (ashimema) <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |release-notes-needed -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This enhancement adds a new release notes| |REST API endpoint for | |exposing configured | |additional fields: | |/api/v1/extended_attribute_ | |types | | | |Configured | |additional fields for a | |specific resource are | |queried as follows e.g. | |invoice: | |/api/v1/extended_attribute_ | |types?resource_type=invoice Keywords|release-notes-needed | CC| |pedro.amorim@ptfs-europe.co | |m -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|Needs documenting |RESOLVED CC| |caroline.cyr-la-rose@inlibr | |o.com --- Comment #41 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Nothing to add/edit in the manual. If API documentation is needed, please reopen with details. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35197 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@openfifth.c | |o.uk Blocks|37262 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37262 [Bug 37262] api/v1/extended_attribute_types does not filter additional fields for unmapped tablenames -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org