Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
DA-Platform
Overview
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
文档服务地址:
http://47.92.0.57:3000/
周报索引地址:
http://47.92.0.57:3000/s/NruNXRYmV
Open sidebar
Berlin
DA-Platform
Commits
c16f9aad
Commit
c16f9aad
authored
Aug 15, 2020
by
李严凡
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
创建任务页面布局以及模板创建英文替代
parent
70e0e201
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
94 additions
and
52 deletions
+94
-52
ReleaseTask.vue
DAPlatform-front/src/components/ReleaseTask.vue
+94
-52
No files found.
DAPlatform-front/src/components/ReleaseTask.vue
View file @
c16f9aad
...
...
@@ -17,7 +17,7 @@
<el-row
:gutter=
"20"
>
<el-form-item>
<!-- 采用手风琴实现折叠-->
<el-collapse
v-model=
"activeName
"
accordion
>
<el-collapse
v-model=
"activeName
F"
>
<el-form-item
v-for=
"(domain, index) in dynamicValidateForm.domains"
:key=
"domain.key"
:prop=
"'domains.' + index + '.value'"
>
...
...
@@ -25,8 +25,8 @@
:title=
"'文本任务分片'+(1+index)"
:name=
"index"
style=
"border-bottom: 1px solid;border-bottom-color:white;font-size: 14px"
>
<!-- 上传图片-->
<el-row
:gutter=
"
20
"
>
<el-col
span=
"8"
>
<el-row
:gutter=
"
4
"
>
<el-col
span=
"8"
>
<el-upload
class=
"upload-demo"
action=
"https://jsonplaceholder.typicode.com/posts/"
...
...
@@ -38,27 +38,33 @@
:data=
"'3:'+(index)"
:on-exceed=
"handleExceed"
:file-list=
"dynamicValidateForm.domains[index].fileList"
>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传
</el-button>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传文本文件
</el-button>
<div
slot=
"tip"
class=
"el-upload__tip"
>
上传要求:txt/xlsx/json格式文件
</div>
</el-upload>
</el-col>
<el-col
span=
"6"
>
<el-select
v-model=
"domain.templateId"
placeholder=
"模板选择"
>
<el-option
v-for=
"i in pOptions"
:key=
"i.templateId"
:label=
"i.templateName"
:value=
"i.templateId"
>
</el-option>
<el-option>
<el-button
type=
"text"
@
click=
"dialogFormVisible = true"
>
自定义模板
</el-button>
</el-option>
</el-select>
<el-col
offset=
"5"
span=
"8"
>
<el-row>
<el-col
offset=
"7"
span=
"9"
>
<el-button
style=
"width: 99%;"
type=
"primary"
icon=
"el-icon-delete"
plain
@
click
.
prevent=
"removeDomain(1,domain)"
>
删除分片
</el-button>
</el-col>
</el-row>
<el-row
style=
"margin-top: 5px"
>
<el-col
offset=
"7"
span=
"9"
>
<el-select
v-model=
"domain.templateId"
placeholder=
"模板选择"
>
<el-option
v-for=
"i in pOptions"
:key=
"i.templateId"
:label=
"i.templateName"
:value=
"i.templateId"
>
</el-option>
<el-option>
<el-button
type=
"text"
@
click=
"dialogFormVisible = true"
>
自定义模板
</el-button>
</el-option>
</el-select>
</el-col>
</el-row>
<!-- 创建文本模板-->
</el-col>
<el-col
span=
"2"
offset=
"2"
>
<el-button
type=
"primary"
plain
@
click
.
prevent=
"removeDomain(1,domain)"
>
删除分片
</el-button>
</el-col>
</el-row>
</el-collapse-item>
</el-form-item>
...
...
@@ -132,7 +138,7 @@
<el-row
:gutter=
"20"
>
<el-form-item>
<!-- 采用手风琴实现折叠-->
<el-collapse
v-model=
"activeName"
>
<el-collapse
v-model=
"activeName
P
"
>
<el-form-item
v-for=
"(domain, index) in dynamicValidateForm.pictureDomains"
:key=
"domain.key"
:prop=
"'pictureDomains.' + index + '.value'"
>
...
...
@@ -140,8 +146,8 @@
:title=
"'图片任务分片'+(1+index)"
:name=
"index"
style=
"border-bottom: 1px solid;border-bottom-color:white;font-size: 14px; "
>
<!-- 上传图片-->
<el-row
:gutter=
"
20
"
style=
"min-height: 75px"
>
<el-col
span=
"
6
"
>
<el-row
:gutter=
"
4
"
style=
"min-height: 75px"
>
<el-col
span=
"
8
"
>
<el-upload
class=
"upload-demo"
action=
"https://jsonplaceholder.typicode.com/posts/"
...
...
@@ -154,16 +160,23 @@
:limit=
"7"
:on-exceed=
"handleExceed"
:file-list=
"dynamicValidateForm.pictureDomains[index].fileList"
>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传
</el-button>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传图像文件
</el-button>
<div
slot=
"tip"
class=
"el-upload__tip"
>
上传要求:jpg/jpeg/png/gif格式文件
</div>
</el-upload>
</el-col>
<el-col
span=
"10"
>
<el-input
type=
"textarea"
:autosize=
"
{minRows: 2, maxRows: 4}" placeholder="请输入分片描述" @input="change($event)" v-model="domain.description" style="resize:none;overflow:hidden ;margin-bottom: 10px;min-height:65px" maxlength="150" show-word-limit="150">
</el-input>
</el-col>
<el-col
span=
"2"
offset=
"2"
>
<el-button
type=
"primary"
plain
@
click
.
prevent=
"removeDomain(2,domain)"
>
删除分片
</el-button>
<el-col
span=
"12"
offset=
"4"
>
<el-row>
<el-col
span=
"20"
>
<el-input
type=
"textarea"
:autosize=
"
{minRows: 2, maxRows: 4}" placeholder="请输入分片描述" @input="change($event)" v-model="domain.description" style="resize:none;overflow:hidden ;margin-bottom: 10px;min-height:65px" maxlength="150" show-word-limit="150">
</el-input>
</el-col>
</el-row>
<el-row>
<el-col
span=
"6"
offset=
"14"
>
<el-button
style=
"width: 99%"
type=
"primary"
icon=
"el-icon-delete"
plain
@
click
.
prevent=
"removeDomain(2,domain)"
>
删除分片
</el-button>
</el-col>
</el-row>
</el-col>
</el-row>
</el-collapse-item>
...
...
@@ -180,7 +193,7 @@
<el-row
:gutter=
"20"
>
<el-form-item>
<!-- 采用手风琴实现折叠-->
<el-collapse
v-model=
"activeName
"
accordion
>
<el-collapse
v-model=
"activeName
L"
>
<el-form-item
v-for=
"(domain, index) in dynamicValidateForm.layerDomains"
:key=
"domain.key"
:prop=
"'layerDomains.' + index + '.value'"
>
...
...
@@ -188,8 +201,8 @@
:title=
"'图层任务分片'+(1+index)"
:name=
"index"
style=
"border-bottom: 1px solid;border-bottom-color:white;font-size: 14px;"
>
<!-- 上传图片-->
<el-row
:gutter=
"
20"
>
<el-col
span=
"
6
"
>
<el-row
:gutter=
"
4"
style=
"min-height: 75px"
>
<el-col
span=
"
8
"
>
<!-- 上传文件传参3表示图层分片,index表示第几个分片,用“:”分割-->
<el-upload
class=
"upload-demo"
...
...
@@ -202,15 +215,22 @@
:limit=
"7"
:on-exceed=
"handleExceed"
:file-list=
"dynamicValidateForm.layerDomains[index].fileList"
>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传
</el-button>
<el-button
size=
"small"
type=
"primary"
@
click=
"setIndex(index)"
>
点击上传图层文件
</el-button>
<div
slot=
"tip"
class=
"el-upload__tip"
>
上传要求:kml格式文件
</div>
</el-upload>
</el-col>
<el-col
span=
"10"
>
<el-input
type=
"textarea"
:autosize=
"
{minRows: 2, maxRows: 4}" placeholder="请输入分片描述" @input="change($event)" v-model="domain.description" style="resize: none;overflow:hidden ;margin-bottom: 10px;min-height:65px" maxlength="150" show-word-limit="150">
</el-input>
</el-col>
<el-col
span=
"2"
offset=
"2"
>
<el-button
type=
"primary"
plain
@
click
.
prevent=
"removeDomain(3,domain)"
>
删除分片
</el-button>
<el-col
offset=
"4"
span=
"12"
>
<el-row>
<el-col
span=
"20"
>
<el-input
type=
"textarea"
:autosize=
"
{minRows: 2, maxRows: 4}" placeholder="请输入分片描述" @input="change($event)" v-model="domain.description" style="resize: none;overflow:hidden ;margin-bottom: 10px;min-height:65px" maxlength="150" show-word-limit="150">
</el-input>
</el-col>
</el-row>
<el-row>
<el-col
span=
"6"
offset=
"14"
>
<el-button
style=
"width: 99%"
type=
"primary"
icon=
"el-icon-delete"
plain
@
click
.
prevent=
"removeDomain(3,domain)"
>
删除分片
</el-button>
</el-col>
</el-row>
</el-col>
</el-row>
</el-collapse-item>
...
...
@@ -228,7 +248,7 @@
<el-row
:gutter=
"20"
>
<el-form-item>
<!-- 采用手风琴实现折叠-->
<el-collapse
v-model=
"activeName"
accordion
>
<el-collapse
v-model=
"activeName"
>
<div
v-if=
"dynamicValidateForm.dataFormList.length != 0"
>
<el-form-item
v-for=
"(domain, index) in dynamicValidateForm.dataFormList"
:key=
"domain.key"
...
...
@@ -265,10 +285,20 @@
<el-dialog
title=
"自定义模板"
:visible
.
sync=
"dialogFormVisible"
>
<el-form
:model=
"form"
>
<el-form-item
label=
"模板名称"
:label-width=
"formLabelWidth"
>
<el-input
v-model=
"form.name"
autocomplete=
"off"
></el-input>
</el-form-item>
<input
v-model=
"mm"
placeholder=
" 输入实体或属性名称"
>
<el-row
:gutter=
"2"
>
<el-col
span=
"11"
>
<el-form-item
label=
"模板名称"
:label-width=
"formLabelWidth"
>
<el-input
v-model=
"form.name"
autocomplete=
"off"
></el-input>
</el-form-item>
</el-col>
<el-col
offset=
""
span=
"11"
>
<el-form-item
label=
"实体/属性名称"
:label-width=
"formLabelWidth"
>
<el-input
v-model=
"form.mm"
autocomplete=
"off"
></el-input>
</el-form-item>
</el-col>
</el-row>
<!-- 树状结构-->
<div
class=
"block"
>
<el-tree
...
...
@@ -282,7 +312,7 @@
<el-button
type=
"text"
size=
"mini"
@
click=
"() => append(data,mm)"
>
@
click=
"() => append(data,
form.
mm)"
>
添加
</el-button>
<el-button
...
...
@@ -400,7 +430,7 @@
var
ins
;
var
entityList
=
[{
id
:
1
,
label
:
'
entityList
'
,
label
:
'
实体模板
'
,
children
:
[]
}];
return
{
...
...
@@ -423,7 +453,8 @@
delivery
:
false
,
type
:
[],
resource
:
''
,
desc
:
''
desc
:
''
,
mm
:
''
},
formLabelWidth
:
'120px'
,
pOptions
:
[{
...
...
@@ -470,11 +501,13 @@
// description:'',
// }
},
activeNameF
:[],
activeNameP
:[],
activeNameL
:[],
cardName
:
'first'
,
createModeValue
:
'-1'
,
createModeLable
:
'自定义模板'
,
entityList
:
JSON
.
parse
(
JSON
.
stringify
(
entityList
)),
entityList
:
JSON
.
parse
(
JSON
.
stringify
(
entityList
)),
fName
:
''
,
url
:
''
,
taskName
:
''
,
...
...
@@ -876,6 +909,7 @@
createMode
:
false
,
key
:
Date
.
now
()
});
this
.
activeNameF
.
push
(
this
.
dynamicValidateForm
.
domains
.
length
-
1
)
}
// //添加表格分片
// if(ptype == 2){
...
...
@@ -894,6 +928,7 @@
description
:
''
,
key
:
Date
.
now
()
});
this
.
activeNameP
.
push
(
this
.
dynamicValidateForm
.
pictureDomains
.
length
-
1
)
}
//添加图层分片
else
if
(
ptype
==
3
){
...
...
@@ -902,6 +937,7 @@
description
:
''
,
key
:
Date
.
now
()
});
this
.
activeNameL
.
push
(
this
.
dynamicValidateForm
.
layerDomains
.
length
-
1
)
}
},
change
(
e
){
...
...
@@ -923,7 +959,7 @@
append
(
data
,
mm
)
{
// console.log("MM")
// console.log(mm)
if
(
mm
==
undefined
){
if
(
mm
==
''
){
this
.
$message
({
type
:
'info'
,
message
:
'请输入模板名称或者实体名称'
...
...
@@ -950,8 +986,6 @@
children
.
splice
(
index
,
1
);
},
rePage
(
ins
){
// console.log(this.entityList);
// console.log("111");
// 确定创建模板
var
max
=
-
1
;
for
(
var
i
=
0
;
i
<
this
.
pOptions
.
length
;
i
++
){
...
...
@@ -968,6 +1002,14 @@
})
return
}
// if(this.entityList.children.length == 0){
// this.$message({
// type: 'info',
// message: '创建无效空模板'
// })
// return
// }
this
.
axios
({
method
:
'POST'
,
url
:
'/textAnnotation/createTemplated'
,
...
...
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