Skip to main content

Black Friday 2025! Only until December 1st: coupon FRIDAY25 for 40% off Yearly/Lifetime membership!

Read more here

Extra Table Filters: Column and Global Filters

Premium
9:07

The Full Lesson is Only for Premium Members

Want to access all of our courses? (29 h 14 min)

You also get:

54 courses
Premium tutorials
Access to repositories
Private Discord
Get Premium for $129/year or $29/month

Already a member? Login here

Comments & Discussion

LS
Laszlo Sandor ✓ Link copied!

Pagination links have gone...

LS
Laszlo Sandor ✓ Link copied!

Index.vue, line 121:

<Pagination :data="posts" @pagination-change-page="page => getPosts(page, selectedCategory)" />

There is no selectedCategory anymore.

PK
Povilas Korop ✓ Link copied!

Yeah, good catch, it should be search_category instead now.

MS
Moaz Said ✓ Link copied!

Hello, what about use https://datatables.net/ in vue as a server-side, I used it but in jquey blade or js file.. in vue How??

PK
Povilas Korop ✓ Link copied!

For vue, there are specific packages, a lot of them, google "vue datatables"

MS
Moaz Said ✓ Link copied!

yes I know but think not server side..thanks for reply

DS
Dmytro Sakharuk ✓ Link copied!

DRY

const filters = [
	'category',
	'id',
	'title',
	'content',
	'global'
]

filters.forEach(filter => {
	watch(eval(`search_${filter}`), (current, previous) => {
		getPosts(
			1,
			search_category.value,
			search_id.value,
			search_title.value,
			search_content.value,
			search_global.value,
			orderColumn.value,
			orderDirection.value
		)
	})
})

I don't remember if I commented on it in a fresher course