diff options
author | raghunayyar <me@iraghu.com> | 2014-02-18 21:59:45 +0530 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2014-06-02 12:52:53 +0200 |
commit | 970f8997260606d805880192dbb389e8b196371a (patch) | |
tree | 1236007a12091d8f10203016b7914d8d00701e82 /settings/ajax | |
parent | dc28f589517e05ef29c6c06145ab4944c0aa2994 (diff) | |
download | nextcloud-server-970f8997260606d805880192dbb389e8b196371a.tar.gz nextcloud-server-970f8997260606d805880192dbb389e8b196371a.zip |
Initial Commit : Changes Storage to Quota, Implements GroupName editing.
Diffstat (limited to 'settings/ajax')
-rw-r--r-- | settings/ajax/changegroupname.php | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/settings/ajax/changegroupname.php b/settings/ajax/changegroupname.php new file mode 100644 index 00000000000..cbf1e3e5e86 --- /dev/null +++ b/settings/ajax/changegroupname.php @@ -0,0 +1,24 @@ +<?php +// Check if we are a user + +OCP\JSON::callCheck(); +OC_JSON::checkLoggedIn(); + +$l=OC_L10N::get('core'); + +$groupname = $_POST["groupname"]; + +// Return Success story +// TODO : make changes to the API to allow this. +// setGroupname doesnt exist yet. +if(OC_Group::setGroupname($groupname)) { + OC_JSON::success( + array("data" => array( + "message" => $l->t('Group name has been changed.'), + "groupname" => $groupname, + ) + ) + ); +} else { + OC_JSON::error(array("data" => array( "message" => $l->t("Unable to change group name")))); +}
\ No newline at end of file |