quicktravel_client 1.1.2 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (108) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +5 -0
  3. data/.ruby-version +1 -1
  4. data/.travis.yml +14 -2
  5. data/CHANGELOG.md +34 -3
  6. data/Gemfile +0 -3
  7. data/Rakefile +0 -6
  8. data/examples/login_example.rb +1 -1
  9. data/gemfiles/rails4.gemfile +9 -0
  10. data/lib/quick_travel.rb +2 -1
  11. data/lib/quick_travel/accommodation.rb +1 -15
  12. data/lib/quick_travel/adapter.rb +98 -67
  13. data/lib/quick_travel/{adapter_exception.rb → adapter_error.rb} +1 -1
  14. data/lib/quick_travel/address.rb +2 -7
  15. data/lib/quick_travel/adjustment.rb +0 -2
  16. data/lib/quick_travel/bed_configuration.rb +0 -1
  17. data/lib/quick_travel/bed_requirement.rb +0 -1
  18. data/lib/quick_travel/booking.rb +22 -46
  19. data/lib/quick_travel/cache.rb +8 -14
  20. data/lib/quick_travel/checkout.rb +1 -1
  21. data/lib/quick_travel/client.rb +2 -4
  22. data/lib/quick_travel/client_type.rb +2 -1
  23. data/lib/quick_travel/connection_error.rb +1 -1
  24. data/lib/quick_travel/constants.rb +0 -1
  25. data/lib/quick_travel/contact.rb +0 -1
  26. data/lib/quick_travel/country.rb +0 -3
  27. data/lib/quick_travel/document.rb +0 -2
  28. data/lib/quick_travel/document_group.rb +0 -2
  29. data/lib/quick_travel/location.rb +0 -2
  30. data/lib/quick_travel/party.rb +7 -12
  31. data/lib/quick_travel/passenger.rb +0 -1
  32. data/lib/quick_travel/passenger_price_break.rb +0 -2
  33. data/lib/quick_travel/passenger_type.rb +0 -2
  34. data/lib/quick_travel/payment.rb +0 -3
  35. data/lib/quick_travel/payment_type.rb +4 -13
  36. data/lib/quick_travel/price_changes.rb +3 -0
  37. data/lib/quick_travel/price_changes/booking_price_change.rb +30 -0
  38. data/lib/quick_travel/price_changes/price_change.rb +23 -0
  39. data/lib/quick_travel/{discounts/discount_tree.rb → price_changes/price_change_tree.rb} +12 -8
  40. data/lib/quick_travel/product.rb +15 -28
  41. data/lib/quick_travel/product_type.rb +4 -16
  42. data/lib/quick_travel/property.rb +4 -20
  43. data/lib/quick_travel/property_facility.rb +0 -1
  44. data/lib/quick_travel/property_type.rb +2 -14
  45. data/lib/quick_travel/region.rb +0 -9
  46. data/lib/quick_travel/reservation.rb +0 -21
  47. data/lib/quick_travel/resource.rb +7 -28
  48. data/lib/quick_travel/room_facility.rb +0 -1
  49. data/lib/quick_travel/route.rb +9 -25
  50. data/lib/quick_travel/route_stop.rb +0 -1
  51. data/lib/quick_travel/service.rb +2 -1
  52. data/lib/quick_travel/status.rb +23 -0
  53. data/lib/quick_travel/trip.rb +0 -1
  54. data/lib/quick_travel/vehicle.rb +2 -4
  55. data/lib/quick_travel/vehicle_type.rb +0 -3
  56. data/lib/quick_travel/version.rb +1 -1
  57. data/quicktravel_client.gemspec +4 -4
  58. data/spec/booking_spec.rb +24 -0
  59. data/spec/discounts_spec.rb +69 -69
  60. data/spec/passenger_type_spec.rb +30 -0
  61. data/spec/payment_type_spec.rb +10 -0
  62. data/spec/product_spec.rb +52 -21
  63. data/spec/product_type_spec.rb +19 -0
  64. data/spec/property_spec.rb +83 -0
  65. data/spec/region_spec.rb +1 -1
  66. data/spec/reservation_spec.rb +3 -2
  67. data/spec/resource_spec.rb +31 -7
  68. data/spec/route_spec.rb +118 -0
  69. data/spec/spec_helper.rb +18 -25
  70. data/spec/status_spec.rb +9 -0
  71. data/spec/support/cassettes/booking_create.yml +39 -33
  72. data/spec/support/cassettes/booking_documents.yml +36 -30
  73. data/spec/support/cassettes/booking_price_changes.yml +66 -0
  74. data/spec/support/cassettes/booking_show.yml +38 -32
  75. data/spec/support/cassettes/booking_update.yml +74 -62
  76. data/spec/support/cassettes/booking_with_documents.yml +88 -76
  77. data/spec/support/cassettes/booking_with_nested_attributes.yml +128 -110
  78. data/spec/support/cassettes/booking_with_price_changes.yml +86 -0
  79. data/spec/support/cassettes/countries.yml +140 -0
  80. data/spec/support/cassettes/country_all.yml +36 -30
  81. data/spec/support/cassettes/create_reservation_fail.yml +32 -27
  82. data/spec/support/cassettes/create_reservation_with_booking.yml +40 -34
  83. data/spec/support/cassettes/passenger_all.yml +36 -30
  84. data/spec/support/cassettes/payment_info.yml +61 -0
  85. data/spec/support/cassettes/product_date_range_bookability.yml +61 -59
  86. data/spec/support/cassettes/product_show.yml +42 -32
  87. data/spec/support/cassettes/product_show_as_agent.yml +63 -0
  88. data/spec/support/cassettes/product_type_all.yml +53 -0
  89. data/spec/support/cassettes/property.yml +66 -0
  90. data/spec/support/cassettes/region_show.yml +36 -30
  91. data/spec/support/cassettes/reservation_with_extra_picks.yml +137 -110
  92. data/spec/support/cassettes/resource_fare_bases.yml +47 -78
  93. data/spec/support/cassettes/resource_product_type.yml +63 -0
  94. data/spec/support/cassettes/resource_show.yml +37 -31
  95. data/spec/support/cassettes/resource_with_price.yml +63 -0
  96. data/spec/support/cassettes/route_all.yml +65 -0
  97. data/spec/support/cassettes/tenant_switcher.yml +109 -0
  98. data/spec/support/coverage_loader.rb +26 -0
  99. data/spec/tenant_spec.rb +28 -0
  100. metadata +106 -115
  101. data/bootstrap/boot.rb +0 -4
  102. data/lib/quick_travel/discounts.rb +0 -3
  103. data/lib/quick_travel/discounts/booking_discount.rb +0 -18
  104. data/lib/quick_travel/discounts/discount.rb +0 -21
  105. data/spec/support/cassettes/booking_create_legacy.yml +0 -50
  106. data/spec/support/cassettes/booking_discounts.yml +0 -53
  107. data/spec/support/cassettes/booking_with_discounts.yml +0 -72
  108. data/spec/support/cassettes/region_index.yml +0 -48
@@ -2,47 +2,53 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://0.0.0.0:8080/api/bookings/3/documents.json?last_group=true&regenerate=false
5
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/2/documents.json?last_group=true&regenerate=false
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: access_key=<QT_KEY>
9
9
  headers:
10
- content-length:
10
+ Content-Length:
11
11
  - '0'
12
12
  response:
13
13
  status:
14
14
  code: 200
15
- message: ! 'OK '
15
+ message: 'OK '
16
16
  headers:
17
- p3p:
17
+ P3p:
18
18
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
- content-type:
19
+ Content-Type:
20
20
  - application/json; charset=utf-8
21
- x-ua-compatible:
22
- - IE=Edge,chrome=1
23
- etag:
24
- - ! '"d751713988987e9331980363e24189ce"'
25
- cache-control:
26
- - max-age=0, private, must-revalidate
27
- x-request-id:
28
- - dda534836aa87de16e4676661b86732d
29
- x-runtime:
30
- - '0.025246'
31
- date:
32
- - Thu, 28 Feb 2013 14:16:27 GMT
33
- x-rack-cache:
21
+ X-Ua-Compatible:
22
+ - IE=Edge
23
+ Cache-Control:
24
+ - no-store, must-revalidate, private, max-age=0
25
+ X-Request-Id:
26
+ - 7aab3392a2e5fe36b5da73636c30beeb
27
+ X-Runtime:
28
+ - '0.158966'
29
+ Vary:
30
+ - Origin
31
+ X-Rack-Cache:
34
32
  - miss
35
- server:
36
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
- content-length:
33
+ X-Miniprofiler-Ids:
34
+ - '["ceg9zan4uza0v8zoi5tp","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
35
+ Server:
36
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
37
+ Date:
38
+ - Mon, 26 Oct 2015 00:18:44 GMT
39
+ Content-Length:
38
40
  - '2'
39
- connection:
40
- - close
41
- set-cookie:
42
- - _session_id=b6531aad203363dea39988a351a9b961; path=/; HttpOnly
41
+ Connection:
42
+ - Keep-Alive
43
+ Set-Cookie:
44
+ - __profilin=p%3Dt; path=/
45
+ - __profilin=p%3Dt; path=/
46
+ - __profilin=p%3Dt; path=/
47
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWZmYjgyMmZiODkxOTQxYmVkNGY0ZDFiNDQyY2EwMTZjBjsAVEkiCXVzZXIGOwBGaQY%3D--e298c165e73d3a0b23a2911b4b63c256d129850e;
48
+ path=/; HttpOnly
43
49
  body:
44
- encoding: US-ASCII
45
- string: ! '[]'
46
- http_version: '1.1'
47
- recorded_at: Thu, 18 Dec 2014 07:33:16 GMT
50
+ encoding: UTF-8
51
+ string: "[]"
52
+ http_version:
53
+ recorded_at: Mon, 26 Oct 2015 00:18:44 GMT
48
54
  recorded_with: VCR 2.9.3
