<div class="row">
                <div class="col-md-12" id = "formulir">

<script type="text/javascript">
$(document).ready(function(){


  $("#submission").click(function(e){
       e.preventDefault();
       var rekening = $('#rekeningselector').val();
       var useable = $('#useableselector option:selected').val();
       var brandgroup = $('#brandgroupselector option:selected').val();
       var ewalletonly = $('#ewalletonlyselector option:selected').val();
         $.ajax({
           type: "POST",
           url: "<?php echo base_url();?>c_modules/updatestatusrekening", 
           data: {
            rekening:rekening,
            useable:useable,
            brandgroup:brandgroup,
            ewalletonly:ewalletonly
           },
           dataType: "text",  
           success: function(data){
                $("#datagrid").html(data);
              
                }
            });
      })
})
</script>

<link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
<link rel="stylesheet" href="/resources/demos/style.css">
<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
<!-- <script>
  $( function() {
    $( "#mindateselector" ).datepicker();
  } );

</script> -->

<h1>Update Status Rekening</h1>

<form  class="form-horizontal" enctype="multipart/form-data"  method="post">
<div class="row">
  <div class="col-md-3">
    <div class="form-group">
      <label for="inputUsername">Nomor Rekening</label>
      <input type="number" class="form-control mainform" id="rekeningselector" name="rekeningselector">
    </div>
  </div>
  
  
  <div class="col-md-3">
    <div class="form-group">
      <label>Useable</label>
      <select id = "useableselector" name="useableselector" class="form-control mainform" style="width: 100%;">
        <option selected = "selected" value = "1">1</option>
        <option value = "0">0</option>
      </select>
    </div>
  </div>
  
  <div class="col-md-3">
    <div class="form-group">
      <label>Ewallet Only</label>
      <select id = "ewalletonlyselector" name="ewalletonlyselector" class="form-control mainform" style="width: 100%;">
        <option selected = "selected" value = "1">1</option>
        <option value = "0">0</option>
      </select>
    </div>
  </div>
  
  
  
 <?php if($this->session->userdata('privilege') == 'SuperAdmin') {?>
    <div class = "row">
   
            <div class="form-group">
              <label>Brand Group</label>
              <select id = "brandgroupselector" name="brandgroupselector" class="form-control mainform" style="width: 100%;">
                <?php 
                    foreach($brandgrouplist as $row)
                    { 
                 ?>
                    <option  value="<?php echo $row->brandgroup;?>"><?php echo $row->brandgroup;?></option>
                <?php }?>
              </select>
            </div>
    </div>
<?php }?>
  
 
</div>

<div id = "errmsg" class = "mt-4">
                
</div>

<div class="card-footer">
  <button id = "submission" type="submit" class="btn btn-primary">Submit</button>
</div>
</form>
</div>
</div>

<div class="row">
    <div class="col-md-12" id = "datagrid">
    </div>
</div>