@extends('backend.header')
@section('index-content')
<?php
function convertToUnicodeNumber($input) {
    
    $standard_numsets = array("0","1","2","3","4","5","6","7","8","9");
    $devanagari_numsets = array("०","१","२","३","४","५","६","७","८","९");
    
    return str_replace($standard_numsets, $devanagari_numsets, $input);
  }
?>
<div class="row">
						
				
				<section role="main" class="content-body">
					<!--<header class="page-header">-->
					<!--	<h2>सर्वेक्षण तपशील</h2>-->
					
					<!--	<div class="right-wrapper pull-right">-->
					<!--		<ol class="breadcrumbs">-->
					<!--			<li>-->
					<!--				<a href="/">-->
					<!--					<i class="fa fa-home"></i>-->
					<!--				</a>-->
					<!--			</li>-->
					<!--			<li><span>टेबल</span></li>-->
					<!--			<li><span>सर्वेक्षण</span></li>-->
					<!--		</ol>-->
					
					<!--		<a class="sidebar-right-toggle" data-open="sidebar-right"><i class="fa fa-chevron-left"></i></a>-->
					<!--	</div>-->
					<!--</header>-->

					<!-- start: page -->
						<section class="panel">
							<header class="panel-heading">
								<div class="panel-actions">
									<a href="#" class="fa fa-caret-down"></a>
									
								</div>
						
								<!--<h2 class="panel-title">सर्वेक्षण तपशील</h2>-->
							</header>
							<form action="/displayallsearch" method="post">
							    @csrf
							<div class="panel-body">
							    <div class="row">
                                    <div class="col-sm-4" style="height:100px;border:1px solid black;border:none;">
                                        <h4>जिल्हा</h4>
                                        <select name="jillase" style="height:40px;width:100%;margin-top:0px;" id="jilla_id">
                                          <option value="">जिल्हा नाव</option>
                                            
                                            @foreach($jilla as $j)
                                            <option value="{{$j->id}}">{{$j->area_name}}</option>
                                            @endforeach
                                          </select>
                                          
                                    </div>
                                    <div class="col-sm-4" style="height:100px;border:1px solid black;border:none;">
                                        <h4>तालुका</h4>
                                        <select name="talukase" style="height:40px;width:100%;margin-top:0px;" id="taluka">
                                          <option value="">तालुका</option>   
                                        </select>
                                    </div>
                                    <div class="col-sm-4" style="height:100px;border:1px solid black;border:none;">
                                        <h4>ग्राम</h4>
                                        <select name="gramse" style="height:40px;width:100%;margin-top:0px;" id="gram_id">
                                         	<option value="">ग्रामपंचायत</option>
                                         	</select>
                                          
                                    </div>
                                    
                                </div>
                                <div class="row">
                                <input type="submit" style="padding:10px;margin-top:20px;width:40%;margin-left:300px;" class="btn btn-success" value="Submit" id="surveyfilter">
                                </div>
                                <br>
                                
							</div>
							</form>
							<form action="/printall" method="post">
							 @csrf
							<div class="panel-body">
							    <?php
							    $jillaname=$jillanamesss[0];
							    $talukaname=$areanamesss[0];
							    $gramname=$gramnamesss[0];
							    ?>
							<input type="hidden" name="jillaname" value="<?php echo $jillaname;?>">
							<input type="hidden" name="talukaname" value="<?php echo $talukaname;?>">
							<input type="hidden" name="gramname" value="<?php echo $gramname;?>">
							<div class="row">
							    <button class="btn btn-primary" style="padding:15px;float:left;width:20%;margin-left:50px;" type="submit" name="printall" value="printall">Print Namuna No ८</button>
							    <!--<button class="btn btn-primary" style="padding:15px;float:left;width:20%;margin-left:250px;" type="submit" name="printnamunanine" value="printnamunanine">Print Namuna No 9</button>-->
                    	    </div>
                    	   
                    	    </div>
                    	    </form>
                    	    <form action="/printformnine" method="post">
							 @csrf
							<div class="panel-body">
							    <?php
							    $jillaname=$jillanamesss[0];
							    $talukaname=$areanamesss[0];
							    $gramname=$gramnamesss[0];
							    ?>
							<input type="hidden" name="jillaname" value="<?php echo $jillaname;?>">
							<input type="hidden" name="talukaname" value="<?php echo $talukaname;?>">
							<input type="hidden" name="gramname" value="<?php echo $gramname;?>">
							<div class="row">
							    <!--<button class="btn btn-primary" style="padding:15px;float:left;width:20%;margin-left:50px;" type="submit" name="printall" value="printall">Print All</button>-->
							    <button class="btn btn-primary" style="padding:15px;float:left;width:20%;margin-left:450px;margin-top:-80px;" type="submit" name="printnamunanine" value="printnamunanine">Print Namuna No ९</button>
                    	    </div>
                    	   
                    	    </div>
                    	    </form>
							<form action="/printformten" method="post">
							 @csrf
							<div class="panel-body">
							    <?php
							    $jillaname=$jillanamesss[0];
							    $talukaname=$areanamesss[0];
							    $gramname=$gramnamesss[0];
							    ?>
							<input type="hidden" name="jillaname" value="<?php echo $jillaname;?>">
							<input type="hidden" name="talukaname" value="<?php echo $talukaname;?>">
							<input type="hidden" name="gramname" value="<?php echo $gramname;?>">
							<div class="row">
							    <!--<button class="btn btn-primary" style="padding:15px;float:left;width:20%;margin-left:50px;" type="submit" name="printall" value="printall">Print All</button>-->
							    <button class="btn btn-primary" style="padding:15px;float:right;width:20%;margin-left:450px;margin-top:-110px;" type="submit" name="printnamunaten" value="printnamunaten">Print Namuna No ९ क</button>
                    	    </div>
                    	   
                    	    </div>
                    	    </form>
            </section>
	    </section>
	    
	</div>

