Merge remote-tracking branch 'origin/main'

main
JiilingLee 1 year ago
commit dccb5fcad5

@ -53,3 +53,13 @@ export function exportAccountingBookExcel(query) {
responseType: 'blob' responseType: 'blob'
}) })
} }
// 下载元数据
export function downloadXml(query) {
return request({
url: '/archives/accounting-book/downloadXml',
method: 'get',
params: query,
responseType: 'blob'
})
}

@ -52,3 +52,13 @@ export function exportAccountingReportExcel(query) {
responseType: 'blob' responseType: 'blob'
}) })
} }
// 下载元数据
export function downloadXml(query) {
return request({
url: '/archives/accounting-report/downloadXml',
method: 'get',
params: query,
responseType: 'blob'
})
}

@ -60,6 +60,16 @@
>导出</el-button >导出</el-button
> >
</el-col> </el-col>
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-download"
size="mini"
@click="handleDownloadData"
>下载元数据</el-button
>
</el-col>
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
@ -236,6 +246,36 @@
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!-- 密码输入框-->
<el-dialog
:title="title"
:visible.sync="open1"
width="800px"
append-to-body
>
<el-form
ref="queryForm"
:model="queryParams"
:rules="rules"
label-width="140px"
>
<el-row>
<el-col :span="14">
<el-form-item label="密码" prop="inputPassword">
<el-input
v-model="queryParams.inputPassword"
placeholder="请输入密码"
/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm1"> </el-button>
<el-button @click="cancel1"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
@ -245,6 +285,7 @@ import {
deleteAccountingBook, deleteAccountingBook,
getAccountingBookPage, getAccountingBookPage,
exportAccountingBookExcel, exportAccountingBookExcel,
downloadXml,
} from "@/api/accounting/book"; } from "@/api/accounting/book";
import { getAccessToken } from "@/utils/auth"; import { getAccessToken } from "@/utils/auth";
import { getOrganizationPage } from "@/api/setting/organization"; import { getOrganizationPage } from "@/api/setting/organization";
@ -271,6 +312,7 @@ export default {
fileList2: [], fileList2: [],
// //
open: false, open: false,
open1: false,
// //
queryParams: { queryParams: {
pageNo: 1, pageNo: 1,
@ -281,6 +323,7 @@ export default {
type: null, type: null,
year: null, year: null,
period: null, period: null,
inputPassword: null,
}, },
// //
form: {}, form: {},
@ -293,6 +336,9 @@ export default {
period: [ period: [
{ required: true, message: "请输入会计期间", trigger: "blur" }, { required: true, message: "请输入会计期间", trigger: "blur" },
], ],
inputPassword: [
{ required: true, message: "密码不能为空", trigger: "blur" },
],
}, },
uploadUrl: uploadUrl:
process.env.VUE_APP_BASE_API + process.env.VUE_APP_BASE_API +
@ -347,6 +393,10 @@ export default {
this.open = false; this.open = false;
this.reset(); this.reset();
}, },
/** 取消按钮 */
cancel1() {
this.open1 = false;
},
/** 表单重置 */ /** 表单重置 */
reset() { reset() {
this.form = { this.form = {
@ -387,6 +437,26 @@ export default {
} }
}); });
}, },
//
handleDownloadData() {
this.open1 = true;
this.queryParams.inputPassword = null;
},
submitForm1() {
this.$refs["queryForm"].validate((valid) => {
if (!valid) {
return;
}
//
let params = { ...this.queryParams };
downloadXml(params)
.then((response) => {
this.$download.excel(response, "会计账簿元数据.xml");
this.open1 = false;
})
.catch(() => {});
});
},
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const id = row.id; const id = row.id;

