Merge branch 'new_theme' of bitbucket.org:venbainformationtechnology/ria into new_theme

This commit is contained in:
VE10-Sanjeev 2025-05-12 10:48:26 +00:00
commit 0e9d05fd6a
5 changed files with 102 additions and 40 deletions

View File

@ -1209,7 +1209,7 @@ class StockController extends BaseController
if(!empty($previousMonthCustomMachineCodes)){
$existingCustomMachineCodes = $this->factoryMachine_model
->getSelectedDieselMachines(array_column($previousMonthCustomMachineCodes, 'machine_id'));
->getSelectedElectricMachines(array_column($previousMonthCustomMachineCodes, 'machine_id'));
}else{
// inserting all active if no previous month present
@ -2119,7 +2119,7 @@ class StockController extends BaseController
if(!empty($previousMonthCustomMachineCodes)){
$existingCustomMaterialCodes = $this->rawmaterialdetails_model
->getSelectedResinMaterialCode(array_column($previousMonthCustomMachineCodes, 'materialCode'));
->getSelectedBagMaterialCode(array_column($previousMonthCustomMachineCodes, 'materialCode'));
}else{
// inserting all active if no previous month present

View File

@ -1,4 +1,6 @@
<?php
use Faker\Core\DateTime;
$datefordropdown = format_date($datefordropdown, 0, 'M-Y');
//echo $datefordropdown;
$attendance = array_merge($attendance, $emppay); // initial step there is no attendance entry so emppay data is merged
@ -14,8 +16,6 @@ $currentday = date('d');
text-align: right;
}
.fht-table,
.fht-table thead,
.fht-table tfoot,
@ -249,8 +249,8 @@ $currentday = date('d');
<?php $today = date('M-Y'); ?>
<input type="text" name="month" id="month" value="<?php echo $datefordropdown; ?>" class="form-control" data-provide="datepicker" data-date-format="M-yyyy" data-date-min-view-mode="1">
</div>
<div class="col-1">
<input type="submit" value="Change Month" class="btn btn-success"
<div class="col-1" style="display: none;">
<input type="submit" id="changemonth" value="Change Month" class="btn btn-success"
title='click here for load attendance for specified month' style="margin-top:0px;">
</div>
@ -310,6 +310,7 @@ $currentday = date('d');
for ($col = 1; $col <= $monthdays; $col++) {
$flag = 0;
$flag2 = 0;
$todayflag = 0;
@ -338,6 +339,10 @@ $currentday = date('d');
}
}
if($col > $currentday && $datefordropdown == date('M-Y')){
continue;
}
?>
@ -414,6 +419,8 @@ $currentday = date('d');
if ($col == $currentday) {
$todayflag = 1;
}
foreach ($sundayarray as $in) {
if ($in == $col) {
$flag = 1;
@ -434,6 +441,7 @@ $currentday = date('d');
//echo $title;
}
}
$WH = 'WH' . $col;
$OT = 'OT' . $col;
@ -451,9 +459,16 @@ $currentday = date('d');
}
if($col > $currentday && $datefordropdown == date('M-Y')){
continue;
}
// echo "<pre>"."empid = $a->EmpID, date = $col, absent = $absent"."</pre>";
// echo "<pre>"."2) all Flags : flag2 = $flag2, flag = $flag2, absent = $absent"."</pre>";
?>
?>
<td <?php if ($flag2 == 1) { ?> title=" <?php echo $title; ?> "
<?php } else if ($flag == 1) { ?> title="sunday" <?php } ?>
<?php if ($absent == 1) { ?> title="absent" <?php } ?>
@ -462,7 +477,7 @@ $currentday = date('d');
id="<?php echo $row . 'row' . $col . 'W'; ?>"
<?php if ($flag == 1 or $flag2 == 1) {
echo "style='background: #f5a6a7 ;'";
} else if ($todayflag == 1) {
} else if ($todayflag == 1 && $datefordropdown == date('M-Y')) {
echo "style='background: #cef0ad ;'";
} ?>
<?php if ($absent == 1) {
@ -484,7 +499,7 @@ $currentday = date('d');
id="<?php echo $row . 'row' . $col . 'OT'; ?>"
<?php if ($flag == 1 or $flag2 == 1) {
echo "style='background: #f5a6a7 ;'";
} else if ($todayflag == 1) {
} else if ($todayflag == 1 && $datefordropdown == date('M-Y')) {
echo "style='background: #cef0ad ;'";
} ?>
<?php if ($absent == 1) {
@ -1092,4 +1107,51 @@ $("#searchInput").on("keyup", function () {
});
});
</script>
<!-- on enter key press allowing user to go next line instead of submitting any form here -->
<script>
document.addEventListener("keydown", function(event) {
if (event.key === "Enter") {
let activeElement = document.activeElement;
// Check if the focused element is inside a table
let cell = activeElement.closest("td, th");
let table = activeElement.closest("table");
if (table && cell) {
event.preventDefault(); // Prevent form submission
let columnIndex = cell.cellIndex; // Get the current column index
let currentRow = cell.parentElement; // Get the current row
let nextRow = currentRow.nextElementSibling; // Get the next row
// Move to the same column in the next row if available
if (nextRow) {
let nextCell = nextRow.cells[columnIndex];
if (nextCell) {
nextCell.focus();
}
}
}
}
});
</script>
<script>
$(document).ready(function(){
$('#month').change(function(){
$('#atten').submit();
})
})
</script>

