62 Commits

Author SHA1 Message Date
Lance Pioch
c7a307af6e Enforce return and parameter types 2024-10-19 21:02:49 -04:00
Boy132
b003404aea
Collection of small admin area changes (#604)
* enable tags for nodes

* update icon for cpu column

* disable inline for "force outgoing ip" label

* change label for database hosts resource

* add custom empty state for database hosts & api keys

* add icons to egg tabs

* fix typo

* rename node "Automatic Allocation" to avoid confusion

* run code cleanup

* remove regex for node name

* only check count for application api keys

* replace "New" with "Create"

* change sidebar width to fit "Database Hosts"
2024-10-04 01:15:08 +02:00
Charles
e78f7bc054
Just some houseKeeping (#593)
* Just some houseKeeping

* ... pint
2024-10-01 04:37:21 -04:00
Boy132
fc643f57f9
Admin Roles (#502)
* add spatie/permissions

* add policies

* add role resource

* add root admin role handling

* replace some "root_admin" with function

* add model specific permissions

* make permission selection nicer

* fix user creation

* fix tests

* add back subuser checks in server policy

* add custom model for role

* assign new users to role if root_admin is set

* add api for roles

* fix phpstan

* add permissions for settings page

* remove "restore" and "forceDelete" permissions

* add user count to list

* prevent deletion if role has users

* update user list

* fix server policy

* remove old `root_admin` column

* small refactor

* fix tests

* forgot can checks here

* forgot use

* disable editing own roles & disable assigning root admin

* don't allow to rename root admin role

* remove php bombing exception handler

* fix role assignment when creating a user

* fix disableOptionWhen

* fix missing `root_admin` attribute on react frontend

* add permission check for bulk delete

* rename viewAny to viewList

* improve canAccessPanel check

* fix admin not displaying for non-root admins

* make sure non root admins can't edit root admins

* fix import

* fix settings page permission check

* fix server permissions for non-subusers

* fix settings page permission check v2

* small cleanup

* cleanup config file

* move consts from resouce into enum & model

* Update database/migrations/2024_08_01_114538_remove_root_admin_column.php

Co-authored-by: Lance Pioch <lancepioch@gmail.com>

* fix config

* fix phpstan

* fix phpstan 2.0

---------

Co-authored-by: Lance Pioch <lancepioch@gmail.com>
2024-09-21 12:27:41 +02:00
MartinOscar
acf43f2826
Ability to create allocations on EditServer page (#494)
* Ability to create allocation on edit page + Ability to assign allocation to server on creation

* Disable dehydrate for readonly

* set these to false

---------

Co-authored-by: notCharles <charles@pelican.dev>
2024-07-20 11:38:34 -04:00
MartinOscar
c464b321dd
Update EditProfile.php (#454) 2024-07-02 07:05:00 -04:00
Lance Pioch
cf37994c3b
Allow user to switch time zones (#332)
* Description not required

* Overwrite to use user’s time zone

* Allow users to change time zones

* Update app/Filament/Resources/UserResource/Pages/EditProfile.php

Co-authored-by: Boy132 <Boy132@users.noreply.github.com>

* Pint fix

---------

Co-authored-by: Charles <charles@pelican.dev>
Co-authored-by: Boy132 <Boy132@users.noreply.github.com>
2024-06-25 20:17:08 -04:00
MartinOscar
5290b8f8bb
Update ListUsers Prevent bulkdelete of yourself/last admin (#425)
* Update ListUsers.php

* Update ListUsers.php

* Update app/Filament/Resources/UserResource/Pages/ListUsers.php

---------

Co-authored-by: Lance Pioch <lancepioch@gmail.com>
2024-06-24 21:41:42 -04:00
MartinOscar
aa08e774a1
Fix varchar(191) by replacing with 255 #135 (#376)
* Add Nullable

* Edit filament & AppServiceProvider

* Pint

* Patch tests

* Actually patching tests

* Actually patching tests

* Remove length

* Remove defaultStringLength

* Let’s see the differences

---------

Co-authored-by: Lance Pioch <git@lance.sh>
2024-06-16 13:56:18 -04:00
MartinOscar
f216376265
Update EditProfile (#368)
* Update EditProfile.php
2024-06-11 14:32:55 -04:00
MartinOscar
58bfa12280
Cleanup unused vars (#366)
* Update app/Exceptions/Handler.php

Co-authored-by: Boy132 <Boy132@users.noreply.github.com>
2024-06-11 12:22:37 -04:00
Lance Pioch
f3501d8b14
Merge pull request #343 from Boy132/phpstan-fixes
Fix remaining phpstan issues for #339
2024-06-09 15:13:44 -04:00
Boy132
70fc84309f revert some changes in EditProfile 2024-06-07 09:11:40 +02:00
Boy132
f43fb985a2 fix phpstan in Node and EditProfile 2024-06-07 08:59:00 +02:00
Lance Pioch
df26c4f9f5 Better exception handling 2024-06-05 21:49:09 -04:00
MartinOscar
cbb4ef1da2
Update EditUser.php 2024-06-03 03:52:39 +02:00
notCharles
f6ef76d98e Disable delete for own user. 2024-06-02 21:00:11 -04:00
Charles
eefe59b153
Merge pull request #300 from pelican-dev/issue/286
2FA Profile
2024-06-01 13:07:32 -04:00
Lance Pioch
cd4b7cbf9e Refresh this 2024-06-01 13:03:46 -04:00
Lance Pioch
67cb3d4816 Show backup tokens better 2024-06-01 12:49:36 -04:00
Lance Pioch
7762e68a6c Make qr code visible on light mode 2024-06-01 12:49:19 -04:00
notCharles
9174de2d8c Add Labels 2024-05-31 17:24:03 -04:00
notCharles
5081cc3f63 Fix badge, update table 2024-05-31 16:39:23 -04:00
Lance Pioch
5519931ee5 Pint 2024-05-31 01:42:02 -04:00
Lance Pioch
7657364208 Cache per user and show backup tokens temporarily 2024-05-31 01:38:32 -04:00
Lance Pioch
ef1a208b95 Add 2fa setup 2024-05-31 01:26:28 -04:00
notCharles
9b2e00ead2 pint 2024-05-17 20:10:53 -04:00
notCharles
d0997dca1a Remove hints 2024-05-17 19:59:41 -04:00
notCharles
cca723d21e Update unique, remove dehydrates 2024-05-17 19:59:04 -04:00
notCharles
12af8fe51e This is better... 2024-05-16 20:34:37 -04:00
notCharles
9f5d27896a Pint 2024-05-16 18:44:59 -04:00
notCharles
15969da41e Fix New User
Removes the required password field for making new accounts, triggers email for user to make their own password.
2024-05-16 18:43:05 -04:00
Lance Pioch
b513366f35 Merge branch 'main' of github.com:pelican-dev/panel 2024-05-15 13:24:44 -04:00
notCharles
35ac1f863a Move save buttons to the top. 2024-05-13 19:58:01 -04:00
Lance Pioch
7f6e4a18c1 Validate these 2024-05-11 23:44:12 -04:00
Lance Pioch
2c98693bd2 Replace hard coded url 2024-05-11 21:56:12 -04:00
Lance Pioch
5fd7e419d9 Run pint 2024-05-10 22:20:14 -04:00
Lance Pioch
39bc87c2e2 Swap suspend over 2024-05-10 22:19:17 -04:00
Lance Pioch
6ed85cfdc6 Better icon 2024-04-27 22:18:25 -04:00
Lance Pioch
1bdef318f0 Start adding translations to backend
Co-authored-by: Miniontoby <tobias.gaarenstroom@gmail.com>
2024-04-25 23:29:19 -04:00
notCharles
cba00d822c minor fixes for random stuff 2024-04-25 18:57:21 -04:00
Lance Pioch
00502f6d4d Allow suspension of servers 2024-04-25 17:45:49 -04:00
Lance Pioch
ea146f4715 Resource changes 2024-04-25 17:35:27 -04:00
notCharles
07244c38eb refactor resources 2024-04-23 19:45:11 -04:00
Lance Pioch
3e239f9caa Fix tabs 2024-04-21 01:00:48 -04:00
Lance Pioch
67edf4f472 Adding and deleting api keys 2024-04-20 21:01:41 -04:00
Lance Pioch
7693106a44 Order in reverse chronological order 2024-04-20 20:22:40 -04:00
Lance Pioch
d8f5e1506c Persist this for now 2024-04-20 20:22:17 -04:00
Lance Pioch
d9738949c1 Some progress 2024-04-19 22:32:57 -04:00
Lance Pioch
ae189748f1 Fix styling 2024-04-18 17:08:10 -04:00