@@ -0,0 +1,66 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/1/price_change.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ Content-Length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: 'OK '
16
+ headers:
17
+ X-Frame-Options:
18
+ - SAMEORIGIN
19
+ X-Xss-Protection:
20
+ - '1'
21
+ X-Content-Type-Options:
22
+ - nosniff
23
+ X-Download-Options:
24
+ - noopen
25
+ X-Permitted-Cross-Domain-Policies:
26
+ - none
27
+ P3p:
28
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
29
+ Content-Type:
30
+ - application/json; charset=utf-8
31
+ X-Ua-Compatible:
32
+ - IE=Edge,chrome=1
33
+ Etag:
34
+ - '"7b91c75a4f38e04e4f967265134f1051"'
35
+ Cache-Control:
36
+ - max-age=0, private, must-revalidate
37
+ X-Request-Id:
38
+ - 0c53d1b7d4305f1b7b5cd8c34a510745
39
+ X-Runtime:
40
+ - '0.095538'
41
+ Vary:
42
+ - Origin
43
+ Date:
44
+ - Thu, 28 Feb 2013 13:32:44 GMT
45
+ X-Rack-Cache:
46
+ - miss
47
+ Server:
48
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
49
+ Content-Length:
50
+ - '1625'
51
+ Connection:
52
+ - Keep-Alive
53
+ Set-Cookie:
54
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWQwZmVhNzIyODRlZDUxMWUwNzlmYzZmNDQ0NzA0MDQxBjsAVEkiCXVzZXIGOwBGaQY%3D--2ddfab634e53917e629c989ce066bc5531d78e6d;
55
+ path=/; HttpOnly
56
+ body:
57
+ encoding: UTF-8
58
+ string: '{"target":{"type":"Booking","id":1},"original_price_in_cents":64000,"changed_price_in_cents":38000,"price_change_in_cents":-26000,"reason":"Test
59
+ Discount Hilton and QBE Get Me","discounted_price_in_cents":38000,"discount_in_cents":-26000,"reservation_price_changes":[{"target":{"type":"Reservation","id":1},"original_price_in_cents":64000,"changed_price_in_cents":38000,"price_change_in_cents":-26000,"reason":"Test
60
+ Discount Hilton and QBE Get Me","discounted_price_in_cents":38000,"discount_in_cents":-26000,"root":{"target":{"type":"Reservation","id":1},"original_price_in_cents":40000,"changed_price_in_cents":20000,"price_change_in_cents":-20000,"reason":"Test
61
+ Discount Hilton","discounted_price_in_cents":20000,"discount_in_cents":-20000},"children":[{"target":{"type":"Reservation","id":3},"original_price_in_cents":12000,"changed_price_in_cents":12000,"price_change_in_cents":0,"reason":"","discounted_price_in_cents":12000,"discount_in_cents":0,"root":{"target":{"type":"Reservation","id":3},"original_price_in_cents":12000,"changed_price_in_cents":12000,"price_change_in_cents":0,"reason":"","discounted_price_in_cents":12000,"discount_in_cents":0},"children":[]},{"target":{"type":"Reservation","id":2},"original_price_in_cents":12000,"changed_price_in_cents":6000,"price_change_in_cents":-6000,"reason":"QBE
62
+ Get Me","discounted_price_in_cents":6000,"discount_in_cents":-6000,"root":{"target":{"type":"Reservation","id":2},"original_price_in_cents":12000,"changed_price_in_cents":6000,"price_change_in_cents":-6000,"reason":"QBE
63
+ Get Me","discounted_price_in_cents":6000,"discount_in_cents":-6000},"children":[]}]}]}'
64
+ http_version:
65
+ recorded_at: Wed, 30 Dec 2015 05:57:39 GMT
66
+ recorded_with: VCR 2.9.3
@@ -2,48 +2,54 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://0.0.0.0:8080/api/bookings/3.json?
5
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/2.json
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: access_key=<QT_KEY>
9
9
  headers:
10
- content-length:
10
+ Content-Length:
11
11
  - '0'
12
12
  response:
13
13
  status:
14
14
  code: 200
15
- message: ! 'OK '
15
+ message: 'OK '
16
16
  headers:
17
- p3p:
17
+ P3p:
18
18
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
- content-type:
19
+ Content-Type:
20
20
  - application/json; charset=utf-8
21
- x-ua-compatible:
22
- - IE=Edge,chrome=1
23
- etag:
24
- - ! '"e46ab802351e11f08fac294ef77f5c74"'
25
- cache-control:
26
- - max-age=0, private, must-revalidate
27
- x-request-id:
28
- - 887edf25cea02eaf0683ae0720994553
29
- x-runtime:
30
- - '0.028099'
31
- date:
32
- - Thu, 28 Feb 2013 14:16:26 GMT
33
- x-rack-cache:
21
+ X-Ua-Compatible:
22
+ - IE=Edge
23
+ Cache-Control:
24
+ - no-store, must-revalidate, private, max-age=0
25
+ X-Request-Id:
26
+ - 4099d1805b0ed2d4e28fc78f42acfc99
27
+ X-Runtime:
28
+ - '0.102448'
29
+ Vary:
30
+ - Origin
31
+ X-Rack-Cache:
34
32
  - miss