View File

@ -316,7 +316,7 @@
style="text-align:center;color:blue;"
<?php } else { ?>style="text-align:center;" <?php } ?>>
<?php if (!empty($record->LOP_Days)) {
echo $record->LOP_Days;
echo round($record->LOP_Days);
} else {
echo "0.00";
} ?>
@ -330,9 +330,9 @@
style="text-align:center;color:blue;"
<?php } else { ?>style="text-align:center;" <?php } ?>>
<?php if (!empty($record->Paid_leave)) {
echo number_format($record->Paid_leave, 2, '.', '');
echo round($record->Paid_leave);
} else {
echo number_format(0.00, 2, '.', '');
echo round(0);
} ?>
</td>
@ -344,59 +344,59 @@
style="text-align:center;color:blue;"
<?php } else { ?>style="text-align:center;" <?php } ?>>
<?php if (!empty($record->OT_Hrs_Worked)) {
echo $record->OT_Hrs_Worked;
echo round($record->OT_Hrs_Worked);
} else {
echo number_format(0.00, 2, '.', '');
echo 0;
} ?>
</td>
<td id="ttlsalary<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php echo $record->TotalSalary; $totalsalary[] = $record->TotalSalary; ?>
<?php echo round($record->TotalSalary); $totalsalary[] = $record->TotalSalary; ?>
</td>
<td style="max-width:80px;text-align:right;">
<?php $perDaySalary = $record->TotalSalary / $record->NoofDays;
echo number_format($perDaySalary, 2, '.', ''); $totalperdaySalary[] = $perDaySalary; ?>
echo round($perDaySalary); $totalperdaySalary[] = $perDaySalary; ?>
</td>
<td style="max-width:80px;text-align:right;">
<?php $workedSalary = $perDaySalary * ($record->Days_worked);
echo number_format($workedSalary, 2, '.', ''); ?>
echo round($workedSalary); ?>
</td>
<td style="max-width:80px;text-align:right;">
<?php $perHrSalary = $perDaySalary / 8;
echo number_format($perHrSalary, 2); $totalperhrSalary[] = $perHrSalary; ?>
echo round($perHrSalary); $totalperhrSalary[] = $perHrSalary; ?>
</td>
<td style="max-width:80px;text-align:right;">
<?php echo number_format($workedSalary, 2, '.', ''); $totalworkedSalary[] = $workedSalary; ?>
<?php echo round($workedSalary); $totalworkedSalary[] = $workedSalary; ?>
</td>
<td id="bassalary<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php $basicWorked = $workedSalary * 70 / 100;
echo number_format($basicWorked, 2, '.', ''); $totalbasic[] = $basicWorked; ?>
echo round($basicWorked); $totalbasic[] = $basicWorked; ?>
</td>
<td id="hrasalary<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php $hraWorked = $workedSalary * 30 / 100;
echo number_format($hraWorked, 2, '.', ''); $totalhra[] = $hraWorked; ?>
echo round($hraWorked); $totalhra[] = $hraWorked; ?>
</td>
<td id="grosalary<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php echo number_format($basicWorked + $hraWorked, 2, '.', ''); $totalgross[] = $basicWorked + $hraWorked; ?>
<?php echo round($basicWorked + $hraWorked); $totalgross[] = $basicWorked + $hraWorked; ?>
</td>
<td id="esiAmt<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php echo $esi[$i]; $totalesi[] = $esi[$i]; ?>
<?php echo round($esi[$i]); $totalesi[] = $esi[$i]; ?>
</td>
<td id="pfAmt<?php echo $index ?>" style="max-width:80px;text-align:right;">
<?php echo $pf[$i]; $totalpf[] = $pf[$i]; ?>
<?php echo round($pf[$i]); $totalpf[] = $pf[$i]; ?>
</td>
<td style="max-width:80px;text-align:right;">
<?php echo $over_time[$i]; $totalovertime[] = $over_time[$i]; ?>
<?php echo round($over_time[$i]); $totalovertime[] = $over_time[$i]; ?>
</td>
<td id="monthDue<?php echo $index ?>" onkeypress="return isNumber(event);" onkeyup="changeInput(event);"
@ -406,10 +406,10 @@
<?php } else { ?>style="text-align:right;" <?php } ?>>
<?php if (!empty($record->Monthly_Due)) {
echo $record->Monthly_Due;
echo round($record->Monthly_Due);
$totalmonthloan[] = $record->Monthly_Due;
} else {
echo number_format(0.00, 2, '.', '');
echo 0;
} ?>
</td>
@ -423,10 +423,10 @@
<?php } else { ?>style="text-align:right;" <?php } ?>>
<?php if (!empty($record->Other_Deductions)) {
echo $record->Other_Deductions;
echo round($record->Other_Deductions);
$totalotherDet[] = $record->Other_Deductions;
} else {
echo number_format(0.00, 2, '.', '');
echo 0 ;
} ?>
</td>
@ -441,10 +441,10 @@
style="text-align:right;color:blue;"
<?php } else { ?>style="text-align:right;" <?php } ?>>
<?php if (!empty($record->Festival_Bonus)) {
echo $record->Festival_Bonus;
echo round($record->Festival_Bonus);
$totalfestival[] = $record->Festival_Bonus;
} else {
echo number_format(0.00, 2, '.', '');;
echo 0;
} ?>
</td>
@ -458,15 +458,15 @@
style="text-align:right;color:blue;" <?php }else{ ?>style="text-align:right;" <?php } ?>>
<!-- <?php if (!empty($record->Estimate)) {
echo $record->Estimate;
echo round($record->Estimate);
$estTotal[] = $record->Estimate;
} else {
echo $empSalary[$i];
echo round($empSalary[$i]);
$estTotal[] = $empSalary[$i];
}
?> -->
<?php echo $empSalary[$i]; $estTotal[] = $empSalary[$i]; ?>
<?php echo round($empSalary[$i]); $estTotal[] = $empSalary[$i]; ?>
</td>

