Questions tagged [laravel]
Laravel is a free, open-source web MVC framework for PHP.
                130 questions
            
            
            
                3
            
            votes
        
        
            
                3
            
            answers
        
        
            
                230
            
            views
        
        
            
            
            
        Best Practices for Implementing a Heartbeat Feature in a Laravel App to Track Offline Status
                    I'm trying to implement a heartbeat feature for offline tracking that just sends an offline message to the server once the web browser app (Laravel-based) is offline. Ideally it will ping the app's ...
                
            
       
        
            
                5
            
            votes
        
        
            
                4
            
            answers
        
        
            
                687
            
            views
        
        
            
            
            
        Is this too much for a modular monolith system? [closed]
                    A little background before I ask my questions. I've designed a system as an architect based on the requirements given to me by the client. The client has a team or two to three developers which are ...
                
            
       
        
            
                1
            
            vote
        
        
            
                2
            
            answers
        
        
            
                226
            
            views
        
        
            
            
        Placing business logic on a not so small/big project
                    I am having a bit of problem trying to find the correct place for business logic. The project I am working on isn't huge, but is not small either and has a very considerable importance in my company. ...
                
            
       
        
            
                3
            
            votes
        
        
            
                2
            
            answers
        
        
            
                2k
            
            views
        
        
            
        Is it good design to have a repository update multiple entities?
                    I'm building a web application using Laravel. I use the repository pattern as my data layer.
Imagine there's some entity like Product and a product can be assigned to a ProductCategory.
The Product ...
                
            
       
        
            
                0
            
            votes
        
        
            
                0
            
            answers
        
        
            
                110
            
            views
        
        
            
            
        In Laravel, how do you handle a resource being managed differently depending on a user role while using policies?
                    I find myself in a situation where I have two roles, "Admin" and a "Organizer". The "Admin" accesses the AdminUserController to update users, while the "Organizer&...
                
            
       
        
            
                -2
            
            votes
        
        
            
                2
            
            answers
        
        
            
                73
            
            views
        
        
            
            
        How to serve customized content to each user, based on targeting criteria?
                    In my PHP Laravel application, I want to display special offers to users, depending on the quality of their house(s).
There are  4 Models: User, House, Offer, OfferTargeting.
Each User can have many ...
                
            
       
        
            
                0
            
            votes
        
        
            
                1
            
            answer
        
        
            
                736
            
            views
        
        
            
        Validation in both controller and my service classes?
                    I use the Laravel framework.
I've got controllers, like CustomerActivityController, and I've got a service layer with services like CustomerActivityService.
Say I want to create a new customer ...
                
            
       
        
            
                1
            
            vote
        
        
            
                1
            
            answer
        
        
            
                392
            
            views
        
        
            
            
            
        Why doesn't Laravel actively support Service Classes?
                    There must be a good reason for this. Laravel's default pattern makes no use of Service Classes... but the Laravel community's best practices is for business logic to be stored in them.
Laravel's ...
                
            
       
        
            
                7
            
            votes
        
        
            
                1
            
            answer
        
        
            
                492
            
            views
        
        
            
            
        Service Design Pattern
                    I'm working with services and I found out there are at least 3 ways to use them inside controllers...
Statically: Like helper, Text::uppercase('foo')
Instancing it: $text = new Text(); $text->...
                
            
       
        
            
                2
            
            votes
        
        
            
                0
            
            answers
        
        
            
                66
            
            views
        
        
            
        How to back out of a website development job that's way out of my league [duplicate]
                    TLDR: project scope has crept beyond my capabilities and I need an early exit strategy (in both parties' best interest)
Early last year I took on a gig to develop a web application for a financial ...
                
            
       
        
            
                -1
            
            votes
        
        
            
                1
            
            answer
        
        
            
                99
            
            views
        
        
            
            
            
        How to write package for two frameworks
                    I'm developing a package for Laravel & Lumen in the same code base, but I encountered some problems.
Well, in the beginning, I thought it could have the same code and work for both frameworks, ...
                
            
       
        
            
                -3
            
            votes
        
        
            
                2
            
            answers
        
        
            
                197
            
            views
        
        
            
            
        Does DigitalOcean offer enough resources to run a scalable MySQL cluster?
                    I have a Kubernetes instance from DigitalOcean that has 2 worker nodes and 1 load balancer. Now I want to create a MySQL managed database cluster for the app that will run on that Kubernetes.
Question ...
                
            
       
        
            
                2
            
            votes
        
        
            
                1
            
            answer
        
        
            
                771
            
            views
        
        
            
            
            
        Is it considered as best practice to use migration scripts for one-off large data manipulation over a table?
                    I have inherited a project via laravel that uses its database migration mechanism coming from the framework. The application has the following table named actions:
action_log_id SERIAL PK
user_id INT 
...
                
            
       
        
            
                0
            
            votes
        
        
            
                1
            
            answer
        
        
            
                231
            
            views
        
        
            
            
            
        Modular code how do they really fit together?
                    Let's say I am developing an ecommerce application. And I have modules organized in certain way.
Products
Coupon
Tag (can be used as brands and linked data)
Offer
Now what I want to achieve is user ...
                
            
       
        
            
                1
            
            vote
        
        
            
                0
            
            answers
        
        
            
                45
            
            views
        
        
        Is this kind of polling from backend (Angular + Laravel) acceptable?
                    I created a forum where I want to display notifications and messages as soon the user gets them. I don't want them to need to refresh to page to see if any notification/message been sent, but I also ...
                
            
       
         
         
         
         
        