Compare commits

...

2 Commits

  1. 2
      src/Layout/index.vue
  2. 4
      src/styles/index.scss
  3. 28
      src/views/roadbedRecommendation/components/mountNode.vue

@ -79,7 +79,7 @@ onMounted(() => {
// console.log(high,totop.value.offsetTop) // console.log(high,totop.value.offsetTop)
if (flog.value) { if (flog.value) {
num = num - 20 num = num - 40
totop.value.style.top = num + 'px' totop.value.style.top = num + 'px'
return return
} }

@ -7,7 +7,9 @@
// background: url('../assets/images/banner4.jpg') no-repeat; // background: url('../assets/images/banner4.jpg') no-repeat;
// background-size: cover // background-size: cover
position: relative; position: relative;
img{
width: 100%;
}
.source-box { .source-box {
position: absolute; position: absolute;
top: 50%; top: 50%;

@ -55,6 +55,14 @@ onMounted(() => {
id: '9', id: '9',
label: 'HTML&CSS&Javascript', label: 'HTML&CSS&Javascript',
}, },
{
id: '10',
label: 'test',
},
{
id: '11',
label: 'text2',
},
], ],
edges: [ edges: [
{ {
@ -129,6 +137,24 @@ onMounted(() => {
date: '学习基础知识', date: '学习基础知识',
}, },
}, },
{
source: '6',
target: '10',
data: {
type: '第一阶段',
amount: '10学时',
date: '学习基础知识',
},
},
{
source: '6',
target: '11',
data: {
type: '第一阶段',
amount: '10学时',
date: '学习基础知识',
},
},
], ],
} }
@ -336,7 +362,7 @@ onMounted(() => {
graph.render() graph.render()
var edges = graph.getEdges() var edges = graph.getEdges()
edges.forEach(function (edge:any) { edges.forEach(function (edge: any) {
var line = edge.getKeyShape() var line = edge.getKeyShape()
var stroke = line.attr('stroke') var stroke = line.attr('stroke')
var targetNode = edge.getTarget() var targetNode = edge.getTarget()

Loading…
Cancel
Save