关于[Filter user records using Global Query Filters]的摘要:
In my last blog post, I demonstrated how you could make use of extension methods to filter EF Core entities belonging to the currently logged-in user. That technique works great in encapsulating the logic to filter the data, but it still requires developers to call the extension method every time they want to filter data. Failing to call the method can have disastrous effects as you can accidentally make one user’s information visible to someone else.
原文地址: https://www.jerriepelser.com/blog/filter-user-records-using-global-query-filter/