gregnb / gregnb/mui-datatables

Go to specific record

Open
#1,460 9 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
2.7k
Forks
906
PR merge metrics
No merged PRs in 30d

Description

I have created a little React game which, when finished, displays a form for the user to enter is name, which is then inserted in my database (MySql) with his score. Then a table is displayed, retrieving every records saved from the DB, showing the score done by every user (sorted by highest score).

What I would like is, when the user finishes and submits his record with its name, that all the records are retrieved from the DB but the table would jump to the page of the user's score (which would still be sorted by highest score) (and eventually highlight his row).

Just so you know, I have the ID of every user in the table (and obviously the ID of the last inserted user - which is the one I want to go to -). I guess this is a key element but don't know how to use it to achieve what I want to do.

I did a lot of research about it but can not find anything. I know this is not a bug but rather a fonction I don't know how to implement.

I also looked at server side pagination, sorting etc but I really don't understand how to put it in place, let alone that I don't think this is the solution to my problem (as my table is populated with "static" data - after putting the users' record in the DB, if that makes sense -).

I hope you will be able to help me here and am truly sorry if this is not the good place to ask this kind of question (if so, please let me know where I should).

Thank you very much and keep up the great work ! Mui-datatables is, with no doubt, the best in its kind and a must have !

| Tech | Version
|-----------------|----------------------------|
| Material-UI | 4.11.0
| MUI-datatables | 3.3.1
| React | 16.13.1
| browser | Google Chrome @latest

Contributor guide

No contributing guide indexed for this repository

Research direction

Begin with the table's existing pagination and sorting setup, then trace the form submission and last inserted user ID into the displayed records. Done means the sorted table opens on the page containing that user's record and can highlight it, using the server-side pagination approach if required.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, mysql, react
Domain
database, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.