35
- server:
36
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
- content-length:
38
- - '1908'
39
- connection:
40
- - close
41
- set-cookie:
42
- - _session_id=21a47f3f5b34001c8bfead0f5511a0ba; path=/; HttpOnly
33
+ X-Miniprofiler-Ids:
34
+ - '["v2b9hwm2gbv6tn5e7ue9","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
35
+ Server:
36
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
37
+ Date:
38
+ - Mon, 26 Oct 2015 00:18:43 GMT
39
+ Content-Length:
40
+ - '2160'
41
+ Connection:
42
+ - Keep-Alive
43
+ Set-Cookie:
44
+ - __profilin=p%3Dt; path=/
45
+ - __profilin=p%3Dt; path=/
46
+ - __profilin=p%3Dt; path=/
47
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWJiMThiZWEyNWVmZGUzYzgzOTQ5ODliZDhjMjU5MjhlBjsAVEkiCXVzZXIGOwBGaQY%3D--05e8ff81acb224f966d97eaddd0144880a552d33;
48
+ path=/; HttpOnly
43
49
  body:
44
- encoding: US-ASCII
45
- string: ! '{"id":3,"state":"new","reference":"222226","public_comments":null,"internal_comments":null,"customer_contact_name":null,"customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":0,"nett_in_cents":0,"gross_in_cents":0,"commission_in_cents":0,"balance_in_cents":0,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":"SeaLink","promo_code":null,"insurance_offered":false,"deposit_due_on":null,"balance_due_on":null,"first_travel_date":{"_type":"Date","_value":"2013-03-01"},"last_travel_date":null,"complete":true,"reason_not_complete":null,"discardable_in":60,"inactivatable_in":10,"notices":{},"deposit_relevant":false,"passenger_ids":[],"vehicle_ids":[],"reservation_ids":[],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[],"vehicles_attributes":[],"reservations_attributes":[],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":7,"name":"PayPal","description":"Payments
46
- made via PayPal account","payment_method":"paypal","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true}]}'
47
- http_version: '1.1'
48
- recorded_at: Thu, 18 Dec 2014 07:33:16 GMT
50
+ encoding: UTF-8
51
+ string: '{"id":2,"state":"new","reference":"222224","public_comments":null,"internal_comments":null,"customer_contact_name":null,"customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"created_at":"2015-11-18T14:45:58+10:30","updated_at":"2015-11-18T14:45:58+10:30","promo_code":null,"promo_code_id":null,"insurance_offered":false,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":0,"nett_in_cents":0,"gross_in_cents":0,"commission_in_cents":0,"balance_in_cents":0,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":"SeaLink","deposit_relevant":false,"deposit_due_on":null,"balance_due_on":null,"first_travel_date":{"_type":"Date","_value":"2015-11-18"},"last_travel_date":null,"complete":true,"reason_not_complete":null,"discardable_in":60,"inactivatable_in":10,"notices":{},"passenger_ids":[],"vehicle_ids":[],"reservation_ids":[],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[],"vehicles_attributes":[],"reservations_attributes":[],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":7,"name":"PayPal","description":"Payments
52
+ made via PayPal account","payment_method":"paypal","gateway":"braintree","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false}],"issued_tickets_attributes":[]}'
53
+ http_version:
54
+ recorded_at: Mon, 26 Oct 2015 00:18:43 GMT
49
55
  recorded_with: VCR 2.9.3
@@ -2,93 +2,105 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: put
5
- uri: http://0.0.0.0:8080/api/bookings/3.json
5
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/2.json
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: booking[customer_contact_name]=John&access_key=<QT_KEY>
9
9
  headers:
10
- content-length:
10
+ Content-Length:
11
11
  - '0'
12
12
  response:
13
13
  status:
14
14
  code: 200
15
- message: ! 'OK '
15
+ message: 'OK '
16
16
  headers:
17
- p3p:
17
+ P3p:
18
18
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
- content-type:
19
+ Content-Type:
20
20
  - application/json; charset=utf-8
21
- x-ua-compatible:
22
- - IE=Edge,chrome=1
23
- etag:
24
- - ! '"7363e85fe9edee6f053a4b319588c086"'
25
- cache-control:
26
- - max-age=0, private, must-revalidate
27
- x-request-id:
28
- - 958f8102631d77aa5df03dad8dd0168b
29
- x-runtime:
30
- - '0.342271'
31
- date:
32
- - Thu, 28 Feb 2013 14:16:27 GMT
33
- x-rack-cache:
21
+ X-Ua-Compatible:
22
+ - IE=Edge
23
+ Cache-Control:
24
+ - no-store, must-revalidate, private, max-age=0
25
+ X-Request-Id:
26
+ - 5e2e185726ab7c1b679a808e87b722d4
27
+ X-Runtime:
28
+ - '0.115204'
29
+ Vary:
30
+ - Origin
31
+ X-Rack-Cache:
34
32
  - invalidate, pass
35
- server:
36
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
- content-length:
33
+ X-Miniprofiler-Ids:
34
+ - '["r5uljau93vrmsu7dvik7","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
35
+ Server:
36
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
37
+ Date:
38
+ - Mon, 26 Oct 2015 00:18:43 GMT
39
+ Content-Length:
38
40
  - '16'
39
- connection:
40
- - close
41
- set-cookie:
42
- - _session_id=101bcafdb111f07269d23e4988bf4bc2; path=/; HttpOnly
41
+ Connection:
42
+ - Keep-Alive
43
+ Set-Cookie:
44
+ - __profilin=p%3Dt; path=/
45
+ - __profilin=p%3Dt; path=/
46
+ - __profilin=p%3Dt; path=/
47
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTAzM2ZjMjliNDcxZGFhYzQ1YmVlNjU5OTZlZmMzNWUzBjsAVEkiCXVzZXIGOwBGaQY%3D--e635e9cbdaa0604d048d31850e7df4264fc145e8;
48
+ path=/; HttpOnly
43
49
  body:
