
<?php $__env->startSection('content'); ?> 

<script>
    function GetMessageCount()
    {
      var Message=$("#Message").val();
      if(document.getElementById("Marathi").checked)
      {
        var MessageLength=(Message.length)*4;
        var NoOfMessages=Math.ceil(MessageLength / 160);
        document.getElementById("MessageCount").innerHTML="Message Characters "+MessageLength+ " : Message Count : "+NoOfMessages;
      }
      else if(document.getElementById("English").checked)
      {
        var MessageLength=Message.length;
        var NoOfMessages=Math.ceil(MessageLength / 160);
        document.getElementById("MessageCount").innerHTML="Message Characters "+MessageLength+ " : Message Count : "+NoOfMessages;
      }
    }

  function GetMobileNumbersCount()
  {
    var VotingAnalysis=$("#VotingAnalysis").val();
    var VotingStatus=$("#VotingStatus").val();

    if(VotingAnalysis!="" || VotingStatus!="")
    {
      $("#loading").show();
      $.ajax({
          type: "GET",
          url: "GetVotersMobileCountForVotingSlip",
          data:"VotingAnalysis="+VotingAnalysis+"&VotingStatus="+VotingStatus,
          dataType: "json",
          success: function(result){
             $("#loading").hide();
             $("#Count").val(result.VotersCount);
             $("#ValidCount").val(result.ValidMobileNumbersCount);
          }
      });
    }
    else
    {
      alert(" मतदार अंदाज किंवा मतदान स्टेट्स निवडा ");  
    }
  }
</script>
  <div class="qv rc sm sp" style="margin-top:3%;">
    <div class="qw">
      <?php if(Session::has('Name')): ?>   
        <span style="margin-left:70px;"> <strong> <?php echo e($pagetitle); ?> </strong> </span>
        <span style="margin-top:-7px;margin-left:55%;">Welcome, <?php echo e(Session::get('Name')); ?>

        <a href='dashboard' class='cg ts fx green' style="margin-left:80px;"> Go To Dashboard </a>
      <?php endif; ?>
    </div>
  </div>
  <div class="row">
      <div class="col-lg-12">
        <div class="col-lg-4"> </div>
        <div class="col-lg-4">
          <?php if(Session::has('success')): ?>
            <div class="alert pv alert-dismissible alert-success" role="alert">
               <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
               <font style="color:#f5f5f5"> <?php echo e(Session::get('success')); ?>  </font>
            </div>
          <?php elseif(Session::has('error')): ?>
            <div class="alert pv alert-dismissible alert-warning" role="alert">
               <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
               <font style="color:#f5f5f5"> <?php echo e(Session::get('error')); ?>  </font>
            </div>
          <?php endif; ?>
         </div>
        <div class="col-lg-4"> </div>                
      </div>
  </div>
  <form action="SendVoterSlip" role="form" id="SMSForm" name="SMSForm">
    <div class="row"  style="margin-left:12px;">
      <div class="col-lg-12">
        <div class="col-lg-5"></div>
        <div class="col-lg-2"> <img src="<?php echo asset('theme/assets/images/loader7.gif'); ?>" id="loading" name="loading">  </div>
        <div class="col-lg-5"></div>                
      </div>
    </div>
   	<div class="row">
   		<div class="col-lg-6 col-md-offset-3">
		  <div class="by amt" style="width:200%;">
		    <div class="gc">
		      <div class="gz">
		        <div class="ca qo anx ">
			        <div class="qf b aml">
                <div class="row" style="margin-top:15px;">
                  <div class="col-md-12">
                    <!--  <div class="col-md-4">
                         <select id="VotingAnalysis" name="VotingAnalysis" class="form-control">
                          <option value=""> मतदार अंदाज निवडा </option>
                          <option value="आपला" style="color:#00b200;font-weight:900;"> आपला </option>
                          <option value="विरोधी" style="color:#de4150;font-weight:900;"> विरोधी </option>
                          <option value="संदिग्ध" style="color:#fca530;font-weight:900;"> संदिग्ध </option>
                          <option value="इतर" style="color:#7c858b;font-weight:900;"> इतर </option>
                        </select>
                      </div>
                      <div class="col-md-4">
                        <select id="VotingStatus" name="VotingStatus" class="form-control">
                          <option value=""> मतदान केले ? </option>
                          <option value="1"> होय </option>
                          <option value="0"> नाही </option> 
                        </select>
                      </div> -->

                        <div class="col-md-4">
                            <input type="button" value="मतदार दाखवा" onclick="GetMobileNumbersCount();" class="cg fp">  </input>
                        </div>
                    </div>

                    <div class="col-md-12" style="margin-top:15px;">
                      <div class="col-md-2">
                         <strong> मतदार संख्या </strong>
                      </div>
                      <div class="col-md-3">
                        <input type="text" id="Count" name="Count" class="form-control" placeholder="मतदार संख्या" readonly></input>
                      </div>
                      <div class="col-md-3">
                         <strong> वैध मोबाईल नंबर्स</strong>
                      </div>
                      <div class="col-md-3">
                        <input type="text" id="ValidCount" name="ValidCount" class="form-control" placeholder=" वैध मोबाईल नंबर्स " readonly></input>
                      </div>                      
                    </div>
                    <div class="col-md-12" style="margin-top:15px;">
                      <div class="col-lg-4">
                        Route Type
                      </div>
                      <div class="col-md-8">
                         <div class="bv" data-example-id="" >
                            <div class="ew ug ul">
                                <label>
                                    <input type="radio" id="TranscationalRoute" name="RouteType" value="T" checked>
                                    <span class="uh"></span>
                                    Transcational
                                </label>
                            </div>
                            <div class="ew ug ul">
                                <label>
                                    <input type="radio" id="PromotionalRoute" name="RouteType" value="P" >
                                    <span class="uh"></span>
                                    Promotional
                                </label>
                            </div>
                          </div>
                      </div>
                    </div>
    			        	<div class="col-md-12" style="margin-top:15px;">
                      <div class="col-lg-4">
                        Sender ID
                      </div>
                      <div class="col-md-8">
                        <select id="SenderID" name="SenderID" class="form-control">
                          <option value=""> Sender ID </option>
                          <?php foreach($SenderIDs as $senders): ?>
                            <option value="<?php echo e($senders->SenderID); ?>"> <?php echo e($senders->SenderID); ?> </option>
                          <?php endforeach; ?>
                        </select>
                      </div>
                    </div>
                </div>
                <div class="row" style="margin-top:15px;">
                  <div class="col-md-12">
                    <div class="col-md-4">
                    </div>
                    <div class="col-md-8">
                      <input type="submit" value=" Send Slip " class="cg fp"> </input>
                    </div>
                  </div>
                </div>
			        </div>
		        </div>
		      </div>
		    </div>
		  </div>
   		</div>
   	</div>
   </form>

  <script>
   $(document).ready(function() {
      $("#loading").hide();

      $('#SMSForm')
        .formValidation({
            framework: 'bootstrap',
            icon: {
                valid: 'glyphicon glyphicon-ok',
                invalid: 'glyphicon glyphicon-remove',
                validating: 'glyphicon glyphicon-refresh'
            },
            // This option will not ignore invisible fields which belong to inactive panels
            excluded: ':disabled',
            fields: {
                SenderID: {
                    validators: {
                        notEmpty: {
                            message: 'The Sender ID is required'
                        }
                    }
                }
              }
        });

    function validateTab(index) {
       var fv   = $('#SMSForm').data('formValidation'), // FormValidation instance
        // The current tab
        $tab = $('#SMSForm');

        // Validate the container
        fv.validateContainer($tab);

        var isValidStep = fv.isValidContainer($tab);
        if (isValidStep === false || isValidStep === null) {
            // Do not jump to the target tab
            return false;
        }
        return true;
    }   
  });
