<section class="content-header">
	<div class="container-fluid">
		<div class="row mb-2">
			<div class="col-sm-6">
				<h1>LOKASI USAHA <button data-toggle="modal" data-target="#addlogcab" class="btn btn-sm btn-primary">
						<i class="fas fa-plus"></i>
						</button</h1> </div> </div> </div> </section> <section class="content">
						<div class="row">
							<?php foreach ($lokcabID->result() as $am => $data) : ?>
								<div class="col-12 col-sm-6  align-items-stretch">
									<div class="card bg-light">
										<div class="card-header text-muted border-bottom-0">
											Detail Data Bengkel :
										</div>
										<div class="card-body pt-0">
											<div class="row">
												<div class="col-7">
													<h2 class="lead"><b><?= $data->cabang ?></b></h2>
													<p class="text-muted text-sm"><b>Support : </b> Service Ringgan / Service Sedang / Service Berat </p>
													<ul class="ml-4 mb-0 fa-ul text-muted">
														<li class="small"><span class="fa-li"></span> <b>Address :</b> <?= $data->alamat ?></li>
														<li class="small"><span class="fa-li"></span> <b>Phone #:</b> <?= $data->no_hp ?></li>
														<li class="small"><span class="fa-li"></span> <b>Open #:</b> <?= $data->inopen ?></li>

													</ul>
												</div>
												<div class="col-5 text-center">
													<img src="<?= base_url() ?>/upload/foto/cab/<?= $data->foto ?>" alt="" class="img-fluid">
												</div>
											</div>
										</div>
										<div class="card-footer">
											<div class="text-right">
												<a href="<?= $data->url ?>" type="button" target="blank" class="btn btn-secondary btn-sm text-center"><i class="fas fa-map-marked-alt"></i></a>

												<a href="https://wa.me/<?= $data->no_hp ?>?text=Hai Apa Kabar, Ada yg bisa di bantu ?" target="black" class="btn btn-sm bg-success">
													<i class="fab fa-whatsapp"></i>
												</a>

											</div>
										</div>
									</div>
								</div>
							<?php endforeach ?>
						</div>
</section>

<!-- Start modal add cabang -->
<form action="<?= base_url('logcab/addcab'); ?>" enctype="multipart/form-data" method="post">
	<div class="modal fade bd-example-modal-lg" id="addlogcab" tabindex="-1" aria-labelledby="exampleModalLabel" aria-hidden="true">
		<div class="modal-dialog modal-lg modal-dialog-centered">
			<div class="modal-content">
				<div class="modal-body">
					<div class="input-group mt-2 col-sm-12 ">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-warehouse"></i>
							</span>
						</div>
						<input autocomplete="off" class="form-control text-uppercase " name="cabang" type="text" placeholder="Nama Usaha">
					</div>

					<div class="input-group mt-2 col-sm-12 ">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-home"></i>
							</span>
						</div>
						<input autocomplete="off" class="form-control text-uppercase" name="alamat" type="text" placeholder="Alamat Usaha">
					</div>

					<div class="input-group mt-2 col-sm-12 ">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-phone"></i>
							</span>
						</div>
						<input autocomplete="off" class="form-control text-uppercase" name="no_hp" type="text" placeholder="No. Handphone">
					</div>

					<div class="input-group mt-2 col-sm-12 ">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-map-marker-alt"></i> &nbsp;
							</span>
						</div>
						<input autocomplete="off" class="form-control text-uppercase" name="url" type="text" placeholder="Google Maps">
					</div>

					<div class="input-group mt-2 col-sm-12 ">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-calendar-alt"></i> &nbsp;
							</span>
						</div>
						<input autocomplete="off" required id="tanggal" class="form-control " name="inopen" placeholder="Tanggal Dibuka">
					</div>

					<div class="input-group mt-2 col-sm-12">
						<div class="input-group-prepend">
							<span class="input-group-text">
								<i class="fas fa-images"></i>
							</span>
						</div>
						<div class="custom-file ">
							<input type="file" name="foto" class="custom-file-input " id="validatedInputGroupCustomFile">
							<label class="custom-file-label " for="validatedInputGroupCustomFile">Pilih Foto Bengkel</label>
						</div>
					</div>

					<button type="submit" class="btn btn-secondary w-100 mt-2">Simpan Data Usaha</button>
				</div>
			</div>
		</div>
	</div>

</form>
<!-- ending modal add cabang -->