close #2799 Fixed: Company delete can not delete sub categories
This commit is contained in:
		
							
								
								
									
										24
									
								
								app/Events/Setting/CategoryCreated.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								app/Events/Setting/CategoryCreated.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Event;
 | 
			
		||||
 | 
			
		||||
class CategoryCreated extends Event
 | 
			
		||||
{
 | 
			
		||||
    public $category;
 | 
			
		||||
 | 
			
		||||
    public $request;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $category
 | 
			
		||||
     * @param $request
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($category, $request)
 | 
			
		||||
    {
 | 
			
		||||
        $this->category = $category;
 | 
			
		||||
        $this->request  = $request;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										22
									
								
								app/Events/Setting/CategoryCreating.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								app/Events/Setting/CategoryCreating.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use Illuminate\Queue\SerializesModels;
 | 
			
		||||
 | 
			
		||||
class CategoryCreating
 | 
			
		||||
{
 | 
			
		||||
    use SerializesModels;
 | 
			
		||||
 | 
			
		||||
    public $request;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $request
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($request)
 | 
			
		||||
    {
 | 
			
		||||
        $this->request = $request;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										20
									
								
								app/Events/Setting/CategoryDeleted.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								app/Events/Setting/CategoryDeleted.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,20 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Event;
 | 
			
		||||
 | 
			
		||||
class CategoryDeleted extends Event
 | 
			
		||||
{
 | 
			
		||||
    public $category;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $category
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($category)
 | 
			
		||||
    {
 | 
			
		||||
        $this->category = $category;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										20
									
								
								app/Events/Setting/CategoryDeleting.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								app/Events/Setting/CategoryDeleting.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,20 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Event;
 | 
			
		||||
 | 
			
		||||
class CategoryDeleting extends Event
 | 
			
		||||
{
 | 
			
		||||
    public $category;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $category
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($category)
 | 
			
		||||
    {
 | 
			
		||||
        $this->category = $category;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										24
									
								
								app/Events/Setting/CategoryUpdated.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								app/Events/Setting/CategoryUpdated.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Event;
 | 
			
		||||
 | 
			
		||||
class CategoryUpdated extends Event
 | 
			
		||||
{
 | 
			
		||||
    public $category;
 | 
			
		||||
 | 
			
		||||
    public $request;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $category
 | 
			
		||||
     * @param $request
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($category, $request)
 | 
			
		||||
    {
 | 
			
		||||
        $this->category = $category;
 | 
			
		||||
        $this->request  = $request;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										24
									
								
								app/Events/Setting/CategoryUpdating.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								app/Events/Setting/CategoryUpdating.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Events\Setting;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Event;
 | 
			
		||||
 | 
			
		||||
class CategoryUpdating extends Event
 | 
			
		||||
{
 | 
			
		||||
    public $category;
 | 
			
		||||
 | 
			
		||||
    public $request;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new event instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @param $category
 | 
			
		||||
     * @param $request
 | 
			
		||||
     */
 | 
			
		||||
    public function __construct($category, $request)
 | 
			
		||||
    {
 | 
			
		||||
        $this->category = $category;
 | 
			
		||||
        $this->request  = $request;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user