Skip to content

Commit

Permalink
Added FILE_UPLOADED fcm category
Browse files Browse the repository at this point in the history
  • Loading branch information
adas0206 authored and khuzema786 committed Sep 8, 2024
1 parent 4e0c3aa commit 5d2ce35
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/mobility-core/src/Kernel/External/Maps/Interface.hs
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ snapToRoadWithFallback mbMapServiceToRectifyDistantPointsFailure SnapToRoadHandl
if dist < maxStraightLineRectificationThreshold
then pure (x1, dist)
else do
distanceRes <- getDistance mapServiceCfg (GetDistanceReq {origin = x1, destination = x2, travelMode = Just CAR, distanceUnit = req.distanceUnit} :: GetDistanceReq LatLong LatLong)
distanceRes <- getDistance mapServiceCfg (GetDistanceReq {origin = x1, destination = x2, travelMode = Just CAR, distanceUnit = req.distanceUnit, sourceDestinationMapping = Nothing} :: GetDistanceReq LatLong LatLong)
pure (x1, metersToHighPrecMeters distanceRes.distance)
)
straightDistancePoints
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ data FCMNotificationType
| TRIGGER_FCM
| POST_RIDE_SOS_ALERT
| REFERRAL_FLOW
| FILE_UPLOADED
deriving (Show, Eq, Read, Ord, Generic, ToJSON, FromJSON)
deriving (PrettyShow) via Showable FCMNotificationType

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ interfaceCategoryToFCMNotificationType = \case
Interface.TRIGGER_FCM -> FCM.TRIGGER_FCM
Interface.POST_RIDE_SOS_ALERT -> FCM.POST_RIDE_SOS_ALERT
Interface.REFERRAL_FLOW -> FCM.REFERRAL_FLOW
Interface.FILE_UPLOADED -> FCM.FILE_UPLOADED

interfaceShowNotificationToFCMShowNotification :: Interface.ShowNotification -> FCM.FCMShowNotification
interfaceShowNotificationToFCMShowNotification = \case
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ data Category
| TRIGGER_FCM
| POST_RIDE_SOS_ALERT
| REFERRAL_FLOW
| FILE_UPLOADED
deriving (Show, Eq, Read, Generic, Ord, ToSchema, ToJSON, FromJSON)

$(mkBeamInstancesForEnum ''Category)
Expand All @@ -89,7 +90,9 @@ data SubCategory
| ByDriver
| ByAllocator
| ByApplication
deriving (Show, Eq, Read, Generic, ToJSON, FromJSON)
deriving (Show, Eq, Read, Generic, Ord, ToSchema, ToJSON, FromJSON)

$(mkBeamInstancesForEnum ''SubCategory)

data ShowNotification = SHOW | DO_NOT_SHOW
deriving (Show, Eq, Read, Generic, ToJSON, FromJSON)
Expand Down
1 change: 0 additions & 1 deletion lib/mobility-core/src/Kernel/Types/Beckn/City.hs
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,6 @@ instance ToHttpApiData City where
toUrlPiece Chandigarh = "std:0172"
toUrlPiece Jaipur = "std:0141"
toUrlPiece Siliguri = "std:0353"
toUrlPiece Durgapur = "std:0342"
toUrlPiece Asansol = "std:0341"
toUrlPiece Durgapur = "std:0342"
toUrlPiece Petrapole = "std:03215"
Expand Down

0 comments on commit 5d2ce35

Please sign in to comment.