|
@@ -1,27 +1,25 @@
|
|
|
<template>
|
|
|
<div class="container">
|
|
|
- <div class="graph-box">
|
|
|
- <template v-for="(item, index) in nodeData" :key="index">
|
|
|
- <div class="graph-container">
|
|
|
- <div class="first-box">{{ item.id }}</div>
|
|
|
- <div class="second-container">
|
|
|
- <template
|
|
|
- v-for="(secondItem, index1) in item.children"
|
|
|
- :key="index1"
|
|
|
- >
|
|
|
- <div class="second-box">{{ secondItem.id }}</div>
|
|
|
- </template>
|
|
|
+ <el-scrollbar class="scrollbox">
|
|
|
+ <div class="graph-box">
|
|
|
+ <template v-for="(item, index) in nodeData" :key="index">
|
|
|
+ <div class="graph-container">
|
|
|
+ <div class="first-box">
|
|
|
+ <div class="content">{{ item.id }}</div>
|
|
|
+ <div class="status-box">进行中</div>
|
|
|
+ </div>
|
|
|
+ <DisposalChildBox :data="item" />
|
|
|
</div>
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- </div>
|
|
|
+ </template>
|
|
|
+ </div>
|
|
|
+ </el-scrollbar>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
import { ref, onMounted } from "vue";
|
|
|
import { Graph, treeToGraphData } from "@antv/g6";
|
|
|
-import { id } from "element-plus/es/locales.mjs";
|
|
|
+import DisposalChildBox from "./common/DisposalChildBox.vue";
|
|
|
|
|
|
const nodeData = [
|
|
|
{
|
|
@@ -104,6 +102,9 @@ onMounted(() => {});
|
|
|
.container {
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
+ .scrollbox {
|
|
|
+ height: calc(100% - 10px);
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
#graph_container {
|
|
@@ -112,28 +113,75 @@ onMounted(() => {});
|
|
|
}
|
|
|
|
|
|
.graph-container {
|
|
|
+ position: relative;
|
|
|
display: flex;
|
|
|
align-items: center;
|
|
|
- margin: 45px;
|
|
|
- .first-box {
|
|
|
- width: 100px;
|
|
|
- height: 50px;
|
|
|
- margin-right: 45px;
|
|
|
- background-color: rgba(0, 4, 255, 0.288);
|
|
|
+ margin: 30px 15px;
|
|
|
+ margin-right: 0;
|
|
|
+
|
|
|
+ &::before {
|
|
|
+ position: absolute;
|
|
|
+ content: "";
|
|
|
+ width: 1px;
|
|
|
+ top: -15px;
|
|
|
+ height: calc(50% - 18px);
|
|
|
+ left: 60px;
|
|
|
+ border-left: 2px dashed #3fa7b6;
|
|
|
+ z-index: 1;
|
|
|
+ }
|
|
|
+ &:first-child {
|
|
|
+ margin-top: 15px;
|
|
|
+ &::before {
|
|
|
+ display: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ &::after {
|
|
|
+ position: absolute;
|
|
|
+ content: "";
|
|
|
+ width: 1px;
|
|
|
+ height: calc(50% - 18px);
|
|
|
+ bottom: -15px;
|
|
|
+ left: 60px;
|
|
|
+ border-left: 2px dashed #3fa7b6;
|
|
|
+ z-index: 1;
|
|
|
}
|
|
|
- .second-container {
|
|
|
- .second-box {
|
|
|
- position: relative;
|
|
|
- width: 100px;
|
|
|
- height: 50px;
|
|
|
- background-color: rgba(0, 60, 255, 0.406);
|
|
|
- &::after {
|
|
|
- position: absolute;
|
|
|
- width: 30px;
|
|
|
- height: 1px;
|
|
|
- left: -30px;
|
|
|
- background-color: rgba(0, 60, 255, 0.406);
|
|
|
- }
|
|
|
+ &:last-child {
|
|
|
+ margin-top: 15px;
|
|
|
+ &::after {
|
|
|
+ display: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .first-box {
|
|
|
+ position: relative;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
+ width: 120px;
|
|
|
+ min-height: 73px;
|
|
|
+ padding: 5px 0;
|
|
|
+ flex-shrink: 0;
|
|
|
+ background: rgba(16, 252, 255, 0.25);
|
|
|
+ border-radius: 6px 6px 6px 6px;
|
|
|
+ border: 1px solid #10fcff;
|
|
|
+ z-index: 9;
|
|
|
+
|
|
|
+ .content {
|
|
|
+ width: 119px;
|
|
|
+ white-space: wrap;
|
|
|
+ font-family: Alibaba PuHuiTi;
|
|
|
+ font-weight: normal;
|
|
|
+ font-size: 18px;
|
|
|
+ line-height: 24px;
|
|
|
+ text-align: center;
|
|
|
+ font-style: normal;
|
|
|
+ text-transform: none;
|
|
|
+ background: linear-gradient(to bottom, #ffffff 0%, #88eaff 100%);
|
|
|
+ -webkit-background-clip: text;
|
|
|
+ -webkit-text-fill-color: transparent;
|
|
|
+ }
|
|
|
+ .status-box{
|
|
|
+ margin-top: 5px;
|
|
|
}
|
|
|
}
|
|
|
}
|