fix main
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
<div class="flex">
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datetimepicker1" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
<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>
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
<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 border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datetarikh" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
|
||||
@@ -11,11 +11,12 @@
|
||||
|
||||
<span class="text-center mx-auto text-white font-bold">Laporan Imbang Duga</span>
|
||||
</div>
|
||||
<form method="get" ref="formimbangduga" :action="Urlredirect()" target="iframe_laporan">
|
||||
<form method="get" name="formimbangduga" ref="formimbangduga" :action="Urlredirect()" target="iframe_laporan">
|
||||
<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>
|
||||
<div class="flex">
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
@@ -28,6 +29,7 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <iframe class="overflow-x-hidden overflow-y-auto fixed inset-0 z-50 outline-none focus:outline-none justify-center items-center flex bg-white" name="iframe_laporan" width="500" height="500"></iframe> -->
|
||||
<div v-if="showModal" class="overflow-x-hidden overflow-y-auto fixed inset-0 z-50 outline-none focus:outline-none justify-center items-center flex">
|
||||
<div class="relative w-1/2 my-6 mx-auto max-w-6xl">
|
||||
@@ -39,16 +41,19 @@
|
||||
<div id="loading" v-show="showLoader" class="flex justify-center mt-10" :style="{visibility: showLoader ? 'visible' : 'hidden'}" >
|
||||
<img id="loading-image" src="/img/loader.gif" alt="Loading..." />
|
||||
</div>
|
||||
<vue-iframe :style="{visibility: showLoader ? 'hidden' : 'visible'}"
|
||||
:src="Urlredirect()"
|
||||
frame-id="iframe_laporan"
|
||||
|
||||
<!-- <vue-iframe :style="{visibility: showLoader ? 'hidden' : 'visible'}"
|
||||
:src="urlHostname()"
|
||||
frame-id="my-ifram"
|
||||
@load="onLoad"
|
||||
@iframe-load="LoadedReady"
|
||||
name="iframe_laporan"
|
||||
width="500px"
|
||||
height="300px"
|
||||
scrolling="true"
|
||||
/>
|
||||
<!-- <iframe :style="{visibility: showLoader ? 'hidden' : 'visible'}" name="iframe_laporan" scrolling="true" :load="onLoad()"></iframe> -->
|
||||
/> -->
|
||||
|
||||
<iframe :style="{visibility: showLoader ? 'hidden' : 'visible'}" name="iframe_laporan" scrolling="true" :load="onLoad()"></iframe>
|
||||
</div>
|
||||
<!--footer-->
|
||||
<div class="flex items-center justify-end p-6 border-t border-solid border-blueGray-200 rounded-b">
|
||||
@@ -108,25 +113,33 @@ export default {
|
||||
// });
|
||||
this.showModal = true;
|
||||
|
||||
|
||||
},
|
||||
toggleModal: function(){
|
||||
this.showLoader = true
|
||||
this.pendingStatus = 'none'
|
||||
this.showModal = !this.showModal;
|
||||
},
|
||||
onLoad() {
|
||||
this.$refs.formimbangduga.submit()
|
||||
// this.myIframe = frame.contentWindow
|
||||
setTimeout(() => {
|
||||
async onLoad() {
|
||||
await this.$refs.formimbangduga.submit()
|
||||
console.log('loaded')// this.myIframe = frame.contentWindow
|
||||
|
||||
},
|
||||
async LoadedReady(){
|
||||
console.log('loadedready')
|
||||
await setTimeout(() => {
|
||||
this.showLoader = false
|
||||
this.pendingStatus = 'ok'
|
||||
}, 8000);
|
||||
}, 10000);
|
||||
},
|
||||
Urlredirect: function() {
|
||||
return window.route('cetak.imbangduga')
|
||||
},
|
||||
setJenis: function(value){
|
||||
return this.jenisgenerate = value;
|
||||
},
|
||||
urlHostname: function(){
|
||||
return document.location.origin + '/iframe';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
<div class="rounded bg-white shadow p-6">
|
||||
<div class="pb-6">
|
||||
<div class="flex place-content-center mb-2">
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
@@ -103,15 +104,12 @@ export default {
|
||||
|
||||
// });
|
||||
this.showModal = true;
|
||||
|
||||
this.$refs.formlejeram.submit()
|
||||
|
||||
},
|
||||
toggleModal: function(){
|
||||
this.showModal = !this.showModal;
|
||||
},
|
||||
onLoad(frame) {
|
||||
this.$refs.formlejeram.submit()
|
||||
async onLoad(frame) {
|
||||
await this.$refs.formlejeram.submit()
|
||||
this.myIframe = frame.contentWindow
|
||||
console.log('loaded')
|
||||
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
<!-- <label for="username" class="font-semibold text-gray-700 block pb-1">Tarikh</label> -->
|
||||
<div class="flex place-content-center mb-2">
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datemula" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Hingga</span>
|
||||
|
||||
@@ -18,6 +18,8 @@
|
||||
<label for="username" class="font-semibold text-gray-700 block pb-1">Tarikh</label>
|
||||
<div class="flex">
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datetarikh" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
<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>
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
<label for="username" class="font-semibold text-gray-700 block pb-1">Tarikh</label>
|
||||
<div class="flex">
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datetimepicker1" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
<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>
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
<div class="flex justify-center mb-4">
|
||||
<input :value="jenisgenerate" type="hidden" name="jenis" />
|
||||
<input :value="$kodcaw" name="kodcaw" hidden/>
|
||||
<input :value="$hostname" name="hostname" hidden/>
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Mula</span>
|
||||
<input id="tarikhmula" name="datemula" class="border border-2 border-l-0 rounded-r px-4 py-2 w-80r mr-2" type="date" />
|
||||
<span style="background-color: #F9FAFB" class="text-gray-600 border border-2 rounded-l px-4 py-2 whitespace-no-wrap">Hingga</span>
|
||||
|
||||
Vendored
+5
-6
@@ -23,8 +23,6 @@ import VueIframe from 'vue-iframes'
|
||||
import VueSweetalert2 from 'vue-sweetalert2';
|
||||
import 'sweetalert2/dist/sweetalert2.min.css';
|
||||
|
||||
Vue.use(VueSweetalert2);
|
||||
Vue.use(VueIframe)
|
||||
|
||||
require('./bootstrap');
|
||||
|
||||
@@ -57,7 +55,8 @@ Vue.component('jw-pagination', JwPagination)
|
||||
Vue.use(Toast, options)
|
||||
Vue.use(datetime)
|
||||
Vue.use(VueContentPlaceholders)
|
||||
|
||||
Vue.use(VueSweetalert2);
|
||||
Vue.use(VueIframe)
|
||||
|
||||
|
||||
Alpine.start()
|
||||
@@ -70,15 +69,15 @@ Vue.use(require('vue-pusher'), {
|
||||
}
|
||||
});
|
||||
|
||||
// Vue.prototype.$hostname = 'http://api.arrahn'
|
||||
Vue.prototype.$api1 = 'http://api.arrahn'
|
||||
|
||||
let initial = 'KB2';
|
||||
let initialhostname = 'http://localhost:8000';
|
||||
let initialhostname = 'http://api.arrahn';
|
||||
|
||||
const store = new Vuex.Store({
|
||||
state: {
|
||||
$kodcaw: 'KB2',
|
||||
$hostname: 'http://localhost:8000'
|
||||
$hostname: 'http://api.arrahn'
|
||||
},
|
||||
plugins: [createPersistedState()],
|
||||
mutations: {
|
||||
|
||||
@@ -275,11 +275,12 @@ export default {
|
||||
})
|
||||
},
|
||||
getDataKeuntungan(){
|
||||
this.axios.get(this.$hostname + '/admin/keuntunganToday', {
|
||||
this.axios.get(this.$api1 + '/admin/keuntunganToday', {
|
||||
params: {
|
||||
kodcaw: this.$kodcaw
|
||||
}
|
||||
}).then(response => {
|
||||
console.log(this.$api1)
|
||||
this.keuntunganharian = formatter.format(response.data[0].upahToday),
|
||||
this.bajetkeuntungan = formatter.format(response.data[0].bajetharian.toFixed(2)),
|
||||
this.percentkeuntungan = response.data[0].percentDiff,
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
// this.sethostname(this.caw)
|
||||
this.pembahagiancawangan(this.caw)
|
||||
this.$forceUpdate();
|
||||
|
||||
console.log(this.$hostname)
|
||||
if(this.akaun =='no')
|
||||
location.reload();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user