diff options
author | Bernhard Posselt <nukeawhale@gmail.com> | 2013-05-29 18:07:26 +0200 |
---|---|---|
committer | Bernhard Posselt <nukeawhale@gmail.com> | 2013-06-11 00:25:00 +0200 |
commit | 8bffbedcd8fe1a8e7f40e27fdd44b8bd329b75ff (patch) | |
tree | 3801f235c44c4ab58cbb3e6cc26cc72461ed04f4 | |
parent | 3ad8deaaa3bc1c680c4f1f3d44d9dcac49f5e15f (diff) |
added method for marking all read
-rw-r--r-- | appinfo/api.php | 8 | ||||
-rw-r--r-- | external/itemapi.php | 9 |
2 files changed, 17 insertions, 0 deletions
diff --git a/appinfo/api.php b/appinfo/api.php index a2adcf373..e54493e5f 100644 --- a/appinfo/api.php +++ b/appinfo/api.php @@ -183,4 +183,12 @@ use \OCA\AppFramework\External\External; }, 'news', \OC_API::USER_AUTH +); + +\OCP\API::register('put', '/apps/news/items/read/multiple', + function($params) { + return External::main('ItemAPI', 'readMultiple', $params, new DIContainer()); + }, + 'news', + \OC_API::USER_AUTH );
\ No newline at end of file diff --git a/external/itemapi.php b/external/itemapi.php index 2ba1fcaed..a67d5a171 100644 --- a/external/itemapi.php +++ b/external/itemapi.php @@ -156,4 +156,13 @@ class ItemAPI extends Controller { } + public function readMultiple() { + $userId = $this->api->getUserId(); + //$ids = $this->params('_put'); + //print_r(json_decode(file_get_contents('php://input'), true)); + + exit(); + //return new NewsAPIResult(); + } + } |