lundi 10 juin 2019

Creating common logics for all type of application in a project

I am creating a project in laravel having web front end, web admin panel, mobile apis as well. Now I Need such type of project structure in laravel so that I can resuse the code in apis, front end and backend as well.

For example I am using login then I will create a login function only once and then I can reuse it to login with admin panel, mobile app and front end panel as well. I am using laravel 5.8 and its modules.

Please suggest me best way to do this so that there will be no conflicts while writing code and creating functionalities. I have tried with Laravel services where I create service class for each of the functionality then call them in api controllers and front end controllers, but I found it little bit messy and complicated.

Please suggest me best idea to do it as I have 3 types of user roles and all can login and make operations in web and mobile both with slightly difference with web and mobile functionalities.

Please help me with best possible solutions

Thanks in advance



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire