1
This commit is contained in:
@@ -407,8 +407,8 @@
|
||||
uploadHeader() { //附件上传header
|
||||
let config = {};
|
||||
if (localStorage.getItem("currentRole")) {
|
||||
let currentRole = localStorage.getItem("currentRole");
|
||||
config["currentRole"] = currentRole;
|
||||
let currentRole = localStorage.getItem("currentRole");
|
||||
config["currentRole"] = currentRole;
|
||||
}
|
||||
return config;
|
||||
},
|
||||
|
||||
@@ -173,25 +173,25 @@
|
||||
<!-- 弹窗4:学号导入 -->
|
||||
<Modal v-model="stuIdImportModalVisible" title="学生学号导入" width="520">
|
||||
<div class="main-contents">
|
||||
<Form ref="UpParmas2.datapre" :model="UpParmas2.datapre" :label-width="100" inline>
|
||||
<FormItem label="Excel上传:" style="margin-bottom:10px;width:100%;">
|
||||
<i-input type="text" style="width:90%;" v-model="UpParmas2.fileName" class="import-input" placeholder="未选中任何文件.." readonly></i-input>
|
||||
<Upload class="fr btn"
|
||||
:action="UpParmas2.actionUrl"
|
||||
:data="UpParmas2.datapre"
|
||||
:show-upload-list="false"
|
||||
:headers="uploadHeader"
|
||||
accept=".xls,.xlsx"
|
||||
:before-upload="handleUpload2"
|
||||
:on-success="importFile2"
|
||||
>
|
||||
<i-button icon="md-add"></i-button>
|
||||
</Upload>
|
||||
</FormItem>
|
||||
<FormItem v-if="UpParmas2.fileName" style="margin-bottom:10px">
|
||||
<div v-if="UpParmas2.listData.code!=0" style="color:red">导入失败,请修改Excel文件中相关数据后再重新上传!</div>
|
||||
<div v-if="UpParmas2.listData.code==0" style="color:green">导入成功!</div>
|
||||
</FormItem>
|
||||
<Form ref="UpParmas2.datapre" :model="UpParmas2.datapre" :label-width="100" inline>
|
||||
<FormItem label="Excel上传:" style="margin-bottom:10px;width:100%;">
|
||||
<i-input type="text" style="width:90%;" v-model="UpParmas2.fileName" class="import-input" placeholder="未选中任何文件.." readonly></i-input>
|
||||
<Upload class="fr btn"
|
||||
:action="UpParmas2.actionUrl"
|
||||
:data="UpParmas2.datapre"
|
||||
:show-upload-list="false"
|
||||
:headers="uploadHeader"
|
||||
accept=".xls,.xlsx"
|
||||
:before-upload="handleUpload2"
|
||||
:on-success="importFile2"
|
||||
>
|
||||
<i-button icon="md-add"></i-button>
|
||||
</Upload>
|
||||
</FormItem>
|
||||
<FormItem v-if="UpParmas2.fileName" style="margin-bottom:10px">
|
||||
<div v-if="UpParmas2.listData.code!=0" style="color:red">导入失败,请修改Excel文件中相关数据后再重新上传!</div>
|
||||
<div v-if="UpParmas2.listData.code==0" style="color:green">导入成功!</div>
|
||||
</FormItem>
|
||||
</Form>
|
||||
|
||||
<Alert show-icon>
|
||||
@@ -338,22 +338,22 @@ export default {
|
||||
datapre:{},
|
||||
actionUrl:APIConfig.BschClassSystem.importStudentClassNo,
|
||||
columns:[
|
||||
{
|
||||
title: '行号',
|
||||
key: 'rows',
|
||||
align: 'center',
|
||||
width:'80'
|
||||
},
|
||||
{
|
||||
title: '内容',
|
||||
key: 'columnValue',
|
||||
align: 'center',
|
||||
},
|
||||
{
|
||||
title: '错误详情',
|
||||
key: 'errorMsg',
|
||||
align: 'center',
|
||||
}
|
||||
{
|
||||
title: '行号',
|
||||
key: 'rows',
|
||||
align: 'center',
|
||||
width:'80'
|
||||
},
|
||||
{
|
||||
title: '内容',
|
||||
key: 'columnValue',
|
||||
align: 'center',
|
||||
},
|
||||
{
|
||||
title: '错误详情',
|
||||
key: 'errorMsg',
|
||||
align: 'center',
|
||||
}
|
||||
],
|
||||
},
|
||||
|
||||
@@ -392,8 +392,8 @@ export default {
|
||||
uploadHeader() { //附件上传header
|
||||
let config = {};
|
||||
if (localStorage.getItem("currentRole")) {
|
||||
let currentRole = localStorage.getItem("currentRole");
|
||||
config["currentRole"] = currentRole;
|
||||
let currentRole = localStorage.getItem("currentRole");
|
||||
config["currentRole"] = currentRole;
|
||||
}
|
||||
return config;
|
||||
},
|
||||
@@ -401,7 +401,7 @@ export default {
|
||||
created() {
|
||||
this.getgradeselect();
|
||||
this.getClassTree();
|
||||
this.initTableColumn()
|
||||
this.initTableColumn();
|
||||
},
|
||||
methods: {
|
||||
//获取年级下拉
|
||||
@@ -409,10 +409,10 @@ export default {
|
||||
const _this = this;
|
||||
var item={};
|
||||
_this.$api.get(APIConfig.BschClassSystem.getgradeselect, item, resp => {
|
||||
if(resp.code==0)
|
||||
{
|
||||
this.gradeselectlist=resp.data;
|
||||
}
|
||||
if(resp.code==0)
|
||||
{
|
||||
this.gradeselectlist=resp.data;
|
||||
}
|
||||
});
|
||||
},
|
||||
//获取班级下拉
|
||||
@@ -422,10 +422,10 @@ export default {
|
||||
gradeId:_this.enrollYear
|
||||
};
|
||||
_this.$api.get(APIConfig.BschClassSystem.getschclassselect, item, resp => {
|
||||
if(resp.code==0)
|
||||
{
|
||||
this.schclassselectlist=resp.data;
|
||||
}
|
||||
if(resp.code==0)
|
||||
{
|
||||
this.schclassselectlist=resp.data;
|
||||
}
|
||||
});
|
||||
},
|
||||
//获取学生状态列表
|
||||
@@ -513,12 +513,12 @@ export default {
|
||||
this.enrollYear=treeNode.enrollYear?treeNode.enrollYear+'':'';
|
||||
this.classId=treeNode.classId?treeNode.classId+'':'';
|
||||
this.selectnodeid=treeNode.id;
|
||||
this.pageNum = 1
|
||||
this.loadData()
|
||||
this.pageNum = 1;
|
||||
this.loadData();
|
||||
},
|
||||
// 多选行回调
|
||||
selectionChange(rows) {
|
||||
this.selectedRows = rows
|
||||
this.selectedRows = rows;
|
||||
},
|
||||
|
||||
// 加载列表数据
|
||||
@@ -623,7 +623,7 @@ export default {
|
||||
this.$api.post(url, JSON.stringify(newItem), resp => {
|
||||
if (resp.code == 0) {
|
||||
this.$Message.success("编辑保存成功!");
|
||||
this.editModalVisible = false
|
||||
this.editModalVisible = false;
|
||||
this.loadData();
|
||||
} else if (resp.code == 4) {
|
||||
this.$Message.info(resp.msg);
|
||||
@@ -635,7 +635,7 @@ export default {
|
||||
// 批量删除
|
||||
batchDelete() {
|
||||
if (!this.selectedRows.length) {
|
||||
return this.$Message.warning('请先勾选学生')
|
||||
return this.$Message.warning('请先勾选学生');
|
||||
}
|
||||
this.$Modal.confirm({
|
||||
title: '提示',
|
||||
@@ -646,8 +646,8 @@ export default {
|
||||
this.$api.post(url,{}, resp => {
|
||||
if (resp.code == 0) {
|
||||
this.$Message.success("删除成功!");
|
||||
this.selectedRows = []
|
||||
this.loadData()
|
||||
this.selectedRows = [];
|
||||
this.loadData();
|
||||
} else if (resp.code == 4) {
|
||||
this.$Message.info(resp.msg);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user