<div class="row" style="margin-top:-50px;">
						
				
				<section role="main" class="content-body">
					<header class="page-header">
						<h2>सर्वेक्षण तपशील</h2>
					
						<div class="right-wrapper pull-right">
							<ol class="breadcrumbs">
								<li>
									<a href="/">
										<i class="fa fa-home"></i>
									</a>
								</li>
								<li><span>टेबल</span></li>
								<li><span>सर्वेक्षण</span></li>
							</ol>
					
							<a class="sidebar-right-toggle" data-open="sidebar-right"><i class="fa fa-chevron-left"></i></a>
						</div>
					</header>

					<!-- start: page -->
						<section class="panel">
							<header class="panel-heading">
								<div class="panel-actions">
									<a href="#" class="fa fa-caret-down"></a>
									<a href="#" class="fa fa-times"></a>
								</div>
						
								<h2 class="panel-title">सर्वेक्षण तपशील</h2>
							</header>
							<div class="panel-body">
								<table class="table table-bordered table-striped mb-none" id="datatable-default">
									<thead>
										<tr>
										    <th></th>
											<th>अ. क्र. </th>
											<th>मिळकत क्र.</th>
											<th>जिल्हा नाव</th>
											<th>तालुका</th>
											<th>ग्रामपंचायत</th>
											
											<th>स्वयंघोषणापत्र  करुन देणार</th>
											<th class="hidden-phone">स्वयंघोषणापत्र  करुन घेणार</th>
											<th class="hidden-phone">भोगवटदाराचे नांव</th>
											<th class="hidden-phone">सिटीसव्‍ह मिळकत धारकाचे नांव </th>
											<th class="hidden-phone">मोबाइल नं</th>
											<th class="hidden-phone">आधार नं</th>
											
											<th class="hidden-phone">Edit</th>
											<th class="hidden-phone">Delete</th>
											
											<th class="hidden-phone">View Details</th>
											<th class="hidden-phone">Add Thakbaki</th>
											<th class="hidden-phone">Print Details ८</th>
											<th class="hidden-phone">Print Details ९</th>
											<th class="hidden-phone">Print Details ९ क</th>
											
										</tr>
									</thead>
									<tbody>
									    <?php
									    $i=0;
									    ?>
										@foreach($survey_i as $sur)
										<?php
										$id=$sur->anu_karmank;
										$idnum=convertToUnicodeNumber($id);
										$taxid=$sur->tax_number;
										$taxnum=convertToUnicodeNumber($taxid);
										$mbl=$sur->mbl;
										$mblnum=convertToUnicodeNumber($mbl);
										$adhar=$sur->adhar;
										$adharnum=convertToUnicodeNumber($adhar);
										?>
										<tr class="gradeX">
										    <td></td>
											<td><?php echo $idnum;?></td>
											<td><?php echo $taxnum;?></td>
											<td><?php echo $jillanamesss[$i];?></td>
											<td><?php echo $areanamesss[$i];?></td>
											<td><?php echo $gramnamesss[$i];?></td>
											<td>{{$sur->name}}</td>
											
											<td class="center hidden-phone">{{$sur->gram_name}}</td>
											
											<td class="center hidden-phone">{{$sur->name2}}</td>
											<td class="center hidden-phone">{{$sur->survey_name}}</td>
											<td class="center hidden-phone"><?php echo $mblnum;?></td>
											<td class="center hidden-phone"><?php echo $adharnum;?></td>
											
											
											<td class="actions"><button class="btn btn-primary"><a href="{{route('survey_info.edit',$sur->id)}}" class="on-default edit-row" style="text-decoration:none;color:white;">Edit</a></button></td>
											<td class="actions">
												<form method="post" action="{{route('survey_info.destroy',$sur->id)}}">
												@csrf
												@method('DELETE')
												<input type="submit" name="delete" value="Delete" class="btn btn-danger">
												</form>
											</td>
											<td class="actions"><button class="btn btn-success"><a href="{{route('survey_info.show',$sur->id)}}" class="on-default edit-row" style="text-decoration:none;color:white;">View Details</a></button></td>
											<td class="actions"><button class="btn btn-success"><a href="/add_thankbaki/{{$sur->id}}" class="on-default edit-row" style="text-decoration:none;color:white;">Add Thakbaki</a></button></td>
											<td><a href="/printdetails/{{$sur->id}}">Print Details ८</a></td>
											<td><a href="/printdetailsnineform/{{$sur->id}}">Print Details ९</a></td>
											<td><a href="/printdetailstenform/{{$sur->id}}">Print Details ९ क</a></td>
											
										</tr>
										<?php
										$i++;
										?>
										@endforeach
									</tbody>
									
									

									
								</table>
							</div>
							
							
							
						</section>
						</section>
						
</div>

			@stop