This commit is contained in:
徐哼唧L
2022-12-09 16:18:12 +08:00
parent dc4d87a990
commit 5ed3073b6e
130 changed files with 41608 additions and 2013 deletions

View File

@@ -12,18 +12,37 @@
<el-button type="primary" icon="el-icon-circle-plus-outline" @click="addEditor">add</el-button>
</div> -->
<div class="handle-box" :rules="rules">
<el-select v-model="query.journal_id" placeholder="请选择期刊" @change="chan_id">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id" :value="item.journal_id"></el-option>
<el-select v-model="query.journal_id" placeholder="Please select a journal" @change="chan_id">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id"
:value="item.journal_id"></el-option>
</el-select>
</div>
<el-table :data="tableData" border stripe class="table" ref="multipleTable" header-cell-class-name="table-header">
<el-table :data="tableData" border stripe class="table" ref="multipleTable"
header-cell-class-name="table-header" empty-text="New messages (0)">
<el-table-column prop="account" label="username" align="center"></el-table-column>
<el-table-column prop="realname" label="realname" align="center"></el-table-column>
<el-table-column prop="phone" label="phone" align="center"></el-table-column>
<el-table-column prop="email" label="email" align="center"></el-table-column>
<el-table-column prop="" label="WOS H index" width="120px" align="center">
<template slot-scope="scope">
<p v-if="scope.row.indexs_show!=0" style="display: inline-block;width: 90px;">
<b :style="{color:scope.row.indexs_color}">{{scope.row.indexs[0].h_index}}</b>
({{now_year}})
<i class="el-icon-edit" @click="HIndexEdit(scope.row)"
style="margin-left: 10px;color: #006699;cursor: pointer;"></i>
</p>
<p v-if="scope.row.indexs_show==0" style="color: #aaa;display: inline-block;width: 90px;">
Null
<i class="el-icon-edit" @click="HIndexEdit(scope.row)"
style="margin-left: 10px;color: #006699;cursor: pointer;"></i>
</p>
<!-- <el-button size="mini" type="text" @click="HIndexList(scope.row)">More ></el-button> -->
</template>
</el-table-column>
<el-table-column label="" width="110" align="center">
<template slot-scope="scope">
<el-button size="mini" type="danger" plain icon="el-icon-delete" @click="handleDelete(scope.$index, scope.row)">Delete</el-button>
<el-button size="mini" type="danger" plain icon="el-icon-delete"
@click="handleDelete(scope.$index, scope.row)">Delete</el-button>
</template>
</el-table-column>
</el-table>
@@ -39,9 +58,10 @@
<el-input v-model="addForm.email" @blur='saerEm_U()'></el-input>
</el-form-item>
<el-form-item label="journal" prop="journal_id">
<el-select v-model="addForm.journal_id" filterable placeholder="Please select a responsible Journal" value-key="groupID"
style="width: 300px;">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id" :value="item.journal_id"></el-option>
<el-select v-model="addForm.journal_id" filterable placeholder="Please select a responsible Journal"
value-key="groupID" style="width: 300px;">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id"
:value="item.journal_id"></el-option>
</el-select>
</el-form-item>
<el-form-item label="realname" prop="realname">
@@ -74,9 +94,10 @@
{{oldForm.email}}
</el-form-item>
<el-form-item label="journal" prop="journal_id">
<el-select v-model="oldForm.journal_id" filterable placeholder="Please select a responsible Journal" value-key="groupID"
style="width: 300px;">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id" :value="item.journal_id"></el-option>
<el-select v-model="oldForm.journal_id" filterable placeholder="Please select a responsible Journal"
value-key="groupID" style="width: 300px;">
<el-option v-for="item in df_jour" :label="item.title" :key="item.journal_id"
:value="item.journal_id"></el-option>
</el-select>
</el-form-item>
<el-form-item label="realname">
@@ -92,6 +113,38 @@
</span>
</el-dialog>
<!-- H指数列表弹出框 -->
<el-dialog title="Edit H Index" :visible.sync="HListVisible" width="400px">
<div style="margin: 0 0 20px 10px;font-weight: bold;">{{HIxForm.realname}}</div>
<div class="HIList HIListTit">
<p>Year</p>
<p>WOS H index</p>
</div>
<div v-for="item in HIxData" class="HIList">
<p>{{item.year}}</p>
<p>{{item.h_index}}</p>
</div>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="HListVisible=false">OK</el-button>
</span>
</el-dialog>
<!-- H指数修改弹出框 -->
<el-dialog title="Edit H Index" :visible.sync="HEditVisible" width="400px">
<div style="margin: 0 0 20px 10px;font-weight: bold;">{{HIxForm.realname}}</div>
<el-form ref="old_Form" :model="HIxForm" :rules="rules" label-width="150px">
<el-form-item>
<span slot="label">
WOS H index ({{this.now_year}})
</span>
<el-input v-model="HIxForm.index"></el-input>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="saveHIx(HIxForm)">OK</el-button>
</span>
</el-dialog>
</div>
</template>
@@ -100,12 +153,19 @@
data() {
return {
edit_id: localStorage.getItem('U_id'),
now_year: 0,
tableData: [],
df_jour: [],
addVisible: false,
oldVisible: false,
HListVisible: false,
HEditVisible: false,
addForm: {},
oldForm: {},
HIxForm: {
index: ''
},
HIxData: [],
aid: -1,
id: -1,
btn_alert: false,
@@ -161,6 +221,25 @@
.post('api/Chief/getJournalBoard', this.query)
.then(res => {
this.tableData = res.data.boards;
for (var i = 0; i < this.tableData.length; i++) {
if (this.tableData[i].indexs.length != 0) {
if (this.tableData[i].indexs[0].year == this.now_year) {
this.tableData[i].indexs_show = this.tableData[i].indexs[0].h_index
if (this.tableData[i].indexs_show < 10) {
this.tableData[i].indexs_color = "#cb160a"
} else if (this.tableData[i].indexs_show < 15) {
this.tableData[i].indexs_color = "#cbb504"
} else {
this.tableData[i].indexs_color = "#0cbc15"
}
} else {
this.tableData[i].indexs_show = 0
}
} else {
this.tableData[i].indexs_show = 0
}
}
})
.catch(err => {
this.$message.error(err);
@@ -168,6 +247,7 @@
},
getjour() {
this.now_year = new Date().getFullYear()
this.$api
.post('api/Chief/getJournalsByEditor', {
'user_id': this.edit_id
@@ -180,6 +260,24 @@
.post('api/Chief/getJournalBoard', this.query)
.then(res => {
this.tableData = res.data.boards;
for (var i = 0; i < this.tableData.length; i++) {
if (this.tableData[i].indexs.length != 0) {
if (this.tableData[i].indexs[0].year == this.now_year) {
this.tableData[i].indexs_show = this.tableData[i].indexs[0].h_index
if (this.tableData[i].indexs_show < 10) {
this.tableData[i].indexs_color = "#cb160a"
} else if (this.tableData[i].indexs_show < 15) {
this.tableData[i].indexs_color = "#cbb504"
} else {
this.tableData[i].indexs_color = "#0cbc15"
}
} else {
this.tableData[i].indexs_show = 0
}
} else {
this.tableData[i].indexs_show = 0
}
}
})
.catch(err => {
this.$message.error(err);
@@ -214,9 +312,11 @@
.then(res => {
if (res.code == 0) {
if (res.data.user_info != null) {
this.$confirm('this account already exists. Do you want to operate under this account', 'Tips', {
type: 'warning'
})
this.$confirm(
'this account already exists. Do you want to operate under this account',
'Tips', {
type: 'warning'
})
.then(() => {
this.addVisible = false;
this.$refs.add_Form.resetFields();
@@ -248,9 +348,11 @@
.then(res => {
if (res.code == 0) {
if (res.data.user_info != null) {
this.$confirm('this account already exists. Do you want to operate under this account', 'Tips', {
type: 'warning'
})
this.$confirm(
'this account already exists. Do you want to operate under this account',
'Tips', {
type: 'warning'
})
.then(() => {
this.addVisible = false;
this.$refs.add_Form.resetFields();
@@ -325,6 +427,41 @@
}
});
},
// H指数列表
HIndexList(row) {
this.HListVisible = true
this.HIxForm.realname = row.realname
this.HIxData = row.indexs
},
// H指数修改
HIndexEdit(row) {
this.HEditVisible = true
this.HIxForm.user_id = row.user_id
this.HIxForm.realname = row.realname
this.HIxForm.year = this.now_year
if (row.indexs_show != 0) {
this.HIxForm.index = row.indexs_show
} else {
this.HIxForm.index = ''
}
},
// 保存index
saveHIx() {
this.$api
.post('api/Board/editIndex', this.HIxForm)
.then(res => {
if (res.code == 0) {
this.$message.success('Edit H Index succeeded');
this.HEditVisible = false
this.getdate();
} else {
this.$message.error(res.msg);
}
})
.catch(err => {
this.$message.error(err);
});
},
// 删除操作
handleDelete(index, row) {
// 二次确认删除
@@ -365,4 +502,17 @@
.red {
color: #ff0000;
}
.HIList {
margin: 0 0 10px 10px;
}
.HIList>p {
display: inline-block;
width: 120px;
}
.HIListTit>p {
font-weight: bold;
}
</style>