Should I put all the logic in Laravel policies?

Viewed 80

In General should I put all the logic in laravel policies or just the authorization logic ?

For example .....

I have a Currency Policy which allows the admin to change the base currency only in this case :

  1. The admin has this permission .
  2. No products added to the system .

As you notice , the condition (1) is specific and obviously an authorization logic .

But Condition (2) is a general condition .

Now my question .....

Should I put (2) or any general conditions in controllers Or I should put It in policies ?

0 Answers
Related