田源
2023-12-08 159c95cafb4f0eb3955c9e4adc3134585512455d
Source/UBCS-WEB/src/views/modeling/Business.vue
@@ -4,7 +4,7 @@
<!--    </el-header>-->
    <el-container>
      <el-aside>
      <el-aside style="width: 20%">
        <basic-container class="businessTreeContainer">
          <div class="app">
            <div style="display: flex;margin-bottom: 10px;justify-content: space-around;">
@@ -18,13 +18,13 @@
                         @click="selectFromTable" plain> 从已有中获取
              </el-button>
            </div>
            <avue-tree :data="treeData" :option="treeOption" class="businessTree" @node-click="nodeClick">
            <span slot-scope="{ node, data }" class="el-tree-node__label">
            <avue-tree :data="treeData" :option="treeOption" class="businessTree" @node-click="nodeClick" style="width: fit-content;">
            <template slot-scope="{ node, data }" class="el-tree-node__label">
              <span>
                <i :class="(node || {}).level === 2 ? 'el-icon-star-off' : 'el-icon-folder-opened'"></i>
                {{ (node || {}).label }}
              </span>
            </span>
            </template>
            </avue-tree>
          </div>
@@ -144,7 +144,7 @@
        </el-dialog>
      </el-container>
    </el-container>
    <business-add ref="btmAdd" :btmType="addOption.btmType" :domainOption="domainOptions" :icons="icons"
    <business-add ref="btmAdd" :btmType="addOption.btmType" :domainOption="domainOptions" :icons="icons" :type="type"
                  @refreshTable="initTreeOnLoad">
    </business-add>
  </el-container>
@@ -163,6 +163,7 @@
  name: "Business",
  data() {
    return {
      type:"",
      //生命周期对话框状态
      packageLifeBox: false,
      //版本规则状态
@@ -171,7 +172,7 @@
      selectionList: [],
      treeData: [],
      treeOption: {
        defaultExpandAll: true,
        defaultExpandAll: false,
        title: '业务类型树',
        addBtn: false,
        menu: false,
@@ -186,8 +187,8 @@
        btmType: {},
      },
      loadOption: {
        height:'auto',
        border: true,
        height: 478,
        editBtn: false,
        addBtn: false,
        menu: false,
@@ -362,6 +363,7 @@
    businessAdd() {
      this.$refs.btmAdd.showSubmitDialog = true;
      this.$refs.btmAdd.btmType = {};
      this.type = 'add';
      this.ifRefreshBtmAddRefresh();
    },
    businessEdit() {
@@ -372,6 +374,7 @@
      const json = JSON.stringify(this.obj);
      this.$refs.btmAdd.btmType = JSON.parse(json);
      this.$refs.btmAdd.showSubmitDialog = true;
      this.type = 'edit'
      this.ifRefreshBtmAddRefresh();
    },
    ifRefreshBtmAddRefresh() {
@@ -381,7 +384,7 @@
}
</script>
<style lang="scss">
<style lang="scss" scoped>
.businessCrud > .el-card:nth-of-type(2) > .el-card__body > .avue-crud__menu {
  display: none !important;
@@ -394,7 +397,7 @@
.app {
  overflow: auto;
  height: calc(100vh - 150px);
  height: 84.3vh;
}
.app::-webkit-scrollbar {
@@ -407,8 +410,12 @@
// 滚动条的滑块
.app::-webkit-scrollbar-thumb {
  width: 10px;
  height: 10px;
  background-color: #ececec;
  border-radius: 20px;
  border: #ececec;
}
</style>