225 lines
9.5 KiB
PHP
225 lines
9.5 KiB
PHP
<?php
|
|
include('techsyn_header.php');
|
|
include('log_entry.php');
|
|
if (!isset($_SESSION['RoleCode']) || ($_SESSION['RoleCode'] != "STR" && $_SESSION['RoleCode'] != "DISC" && $_SESSION['RoleCode'] != "TRAC")) {
|
|
// echo "<script>location.href='accessDenied.php'</script>";
|
|
}
|
|
?>
|
|
<link rel="stylesheet" href="css/wizard.css">
|
|
|
|
<script src="js/Chart.min.js"></script>
|
|
<script type="text/javascript"
|
|
src="https://cdn.jsdelivr.net/npm/chartjs-plugin-datalabels@0.4.0/dist/chartjs-plugin-datalabels.min.js"></script>
|
|
<style type="text/css">
|
|
.hidden-radio {
|
|
position: absolute;
|
|
top: 11px;
|
|
left: 27px;
|
|
width: 60px;
|
|
height: 60px;
|
|
border-radius: 100%;
|
|
background: #fff;
|
|
opacity: 0;
|
|
cursor: pointer;
|
|
}
|
|
|
|
button:focus {
|
|
outline-color: black;
|
|
}
|
|
</style>
|
|
|
|
<!-- Main Content Container for side bar and body-->
|
|
<div class="main-container ace-save-state" id="main-container">
|
|
<script type="text/javascript">
|
|
try {
|
|
ace.settings.loadState('main-container')
|
|
} catch (e) {}
|
|
</script>
|
|
<?php include('techsyn_sidebar.php'); ?>
|
|
|
|
<!--breadcrumb-->
|
|
<?php
|
|
$sql_procure_items = "select * from procurement_items where isExpired='0' and expiry < (CURRENT_DATE + INTERVAL 30 DAY) and ohc_type_id='" . $_SESSION['current_ohcttype'] . "' order by expiry asc";
|
|
error_log('query: 19: ' . $sql_procure_items);
|
|
$results_procure_items = mysqli_query($conn, $sql_procure_items);
|
|
$total_proc = mysqli_num_rows($results_procure_items);
|
|
|
|
//added on 04-12-2021 - start
|
|
$ohc_type = $_SESSION['current_ohcttype'];
|
|
$sql_count_stock_in = "select ifNull(count(*),0) from stock_issue where status='Y' and stock_issue_id not in (SELECT issue_id FROM `received_master`) and ohc_location_id in ($ohc_type)";
|
|
error_log('query:va: ' . $sql_count_stock_in);
|
|
$results_stock_in_items = mysqli_query($conn, $sql_count_stock_in);
|
|
|
|
$total_stock_in_row = mysqli_fetch_array($results_stock_in_items);
|
|
$total_stock_in = $total_stock_in_row[0];
|
|
|
|
error_log("total_stock_in: " . $total_stock_in);
|
|
// end
|
|
|
|
$sql_reorder_items = "select i.item_id,item_name,reorder_store_level,min_store_level,itm_stk.item_stock_qty from tbl_items i, (SELECT item_id, sum(stock_qty) item_stock_qty FROM `item_stock` group by item_id) itm_stk where itm_stk.item_id=i.item_id and item_stock_qty<=reorder_store_level";
|
|
|
|
error_log('query: 262626262 ' . $sql_reorder_items);
|
|
$results_reorder_items = mysqli_query($conn, $sql_reorder_items);
|
|
$total = mysqli_num_rows($results_reorder_items);
|
|
|
|
$expiryAlertAdvance = getConfigKey("ITEM_EXPIRY_ALERT_DAYS");
|
|
if ($expiryAlertAdvance == null) {
|
|
$expiryAlertAdvance = 90;
|
|
}
|
|
$sql_expiry_items = "select i.item_id,item_name,itm_stk.item_batch_no,itm_stk.expiry_date, itm_stk.stock_qty from tbl_items i, (select * from item_stock where stock_qty>0 and ohc_type_id='" . $_SESSION['current_ohcttype'] . "' and item_stock_id not in (select item_stock_id from cleanup_item_stock) and DATE(expiry_date)<= (CURDATE() + INTERVAL $expiryAlertAdvance DAY )) itm_stk where itm_stk.item_id=i.item_id";
|
|
$results_expiry_items = mysqli_query($conn, $sql_expiry_items);
|
|
$total_item = mysqli_num_rows($results_expiry_items);
|
|
|
|
|
|
|
|
?>
|
|
<div class="main-content">
|
|
<div class="main-content-inner">
|
|
<div class="breadcrumbs ace-save-state" id="breadcrumbs">
|
|
<ul class="breadcrumb">
|
|
<li><i class="ace-icon fa fa-home home-icon"></i> <a href="#">Home</a>
|
|
</li>
|
|
<li class="active">Dashboard</li>
|
|
|
|
</ul>
|
|
|
|
|
|
</div>
|
|
<!-- End of breadcrumb -->
|
|
|
|
<div class="content">
|
|
<!-- Start new dashboard view -->
|
|
<div class="container-fluid">
|
|
|
|
<form id="store_form">
|
|
<div class="row" style="margin-top: 10px;">
|
|
|
|
<div class="col-12 col-sm-6 col-md-4">
|
|
<div class="info-box mb-3 choice">
|
|
<span class="info-box-icon bg-red"><input type="radio" name="task"
|
|
class="hidden-radio" value="attendance"><i class="fa fa-calendar" aria-hidden="true"></i>
|
|
</i></span>
|
|
|
|
<div class="info-box-content"><br>
|
|
<span class="info-box-text">Daily Attendance</span>
|
|
<span class="info-box-number"><?php echo getCountForToday('attendance_batch', 'attendence_date', '', '') ?>
|
|
<small>Attendance Done</small></span>
|
|
</div>
|
|
<!-- /.info-box-content -->
|
|
</div>
|
|
<!-- /.info-box -->
|
|
</div>
|
|
|
|
|
|
<div class="col-12 col-sm-6 col-md-4">
|
|
<div class="info-box mb-3 choice">
|
|
<span class="info-box-icon bg-green"><input type="radio" name="task"
|
|
class="hidden-radio" value="meeting"><i class="fa fa-product-hunt" aria-hidden="true"></i>
|
|
</i></span>
|
|
|
|
<div class="info-box-content"><br>
|
|
<span class="info-box-text">Parents Meeting</span>
|
|
<span class="info-box-number"><?php echo getCountForToday('primary_parents_meeting', 'meeting_date', '', '') ?>
|
|
<small>Meetings</small></span>
|
|
</div>
|
|
<!-- /.info-box-content -->
|
|
</div>
|
|
<!-- /.info-box -->
|
|
</div>
|
|
|
|
<div class="col-12 col-sm-6 col-md-4">
|
|
<div class="info-box mb-3 choice">
|
|
<span class="info-box-icon bg-green"><input type="radio" name="task"
|
|
class="hidden-radio" value="examination"><i class="fa fa-pencil-square" aria-hidden="true"></i>
|
|
</i></span>
|
|
|
|
<div class="info-box-content"><br>
|
|
<span class="info-box-text">Examination</span>
|
|
<span class="info-box-number"><?php echo getCountForToday('placement_examination', 'examination_date', '', '') ?>
|
|
<small> Done</small></span>
|
|
</div>
|
|
<!-- /.info-box-content -->
|
|
</div>
|
|
<!-- /.info-box -->
|
|
</div>
|
|
|
|
|
|
|
|
<!-- /.col -->
|
|
</div>
|
|
<!-- /.row -->
|
|
|
|
<div class="row" style="margin-top: 10px;">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="col-12 col-sm-6 col-md-4">
|
|
<div class="info-box mb-3 choice">
|
|
<span class="info-box-icon bg-red"><input type="radio" name="task"
|
|
class="hidden-radio" value="placement"><i class="fa fa-street-view" aria-hidden="true"></i>
|
|
</i></span>
|
|
|
|
<div class="info-box-content"><br>
|
|
<span class="info-box-text">Placement Register</span>
|
|
<span class="info-box-number"><?php echo getCountForToday('placement_records', 'placement_date', '', '') ?>
|
|
<small> Registerd</small></span>
|
|
</div>
|
|
<!-- /.info-box-content -->
|
|
</div>
|
|
<!-- /.info-box -->
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</form>
|
|
</div>
|
|
|
|
|
|
<!-- /.page-content -->
|
|
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!-- /.main-content -->
|
|
|
|
|
|
</div>
|
|
|
|
<?php include('techsyn_footer.php'); ?>
|
|
|
|
<script>
|
|
$(document).ready(function() {
|
|
$(".choice").on("click", function() {
|
|
var v = $(this).closest("div").find("input[name='task']").attr("checked", "checked");
|
|
task = $(this).closest("div").find("input[name='task']").val()
|
|
$("#store_form").attr('method', 'POST');
|
|
if (task == 'fees') {
|
|
$("#store_form").attr('action', 'batch_fee_schedule.php');
|
|
} else if (task == 'meeting') {
|
|
$("#store_form").attr('action', 'parents_meeting.php');
|
|
} else if (task == 'attendance') {
|
|
$("#store_form").attr('action', 'tranning_atendence.php');
|
|
} else if (task == 'examination') {
|
|
$("#store_form").attr('action', 'examination.php');
|
|
} else if (task == 'placement') {
|
|
$("#store_form").attr('action', 'placement_register.php');
|
|
}
|
|
|
|
|
|
$("#store_form").submit();
|
|
|
|
});
|
|
});
|
|
</script>
|