fix skit2

This commit is contained in:
hafifierahman
2022-03-22 02:28:17 +08:00
parent 6088dfad46
commit a92d37df91
3 changed files with 70 additions and 28 deletions
+58 -27
View File
@@ -504,12 +504,9 @@
<th class="px-5 py-3 border-b-2 border-gray-200 bg-gray-100 text-left text-xs font-semibold text-gray-600 uppercase tracking-wider">
Jumlah Mohon (RM)
</th>
<th class="px-5 py-3 border-b-2 border-gray-200 bg-gray-100 text-left text-xs font-semibold text-gray-600 uppercase tracking-wider">
Bayaran Balik (RM)
</th>
<th class="px-5 py-3 border-b-2 border-gray-200 bg-gray-100 text-left text-xs font-semibold text-gray-600 uppercase tracking-wider">
<!-- <th class="px-5 py-3 border-b-2 border-gray-200 bg-gray-100 text-left text-xs font-semibold text-gray-600 uppercase tracking-wider">
Status
</th>
</th> -->
<th class="px-5 py-3 border-b-2 border-gray-200 bg-gray-100 text-left text-xs font-semibold text-gray-600 uppercase tracking-wider">
Jenis Permohonan
</th>
@@ -519,12 +516,11 @@
</tr>
</thead>
<tbody>
<tr>
<tr v-for="(mohon,i) in showpermohonan.data" :key="i">
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
Kota Bharu 2
<p class="text-gray-900 whitespace-no-wrap" v-text="mohon.kodcaw">
</p>
</div>
</div>
@@ -532,8 +528,7 @@
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
ARKB120191020-1425
<p class="text-gray-900 whitespace-no-wrap" v-text="mohon.nopermohonan">
</p>
</div>
</div>
@@ -541,7 +536,7 @@
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
<p class="text-gray-900 whitespace-no-wrap" v-text="mohon.tarikh_permohonan">
s2019-19-20
</p>
</div>
@@ -550,22 +545,12 @@
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
50000
<p class="text-gray-900 whitespace-no-wrap" v-text="formatterfunction(mohon.amaun_mohon)">
</p>
</div>
</div>
</td>
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
0.00
</p>
</div>
</div>
</td>
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<!-- <td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
@@ -573,11 +558,11 @@
</p>
</div>
</div>
</td>
</td> -->
<td class="px-5 py-5 border-b border-gray-200 bg-white text-sm">
<div class="flex items-center">
<div class="ml-3">
<p class="text-gray-900 whitespace-no-wrap">
<p :class="mohon.jenismohon == 'permohonanwang' ? 'bg-green-500' : 'bg-red-500'" class="text-white whitespace-no-wrap p-2 rounded" v-text="checkjenismohon(mohon.jenismohon)">
Permohonan Wang
</p>
</div>
@@ -587,7 +572,7 @@
<div class="flex items-center">
<div class="ml-3">
<div class="border border-yellow-600 text-yellow-600 font-montserrat py-2 px-4 font-medium rounded-xl hover:bg-yellow-600 hover:text-white transition-all duration-300">
<router-link to="/permohonan/status">
<router-link :to="{ name: 'permohonanstatus', params: { mohonid: mohon.mohonid }}">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-card-checklist" viewBox="0 0 16 16">
<path d="M14.5 3a.5.5 0 0 1 .5.5v9a.5.5 0 0 1-.5.5h-13a.5.5 0 0 1-.5-.5v-9a.5.5 0 0 1 .5-.5h13zm-13-1A1.5 1.5 0 0 0 0 3.5v9A1.5 1.5 0 0 0 1.5 14h13a1.5 1.5 0 0 0 1.5-1.5v-9A1.5 1.5 0 0 0 14.5 2h-13z"/>
<path d="M7 5.5a.5.5 0 0 1 .5-.5h5a.5.5 0 0 1 0 1h-5a.5.5 0 0 1-.5-.5zm-1.496-.854a.5.5 0 0 1 0 .708l-1.5 1.5a.5.5 0 0 1-.708 0l-.5-.5a.5.5 0 1 1 .708-.708l.146.147 1.146-1.147a.5.5 0 0 1 .708 0zM7 9.5a.5.5 0 0 1 .5-.5h5a.5.5 0 0 1 0 1h-5a.5.5 0 0 1-.5-.5zm-1.496-.854a.5.5 0 0 1 0 .708l-1.5 1.5a.5.5 0 0 1-.708 0l-.5-.5a.5.5 0 0 1 .708-.708l.146.147 1.146-1.147a.5.5 0 0 1 .708 0z"/>
@@ -601,10 +586,56 @@
</tr>
</tbody>
</table>
<pagination :data="paginate" @clickEvent_="getSenaraiMohon"></pagination>
</div>
</template>
<script>
import pagination from '../components/pagination.vue'
const formatter = new Intl.NumberFormat('en-US', {
minimumFractionDigits: 2
});
export default {
components: {
pagination
},
data(){
return{
showpermohonan:[],
currentPage:1,
paginate: []
}
},
created() {
this.getSenaraiMohon(this.currentPage)
},
methods:{
getSenaraiMohon(pageNumber){
this.axios.get(this.$hostname + '/admin/permohonan/get/admin',{
params: {
page: pageNumber
}
}).then(response => {
this.showpermohonan = response.data
this.paginate = response.data
this.currentPage = pageNumber
});
},
formatterfunction(value){
return formatter.format(value)
},
checkjenismohon(value){
if(value === 'permohonanwang')
{
return 'Permohonan Wang'
}else{
return 'Bayaran Balik'
}
}
}
}
</script>
+11
View File
@@ -363,6 +363,17 @@
<script>
export default {
data(){
return{
mohonid: this.$route.params.mohonid,
}
},
created(){
console.log(this.mohonid);
},
methods:{
}
}
</script>
+1 -1
View File
@@ -58,7 +58,7 @@ export default new VueRouter({
{ name: 'bajetkemaskini',path: '/bajet/kemaskini/:id', component: BajetKemaskini },
{ path: '/permohonan', component: SenaraiMohon },
{ path: '/permohonan/status', component: StatusMohon },
{ name: 'permohonanstatus',path: '/permohonan/status/:mohonid', component: StatusMohon },
],
mode: 'history'