diff --git a/test/vuex/acc-one-faktur-v4/components/listing.vue b/test/vuex/acc-one-faktur-v4/components/listing.vue index 51adefc..2ca080c 100644 --- a/test/vuex/acc-one-faktur-v4/components/listing.vue +++ b/test/vuex/acc-one-faktur-v4/components/listing.vue @@ -96,7 +96,7 @@ Rp. {{ toRupiah(props.item.SupplierInvoiceGrandTotal) }} {{ props.item.SupplierInvoiceStatus }} - + @@ -377,6 +373,14 @@ + @@ -415,9 +419,14 @@ module.exports = { "dialog-item-confirm": httpVueLoader("./dialogItemConfirm.vue"), "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDeleteRequest: "", dialogAlertDeleteRequest: false, dialogAlertDeleteDetail: false, @@ -935,6 +944,15 @@ module.exports = { this.$store.dispatch("requester/getItemOuts", { ioID: val.T_ItemOutID }); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_pengeluaran_barang/pdf?id=" + val.T_ItemOutID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, diff --git a/test/vuex/acc-one-item-usage-v3/components/itemUsedList.vue b/test/vuex/acc-one-item-usage-v3/components/itemUsedList.vue index d2f84ac..1b96b41 100644 --- a/test/vuex/acc-one-item-usage-v3/components/itemUsedList.vue +++ b/test/vuex/acc-one-item-usage-v3/components/itemUsedList.vue @@ -38,6 +38,9 @@ >DAFTAR ITEM DIGUNAKAN + + print +
@@ -317,6 +320,14 @@ +
@@ -346,9 +357,14 @@ module.exports = { components: { "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, headers: [ { text: "TANGGAL/NO", @@ -684,6 +700,23 @@ module.exports = { enddate: this.$store.state.used.fEndDate }; this.$store.dispatch("used/confirmItemUsed", prm); + }, + printout() { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + + let division_id = this.$store.state.usage.selectedDivision && this.$store.state.usage.selectedDivision.DivisionID + ? this.$store.state.usage.selectedDivision.DivisionID + : 0; + + let start_date = this.$store.state.used.fStartDate || moment(new Date()).format("YYYY-MM-DD"); + let end_date = this.$store.state.used.fEndDate || moment(new Date()).format("YYYY-MM-DD"); + + this.urlprint = BASE_URL + "/one-api/report/rpt_pemakaian_item_divisi/pdf?start_date=" + start_date + "&end_date=" + end_date + "&division_id=" + division_id + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, }; diff --git a/test/vuex/acc-one-mutasi-handover/components/mutasiListing.vue b/test/vuex/acc-one-mutasi-handover/components/mutasiListing.vue index 300a930..2e763f9 100644 --- a/test/vuex/acc-one-mutasi-handover/components/mutasiListing.vue +++ b/test/vuex/acc-one-mutasi-handover/components/mutasiListing.vue @@ -217,7 +217,8 @@ Lihat Detail
+ + + Cetak PDF +
@@ -249,6 +262,18 @@ Kirim Mutasi + + + Cetak PDF +
@@ -267,6 +292,14 @@ + @@ -303,9 +336,14 @@ module.exports = { "approve-dialog": httpVueLoader("./approveDialog.vue"), "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDeleteRequest: "", dialogAlertDeleteRequest: false, dialogAlertDeleteDetail: false, @@ -593,6 +631,16 @@ module.exports = { this.$store.dispatch("form/getCategory"); this.$store.dispatch("form/getBranchAsal"); this.$store.dispatch("form/getBranchTujuan"); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + let id = val.MutasiHandoverID ? val.MutasiHandoverID : val.MutasiRequestID; + this.urlprint = BASE_URL + "/one-api/report/rpt_penyerahan_mutasi/pdf?id=" + id + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, }; diff --git a/test/vuex/acc-one-mutasi-receive/components/mutasiListing.vue b/test/vuex/acc-one-mutasi-receive/components/mutasiListing.vue index a218c1a..152b4bf 100644 --- a/test/vuex/acc-one-mutasi-receive/components/mutasiListing.vue +++ b/test/vuex/acc-one-mutasi-receive/components/mutasiListing.vue @@ -223,7 +223,8 @@ Lihat Detail + + + Cetak PDF +
@@ -286,6 +299,14 @@ +
@@ -323,9 +344,14 @@ module.exports = { "approve-dialog": httpVueLoader("./approveDialog.vue"), "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDeleteRequest: "", dialogAlertDeleteRequest: false, dialogAlertDeleteDetail: false, @@ -624,6 +650,15 @@ module.exports = { this.$store.commit("mutasi/update_indeterminatex", false); this.$store.commit("mutasi/update_selected_barcode", []); this.$store.dispatch("mutasi/getBarcodes"); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_penerimaan_mutasi/pdf?id=" + val.MutasiHandoverID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, }; diff --git a/test/vuex/acc-one-mutasi-request/components/mutasiListing.vue b/test/vuex/acc-one-mutasi-request/components/mutasiListing.vue index a925a13..3261e39 100644 --- a/test/vuex/acc-one-mutasi-request/components/mutasiListing.vue +++ b/test/vuex/acc-one-mutasi-request/components/mutasiListing.vue @@ -217,12 +217,13 @@ -
+ @@ -265,6 +280,14 @@ +
@@ -301,9 +324,14 @@ module.exports = { "approve-dialog": httpVueLoader("./approveDialog.vue"), "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDeleteRequest: "", dialogAlertDeleteRequest: false, dialogAlertDeleteDetail: false, @@ -546,6 +574,15 @@ module.exports = { deleteRM(data) { this.$store.commit("mutasi/update_selected_list_data", data); this.$store.commit("mutasi/update_dialog_delete", true); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_request_mutasi/pdf?id=" + val.MutasiRequestID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, }; diff --git a/test/vuex/acc-one-payment-voucher/components/voucherListing.vue b/test/vuex/acc-one-payment-voucher/components/voucherListing.vue index faf9683..a771706 100644 --- a/test/vuex/acc-one-payment-voucher/components/voucherListing.vue +++ b/test/vuex/acc-one-payment-voucher/components/voucherListing.vue @@ -192,25 +192,43 @@ @@ -234,6 +252,15 @@ @forget-dialog-alert="dialogAlertDelete = false" @close-dialog-alert="closeAndDelete()" > + + @@ -263,10 +290,15 @@ module.exports = { components: { "dialog-form-voucher": httpVueLoader("./dialogFormVoucher.vue"), "one-dialog-alert": httpVueLoader("../../common/oneDialogAlert.vue"), - "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue") + "one-dialog-error": httpVueLoader("../../common/oneDialogError.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDelete: "", dialogAlertDelete: false, xPVID: 0, @@ -306,7 +338,7 @@ module.exports = { }, { text: "AKSI", - align: "left", + align: "center", sortable: false, value: "status", width: "15%", @@ -570,6 +602,15 @@ module.exports = { this.$store.commit("voucher/update_selected_purchase", this.$store.state.voucher.details); this.$store.commit("voucher/update_resume_total", {"totalRealitation": data.PaymentVoucherTotal} ); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_payment_voucher/pdf?id=" + val.PaymentVoucherID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, watch: { diff --git a/test/vuex/acc-one-po-asset/components/dialog-add-item-aset.vue b/test/vuex/acc-one-po-asset/components/dialog-add-item-aset.vue new file mode 100644 index 0000000..341e3a5 --- /dev/null +++ b/test/vuex/acc-one-po-asset/components/dialog-add-item-aset.vue @@ -0,0 +1,244 @@ + + + \ No newline at end of file diff --git a/test/vuex/acc-one-po-asset/components/dialog-create-contract.vue b/test/vuex/acc-one-po-asset/components/dialog-create-contract.vue new file mode 100644 index 0000000..00eedcb --- /dev/null +++ b/test/vuex/acc-one-po-asset/components/dialog-create-contract.vue @@ -0,0 +1,259 @@ + + + diff --git a/test/vuex/acc-one-po-asset/components/dialog-form-order-aset.vue b/test/vuex/acc-one-po-asset/components/dialog-form-order-aset.vue new file mode 100644 index 0000000..826493a --- /dev/null +++ b/test/vuex/acc-one-po-asset/components/dialog-form-order-aset.vue @@ -0,0 +1,601 @@ + + + \ No newline at end of file diff --git a/test/vuex/acc-one-po-asset/components/main-layout.vue b/test/vuex/acc-one-po-asset/components/main-layout.vue index b05472f..8cc2677 100644 --- a/test/vuex/acc-one-po-asset/components/main-layout.vue +++ b/test/vuex/acc-one-po-asset/components/main-layout.vue @@ -56,7 +56,7 @@ Rp. {{ formatCurrency(props.item.PurchaseOrderGrandTotal) }} {{ props.item.PurchaseOrderStatus }} - +
Detail PO + + + Cetak PDF +
@@ -133,6 +142,14 @@ + @@ -145,6 +162,10 @@ module.exports = { }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, menuStartdateFilter: false, menuEnddateFilter: false, headers: [ @@ -187,6 +208,7 @@ module.exports = { 'dialog-add-attchment': httpVueLoader('./dialog-add-attachment.vue'), 'dialog-delete-order': httpVueLoader('./dialog-delete-order.vue'), 'dialog-create-order': httpVueLoader('./dialog-create-order.vue'), + 'one-dialog-print': httpVueLoader('../../common/oneDialogPrintX.vue'), }, computed: { snackbar: { @@ -289,6 +311,15 @@ module.exports = { viewDetailPO(item) { this.$store.commit("common/update_viewonlymode", true); this.$store.dispatch("kontrakAsset/getDetailDataPO", item.PurchaseOrderID); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_purchase_order_asset/pdf?id=" + val.PurchaseOrderID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, watch: { diff --git a/test/vuex/acc-one-po-asset/modules/poasset.js b/test/vuex/acc-one-po-asset/modules/poasset.js new file mode 100644 index 0000000..c04f9cf --- /dev/null +++ b/test/vuex/acc-one-po-asset/modules/poasset.js @@ -0,0 +1,179 @@ +import * as api from '../api/api.js'; + +export default { + namespaced: true, + state: { + /* common */ + snackbar: { + color: 'success', + msg: '', + state: false + }, + loading_process: false, + selected_orderaset: {}, + + /* main layout */ + filterpo: { + startdate: moment(new Date()).format('YYYY-MM-DD'), + enddate: moment(new Date()).format('YYYY-MM-DD'), + status: 'All', + search: '' + }, + list_status: ['All', 'Draft', 'Pending', 'Approved', 'Rejected', 'Completed'], + list_asetpo: { + records: [], + total: 0 + }, + currpage: 1, + + /* form order aset */ + dialog_form_orderaset: false, + list_supplier: [], + list_branch: [], + form_orderaset: { + podate: moment(new Date()).format('YYYY-MM-DD'), + supplierID: "", + reference: "", + branchcode: "", + typepajak: "persen", + valuepajak: 0, + typediskon: "persen", + valuediskon: 0 + }, + item_orderaset: [], + summary_orderaset: { + subtotal: 0, + diskon: 0, + pajak: 0, + total: 0 + }, + + dialog_add_itemaset: false, + list_requestaset: { + records: [], + total: 0 + }, + + /* delete order */ + dialog_deleteorder: false, + + /* attachment */ + dialog_attachment: false, + prview_attachment: [], + + }, + mutations: { + /* common */ + update_snackbar(state, val) { + state.snackbar = val + }, + update_loading_process(state, val) { + state.loading_process = val + }, + update_selected_orderaset(state, val) { + state.selected_orderaset = val + }, + + /* main layout */ + update_filterpo(state, val) { + state.filterpo = val + }, + update_list_status(state, val) { + state.list_status = val + }, + update_list_asetpo(state, val) { + state.list_asetpo = val + }, + update_currpage(state, val) { + state.currpage = val + }, + + /* form order aset */ + update_dialog_form_orderaset(state, val) { + state.dialog_form_orderaset = val + }, + update_list_supplier(state, val) { + state.list_supplier = val + }, + update_list_branch(state, val) { + state.list_branch = val + }, + update_form_orderaset(state, val) { + state.form_orderaset = val + }, + update_item_orderaset(state, val) { + state.item_orderaset = val + }, + update_summary_orderaset(state, val) { + state.summary_orderaset = val + }, + update_dialog_add_itemaset(state, val) { + state.dialog_add_itemaset = val + }, + update_list_requestaset(state, val) { + state.list_requestaset = val + }, + + /* delete order */ + update_dialog_deleteorder(state, val) { + state.dialog_deleteorder = val + }, + + /* attachment */ + update_dialog_attachment(state, val) { + state.dialog_attachment = val + }, + update_prview_attachment(state, val) { + state.prview_attachment = val + } + }, + actions: { + async lookupVendor(context) { + try { + const resp = await api.getListSupplier({token: one_token()}); + if (resp.status != 'OK') { + throw new Error(resp.message); + } else { + context.commit('update_list_supplier', resp.data) + } + } catch (error) { + let snac = {color: 'error', msg: error.message, state: true} + context.commit('update_snackbar', snac) + } + }, + async lookupCabang(context) { + try { + const resp = await api.getListCabang({token: one_token()}); + if (resp.status != 'OK') { + throw new Error(resp.message); + } + + context.commit('update_list_branch', resp.data) + } catch (error) { + let snac = {color: 'error', msg: error.message, state: true} + context.commit('update_snackbar', snac) + } + }, + async lookupOrderRequest(context, keyword) { + try { + const form = context.state.form_orderaset + let param = { + token: one_token(), + branchcode: form.branchcode, + search: keyword, + currpage: 1, + supplierID: form.supplierID + } + const resp = await api.searchRequestAset(param) + if (resp.status != 'OK') { + throw new Error(resp.message); + } + + context.commit('update_list_requestaset', resp.data) + } catch (error) { + let snac = {color: 'error', msg: error.message, state: true} + context.commit('update_snackbar', snac) + } + } + } +} diff --git a/test/vuex/acc-one-po-jasa/components/layoutPoJasa.vue b/test/vuex/acc-one-po-jasa/components/layoutPoJasa.vue index 7ac73cc..46e5040 100644 --- a/test/vuex/acc-one-po-jasa/components/layoutPoJasa.vue +++ b/test/vuex/acc-one-po-jasa/components/layoutPoJasa.vue @@ -77,7 +77,7 @@ Rp. {{ formatCurrency(props.item.PurchaseOrderGrandTotal) }} {{ props.item.PurchaseOrderStatus }} - +
Detail PO + + + Cetak PDF +
@@ -163,6 +175,14 @@ + @@ -175,6 +195,7 @@ module.exports = { 'dialog-jasa-delete': httpVueLoader('./dialogDeletePoJasa.vue'), 'dialog-jasa-attach': httpVueLoader('./dialogAddAttachment.vue'), 'dialog-view-jasa': httpVueLoader('./dialogViewPoJasa.vue'), + 'one-dialog-print': httpVueLoader('../../common/oneDialogPrintX.vue'), }, mounted() { this.$store.dispatch("poservice/lookupVendor") @@ -183,6 +204,10 @@ module.exports = { }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, menuStartdateFilter: false, menuEnddateFilter: false, headers: [ @@ -311,6 +336,15 @@ module.exports = { viewPO(item) { this.$store.dispatch("poservice/lookupDataPOJasa", item.PurchaseOrderID) this.$store.commit("poservice/update_dialog_viewpo", true); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_purchase_order_jasa/pdf?id=" + val.PurchaseOrderID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, watch: { diff --git a/test/vuex/acc-one-purchase-request-direct-approved/components/listingRequest.vue b/test/vuex/acc-one-purchase-request-direct-approved/components/listingRequest.vue index d153e31..ee5f101 100644 --- a/test/vuex/acc-one-purchase-request-direct-approved/components/listingRequest.vue +++ b/test/vuex/acc-one-purchase-request-direct-approved/components/listingRequest.vue @@ -111,20 +111,29 @@ {{ props.item.PurchaseRequestDirectStatus }} - +
edit visibility + + print +
@@ -325,6 +334,16 @@ + + +
@@ -349,9 +368,14 @@ module.exports = { "one-dialog-info": httpVueLoader("../../common/oneDialogInfo.vue"), "one-dialog-attachment": httpVueLoader("./formDialogAttachtment.vue"), "one-dialog-edit-req": httpVueLoader("./formEditRequest.vue"), + "one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"), }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, msgAlertDeleteOrReject: "", dialogAlertRejectRequest: false, dialogAlertDeleteDetail: false, @@ -376,7 +400,7 @@ module.exports = { }, { text: "TOTAL", align: "left", sortable: false, - value: "description", width: "20%", class: "blue lighten-3 white--text", + value: "description", width: "15%", class: "blue lighten-3 white--text", }, { text: "STATUS", align: "center", sortable: false, @@ -384,7 +408,7 @@ module.exports = { }, { text: "AKSI", align: "center", sortable: false, - value: "action", width: "10%", class: "blue lighten-3 white--text", + value: "action", width: "15%", class: "blue lighten-3 white--text", }, ], detail_headers: [ @@ -742,6 +766,15 @@ module.exports = { }) } this.dialogAlertUnapprove = false; + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_pr_direct_approval/pdf?id=" + val.PurchaseRequestDirectID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, } diff --git a/test/vuex/acc-one-purchase-request-direct/components/requestListing.vue b/test/vuex/acc-one-purchase-request-direct/components/requestListing.vue index ab95951..156e9ea 100644 --- a/test/vuex/acc-one-purchase-request-direct/components/requestListing.vue +++ b/test/vuex/acc-one-purchase-request-direct/components/requestListing.vue @@ -204,6 +204,7 @@ > + > + + print + + @@ -559,6 +570,14 @@ + +
Lihat detail + + + Cetak PDF +
@@ -151,6 +162,14 @@ + +
Detail Order - + @@ -198,6 +217,7 @@ module.exports = { 'dialog-delete-ro': httpVueLoader('./dialog-delete-ro.vue'), 'dialog-confirm-ro': httpVueLoader('./dialog-confirm-ro.vue'), 'dialog-edit-ro': httpVueLoader('./dialog-edit-ro.vue'), + 'one-dialog-print': httpVueLoader('../../common/oneDialogPrintX.vue'), }, mounted() { this.$store.dispatch('roservice/lookupCabang'); @@ -207,6 +227,10 @@ module.exports = { }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, menuStartdateFilter: false, menuEnddateFilter: false, headers: [ @@ -315,6 +339,15 @@ module.exports = { this.$store.commit("roservice/update_selected_rojasa", item) this.$store.commit("roservice/update_dialog_deletero", true) } + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_receive_order_jasa/pdf?id=" + val.ReceiveOrderPoID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, watch: { diff --git a/test/vuex/acc-one-receive-order-asset/components/main-layout.vue b/test/vuex/acc-one-receive-order-asset/components/main-layout.vue index 1840e81..e22d5ab 100644 --- a/test/vuex/acc-one-receive-order-asset/components/main-layout.vue +++ b/test/vuex/acc-one-receive-order-asset/components/main-layout.vue @@ -68,7 +68,7 @@ Unconfirmed
- +
View Document + + + Cetak PDF +
@@ -154,6 +163,14 @@ + @@ -166,6 +183,7 @@ module.exports = { 'dialog-confirm-order-asset': httpVueLoader('./dialog-confirm-receive.vue'), 'dialog-pick-contract': httpVueLoader('./dialog-pick-contract.vue'), 'dialog-inspeksi': httpVueLoader('./dialog-inspeksi.vue'), + 'one-dialog-print': httpVueLoader('../../common/oneDialogPrintX.vue'), }, mounted() { this.$store.dispatch("orderAsset/listingCabang"); @@ -174,6 +192,10 @@ module.exports = { }, data() { return { + urlprint: "", + printtitle: "", + printwidth: "60%", + openprint: false, menuStartdateFilter: false, menuEnddateFilter: false, headers: [ @@ -282,6 +304,15 @@ module.exports = { deleteRO(item) { this.$store.commit("roasset/update_selected_roasset", item) this.$store.commit("roasset/update_dialog_delete", true); + }, + printout(val) { + this.printwidth = "60%"; + this.printtitle = ""; + let user = one_user(); + let username = user && user.M_StaffName ? user.M_StaffName : ""; + let tm = Date.now(); + this.urlprint = BASE_URL + "/one-api/report/rpt_receive_order_asset/pdf?id=" + val.ReceiveOrderPoID + "&username=" + username + "&tm=" + tm; + this.openprint = true; } }, watch: { diff --git a/test/vuex/acc-one-receive-surat-jalan/components/listing.vue b/test/vuex/acc-one-receive-surat-jalan/components/listing.vue index 5c3c237..9ba9e63 100644 --- a/test/vuex/acc-one-receive-surat-jalan/components/listing.vue +++ b/test/vuex/acc-one-receive-surat-jalan/components/listing.vue @@ -83,6 +83,16 @@ {{ props.item.SuratJalanStatus }} + + + print + + @@ -91,11 +101,23 @@ + +
diff --git a/test/vuex/acc-one-surat-jalan/components/listing.vue b/test/vuex/acc-one-surat-jalan/components/listing.vue index b5c0630..71add5d 100644 --- a/test/vuex/acc-one-surat-jalan/components/listing.vue +++ b/test/vuex/acc-one-surat-jalan/components/listing.vue @@ -84,13 +84,24 @@ {{ props.item.SuratJalanStatus }} - - + - delete - + delete + + + print + @@ -100,18 +111,33 @@ + +