1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2026-02-05 11:14:03 +00:00
Commit graph

19 commits

Author SHA1 Message Date
lukinovec
a1e8324fb5 Use consistent shortest path terminology 2025-05-29 13:13:41 +02:00
github-actions[bot]
82f9138666 Fix code style (php-cs-fixer) 2025-05-29 10:52:24 +00:00
lukinovec
233dbd0184 Improve readability 2025-05-29 12:51:37 +02:00
lukinovec
973f7994c3 Improve code for determining the shortest path 2025-05-29 12:51:37 +02:00
lukinovec
3e8cb02981 Improve TableRLSManager comments 2025-05-29 12:51:36 +02:00
github-actions[bot]
759931394c Fix code style (php-cs-fixer) 2025-05-28 13:56:50 +00:00
lukinovec
a3b925b362 Refactor TableRLSManagerr (dynamic programming, deal with recursive relationships, determine shortest paths while generating the paths) 2025-05-28 15:56:25 +02:00
lukinovec
37edba8dbc Improve comments 2025-05-21 14:10:46 +02:00
lukinovec
adfddab951 Make path skipping logic more explicit 2025-05-21 14:03:51 +02:00
lukinovec
349ac6e9fc Simplify and clarify comment-related TableRLSManager code 2025-05-21 14:03:51 +02:00
lukinovec
f65c64c9c7 Correct comment functionality, add comment constraint exception 2025-05-21 14:03:51 +02:00
github-actions[bot]
a52745704e Fix code style (php-cs-fixer) 2025-05-20 11:59:09 +00:00
lukinovec
c80b28cf00 Add option to provide constraint information in column comment 2025-05-20 13:58:33 +02:00
lukinovec
588d1fcc0d
[4.x] Make TableRLSManager skip foreign keys with 'no-rls' comment right away (#1352)
* When a foreign key has no-rls comment (or no comment when scopeByDefault is false), skip path generation earlier

* Fix column definitions
2025-05-15 14:54:04 +02:00
8960a83047
[4.x] Laravel 12 support (#1321)
* Add Laravel 12 support, drop Laravel 11 support

* Fix RLS tree generation (specify schema name in generateTrees())

* ci fixes, use stable virtualcolumn version

---------

Co-authored-by: lukinovec <lukinovec@gmail.com>
2025-02-25 16:26:18 +01:00
f955b38e2b phpstan fixes 2025-01-05 15:50:30 +01:00
Márk Magyar
79f740d057
[4.x] General code cleanup (#1278)
* Declare sensitive parameters as sensitive

... just so that they don't show up in logs

* Remove unnecessary null-coalescing

* Simplify return

* Merge isset() calls

* Inline return

* Use nullsafe operator

* Simplify if-else branches

* Use direct empty string comparison instead of strlen()

* Add missing type

* Change interface as events expect a TenantWithDatabase not just a Tenant

* Narrow typehint

* Remove redundant type casts

* Fix style with php-cs-fixer

* Fix typos

* Revert unwanted if-else simplification

* fix phpstan errors

* narrow type

---------

Co-authored-by: Samuel Štancl <samuel@archte.ch>
2024-12-31 00:35:46 +01:00
4372e1bef2 fix phpstan errors 2024-08-06 04:35:25 +02:00
Samuel Štancl
7317d2638a
Postgres RLS + permission controlled database managers (#33)
This PR adds Postgres RLS (trait manager + table manager approach) and permission controlled managers for PostgreSQL.

---------

Co-authored-by: lukinovec <lukinovec@gmail.com>
Co-authored-by: PHP CS Fixer <phpcsfixer@example.com>
2024-04-24 22:32:49 +02:00