Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.1] Media webservice #35788

Merged
merged 76 commits into from
Nov 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
2e78f24
[4.0] Notification icons (#34226)
brianteeman May 29, 2021
dbdf8aa
remove method allow parent to run (#34118)
PhilETaylor May 29, 2021
aba8360
[4.0] Changing title to tooltip for template preview (#33292)
infograf768 May 29, 2021
1eab8c0
Update location path in description (#34238)
May 29, 2021
d560b16
Fix patterns field check when field empty and not required (#34124)
Ruud68 May 29, 2021
d240975
[4.0] Finish transition from CSS classes "label-" to "alert-" for the…
richard67 May 29, 2021
810b2ef
[4.0] mod_popular with disabled hits (#34257)
brianteeman May 29, 2021
c9e8d93
[4.0] Use MVCFactory to create model (#34092)
joomdonation May 30, 2021
c8e2cd5
Fix row selecting, when module is disabled (#34273)
Fedik May 30, 2021
33d53fe
Media web service implementation.
pjdevries May 28, 2021
df67df3
Merge branch '4.0-dev' into media_web_service
pjdevries May 31, 2021
8466992
Media web service implementation.
pjdevries May 31, 2021
5612a4c
Fix hard coded adapter name default.
pjdevries Jun 2, 2021
6ba3655
Fix missing url and tempUrl attributes in single item response.
pjdevries Jun 2, 2021
259f325
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 2, 2021
60c85af
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 3, 2021
4736aa9
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 4, 2021
77ad810
Remove useless comments.
pjdevries Jun 4, 2021
e9c287d
Replace 'PATH' with 'STRING' for cleaning of input parameters.
pjdevries Jun 4, 2021
f9793fc
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 5, 2021
4042d78
Adds required parameter checks and removes global exception handling.
pjdevries Jun 6, 2021
4bf9821
Adds media web service specific language strings.
pjdevries Jun 6, 2021
5c3df9c
Adds exception handling.
pjdevries Jun 6, 2021
c2b4d74
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 6, 2021
48f34e7
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 7, 2021
8a2dad4
Adds missing exception handler and fixes wrong path return value afte…
pjdevries Jun 7, 2021
03c413b
Use exception message as error title.
pjdevries Jun 8, 2021
d1967c5
Adds proper FileNotFound exception handling for GET requests.
pjdevries Jun 8, 2021
26cdde7
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 8, 2021
4b9245e
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 10, 2021
07464a7
Fixes handling of status code.
pjdevries Jun 10, 2021
c4d1d90
Fixes some types, formatting and similar stuff.
pjdevries Jun 10, 2021
757f439
Fixes yet another sloppy typo.
pjdevries Jun 10, 2021
1d9daae
Merge branch '4.0-dev' into media_web_service
pjdevries Jun 10, 2021
c673445
Merge remote-tracking branch 'webservice/media_web_service' into j4/m…
laoneo Sep 29, 2021
58416b8
Merge branch '4.0-dev' into j4/media/webservice
laoneo Sep 29, 2021
4d816ce
restore file
laoneo Sep 29, 2021
83fc130
Fix some docs
laoneo Oct 7, 2021
4075761
Adapter endpoint
laoneo Oct 7, 2021
eacc063
Add plugin to install file
laoneo Oct 8, 2021
c82367b
Add tests
laoneo Oct 8, 2021
75ef474
Merge remote-tracking branch 'upstream/4.0-dev' into j4/media/webservice
laoneo Oct 8, 2021
fe21a52
Merge remote-tracking branch 'upstream/4.0-dev' into j4/media/webservice
laoneo Oct 21, 2021
82528eb
Update api/components/com_media/src/Helper/MediaHelper.php
laoneo Oct 21, 2021
eb196c9
Update api/components/com_media/src/Helper/MediaHelper.php
laoneo Oct 21, 2021
34dd765
Update api/components/com_media/src/Model/MediaModel.php
laoneo Oct 21, 2021
588a468
Update api/components/com_media/src/Model/MediumModel.php
laoneo Oct 21, 2021
bdeb8e5
Update api/components/com_media/src/View/Media/JsonapiView.php
laoneo Oct 21, 2021
0b1526e
Update libraries/src/Error/JsonApi/SaveExceptionHandler.php
laoneo Oct 21, 2021
4445472
Update api/components/com_media/src/Controller/MediaController.php
laoneo Oct 21, 2021
4c22899
Update api/components/com_media/src/Controller/MediaController.php
laoneo Oct 21, 2021
f569891
Update api/components/com_media/src/Model/AdaptersModel.php
laoneo Oct 21, 2021
5465807
Update api/components/com_media/src/Model/MediaModel.php
laoneo Oct 21, 2021
84c32d5
docs
laoneo Oct 21, 2021
dab0060
Update api/components/com_media/src/View/Media/JsonapiView.php
laoneo Oct 21, 2021
1569a61
int
laoneo Oct 21, 2021
e663b03
Merge branch 'j4/media/webservice' of github.com:Digital-Peak/joomla-…
laoneo Oct 21, 2021
d42d544
cs
laoneo Oct 21, 2021
1b3dd32
cs
laoneo Oct 21, 2021
689d167
more cleanup
laoneo Oct 21, 2021
dd756fd
tabs
laoneo Oct 21, 2021
3bb4a66
restore
laoneo Oct 21, 2021
e54043d
Test all endpoints
laoneo Oct 24, 2021
26cd1d8
Update api/components/com_media/src/Model/MediaModel.php
laoneo Oct 24, 2021
245e36a
Hardening
laoneo Oct 24, 2021
6d85a47
Merge branch 'j4/media/webservice' of github.com:Digital-Peak/joomla-…
laoneo Oct 24, 2021
2c9ee7a
Tests fix for drone
laoneo Oct 24, 2021
be5e17c
Update Api.php
laoneo Oct 24, 2021
431ff46
Merge branch '4.1-dev' into j4/media/webservice
laoneo Oct 24, 2021
4a359c3
Merge remote-tracking branch 'upstream/4.1-dev' into j4/media/webservice
laoneo Nov 5, 2021
cdd607e
Create directory in test with correct permissions
laoneo Nov 5, 2021
348abb6
Add more tests and remove static helper
laoneo Nov 5, 2021
2f867ba
Update tests/Codeception/api/com_media/MediaCest.php
laoneo Nov 15, 2021
c2059a9
Update tests/Codeception/_support/Helper/Api.php
laoneo Nov 15, 2021
d1bc84a
cs
laoneo Nov 15, 2021
9343c07
Merge remote-tracking branch 'upstream/4.1-dev' into j4/media/webservice
laoneo Nov 23, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions administrator/language/en-GB/plg_webservices_media.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
; Joomla! Project
; (C) 2021 Open Source Matters, Inc. <https://www.joomla.org>
; License GNU General Public License version 2 or later; see LICENSE.txt
; Note : All ini files need to be saved as UTF-8

PLG_WEBSERVICES_MEDIA="Web Services - Media"
PLG_WEBSERVICES_MEDIA_XML_DESCRIPTION="Add media routes to the API for your website."
7 changes: 7 additions & 0 deletions administrator/language/en-GB/plg_webservices_media.sys.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
; Joomla! Project
; (C) 2021 Open Source Matters, Inc. <https://www.joomla.org>
; License GNU General Public License version 2 or later; see LICENSE.txt
; Note : All ini files need to be saved as UTF-8

PLG_WEBSERVICES_MEDIA="Web Services - Media"
PLG_WEBSERVICES_MEDIA_XML_DESCRIPTION="Add media routes to the API for your website."
63 changes: 63 additions & 0 deletions api/components/com_media/src/Controller/AdaptersController.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
<?php
/**
* @package Joomla.API
* @subpackage com_media
*
* @copyright (C) 2021 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

namespace Joomla\Component\Media\Api\Controller;

\defined('_JEXEC') or die;

use Joomla\CMS\MVC\Controller\ApiController;
use Joomla\Component\Media\Administrator\Exception\InvalidPathException;
use Joomla\Component\Media\Api\Helper\AdapterTrait;

/**
* Media web service controller.
*
* @since __DEPLOY_VERSION__
*/
class AdaptersController extends ApiController
{
use AdapterTrait;

/**
* The content type of the item.
*
* @var string
* @since __DEPLOY_VERSION__
*/
protected $contentType = 'adapters';

/**
* The default view for the display method.
*
* @var string
*
* @since __DEPLOY_VERSION__
*/
protected $default_view = 'adapters';

/**
* Display one specific adapter.
*
* @param string $path The path of the file to display. Leave empty if you want to retrieve data from the request.
*
* @return static A \JControllerLegacy object to support chaining.
*
* @throws InvalidPathException
* @throws \Exception
*
* @since __DEPLOY_VERSION__
*/
public function displayItem($path = '')
{
// Set the id as the parent sets it as int
$this->modelState->set('id', $this->input->get('id', '', 'string'));

return parent::displayItem();
}
}
Loading