Skip to content

Commit 31638ee

Browse files
committed
Merge branch 'release/1.4.7'
2 parents f0df04d + e5c29da commit 31638ee

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

pam-android-kotlin/src/main/java/ai/pams/android/kotlin/Pam.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -604,6 +604,7 @@ class Pam {
604604
}
605605

606606
private fun createGson() = GsonBuilder()
607+
.setDateFormat("yyyy-MM-dd HH:mm:ss")
607608
.registerTypeAdapterFactory(NullableTypeAdapterFactory())
608609
.create()
609610

pam-android-kotlin/src/main/java/ai/pams/android/kotlin/models/notification/NotificationItem.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,11 @@ import ai.pams.android.kotlin.flex.parser.PImage
66
import ai.pams.android.kotlin.http.Http
77
import android.content.Context
88
import com.google.gson.annotations.SerializedName
9+
import java.util.*
910

1011
data class NotificationItem(
1112
@SerializedName("created_date")
12-
val createdDate: String? = null,
13+
val date: Date? = null,
1314
@SerializedName("deliver_id")
1415
val deliverId: String? = null,
1516
@SerializedName("description")
@@ -33,6 +34,10 @@ data class NotificationItem(
3334
) {
3435
var bannerUrl: String? = null
3536

37+
@Deprecated("createdDate is deprecated use date instead.", ReplaceWith("date"))
38+
val createdDate: Date?
39+
get() = date
40+
3641
fun parseFlex(context: Context) {
3742
flex?.let {
3843
val parser = FlexParser(context)

0 commit comments

Comments
 (0)