44
- encoding: US-ASCII
45
- string: ! '{"success":true}'
46
- http_version: '1.1'
47
- recorded_at: Thu, 18 Dec 2014 07:33:16 GMT
50
+ encoding: UTF-8
51
+ string: '{"success":true}'
52
+ http_version:
53
+ recorded_at: Mon, 26 Oct 2015 00:18:43 GMT
48
54
  - request:
49
55
  method: get
50
- uri: http://0.0.0.0:8080/api/bookings/3.json?
56
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/2.json
51
57
  body:
52
- encoding: US-ASCII
58
+ encoding: UTF-8
53
59
  string: access_key=<QT_KEY>
54
60
  headers:
55
- content-length:
61
+ Content-Length:
56
62
  - '0'
57
63
  response:
58
64
  status:
59
65
  code: 200
60
- message: ! 'OK '
66
+ message: 'OK '
61
67
  headers:
62
- p3p:
68
+ P3p:
63
69
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
64
- content-type:
70
+ Content-Type:
65
71
  - application/json; charset=utf-8
66
- x-ua-compatible:
67
- - IE=Edge,chrome=1
68
- etag:
69
- - ! '"44d2917ae555e3fb822366b754ac5fe2"'
70
- cache-control:
71
- - max-age=0, private, must-revalidate
72
- x-request-id:
73
- - 982eb67a8c0120e54393e5b4867395ed
74
- x-runtime:
75
- - '0.028250'
76
- date:
77
- - Thu, 28 Feb 2013 14:16:27 GMT
78
- x-rack-cache:
72
+ X-Ua-Compatible:
73
+ - IE=Edge
74
+ Cache-Control:
75
+ - no-store, must-revalidate, private, max-age=0
76
+ X-Request-Id:
77
+ - e781e9ffe845c2e4358a6d5f32978d02
78
+ X-Runtime:
79
+ - '0.107253'
80
+ Vary:
81
+ - Origin
82
+ X-Rack-Cache:
79
83
  - miss
80
- server:
81
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
82
- content-length:
83
- - '1910'
84
- connection:
85
- - close
86
- set-cookie:
87
- - _session_id=9d117a8940e1f11cd6a39f3600798003; path=/; HttpOnly
84
+ X-Miniprofiler-Ids:
85
+ - '["ernyl1slki20rwagrd5p","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
86
+ Server:
87
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
88
+ Date:
89
+ - Mon, 26 Oct 2015 00:18:43 GMT
90
+ Content-Length:
91
+ - '2162'
92
+ Connection:
93
+ - Keep-Alive
94
+ Set-Cookie:
95
+ - __profilin=p%3Dt; path=/
96
+ - __profilin=p%3Dt; path=/
97
+ - __profilin=p%3Dt; path=/
98
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTljN2YzODkxZGE0ZmEyYjYwNWVkNDRhZjM3ODIxYWE5BjsAVEkiCXVzZXIGOwBGaQY%3D--f0d2fa747da5c85f6ec5a7a7ba894e6a80451f99;
99
+ path=/; HttpOnly
88
100
  body:
89
- encoding: US-ASCII
90
- string: ! '{"id":3,"state":"new","reference":"222226","public_comments":null,"internal_comments":null,"customer_contact_name":"John","customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":0,"nett_in_cents":0,"gross_in_cents":0,"commission_in_cents":0,"balance_in_cents":0,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":"SeaLink","promo_code":null,"insurance_offered":false,"deposit_due_on":null,"balance_due_on":null,"first_travel_date":{"_type":"Date","_value":"2013-03-01"},"last_travel_date":null,"complete":true,"reason_not_complete":null,"discardable_in":60,"inactivatable_in":10,"notices":{},"deposit_relevant":false,"passenger_ids":[],"vehicle_ids":[],"reservation_ids":[],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[],"vehicles_attributes":[],"reservations_attributes":[],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":7,"name":"PayPal","description":"Payments
91
- made via PayPal account","payment_method":"paypal","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true}]}'
92
- http_version: '1.1'
93
- recorded_at: Thu, 18 Dec 2014 07:33:16 GMT
101
+ encoding: UTF-8
102
+ string: '{"id":2,"state":"new","reference":"222224","public_comments":null,"internal_comments":null,"customer_contact_name":"John","customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"created_at":"2015-11-18T14:45:58+10:30","updated_at":"2015-11-18T14:45:58+10:30","promo_code":null,"promo_code_id":null,"insurance_offered":false,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":0,"nett_in_cents":0,"gross_in_cents":0,"commission_in_cents":0,"balance_in_cents":0,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":"SeaLink","deposit_relevant":false,"deposit_due_on":null,"balance_due_on":null,"first_travel_date":{"_type":"Date","_value":"2015-11-18"},"last_travel_date":null,"complete":true,"reason_not_complete":null,"discardable_in":60,"inactivatable_in":10,"notices":{},"passenger_ids":[],"vehicle_ids":[],"reservation_ids":[],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[],"vehicles_attributes":[],"reservations_attributes":[],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":7,"name":"PayPal","description":"Payments
103
+ made via PayPal account","payment_method":"paypal","gateway":"braintree","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false}],"issued_tickets_attributes":[]}'
104
+ http_version:
105
+ recorded_at: Mon, 26 Oct 2015 00:18:43 GMT
94
106
  recorded_with: VCR 2.9.3
