| | |
| | | <el-container> |
| | | <!-- 顶端按钮 --> |
| | | <el-header class="businessHeader" style="height: 40px;"> |
| | | <el-button-group> |
| | | <el-button type="primary" @click="linkTypeAdd" size="small"> |
| | | <i class="el-icon-plus"></i> |
| | | 新增 |
| | | </el-button> |
| | | <el-button type="primary" @click="linkTypeEdit" size="small"> |
| | | <i class="el-icon-edit"></i> |
| | | 修改 |
| | | </el-button> |
| | | </el-button-group> |
| | | <div> |
| | | <el-button type="primary" @click="linkTypeAdd" size="small" icon="el-icon-plus" v-if="permissionList.addBtn"> |
| | | 新增 |
| | | </el-button> |
| | | <el-button type="primary" @click="linkTypeEdit" size="small" icon="el-icon-edit" v-if="permissionList.editBtn"> |
| | | 修改 |
| | | </el-button> |
| | | </div> |
| | | </el-header> |
| | | <!-- 侧边栏树 --> |
| | | <el-container> |
| | |
| | | <i :class="icons.domain"></i> |
| | | 所属领域 |
| | | </template> |
| | | <el-tag size="small"> |
| | | <el-tag v-if="obj.domainText" size="small"> |
| | | {{ obj.domainText }} |
| | | </el-tag> |
| | | </el-descriptions-item> |
| | |
| | | </el-descriptions> |
| | | |
| | | <el-descriptions class="margin-top" :column="2" size="medium" border> |
| | | <!-- |
| | | <!-- |
| | | <el-descriptions-item :labelStyle="descriptionOption.labelStyle" |
| | | :contentStyle="descriptionOption.contentStyle"> |
| | | <template slot="label"> |
| | |
| | | </template> |
| | | {{ obj.description }} |
| | | </el-descriptions-item> |
| | | </el-descriptions> |
| | | </el-descriptions> |
| | | </basic-container> |
| | | <!-- 属性列表--> |
| | | <basic-container> |
| | |
| | | |
| | | </el-container> |
| | | </template> |
| | | |
| | | |
| | | <script> |
| | | import { |
| | | initTree, |
| | |
| | | saveFromTable, |
| | | getDetail |
| | | } from "@/api/omd/linkType" |
| | | import {mapGetters} from "vuex"; |
| | | export default { |
| | | name: "LinkType", |
| | | data() { |
| | | return { |
| | | addOption: { |
| | | linkType: {}, |
| | | linkType: { |
| | | attributes:[] |
| | | }, |
| | | }, |
| | | domain: null, |
| | | domainOptions: [], |
| | |
| | | }, |
| | | loadOption: { |
| | | border: true, |
| | | height: 360, |
| | | height: 395, |
| | | editBtn: false, |
| | | addBtn: false, |
| | | menu: false, |
| | |
| | | }, |
| | | } |
| | | }, |
| | | computed:{ |
| | | ...mapGetters(["permission"]), |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.modeling_LinkType.LinkType_add, false), |
| | | editBtn: this.vaildData(this.permission.modeling_LinkType.LinkType_edit, false), |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | this.initTreeOnLoad(); |
| | | this.initDomainOption(); |
| | |
| | | }, |
| | | // 添加按钮点击事件 |
| | | linkTypeAdd() { |
| | | this.$refs.linkAdd.linkType = {}; |
| | | this.$refs.linkAdd.showSubmitDialog = true; |
| | | }, |
| | | // 编辑按钮点击事件 |
| | | linkTypeEdit() { |
| | | this.addOption.linkType = this.obj; |
| | | var linktype = this.obj; |
| | | linktype.fromBtmValues = this.obj.fromBtmTypes; |
| | | linktype.toBtmValues = this.obj.toBtmTypes; |
| | | linktype.attributes = this.obj.attributes; |
| | | var json = JSON.stringify(linktype); |
| | | this.addOption.linkType = JSON.parse(json); |
| | | this.$refs.linkAdd.linkType = this.addOption.linkType; |
| | | this.$refs.linkAdd.showSubmitDialog = true; |
| | | }, |
| | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | |
| | | <style lang="scss"> |
| | | .attributeCrud>.el-card:nth-of-type(2)>.el-card__body>.avue-crud__menu { |
| | | display: none !important; |
| | | } |
| | | </style> |
| | | |