fix final
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 889 KiB |
@@ -27,29 +27,29 @@
|
||||
<option v-for="(bank,i) in jenisbank" :key="i" :value="bank.abbreviation">{{ bank.name }}</option>
|
||||
</select>
|
||||
<!-- <input v-model="selectedbank" type="text" class="mr-2 bg-white appearance-none border-2 border-gray-400 rounded w-full py-2 px-4 text-gray-700 leading-tight focus:outline-none focus:bg-white focus:border-blue-500 border-black" /> -->
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.selectedbank.required">Field is required</div>
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.selectedbank.required">Isi tempat kosong</div>
|
||||
|
||||
<label class="block uppercase tracking-wide text-gray-700 text-xs font-bold mb-2 mt-3">
|
||||
No Rujukan
|
||||
</label>
|
||||
<input v-model.trim="$v.noresit.$model" type="text" class="mr-2 bg-white appearance-none border-2 border-gray-400 rounded w-full py-2 px-4 text-gray-700 leading-tight focus:outline-none focus:bg-white focus:border-blue-500 border-black" />
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.noresit.required">Field is required</div>
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.noresit.required">Isi tempat kosong</div>
|
||||
|
||||
<label class="block uppercase tracking-wide text-gray-700 text-xs font-bold mb-2 mt-3">
|
||||
Kaedah Penghantaran
|
||||
</label>
|
||||
<select v-model.trim="$v.selectedjeniscit.$model" class="w-full p-2 rounded-md border bg-white border-gray-400 focus:outline-none rounded-md focus:ring-1 ring-cyan-500 uppercase">
|
||||
<option value="" selected disabled hidden>Sila Pilih Kaedah Penghantaranr***</option>
|
||||
<option value="" selected disabled hidden>Sila Pilih Kaedah Penghantaran***</option>
|
||||
<option value="CIT">Cash-in-Transit</option>
|
||||
<option value="TT">tellygraphic Transfer</option>
|
||||
</select>
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.selectedjeniscit.required">Field is required</div>
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.selectedjeniscit.required">Isi tempat kosong</div>
|
||||
|
||||
<label class="block uppercase tracking-wide text-gray-700 text-xs font-bold mb-2 mt-3">
|
||||
Nota
|
||||
</label>
|
||||
<input v-model.trim="$v.namacit.$model" type="text" class="mr-2 bg-white appearance-none border-2 border-gray-400 rounded w-full py-2 px-4 text-gray-700 leading-tight focus:outline-none focus:bg-white focus:border-blue-500 border-black" />
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.namacit.required">Field is required</div>
|
||||
<div class="text-red-500 text-xs italic" v-if="!$v.namacit.required">Isi tempat kosong</div>
|
||||
</div>
|
||||
<!--footer-->
|
||||
<div class="flex items-center justify-end p-6 border-t border-solid border-blueGray-200 rounded-b">
|
||||
@@ -100,6 +100,7 @@ export default {
|
||||
selectedjeniscit: '',
|
||||
noresit: '',
|
||||
namacit: '',
|
||||
submitStatus: '',
|
||||
jenisbank: {}
|
||||
}
|
||||
},
|
||||
@@ -116,27 +117,48 @@ export default {
|
||||
});
|
||||
},
|
||||
FuncHantar: function () {
|
||||
// console.log(this.selectedbank,this.noresit)
|
||||
axios.put(this.$hostname + '/admin/permohonan/updatebank', {
|
||||
kelulusan: 'Lulus',
|
||||
jenisbank: this.selectedbank,
|
||||
noresit: this.noresit,
|
||||
namacit: this.namacit,
|
||||
jeniscit: this.selectedjeniscit,
|
||||
mohonid: this.mohonid
|
||||
|
||||
}).then(response => {
|
||||
if (this.submitStatus == 'PENDING') {
|
||||
console.log(this.submitStatus);
|
||||
event.target.disabled = true;
|
||||
return;
|
||||
} else {
|
||||
console.log(this.submitStatus);
|
||||
event.target.disabled = false;
|
||||
}
|
||||
|
||||
if (response.data === 1) {
|
||||
this.showModal = false;
|
||||
this.$toast.success("Berjaya Meluluskan Permohonan Daripada Pengurus Besar!")
|
||||
this.$emit('clickEvent_', this.pageNumber)
|
||||
} else {
|
||||
this.$v.$touch()
|
||||
|
||||
if (this.$v.$invalid) {
|
||||
this.submitStatus = 'ERROR'
|
||||
this.$toast.error('Sila isi butiran yang disediakan dengan betul!')
|
||||
} else {
|
||||
// console.log(this.selectedbank,this.noresit)
|
||||
this.submitStatus = 'PENDING'
|
||||
setTimeout(() => {
|
||||
axios.put(this.$hostname + '/admin/permohonan/updatebank', {
|
||||
kelulusan: 'Lulus',
|
||||
jenisbank: this.selectedbank,
|
||||
noresit: this.noresit,
|
||||
namacit: this.namacit,
|
||||
jeniscit: this.selectedjeniscit,
|
||||
mohonid: this.mohonid
|
||||
|
||||
}).then(response => {
|
||||
|
||||
if (response.data === 1) {
|
||||
this.showModal = false;
|
||||
this.$toast.success("Berjaya Meluluskan Permohonan Bank!")
|
||||
this.$emit('clickEvent_', this.pageNumber)
|
||||
} else {
|
||||
|
||||
this.showModal = false;
|
||||
this.$toast.error("Tidak Berjaya!")
|
||||
}
|
||||
});
|
||||
}, 500)
|
||||
}
|
||||
|
||||
this.showModal = false;
|
||||
this.$toast.error("Tidak Berjaya!")
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
validations: {
|
||||
|
||||
@@ -146,6 +146,16 @@ export default {
|
||||
},
|
||||
FuncHantar: function () {
|
||||
|
||||
if(this.submitStatus == 'PENDING')
|
||||
{
|
||||
console.log(this.submitStatus);
|
||||
event.target.disabled = true;
|
||||
return;
|
||||
}else{
|
||||
console.log(this.submitStatus);
|
||||
event.target.disabled = false;
|
||||
}
|
||||
|
||||
this.$v.$touch()
|
||||
|
||||
if (this.$v.$invalid) {
|
||||
@@ -175,10 +185,11 @@ export default {
|
||||
|
||||
if (response.data === 1) {
|
||||
this.showModal = false;
|
||||
this.submitStatus = 'SIAP'
|
||||
this.$toast.success("Berjaya Meluluskan Permohonan Daripada Pengurus Besar!")
|
||||
this.$emit('clickEvent_', this.pageNumber)
|
||||
} else {
|
||||
|
||||
this.submitStatus = 'SIAP'
|
||||
this.showModal = false;
|
||||
this.$toast.error("Tidak Berjaya!")
|
||||
}
|
||||
@@ -187,7 +198,7 @@ export default {
|
||||
}, 500)
|
||||
}
|
||||
|
||||
console.log(this.submitStatus)
|
||||
// console.log(this.submitStatus)
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
|
||||
<title>Ar-Rahn | Admin Page</title>
|
||||
|
||||
<link rel="icon" type="image/x-icon" href="{{ asset('img/icon_pkb.png') }}" />
|
||||
|
||||
<!-- Fonts -->
|
||||
<link href="https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700&display=swap" rel="stylesheet">
|
||||
|
||||
@@ -170,15 +172,15 @@
|
||||
@endif
|
||||
<form class="login-form" method="POST" action="{{ route('login') }}">
|
||||
@csrf
|
||||
<input type="text" placeholder="email" name="email"/>
|
||||
<input type="text" placeholder="emel" name="email"/>
|
||||
@error('email')
|
||||
<p style="color:#d63031;font-size: 11px;font-style: italic;font-weight: bold;margin-top:0;" >{{ $message }}</p>
|
||||
<p style="color:#d63031;font-size: 11px;font-style: italic;font-weight: bold;margin-top:0;" >*Sila pastikan emel anda betul</p>
|
||||
@enderror
|
||||
<input type="password" placeholder="password" name="password"/>
|
||||
<input type="password" placeholder="katalaluan" name="password"/>
|
||||
@error('password')
|
||||
<p style="color:#d63031;font-size: 11px;font-style: italic;font-weight: bold;margin-top:0;">{{ $message }}</p>
|
||||
<p style="color:#d63031;font-size: 11px;font-style: italic;font-weight: bold;margin-top:0;">*Sila pastikan katalaluan anda betul</p>
|
||||
@enderror
|
||||
<button>DAFTAR MASUK</button>
|
||||
<button>Daftar Masuk</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user