2011-08-07 19:20:57 +00:00
|
|
|
<?php
|
|
|
|
|
2012-05-03 10:23:29 +00:00
|
|
|
OCP\JSON::checkAppEnabled('files_sharing');
|
2012-05-05 18:56:52 +00:00
|
|
|
OCP\JSON::checkLoggedIn();
|
2011-08-07 19:20:57 +00:00
|
|
|
|
2012-05-05 18:56:52 +00:00
|
|
|
$source = '/'.OCP\USER::getUser().'/files'.$_POST['source'];
|
|
|
|
$uid_shared_with = $_POST['uid_shared_with'];
|
|
|
|
$permissions = $_POST['permissions'];
|
2011-08-07 19:20:57 +00:00
|
|
|
OC_Share::setPermissions($source, $uid_shared_with, $permissions);
|
|
|
|
|
2012-05-05 18:56:52 +00:00
|
|
|
OCP\JSON::success();
|
|
|
|
|
2011-09-30 21:05:10 +00:00
|
|
|
?>
|