@ -134,6 +134,17 @@
>下载元数据</el-button >下载元数据</el-button
> >
</el-col> </el-col>
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-document"
size="mini"
:disabled="multiple"
@click="handleGLPZ"
>关联凭证</el-button
>
</el-col>
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
@ -692,6 +703,35 @@
<el-button @click="cancel1"> </el-button> <el-button @click="cancel1"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!-- 会计凭证选择框-->
<el-dialog
:title="title"
:visible.sync="open2"
width="800px"
append-to-body
>
<el-form ref="form" :model="form" :rules="rules1" label-width="140px">
<el-row>
<el-col :span="14">
<el-form-item label="会计凭证" prop="voucherId">
<el-select v-model="form.voucherId" placeholder="请选择会计凭证">
<el-option
v-for="item in kjpzOptions"
:key="item.recordId"
:label="item.voucherNum"
:value="item.flowId"
>
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm2"> </el-button>
<el-button @click="cancel2"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
@ -707,6 +747,7 @@ import {
downloadXml, downloadXml,
getInvoicesPageTime, getInvoicesPageTime,
} from "@/api/accounting/invoices"; } from "@/api/accounting/invoices";
import { getVoucherPage } from "@/api/accounting/voucher";
import { listData } from "@/api/system/dict/data"; import { listData } from "@/api/system/dict/data";
import { getAccessToken } from "@/utils/auth"; import { getAccessToken } from "@/utils/auth";
@ -717,6 +758,8 @@ export default {
return { return {
// //
loading: true, loading: true,
//
multiple: true,
// //
exportLoading: false, exportLoading: false,
downloadLoading: false, downloadLoading: false,
@ -733,6 +776,7 @@ export default {
// //
open: false, open: false,
open1: false, open1: false,
open2: false,
accountingType: "in", accountingType: "in",
fileList: [], fileList: [],
time: null, time: null,
@ -820,6 +864,9 @@ export default {
{ required: true, message: "密码不能为空", trigger: "blur" }, { required: true, message: "密码不能为空", trigger: "blur" },
], ],
}, },
rules1: {
voucherId: [{ required: true, message: "请选择凭证", trigger: "blur" }],
},
// //
upload: { upload: {
// //
@ -843,10 +890,12 @@ export default {
invoiceStateOptions: [], // invoiceStateOptions: [], //
inOrOutOptions: [], // inOrOutOptions: [], //
qrCheckCodeOptions: [], // qrCheckCodeOptions: [], //
kjpzOptions: [], //
}; };
}, },
created() { created() {
this.getList(); this.getList();
this.getKJPZ();
this.handleInitList(); this.handleInitList();
}, },
@ -892,7 +941,8 @@ export default {
this.total = response.data.total; this.total = response.data.total;
this.loading = false; this.loading = false;
}); });
} /** 查询列表2 */, },
/** 查询列表2 */
getList2() { getList2() {
this.loading = true; this.loading = true;
// //
@ -902,6 +952,7 @@ export default {
this.loading = false; this.loading = false;
}); });
}, },
handleOneMonth() { handleOneMonth() {
this.time = 1; this.time = 1;
this.getList2(); this.getList2();
@ -914,6 +965,12 @@ export default {
this.time = 12; this.time = 12;
this.getList2(); this.getList2();
}, },
//
getKJPZ() {
getVoucherPage().then((res) => {
this.kjpzOptions = res.data.list || [];
});
},
// //
handleInitList() { handleInitList() {
// //
@ -980,6 +1037,10 @@ export default {
cancel1() { cancel1() {
this.open1 = false; this.open1 = false;
}, },
/** 取消按钮 */
cancel2() {
this.open2 = false;
},
/** 表单重置 */ /** 表单重置 */
reset() { reset() {
this.form = { this.form = {
@ -1057,8 +1118,14 @@ export default {
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
console.log(selection);
this.ids = selection.map((item) => item.id); this.ids = selection.map((item) => item.id);
this.multiple = !selection.length; if (selection.length == 1) {
this.multiple = false;
} else {
this.multiple = true;
}
this.form = selection[0];
}, },
/** 新增按钮操作 */ /** 新增按钮操作 */
handleAdd() { handleAdd() {
@ -1130,6 +1197,24 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleGLPZ() {
this.open2 = true;
this.form.voucherId = null;
},
submitForm2() {
this.$refs["form"].validate((valid) => {
if (!valid) {
return;
}
updateInvoices(this.form).then((response) => {
this.$modal.msgSuccess("关联成功");
this.open2 = false;
this.multiple = true;
this.getList();
});
});
},
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
// //
@ -1181,19 +1266,25 @@ export default {
submitFileForm() { submitFileForm() {
this.$refs.upload.submit(); this.$refs.upload.submit();
}, },
//
handleDownloadData() { handleDownloadData() {
this.open1 = true; this.open1 = true;
this.queryParams.inputPassword = null; this.queryParams.inputPassword = null;
}, },
submitForm1() { submitForm1() {
// this.$refs["queryForm"].validate((valid) => {
let params = { ...this.queryParams }; if (!valid) {
downloadXml(params) return;
.then((response) => { }
this.$download.excel(response, "发票元数据.xml"); //
this.open1 = false; let params = { ...this.queryParams };
}) downloadXml(params)
.catch(() => {}); .then((response) => {
this.$download.excel(response, "发票元数据.xml");
this.open1 = false;
})
.catch(() => {});
});
}, },
}, },
}; };

@ -88,11 +88,13 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="业务实体" align="center" prop="company" /> <el-table-column label="业务实体" align="center" prop="company" />
<el-table-column label="文件后缀" align="center" prop="suffix" /> <el-table-column label="文件地址" align="center" prop="fileUrl">
<el-table-column label="文件地址" align="center" prop="fileUrl" /> <template slot-scope="scope">
<el-table-column label="绝对路径" align="center" prop="fileAp" /> <el-button type="text" @click="openLink(scope.row.fileUrl)">
<el-table-column label="流程号" align="center" prop="flowId" /> {{ scope.row.fileUrl }}
<el-table-column label="摘要" align="center" prop="note" /> </el-button>
</template>
</el-table-column>
<el-table-column label="归档状态" align="center" prop="archiveState" /> <el-table-column label="归档状态" align="center" prop="archiveState" />
<el-table-column <el-table-column
label="创建时间" label="创建时间"
@ -243,11 +245,6 @@
<el-input v-model="form.company" placeholder="请输入业务实体" /> <el-input v-model="form.company" placeholder="请输入业务实体" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="摘要" prop="note">
<el-input v-model="form.note" placeholder="请输入摘要" />
</el-form-item>
</el-col>
</el-row> </el-row>
<el-form-item label="备注" prop="remark"> <el-form-item label="备注" prop="remark">
<el-input <el-input
@ -338,6 +335,16 @@ export default {
this.getList(); this.getList();
}, },
methods: { methods: {
/**
* 文件预览
* @param fileUrl 地址
*/
openLink(fileUrl) {
const url = `http://139.224.253.31:48012/onlinePreview?url=${encodeURIComponent(
this.base64Encode(fileUrl)
)}`;
window.open(url);
},
/** 查询列表 */ /** 查询列表 */
getList() { getList() {
this.loading = true; this.loading = true;

@ -69,6 +69,16 @@
>导出</el-button >导出</el-button
> >
</el-col> </el-col>
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-download"
size="mini"
@click="handleDownloadData"
>下载元数据</el-button
>
</el-col>
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
@ -241,6 +251,36 @@
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!-- 密码输入框-->
<el-dialog
:title="title"
:visible.sync="open1"
width="800px"
append-to-body
>
<el-form
ref="queryForm"
:model="queryParams"
:rules="rules"
label-width="140px"
>
<el-row>
<el-col :span="14">
<el-form-item label="密码" prop="inputPassword">
<el-input
v-model="queryParams.inputPassword"
placeholder="请输入密码"
/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm1"> </el-button>
<el-button @click="cancel1"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
@ -251,6 +291,7 @@ import {
getAccountingReport, getAccountingReport,
getAccountingReportPage, getAccountingReportPage,
exportAccountingReportExcel, exportAccountingReportExcel,
downloadXml,
} from "@/api/accounting/report"; } from "@/api/accounting/report";
import { getAccessToken } from "@/utils/auth"; import { getAccessToken } from "@/utils/auth";
import { getOrganizationPage } from "@/api/setting/organization"; import { getOrganizationPage } from "@/api/setting/organization";
@ -277,6 +318,7 @@ export default {
fileList2: [], fileList2: [],
// //
open: false, open: false,
open1: false,
// //
queryParams: { queryParams: {
pageNo: 1, pageNo: 1,
@ -295,6 +337,7 @@ export default {
archiveState: null, archiveState: null,
deptId: null, deptId: null,
deptName: null, deptName: null,
inputPassword: null,
}, },
// //
form: {}, form: {},
@ -307,6 +350,9 @@ export default {
period: [ period: [
{ required: true, message: "请输入会计期间", trigger: "blur" }, { required: true, message: "请输入会计期间", trigger: "blur" },
], ],
inputPassword: [
{ required: true, message: "密码不能为空", trigger: "blur" },
],
}, },
uploadUrl: uploadUrl:
process.env.VUE_APP_BASE_API + process.env.VUE_APP_BASE_API +
@ -338,6 +384,10 @@ export default {
this.open = false; this.open = false;
this.reset(); this.reset();
}, },
/** 取消按钮 */
cancel1() {
this.open1 = false;
},
/** 表单重置 */ /** 表单重置 */
reset() { reset() {
this.form = { this.form = {
@ -371,6 +421,26 @@ export default {
this.resetForm("queryForm"); this.resetForm("queryForm");
this.handleQuery(); this.handleQuery();
}, },
//
handleDownloadData() {
this.open1 = true;
this.queryParams.inputPassword = null;
},
submitForm1() {
this.$refs["queryForm"].validate((valid) => {
if (!valid) {
return;
}
//
let params = { ...this.queryParams };
downloadXml(params)
.then((response) => {
this.$download.excel(response, "会计账簿元数据.xml");
this.open1 = false;
})
.catch(() => {});
});
},
/** 新增按钮操作 */ /** 新增按钮操作 */
handleAdd() { handleAdd() {
this.reset(); this.reset();

@ -184,42 +184,55 @@
append-to-body append-to-body
> >
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="业务实体" prop="company"> <!-- <el-form-item label="业务实体" prop="company">
<el-input v-model="form.company" placeholder="请输入业务实体" /> <el-input v-model="form.company" placeholder="请输入业务实体" />
</el-form-item> </el-form-item>
<el-form-item label="所属部门" prop="deptName"> <el-form-item label="所属部门" prop="deptName">
<el-input v-model="form.deptName" placeholder="请输入所属部门" /> <el-input v-model="form.deptName" placeholder="请输入所属部门" />
</el-form-item> </el-form-item> -->
<el-form-item label="凭证号" prop="voucherNum"> <el-row>
<el-input v-model="form.voucherNum" placeholder="请输入凭证号" /> <el-col :span="8">
</el-form-item> <el-form-item label="凭证号" prop="voucherNum">
<el-form-item label="凭证类型" prop="type"> <el-input v-model="form.voucherNum" placeholder="请输入凭证号" />
<el-select v-model="form.type" placeholder="请选择凭证类型"> </el-form-item>
<el-option label="请选择字典生成" value="" /> </el-col>
</el-select> <el-col :span="8">
</el-form-item> <el-form-item label="凭证类型" prop="type">
<el-form-item label="凭证日期" prop="voucherTime"> <el-select v-model="form.type" placeholder="请选择凭证类型">
<el-date-picker <el-option label="请选择字典生成" value="" />
clearable </el-select>
v-model="form.voucherTime" </el-form-item>
type="date" </el-col>
value-format="timestamp" <el-col :span="8">
placeholder="选择凭证日期" <el-form-item label="凭证日期" prop="voucherTime">
/> <el-date-picker
</el-form-item> clearable
<el-form-item label="摘要" prop="digest"> v-model="form.voucherTime"
<el-input v-model="form.digest" placeholder="请输入摘要" /> type="date"
</el-form-item> value-format="timestamp"
<el-form-item label="审核人" prop="audit"> placeholder="选择凭证日期"
<el-input v-model="form.audit" placeholder="请输入审核人" /> />
</el-form-item> </el-form-item>
<el-form-item label="核准人" prop="checker"> </el-col>
<el-input v-model="form.checker" placeholder="请输入核准人" /> </el-row>
</el-form-item> <el-row>
<el-form-item label="经办人" prop="handle"> <el-col :span="8">
<el-input v-model="form.handle" placeholder="请输入经办人" /> <el-form-item label="审核人" prop="audit">
</el-form-item> <el-input v-model="form.audit" placeholder="请输入审核人" />
<el-form-item label="业务标识" prop="serviceId"> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="核准人" prop="checker">
<el-input v-model="form.checker" placeholder="请输入核准人" />
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="经办人" prop="handle">
<el-input v-model="form.handle" placeholder="请输入经办人" />
</el-form-item>
</el-col>
</el-row>
<!-- <el-form-item label="业务标识" prop="serviceId">
<el-input v-model="form.serviceId" placeholder="请输入业务标识" /> <el-input v-model="form.serviceId" placeholder="请输入业务标识" />
</el-form-item> </el-form-item>
<el-form-item label="业务说明" prop="serviceExplain"> <el-form-item label="业务说明" prop="serviceExplain">
@ -283,6 +296,9 @@
>{{ dict.label }}</el-radio >{{ dict.label }}</el-radio
> >
</el-radio-group> </el-radio-group>
</el-form-item> -->
<el-form-item label="摘要" prop="digest">
<el-input v-model="form.digest" placeholder="请输入摘要" />
</el-form-item> </el-form-item>
<el-form-item label="备注" prop="remark"> <el-form-item label="备注" prop="remark">
<el-input <el-input

Loading…
Cancel
Save