mirror of
https://github.com/nextcloud/android.git
synced 2024-11-27 17:46:37 +03:00
Modify FileDataStorageManager for adding permission value to ContentValue
This commit is contained in:
parent
0544e3a18d
commit
ba4386008a
1 changed files with 5 additions and 0 deletions
|
@ -186,6 +186,7 @@ public class FileDataStorageManager {
|
|||
cv.put(ProviderTableMeta.FILE_ETAG, file.getEtag());
|
||||
cv.put(ProviderTableMeta.FILE_SHARE_BY_LINK, file.isShareByLink() ? 1 : 0);
|
||||
cv.put(ProviderTableMeta.FILE_PUBLIC_LINK, file.getPublicLink());
|
||||
cv.put(ProviderTableMeta.FILE_PERMISSIONS, file.getPermissions());
|
||||
|
||||
boolean sameRemotePath = fileExists(file.getRemotePath());
|
||||
if (sameRemotePath ||
|
||||
|
@ -285,6 +286,7 @@ public class FileDataStorageManager {
|
|||
cv.put(ProviderTableMeta.FILE_ETAG, file.getEtag());
|
||||
cv.put(ProviderTableMeta.FILE_SHARE_BY_LINK, file.isShareByLink() ? 1 : 0);
|
||||
cv.put(ProviderTableMeta.FILE_PUBLIC_LINK, file.getPublicLink());
|
||||
cv.put(ProviderTableMeta.FILE_PERMISSIONS, file.getPermissions());
|
||||
|
||||
boolean existsByPath = fileExists(file.getRemotePath());
|
||||
if (existsByPath || fileExists(file.getFileId())) {
|
||||
|
@ -342,6 +344,7 @@ public class FileDataStorageManager {
|
|||
cv.put(ProviderTableMeta.FILE_ETAG, folder.getEtag());
|
||||
cv.put(ProviderTableMeta.FILE_SHARE_BY_LINK, folder.isShareByLink() ? 1 : 0);
|
||||
cv.put(ProviderTableMeta.FILE_PUBLIC_LINK, folder.getPublicLink());
|
||||
cv.put(ProviderTableMeta.FILE_PERMISSIONS, folder.getPermissions());
|
||||
|
||||
operations.add(ContentProviderOperation.newUpdate(ProviderTableMeta.CONTENT_URI).
|
||||
withValues(cv).
|
||||
|
@ -750,6 +753,7 @@ public class FileDataStorageManager {
|
|||
file.setShareByLink(c.getInt(
|
||||
c.getColumnIndex(ProviderTableMeta.FILE_SHARE_BY_LINK)) == 1 ? true : false);
|
||||
file.setPublicLink(c.getString(c.getColumnIndex(ProviderTableMeta.FILE_PUBLIC_LINK)));
|
||||
file.setPermissions(c.getString(c.getColumnIndex(ProviderTableMeta.FILE_PERMISSIONS)));
|
||||
|
||||
}
|
||||
return file;
|
||||
|
@ -1092,6 +1096,7 @@ public class FileDataStorageManager {
|
|||
cv.put(ProviderTableMeta.FILE_ETAG, file.getEtag());
|
||||
cv.put(ProviderTableMeta.FILE_SHARE_BY_LINK, file.isShareByLink() ? 1 : 0);
|
||||
cv.put(ProviderTableMeta.FILE_PUBLIC_LINK, file.getPublicLink());
|
||||
cv.put(ProviderTableMeta.FILE_PERMISSIONS, file.getPermissions());
|
||||
|
||||
boolean existsByPath = fileExists(file.getRemotePath());
|
||||
if (existsByPath || fileExists(file.getFileId())) {
|
||||
|
|
Loading…
Reference in a new issue