diff --git a/.env.local b/.env.local index 3e21c0ed..e1468d87 100644 --- a/.env.local +++ b/.env.local @@ -5,8 +5,8 @@ ENV = 'development' VUE_APP_TITLE = 链友融财务数字一体化信息系统 # 芋道管理系统/本地环境 -# VUE_APP_BASE_API = '/proxy-api' -VUE_APP_BASE_API = 'http://127.0.0.1:48080' +VUE_APP_BASE_API = '/proxy-api' +# VUE_APP_BASE_API = 'http://127.0.0.1:48080' # 路由懒加载 VUE_CLI_BABEL_TRANSPILE_MODULES = true @@ -22,3 +22,10 @@ VUE_APP_DOC_ENABLE = true # 百度统计 VUE_APP_BAIDU_CODE = fadc1bd5db1a1d6f581df60a1807f8ab + +#线上预览 +VUE_APP_ONLINE_API = 'http://139.224.253.31:48012' + +#报表 +# VUE_APP_BIAO_API = 'http://139.224.253.31:48080' +VUE_APP_BIAO_API = 'http://192.168.3.172:48080' diff --git a/.env.prod b/.env.prod index 4d5d31e8..57311843 100644 --- a/.env.prod +++ b/.env.prod @@ -23,3 +23,9 @@ VUE_APP_DOC_ENABLE = false # 百度统计 VUE_APP_BAIDU_CODE = fadc1bd5db1a1d6f581df60a1807f8ab + +#线上预览 +VUE_APP_ONLINE_API = 'http://139.224.253.31:48012' + +#报表 +VUE_APP_BIAO_API = 'http://139.224.253.31:48080' diff --git a/src/components/iFrame/index.vue b/src/components/iFrame/index.vue index 426857fb..3ce6e79e 100644 --- a/src/components/iFrame/index.vue +++ b/src/components/iFrame/index.vue @@ -13,16 +13,19 @@ export default { props: { src: { type: String, - required: true + required: true, }, }, data() { return { height: document.documentElement.clientHeight - 94.5 + "px;", loading: true, - url: this.src + url: this.src, }; }, + created() { + console.log(this.url); + }, mounted: function () { setTimeout(() => { this.loading = false; @@ -31,6 +34,6 @@ export default { window.onresize = function temp() { that.height = document.documentElement.clientHeight - 94.5 + "px;"; }; - } + }, }; diff --git a/src/utils/dict.js b/src/utils/dict.js index 4ea6c05d..5294adea 100644 --- a/src/utils/dict.js +++ b/src/utils/dict.js @@ -143,6 +143,8 @@ export const DICT_TYPE = { BORROW_STATUS: 'borrow_status', //会计凭证类型 ACCOUNTING_VOUCHER_TYPE: 'accounting_voucher_type', + //银行回单认款状态 + BANK_CONFIRM_STATUS: 'bank_confirm_status', } diff --git a/src/views/accounting/attachment/index.vue b/src/views/accounting/attachment/index.vue index 7f73bccc..c21ac4c6 100644 --- a/src/views/accounting/attachment/index.vue +++ b/src/views/accounting/attachment/index.vue @@ -161,16 +161,19 @@ > - - - + + @@ -307,9 +310,11 @@ export default { * @param fileUrl */ openLink(fileUrl) { - const url = `http://139.224.253.31:48012/onlinePreview?url=${encodeURIComponent( - this.base64Encode(fileUrl) - )}`; + console.log(process.env.VUE_APP_ONLINE_API); + // const url = `http://139.224.253.31:48012/onlinePreview?url=${encodeURIComponent(this.base64Encode(fileUrl))}`; + const url = + process.env.VUE_APP_ONLINE_API + + `/onlinePreview?url=${encodeURIComponent(this.base64Encode(fileUrl))}`; window.open(url); }, /** 取消按钮 */ @@ -372,6 +377,11 @@ export default { this.form.fileName = res.data.name; this.form.fileSize = res.data.size; }, + //凭证选择 + handleSelectVoucher(val) { + this.form.voucherId = val.id; + this.form.voucherNum = val.voucherNum; + }, /** 提交按钮 */ submitForm() { this.$refs["form"].validate((valid) => { diff --git a/src/views/accounting/bankSlip/index.vue b/src/views/accounting/bankSlip/index.vue index b03715b1..3e9abf81 100644 --- a/src/views/accounting/bankSlip/index.vue +++ b/src/views/accounting/bankSlip/index.vue @@ -85,10 +85,10 @@ @keyup.enter.native="handleQuery" /> - + @@ -164,7 +164,7 @@ - + @@ -544,6 +607,8 @@ import { downloadXml, getBankSlipPageTime, } from "@/api/accounting/bankSlip"; +import { getAccessToken, getTenantId } from "@/utils/auth"; +import { listUser } from "@/api/system/user"; export default { name: "BankSlip", @@ -565,6 +630,7 @@ export default { // 是否显示弹出层 open: false, open1: false, + open2: false, // 查询参数 queryParams: { pageNo: 1, @@ -612,15 +678,27 @@ export default { password: null, inputPassword: null, }, + userOptions: [], //用户数据 // 表单参数 form: {}, + form1: {}, // 表单校验 - rules: {}, + rules: { + staffName: [{ required: true, message: "请选择", trigger: "blur" }], + }, + fileList: [], // 文件列表 + uploadUrl: + process.env.VUE_APP_BASE_API + "/admin-api/archives/flow/upload", // 上传地址地址 + headers: { + Authorization: "Bearer " + getAccessToken(), + "tenant-id": getTenantId(), + }, // 设置上传的请求头 time: "", }; }, created() { this.getList(); + this.getUserList(); }, methods: { /** 查询列表 */ @@ -643,6 +721,12 @@ export default { this.loading = false; }); }, + //获取用户 + getUserList() { + listUser().then((response) => { + this.userOptions = response.data.list; + }); + }, handleOneMonth() { this.time = 1; this.getList2(); @@ -663,6 +747,12 @@ export default { /** 取消按钮 */ cancel1() { this.open1 = false; + this.reset(); + }, + /** 取消按钮 */ + cancel2() { + this.open2 = false; + this.reset(); }, /** 表单重置 */ reset() { @@ -709,6 +799,12 @@ export default { archiveState: undefined, password: undefined, }; + this.form1 = { + id: undefined, + staffId: undefined, + staffName: undefined, + subscriptionStatus: undefined, + }; this.resetForm("form"); }, /** 搜索按钮操作 */ @@ -727,6 +823,10 @@ export default { this.open = true; this.title = "添加银行回单"; }, + // 上传成功的函数 + handleSuccess(res) { + console.log(res); + }, /** 修改按钮操作 */ handleUpdate(row) { this.reset(); @@ -737,6 +837,43 @@ export default { this.title = "修改银行回单"; }); }, + /** 认款按钮操作 */ + handleComfirm(val) { + this.reset(); + this.form1.id = val.id; + this.open2 = true; + }, + handleSelectUser(val) { + this.form1.staffId = val.id; + this.form1.staffName = val.username; + }, + submitForm2() { + this.form1.subscriptionStatus = 1; + this.$refs["form1"].validate((valid) => { + if (!valid) { + return; + } + updateBankSlip(this.form1).then((response) => { + this.$modal.msgSuccess("认款成功"); + this.open2 = false; + this.getList(); + }); + }); + }, + /** 取消认款按钮操作 */ + handleUnComfirm(val) { + this.reset(); + const data = { id: val.id, subscriptionStatus: 0 }; + this.$modal + .confirm('是否确认取消银行回单编号为"' + val.id + '"的认款?') + .then(function () { + updateBankSlip(data).then((response) => {}); + }) + .then(() => { + this.getList(); + this.$modal.msgSuccess("取消成功"); + }); + }, /** 提交按钮 */ submitForm() { this.$refs["form"].validate((valid) => { @@ -762,6 +899,7 @@ export default { }, //下载元数据 handleDownloadData() { + this.reset(); this.open1 = true; this.queryParams.inputPassword = null; }, diff --git a/src/views/accounting/book/index.vue b/src/views/accounting/book/index.vue index f3b0d706..5bcfba5c 100644 --- a/src/views/accounting/book/index.vue +++ b/src/views/accounting/book/index.vue @@ -79,11 +79,11 @@ - + @@ -106,14 +106,14 @@ class-name="small-padding fixed-width" > - - - - - - - - + + + + + - - - - - - - - @@ -270,6 +262,7 @@ import { downloadXml, } from "@/api/accounting/flow"; import { getAccessToken, getTenantId } from "@/utils/auth"; +import { getVoucherPage } from "@/api/accounting/voucher"; export default { name: "Flow", @@ -291,7 +284,6 @@ export default { // 是否显示弹出层 open: false, open1: false, - fileList: [], imgType: ".jpeg, .jpg, .png", // 查询参数 queryParams: { @@ -328,10 +320,12 @@ export default { Authorization: "Bearer " + getAccessToken(), "tenant-id": getTenantId(), }, // 设置上传的请求头 + kjpzOptions: [], //会计凭证 }; }, created() { this.getList(); + this.getKJPZ(); }, methods: { /** 查询列表 */ @@ -344,6 +338,12 @@ export default { this.loading = false; }); }, + //获取会计凭证 + getKJPZ() { + getVoucherPage().then((res) => { + this.kjpzOptions = res.data.list || []; + }); + }, openLink(fileUrl) { window.open(fileUrl); }, @@ -352,10 +352,10 @@ export default { this.open = false; this.reset(); }, - /** 取消按钮 */ cancel1() { this.open1 = false; + this.reset(); }, /** 表单重置 */ reset() { @@ -408,6 +408,11 @@ export default { this.title = "修改审批流程"; }); }, + //凭证选择 + handleSelectVoucher(val) { + this.form.voucherId = val.id; + this.form.voucherNum = val.voucherNum; + }, /** 提交按钮 */ submitForm() { this.$refs["form"].validate((valid) => { @@ -470,6 +475,7 @@ export default { }, //下载元数据 handleDownloadData() { + this.reset(); this.open1 = true; this.queryParams.inputPassword = null; }, diff --git a/src/views/accounting/invoices/index.vue b/src/views/accounting/invoices/index.vue index 51f8222e..2f7545f1 100644 --- a/src/views/accounting/invoices/index.vue +++ b/src/views/accounting/invoices/index.vue @@ -918,9 +918,9 @@ export default { * @param fileUrl */ openLink(fileUrl) { - const url = `http://139.224.253.31:48012/onlinePreview?url=${encodeURIComponent( - this.base64Encode(fileUrl) - )}`; + const url = + process.env.VUE_APP_ONLINE_API + + `/onlinePreview?url=${encodeURIComponent(this.base64Encode(fileUrl))}`; window.open(url); }, handleClick(tab) { diff --git a/src/views/accounting/other/index.vue b/src/views/accounting/other/index.vue index 2664ef6a..6519d207 100644 --- a/src/views/accounting/other/index.vue +++ b/src/views/accounting/other/index.vue @@ -340,9 +340,9 @@ export default { * @param fileUrl 地址 */ openLink(fileUrl) { - const url = `http://139.224.253.31:48012/onlinePreview?url=${encodeURIComponent( - this.base64Encode(fileUrl) - )}`; + const url = + process.env.VUE_APP_ONLINE_API + + `/onlinePreview?url=${encodeURIComponent(this.base64Encode(fileUrl))}`; window.open(url); }, /** 查询列表 */ diff --git a/src/views/accounting/voucher/index.vue b/src/views/accounting/voucher/index.vue index e3ec5eb8..da840549 100644 --- a/src/views/accounting/voucher/index.vue +++ b/src/views/accounting/voucher/index.vue @@ -149,7 +149,7 @@ @@ -288,81 +288,53 @@ @tab-click="handleClick" > -
-
- -
-
- + + > +
-
+
+ + +
-
-
- +
+ +
-
+ -
+
+ + +