Documentation

disk.storage.rename

disk.storage.rename

Renames the storage. Only application storage can be renamed (see disk.storage.getforapp).

Response example:

"result": {
    "ID": "2", //identifier
    "NAME": "Marketing and Advertisement", //name
    "CODE": null, //symbol code
    "MODULE_ID": "disk",
    "ENTITY_TYPE": "group", //entity type (see disk.storage.gettypes)
    "ENTITY_ID": "1", //entity ID
    "ROOT_OBJECT_ID": "2" //root folder ID
}


Parameters

Parameter Description
id Storage ID.
newName New name.

Example

        BX24.callMethod(
		"disk.storage.rename",
		{
			id: 2,
			newName: 'New name for storage'
		},
		function (result)
		{
			if (result.error())
				console.error(result.error());
			else
				console.dir(result.data());
		}
);




© «Bitrix24», 2001-2024
Up