Skip to content

Commit f019a62

Browse files
authored
Merge pull request #565 from vimeo/team_permission_display_description
Update PermissionPolicy with missing fields
2 parents 260392e + 918ede2 commit f019a62

4 files changed

Lines changed: 23 additions & 7 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
Change Log
22
==========
3+
Version 3.7.0 *(2022-06-08)*
4+
----------------------------
5+
- Added `displayName`, `displayDescription` to `PermissionPolicy`
6+
- Made `PermissionPolicy` implement `Entity`
7+
38
Version 3.6.0 *(2022-06-07)*
49
----------------------------
510
- Added `unit` to `StorageQuota`.

api-core/src/main/java/com/vimeo/networking2/ApiConstants.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ object ApiConstants {
3333

3434
const val SSL_URL_PATTERN = "*.vimeo.com"
3535

36-
const val SDK_VERSION = "3.6.0"
36+
const val SDK_VERSION = "3.7.0"
3737

3838
const val NONE = -1
3939

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
org.gradle.parallel=true
2020
org.gradle.daemon=true
2121
org.gradle.jvmargs=-Xmx4096M
22-
version=3.6.0
22+
version=3.7.0
2323

2424
android.useAndroidX=true
2525
android.enableJetifier=true

models/src/main/java/com/vimeo/networking2/PermissionPolicy.kt

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,18 @@ package com.vimeo.networking2
22

33
import com.squareup.moshi.Json
44
import com.squareup.moshi.JsonClass
5+
import com.vimeo.networking2.common.Entity
56
import java.util.Date
67

78
/**
89
* A permission policy which represents a collection or permutation of certain [PermissionActions].
910
*
10-
* @property uri The uri for the permission policy
11-
* @property name The displayable name for the permission policy
12-
* @property createdOn The date the policy was created
13-
* @property modifiedOn The date the policy was last modified on
11+
* @property uri The uri for the permission policy.
12+
* @property name The displayable name for the permission policy.
13+
* @param displayName The name of the permission level, translated and ready for client display.
14+
* @param displayDescription The description of the permission level, for client display.
15+
* @property createdOn The date the policy was created.
16+
* @property modifiedOn The date the policy was last modified on.
1417
* @property permissionActions The actions the user can take.
1518
*/
1619
@JsonClass(generateAdapter = true)
@@ -22,6 +25,12 @@ data class PermissionPolicy(
2225
@Json(name = "name")
2326
val name: String? = null,
2427

28+
@Json(name = "display_name")
29+
val displayName: String? = null,
30+
31+
@Json(name = "display_description")
32+
val displayDescription: String? = null,
33+
2534
@Json(name = "created_on")
2635
val createdOn: Date? = null,
2736

@@ -30,4 +39,6 @@ data class PermissionPolicy(
3039

3140
@Json(name = "permission_actions")
3241
val permissionActions: PermissionActions? = null
33-
)
42+
) : Entity {
43+
override val identifier: String? = uri
44+
}

0 commit comments

Comments
 (0)