@@ -2,116 +2,128 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://0.0.0.0:8080/api/bookings/1.json?
5
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/1.json
6
6
  body:
7
- encoding: US-ASCII
7
+ encoding: UTF-8
8
8
  string: access_key=<QT_KEY>
9
9
  headers:
10
- content-length:
10
+ Content-Length:
11
11
  - '0'
12
12
  response:
13
13
  status:
14
14
  code: 200
15
- message: ! 'OK '
15
+ message: 'OK '
16
16
  headers:
17
- p3p:
17
+ P3p:
18
18
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
- content-type:
19
+ Content-Type:
20
20
  - application/json; charset=utf-8
21
- x-ua-compatible:
22
- - IE=Edge,chrome=1
23
- etag:
24
- - ! '"979f11e6024532d965e0b8281488f134"'
25
- cache-control:
26
- - max-age=0, private, must-revalidate
27
- x-request-id:
28
- - 843b269e235cf88c2b29901b8ae25c85
29
- x-runtime:
30
- - '0.128731'
31
- date:
32
- - Thu, 28 Feb 2013 14:20:59 GMT
33
- x-rack-cache:
21
+ X-Ua-Compatible:
22
+ - IE=Edge
23
+ Cache-Control:
24
+ - no-store, must-revalidate, private, max-age=0
25
+ X-Request-Id:
26
+ - e484be28139a6e16289015effe20f107
27
+ X-Runtime:
28
+ - '0.965696'
29
+ Vary:
30
+ - Origin
31
+ X-Rack-Cache:
34
32
  - miss
35
- server:
36
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
- content-length:
38
- - '11694'
39
- connection:
40
- - close
41
- set-cookie:
42
- - _session_id=27e1d1ad1683ee7e4955e0f7384f1de2; path=/; HttpOnly
33
+ X-Miniprofiler-Ids:
34
+ - '["v89i3py9r73xf497p5uw","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
35
+ Server:
36
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
37
+ Date:
38
+ - Mon, 26 Oct 2015 00:18:45 GMT
39
+ Content-Length:
40
+ - '12124'
41
+ Connection:
42
+ - Keep-Alive
43
+ Set-Cookie:
44
+ - __profilin=p%3Dt; path=/
45
+ - __profilin=p%3Dt; path=/
46
+ - __profilin=p%3Dt; path=/
47
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWY4YTQ1MDAxOGIwMGQzMTgxZDYxMmY1YWVlMWY0OGViBjsAVEkiCXVzZXIGOwBGaQY%3D--17d992c7f13a7208dbca2e4c4a036704ccb798c4;
48
+ path=/; HttpOnly
43
49
  body:
