More fileinfo

This commit is contained in:
Roeland Jago Douma 2015-10-01 16:04:22 +02:00
parent eeafccb3a6
commit 40dd2d9dbe
1 changed files with 8 additions and 4 deletions

View File

@ -191,14 +191,18 @@
// convert share data to file data // convert share data to file data
.map(function(share) { .map(function(share) {
var file = { var file = {
shareOwner: share.owner + '@' + share.remote, shareOwner: share.owner + '@' + share.remote.replace(/.*?:\/\//g, ""),
name: share.name name: OC.basename(share.mountpoint),
mtime: share.mtime,
mimetype: share.mimetype,
type: share.type,
id: share.file_id,
path: OC.dirname(share.mountpoint)
}; };
file.shares = [{ file.shares = [{
id: share.id, id: share.id,
type: OC.Share.SHARE_TYPE_REMOTE, type: OC.Share.SHARE_TYPE_REMOTE
target: share.mountpoint
}]; }];
return file; return file;
}) })