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
a3a2a862
Commit
a3a2a862
authored
Jul 17, 2020
by
李严凡
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
模板删除
parent
cd771858
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
98 additions
and
50 deletions
+98
-50
ReleaseTask.vue
DAPlatform-front/src/components/ReleaseTask.vue
+91
-47
SelectedText.vue
...form-front/src/components/textAnnotation/SelectedText.vue
+7
-3
通用功能组_接口文档.docx
文档/通用功能组_接口文档.docx
+0
-0
No files found.
DAPlatform-front/src/components/ReleaseTask.vue
View file @
a3a2a862
...
...
@@ -271,15 +271,15 @@
<!--
<div
class=
"block"
v-for=
"(entity,index) in this.templateList"
>
-->
<el-select
v-model=
"templateChoose"
placeholder=
"模板选择"
>
<el-option
v-for=
"
i
in pOptions"
:key=
"i.templateId"
:label=
"i.templateName"
:value=
"i
.templateId
"
>
v-for=
"
(item,index)
in pOptions"
:key=
"i
tem
.templateId"
:label=
"i
tem
.templateName"
:value=
"i
ndex
"
>
</el-option>
<!--
<el-button
@
click=
"createModle"
>
查看
</el-button>
--
>
<el-button
@
click=
"createModle"
>
查看
</el-button
>
</el-select>
<el-tree
:data=
"this.pOptions[templateChoose
-1
].entityList"
:data=
"this.pOptions[templateChoose].entityList"
node-key=
"id"
default-expand-all
:expand-on-click-node=
"false"
>
...
...
@@ -301,7 +301,7 @@
<!--
</span>
-->
</span>
</el-tree>
<!--
<el-button>
删除模板
</el-button>
--
>
<el-button
type=
"primary"
@
click=
"delTemplate(templateChoose)"
>
删除模板
</el-button
>
<!--
</div>
-->
</el-row>
<el-row
:gutter=
"20"
>
...
...
@@ -834,6 +834,7 @@
},
createModle
(){
console
.
log
(
this
.
templateChoose
);
console
.
log
(
this
.
pOptions
);
},
append
(
data
,
mm
)
{
//type = 0 ,最下面的子节点,对应描述value;type=1,根节点,对应子类children
...
...
@@ -855,51 +856,94 @@
children
.
splice
(
index
,
1
);
},
rePage
(
ins
){
console
.
log
(
this
.
entityList
);
//确定创建模板
// if(ins == 1){
// this.axios({
// method:'POST',
// url:'/textAnnotation/createTemplated',
// data:{
// templateId:this.pOptions.length+1,
// templateName:this.form.name,
// templateType:0,
// creatorId:this.userInfo.userId,
// entityList:this.entityList,
// },
// }).then(res=>{
// if(res.code == 1){
// this.pOptions = res.message;
// }
// else{
// alert("模板创建失败");
// }
// this.dialogFormVisible = false;
// })
// }
// console(this.pOptions);
// console.log(this.entityList);
// console.log("111");
// 确定创建模板
var
max
=
-
1
;
for
(
var
i
=
0
;
i
<
this
.
pOptions
.
length
;
i
++
){
if
(
this
.
pOptions
[
i
].
templateId
>
max
)
max
=
this
.
pOptions
[
i
].
templateId
;
};
if
(
ins
==
1
){
this
.
axios
({
method
:
'POST'
,
url
:
'/textAnnotation/createTemplated'
,
data
:{
templateId
:
max
+
1
,
templateName
:
this
.
form
.
name
,
templateType
:
0
,
creatorId
:
this
.
userInfo
.
userId
,
entityList
:
this
.
entityList
,
},
}).
then
(
res
=>
{
console
.
log
(
res
);
if
(
res
.
code
==
1
){
this
.
pOptions
=
res
.
message
;
}
else
{
alert
(
"模板创建失败"
);
}
this
.
dialogFormVisible
=
false
;
})
}
// console(this.pOptions);
// // alert("111");
//location.reload();
},
delTemplate
(
index
){
console
.
log
(
this
.
pOptions
);
//
this
.
$confirm
(
'此操作将永久删除改模板'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
this
.
axios
({
method
:
"POST"
,
data
:{
creatorId
:
this
.
userInfo
.
userId
,
templateId
:
this
.
pOptions
[
index
].
templateId
},
url
:
'textAnnotation/deleteTemplate'
,
}).
then
(
res
=>
{
console
.
log
(
res
.
return_code
);
if
(
res
.
return_code
==
200
){
this
.
$message
({
type
:
'success'
,
message
:
'删除成功!'
});
this
.
pOptions
.
splice
(
index
,
1
);
}
else
{
alert
(
"未知错误,删除失败"
);
}
});
}).
catch
(()
=>
{
this
.
$message
({
type
:
'info'
,
message
:
'已取消删除'
});
});
console
.
log
(
this
.
pOptions
);
},
checkTemplate
(){
this
.
templateVisible
=
true
;
this
.
axios
({
method
:
"POST"
,
data
:{
creatorId
:
this
.
userInfo
.
userId
,
},
url
:
"/textAnnotation/getTemplated"
}).
then
(
res
=>
{
console
.
log
(
"///"
);
console
.
log
(
res
);
if
(
res
.
code
==
0
){
alert
(
"模板获取失败"
);
}
else
{
this
.
templateDetailList
=
res
.
message
;
}
})
//
this.axios({
//
method:"POST",
//
data:{
//
creatorId:this.userInfo.userId,
//
},
//
url:"/textAnnotation/getTemplated"
//
}).then(res=>{
//
console.log("///");
//
console.log(res);
//
if(res.code == 0){
//
alert("模板获取失败");
//
}
//
else{
//
this.templateDetailList = res.message;
//
}
//
})
// this.templateDetailList = this.pOptions;
}
}
...
...
DAPlatform-front/src/components/textAnnotation/SelectedText.vue
View file @
a3a2a862
<
template
>
<div
class=
"select-container"
>
<el-container
style=
"margin-top: 40px"
>
<el-aside
class=
"sidebar"
...
...
@@ -130,7 +130,7 @@ export default {
// 从通用传来文本信息
// TODO quary instead of params to fix the bug during refreshing 没办法统一改就task存字段,刷新后去库里找
this
.
file
=
JSON
.
parse
(
decodeURIComponent
(
this
.
$route
.
params
.
file
));
this
.
executor
=
JSON
.
parse
(
decodeURIComponent
(
this
.
$route
.
params
.
executor
));
this
.
executor
=
JSON
.
parse
(
decodeURIComponent
(
this
.
$route
.
params
.
executor
));
// this.task = JSON.parse(decodeURIComponent(this.$route.params.task));
},
methods
:
{
...
...
@@ -239,8 +239,12 @@ export default {
this
.
commentScore
=
false
;
this
.
$message
(
"打分成功"
);
}
}
},
submit
(){
alert
(
"inin"
);
},
},
mounted
:
function
()
{
this
.
insertDocument
();
}
...
...
文档/通用功能组_接口文档.docx
View file @
a3a2a862
No preview for this file type
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