Start to implement rental car support
ClosedPublic

Authored by mlaurent on Aug 9 2018, 12:00 PM.

Details

Test Plan

For the moment we don't have data for testing it...

Diff Detail

Repository
R1003 KItinerary: Travel Reservation handling library
Branch
implement_rental_car_support (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 1648
Build 1666: arc lint + arc unit
mlaurent created this revision.Aug 9 2018, 12:00 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptAug 9 2018, 12:00 PM
Restricted Application added a subscriber: kde-pim. · View Herald Transcript
mlaurent requested review of this revision.Aug 9 2018, 12:00 PM
mlaurent edited the test plan for this revision. (Show Details)Aug 9 2018, 12:01 PM
mlaurent added a reviewer: vkrause.
vkrause added inline comments.Aug 9 2018, 12:48 PM
src/datatypes/reservation.h
139

Shoudln't this be Place rather than Reservation? Same below.

mlaurent updated this revision to Diff 39357.Aug 9 2018, 4:32 PM
  • Replace Reservation by RentalCarPlace.
vkrause added inline comments.Aug 9 2018, 5:17 PM
src/datatypes/place.h
134 ↗(On Diff #39357)

Hm, Googles example data uses the Place type directly rather than a specialized sub-type: https://developers.google.com/gmail/markup/reference/rental-car . This means on deserialization we would fail with their data right now. I see a few options to address this:
(1) make the properties in RentalCarReservation QVariants to accept both types
(2) convert Place to RentalCarPlace in JsonLdImportFilter
(3) if we don't need any extra properties on RentalCarPlace on top of Place (now and foreseeable future), use Place directly and convert RentalCarPlace to Place in the import filter.

mlaurent updated this revision to Diff 39366.Aug 9 2018, 7:35 PM
  • Use Place directly. Increase version
vkrause accepted this revision.Aug 9 2018, 8:28 PM
This revision is now accepted and ready to land.Aug 9 2018, 8:28 PM
This revision was automatically updated to reflect the committed changes.