McGansWebsite/admin/application/views/subject/view_subject.php
dotwingssoftware f2a40c268b 20230207
1. Have to test and deploy in server.  2. add faculty detail into employee table and student detail  into employee table, 3. Change Teaching Assistant into multiple select 4. User Profile
2023-02-07 18:41:26 +05:30

157 lines
4.9 KiB
PHP

<!-- data tables -->
<link href="<?=base_url();?>/assets/datatables/plugins/bootstrap/dataTables.bootstrap4.min.css" rel="stylesheet" type="text/css" />
<?php $this->load->view('includes/header');?>
<?php
$CI=& get_instance();
$CI->load->model('Subject_model');?>
<!-- start page container -->
<div class="page-container">
<!-- start sidebar menu -->
<?php $this->load->view('includes/sidebar');?>
<!-- start page content -->
<div class="page-content-wrapper">
<div class="page-content">
<div class="page-bar col-md-9" style="margin:0px auto;padding:0">
<div class="page-title-breadcrumb">
<div class=" pull-left">
<div class="page-title">Subject View</div>
</div>
<ol class="breadcrumb page-breadcrumb pull-right">
<li><i class="fa fa-home"></i>&nbsp;<a class="parent-item" href="<?=base_url();?>/dashboard">Home</a>&nbsp;<i class="fa fa-angle-right"></i>
</li>
<li>&nbsp;<a class="parent-item" href="<?=base_url();?>/subject">Subject</a>&nbsp;<i class="fa fa-angle-right"></i>
</li>
<li class="active">View Subject</li>
</ol>
</div>
</div>
<?php $this->load->view('includes/msg');?>
<div class="row">
<div class="col-md-9" style="margin:0px auto;">
<?php
if(isset($viewSubject)&& $viewSubject->num_rows()>0)
{
$view=$viewSubject->row();
$id=$view->id;
$degName=$view->degName;
$subtitle=$view->subtitle;
$facultyId=$view->facultyId;
$facName=$view->facName;
$teachingAssistant=$view->teachingAssistant;
$name=$view->name;
$code=$view->code;
$image=$view->image;
$description=$view->description;
$facIdd = explode(",", $facultyId);
$taId = explode(",", $teachingAssistant);
//print_r ($facIdd);
}
?>
<!-- BEGIN PROFILE SIDEBAR -->
<div class="card card-topline-aqua">
<div class="card-body no-padding height-9">
<div class="row">
<div class="profile-userpic">
<img src="<?=base_url();?>uploads/subject/<?=$image;?>" class="img-responsive" alt=""> </div>
</div>
<div class="profile-usertitle">
<div class="profile-usertitle-name"><?=$name;?></div>
</div>
<div class="profile-usertitle">
<div class="profile-usertitle-name"><?=$subtitle;?></div>
</div>
<hr>
<div class="row">
<div class="col-md-4 col-xs-6 b-r"> <strong>Code</strong>
<br>
<p class="text-muted"><?=$code;?></p>
</div>
<div class="col-md-4 col-xs-6 b-r"> <strong>Degree</strong>
<br>
<p class="text-muted"><?=$degName;?></p>
</div>
<div class="col-md-4 col-xs-6 b-r"> <strong>Teaching Assistant</strong>
<br>
<p class="text-muted">
<?php
$i=0;
foreach($taId as $faculty)
{
$getFac=$CI->Subject_model->get_faculty($faculty);
if($getFac->num_rows()>0)
{
$list=$getFac->row();
$facName=$list->name;
}
?>
<?=$facName.','?>
<?php
}
$i++;
?></p>
</div>
<div class="col-md-4 col-xs-6 b-r"> <strong>Faculty</strong>
<br>
<p class="text-muted">
<?php
$i=0;
foreach($facIdd as $faculty)
{
$getFac=$CI->Subject_model->get_faculty($faculty);
if($getFac->num_rows()>0)
{
$list=$getFac->row();
$facName=$list->name;
}
?>
<?=$facName.','?>
<?php
}
$i++;
?>
</p>
</div>
</div>
<hr>
<div class="row">
<div class="col-md-12 col-xs-6" style="text-align:justify;"> <strong>Description</strong>
<br>
<br>
<p class="text-muted"><?=$description;?></p>
</div>
</div>
<!-- END SIDEBAR USER TITLE -->
<!-- SIDEBAR BUTTONS -->
<!-- END SIDEBAR BUTTONS -->
</div>
</div>
<!-- END PROFILE CONTENT -->
<!-- END BEGIN PROFILE SIDEBAR -->
</div>
</div>
</div>
</div>
</div>
<?php $this->load->view('includes/footer');?>
<!-- data tables -->
<script src="<?=base_url();?>/assets/datatables/jquery.dataTables.min.js"></script>
<script src="<?=base_url();?>/assets/datatables/plugins/bootstrap/dataTables.bootstrap4.min.js"></script>
<script src="<?=base_url();?>/assets/table_data.js"></script>