<div class="row">
	<div class="col-md-12">
		<div class="box box-primary">
			<div class="box-header with-border">
				<h3 class="box-title"> <?= !empty(lang('order_list'))?lang('order_list'):"Order List";?> <a href="<?= base_url('admin/profile/services'); ?>" class="btn btn-primary ml-10"> <i class="fa fa-arrow-left"></i>&nbsp;<?= lang('services');?></a></h3>
				<div class="box-tools pull-right">
					<button type="button" class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button>
					<button type="button" class="btn btn-box-tool" data-widget="remove"><i class="fa fa-remove"></i></button>
				</div>
			</div>
			<!-- /.box-header -->
			<div class="box-body">

				<div class="table-responsive">
					<table class="table table-bordered table-striped" id="example1">
						<thead>
							<tr>
								<th><?= lang('sl'); ?></th>
								<th><?= lang('service'); ?></th>
								<th><?= lang('customer_name'); ?></th>
								<th><?= lang('payment_method'); ?></th>
								<th><?= lang('price'); ?></th>
								<th><?= lang('txn_id'); ?></th>
								<th><?= lang('date'); ?></th>
								<th><?= lang('payment_status'); ?></th>
								<th><?= lang('status'); ?></th>
								<th><?= lang('action'); ?></th>
							</tr>
						</thead>
						<tbody>
							<?php foreach ($order_list as $key => $row): ?>
								<tr>
									<td><?= $key+1;?></td>
									<td><?= $row['title'];?></td>
									<td>
										<div class="customerDetailsList">
											<p><b><?= $row['name'];?></b></p>
											<p><?=  my_currency($row['country_id'],'dial_code');?> <?= $row['phone'];?></p>
											<p><?=  my_currency($row['country_id'],'name');?></p>
										</div>
											
									</td>
									<td><?= $row['price'];?> <?= $row['currency_code'];?></td>
									<td><?= $row['payment_by'];?></td>
									<td><?= $row['txn_id'];?></td>
									<td><?= full_time($row['created_at']);?></td>
									<td>
										<?php if($row['payment_by']=="offline"): ?>
											<label class="label label-warning"><?= $row['payment_status'];?></label>
										<?php else: ?>
											<label class="label label-success"><?= $row['payment_status'];?></label>
										<?php endif;?>
									</td>
									<td>
										<?php if($row['status']==0): ?>
											<label class="label label-warning"><?= lang('pending'); ?></label>
										<?php elseif($row['status']==1): ?>
											<label class="label label-info"><?= lang('approved'); ?></label>
										<?php elseif($row['status']==2): ?>
											<label class="label label-danger"><?= lang('rejected'); ?></label>
										<?php elseif($row['status']==3): ?>
											<label class="label label-success"><?= lang('completed'); ?></label>
										<?php endif;?>

									</td>

									<td>
										<div class="input-group-btn customBtn">
											<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
											<?php if($row['status']==0): ?>
												<?= lang('pending'); ?>
											<?php elseif($row['status']==1): ?>
												<?= lang('approved'); ?>
											<?php elseif($row['status']==2): ?>
												<?= lang('rejected'); ?>
											<?php elseif($row['status']==3): ?>
												<?= lang('completed'); ?>
											<?php endif;?>
											<span class="fa fa-caret-down"></span></button>
											<ul class="dropdown-menu">
												<li><a href="<?= base_url('service/change_status/1/'.$row['id']) ;?>"><?= lang('approved'); ?></a></li>
												<li><a href="<?= base_url('service/change_status/2/'.$row['id']) ;?>"><?= lang('rejected'); ?></a></li>
												<li><a href="<?= base_url('service/change_status/3/'.$row['id']) ;?>"><?= lang('completed'); ?></a></li>
											</ul>
										</div>
									</td>
								</tr>
							<?php endforeach ?>
						</tbody>
					</table>
				</div>

			</div><!-- /.box-body -->
		</div>
	</div>
</div>