-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
orderBy('sort') for permissions BP Latest #552
Comments
This is interesting, if your way solves then it does that for the However, this seem to have brought up a bug. The DataTables Sort By does not work for the entire Roles table. I tried to take a look at it but honestly I dont quite get how DataaTables are sorting things. |
Well i personally don't use DataTables cause i like to have my own filtering and stuff but this were important to me since it soon gets allot of permissions and i need them to list in an correct order. Let's say i crate an new permission for projects i want it among the other project permissions and not at the end of the list. My fix woks for me but please tell me if you decide to solve it in another way :) Edit: Well now i see what you mean, the role list gets locked to permission sort. This is obvious not the idea. I just wanted to hard code permission sort by order in the sub list in roles DataTable. I don't have many roles so this is not an problem for me but of course there must be an way to solve this? |
Fixed in upcoming. |
Don't know if I'm missing something but my permissions won't sort by sort so i changed
App\Repositories\Repository on line 16 from:
return $this->query()->get();
to
return $this->query()->orderBy('sort')->get();
Is this okay or is it a better way?
The text was updated successfully, but these errors were encountered: