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
dc4630e1
Commit
dc4630e1
authored
Nov 23, 2023
by
高源
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
表格添加types属性值
parent
6499c6e8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
collectionTable.vue
src/components/collectionTable.vue
+1
-1
sdk-table.js
src/sdk-table.js
+4
-4
No files found.
src/components/collectionTable.vue
View file @
dc4630e1
...
@@ -239,7 +239,7 @@ export default {
...
@@ -239,7 +239,7 @@ export default {
// 遍历 Xpaths
// 遍历 Xpaths
for
(
let
i
=
0
;
i
<
_this
.
Xpaths
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
_this
.
Xpaths
.
length
;
i
++
)
{
// _this.Xpaths[i].name = 'ID' + i
// _this.Xpaths[i].name = 'ID' + i
_this
.
table
.
newCell
(
_this
.
Xpaths
[
i
].
xpath
,
_this
.
Xpaths
[
i
].
name
,
_this
.
Xpaths
[
i
].
type
,
_this
.
Xpaths
[
i
].
title
)
_this
.
table
.
newCell
(
_this
.
Xpaths
[
i
].
xpath
,
_this
.
Xpaths
[
i
].
name
,
_this
.
Xpaths
[
i
].
type
,
_this
.
Xpaths
[
i
].
typeOptions
,
_this
.
Xpaths
[
i
].
title
)
}
}
_this
.
table
.
verify
()
_this
.
table
.
verify
()
_this
.
table
.
name
=
_this
.
tableName
_this
.
table
.
name
=
_this
.
tableName
...
...
src/sdk-table.js
View file @
dc4630e1
...
@@ -14,9 +14,9 @@ function table () {
...
@@ -14,9 +14,9 @@ function table () {
* 新生成一个单元格
* 新生成一个单元格
* @param {any} xpath
* @param {any} xpath
*/
*/
this
.
newCell
=
function
(
xpath
,
name
,
type
,
title
)
{
this
.
newCell
=
function
(
xpath
,
name
,
type
,
t
ypes
,
t
itle
)
{
_isVerified
=
false
;
//加入了
_isVerified
=
false
;
//加入了
let
newCell
=
new
cell
(
xpath
,
name
,
type
,
title
);
let
newCell
=
new
cell
(
xpath
,
name
,
type
,
types
,
title
);
this
.
cells
.
push
(
newCell
);
this
.
cells
.
push
(
newCell
);
}
}
/**
/**
...
@@ -102,7 +102,7 @@ function table () {
...
@@ -102,7 +102,7 @@ function table () {
* @param {string} type 元素取值类型,文本,链接,元素路径(点击动作用)
* @param {string} type 元素取值类型,文本,链接,元素路径(点击动作用)
* @param {string} title 标题信息
* @param {string} title 标题信息
*/
*/
function
cell
(
xpath
,
name
,
type
,
title
)
{
function
cell
(
xpath
,
name
,
type
,
types
,
title
)
{
/**当前单元格的绝对路径,存入Action时有用 */
/**当前单元格的绝对路径,存入Action时有用 */
this
.
xpath
=
xpath
;
this
.
xpath
=
xpath
;
/**当前单元格存储数据时的属性名 */
/**当前单元格存储数据时的属性名 */
...
@@ -110,7 +110,7 @@ function cell (xpath, name, type, title) {
...
@@ -110,7 +110,7 @@ function cell (xpath, name, type, title) {
/**单元格取值类型, 文本,链接,元素路径(点击动作用)*/
/**单元格取值类型, 文本,链接,元素路径(点击动作用)*/
this
.
type
=
type
;
this
.
type
=
type
;
/**当前单元格所具备的可以操作的类型集合 */
/**当前单元格所具备的可以操作的类型集合 */
this
.
types
=
[]
;
this
.
types
=
types
;
/** 单元格在表上的表头信息*/
/** 单元格在表上的表头信息*/
this
.
title
=
title
;
this
.
title
=
title
;
/**当表结构验证成功后,正确的表绝对路径,不包含下标 */
/**当表结构验证成功后,正确的表绝对路径,不包含下标 */
...
...
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