stock changes 21-04-2025

This commit is contained in:
vadivelJ96 2025-04-21 12:57:54 +05:30
parent 82a18ebb8c
commit adf9498710
5 changed files with 41 additions and 29 deletions

View File

@ -365,9 +365,7 @@
<input type="text" name="month" id="month" value="<?php echo "$month" ?>" <input type="text" name="month" id="month" value="<?php echo "$month" ?>"
class="form-control " class="form-control "
data-provide="datepicker" readonly>
data-date-format="M-yyyy"
data-date-min-view-mode="1" readonly>
</div> </div>
@ -1713,7 +1711,6 @@
$('#changeMonthForm').submit(); $('#changeMonthForm').submit();
}); });
$(document).ready(function(){
$('#month').datepicker({ $('#month').datepicker({
format: 'M-yyyy', format: 'M-yyyy',
viewMode: 'months', viewMode: 'months',
@ -1723,7 +1720,6 @@
startDate: new Date(2025, 0), // Jan is month 0 startDate: new Date(2025, 0), // Jan is month 0
endDate: new Date() // current date as max endDate: new Date() // current date as max
}); });
})

View File

@ -327,9 +327,7 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y');
<input type="text" name="month" id="month" value="<?php echo "$datefordropdown" ?>" <input type="text" name="month" id="month" value="<?php echo "$datefordropdown" ?>"
class="form-control " class="form-control "
data-provide="datepicker" readonly>
data-date-format="M-yyyy"
data-date-min-view-mode="1" readonly>
</div> </div>
@ -1585,11 +1583,23 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y');
<!-- onchange of month submit will happen --> <!-- onchange of month submit will happen -->
<script> <script>
$(document).ready(function() {
$('#month').change(function() { $(document).on('change', '#month', function() {
$('#changeMonthForm').submit(); $('#changeMonthForm').submit();
}) });
})
$('#month').datepicker({
format: 'M-yyyy',
viewMode: 'months',
minViewMode: 'months',
autoclose: true,
orientation: 'bottom',
startDate: new Date(2025, 0), // Jan is month 0
endDate: new Date() // current date as max
});
</script> </script>
<script> <script>

View File

@ -362,9 +362,7 @@
<input type="text" name="month" id="month" value="<?php echo "$month" ?>" <input type="text" name="month" id="month" value="<?php echo "$month" ?>"
class="form-control " class="form-control "
data-provide="datepicker" readonly
data-date-format="M-yyyy"
data-date-min-view-mode="1" readonly
style="max-width: 175px;"> style="max-width: 175px;">
</div> </div>
@ -992,9 +990,6 @@
<script> <script>
$('#month').change(function() {
$('#changeMonthForm').submit();
})
$(document).ready(function() { $(document).ready(function() {
@ -1006,9 +1001,15 @@
orientation: 'bottom', orientation: 'bottom',
startDate: new Date(2025, 0), // Jan is month 0 startDate: new Date(2025, 0), // Jan is month 0
endDate: new Date() // current date as max endDate: new Date() // current date as max
}).on('focus', function() { }).on('focus', function() {
$(this).datepicker('show'); // Ensure it opens on focus $(this).datepicker('show'); // Ensure it opens on focus
}); });
$('#month').change(function() {
$('#changeMonthForm').submit();
})
}); });
</script> </script>

View File

@ -315,6 +315,8 @@
display: none; display: none;
} }
</style> </style>

View File

@ -353,9 +353,7 @@
<input type="text" name="month" id="month" value="<?php echo "$month" ?>" <input type="text" name="month" id="month" value="<?php echo "$month" ?>"
class="form-control " class="form-control "
data-provide="datepicker" readonly
data-date-format="M-yyyy"
data-date-min-view-mode="1" readonly
style="max-width: 175px;"> style="max-width: 175px;">
</div> </div>
@ -1035,9 +1033,7 @@
</script> </script>
<script> <script>
$('#month').change(function() {
$('#changeMonthForm').submit();
})
$(document).ready(function() { $(document).ready(function() {
@ -1052,7 +1048,14 @@
}).on('focus', function() { }).on('focus', function() {
$(this).datepicker('show'); // Ensure it opens on focus $(this).datepicker('show'); // Ensure it opens on focus
}); });
$('#month').change(function() {
$('#changeMonthForm').submit();
})
}); });
</script> </script>