From f99e979d1484f826e35794ba7d9d03ad8a6fc89f Mon Sep 17 00:00:00 2001 From: gtz <535262213@qq.com> Date: Thu, 7 Dec 2023 10:06:14 +0800 Subject: [PATCH] '1' --- .env.dev | 2 +- .env.prod | 2 +- src/views/base/custom/index.vue | 20 ++++++++++++++------ src/views/system/dept/index.vue | 1 + 4 files changed, 17 insertions(+), 8 deletions(-) diff --git a/.env.dev b/.env.dev index 1da25e71..9fa09014 100644 --- a/.env.dev +++ b/.env.dev @@ -13,7 +13,7 @@ VUE_APP_TITLE = MES系统 # 芋道管理系统/开发环境 # VUE_APP_BASE_API = 'http://100.64.0.26:48082' -VUE_APP_BASE_API = 'http://192.168.0.33:48082' +VUE_APP_BASE_API = 'http://10.70.2.2:8080' # VUE_APP_BASE_API = 'http://192.168.4.173:48080' # VUE_APP_BASE_API = 'http://192.168.2.173:48080' # VUE_APP_BASE_API = 'http://192.168.1.49:48082' diff --git a/.env.prod b/.env.prod index 085ca647..d89ed16a 100644 --- a/.env.prod +++ b/.env.prod @@ -15,7 +15,7 @@ VUE_APP_TITLE = MES系统 VUE_APP_BASE_API = '/prod-api' # 积木报表指向地址 -VUE_APP_JIMU_API = 'http://10.70.2.2:8080' +VUE_APP_JIMU_API = 'http://10.70.2.22:8080' # 根据服务器或域名修改 diff --git a/src/views/base/custom/index.vue b/src/views/base/custom/index.vue index 97c816dc..d216aac8 100644 --- a/src/views/base/custom/index.vue +++ b/src/views/base/custom/index.vue @@ -268,17 +268,25 @@ export default { // }) // } else { $('.hiprintEpContainer').empty() - console.log(this.modelData); + console.log(this.modelData || {}); hiprint.PrintElementTypeManager.build('.hiprintEpContainer', provider.value) $('.hiprint-printTemplate').empty() // const templates = this.$ls.get('KEY_TEMPLATES', {}) const template = provider.value // console.log(template) - hiprintTemplate = new hiprint.PrintTemplate({ - template: this.modelData != '' ? JSON.parse(this.modelData) : {}, - settingContainer: '#PrintElementOptionSetting', - paginationContainer: '.hiprint-printPagination' - }) + if (this.modelData) { + hiprintTemplate = new hiprint.PrintTemplate({ + template: JSON.parse(this.modelData), + settingContainer: '#PrintElementOptionSetting', + paginationContainer: '.hiprint-printPagination' + }) + } else { + hiprintTemplate = new hiprint.PrintTemplate({ + template: {}, + settingContainer: '#PrintElementOptionSetting', + paginationContainer: '.hiprint-printPagination' + }) + } // } hiprintTemplate.design('#hiprint-printTemplate') // console.log(hiprintTemplate) diff --git a/src/views/system/dept/index.vue b/src/views/system/dept/index.vue index 3397a935..9561f92e 100644 --- a/src/views/system/dept/index.vue +++ b/src/views/system/dept/index.vue @@ -28,6 +28,7 @@ +