Loop to upload DRP docs
This commit is contained in:
parent
0e52d2d93c
commit
873f5339fb
@ -12,7 +12,7 @@
|
||||
title="Upload Dokumen Pendukung"
|
||||
>
|
||||
<template #content>
|
||||
<PopUpUploadDokumenPendukung :drpId="selectedDrpId" :drpTahun="selectedDrpTahun" @addDokumenRKAP="addDokumenRKAP" @addDokumenPendukung="addDokumenPendukung" />
|
||||
<PopUpUploadDokumenPendukung v-if="isPopupUploadDokumenPendukung" :drpId="selectedDrpId" :drpTahun="selectedDrpTahun" @addDokumenRKAP="addDokumenRKAP" @addDokumenPendukung="addDokumenPendukung" />
|
||||
</template>
|
||||
<DxToolbarItem
|
||||
widget="dxButton"
|
||||
@ -176,6 +176,7 @@ const approveStatus = [
|
||||
];
|
||||
|
||||
const URL = process.env.VUE_APP_ROOT_API + "/drp";
|
||||
const URL_UPLOAD = process.env.VUE_APP_ROOT_API + "/drp/upload/dokumen";
|
||||
|
||||
const dataSource = new CustomStore({
|
||||
key: "id",
|
||||
@ -276,6 +277,11 @@ export default {
|
||||
save() {
|
||||
|
||||
const dataDrpDokumen = this.dataDrpDokumen.map(item => {
|
||||
|
||||
http.post(URL_UPLOAD, item.formData)
|
||||
.then((res) => res.json())
|
||||
.then((json) => console.log(json))
|
||||
|
||||
return {
|
||||
jenisDokumenId : item.jenisDokumenId,
|
||||
filename : item.filename,
|
||||
@ -284,6 +290,11 @@ export default {
|
||||
});
|
||||
|
||||
const dataDrpDokumenPendukung = this.dataDrpDokumenPendukung.map(item => {
|
||||
|
||||
http.post(URL_UPLOAD, item.formData)
|
||||
.then((res) => res.json())
|
||||
.then((json) => console.log(json))
|
||||
|
||||
return {
|
||||
jenisDokumenId : item.jenisDokumenId,
|
||||
filename : item.filename,
|
||||
|
Loading…
x
Reference in New Issue
Block a user