Fixed the column hiding, Added the HorillaDb file in gitignore + using columns instead of rows (#605)

* Added the HorillaDb file in gitignore + using columns instead of rows in actions tab

* Fixed the typo which was hiding the columns in request table in work type reqest

* Fixed the typo which was hiding the columns in request table in work type reqest

* payslip table should have this as the first parameter for toggleColumns as we are passing id not data attribute , previous PR was wrong

* Fix for column toggling issue

* toggling issue fixed
This commit is contained in:
aditya singh rawat
2025-03-21 12:22:15 +05:30
committed by GitHub
parent aa4919562d
commit 46607e65e9
6 changed files with 5 additions and 8 deletions

1
.gitignore vendored
View File

@@ -57,6 +57,7 @@ coverage.xml
# Django stuff:
*.log
local_settings.py
TestDB_Horilla.sqlite3
db.sqlite3
db.sqlite3-journal

View File

@@ -32,8 +32,8 @@ function toggleColumns(tableId, fieldContainer) {
}
let selectButtons = $(`
<div class="oh-dropdown_btn-header">
<button onclick="$(this).parent().parent().find('[type=checkbox]').prop('checked',true).change()" class="oh-btn oh-btn--success-outline">Select All Rows</button>
<button onclick="$(this).parent().parent().find('[type=checkbox]').prop('checked',false).change()" class="oh-btn oh-btn--primary-outline">Unselect All Rows</button>
<button onclick="$(this).parent().parent().find('[type=checkbox]').prop('checked',true).change()" class="oh-btn oh-btn--success-outline">Select All Columns</button>
<button onclick="$(this).parent().parent().find('[type=checkbox]').prop('checked',false).change()" class="oh-btn oh-btn--primary-outline">Unselect All Columns</button>
</div>
`)
$(`#${fieldContainer}`).parent().prepend(selectButtons)

View File

@@ -398,5 +398,4 @@
if (!localStorageroratingShiftCells) {
$("#roratingShiftCells").find("[type=checkbox]").prop("checked", true);
}
$("[type=checkbox]").change();
</script>

View File

@@ -399,5 +399,4 @@
if (!localStorageroratingWorkTypeCells) {
$("#roratingWorkTypeCells").find("[type=checkbox]").prop("checked", true);
}
$("[type=checkbox]").change();
</script>

View File

@@ -427,5 +427,4 @@
if (!localStorageWorkTypeReqCells) {
$("#workTypeRequestCells").find("[type=checkbox]").prop("checked", true);
}
$("[type=checkbox]").change();
</script>
</script>

View File

@@ -246,10 +246,9 @@
});
});
// toggle columns //
toggleColumns("payslip_column_tab", "payslipCells")
toggleColumns("payslip-column-table", "payslipCells")
localStoragepayslipCells = localStorage.getItem("payslip_column_tab")
if (!localStoragepayslipCells) {
$("#payslipCells").find("[type=checkbox]").prop("checked", true)
}
$("[type=checkbox]").change()
</script>