Commit 1490c705 authored by 向偲彪's avatar 向偲彪 Committed by qiaozhanwei
Browse files

merge dev branch front-end code (#1786)

parent 6b4caff8
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -177,8 +177,6 @@ Dag.prototype.backfill = function (arg) {
      // Number of tree node levels
      let countTree = getLeafCountTree(datas[0])
      function getMaxFloor(treeData) {
        let floor = 0
        let v = this
        let max = 0
        function each (data, floor) {
          data.forEach(e => {
@@ -224,9 +222,8 @@ Dag.prototype.backfill = function (arg) {
          return []
        }
        function toLine(data){
          return data.reduce((arr, {id, name, targetarr, x, y, children = []}) =>
          arr.concat([{id, name, targetarr, x, y}], toLine(children)), [])
          return result;
          return data.reduce((arrData, {id, name, targetarr, x, y, children = []}) =>
          arrData.concat([{id, name, targetarr, x, y}], toLine(children)), [])
        }
        let listarr = toLine(datas);
        let listarrs = toLine(datas)
+11 −14
Original line number Diff line number Diff line
@@ -317,6 +317,7 @@ svg path:hover {
.jtk-demo-canvas {
  position: relative;
  height: 100%;
  display: flex;
}

.jtk-bootstrap {
@@ -359,10 +360,6 @@ svg path:hover {
  list-style-type: disc !important;
}

.jtk-demo-canvas {
  display: flex;
}

.canvas-wide {
  padding-top: 10px;
  margin-left: 0;
@@ -459,6 +456,12 @@ svg path:hover {
  -webkit-transition: background-color 0.25s ease-in;
  -moz-transition: background-color 0.25s ease-in;
  transition: background-color 0.25s ease-in;
  background-color: white;
  opacity: 0.8;
  padding: 0.3em;
  border-radius: 0.5em;
  border: 1px solid #346789;
  cursor: pointer;
}

.aLabel.jtk-hover,
@@ -485,14 +488,6 @@ svg path:hover {
  }
}

.aLabel {
  background-color: white;
  opacity: 0.8;
  padding: 0.3em;
  border-radius: 0.5em;
  border: 1px solid #346789;
  cursor: pointer;
}

.jtk-ep {
  .ep {
@@ -552,3 +547,5 @@ svg path:hover {
  width: 628px;
  left: auto;
}

+14 −6
Original line number Diff line number Diff line
@@ -58,7 +58,7 @@
          </x-button>
          <span class="name">{{name}}</span>
          &nbsp;
          <span v-if="name"  class="copy-name" @click="_copyName" :data-clipboard-text="name"><i class="ans-icon-copy" data-container="body"  data-toggle="tooltip" :title="$t('Copy name')" ></i></span>
          <span v-if="name"  class="copy-name" @click="_copyName" :data-clipboard-text="name"><em class="ans-icon-copy" data-container="body"  data-toggle="tooltip" :title="$t('Copy name')" ></em></span>
        </div>
        <div class="save-btn">
          <div class="operation" style="vertical-align: middle;">
@@ -68,7 +68,7 @@
               :id="item.code"
               :key="$index"
               @click="_ckOperation(item,$event)">
              <i :class="item.icon" data-toggle="tooltip" :title="item.description" ></i>
              <em :class="item.icon" data-toggle="tooltip" :title="item.description" ></em>
            </a>
          </div>
          <x-button type="text" icon="ans-icon-triangle-solid-right" @click="dagAutomaticLayout"></x-button>
@@ -156,7 +156,7 @@
    },
    methods: {
      ...mapActions('dag', ['saveDAGchart', 'updateInstance', 'updateDefinition', 'getTaskState']),
      ...mapMutations('dag', ['addTasks', 'resetParams', 'setIsEditDag', 'setName']),
      ...mapMutations('dag', ['addTasks', 'cacheTasks', 'resetParams', 'setIsEditDag', 'setName']),

      // DAG automatic layout
      dagAutomaticLayout() {
@@ -257,8 +257,8 @@
                  let state = dom.find('.state-p')
                  dom.attr('data-state-id', v1.stateId)
                  dom.attr('data-dependent-result', v1.dependentResult || '')
                  state.append(`<b class="${v1.icoUnicode} ${v1.isSpin ? 'as as-spin' : ''}" style="color:${v1.color}" data-toggle="tooltip" data-html="true" data-container="body"></b>`)
                  state.find('b').attr('title', titleTpl(v2, v1.desc))
                  state.append(`<strong class="${v1.icoUnicode} ${v1.isSpin ? 'as as-spin' : ''}" style="color:${v1.color}" data-toggle="tooltip" data-html="true" data-container="body"></strong>`)
                  state.find('strong').attr('title', titleTpl(v2, v1.desc))
                }
              })
            })
@@ -495,6 +495,14 @@
                  removeNodesEvent(fromThis)
                }, 100)
              },
              /**
               * Cache the item
               * @param item
               * @param fromThis
               */
              cacheTaskInfo({item, fromThis}) {
                self.cacheTasks(item)
              },
              close ({ flag, fromThis }) {
                // Edit status does not allow deletion of nodes
                if (flag) {
+2 −2
Original line number Diff line number Diff line
@@ -32,8 +32,8 @@
              :value="selectedModel === null ? '0' : selectedModel.value"
              style="width: 100%;"
              @on-click-icon.stop="_ckIcon">
        <i slot="suffix" class="ans-icon-fail-solid" style="font-size: 15px;cursor: pointer;" v-show="!isIconState"></i>
        <i slot="suffix" class="ans-icon-arrow-down" style="font-size: 12px;" v-show="isIconState"></i>
        <em slot="suffix" class="ans-icon-fail-solid" style="font-size: 15px;cursor: pointer;" v-show="!isIconState"></em>
        <em slot="suffix" class="ans-icon-arrow-down" style="font-size: 12px;" v-show="isIconState"></em>
      </x-input>
    <x-option
            v-for="city in list"
+0 −2
Original line number Diff line number Diff line
@@ -115,8 +115,6 @@
        color: #0097e0;
      }
    }
    &:hover {
    }
    .list-t {
      width: 50%;
      float: left;
Loading