From 2871cb99e018f6bf9e2ef76a424a1429a7c818f0 Mon Sep 17 00:00:00 2001 From: xiejun <xj@2023> Date: 星期四, 13 七月 2023 11:40:07 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/UBCS-WEB/src/views/system/tenant.vue | 270 +++++++++++++++++++++++++++-------------------------- 1 files changed, 138 insertions(+), 132 deletions(-) diff --git a/Source/UBCS-WEB/src/views/system/tenant.vue b/Source/UBCS-WEB/src/views/system/tenant.vue index 96ce15c..1a739c4 100644 --- a/Source/UBCS-WEB/src/views/system/tenant.vue +++ b/Source/UBCS-WEB/src/views/system/tenant.vue @@ -1,6 +1,6 @@ <template> <basic-container> - <avue-crud :option="option" + <avue-crud :option="this.option" :table-loading="loading" :data="data" ref="crud" @@ -61,7 +61,7 @@ <el-tag>{{ row.expireTime ? row.expireTime : '涓嶉檺鍒�' }}</el-tag> </template> </avue-crud> - + <el-dialog title="绉熸埛鏁版嵁婧愰厤缃�" append-to-body :visible.sync="datasourceBox" @@ -90,7 +90,7 @@ remove, update, add, - setting, + // setting, datasource, packageInfo, packageSetting @@ -115,117 +115,6 @@ pageSize: 10, currentPage: 1, total: 0 - }, - option: { - height: 'auto', - calcHeight: 30, - tip: false, - searchShow: true, - searchMenuSpan: 6, - border: true, - index: true, - selection: true, - viewBtn: true, - dialogWidth: 900, - dialogClickModal: false, - highlightCurrentRow: true, //琛岄�変腑鏃堕珮浜� - column: [ - { - label: "绉熸埛ID", - prop: "tenantId", - width: 100, - search: true, - addDisplay: false, - editDisplay: false, - span: 24, - rules: [{ - required: true, - message: "璇疯緭鍏ョ鎴稩D", - trigger: "blur" - }] - }, - { - label: "鍏ㄧО", - prop: "fullName", - width: 120, - span:24, - rules: [{ - required: true, - message: "璇疯緭鍏ュ叏绉�", - trigger: "blur" - }] - }, - { - label: "绉熸埛鍚嶇О", - prop: "tenantName", - search: true, - width: 180, - span: 24, - rules: [{ - required: true, - message: "璇疯緭鍏ュ弬鏁板悕绉�", - trigger: "blur" - }] - }, - { - label: "鑱旂郴浜�", - prop: "linkman", - width: 150, - search: true, - rules: [{ - required: true, - message: "璇疯緭鍏ヨ仈绯讳汉", - trigger: "blur" - }] - }, - { - label: "鑱旂郴鐢佃瘽", - prop: "contactNumber", - width: 150, - }, - { - label: "鑱旂郴鍦板潃", - prop: "address", - span: 24, - minRows: 2, - type: "textarea", - hide: true, - }, - { - label: '寮�鍚笁鍛�', - prop: 'ssaEnable', - type: 'radio', - width: 100, - value:0, - disabled:Boolean, - dicData: [{ - label: '寮�鍚�', - value: 0 - }, { - label: '涓嶅紑鍚�', - value: 1 - },], - }, - { - label: "缁戝畾鍩熷悕", - prop: "domainUrl", - span: 24, - }, - { - label: "绯荤粺鑳屾櫙", - prop: "backgroundUrl", - type: 'upload', - listType: 'picture-img', - dataType: 'string', - action: '/api/ubcs-resource/oss/endpoint/put-file', - propsHttp: { - res: 'data', - url: 'link', - }, - hide: true, - span: 24, - }, - ] }, data: [], settingForm: {}, @@ -298,14 +187,12 @@ }, ] }, + BooleanFlag:Boolean, }; }, created() { - // 鑾峰彇鍒皌rue杩樻槸false鐩存帴璧嬪�硷紝瀹氫箟鏂规硶浼氬氨鏄幏鍙栦笉鍒帮紝涓嶇煡閬撲粈涔堥棶棰橈紝寮哄埗鐢↗SON.parse浼氬湪鍚庨潰杩藉姞涓�涓猟isabled锛屾墍浠ョ洿鎺ヨ幏鍙栥�傚悗鏈熷鏋滄坊鍔燾loumn浼氬嚭鐜癰ug锛岀敤foreach寰幆鍑篶olumn鍦ㄥ垽鏂璽ype鏄惁绛変簬radio锛岀劧鍚庡皢鍗曠嫭radio鐨刣isabled鏀逛负res.data.data - this.$axios.get('/api/ubcs-system/tenant/find-ssa-enable').then(res => { - this.option.column[6].disabled= res.data.data - }); + this.initBoolean() }, watch: { 'packageForm.packageId'() { @@ -336,9 +223,128 @@ }, tenantId() { return this.selectionList[0].tenantId; + }, + option(){ + return{ + height: 'auto', + calcHeight: 30, + tip: false, + searchShow: true, + searchMenuSpan: 6, + border: true, + index: true, + selection: true, + viewBtn: true, + dialogWidth: 900, + dialogClickModal: false, + highlightCurrentRow: true, //琛岄�変腑鏃堕珮浜� + column: [ + { + label: "绉熸埛ID", + prop: "tenantId", + width: 100, + search: true, + addDisplay: false, + editDisplay: false, + span: 24, + rules: [{ + required: true, + message: "璇疯緭鍏ョ鎴稩D", + trigger: "blur" + }] + }, + { + label: "鍏ㄧО", + prop: "fullName", + width: 120, + span:24, + rules: [{ + required: true, + message: "璇疯緭鍏ュ叏绉�", + trigger: "blur" + }] + }, + { + label: "绉熸埛鍚嶇О", + prop: "tenantName", + search: true, + width: 180, + span: 24, + rules: [{ + required: true, + message: "璇疯緭鍏ュ弬鏁板悕绉�", + trigger: "blur" + }] + }, + { + label: "鑱旂郴浜�", + prop: "linkman", + width: 150, + search: true, + rules: [{ + required: true, + message: "璇疯緭鍏ヨ仈绯讳汉", + trigger: "blur" + }] + }, + { + label: "鑱旂郴鐢佃瘽", + prop: "contactNumber", + width: 150, + }, + { + label: "鑱旂郴鍦板潃", + prop: "address", + span: 24, + minRows: 2, + type: "textarea", + hide: true, + }, + { + label: '寮�鍚笁鍛�', + prop: 'ssaEnable', + type: 'radio', + width: 100, + value:0, + disabled:this.BooleanFlag , + dicData: [{ + label: '寮�鍚�', + value: 0 + }, { + label: '涓嶅紑鍚�', + value: 1 + },], + }, + { + label: "缁戝畾鍩熷悕", + prop: "domainUrl", + span: 24, + }, + { + label: "绯荤粺鑳屾櫙", + prop: "backgroundUrl", + type: 'upload', + listType: 'picture-img', + dataType: 'string', + action: '/api/ubcs-resource/oss/endpoint/put-file', + propsHttp: { + res: 'data', + url: 'link', + }, + hide: true, + span: 24, + }, + ] + } } }, methods: { + initBoolean(){ + this.$axios.get('/api/ubcs-system/tenant/find-ssa-enable').then(res => { + this.BooleanFlag=res.data.data; + //console.log('---',res) + }); + }, initData() { getMenuTree().then(res => { const column = this.findObject(this.packageOption.column, "menuId"); @@ -510,20 +516,20 @@ handlePackageSetting() { this.packageSettingBox = true; }, - handleSubmit(form, done, loading) { - setting(this.ids, form).then(() => { - this.onLoad(this.page); - this.$message({ - type: "success", - message: "閰嶇疆鎴愬姛!" - }); - done(); - this.box = false; - }, error => { - window.console.log(error); - loading(); - }); - }, + // handleSubmit(form, done, loading) { + // setting(this.ids, form).then(() => { + // this.onLoad(this.page); + // this.$message({ + // type: "success", + // message: "閰嶇疆鎴愬姛!" + // }); + // done(); + // this.box = false; + // }, error => { + // window.console.log(error); + // loading(); + // }); + // }, handleDatasourceSubmit(form, done, loading) { datasource(this.tenantId, form.datasourceId).then(() => { this.$message({ -- Gitblit v1.9.3