文档服务地址:http://47.92.0.57:3000/ 周报索引地址:http://47.92.0.57:3000/s/NruNXRYmV

Commit 5d023df7 by 李景熙

Merge branch 'develop' of https://gitlab.redhtc.com/Berlincen/DA-Platform into develop

parents 10a81a0a daa99187
var baseURL = 'http://localhost:9100/api' var baseURL = 'http://47.92.1.107/api'
export { export {
baseURL baseURL
......
...@@ -1227,12 +1227,26 @@ export default { ...@@ -1227,12 +1227,26 @@ export default {
// alert("请打分和填写准确率"); // alert("请打分和填写准确率");
// return; // return;
// } // }
// 2=>标注者标对的,1=>审查者后加的,0=>标错的
var yesAll = 0
var yesTmp = 0
this.canvasAllCheck.forEach(e =>{
if(e === 2) {
yesAll++;
yesTmp++;
}
else if(e === 1 || e === 0) {
yesAll++;
}
})
this.axios({ this.axios({
method: "get", method: "get",
params: { params: {
userId: this.$route.params.executor.id, userId: this.$route.params.executor.id,
fileId: this.$route.params.file.id, fileId: this.$route.params.file.id,
score: this.computeScore score: this.computeScore,
num: yesAll,
correctnum: yesTmp
}, },
url: "task/gradePieces" url: "task/gradePieces"
}).then(res => { }).then(res => {
......
...@@ -1000,12 +1000,37 @@ export default { ...@@ -1000,12 +1000,37 @@ export default {
// alert("请打分和填写准确率"); // alert("请打分和填写准确率");
// return; // return;
// } // }
// 2=>标注者标对的,1=>审查者后加的,0=>标错的
var yesAll = 0
var yesTmp = 0
// console.log(this.checkLayer)
// console.log(this.checkLand)
this.checkLayer.forEach(e =>{
if(e == 2) {
yesAll++;
yesTmp++;
}
else if(e == 1 || e === 0) {
yesAll++;
}
})
this.checkLand.forEach(e =>{
if(e == 2) {
yesAll++;
yesTmp++;
}
else if(e == 1 || e === 0) {
yesAll++;
}
})
this.axios({ this.axios({
method: "get", method: "get",
params: { params: {
userId: this.$route.params.executor.id, userId: this.$route.params.executor.id,
fileId: this.$route.params.file.id, fileId: this.$route.params.file.id,
score: this.computeScore score: this.computeScore,
num: yesAll,
correctnum: yesTmp
}, },
url: "task/gradePieces" url: "task/gradePieces"
}).then(res => { }).then(res => {
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<!-- 实体列表 --> <!-- 实体列表 -->
<div class="sidebar-box3"> <div class="sidebar-box3">
<div> <div>
<div class="img-list-title3">实体/属性模板</div> <div class="img-list-title3">标注:{{this.token.word}}</div>
<div class="img-title-list-box4"> <div class="img-title-list-box4">
<div> <div>
<div style="overflow: auto;height: calc(100vh - 61px - 100px - 180px - 50px);"> <div style="overflow: auto;height: calc(100vh - 61px - 100px - 180px - 50px);">
...@@ -63,7 +63,6 @@ ...@@ -63,7 +63,6 @@
<div class="content2" @mouseup="select2()"> <div class="content2" @mouseup="select2()">
<el-table <el-table
:data="nowContent.tableData" :data="nowContent.tableData"
:cell-style="cellStyle"
border border
style="width: 100%,height:200px" style="width: 100%,height:200px"
@cell-click="select" @cell-click="select"
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<!-- 实体列表 --> <!-- 实体列表 -->
<div class="sidebar-box3"> <div class="sidebar-box3">
<div> <div>
<div class="img-list-title3">实体/属性模板</div> <div class="img-list-title3">标注:{{this.token.word}}</div>
<div class="img-title-list-box4"> <div class="img-title-list-box4">
<div> <div>
<div style="overflow: auto;height: calc(100vh - 61px - 100px - 180px - 50px);"> <div style="overflow: auto;height: calc(100vh - 61px - 100px - 180px - 50px);">
...@@ -40,23 +40,29 @@ ...@@ -40,23 +40,29 @@
<el-button <el-button
type="primary" type="primary"
style="margin-top: 9px;margin-right: 20px;float:right" style="margin-top: 9px;margin-right: 20px;float:right"
@click="save"
size="small"
plain
>提交</el-button>
<el-button
type="primary"
style="margin-top: 9px;margin-right: 20px;float:right"
@click="uploadToken" @click="uploadToken"
size="small" size="small"
plain plain
>确定</el-button> >修改</el-button>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</el-aside> </el-aside>
<!-- 文件界面 --> <!-- 文件界面 -->
<el-main class="filter-container2" style="background-color: #FFFFFF"> <el-main class="filter-container3" style="background-color: #FFFFFF">
<div style="overflow-y:auto;height:100%;"> <div style="overflow-y:auto;height:100%;">
<!-- 表格界面 --> <!-- 表格界面 -->
<div class="content2"> <div class="content3">
<el-table <el-table
:data="nowContent.tableData" :data="nowContent.tableData"
:cell-style="cellStyle"
border border
style="width: 100%,height:200px" style="width: 100%,height:200px"
@cell-click="select" @cell-click="select"
...@@ -70,51 +76,35 @@ ...@@ -70,51 +76,35 @@
></el-table-column> ></el-table-column>
</el-table> </el-table>
</div> </div>
<!-- 表格界面 --> <div class="content_left1">
<!-- 打分 -->
<!--div v-if="this.$route.query.isCheck == '1'"-->
<el-row>
<el-col :span="21">
<div class="content_left">
<div <div
class="tokenList3" class="tokenList1"
v-for="it in tokenList" v-for="it in tokenList"
:key="it" :key="it"
style="user-select:none; float: left;" style="user-select:none; float: left;"
>
<el-tag
size="small"
@click="changeToken(it)" @click="changeToken(it)"
closable
:disable-transitions="false" :disable-transitions="false"
@close="deleteToken(it)"
> >
<a class="token3" v-html="it.word"></a> <el-checkbox>
</el-tag> <a style="font-size: 18px;" v-html="it.word"></a>
<a style="font-size: 14px;">: 实体</a>
<a style="font-size: 14px;" v-html="it.entityId"></a>
<a style="font-size: 14px;">属性</a>
<a style="font-size: 14px;" v-html="it.attribute"></a>
<!--el-button
style="margin-left: auto;font-size: 12px"
@click="countScore()"
size="mini"
type="text"
>O</el-button-->
</el-checkbox>
</div> </div>
</div> </div>
</el-col> <div style="overflow:auto;font-size: 15px;float: right;">
<el-col :span="3"> 计算得分 =
<div class="content_right"> <b style="font-size: 20px">{{this.computeScore}}</b>
<div class="button1">
<el-button type="primary" @click="commentScore = true">打分</el-button>
<!-- <el-button type="primary" @click="submit()">提交</el-button>-->
<el-dialog title="请打分" :visible.sync="commentScore" width="400px">
<el-form :model="scoreForm">
<el-form-item label="标注准确率" :label-width="formLabelWidth">
<el-input v-model="scoreForm.accuracy" autocomplete="off" clearable></el-input>
</el-form-item>
<el-form-item label="标注得分" :label-width="formLabelWidth">
<el-input v-model="scoreForm.score" autocomplete="off" clearable></el-input>
</el-form-item>
<el-button class="button1" type="primary" @click="addScore()">确认</el-button>
</el-form>
</el-dialog>
</div> </div>
</div> </div>
</el-col>
</el-row>
</div>
</el-main> </el-main>
</el-container> </el-container>
</div> </div>
...@@ -125,6 +115,8 @@ import FileSaver from "file-saver"; ...@@ -125,6 +115,8 @@ import FileSaver from "file-saver";
export default { export default {
data() { data() {
return { return {
computeScore: 0,
documentId: "", documentId: "",
// 文章 // 文章
file: null, file: null,
...@@ -182,7 +174,7 @@ export default { ...@@ -182,7 +174,7 @@ export default {
}, },
formLabelWidth: "120px", formLabelWidth: "120px",
executors: [], executors: [],
treeToArray: [] treeToArray: [],
}; };
}, },
beforeMount() { beforeMount() {
...@@ -534,27 +526,37 @@ export default { ...@@ -534,27 +526,37 @@ export default {
// this.$message("打分成功"); // this.$message("打分成功");
} }
}, },
// submit() { save() {
// // alert("打分成功"); this.submit();
// // this.$router.push({path: '/taskhall'}); this.$router.push({ path: "/check" });
// // // alert("inin"); },
// // this.axios({ submit() {
// // method: "get", // alert("打分成功");
// // params: { // console.log("route:")
// // userId: this.$route.params.executor.id, // console.log(this.$route.params.executor.id)
// // fileId: this.file.id, // if(this.scoreForm.score == '' || this.scoreForm.accuracy == ''){
// // scoreForm: this.scoreForm, // alert("请打分和填写准确率");
// // }, // return;
// // url: "task/gradePieces", // }
// // }).then((res) => { this.axios({
// // if (res.code == 0) { method: "get",
// // alert("分数提交失败!"); params: {
// // } else if (res.code == 1) { userId: this.$route.params.executor.id,
// // alert("打分成功"); fileId: this.$route.params.file.id,
// // this.$router.push({ path: "/taskhall" }); score: this.computeScore,
// // } },
// // }); url: "task/gradePieces",
// }, }).then((res) => {
// console.log(res);
// console.log("dafennjg");
if (res.code == 0) {
alert("分数提交失败!");
} else if (res.code == 1) {
// alert("打分成功");
// this.$router.push({ path: "/taskhall" });
}
});
},
}, },
mounted: function () { mounted: function () {
this.insertDocument(); this.insertDocument();
...@@ -613,4 +615,35 @@ export default { ...@@ -613,4 +615,35 @@ export default {
.token { .token {
font-size: 18px; font-size: 18px;
} }
.filter-container3 {
margin-right: 40px;
margin-left: 20px;
margin-top: 40px;
height: calc(100vh - 61px - 100px);
//float: center;
width: 100%;
@include whiteBoard;
.content3 {
overflow: auto;
height: calc(100vh - 61px - 100px - 170px);
text-align: left;
font-size: 20px;
line-height: 30px;
}
.content_left1 {
width: 100%;
overflow: auto;
height: 100px;
margin-top: 1px;
.tokenList1 {
margin: 3px;
}
}
.button1 {
overflow: auto;
float: right;
margin-right: 10px;
margin-top: 10px;
}
}
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment