Skip to content

Commit

Permalink
drop delete from Jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
temaotl committed Jun 10, 2024
1 parent fa807c5 commit 62659fa
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions app/Http/Controllers/FederationController.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@

use App\Http\Requests\StoreFederation;
use App\Http\Requests\UpdateFederation;
use App\Jobs\GitAddFederation;
use App\Jobs\GitAddMembers;
use App\Jobs\GitDeleteFederation;
use App\Jobs\GitDeleteMembers;
use App\Jobs\GitUpdateFederation;
use App\Models\Entity;
Expand Down Expand Up @@ -212,12 +210,14 @@ public function update(UpdateFederation $request, Federation $federation)
$state = $federation->trashed() ? 'deleted' : 'restored';
$color = $federation->trashed() ? 'red' : 'green';

if ($federation->trashed()) {
//TODO ask about what we want to do with cfg and tag files

/* if ($federation->trashed()) {
GitDeleteFederation::dispatch($federation, Auth::user());
} else {
//TODO ask about what we want to do with cfg and tag files
// GitAddFederation::dispatch($federation, 'state', Auth::user());
}
GitAddFederation::dispatch($federation, 'state', Auth::user());
}*/

Notification::send($federation->operators, new FederationStateChanged($federation));
Notification::send(User::activeAdmins()->select('id', 'email')->get(), new FederationStateChanged($federation));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
use Illuminate\Support\Facades\Mail;
use Throwable;

class GitDeleteFederation implements ShouldQueue
class Old_GitDeleteFederation implements ShouldQueue
{
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels, GitTrait;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

use App\Jobs\Old_GitAddFederation;
use App\Jobs\GitAddMembers;
use App\Jobs\GitDeleteFederation;
use App\Jobs\Old_GitDeleteFederation;
use App\Jobs\GitDeleteMembers;
use App\Jobs\GitUpdateFederation;
use App\Models\Entity;
Expand Down

0 comments on commit 62659fa

Please sign in to comment.