 <div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <div class="content-header">
      <div class="container-fluid">
        <div class="row mb-2">
          <div class="col-sm-6">
            <h1 class="m-0 text-dark"><?php echo $title ?></h1>
          </div><!-- /.col -->
          <div class="col-sm-6">
            <ol class="breadcrumb float-sm-right">
              <li class="breadcrumb-item"><a href="<?php echo base_url() ?>admin/admin/dashboard">Dashboard</a></li>
              <li class="breadcrumb-item"><a href="#"><?php echo ucwords(str_replace("_", " ", $this->uri->segment(2))); ?></a></li>
              <li class="breadcrumb-item active"><?php echo ucwords(str_replace("_", " ", $title)); ?></li>

            </ol>
          </div><!-- /.col -->
        </div><!-- /.row -->
      </div><!-- /.container-fluid -->
    </div>
    <!-- /.content-header -->
  <?php
    $errors = $this->session->userdata('errors');
    if (isset($errors)) {
        ?>
        <script>
            swal ( "Oops" ,  "<?php echo $errors ?>" ,  "error" )
        </script>
        <?php echo $errors ?>
        <?php
        $this->session->unset_userdata('errors');
    }
    $error = $this->session->userdata('error');
    if (isset($error)) {
        ?>
         <script>
            swal ( "Oops" ,  "<?php echo $error ?>" ,  "error" )
        </script>
        <?php
        $this->session->unset_userdata('error');
    }
    $success = $this->session->userdata('success');
    if (isset($success)) {
        ?>
         <script>
            swal({
          title: "Done!",
          text: "<?php echo $success ?>",
          icon: "success",
        });
        </script>
        <?php
        $this->session->unset_userdata('success');
    }
    ?>
     <section class="content">
      <div class="container-fluid">

        <!-- Info boxes -->
        <div class="row">
          <div class="col-sm-12">
            <div class="card card-default">
              <div class="card-header">
                <h3 class="card-title">Update Batches Shedule</h3>
              </div>
              <!-- /.card-header -->
              <?php echo form_open('admin/branch/update_batches_shedule'); 
              $testi = $this->branch->get_alltesti();?>
              <div class="card-body">
                <div class="row">

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Heading<span class="required">*</span></label>
                       <div class="col-sm-12">
                          <input class="form-control"  name="schedule_heading" placeholder="Enter Heading" required="required" type="text" value="<?php echo $testi->schedule_heading; ?>">
                       </div>
                    </div>
                  </div>
                  
                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Description <span class="required">*</span></label>
                       <div class="col-sm-12">
                          <textarea class="form-control"  name="schedule_des" placeholder="Enter Description" required="required" type="text"><?php echo $testi->schedule_des; ?></textarea>
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <button name="submit" style="float: right" type="submit" class="btn btn-success">Update</button>
                    </div>
                  </div>

                   <?php echo form_close() ?>
                   

                  <!-- /.col -->
                </div>
                <!-- /.row -->
              </div>
              <!-- /.card-body -->
            </div>
          </div>
            <!-- /.row -->
      </div><!--/. container-fluid -->
    </section>
    <!-- Main content -->
    <section class="content">
      <div class="container-fluid">

        <!-- Info boxes -->
        <div class="row">
          <div class="col-sm-12">
            <div class="card card-default">
              <div class="card-header">
                <h3 class="card-title">Add <?php echo $title ?></h3>

                <div class="card-tools">
                  <button type="button" class="btn btn-tool" data-card-widget="collapse"><i class="fas fa-minus"></i></button>
                </div>
              </div>
              <!-- /.card-header -->
              <?php echo form_open_multipart('admin/branch/add_schedule'); ?>
              <div class="card-body">
                <div class="row">

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Select Branch</label>
                       <div class="col-sm-12">
                          <select id="showing" class="form-control"  name="branch" required="">
                            <option value="">Select Cateory</option>
                              <?php foreach ($all_branch as $key => $branch):?>
                                <option value="<?php echo $branch->id ?>"><?php echo $branch->name ?></option>
                              <?php endforeach; ?>
                          </select>
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Date <span class="required">*</span></label>
                       <div class="col-sm-12">
                          <input class="form-control"  name="date" placeholder="Enter Category Name" required="required" type="date">
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Days <span class="required">*</span></label>
                       <div class="col-sm-12">
                          <input class="form-control"  name="days" placeholder="Enter Days Ex - Mon to Fri" required="required" type="text">
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Is Weekdays Batch <span class="required">*</span></label>
                       <div class="col-sm-12">
                          <select class="form-control"  name="is_weekdays" placeholder="Enter Days Ex - Mon to Fri" required="required" type="text">
                           <option value="1">Yes</option>
                           <option value="0">No</option>
                          </select>
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Time <span class="required">*</span></label>
                       <div class="col-sm-12">
                          <input class="form-control"  name="time" placeholder="Enter 8:00 AM " required="required" type="text">
                       </div>
                    </div>
                  </div>

                  <div class="col-md-12">
                    <div class="form-group">
                       <label for="inputEmail" class="col-sm-12 col-form-label">Time Sub Heading<span class="required">*</span></label>
                       <div class="col-sm-12">
                          <input class="form-control"  name="time_sub" placeholder="Ex. (Class 1Hr - 3Hr) / Per Session" required="required" type="text">
                       </div>
                    </div>
                  </div>


                  
                  <div class="col-md-12">
                    <div class="form-group">
                       <button name="submit" style="float: right" type="submit" class="btn btn-success">Add</button>
                    </div>
                  </div>

                   <?php echo form_close() ?>
                   

                  <!-- /.col -->
                </div>
                <!-- /.row -->
              </div>
              <!-- /.card-body -->
            </div>
          </div>
        </div>
            <!-- /.row -->
      </div><!--/. container-fluid -->
    </section>
    <!-- /.content -->
  </div>
  