bug Webservices PR-5.3-dev Pending

User tests: Successful: Unsuccessful:

avatar MacJoom
MacJoom
22 Jun 2023

Pull Request for Issue # .
Using the API for changing langugage overrides does not work
See https://docs.joomla.org/J4.x:Joomla_Core_APIs - Section Overrides Languages

Summary of Changes

OverrideModel: Wrong determination of client (site or admin)
OverridesController: Edit function did not exist, Save function did not use correct language/client
APIController: Delete needs modelstate

Testing Instructions

Do your own API calls on Language Override Operations

or use my Postman collection https://github.com/MacJoom/j4x-api-collection Section 5.3

Update: Use the updated collection from Alexandre Elise:

https://github.com/alexandreelise/j4x-api-collection

Example calls:
POST:
http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE
raw Body: {"key":"JTESTIT","override":"text"}

replace http://newrelease6-0.test with your url

Result:
{
"links": {
"self": "http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE"
},
"data": {
"type": "overrides",
"id": "JTESTIT",
"attributes": {
"value": "text"
}
}
}
GET:
http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE
Result:
{
"links": {
"self": "http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE"
},
"data": [
{
"type": "overrides",
"id": "JTESTIT",
"attributes": {
"value": "text"
}
}
],
"meta": {
"total-pages": 1
}
GET: (language id)
http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE/JTESTIT
Result:
{
"links": {
"self": "http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE/JTESTIT"
},
"data": {
"type": "overrides",
"id": "JTESTIT",
"attributes": {
"value": "JTestit Entry"
}
}
}

PATCH:
http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE/JTESTIT
{"key":"JTESTIT","override":"new text 5"}
Result:
{
"links": {
"self": "http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE/JTESTIT"
},
"data": {
"type": "overrides",
"id": "JTESTIT",
"attributes": {
"value": "new text 5"
}
}
}

DELETE:
http://newrelease6-0.test/joomla-cms/api/index.php/v1/languages/overrides/site/de-DE/JTESTIT

Empty result: Status 204, Language Override is deleted

if you get Forbidden as result your Authorization is not set up correctly
use Auth Type: API Key
Key: X-Joomla-Token
Value: <copy from User Tab 'Joomla API Token'>

Actual result BEFORE applying this Pull Request

POST, PATCH and DEL requests fail

Expected result AFTER applying this Pull Request

All requests work

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • [ x] No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • [x ] No documentation changes for manual.joomla.org needed

avatar joomla-cms-bot joomla-cms-bot - change - 22 Jun 2023
Category Administration com_languages Libraries
avatar MacJoom MacJoom - open - 22 Jun 2023
avatar MacJoom MacJoom - change - 22 Jun 2023
Status New Pending
avatar MacJoom MacJoom - change - 22 Jun 2023
The description was changed
avatar MacJoom MacJoom - edited - 22 Jun 2023
1f78b9a 22 Jun 2023 avatar MacJoom cs
avatar MacJoom MacJoom - change - 22 Jun 2023
Labels Added: PR-4.3-dev
48b8b37 22 Jun 2023 avatar MacJoom cs
avatar HLeithner
HLeithner - comment - 30 Sep 2023

This pull request has been automatically rebased to 4.4-dev.

avatar HLeithner HLeithner - change - 24 Apr 2024
Title
Language override api issue - the webservices API for handling language overrides is not working
[4.4] Language override api issue - the webservices API for handling language overrides is not working
avatar HLeithner HLeithner - edited - 24 Apr 2024
avatar HLeithner
HLeithner - comment - 15 Nov 2024

This pull request has been automatically rebased to 5.2-dev.

avatar HLeithner HLeithner - change - 15 Nov 2024
Title
[4.4] Language override api issue - the webservices API for handling language overrides is not working
[5.2] Language override api issue - the webservices API for handling language overrides is not working
avatar HLeithner HLeithner - edited - 15 Nov 2024
avatar Hackwar Hackwar - change - 16 Jan 2025
Labels Added: bug Webservices PR-4.4-dev PR-5.2-dev
Removed: PR-4.3-dev
avatar HLeithner
HLeithner - comment - 15 Apr 2025

This pull request has been automatically rebased to 5.3-dev.

avatar HLeithner HLeithner - change - 15 Apr 2025
Title
[5.2] Language override api issue - the webservices API for handling language overrides is not working
[5.3] Language override api issue - the webservices API for handling language overrides is not working
avatar HLeithner HLeithner - edited - 15 Apr 2025
avatar MacJoom MacJoom - change - 23 Aug 2025
Labels Added: PR-5.3-dev
Removed: PR-4.4-dev PR-5.2-dev
avatar MacJoom MacJoom - change - 23 Aug 2025
The description was changed
avatar MacJoom MacJoom - edited - 23 Aug 2025
avatar exlemor exlemor - test_item - 23 Aug 2025 - Tested unsuccessfully
avatar exlemor
exlemor - comment - 23 Aug 2025

I have tested this item 🔴 unsuccessfully on 74e668b

I was not able to test successfully (and Macjoom and Richard were watching during PBF 23.08) ;( Sorry @MacJoom


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/41016.

avatar MacJoom MacJoom - change - 23 Aug 2025
The description was changed
avatar MacJoom MacJoom - edited - 23 Aug 2025
avatar MacJoom MacJoom - change - 23 Aug 2025
The description was changed
avatar MacJoom MacJoom - edited - 23 Aug 2025

Add a Comment

Login with GitHub to post a comment