修改 发票登记

ywj_dev
wangwei 2 years ago
parent d0419d144f
commit f3edef9022

@ -171,18 +171,6 @@
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" width="160" fixed="right">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="InvoiceRegister(scope.row)"
>发票登记
</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
@ -194,106 +182,11 @@
</el-card>
<el-tabs type="border-card" style="margin: 15px">
<el-tab-pane>
<span slot="label">订单 {{ currentRow.billNo }}-发票信息</span>
<el-form :inline="true" :model="bizQuery" class="query-form" size="mini">
</el-form>
<el-table v-loading="bizDetailLoading" :data="bizDetailList" style="width: 100%" border
row-key="id"
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="规格型号"
prop="ggxh"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="产品名称"
prop="cpmctymc"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="批次号"
prop="batchNo"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="机器编码"
prop="machineNo"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="发票代码"
prop="invoiceCode"
></el-table-column>
<el-table-column
label="发票编码"
prop="invoiceEncode"
></el-table-column>
<el-table-column
label="开票日期"
prop="invoiceDate"
></el-table-column>
<el-table-column
label="发票价格"
prop="price"
></el-table-column>
<el-table-column
label="生产日期"
prop="productDate"
></el-table-column>
<el-table-column
label="失效日期"
prop="expireDate"
></el-table-column>
<el-table-column
label="备注"
prop="remark"
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作" width="160">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="printOrder(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native.stop="deleteInvoice(scope.row.id)"
>删除
</el-button
>
<el-button
type="text"
size="small"
@click.native.stop="toViewCompanyCert(scope.row)"
>预览
</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="bizTotal>0"
:total="bizTotal"
:page.sync="bizQuery.page"
:limit.sync="bizQuery.limit"
@pagination="getBizDetailList"
/>
</el-tab-pane>
<!--单据业务详情-->
<el-tab-pane>
<span slot="label">单据 {{ currentRow.billNo }}-单据详情</span>
<el-table v-loading="bizDetailLoading" :data="codeDetailList" style="width: 100%" border
row-key="id"
row-key="id" @row-click="BizDetail" highlight-current-row
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
@ -352,6 +245,19 @@
prop="certCode"
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作" width="160" fixed="right">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="InvoiceRegister(scope.row)"
>发票登记
</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="bizTotal>0"
@ -364,6 +270,107 @@
</el-tabs>
<el-tabs type="border-card" style="margin: 15px">
<!--单据业务详情-->
<el-tab-pane>
<span slot="label">单据 {{ currentRow.billNo }}-发票信息</span>
<el-table v-loading="bizDetailLoading" :data="bizDetailList" style="width: 100%" border
row-key="id"
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="规格型号"
prop="ggxh"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="产品名称"
prop="cpmctymc"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="批次号"
prop="batchNo"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="机器编码"
prop="machineNo"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="发票代码"
prop="invoiceCode"
></el-table-column>
<el-table-column
label="发票编码"
prop="invoiceEncode"
></el-table-column>
<el-table-column
label="开票日期"
prop="invoiceDate"
></el-table-column>
<el-table-column
label="发票价格"
prop="price"
></el-table-column>
<el-table-column
label="生产日期"
prop="productDate"
></el-table-column>
<el-table-column
label="失效日期"
prop="expireDate"
></el-table-column>
<el-table-column
label="备注"
prop="remark"
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作" width="160">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="printOrder(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native.stop="deleteInvoice(scope.row.id)"
>删除
</el-button
>
<el-button
type="text"
size="small"
:disabled="!scope.row.licenseUrl"
@click.native.stop="showImgViewer(scope.row)"
>预览
</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="bizTotal>0"
:total="bizTotal"
:page.sync="bizQuery.page"
:limit.sync="bizQuery.limit"
@pagination="getBizDetailList"
/>
</el-tab-pane>
</el-tabs>
<el-image-viewer v-if="imgViewerVisible" style="z-index:9999" :on-close="closeImgViewer" :url-list="imgList"/>
<el-dialog
title="发票编辑"
:visible.sync="Upinvoice"
@ -419,7 +426,7 @@ import {getLocalJoinByUser} from "@/api/basic/busType";
import {getInvListByUser} from "@/api/system/invWarehouse";
import {isBlank} from "@/utils/strUtil";
import {selectSysParamByKey} from "@/api/param/systemParamConfig";
import {filterListInvoice, getBizDetailList, deleteById} from '@/api/inout/orderDetailBiz'
import {filterListInvoice, getBizDetailList, deleteById,insertInvoice} from '@/api/inout/orderDetailBiz'
import {getCodeList} from "@/api/inout/code";
import AcceptOrder from "@/views/inout/DialogReviewOrder";
import DialogInvoice from "@/views/inout/DialogInvoice";
@ -428,6 +435,10 @@ import InvoiceRegister from "@/views/inout/InvoiceRegister";
import {inspectionOrderPDFFromTemplateFile, orderPDFFromTemplateFile} from "@/api/itextpdf/orderPrint"
import {getDeptListByUser} from "@/api/auth/authDept";
import {getBasicUnitMaintains} from "@/api/basic/basicUnitMaintain";
import { previewImage } from '@/api/purchase/supCompany'
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
const formJson = {
@ -441,6 +452,8 @@ export default {
name: "IoCheckSuccessOrder",
data() {
return {
imgList:[],
imgViewerVisible:false,
BASE_URL: process.env.VUE_APP_BASE_API,
showSearch: true,
filterQuery: {
@ -579,7 +592,7 @@ export default {
acceptOrderVisible: false,
};
},
components: {AcceptOrder, DialogInvoice, InvoiceRegister},
components: {AcceptOrder, DialogInvoice, InvoiceRegister,ElImageViewer},
methods: {
onReset() {
this.$router.push({
@ -600,8 +613,17 @@ export default {
this.getList();
},
InvoiceRegister(row) {
this.inputQueryId = row.billNo;
this.InvoiceRegisterv = true;
insertInvoice(row)
.then(response => {
if (response.code === 20000) {
this.closeInvoice();
} else {
this.$message.error(response.message);
}
})
.catch(() => {
this.$message.error(response.message);
});
},
onSubmit() {
this.loading = true;
@ -627,10 +649,30 @@ export default {
hideSearch() {
this.showSearch = !this.showSearch;
},
toViewCompanyCert(row) {
showImgViewer(row){
this.certFileUrl = this.BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
window.open(this.certFileUrl + row.licenseUrl);
this.imgList=[];
previewImage({imageUrl:row.licenseUrl,certFileUrl:this.certFileUrl}).then(response => {
if (response.code === 20000) {
debugger
this.imgList=response.data;
}
console.log(this.imgList)
this.imgViewerVisible = true;
});
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'hidden';
document.addEventListener("touchmove", m, false); //
},
closeImgViewer(){
this.imgViewerVisible = false;
const m = (e) => { e.preventDefault() };
document.body.style.overflow = 'auto';
document.removeEventListener("touchmove", m, true);
},
invChange() {
this.filterQuery.action = null;
this.getBusType();
@ -689,11 +731,9 @@ export default {
},
//
getOrderDetails() {
this.bizQuery.page = 1;
this.codeQuery.page = 1;
this.resultQuery.page = 1;
this.getBizDetailList();
this.getCodeDetailList();
this.getResultDetailList();
},
@ -884,6 +924,10 @@ export default {
this.bizTotal = 0;
})
},
BizDetail(){
this.bizQuery.page=1;
this.getBizDetailList();
},
//

Loading…
Cancel
Save