|
@@ -0,0 +1,126 @@
|
|
|
+<style scoped>
|
|
|
+ .user-panel {
|
|
|
+ margin: 10px auto;
|
|
|
+ }
|
|
|
+ table.gridtable {
|
|
|
+ font-family: verdana,arial,sans-serif;
|
|
|
+ font-size:11px;
|
|
|
+ color:#333333;
|
|
|
+ border-width: 1px;
|
|
|
+ border-color: #666666;
|
|
|
+ border-collapse: collapse;
|
|
|
+ }
|
|
|
+ table.gridtable th {
|
|
|
+ border-width: 1px;
|
|
|
+ padding: 8px;
|
|
|
+ border-style: solid;
|
|
|
+ border-color: #666666;
|
|
|
+ background-color: #dedede;
|
|
|
+ }
|
|
|
+ table.gridtable td {
|
|
|
+ border-width: 1px;
|
|
|
+ padding: 8px;
|
|
|
+ border-style: solid;
|
|
|
+ border-color: #666666;
|
|
|
+ background-color: #ffffff;
|
|
|
+ }
|
|
|
+</style>
|
|
|
+<template>
|
|
|
+ <el-dialog
|
|
|
+ :visible.sync="showDialog"
|
|
|
+ :title="title"
|
|
|
+ :modal-append-to-body="false"
|
|
|
+ style="text-align: left"
|
|
|
+ width="70%"
|
|
|
+ @close="closeDialog"
|
|
|
+ :close-on-click-modal="false"
|
|
|
+ >
|
|
|
+ <div class="user-panel">
|
|
|
+ <table ref="printContent" class="gridtable" border="1" width="100%" cellspacing="0" cellpadding="0">
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="8">发票入账单</td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="3"></td>
|
|
|
+ <td style="height:50px" colspan="5"></td>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <td style="height:50px" colspan="2"></td>
|
|
|
+ <td style="height:50px" colspan="2"></td>
|
|
|
+ <td style="height:50px" colspan="2"></td>
|
|
|
+ <td style="height:50px" colspan="2"></td>
|
|
|
+ </tr>
|
|
|
+ </table>
|
|
|
+ </div>
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
+ <el-button @click="printDialog">打 印</el-button>
|
|
|
+ <el-button @click="closeDialog">关 闭</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
+</template>
|
|
|
+<script>
|
|
|
+import Constant from "@/constant";
|
|
|
+import auditingApi from "@/api/base/auditing";
|
|
|
+
|
|
|
+export default {
|
|
|
+ props: ["businessKey", "title"],
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ showDialog: true,
|
|
|
+ showData: {},
|
|
|
+ };
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ closeDialog() {
|
|
|
+ this.$emit("close", false);
|
|
|
+ },
|
|
|
+ printDialog() {
|
|
|
+ var oldHtml = document.body;
|
|
|
+ var printbox = this.$refs.printContent.innerHTML;
|
|
|
+ document.body.innerHTML = printbox;
|
|
|
+ window.print();
|
|
|
+ // document.body.innerHTML = oldHtml;
|
|
|
+ // location.reload();
|
|
|
+ console.log(oldHtml);
|
|
|
+ console.log(printbox);
|
|
|
+ },
|
|
|
+ },
|
|
|
+ mounted: function () {
|
|
|
+ var self = this;
|
|
|
+
|
|
|
+ //发票入账单数据
|
|
|
+ var formData = new FormData();
|
|
|
+ formData.append("auditingId", self.businessKey);
|
|
|
+ auditingApi
|
|
|
+ .showFPRZDData(formData)
|
|
|
+ .then(function (response) {
|
|
|
+ var jsonData = response.data.data;
|
|
|
+ self.showFPRZDData = jsonData;
|
|
|
+ // console.log(self.showFPRZDData);
|
|
|
+ })
|
|
|
+ .catch((error) => {
|
|
|
+ // self.$message.error(error + "");
|
|
|
+ });
|
|
|
+ },
|
|
|
+};
|
|
|
+</script>
|