add permohonana
This commit is contained in:
@@ -112,7 +112,13 @@ class KelulusanController extends Controller
|
||||
|
||||
public function download(Request $request)
|
||||
{
|
||||
|
||||
return Storage::download('public/kelulusanpb/'.$request->image);
|
||||
$download = Http::get(config('api.url').'/admin/permohonan/viewfiles',[
|
||||
'files_id' => $request->files_id
|
||||
])->json();
|
||||
|
||||
return response(base64_decode($download['data']), 200, [
|
||||
'Content-type' => 'application/' . $download['type'],
|
||||
'Content-Disposition' => 'inline; filename='.$download['filename']
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -267,11 +267,23 @@
|
||||
|
||||
<p v-if="status.statusid === 4" class="text-gray-900 whitespace-no-wrap">
|
||||
{{ status.description }} <br> {{ 'JUMLAH DILULUSKAN : RM ' + formatterfunction(status[0].jumlah_diluluskan) }}
|
||||
<br>
|
||||
<button class="text-white p-2 bg-blue-500 rounded mr-1 mt-2" @click.prevent="downloadpb(status[0].pbfiles)">Muat Turun</button>
|
||||
</p>
|
||||
|
||||
<p v-if="status.statusid === 5" class="text-gray-900 whitespace-no-wrap">
|
||||
{{ status.description }} <br> {{ 'JENIS BANK : ' + status[0].jenisbank }} <br> {{ 'NO RESIT :' + status[0].noresit }}
|
||||
</p>
|
||||
<div v-if="status.statusid === 5" class="text-gray-900 whitespace-no-wrap">
|
||||
{{ status.description }}
|
||||
<br>
|
||||
<div class="w-full">
|
||||
<span class="w-1/2">{{ 'JENIS BANK : ' + status[0].jenisbank }}</span>
|
||||
<span class="w-1/2">{{ 'JENIS CIT : ' + status[0].jeniscit }}</span>
|
||||
</div>
|
||||
<br>
|
||||
<div class="w-full">
|
||||
<span class="w-1/2">{{ 'NO RESIT :' + status[0].noresit }}</span>
|
||||
<span class="w-1/2">{{ 'NAMA SYARIKAT :' + status[0].namasyarikat }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<p v-if="status.statusid === 6" class="text-gray-900 whitespace-no-wrap">
|
||||
{{ status.description }} <br> {{ 'NAMA PENERIMA : ' + status[0].nama_penerima }}
|
||||
@@ -282,7 +294,10 @@
|
||||
</p>
|
||||
|
||||
<p v-if="status.statusid === 8" class="text-gray-900 whitespace-no-wrap">
|
||||
{{ status.description }} <br> {{ 'JENIS BANK : ' + status[0].jenisbank }}
|
||||
{{ status.description }} <br> {{ 'JENIS BANK : ' + status[0].jenisbank }}
|
||||
<br>
|
||||
<button class="text-white p-2 bg-blue-500 rounded mr-1 mt-2" @click.prevent="downloadresit(status[0].resitfiles)">Muat Turun Resit</button>
|
||||
<button class="text-white p-2 bg-blue-500 rounded mt-2" @click.prevent="downloadinvoice(status[0].invoicefiles)">Muat Turun Invoice</button>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
@@ -457,6 +472,15 @@ export default {
|
||||
formatterfunction(value) {
|
||||
return formatter.format(value)
|
||||
},
|
||||
downloadresit(resitid) {
|
||||
window.open('/api/check/muatturun?files_id=' + resitid, '_blank');
|
||||
},
|
||||
downloadinvoice(invoiceid) {
|
||||
window.open('/api/check/muatturun?files_id=' + invoiceid, '_blank');
|
||||
},
|
||||
downloadpb(pbid) {
|
||||
window.open('/api/check/muatturun?files_id=' + pbid, '_blank');
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -16,14 +16,6 @@ use Illuminate\Support\Facades\Http;
|
||||
|
||||
Route::get('/iframe', function () {
|
||||
|
||||
$cawangan=Http::get(config('api.url').'/admin/permohonan/viewfiles',[
|
||||
'files_id' => 1
|
||||
])->json();
|
||||
|
||||
return response(base64_decode($cawangan['data']), 200, [
|
||||
'Content-type' => 'application/' . $cawangan['type'],
|
||||
'Content-Disposition' => 'inline; filename='.$cawangan['filename']
|
||||
]);
|
||||
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user