All files / app/elements/transportation-b-c transportation-b-c.component.html

100% Statements 378/378
100% Branches 2/2
100% Functions 1/1
100% Lines 378/378

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 3791x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1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="">
		<label class="label" (click)="toggleTickets('yes_tickets')">
			Yes, I already have them
			<input type="radio" name="tickets" value="1" [ngModel]="purchased" />
			<span class="checkmark"></span>
		</label>
 
		<label class="label" (click)="toggleTickets('default')"
			>No, I don't have them yet
			<input type="radio" name="tickets" value="0" [ngModel]="purchased" />
			<span class="checkmark"></span>
		</label>
	</div>
</div>
@if (openedSection === 'yes_tickets') {
	<div class="selection">
		<div class="row">
			<div class="col-xs-12 col-md-4">
				<label for="" class="label-sm">DATE OF ARRIVAL</label>
				<div style="position: relative">
					<input
						type="text"
						[class.bordererror]="arrivalerror"
						[minDate]="options.minDate"
						[maxDate]="options.maxDate"
						(bsValueChange)="validateArrival($event)"
						[bsConfig]="{ dateInputFormat: 'YYYY-MM-DD', showWeekNumbers: false }"
						#dpArrivalFirst="bsDatepicker"
						(onShown)="setArrivalDefaultDate(dpArrivalFirst)"
						[(ngModel)]="startDate"
						class="form-control"
						placeholder="Choose a date"
						bsDatepicker
					/>
					@if (mobile) {
						<button
							style="position: absolute; height: 100%; opacity: 0; width: 100%; top: 0"
							(click)="dpArrivalFirst.toggle()"
						>
							Click
						</button>
					}
				</div>
				@if (arrivalerror) {
					<div class="text-danger mt-1">Please select a valid arrival date.</div>
				}
			</div>
			<div class="col-xs-12 col-md-8">
				<label for="" class="label-sm">SELECT ARRIVAL CITY</label>
				<div class="select">
					<select [ngModel]="arrival_yes" (change)="arriveYes($event)">
						@for (city of addedCities; track city; let i = $index) {
							<option value="{{ city.id }}">{{ city?.name }}</option>
						}
						<option value="other">Other</option>
					</select>
				</div>
			</div>
		</div>
		<div class="row m-t-30">
			<div class="col-xs-12 col-md-4">
				<label for="" class="label-sm">DATE OF DEPARTURE</label>
 
				<div style="position: relative">
					<input
						type="text"
						[class.bordererror]="departureerror"
						(bsValueChange)="validateDeparture($event)"
						[(ngModel)]="endDate"
						[bsValue]="startDate ?? undefined"
						[minDate]="options.minDate"
						[maxDate]="options.maxDate"
						[bsConfig]="{ dateInputFormat: 'YYYY-MM-DD', showWeekNumbers: false }"
						#dpDepartFirst="bsDatepicker"
						class="form-control"
						placeholder="Choose a date"
						(onShown)="setArrivalDefaultDate(dpDepartFirst)"
						bsDatepicker
					/>
					@if (mobile) {
						<button
							style="position: absolute; height: 100%; opacity: 0; width: 100%; top: 0"
							(click)="dpDepartFirst.toggle()"
						>
							Click
						</button>
					}
				</div>
				@if (departureerror) {
					<div class="text-danger mt-1">Please select a valid departure date.</div>
				}
			</div>
			<div class="col-xs-12 col-md-8">
				<label for="" class="label-sm">SELECT DEPARTURE CITY</label>
				<div class="select">
					<select [ngModel]="depart_yes" (change)="departYes($event)">
						@for (city of addedCities; track city; let i = $index) {
							<option value="{{ city.id }}">{{ city?.name }}</option>
						}
						<option value="other">Other</option>
					</select>
				</div>
			</div>
			@if (triplengthexceederror) {
				<p class="warning-link mb-0 mt-2">
					<span
						>The maximum allowable length is 35 days. If you would like to create a trip longer than 35 days, please
						submit a trip request</span
					><a
						href="https://share-eu1.hsforms.com/1r9x_xv-ASeWG8jZNnIQLjA2b8sze"
						target="_blank"
						rel="noopener noreferrer"
						class="link"
					>
						here</a
					><span>.</span>
				</p>
			}
		</div>
	</div>
}
@if (openedSection === 'default') {
	<div class="selection">
		<label for="" class="selection__label">Choose arrival city</label>
		<div class="select">
			<select [ngModel]="arrival_no" (change)="arriveNo($event)">
				<option value="tbd">Let us select the best route (Recommended)</option>
				@for (city of addedCities; track city; let i = $index) {
					<option value="{{ city.id }}">{{ city?.name }}</option>
				}
				<option value="other">Other</option>
			</select>
		</div>
		<label for="" class="selection__label">Choose departure city</label>
		<div class="select">
			<select [ngModel]="depart_no" (change)="departNo($event)">
				<option value="tbd">Let us select the best route (Recommended)</option>
				@for (city of addedCities; track city; let i = $index) {
					<option value="{{ city.id }}">{{ city?.name }}</option>
				}
				<option value="other">Other</option>
			</select>
		</div>
	</div>
}
@if (purchased === '0') {
	<div>
		<h6 class="left">Do you have your dates set already?</h6>
		<div class="row">
			<div class="col-xs-12 col-md-4">
				<label class="label" (click)="toogledatesset('1')">
					Yes, my dates are set
					<input type="radio" name="datesset" value="1" [ngModel]="datesset" />
					<span class="checkmark"></span>
				</label>
			</div>
			<div class="col-xs-12 col-md-4">
				<label class="label" (click)="toogledatesset('0')"
					>No, my dates aren’t set yet
					<input type="radio" name="datesset" value="0" [ngModel]="datesset" />
					<span class="checkmark"></span>
				</label>
			</div>
		</div>
		<div class="row">
			<div class="col-xs-12 sub-label p-l-20">Please select the dates within your trip will take place</div>
		</div>
		<div class="row p-t-20">
			<div class="col-xs-12 col-md-4">
				<label for="" class="label-sm">DATE OF ARRIVALS</label>
				<div style="position: relative">
					<input
						type="text"
						[class.bordererror]="arrivalerror"
						[minDate]="options.minDate"
						[maxDate]="options.maxDate"
						[bsConfig]="{ dateInputFormat: 'YYYY-MM-DD', showWeekNumbers: false }"
						#dpArrivalSecond="bsDatepicker"
						(onShown)="setArrivalDefaultDate(dpArrivalSecond)"
						[(ngModel)]="startDate"
						class="form-control"
						(bsValueChange)="validateArrival($event)"
						placeholder="Choose a date"
						bsDatepicker
					/>
					@if (mobile) {
						<button
							style="position: absolute; height: 100%; opacity: 0; width: 100%; top: 0"
							(click)="dpArrivalSecond.toggle()"
						>
							Click
						</button>
					}
				</div>
				@if (arrivalerror) {
					<div class="text-danger mt-1">Please select a valid arrival date.</div>
				}
			</div>
			@if (datesset === '1') {
				<div class="col-xs-12 col-md-4">
					<label for="" class="label-sm">DATE OF DEPARTURE</label>
					<div style="position: relative">
						<input
							type="text"
							[class.bordererror]="departureerror"
							(bsValueChange)="validateDeparture($event)"
							[(ngModel)]="endDate"
							[bsValue]="startDate ?? undefined"
							[minDate]="options.minDate"
							[maxDate]="options.maxDate"
							[bsConfig]="{ dateInputFormat: 'YYYY-MM-DD', showWeekNumbers: false }"
							#dpDepartSecond="bsDatepicker"
							class="form-control"
							(onShown)="setArrivalDefaultDate(dpDepartSecond)"
							placeholder="Choose a date"
							bsDatepicker
						/>
						@if (mobile) {
							<button
								style="position: absolute; height: 100%; opacity: 0; width: 100%; top: 0"
								(click)="dpDepartSecond.toggle()"
							>
								Click
							</button>
						}
					</div>
					@if (departureerror) {
						<div class="text-danger mt-1">Please select a valid departure date.</div>
					}
				</div>
				@if (triplengthexceederror) {
					<p class="warning-link mb-0 mt-2">
						<span
							>The maximum allowable length is 35 days. If you would like to create a trip longer than 35 days, please
							submit a trip request</span
						><a
							href="https://share-eu1.hsforms.com/1r9x_xv-ASeWG8jZNnIQLjA2b8sze"
							target="_blank"
							rel="noopener noreferrer"
							class="link"
						>
							here</a
						><span>.</span>
					</p>
				}
			}
			@if (datesset === '0') {
				<div class="col-xs-12 col-md-3">
					<label for="" class="label-sm">TRIP LENGTH</label>
					<ng-select
						[class.bordererror]="triplengtherror"
						class="shadow-box calendar-icon"
						id="select2"
						[(ngModel)]="tripLength"
						bindValue="value"
						type="number"
						bindLabel="text"
						[items]="durationOptions"
						placeholder="0 days"
						typeToSearchText="false"
					>
						<ng-template let-item="item" let-index="index">
							<span>{{ item.text }}</span>
						</ng-template>
					</ng-select>
				</div>
			}
		</div>
	</div>
}
<div class="included m-b-180 m-t-100">
	<h6 class="left m-t-5">Included in your itinerary</h6>
	<div class="row">
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/hazi.png" width="22px" height="auto" alt="hazi" />
			</div>
			<p class="center">Fast & convenient routes</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/tips.png" width="22px" height="auto" alt="tips" />
			</div>
			<p class="center">Intercity transport bookings & tips</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/door.png" width="22px" height="auto" alt="door" />
			</div>
			<p class="center">Door to door & optional airport shuttle</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/map.png" width="22px" height="auto" alt="map" />
			</div>
			<p class="center">Local transport maps & tips</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/city.png" width="22px" height="auto" alt="city" />
			</div>
			<p class="center">Central Location</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/star.png" width="22px" height="auto" alt="star" />
			</div>
			<p class="center">Highly rated hotels</p>
		</div>
		<div class="col-4 col-sm-3 p-2">
			<div class="w-100 text-center">
				<img loading="lazy" src="/assets/images/stars.png" width="22px" height="auto" alt="stars" />
			</div>
			<p class="center">100% clean & comfortable rooms</p>
		</div>
	</div>
