From 8835c9e1dec836d6d8159e78b9df12ad6402ad98 Mon Sep 17 00:00:00 2001 From: 田源 <lastanimals@163.com> Date: 星期四, 14 十一月 2024 10:03:24 +0800 Subject: [PATCH] 修复bug 整合代码 --- Source/plt-web/plt-web-ui/src/views/authority/secure/machineClassification/index.vue | 122 +++++++++++++++++++++++++--------------- 1 files changed, 76 insertions(+), 46 deletions(-) diff --git a/Source/plt-web/plt-web-ui/src/views/authority/secure/machineClassification/index.vue b/Source/plt-web/plt-web-ui/src/views/authority/secure/machineClassification/index.vue index 308c333..97a3686 100644 --- a/Source/plt-web/plt-web-ui/src/views/authority/secure/machineClassification/index.vue +++ b/Source/plt-web/plt-web-ui/src/views/authority/secure/machineClassification/index.vue @@ -41,52 +41,82 @@ </el-container> </template> - <script> export default { - name: "index" -} + data() { + return { + form: {}, + data: [ + { + name: "寮犱笁", + sex: "鐢�", + showType:'Ludc' + }, + ], + option: { + column: [ + { + label: "濮撳悕", + prop: "name", + }, + { + label: "鎬у埆", + prop: "sex", + type: "select", + dicData: [ + { + label: "鐢�", + value: 0, + }, + { + label: "濂�", + value: 1, + }, + ], + }, + { + label: '婧愬璞�', + prop: 'showType', + type: 'select', + cascader: ['linkType', 'templateId', 'SubUILayout', 'searchObjType', 'queryTemplateName'], + placeholder: "璇疯緭鍏ュ唴瀹�", + dicUrl: '/api/uiManagerController/getBtmDatasByPage?page=1&limit=-1', + filterable: true, + props: { + label: 'name', + value: 'name', + desc: 'label' + }, + rules: [ + { + required: true, + message: '璇烽�夋嫨鍐呭', + trigger: 'change' + } + ], + }, + ], + }, + }; + }, + methods: { + beforeOpen(done, type) { + this.$alert(`鎴戞槸${type}`, { + confirmButtonText: "纭畾", + callback: (action) => { + if (["view", "edit"].includes(type)) { + // 鏌ョ湅鍜岀紪杈戦�昏緫 + this.form.showType = 'Ludc'; + } else { + //鏂板閫昏緫 + this.form.name = "鍒濆鍖栬祴鍊�"; + this.form.sex = 0; + this.form.showType = 'Ludc'; + } + done(); + }, + }); + }, + }, +}; </script> - -<style lang="scss" scoped> -::v-deep { - .el-scrollbar__wrap { - overflow: auto !important; - } - .headerCon{ - .el-button{ - width: 82px; - } - } -} - -.headerCon { - display: flex; - flex-wrap: wrap; - margin-bottom: 5px; - - .el-button + .el-button { - margin-left: 5px; - } - - .el-button { - margin-top: 5px; - } -} - -.headerCon > .el-button:nth-child(4) { - margin-left: 0; -} - -.headerCon > .el-button:nth-child(7) { - margin-left: 0; -} - - -.smallBtn { - width: 82px; - text-align: center; - padding-left: 4.5px; -} - -</style> -- Gitblit v1.9.3