44
- encoding: US-ASCII
45
- string: ! '{"id":1,"state":"new","reference":"222223","public_comments":null,"internal_comments":null,"customer_contact_name":null,"customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":38000,"nett_in_cents":38000,"gross_in_cents":38000,"commission_in_cents":0,"balance_in_cents":38000,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":null,"promo_code":null,"insurance_offered":false,"deposit_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"balance_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"complete":true,"reason_not_complete":null,"discardable_in":50,"inactivatable_in":0,"notices":{},"deposit_relevant":false,"passenger_ids":[1,2],"vehicle_ids":[],"reservation_ids":[1,3,2],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[{"id":1,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":1},{"id":2,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":2}],"vehicles_attributes":[],"reservations_attributes":[{"id":1,"booking_id":1,"description":"A
46
- basic studio room","comment":"","active":true,"service_ids":[3,4],"resource_id":6,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"bed_configuration":"1
47
- x Double","product_type_id":2,"itinerary_footer":false,"fare_basis_set_id":12,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":6,"pick_up_info":null,"drop_off_info":null,"selection_name":"Hilton
48
- Hotel: Executive Room","product_name_underscore":"accommodation","resource_class_name_underscore":"accommodation","resource_class_name":"Accommodation","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"checkout_date":{"_type":"Date","_value":"2016-03-03"},"duration_units":"Nights","date_start_label":"In:","date_end_label":"Out:","accommodation_extra_picks":false,"has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
49
- Priced as: Rack Rate","gross_including_packaged_item_in_cents":38000,"pre_adjusted_gross_including_packaged_item_in_cents":64000,"gross_in_cents":20000,"pre_adjusted_gross_in_cents":40000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":20000,"sub_items_gross_in_cents":18000,"adjustments_attributes":[{"id":6,"gross_in_cents":-20000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
50
+ encoding: UTF-8
51
+ string: '{"id":1,"state":"active","reference":"222223","public_comments":null,"internal_comments":null,"customer_contact_name":null,"customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":3,"post_code":"","referral_code_id":1,"created_at":"2013-03-01T00:05:46+10:30","updated_at":"2013-03-01T00:15:33+10:30","promo_code":null,"promo_code_id":null,"insurance_offered":false,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":38000,"nett_in_cents":38000,"gross_in_cents":38000,"commission_in_cents":0,"balance_in_cents":38000,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":null,"deposit_relevant":false,"deposit_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"balance_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"complete":true,"reason_not_complete":null,"discardable_in":-1395933,"inactivatable_in":-1395983,"notices":{},"passenger_ids":[1,2],"vehicle_ids":[],"reservation_ids":[1,3,2],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[{"id":1,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":1},{"id":2,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":2}],"vehicles_attributes":[],"reservations_attributes":[{"id":1,"booking_id":1,"description":"A
52
+ basic studio room","comment":"","active":true,"service_ids":[3,4],"resource_id":6,"quantity":null,"adjustments_attributes":[{"id":6,"gross_in_cents":-20000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
50
53
  Administrator","notes":null,"remember_token":null,"remember_token_expires_at":null,"salt":null,"title":null,"updated_at":"2013-03-01T00:00:03+10:30","updator_id":null},"created_at":"2013-03-01T00:40:04+10:30","description":"50%
51
- Off","adjustable_item_type":"Reservation","adjustable_item_id":1,"automatic":true}],"rules":[{"unique_name":"Test
54
+ Off","adjustable_item_type":"Reservation","adjustable_item_id":1,"adjustment_definition_id":1,"adjustment_category_id":1,"automatic":true}],"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"bed_configuration":"1
55
+ x Double and 1 x Single","product_type_id":2,"itinerary_footer":false,"fare_basis_set_id":12,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":6,"pick_up_info":null,"drop_off_info":null,"selection_name":"Hilton
56
+ Hotel: Executive Room","product_name_underscore":"accommodation","resource_class_name_underscore":"accommodation","resource_class_name":"Accommodation","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"checkout_date":{"_type":"Date","_value":"2016-03-03"},"duration_units":"Nights","date_start_label":"In:","date_end_label":"Out:","accommodation_extra_picks":false,"expires":false,"has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
57
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":38000,"pre_adjusted_gross_including_packaged_item_in_cents":64000,"gross_in_cents":20000,"pre_adjusted_gross_in_cents":40000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":20000,"sub_items_gross_in_cents":18000,"rules":[{"unique_name":"Test
52
58
  Discount Hilton","description":"","display_name":"Test Discount Hilton"}],"package":false,"sub_reservation_depth":0,"sub_reservations_attributes":[{"id":3,"booking_id":1,"description":"You
53
59
  have declined Travel Insurance for your booking. If you wish to add Travel
54
60
  Insurance to this booking, please contact the SeaLink Travel Group on 13 13
55
- 01 prior to commencing your travels.","comment":null,"active":true,"service_ids":[7,8],"resource_id":4,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"Travel
61
+ 01 prior to commencing your travels.","comment":null,"active":true,"service_ids":[7,8],"resource_id":4,"quantity":null,"adjustments_attributes":[],"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"Travel
56
62
  Insurance - Declined","product_name_underscore":"travel_insurance","resource_class_name_underscore":"insurance","resource_class_name":"Insurance","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"duration_units":"Days","date_start_label":"Start
57
- Date:","date_end_label":"End Date:","has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
58
- Priced as: Rack Rate","gross_including_packaged_item_in_cents":12000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":12000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"adjustments_attributes":[],"rules":[],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":7,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":8,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":6000,"2":6000}},{"id":2,"booking_id":1,"description":"QBE
63
+ Date:","date_end_label":"End Date:","expires":false,"has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
64
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":12000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":12000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"rules":[],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pick_up_information":null,"drop_off_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":7,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":8,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":6000,"2":6000}},{"id":2,"booking_id":1,"description":"QBE
59
65
  Travel Insurance Policy E known as the ''Australian Cancellation and Additional
60
66
  Expenses'' plan has been included into this booking. This covers you for defined
61
67
  unforeseen cancellations and additional expenses. Please refer to the Product
62
- Disclosure Statement for further information.","comment":null,"active":true,"service_ids":[5,6],"resource_id":3,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"QBE
63
- Travel Insurance - Policy E","product_name_underscore":"travel_insurance","resource_class_name_underscore":"insurance","resource_class_name":"Insurance","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"duration_units":"Days","date_start_label":"Start
64
- Date:","date_end_label":"End Date:","has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
65
- Priced as: Rack Rate","gross_including_packaged_item_in_cents":6000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":6000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"adjustments_attributes":[{"id":5,"gross_in_cents":-6000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
68
+ Disclosure Statement for further information.","comment":null,"active":true,"service_ids":[5,6],"resource_id":3,"quantity":null,"adjustments_attributes":[{"id":5,"gross_in_cents":-6000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
66
69
  Administrator","notes":null,"remember_token":null,"remember_token_expires_at":null,"salt":null,"title":null,"updated_at":"2013-03-01T00:00:03+10:30","updator_id":null},"created_at":"2013-03-01T00:40:04+10:30","description":"50%
67
- Off","adjustable_item_type":"Reservation","adjustable_item_id":2,"automatic":true}],"rules":[{"unique_name":"QBE
68
- Get Me","description":"","display_name":"QBE Get Me"}],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":3,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":4,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":3000,"2":3000}}],"extra_pick":null,"child_resource":null,"pending_confirmation":false,"confirmation_request_fields":[],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":1,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":2,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":0,"2":0}}],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":7,"name":"PayPal","description":"Payments
69
- made via PayPal account","payment_method":"paypal","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true}]}'
70
- http_version: '1.1'
71
- recorded_at: Thu, 18 Dec 2014 07:37:48 GMT
70
+ Off","adjustable_item_type":"Reservation","adjustable_item_id":2,"adjustment_definition_id":1,"adjustment_category_id":1,"automatic":true}],"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"QBE
71
+ Travel Insurance - Policy E","product_name_underscore":"travel_insurance","resource_class_name_underscore":"insurance","resource_class_name":"Insurance","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"duration_units":"Days","date_start_label":"Start
72
+ Date:","date_end_label":"End Date:","expires":false,"has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
73
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":6000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":6000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"rules":[{"unique_name":"QBE
74
+ Get Me","description":"","display_name":"QBE Get Me"}],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pick_up_information":null,"drop_off_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":3,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":4,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":3000,"2":3000}}],"extra_pick":null,"child_resource":null,"pending_confirmation":false,"confirmation_request_fields":[],"report_reservation_changes":false,"vendor_pnr":null,"pick_up_information":null,"drop_off_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":1,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":2,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":0,"2":0}}],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","gateway":"braintree","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false},{"id":7,"name":"PayPal","description":"Payments
75
+ made via PayPal account","payment_method":"paypal","gateway":"braintree","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true,"redirect":false}],"issued_tickets_attributes":[]}'
76
+ http_version:
77
+ recorded_at: Mon, 26 Oct 2015 00:18:45 GMT
72
78
  - request:
