added akru bulanan pecahan
This commit is contained in:
@@ -146,7 +146,7 @@
|
||||
</router-link>
|
||||
</div>
|
||||
<div class="bg-white ml-2 shadow border border-solid px-6 py-4 rounded-lg hover:bg-yellow-300 hover:transition-all mb-2 cursor-pointer">
|
||||
<router-link to="/akaunhome/akrubulan">
|
||||
<router-link to="/akaunhome/akrubulanpecahan">
|
||||
<h2 class="mx-auto text-center font-bold text-2xl uppercase">Akru Bulanan Pecahan</h2>
|
||||
</router-link>
|
||||
</div>
|
||||
|
||||
@@ -1,42 +1,244 @@
|
||||
<template>
|
||||
<div class="container">
|
||||
|
||||
<div class="flex w-full">
|
||||
<div class="xl:w-2/3 2xl:w-1/2 p-8 mx-auto">
|
||||
<div class="bg-yellow-600 text-gray-200 text-lg px-6 py-4 rounded-t-lg">
|
||||
<router-link to="/akaunhome">
|
||||
<div class="container">
|
||||
<div class="flex w-full">
|
||||
<div class="xl:w-2/3 2xl:w-1/2 p-8 mx-auto">
|
||||
<div
|
||||
class="bg-yellow-600 text-gray-200 text-lg px-6 py-4 rounded-t-lg"
|
||||
>
|
||||
<router-link to="/akaunhome">
|
||||
<i class="fas fa-backspace text-white"></i>
|
||||
</router-link>
|
||||
<span class="text-center mx-auto text-white font-bold">Imbang Duga</span>
|
||||
<span class="text-center mx-auto text-white font-bold"
|
||||
>Imbang Duga</span
|
||||
>
|
||||
</div>
|
||||
<form method="get" id="formgadaian" :action="Urlredirect()" target="_blank">
|
||||
<form
|
||||
method="get"
|
||||
id="formgadaian"
|
||||
:action="Urlredirect()"
|
||||
target="_blank"
|
||||
>
|
||||
<div class="rounded bg-white shadow p-6">
|
||||
<div class="pb-6">
|
||||
<label for="username" class="font-semibold text-gray-700 block pb-1">Tarikh</label>
|
||||
<label
|
||||
for="username"
|
||||
class="font-semibold text-gray-700 block pb-1"
|
||||
>Tarikh</label
|
||||
>
|
||||
<div class="flex">
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datetarikh" @change="dateChecking()" class="border border-l-0 rounded-r px-4 py-2 w-1/2 mr-2" type="date" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border rounded-l px-4 py-2 whitespace-no-wrap">Hingga</span>
|
||||
<input id="tarikhhingga" name="datehingga" @change="dateChecking()" class="border border-l-0 rounded-r px-4 py-2 w-1/2 mr-2" type="date"/>
|
||||
|
||||
<span
|
||||
style="background-color: #f9fafb"
|
||||
class="text-gray-600 border rounded-l px-4 py-2 whitespace-no-wrap"
|
||||
>Mula</span
|
||||
>
|
||||
<input
|
||||
id="tarikhmula"
|
||||
name="datetarikh"
|
||||
@change="dateChecking"
|
||||
v-model="tarikhmula"
|
||||
class="border border-l-0 rounded-r px-4 py-2 w-1/2 mr-2"
|
||||
type="date"
|
||||
/>
|
||||
<span
|
||||
style="background-color: #f9fafb"
|
||||
class="text-gray-600 border rounded-l px-4 py-2 whitespace-no-wrap"
|
||||
>Hingga</span
|
||||
>
|
||||
<input
|
||||
id="tarikhhingga"
|
||||
name="datehingga"
|
||||
v-model="tarikhhingga"
|
||||
@change="dateChecking"
|
||||
class="border border-l-0 rounded-r px-4 py-2 w-1/2 mr-2"
|
||||
type="date"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end mt-5">
|
||||
<!-- <button @click.prevent="generatepdf" class=" mr-2 border border-yellow-600 text-yellow-600 font-montserrat py-2 px-8 font-medium rounded-xl hover:bg-yellow-600 hover:text-white transition-all duration-300"><i class="fas fa-file-pdf mr-2"></i>PDF</button> -->
|
||||
<button @click.prevent="generateview" class="border border-yellow-600 text-yellow-600 font-montserrat py-2 px-8 font-medium rounded-xl hover:bg-yellow-600 hover:text-white transition-all duration-300"><i class="fas fa-eye mr-2"></i>Cari</button>
|
||||
<button
|
||||
@click.prevent="getImbangDuga(1)"
|
||||
class="border border-yellow-600 text-yellow-600 font-montserrat py-2 px-8 font-medium rounded-xl hover:bg-yellow-600 hover:text-white transition-all duration-300"
|
||||
>
|
||||
<i class="fas fa-eye mr-2"></i>Cari
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container mx-auto px-5 my-10">
|
||||
<modal ref="modal"></modal>
|
||||
<table class="min-w-full leading-normal">
|
||||
<thead class="text-center">
|
||||
<tr>
|
||||
<th
|
||||
class="px-4 py-8 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
></th>
|
||||
<th
|
||||
class="px-4 py-8 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Bil
|
||||
</th>
|
||||
<th
|
||||
class="px-4 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Tarikh
|
||||
</th>
|
||||
<th
|
||||
class="px-4 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Kod Caw
|
||||
</th>
|
||||
<th
|
||||
class="px-4 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Tanggungan Semasa
|
||||
</th>
|
||||
<th
|
||||
class="px-4 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Harta Semasa
|
||||
</th>
|
||||
<th
|
||||
class="px-4 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Tag Telly
|
||||
</th>
|
||||
<th
|
||||
class="px-10 py-6 border-b-2 border-gray-200 bg-gray-100 text-left text-sm font-semibold text-gray-600 uppercase tracking-wider"
|
||||
>
|
||||
Act
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(imbangduga, i) in showimbangduga.data" :key="i">
|
||||
<td
|
||||
class="px-5 py-5 border-b border-gray-200 bg-white text-sm"
|
||||
>
|
||||
|
||||
</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"
|
||||
v-text="showimbangduga.from + i"
|
||||
></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"
|
||||
v-text="imbangduga.tarikh"
|
||||
></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"
|
||||
v-text="imbangduga.kodcaw"
|
||||
></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"
|
||||
v-text="
|
||||
formatterfunction(
|
||||
imbangduga.totaltanggungan
|
||||
)
|
||||
"
|
||||
></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"
|
||||
v-text="
|
||||
formatterfunction(
|
||||
imbangduga.totalharta
|
||||
)
|
||||
"
|
||||
></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">
|
||||
<span
|
||||
:class="{
|
||||
'bg-green-100 text-green-800 border-green-400 dark:text-green-400':
|
||||
imbangduga.tagtally,
|
||||
}"
|
||||
class="bg-red-100 text-red-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-gray-700 dark:text-red-400 border border-red-400"
|
||||
>          </span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td
|
||||
class="px-5 py-5 border-b border-gray-200 bg-white text-sm"
|
||||
>
|
||||
<button
|
||||
@click="action('2024', 'kb2')"
|
||||
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"
|
||||
>
|
||||
<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 1 1 .708-.708l.146.147 1.146-1.147a.5.5 0 0 1 .708 0z"
|
||||
/>
|
||||
</svg>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<pagination
|
||||
:data="paginate"
|
||||
@clickEvent_="getImbangDuga"
|
||||
></pagination>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
<<<<<<< HEAD
|
||||
export default {
|
||||
|
||||
data(){
|
||||
@@ -162,4 +364,88 @@ export default {
|
||||
}
|
||||
|
||||
}
|
||||
=======
|
||||
import modal from "../components/util/ImbangdugaModal.vue";
|
||||
import pagination from "../components/pagination.vue";
|
||||
|
||||
const formatter = new Intl.NumberFormat("en-US", {
|
||||
minimumFractionDigits: 2,
|
||||
});
|
||||
|
||||
export default {
|
||||
components: {
|
||||
pagination,
|
||||
modal,
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
tarikhmula: "",
|
||||
tarikhhingga: "",
|
||||
|
||||
index: 0,
|
||||
leftToRight: true,
|
||||
imbangduga: [],
|
||||
PaginationLimit: 2,
|
||||
perPage: 5,
|
||||
totalPage: 0,
|
||||
currentPage: 1,
|
||||
lastPage: 5,
|
||||
showimbangduga: [],
|
||||
paginate: {},
|
||||
activePage: 1,
|
||||
showLoader: false,
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
Urlredirect: function () {
|
||||
return window.route("cetak.gadaian");
|
||||
},
|
||||
|
||||
dateChecking() {
|
||||
var tarikhMula = document.getElementById("tarikhmula");
|
||||
var tarikhHingga = document.getElementById("tarikhhingga");
|
||||
|
||||
var tarikh1 = new Date(tarikhMula.value);
|
||||
var tarikh2 = new Date(tarikhHingga.value);
|
||||
var Difference_In_Time = tarikh2.getTime() - tarikh1.getTime();
|
||||
var Difference_In_Days =
|
||||
Difference_In_Time / (1000 * 3600 * 24) + 1;
|
||||
|
||||
if (Difference_In_Days > 62) {
|
||||
this.$swal({
|
||||
text: "Sila Pilih Tarikh Kurang Dari 2 Bulan",
|
||||
icon: "error",
|
||||
allowEscapeKey: false,
|
||||
showCancelButton: false,
|
||||
showConfirmButton: true,
|
||||
});
|
||||
}
|
||||
},
|
||||
action(tarikhmula, kodcaw, tarikhhingga) {
|
||||
this.$refs.modal.showModal = true;
|
||||
},
|
||||
|
||||
getImbangDuga(pageNumber) {
|
||||
this.axios
|
||||
.get(this.$hostname + "/api/reports/balancesheets/get", {
|
||||
params: {
|
||||
kodcaw: this.$kodcaw,
|
||||
mula: this.tarikhmula,
|
||||
hingga: this.tarikhhingga,
|
||||
page: pageNumber,
|
||||
},
|
||||
})
|
||||
.then((response) => {
|
||||
this.showimbangduga = response.data;
|
||||
this.paginate = response.data;
|
||||
});
|
||||
},
|
||||
|
||||
formatterfunction(value) {
|
||||
return formatter.format(value);
|
||||
},
|
||||
},
|
||||
};
|
||||
>>>>>>> b29d4714 (added akru bulanan pecahan)
|
||||
</script>
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
</li>
|
||||
</a>
|
||||
|
||||
<a href="{{ route('tetapanaros') }}"
|
||||
{{-- <a href="{{ route('tetapanaros') }}"
|
||||
class="rounded mb-2 mr-2 {{ Route::is('tetapanaros') || Route::is('tetapanaros.*') ? 'bg-gray-200 rounded text-white-500' : 'hover:bg-yellow-300 ' }}">
|
||||
<li class="flex w-full justify-between text-gray-600 hover:text-gray-500 cursor-pointer items-center ">
|
||||
<div class="flex items-center">
|
||||
@@ -73,7 +73,7 @@
|
||||
<span class="ml-2 text-lg">Tetapan</span>
|
||||
</div>
|
||||
</li>
|
||||
</a>
|
||||
</a> --}}
|
||||
|
||||
<a href="{{ route('pelanggan') }}" class="rounded mb-2 mr-2 {{ Route::is('pelanggan') || Route::is('pelanggan.*') ? 'bg-gray-200 rounded text-white-500' : 'hover:bg-yellow-300 ' }}">
|
||||
<li class="flex w-full justify-between text-gray-600 hover:text-gray-500 cursor-pointer items-center ">
|
||||
|
||||
Reference in New Issue
Block a user