diff --git a/src/api/accounting/report.js b/src/api/accounting/report.js new file mode 100644 index 00000000..0fdefb91 --- /dev/null +++ b/src/api/accounting/report.js @@ -0,0 +1,54 @@ +import request from '@/utils/request' + +// 创建会计报表 +export function createAccountingReport(data) { + return request({ + url: '/archives/accounting-report/create', + method: 'post', + data: data + }) +} + +// 更新会计报表 +export function updateAccountingReport(data) { + return request({ + url: '/archives/accounting-report/update', + method: 'put', + data: data + }) +} + +// 删除会计报表 +export function deleteAccountingReport(id) { + return request({ + url: '/archives/accounting-report/delete?id=' + id, + method: 'delete' + }) +} + +// 获得会计报表 +export function getAccountingReport(id) { + return request({ + url: '/archives/accounting-report/get?id=' + id, + method: 'get' + }) +} + +// 获得会计报表分页 +export function getAccountingReportPage(query) { + return request({ + url: '/archives/accounting-report/page', + method: 'get', + params: query + }) +} + +// 导出会计报表 Excel +export function exportAccountingReportExcel(query) { + return request({ + url: '/archives/accounting-report/export-excel', + method: 'get', + params: query, + responseType: 'blob' + }) +} diff --git a/src/api/common/index.js b/src/api/common/index.js index 811c79db..ba7f73d6 100644 --- a/src/api/common/index.js +++ b/src/api/common/index.js @@ -16,4 +16,13 @@ export function uploadFileApi(data) { method: 'post', data: data }) +} + +// 文件上传 +export function uploadInvoiceApi(data) { + return request({ + url: '/accounting/invoices/identify', + method: 'post', + data: data + }) } \ No newline at end of file diff --git a/src/components/UploadImgPdf/index.vue b/src/components/UploadImgPdf/index.vue index e2ba2b7e..76cd0ff6 100644 --- a/src/components/UploadImgPdf/index.vue +++ b/src/components/UploadImgPdf/index.vue @@ -1,17 +1,48 @@ - \ No newline at end of file + diff --git a/src/components/UploadInvoice/index.vue b/src/components/UploadInvoice/index.vue new file mode 100644 index 00000000..3d48e152 --- /dev/null +++ b/src/components/UploadInvoice/index.vue @@ -0,0 +1,221 @@ + + + + + diff --git a/src/views/accounting/book/index.vue b/src/views/accounting/book/index.vue index 94dd1497..74bca118 100644 --- a/src/views/accounting/book/index.vue +++ b/src/views/accounting/book/index.vue @@ -10,20 +10,25 @@ label-width="68px" > - + value-format="yyyy" + type="year" + placeholder="请选择会计年度" + > + - + format="M月" + value-format="M" + type="month" + placeholder="请选择会计期间" + > + - + + + @@ -220,7 +231,6 @@ -
- + --> + + + + + + 发票信息 @@ -523,7 +533,7 @@ - + import("@/components/UploadInvoice") }, data() { return { // 遮罩层 @@ -585,6 +595,7 @@ export default { // 是否显示弹出层 open: false, accountingType: "in", + fileList: [], // 查询参数 queryParams: { pageNo: 1, @@ -678,6 +689,16 @@ export default { }, methods: { + // 上传文件事件 + handleImg(list) { + this.fileList = list; + this.reset(); + }, + handleScan(form) { + const num = form.duplicateMark.toString(); + this.form = form; + this.form.duplicateMark = num; + }, /** * 文件预览 * @param fileUrl @@ -841,6 +862,7 @@ export default { this.reset(); this.open = true; this.title = "添加发票"; + this.fileList = []; }, /** 修改按钮操作 */ handleUpdate(row) { @@ -918,3 +940,10 @@ export default { }, }; + + diff --git a/src/views/accounting/report/index.vue b/src/views/accounting/report/index.vue new file mode 100644 index 00000000..ba7571cb --- /dev/null +++ b/src/views/accounting/report/index.vue @@ -0,0 +1,373 @@ + + + diff --git a/src/views/bs/invoice/components/form.vue b/src/views/bs/invoice/components/form.vue index cb5598ca..760d4b9d 100644 --- a/src/views/bs/invoice/components/form.vue +++ b/src/views/bs/invoice/components/form.vue @@ -1,22 +1,32 @@