Skip to content

Commit

Permalink
bump sdk
Browse files Browse the repository at this point in the history
fix currentRole in createForm
add oc10 docker dev config to enable quicklinks
fix resource quicklink detection
  • Loading branch information
fschade committed May 2, 2022
1 parent 9284767 commit d2161cb
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 14 deletions.
1 change: 1 addition & 0 deletions dev/docker/oc10.config.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
$CONFIG = [
'web.baseUrl' => 'http://host.docker.internal:8080/index.php/apps/web',
'web.rewriteLinks' => true,
'sharing.showPublicLinkQuickAction' => true,
];

Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ export default {
passwordEnforcedForRole() {
const currentRole = this.availableRoleOptions.find(({ role }) => {
return this.link.role.label === role.label
return this.link.role.name === role.name
})
const canRead = currentRole.role.hasPermission(SharePermissions.read)
Expand Down
12 changes: 5 additions & 7 deletions packages/web-app-files/src/helpers/resources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -433,13 +433,11 @@ function _buildLink(link): Share {
description = role.label
}

let oc10QuickLink = false
if (link.attributes) {
const attributes = JSON.parse(link.attributes) || []
oc10QuickLink = attributes.find((attr) => attr.key === 'isQuickLink')?.enabled
}
const ocisQuickLink = link.quicklink === 'true'
const quicklink = oc10QuickLink || ocisQuickLink
const quicklinkOc10 =
JSON.parse(link.attributes || '[]').find((attr) => attr.key === 'isQuickLink')?.enabled ===
'true'
const quicklinkOcis = link.quicklink === 'true'
const quicklink = quicklinkOc10 || quicklinkOcis

return {
shareType: parseInt(link.share_type),
Expand Down
2 changes: 1 addition & 1 deletion packages/web-runtime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"marked": "^4.0.12",
"oidc-client": "1.11.5",
"owncloud-design-system": "^13.1.0-rc.5",
"owncloud-sdk": "~3.0.0-alpha.6",
"owncloud-sdk": "~3.0.0-alpha.7",
"p-queue": "^6.1.1",
"popper-max-size-modifier": "^0.2.0",
"portal-vue": "^2.1.7",
Expand Down
10 changes: 5 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9811,9 +9811,9 @@ __metadata:
languageName: node
linkType: hard

"owncloud-sdk@npm:~3.0.0-alpha.6":
version: 3.0.0-alpha.6
resolution: "owncloud-sdk@npm:3.0.0-alpha.6"
"owncloud-sdk@npm:~3.0.0-alpha.7":
version: 3.0.0-alpha.7
resolution: "owncloud-sdk@npm:3.0.0-alpha.7"
peerDependencies:
axios: ^0.26.0
cross-fetch: ^3.0.6
Expand All @@ -9823,7 +9823,7 @@ __metadata:
uuid: ^8.2.0
webdav: 4.9.0
xml-js: ^1.6.11
checksum: 4f5d5e92f108ed2e1fa1145396cb29d2d6ff48737edb8de8e655e77d9960acccb1e5136451f681d9c731a95f94e37fd1b3abb0202d61e6724104bdece3052151
checksum: 87ba4e2151ccbbb4a67aede7d0a366c7d55605b5e08649ac61d6b9a6f2223d53a2a9db86e69668a384af01c3f0fb871ef7361484df5ca08d7e2753118fef2495
languageName: node
linkType: hard

Expand Down Expand Up @@ -13933,7 +13933,7 @@ __metadata:
marked: ^4.0.12
oidc-client: 1.11.5
owncloud-design-system: ^13.1.0-rc.5
owncloud-sdk: ~3.0.0-alpha.6
owncloud-sdk: ~3.0.0-alpha.7
p-queue: ^6.1.1
popper-max-size-modifier: ^0.2.0
portal-vue: ^2.1.7
Expand Down

0 comments on commit d2161cb

Please sign in to comment.