selected row, colored
This commit is contained in:
@@ -26,6 +26,7 @@ const screenWidth = ref(screen.width)
|
|||||||
const screenHeight = ref(screen.height)
|
const screenHeight = ref(screen.height)
|
||||||
const hover = ref(true);
|
const hover = ref(true);
|
||||||
const hoverImage = ref(null);
|
const hoverImage = ref(null);
|
||||||
|
const selectedRow = ref(null);
|
||||||
|
|
||||||
const sdropdown = ref([
|
const sdropdown = ref([
|
||||||
{ text: "Description", value: "typeName" },
|
{ text: "Description", value: "typeName" },
|
||||||
@@ -400,6 +401,10 @@ const submit = () => {
|
|||||||
settingsStore.post(route("products.compare"));
|
settingsStore.post(route("products.compare"));
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const selectedRowClassNameFunction = (item) => {
|
||||||
|
if (item.code == itemCode.value) return 'selected-row';
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
@@ -532,6 +537,7 @@ const submit = () => {
|
|||||||
:items="options_items"
|
:items="options_items"
|
||||||
:search-field="searchField"
|
:search-field="searchField"
|
||||||
:search-value="searchValue"
|
:search-value="searchValue"
|
||||||
|
:body-row-class-name="selectedRowClassNameFunction"
|
||||||
@click-row="showRow"
|
@click-row="showRow"
|
||||||
:filter-options="filterOptions"
|
:filter-options="filterOptions"
|
||||||
alternating
|
alternating
|
||||||
@@ -655,6 +661,12 @@ const submit = () => {
|
|||||||
width: 128px;
|
width: 128px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.selected-row {
|
||||||
|
--easy-table-body-row-background-color: #f56c6c;
|
||||||
|
--easy-table-body-row-font-color: #fff;
|
||||||
|
--easy-table-body-even-row-background-color: #f56c6c
|
||||||
|
}
|
||||||
|
|
||||||
:root .result-country {
|
:root .result-country {
|
||||||
--easy-table-body-row-background-color: yellow;
|
--easy-table-body-row-background-color: yellow;
|
||||||
--easy-table-body-even-row-background-color: yellow;
|
--easy-table-body-even-row-background-color: yellow;
|
||||||
|
|||||||
Reference in New Issue
Block a user