# data-table

```vue-html
<data-table
    :columns="columns"
    :data="products"
    :total-rows="total"
    :options="{ showSelection: true, globalSearch: true }"
    @change-query="loadData"
/>
```

**Key Features:**

* Column-based filtering (multi-select, single-select, boolean, date, search)
* Multi-column sorting
* URL query parameter persistence
* Row selection and bulk actions
* Expandable rows
* Global search
* Configurable pagination

**Props:**

* `columns` (Array) - Column definitions with filters, sorting, rendering
* `data` (Array) - Table data
* `totalRows` (Number) - Total record count for pagination
* `options` (Object) - Configuration object
* `isLoading` (Boolean) - Loading state
* `perPage` (Number) - Rows per page (default: 10)
* `compact` (Boolean) - Compact display mode
* `urlQueryParams` (Object) - Additional URL parameters

**Events:**

* `change-query` - Emitted when criteria changes (filters, sorting, pagination)
* `select-row` - Row selection change
* `change-page` - Page navigation
* `change-filter` - Filter modification
* `change-sort` - Sort order change


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.b2b-sellers.com/b2b-platform/developer-guide/b2bsellers-core-plugin/vue.js-b2b-platform/base-components/data-table.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