</div>
 
@if (max_cities) {
	<div class="popup-back">
		<div [ngClass]="{ 'popup popup-max': true, 'is-active': max_cities }">
			<div class="popup-body">
				<a class="popup-close" (click)="closePopup()">×</a>
				<h3 class="popup-title center">Remove cities to shorten the trip</h3>
				<p class="popup-notice center m-t-30">You need a min. of {{ recommended }} days to visit these cities</p>
				@if (arriveCity() || departCity()) {
					<div class="row m-t-40">
						<div class="col-12 city-to-remove m-b-10">
							<div class="row">
								<div class="col-6 city-title">
									{{ arriveCity()?.name }}
								</div>
								<div class="col-6 airport-city text-end">ARRIVAL</div>
							</div>
						</div>
						<div class="col-12 city-to-remove m-b-10">
							<div class="row">
								<div class="col-6 city-title">
									{{ departCity()?.name }}
								</div>
								<div class="col-6 airport-city text-end">DEPARTURE</div>
							</div>
						</div>
					</div>
				}
				<div class="row m-t-40">
					@for (city of citiesForRemoval(); track city) {
						<div class="col-12 city-to-remove m-b-10">
							<div class="row">
								<div class="col-6 city-title">
									{{ city?.name }}
								</div>
								<div class="col-6">
									@if (citiesToRemove.indexOf(city.id) === -1) {
										<button class="btn-remove" (click)="toogle(city.id)">Remove</button>
									}
									@if (citiesToRemove.indexOf(city.id) !== -1) {
										<button class="btn-keep" (click)="toogle(city.id)">KEEP</button>
									}
								</div>
							</div>
						</div>
					}
				</div>
				<div class="row">
					<div class="col-12 p-l-0 p-r-0">
						<button type="button" (click)="confirmremoval()" class="btn btn-green btn-wide uppercase">
							CONFIRM SELECTION
						</button>
					</div>
				</div>
			</div>
		</div>
	</div>
}