Add project files.

This commit is contained in:
login
2025-05-06 02:04:49 +07:00
parent b387f4e283
commit e1980fe6a2
333 changed files with 128684 additions and 0 deletions

View File

@ -0,0 +1,57 @@
import AbsTable from '/js/libs/js-AbsTable.js'
export default class AListBox extends AbsTable {
constructor(e) {
super(e);
this.absContainer.setAttribute("data-style", "AListBox");
this.multiSelect = false;
this.selectedID = -1;
this.selectedIDs = [];
this.selectedItem = null;
this.selectedItems = [];
this.absRows.addEventListener("click", this.RowClick.bind(this), false);
}
RemoveItem(id) {
}
CheckSelected(row) {
var id = row.getAttribute("data-id");
if (this.multiSelect) {
} else {
if (this.selectedID != id) {
(this.selectedItem != null)?this.selectedItem.classList.remove("active"):null;
this.selectedItem = row;
this.selectedID = id;
this.selectedItem.classList.add("active");
}
}
}
checkMultiSeleted(id, ele, f) {
if (this.multiSelect) {
if (f) {
} else {
}
} else {
if (f) {
this.selectedID = id;
this.selectedItem = ele;
} else {
this.selectedID = null;
this.selectedItem = null;
}
}
}
RowClick(e) {
var target = e.target;
var row = target.closest("tr");
if (row != null) {
this.CheckSelected(row);
}
}
LoadDataAuto() {
}
}