|
|
|
@ -106,7 +106,7 @@
|
|
|
|
|
plain
|
|
|
|
|
icon="el-icon-delete"
|
|
|
|
|
size="mini"
|
|
|
|
|
:disabled="multiple1"
|
|
|
|
|
:disabled="multiple"
|
|
|
|
|
@click="handleDelete"
|
|
|
|
|
>删除</el-button
|
|
|
|
|
>
|
|
|
|
@ -746,12 +746,12 @@
|
|
|
|
|
width="800px"
|
|
|
|
|
append-to-body
|
|
|
|
|
>
|
|
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="140px">
|
|
|
|
|
<el-form ref="PZform" :model="PZform" :rules="rules" label-width="140px">
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="14">
|
|
|
|
|
<el-form-item label="会计凭证" prop="voucherId">
|
|
|
|
|
<el-form-item label="会计凭证">
|
|
|
|
|
<el-input
|
|
|
|
|
v-model="form.voucherId"
|
|
|
|
|
v-model="PZform.voucherNum"
|
|
|
|
|
placeholder="请选择凭证"
|
|
|
|
|
readonly
|
|
|
|
|
>
|
|
|
|
@ -793,6 +793,7 @@ import {
|
|
|
|
|
outTemplate,
|
|
|
|
|
downloadXml,
|
|
|
|
|
getInvoicesPageTime,
|
|
|
|
|
updateArrayInvoices,
|
|
|
|
|
} from "@/api/accounting/invoices";
|
|
|
|
|
import { getVoucherPage } from "@/api/accounting/voucher";
|
|
|
|
|
import { listData } from "@/api/system/dict/data";
|
|
|
|
@ -810,10 +811,8 @@ export default {
|
|
|
|
|
optType: undefined,
|
|
|
|
|
// 遮罩层
|
|
|
|
|
loading: true,
|
|
|
|
|
// 多个禁用
|
|
|
|
|
multiple: true,
|
|
|
|
|
// 非多个禁用
|
|
|
|
|
multiple1: true,
|
|
|
|
|
multiple: true,
|
|
|
|
|
// 导出遮罩层
|
|
|
|
|
exportLoading: false,
|
|
|
|
|
downloadLoading: false,
|
|
|
|
@ -901,6 +900,10 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
// 表单参数
|
|
|
|
|
form: {},
|
|
|
|
|
PZform: {
|
|
|
|
|
voucherId: undefined,
|
|
|
|
|
voucherNum: undefined,
|
|
|
|
|
},
|
|
|
|
|
uploadUrl:
|
|
|
|
|
process.env.VUE_APP_BASE_API +
|
|
|
|
|
"/admin-api/accounting/invoices/identify", // 上传地址地址
|
|
|
|
@ -1178,13 +1181,7 @@ export default {
|
|
|
|
|
handleSelectionChange(selection) {
|
|
|
|
|
console.log(selection);
|
|
|
|
|
this.ids = selection.map((item) => item.id);
|
|
|
|
|
if (selection.length == 1) {
|
|
|
|
|
this.multiple = false;
|
|
|
|
|
this.form = selection[0];
|
|
|
|
|
} else {
|
|
|
|
|
this.multiple = true;
|
|
|
|
|
}
|
|
|
|
|
this.multiple1 = !selection.length;
|
|
|
|
|
this.multiple = !selection.length;
|
|
|
|
|
},
|
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
|
handleAdd() {
|
|
|
|
@ -1287,16 +1284,19 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
//关联凭证
|
|
|
|
|
handleGLPZ() {
|
|
|
|
|
this.form.voucherId = null;
|
|
|
|
|
this.open2 = true;
|
|
|
|
|
console.log(this.form);
|
|
|
|
|
this.PZform = {
|
|
|
|
|
voucherId: undefined,
|
|
|
|
|
voucherNum: undefined,
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
submitForm2() {
|
|
|
|
|
this.$refs["form"].validate((valid) => {
|
|
|
|
|
this.$refs["PZform"].validate((valid) => {
|
|
|
|
|
if (!valid) {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
updateInvoices(this.form).then((response) => {
|
|
|
|
|
const data = { id: this.ids, voucherId: this.PZform.voucherId };
|
|
|
|
|
updateArrayInvoices(data).then((response) => {
|
|
|
|
|
this.$modal.msgSuccess("关联成功");
|
|
|
|
|
this.open2 = false;
|
|
|
|
|
this.multiple = true;
|
|
|
|
@ -1387,7 +1387,8 @@ export default {
|
|
|
|
|
onVoucherSelected(obj) {
|
|
|
|
|
console.log(obj);
|
|
|
|
|
if (obj != undefined && obj != null) {
|
|
|
|
|
this.form.voucherId = obj.id;
|
|
|
|
|
this.PZform.voucherId = obj.id;
|
|
|
|
|
this.PZform.voucherNum = obj.voucherNum;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|