Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
Vue-WebDriver
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
高源
Vue-WebDriver
Commits
0ff2036c
Commit
0ff2036c
authored
Nov 16, 2023
by
郁子恒
Browse files
Options
Browse Files
Download
Plain Diff
合并分支
parents
f18d7b67
82f1e96e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
77 additions
and
1 deletion
+77
-1
App.vue
src/App.vue
+44
-1
collectionTable.vue
src/components/collectionTable.vue
+4
-0
elRightClick.vue
src/components/elRightClick.vue
+29
-0
No files found.
src/App.vue
View file @
0ff2036c
...
@@ -31,11 +31,12 @@
...
@@ -31,11 +31,12 @@
<div>
<div>
<div
style=
"height: 25px;display: flex;justify-content: flex-start;align-items: center;margin-left: 15px;"
>
<div
style=
"height: 25px;display: flex;justify-content: flex-start;align-items: center;margin-left: 15px;"
>
<span>
动作集合:
</span>
<span>
动作集合:
</span>
<span
style=
"margin-left: 10px;"
@
click=
"onBreadcrumb(item)"
v-for=
"item in actionAll"
:key=
"item.
k
vid"
>
<span
style=
"margin-left: 10px;"
@
click=
"onBreadcrumb(item)"
v-for=
"item in actionAll"
:key=
"item.
K
vid"
>
<span
id=
"Breadcrumb"
style=
"color: blue;"
>
{{
item
.
name
}}
</span>
>
<span
id=
"Breadcrumb"
style=
"color: blue;"
>
{{
item
.
name
}}
</span>
>
</span>
</span>
</div>
</div>
</div>
</div>
<<<<<<<
HEAD
<div
style=
"display: flex;align-items: flex-start;justify-content: space-between;"
>
<div
style=
"display: flex;align-items: flex-start;justify-content: space-between;"
>
<!-- 动作标签 -->
<!-- 动作标签 -->
<div
style=
"margin-bottom: 5px;margin-right: 1px;white-space: wrap;display: flex;width: 410px;"
>
<div
style=
"margin-bottom: 5px;margin-right: 1px;white-space: wrap;display: flex;width: 410px;"
>
...
@@ -71,6 +72,39 @@
...
@@ -71,6 +72,39 @@
<img
style=
"width: 20px;height: 20px;"
src=
"./assets/add.svg"
>
<img
style=
"width: 20px;height: 20px;"
src=
"./assets/add.svg"
>
</el-button>
</el-button>
</div>
</div>
=======
<!-- 动作标签 -->
<div
style=
"margin-bottom: 5px;margin-left: 15px;margin-right: 15px;width: 470px;overflow: auto;white-space: nowrap;display: flex;padding-top: 5px;"
>
<!--
<el-button
@
click=
"goback"
>
返回
</el-button>
-->
<draggable
v-model=
"treeNode"
chosenClass=
"chosen"
forceFallback=
"true"
group=
"people"
animation=
"1000"
@
start=
"onStart"
@
end=
"onEnd"
v-if=
"isChildrenTree == false"
>
<transition-group>
<!--
<div
class=
"item"
v-for=
"element in myArray"
:key=
"element.id"
>
{{
element
.
name
}}
</div>
-->
<el-tag
class=
"boxtags"
:key=
"tag.tagId"
v-for=
"tag in treeNode"
@
click=
"selectTag(tag)"
>
<div
style=
"display: flex;align-items: center;height: 30px;position: relative;"
>
<span
style=
"margin-left: 3px;min-width: 20px;"
>
{{
tag
.
actionName
}}
</span>
<img
id=
"closeimg"
@
click=
"handleClose(tag)"
style=
"width: 20px;position: absolute;top: -8px;right: -18px;"
src=
"./assets/close.png"
>
</div>
</el-tag>
</transition-group>
</draggable>
<draggable
v-model=
"childrenTreeNode"
chosenClass=
"chosen"
forceFallback=
"true"
group=
"people"
animation=
"1000"
@
start=
"onStart"
@
end=
"onEnd"
v-if=
"isChildrenTree == true"
>
<transition-group>
<el-tag
class=
"boxtags"
:key=
"item.tagId"
v-for=
"item in childrenTreeNode"
@
click=
"selectTag(item)"
>
<div
style=
"display: flex;align-items: center;height: 30px;position: relative;"
>
<span
style=
"margin-left: 3px;"
>
{{
item
.
actionName
}}
</span>
<img
id=
"closeimg"
@
click=
"handleClose(item)"
style=
"width: 20px;position: absolute;top: -8px;right: -18px;"
src=
"./assets/close.png"
>
</div>
</el-tag>
</transition-group>
</draggable>
>>>>>>> 82f1e96eec8aec19c0ac6a7117d713ee35e99001
</div>
</div>
<el-divider></el-divider>
<el-divider></el-divider>
<!-- 动作配置 -->
<!-- 动作配置 -->
...
@@ -115,6 +149,7 @@ export default {
...
@@ -115,6 +149,7 @@ export default {
actionName
:
''
,
actionName
:
''
,
actionType
:
''
,
actionType
:
''
,
dynamicTags
:
[],
dynamicTags
:
[],
winHeight
:
window
.
outerHeight
,
isShowAction
:
false
,
isShowAction
:
false
,
options
:
[{
options
:
[{
value
:
'elRightClick'
,
value
:
'elRightClick'
,
...
@@ -371,7 +406,12 @@ export default {
...
@@ -371,7 +406,12 @@ export default {
}
}
},
},
// 导航标签
// 导航标签
<<<<<<<
HEAD
onBreadcrumb
(
item
)
{
onBreadcrumb
(
item
)
{
=======
onBreadcrumb
(
item
)
{
this
.
isShowAction
=
false
>>>>>>>
82
f1e96eec8aec19c0ac6a7117d713ee35e99001
this
.
actionName
=
item
.
actionName
this
.
actionName
=
item
.
actionName
this
.
actionType
=
item
.
actionType
this
.
actionType
=
item
.
actionType
this
.
deleteObjectsAfterKvid
(
this
.
actionAll
,
item
.
Kvid
)
this
.
deleteObjectsAfterKvid
(
this
.
actionAll
,
item
.
Kvid
)
...
@@ -631,6 +671,9 @@ export default {
...
@@ -631,6 +671,9 @@ export default {
// 拖拽完最终结果
// 拖拽完最终结果
console
.
log
(
this
.
treeNode
)
console
.
log
(
this
.
treeNode
)
},
},
onResize
()
{
this
.
winHeight
=
window
.
outerHeight
},
},
},
}
}
</
script
>
</
script
>
...
...
src/components/collectionTable.vue
View file @
0ff2036c
...
@@ -154,7 +154,11 @@ export default {
...
@@ -154,7 +154,11 @@ export default {
//表格展示配置
//表格展示配置
let
objs
=
{}
let
objs
=
{}
objs
.
field
=
(
'content'
+
_this
.
index
++
)
+
'.content'
objs
.
field
=
(
'content'
+
_this
.
index
++
)
+
'.content'
<<<<<<<
HEAD
objs
.
title
=
'1'
objs
.
title
=
'1'
=======
objs
.
title
=
'请填写标题'
>>>>>>>
82
f1e96eec8aec19c0ac6a7117d713ee35e99001
objs
.
width
=
145
objs
.
width
=
145
_this
.
tableColumn
.
push
(
objs
)
_this
.
tableColumn
.
push
(
objs
)
let
element
=
event
.
target
;
let
element
=
event
.
target
;
...
...
src/components/elRightClick.vue
View file @
0ff2036c
...
@@ -91,6 +91,35 @@ export default {
...
@@ -91,6 +91,35 @@ export default {
this
.
actionConfig
.
Name
=
this
.
actionName
this
.
actionConfig
.
Name
=
this
.
actionName
this
.
actionConfig
.
Alias
=
this
.
actionType
this
.
actionConfig
.
Alias
=
this
.
actionType
this
.
$emit
(
'dataChanged'
,
this
.
actionConfig
);
this
.
$emit
(
'dataChanged'
,
this
.
actionConfig
);
<<<<<<<
HEAD
:
src
/
components
/
elRightClick
.
vue
=======
},
// 获取页面元素
selectElement
()
{
let
_this
=
this
// 定义事件处理函数
function
contextMenuHandler
(
event
)
{
event
.
preventDefault
();
// 阻止默认的右击菜单
let
element
=
event
.
target
;
let
elementInfo
=
{
Id
:
element
.
id
||
'无'
,
Xpath
:
_this
.
getElementXPath
(
element
),
Link
:
element
.
href
||
'无'
,
Name
:
element
.
name
||
'无'
,
Class
:
element
.
className
||
'无'
,
PartialLink
:
element
.
textContent
.
trim
()
||
'无'
,
Tag
:
element
.
tagName
.
toLowerCase
(),
Css
:
_this
.
getElementCssSelector
(
element
)
};
_this
.
elementInfo
=
elementInfo
_this
.
selectDisabled
=
false
// 移除事件监听器
document
.
removeEventListener
(
'contextmenu'
,
contextMenuHandler
);
}
// 添加事件监听器
document
.
addEventListener
(
'contextmenu'
,
contextMenuHandler
,
false
);
>>>>>>>
82
f1e96eec8aec19c0ac6a7117d713ee35e99001
:
src
/
components
/
elClick
.
vue
},
},
// 获取页面元素方法
// 获取页面元素方法
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment