class RiderBookingViewSchema(schema.Schema): rider_booking = fields.Raw(missing=fields.allow_missing, load_only=True, required=False) case_conversion = False from_location = fields.Raw(description="the origin of the trip") to_location = fields.Raw(description="the destination of the trip") earliest_arrival = fields.Localtime(allow_none=True) latest_arrival = fields.Localtime(allow_none=True) earliest_departure = fields.Localtime(allow_none=True) latest_departure = fields.Localtime(allow_none=True) user_id = fields.String(description="User Id (redundant)") preview_pic_url = fields.Raw( allow_none=True, description="Url of the preview picture of the origin and destination") localdate_timestamp = fields.Raw( allow_none=True, description="local time in timestamp (for sorting)") localdate_string = fields.Raw(allow_none=True, description="local time in iso8601 string") weekday = fields.Raw( allow_none=True, description= "Return the day of the week as an integer, where Monday is 0 and Sunday is 6. For example, date(2002, 12, 4).weekday() == 2, a Wednesday" ) booking_id = fields.Raw(dump_only=True, description="Resource ID for booking (redundant)")
class RideHostSchema(schema.Schema): from_location = fields.Relationship(nested=True) to_location = fields.Relationship(nested=True) earliest_arrival = fields.Raw(allow_none=True) latest_arrival = fields.Raw(allow_none=True) earliest_departure = fields.Raw(allow_none=True) latest_departure = fields.Raw(allow_none=True) user_id = fields.String() orbit_ref = fields.Relationship(nested=False, required=False, allow_none=True) status = fields.Raw()
class UserSublocationViewSchema(schema.Schema): _id = fields.Raw(dump_only=True, data_key="id") place_id = fields.Raw(dump_only=True) latitude = fields.Raw(dump_only=True) longitude = fields.Raw(dump_only=True) address = fields.Raw(dump_only=True) sublocations = fields.Raw(dump_only=True) place_name = fields.Raw(dump_only=True, default=fields.allow_missing)
class TargetSchema(schema.Schema): earliest_arrival = fields.NumberTimestamp(missing=-inf, allow_none=False) latest_arrival = fields.NumberTimestamp(missing=inf, allow_none=False) earliest_departure = fields.NumberTimestamp(missing=-inf, allow_none=False) latest_departure = fields.NumberTimestamp(missing=inf, allow_none=False) r_ref = fields.Relationship(nested=False) from_lat = fields.Raw() from_lng = fields.Raw() from_id = fields.Raw() to_lat = fields.Raw() to_lng = fields.Raw() to_id = fields.Raw() origin_geohash = fields.Raw(dump_only=True) destination_geohash = fields.Raw(dump_only=True) user_id = fields.Raw()
class UserLocationFormSchema(schema.Schema): user_location = fields.Raw(missing=fields.allow_missing, load_only=True, required=False) place_id = fields.Raw() place_name = fields.Raw() user_id = fields.Raw(dump_only=True) latitude = fields.Raw() longitude = fields.Raw() address = fields.Raw()
class RideHostViewSchema(schema.Schema): case_conversion = False ride_host = fields.Raw( missing=fields.allow_missing, load_only=True, required=False) from_location = fields.Raw() to_location = fields.Raw() earliest_arrival = fields.Localtime(allow_none=True) latest_arrival = fields.Localtime(allow_none=True) earliest_departure = fields.Localtime(allow_none=True) latest_departure = fields.Localtime(allow_none=True) user_id = fields.String() preview_pic_url = fields.Raw(allow_none=True) localdate_timestamp = fields.Raw(allow_none=True, description="local time in timestamp (for sorting)") localdate_string = fields.Raw(allow_none=True, description="local time in iso8601 string") weekday = fields.Raw(allow_none=True, description="Return the day of the week as an integer, where Monday is 0 and Sunday is 6. For example, date(2002, 12, 4).weekday() == 2, a Wednesday") hosting_id = fields.Raw(dump_only=True)
class TargetNodeSchema(schema.Schema): case_conversion = False earliest_arrival = fields.Raw() latest_arrival = fields.Raw() earliest_departure = fields.Raw() latest_departure = fields.Raw() r_ref = fields.Relationship(nested=False) user_id = fields.Raw() from_lat = fields.Raw() from_lng = fields.Raw() from_id = fields.Raw() to_lat = fields.Raw() to_lng = fields.Raw() to_id = fields.Raw()
class OrbitSchema(schema.Schema): bookings = fields.Relationship(nested=True, many=True) ride_host = fields.Relationship(nested=True, many=False, allow_none=True) status = fields.Raw() user_ticket_pairs = fields.Raw(missing=dict)
class LuggageCollectionSchema(Schema): luggages = fields.Raw(many=True, load_from="luggages", dump_to="luggages") total_count = fields.Integer(dump_to="total_count", dump_only=True) total_weight = fields.Integer(dump_to="total_weight", dump_only=True)
class TimelineSchema(schema.Schema): timeline = fields.Raw()