add button report receive surat jalan
This commit is contained in:
@@ -83,6 +83,16 @@
|
|||||||
{{ props.item.SuratJalanStatus }}
|
{{ props.item.SuratJalanStatus }}
|
||||||
</v-chip>
|
</v-chip>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="text-xs-center pa-2" style="white-space: nowrap;">
|
||||||
|
<v-btn
|
||||||
|
style="min-width: 25px; height: 25px; margin: 0;"
|
||||||
|
@click="printout(props.item)"
|
||||||
|
small title="Cetak PDF"
|
||||||
|
color="primary"
|
||||||
|
>
|
||||||
|
<v-icon small color="white">print</v-icon>
|
||||||
|
</v-btn>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</template>
|
</template>
|
||||||
</v-data-table>
|
</v-data-table>
|
||||||
@@ -91,11 +101,23 @@
|
|||||||
<v-pagination v-model="paginat" :length="paginat_len" :total-visible="5"></v-pagination>
|
<v-pagination v-model="paginat" :length="paginat_len" :total-visible="5"></v-pagination>
|
||||||
</div>
|
</div>
|
||||||
</v-card>
|
</v-card>
|
||||||
|
|
||||||
|
<one-dialog-print
|
||||||
|
:title="printtitle"
|
||||||
|
:width="printwidth"
|
||||||
|
:height="600"
|
||||||
|
:status="openprint"
|
||||||
|
:urlprint="urlprint"
|
||||||
|
@close-dialog-print="openprint = false"
|
||||||
|
></one-dialog-print>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
components: {
|
||||||
|
"one-dialog-print": httpVueLoader("../../common/oneDialogPrintX.vue"),
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.$store.dispatch("suratjalan/LookupBranches")
|
this.$store.dispatch("suratjalan/LookupBranches")
|
||||||
this.$store.dispatch("suratjalan/LookupEkpedisi")
|
this.$store.dispatch("suratjalan/LookupEkpedisi")
|
||||||
@@ -105,6 +127,10 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
urlprint: "",
|
||||||
|
printtitle: "",
|
||||||
|
printwidth: "60%",
|
||||||
|
openprint: false,
|
||||||
menuStartDate: false,
|
menuStartDate: false,
|
||||||
menuEndDate: false,
|
menuEndDate: false,
|
||||||
headers: [
|
headers: [
|
||||||
@@ -130,7 +156,11 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: "STATUS", align: "center", sortable: false,
|
text: "STATUS", align: "center", sortable: false,
|
||||||
value: "requestDate", width: "15%", class: "blue lighten-3 white--text",
|
value: "requestDate", width: "10%", class: "blue lighten-3 white--text",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: "AKSI", align: "center", sortable: false,
|
||||||
|
value: "action", width: "10%", class: "blue lighten-3 white--text",
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -232,6 +262,15 @@
|
|||||||
default:
|
default:
|
||||||
return "gray"
|
return "gray"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
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_transfer/pdf?id=" + val.SuratJalanID + "&username=" + username + "&tm=" + tm;
|
||||||
|
this.openprint = true;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user