Not understanding how to use the RoomStay Special Case extra TimeSpan

30 views
Skip to first unread message

schro...@gmail.com

unread,
May 15, 2017, 2:35:23 AM5/15/17
to AlpineBits
As reading from the AlpineBits_2015-07b.pdf on page 25 the following article:

As a special case, however, only for quote requests (ResStatus is Requested), it is possible to add at most one optional RoomStay element that contains only the TimeSpan element. In this case, this last TimeSpan is allowed to have different values (as a matter of fact, they must be different) and it ought to be interpreted by the client as an alternative period with regard to the preceding RoomStay element(s).

i have a sample generated from my server, which does not validate against 2015-07b XSD and RNG, omitting my extra TimesSpan RoomStay is validates fine, what am i doing wrong here?

<?xml version="1.0" encoding="UTF-8"?>

<OTA_ResRetrieveRS xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.opentravel.org/OTA/2003/05"
Version="7.000"
xsi:schemaLocation="http://www.opentravel.org/OTA/2003/05 OTA_ResRetrieveRS.xsd">
<Success/>

<ReservationsList>

<HotelReservation CreateDateTime="2017-05-14T14:42:11+02:00" ResStatus="Requested">

<UniqueID Type="14" ID="24"/>

<RoomStays>

<RoomStay>

<RoomTypes>
<RoomType RoomTypeCode="1"/>
</RoomTypes>

<RatePlans>
<RatePlan>
<MealsIncluded MealPlanIndicator="true" MealPlanCodes="1"/>
</RatePlan>
</RatePlans>

<GuestCounts>
<GuestCount Count="1"/>
<GuestCount Count="1" Age="4"/>
<GuestCount Count="1" Age="6"/>
<GuestCount Count="1" Age="2"/>
</GuestCounts>

<TimeSpan Start="2017-07-01" End="2017-07-05"/>

<Total AmountAfterTax="150" CurrencyCode="EUR"/>

</RoomStay>

<RoomStay>
<TimeSpan Start="2017-07-11" End="2017-07-15"/>
</RoomStay>

</RoomStays>

<ResGuests>
<ResGuest>
<Profiles>
<ProfileInfo>
<Profile>

<Customer Gender="Unknown" BirthDate="1900-01-01" Language="en">

<PersonName>
<NamePrefix>Mr</NamePrefix>
<GivenName>Mickey</GivenName>
<Surname>Mouse</Surname>
<NameTitle>Dipl.-Agrar Ing.</NameTitle>
</PersonName>

<Telephone PhoneTechType="1" PhoneNumber="+391234123456"/>

<Telephone PhoneTechType="3" PhoneNumber="+391234123456"/>

<Telephone PhoneTechType="5" PhoneNumber="+39123123456"/>

<Email Remark="newsletter:yes">sampl...@example.com</Email>

<Address Remark="catalog:yes">

<AddressLine>Samplestreet 1</AddressLine>
<CityName>Samplecity</CityName>
<PostalCode>12345</PostalCode>
<CountryName Code="DE"/>

</Address>


</Customer>

</Profile>
</ProfileInfo>
</Profiles>
</ResGuest>
</ResGuests>

<ResGlobalInfo>

<Comments>

<Comment Name="included services">
<ListItem ListItem="0" Language="en">swimming pool</ListItem>
<ListItem ListItem="1" Language="en">ski pass</ListItem>
</Comment>

<Comment Name="customer comment">
<Text>
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.

</Text>
</Comment>

</Comments>

<BasicPropertyInfo/>

</ResGlobalInfo>

</HotelReservation>

</ReservationsList>

</OTA_ResRetrieveRS>

Stephan P.

unread,
May 15, 2017, 10:37:02 AM5/15/17
to AlpineBits, schro...@gmail.com
Indeed, the AlpineBits XSD is ambiguous:

  <!-- HotelReservation > RoomStays > RoomStay > RoomTypes {0,1} -->
  <xs:element name="RoomTypes">
    <xs:complexType>
      ...
    </xs:complexType>
  </xs:element>

According to the comment, RoomTypes should be declared optional (minOccurs="0").
We (ASA) are already able to process your special case as alternative stay period.

Regards,
Stephan

ch...@1006.org

unread,
Sep 11, 2017, 3:40:16 AM9/11/17
to AlpineBits
Hi,

this was fixed with the 2017-10 development kit. I'm posting this info again here, so people know the issue is closed.

-- Chris
Reply all
Reply to author
Forward
0 new messages