|
@@ -124,7 +124,32 @@
|
|
},
|
|
},
|
|
};
|
|
};
|
|
},
|
|
},
|
|
|
|
+ mounted() {
|
|
|
|
+ this.$nextTick(function () {
|
|
|
|
+ this.tableHeight =
|
|
|
|
+ window.innerHeight - this.$refs.table.$el.offsetTop - 200;
|
|
|
|
+ if (this.tableHeight <= 530) {
|
|
|
|
+ this.tableHeight = 530;
|
|
|
|
+ }
|
|
|
|
+ // 监听窗口大小变化
|
|
|
|
+ let self = this;
|
|
|
|
+ window.onresize = function () {
|
|
|
|
+ self.tableHeight =
|
|
|
|
+ window.innerHeight - self.$refs.table.$el.offsetTop - 200;
|
|
|
|
+ if (self.tableHeight <= 530) {
|
|
|
|
+ self.tableHeight = 530;
|
|
|
|
+ }
|
|
|
|
+ };
|
|
|
|
+ });
|
|
|
|
+ },
|
|
methods: {
|
|
methods: {
|
|
|
|
+ tableRowClassName({ row, rowIndex }) {
|
|
|
|
+ if ((rowIndex + 1) % 2 === 0) {
|
|
|
|
+ return "even_row";
|
|
|
|
+ } else {
|
|
|
|
+ return "";
|
|
|
|
+ }
|
|
|
|
+ },
|
|
getSchool() {
|
|
getSchool() {
|
|
this.isLoading = true;
|
|
this.isLoading = true;
|
|
let params = {
|
|
let params = {
|
|
@@ -147,10 +172,10 @@
|
|
{
|
|
{
|
|
uid: this.$store.state.userInfo.userid,
|
|
uid: this.$store.state.userInfo.userid,
|
|
sname: this.ruleForm.name,
|
|
sname: this.ruleForm.name,
|
|
- ph:this.ruleForm.phone,
|
|
|
|
|
|
+ ph: this.ruleForm.phone,
|
|
sex: this.ruleForm.sex == "男" ? "0" : "1",
|
|
sex: this.ruleForm.sex == "男" ? "0" : "1",
|
|
email: this.ruleForm.mail,
|
|
email: this.ruleForm.mail,
|
|
- oid:this.ruleForm.sBySchool,
|
|
|
|
|
|
+ oid: this.ruleForm.sBySchool,
|
|
js: this.ruleForm.desc,
|
|
js: this.ruleForm.desc,
|
|
},
|
|
},
|
|
];
|
|
];
|
|
@@ -161,7 +186,7 @@
|
|
message: "修改成功",
|
|
message: "修改成功",
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
- this.getDetail();
|
|
|
|
|
|
+ this.getDetail();
|
|
})
|
|
})
|
|
.catch((err) => {
|
|
.catch((err) => {
|
|
this.$message.error("修改失败");
|
|
this.$message.error("修改失败");
|