</script>   
<style>
.pagination {
  display: inline-block;
  padding-left: 0;
  margin-top: 1rem;
  margin-bottom: 1rem;
  border-radius: .25rem;
}

.page-item {
  display: inline;
}

.page-item:first-child .page-link {
  margin-left: 0;
  border-top-left-radius: .25rem;
  border-bottom-left-radius: .25rem;
}

.page-item:last-child .page-link {
  border-top-right-radius: .25rem;
  border-bottom-right-radius: .25rem;
}

.page-item.active .page-link, .page-item.active .page-link:focus, .page-item.active .page-link:hover {
  z-index: 2;
  color: #fff;
  cursor: default;
  background-color: #0275d8;
  border-color: #0275d8;
}

.page-item.disabled .page-link, .page-item.disabled .page-link:focus, .page-item.disabled .page-link:hover {
  color: #818a91;
  cursor: not-allowed;
  background-color: #fff;
  border-color: #ddd;
}

.page-link {
  position: relative;
  float: left;
  padding: .5rem .75rem;
  margin-left: -1px;
  line-height: 1.5;
  color: #0275d8;
  text-decoration: none;
  background-color: #fff;
  border: 1px solid #ddd;
}

.page-link:focus, .page-link:hover {
  color: #014c8c;
  background-color: #eceeef;
  border-color: #ddd;
}

.pagination-lg .page-link {
  padding: .75rem 1.5rem;
  font-size: 1.25rem;
  line-height: 1.333333;
}

.pagination-lg .page-item:first-child .page-link {
  border-top-left-radius: .3rem;
  border-bottom-left-radius: .3rem;
}

.pagination-lg .page-item:last-child .page-link {
  border-top-right-radius: .3rem;
  border-bottom-right-radius: .3rem;
}

.pagination-sm .page-link {
  padding: .275rem .75rem;
  font-size: .875rem;
  line-height: 1.5;
}

.pagination-sm .page-item:first-child .page-link {
  border-top-left-radius: .2rem;
  border-bottom-left-radius: .2rem;
}

.pagination-sm .page-item:last-child .page-link {
  border-top-right-radius: .2rem;
  border-bottom-right-radius: .2rem;
}

 .pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}
 .pagination>li{display:inline}
 .pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;margin-left:-1px;line-height:1.42857143;color:#337ab7;text-decoration:none;background-color:#fff;border:1px solid #ddd}
 .pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-top-left-radius:4px;border-bottom-left-radius:4px}
 .pagination>li:last-child>a,.pagination>li:last-child>span{border-top-right-radius:4px;border-bottom-right-radius:4px}
 .pagination>li>a:focus,.pagination>li>a:hover,.pagination>li>span:focus,.pagination>li>span:hover{color:#23527c;background-color:#eee;border-color:#ddd}
 .pagination>.active>a,.pagination>.active>a:focus,.pagination>.active>a:hover,.pagination>.active>span,.pagination>.active>span:focus,.pagination>.active>span:hover{z-index:2;color:#fff;cursor:default;background-color:#337ab7;border-color:#337ab7}.pagination>.disabled>a,.pagination>.disabled>a:focus,.pagination>.disabled>a:hover,.pagination>.disabled>span,.pagination>.disabled>span:focus,.pagination>.disabled>span:hover{color:#777;cursor:not-allowed;background-color:#fff;border-color:#ddd}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-top-left-radius:6px;border-bottom-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-top-right-radius:6px;border-bottom-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-top-left-radius:3px;border-bottom-left-radius:3px}
 .pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-top-right-radius:3px;border-bottom-right-radius:3px}

</style>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('admin.layouts.votermainview', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>