73
79
  method: get
74
- uri: http://0.0.0.0:8080/api/bookings/1/documents.json?last_group=true&regenerate=false
80
+ uri: http://test.qt.sealink.com.au:8080/api/bookings/1/documents.json?last_group=true&regenerate=false
75
81
  body:
76
- encoding: US-ASCII
82
+ encoding: UTF-8
77
83
  string: access_key=<QT_KEY>
78
84
  headers:
79
- content-length:
85
+ Content-Length:
80
86
  - '0'
81
87
  response:
82
88
  status:
83
89
  code: 200
84
- message: ! 'OK '
90
+ message: 'OK '
85
91
  headers:
86
- p3p:
92
+ P3p:
87
93
  - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
88
- content-type:
94
+ Content-Type:
89
95
  - application/json; charset=utf-8
90
- x-ua-compatible:
91
- - IE=Edge,chrome=1
92
- etag:
93
- - ! '"877efa1d49e3e645f3aa1d836e4ee620"'
94
- cache-control:
95
- - max-age=0, private, must-revalidate
96
- x-request-id:
97
- - d0aeb7bb3e6bb5b030ede5cfe6ca2c91
98
- x-runtime:
99
- - '0.019773'
100
- date:
101
- - Thu, 28 Feb 2013 14:20:59 GMT
102
- x-rack-cache:
96
+ X-Ua-Compatible:
97
+ - IE=Edge
98
+ Cache-Control:
99
+ - no-store, must-revalidate, private, max-age=0
100
+ X-Request-Id:
101
+ - 0f52eb22083a5f05b4c5bb57b8a383a4
102
+ X-Runtime:
103
+ - '0.073278'
104
+ Vary:
105
+ - Origin
106
+ X-Rack-Cache:
103
107
  - miss
104
- server:
105
- - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
106
- content-length:
108
+ X-Miniprofiler-Ids:
109
+ - '["wey4tzg05y6h98h2ufkx","3n393d46407xjckipoz4","sbzq3sn22o19v6amh4lx","hnsva789t8cmifp64wx3","wmmnukmwie7vr7vj8xqf","2brmax1rs5fwk4fd7n5","dvsmvrl183r0tifnlw46","5o49qsg88hbcsljo43fu","w0wrmi9s9rgua6owkm3z","lxziuvwk5cnyi9wz6zbf"]'
110
+ Server:
111
+ - WEBrick/1.3.1 (Ruby/2.2.3/2015-08-18)
112
+ Date:
113
+ - Mon, 26 Oct 2015 00:18:45 GMT
114
+ Content-Length:
107
115
  - '51'
108
- connection:
109
- - close
110
- set-cookie:
111
- - _session_id=363eae498e13e14167f4e17b6bc7d532; path=/; HttpOnly
116
+ Connection:
117
+ - Keep-Alive
118
+ Set-Cookie:
119
+ - __profilin=p%3Dt; path=/
120
+ - __profilin=p%3Dt; path=/
121
+ - __profilin=p%3Dt; path=/
122
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWZkN2MwZjgwZThhM2Y2NWU1MTllZmEyNDExYTY3OGYzBjsAVEkiCXVzZXIGOwBGaQY%3D--5185c60ef29f56eb615cc2755030ee803ed2ef3c;
123
+ path=/; HttpOnly
112
124
  body:
113
- encoding: US-ASCII
114
- string: ! '[{"id":1,"name":"Invoice Document","booking_id":1}]'
115
- http_version: '1.1'
116
- recorded_at: Thu, 18 Dec 2014 07:37:48 GMT
125
+ encoding: UTF-8
126
+ string: '[{"id":1,"name":"Invoice Document","booking_id":1}]'
127
+ http_version:
128
+ recorded_at: Mon, 26 Oct 2015 00:18:45 GMT
117
129
  recorded_with: VCR 2.9.3