Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Perbaiki perintah menjalankan queue #769

Merged
merged 10 commits into from
Aug 17, 2023
17 changes: 9 additions & 8 deletions app/Http/Controllers/LogViewerController.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
use Illuminate\Support\Facades\Crypt;
use RachidLaasri\LaravelInstaller\Helpers\RequirementsChecker;
use Rap2hpoutre\LaravelLogViewer\LaravelLogViewer;
use Symfony\Component\HttpFoundation\Response;

/**
* Class LogViewerController
Expand Down Expand Up @@ -198,16 +199,16 @@ public function queueListen()
{
try {
Artisan::call('queue:work', ['--stop-when-empty' => null]); // this will do the command line job

return response()->json([
'status' => true,
'message' => 'success',
]);
} catch (\Exception $e) {
report($e);

return response()->json([
'status' => true,
'message' => $e->getMessage(),
]);
'error' => $e->getMessage()
], Response::HTTP_INTERNAL_SERVER_ERROR);
}

return response()->json([
'success' => true,
], Response::HTTP_OK);
}
}
3 changes: 2 additions & 1 deletion catatan_rilis.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ Di rilis v2308.0.1 berisi perbaikan yang diminta Komunitas OpenDK.
10. [#749](https://github.com/OpenSID/OpenDK/issues/749) Perbaikan breadcrumb pada halaman admin event.
11. [#750](https://github.com/OpenSID/OpenDK/issues/750) Perbaikan breadcrumb pada halaman admin artikel.
12. [#751](https://github.com/OpenSID/OpenDK/issues/751) Perbaikan breadcrumb pada halaman admin FAQ.
13. [#754](https://github.com/OpenSID/OpenDK/issues/754) Perbaikan notifikasi saat akses modul info sistem.

#### Teknis
1. [#12](https://github.com/OpenSID/wiki-keamanan/issues/12) Perbaikan keamanan modul bantuan.
2. [#13](https://github.com/OpenSID/wiki-keamanan/issues/13) Perbaikan kemanan modul desa.
3. [#11](https://github.com/OpenSID/wiki-keamanan/issues/11) Pembatasan input element HTML.
3. [#11](https://github.com/OpenSID/wiki-keamanan/issues/11) Pembatasan input element HTML.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
</a>
</div>
</div>
<p id="#ajaxProgress" style="display: none;">asdasd</p>
<div class="box-body">
@foreach($requirements['requirements'] as $type => $requirement)
<div class="form-group">
Expand Down Expand Up @@ -44,22 +45,28 @@
$.ajax({
type: "GET",
url: "{{ URL('setting/info-sistem/queuelisten') }}",
dataType: "Json"
beforeSend: function() {
Swal.showLoading()
},
success: function(data) {
Swal.fire({
position: 'center',
icon: 'success',
title: 'Perintah berhasil dijalankan',
showConfirmButton: false,
timer: 1500
})
},
error: function(xhr, status, error) {
Swal.fire({
position: 'center',
icon: 'error',
title: 'Perintah gagal dijalankan',
showConfirmButton: false,
timer: 1500
})
}
});
});

$(document)
.ajaxStart(function () {
Swal.showLoading()
})
.ajaxStop(function () {
Swal.fire({
position: 'center',
icon: 'success',
title: 'Perintah berhasil dijalankan',
showConfirmButton: false,
timer: 1500
})
});
</script>
@endpush