View File

@ -29,13 +29,13 @@
<a href="<?php echo base_url(); ?>Report_purchase" target="_blank"><p class="uk-text uk-margin-remove">Purchase</p></a>
<a href="<?php echo base_url(); ?>Report_year_wise" target="_blank"><p class="uk-text uk-margin-remove">Year Wise</p></a>
<a href="<?php echo base_url(); ?>Report_pending_purchase" target="_blank"><p class="uk-text uk-margin-remove">Pending Purchase</p></a>
<a href="<?php echo base_url(); ?>Report_supplier" target="_blank"><p class="uk-text uk-margin-remove">purchase - Supplier Wise</p></a>
<a href="<?php echo base_url(); ?>Report_consolidate" target="_blank"><p class="uk-text uk-margin-remove">purchase - Consolidate</p></a>
<a href="<?php echo base_url(); ?>Report_supplier" target="_blank"><p class="uk-text uk-margin-remove">Purchase - Supplier Wise</p></a>
<a href="<?php echo base_url(); ?>Report_consolidate" target="_blank"><p class="uk-text uk-margin-remove">Purchase - Consolidate</p></a>
</div>
<div class="col-md-3">
<h4><span class="fa fa-layer-group">&nbsp; Material Master </span></h4>
<a href="<?php echo base_url(); ?>Report_Material_Supplier" target="_blank"><p class="uk-text uk-margin-remove">Material Master - supplier wise</p></a>
<a href="<?php echo base_url(); ?>Report_Material_Item" target="_blank"><p class="uk-text uk-margin-remove">Material Master - Item wise</p></a>
<a href="<?php echo base_url(); ?>Report_Material_Supplier" target="_blank"><p class="uk-text uk-margin-remove">Material Master - Supplier Wise</p></a>
<a href="<?php echo base_url(); ?>Report_Material_Item" target="_blank"><p class="uk-text uk-margin-remove">Material Master - Item Wise</p></a>
<a href="<?php echo base_url(); ?>Report_Material_ReceiptValue" target="_blank"><p class="uk-text uk-margin-remove">Material Master - Receipt Value</p></a>
</div>
<div class="col-md-3">

View File

@ -523,7 +523,7 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y');
<!-- input sand qty -->
<div class="col-md-3">
<label class="form" for="additionalEntryInputSandQtyId">Input Sand Quantity (Metric Ton)</label>
<label class="form" for="additionalEntryInputSandQtyId">Input Sand Qty(Metric Ton)</label>
<span class="text-danger">*</span>
<input onchange="additionalEntryGasPerTon(); additionalEntryMoistureLossQty(); additionalEntryQtyPerHrs(); "
type="text" class="form-control" id="additionalEntryInputSandQtyId" name="input_sand_qty" value="" required>
@ -691,7 +691,7 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y');
<!-- input sand qty -->
<div class="col-md-3">
<label class="form" for="editEntryInputSandQtyId">Input Sand Quantity (Metric Ton)</label>
<label class="form" for="editEntryInputSandQtyId">Input Sand Qty(Metric Ton)</label>
<span class="text-danger">*</span>
<input onchange="editEntryGasPerTon(); editEntryMoistureLossQty(); editEntryQtyPerHrs(); "
type="text" class="form-control" id="editEntryInputSandQtyId" name="input_sand_qty" value="" required>