Commit 61ae9d3c authored by 杨梦雪's avatar 杨梦雪

11

parent b6573691
......@@ -29,7 +29,7 @@ export default {
return callback(new Error("身份证号不能为空"));
}
if (!/(^\d{15}$)|(^\d{17}(\d|X|x)$)/.test(value)) {
callback(new Error("你输入的身份证长度或格式错误"));
return callback(new Error("你输入的身份证长度或格式错误"));
}
//身份证城市
var aCity = {
......@@ -70,8 +70,9 @@ export default {
91: "国外"
};
if (!aCity[parseInt(value.substr(0, 2))]) {
callback(new Error("你的身份证地区非法"));
return callback(new Error("你的身份证地区非法"));
}
return callback();
},
// 数字验证
validateNumber: function (rule, value, callback) {
......
......@@ -65,7 +65,7 @@ export default {
},
];
let arr = [];
console.log(newArr, "newArr");
// console.log(newArr, "newArr");
for (let i = 0; i < newArr.length; i++) {
const item = newArr[i];
if (
......@@ -81,7 +81,7 @@ export default {
},
watch: {
statusNum(val) {
console.log(val, "statusNum");
// console.log(val, "statusNum");
this.status = val;
},
},
......
......@@ -34,6 +34,7 @@
</template>
<script>
/* eslint-disable */
export default {
name: "Footer",
};
......
......@@ -64,12 +64,12 @@ export default {
},
methods: {
async confirm() {
console.log(SERVER_WS_URL);
// console.log(SERVER_WS_URL);
let { data: res } = await getWxConfig({
// exam_uuid: this.examuuid,
pay_type: 1,
});
console.log(res);
// console.log(res);
if (res.code !== 200) {
if (res.code == 400801) {
return this.cancelBtn();
......@@ -103,7 +103,7 @@ export default {
if (this.$refs.qrCodeUrl) {
// 获取 父 标签下的所有子节点
let pObjs = this.$refs.qrCodeUrl.childNodes;
console.log(pObjs);
// console.log(pObjs);
for (var i = pObjs.length - 1; i >= 0; i--) {
// 一定要倒序,正序是删不干净的,可自行尝试
this.$refs.qrCodeUrl.removeChild(pObjs[i]);
......@@ -208,7 +208,7 @@ export default {
// 连接成功建立的回调方法
websocketOnopen() {
this.websocketSend();
console.log("连接成功建立的回调方法");
// console.log("连接成功建立的回调方法");
//开启心跳
this.start();
},
......@@ -223,10 +223,10 @@ export default {
},
// 接收到消息的回调方法
websocketOnmessage(event) {
console.log(event, "event");
// console.log(event, "event");
if (event.data !== "Opened") {
//const data = JSON.parse(event.data);
console.log("接收到消息的回调方法", event.data);
// console.log("接收到消息的回调方法", event.data);
if (event.data == 1) {
this.lockReconnect = false;
......@@ -244,7 +244,7 @@ export default {
},
// 连接关闭的回调方法
websocketOnclose() {
console.log("连接关闭的回调方法");
// console.log("连接关闭的回调方法");
//重连
this.reconnect();
},
......
......@@ -66,7 +66,7 @@ export default {
window.localStorage.removeItem("campsite_id");
window.localStorage.removeItem("order_no");
window.localStorage.removeItem("campindex_type");
this.$store.state.token = "";
// this.$store.state.token = "";
// 使用编程式导航跳转到登录页面
this.$router.push({ name: "recruit" });
},
......@@ -74,20 +74,20 @@ export default {
toRecruit() {
// 清除本地缓存除了大学logo
// window.localStorage.clear();
window.localStorage.removeItem("doubt_code");
window.localStorage.removeItem("doubt_info");
window.localStorage.removeItem("doubt_check");
// window.localStorage.removeItem("doubt_code");
// window.localStorage.removeItem("doubt_info");
// window.localStorage.removeItem("doubt_check");
// window.localStorage.removeItem("index-identity");
window.localStorage.removeItem("index-token");
window.localStorage.removeItem("phone");
window.localStorage.removeItem("camp_name");
window.localStorage.removeItem("system_color");
window.localStorage.removeItem("has_amount");
window.localStorage.removeItem("campsite_id");
window.localStorage.removeItem("order_no");
window.localStorage.removeItem("campindex_type");
this.$store.state.token = "";
this.$router.push({ name: "recruit" });
// window.localStorage.removeItem("index-token");
// window.localStorage.removeItem("phone");
// window.localStorage.removeItem("camp_name");
// window.localStorage.removeItem("system_color");
// window.localStorage.removeItem("has_amount");
// window.localStorage.removeItem("campsite_id");
// window.localStorage.removeItem("order_no");
// window.localStorage.removeItem("campindex_type");
// this.$store.state.token = "";
this.$router.replace({ name: "recruit" });
},
},
};
......
<template>
<!--底部-->
<div class="confirm">
<div class="title">2021年南开大学历史学科暑假营报名须知</div>
<p>
<div class="title">{{ info.name }}报名须知</div>
<div v-html="info.exam_instructions"></div>
<!-- <p>
南开大学是教育部直属重点综合性大学,是敬爱的周恩来总理的母校。新中国成立以来,学校发展始终得到党和国家的亲切关怀。毛泽东主席题写校名、亲临视察;周恩来总理三回母校指导;邓小平同志会见数学大师陈省身,批示成立南开数学研究所;江泽民同志、胡锦涛同志先后视察南开。特别是党的十八大以来,习近平总书记多次对南开的发展给予肯定,并对相关工作回信和勉励,更在百年校庆之际亲临南开视察。
</p>
<p>
......@@ -14,7 +16,7 @@
</p>
<div>
<img src="../../../assets/img/signUp/computer.png" alt="" />
</div>
</div> -->
<div class="check">
<el-checkbox v-model="checked"
>我已阅读并了解《2021年南开大学历史学科暑假营报名须知》</el-checkbox
......@@ -29,28 +31,38 @@
<script>
/* eslint-disable */
import { setSignShould } from "r/index/signUp";
import { getCam } from "r/index/login";
export default {
name: "Confirm",
// props: { statusNum: [String, Number] }, //进度参数
data() {
return {
checked: false,
info: {},
};
},
created() {
this.getCams();
},
methods: {
next() {
// console.log(this.checked);
setSignShould({}).then((res) => {
console.log(res, "setSignShould");
// console.log(res, "setSignShould");
if (res.data.code !== 200) return this.$message.error(res.data.message);
this.$emit("getstatus", res.data.status);
this.$emit("getstatus", res.data.status);
this.$message.success(res.data.message);
this.$router.push("/signUp/invitation");
});
},
getCams() {
getCam(false).then((res) => {
// console.log(res, "res");
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
this.$message.success(res.data.message);
this.info = res.data;
});
},
},
......@@ -83,6 +95,5 @@ export default {
text-align: center;
margin-top: 42px;
}
}
</style>
......@@ -181,7 +181,7 @@ export default {
},
// 下一步
async next() {
console.log(111);
// console.log(111);
let code;
if (
this.invatation1 == "" &&
......
......@@ -22,15 +22,20 @@ export default {
name: "Pass",
props: {
getExamine: [String, Number],
next: "",
// isNext:''
},
created() {
console.log(this.getExamine);
// console.log(this.getExamine);
},
watch:{
// is_next(val){
// }
},
methods: {
paying() {
this.nextNum = 1;
this.$emit('isNext',this.nextNum)
this.$emit('is_next',1)
// console.log(is_next);
},
},
......
......@@ -97,7 +97,7 @@ export default {
},
getAccount() {
getAccount({}).then((res) => {
console.log(res, "getAccount");
// console.log(res, "getAccount");
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
......
......@@ -10,7 +10,7 @@
<div class="cont_title">个人信息</div>
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="姓名" prop="name" >
<el-form-item label="姓名" prop="name">
<el-input
ref="name"
v-model="referForm.name"
......@@ -27,8 +27,8 @@
ref="gender"
size="small"
>
<el-radio label="0"></el-radio>
<el-radio label="1"></el-radio>
<el-radio :label="0"></el-radio>
<el-radio :label="1"></el-radio>
</el-radio-group>
</el-form-item>
</el-col>
......@@ -44,7 +44,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="出生日期" prop="birthday" ref="birthday">
<el-form-item label="出生日期" prop="birthday">
<el-row :gutter="20">
<el-col :span="8">
<el-select v-model="bdYear" placeholder="年">
......@@ -69,7 +69,12 @@
</el-select>
</el-col>
<el-col :span="8">
<el-select v-model="bdDay" placeholder="日" @change="getTime">
<el-select
ref="birthday"
v-model="bdDay"
placeholder="日"
@change="getTime"
>
<el-option
v-for="(item, index) in dayArrs"
:key="index"
......@@ -84,14 +89,13 @@
</el-col>
<el-col :span="12">
<el-form-item label="籍贯" prop="jiguan_code" >
<el-form-item label="籍贯" prop="jiguan_code">
<el-row :gutter="20">
<el-col :span="12">
<!-- @keyup.enter.native="selsectProvince" -->
<el-select
ref="jgProvinceCode"
v-model="jgProvinceCode"
placeholder="省"
@keyup.enter.native="selsectProvince"
@change="changeProvince(1, $event)"
>
<el-option
......@@ -105,7 +109,7 @@
</el-col>
<el-col :span="12">
<el-select
ref="jiguan_city"
ref="jiguan_code"
v-model="jiguan_city"
placeholder="市"
@change="getJiguan()"
......@@ -165,9 +169,8 @@
<el-col :span="12">
<el-form-item label="手机号">
<el-input
ref="phone"
v-model="phone"
placeholder="18355151517"
v-model="referForm.phone"
placeholder="请输入手机号"
size="small"
:disabled="true"
/>
......@@ -329,7 +332,7 @@
</el-form-item>
<el-form-item class="btn">
<el-button @click="confirm()">提交资料</el-button>
<el-button @click="confirm">提交资料</el-button>
</el-form-item>
</el-form>
</div>
......@@ -352,14 +355,14 @@ export default {
name: "CheckForm",
data() {
let validateContent = (rule, value, callback) => {
const validateContent = (rule, value, callback) => {
if (!this.referForm.birthday) {
callback(new Error("出生日期不能为空!"));
} else {
callback();
}
};
let validateContents = (rule, value, callback) => {
const validateContents = (rule, value, callback) => {
if (!this.referForm.jiguan_code) {
callback(new Error("籍贯不能为空!"));
} else {
......@@ -377,7 +380,7 @@ export default {
nation: null,
start_school_date: null,
political_status: null,
// phone: null,
phone: null,
email: null,
school_province: null,
school_city: null,
......@@ -386,7 +389,7 @@ export default {
school_phone: null,
},
phone: "",
schoolName: [],
schoolName: {},
referInfoRules: {
name: [
{ required: true, message: "真实姓名不能为空!", trigger: "blur" },
......@@ -518,46 +521,67 @@ export default {
disabled: false, //限制输入框
};
},
mounted() {},
created() {
this.phone = window.localStorage.getItem("phone"); //本地取用户手机号
// this.phone = window.localStorage.getItem("phone"); //本地取用户手机号
let signUpFile = window.localStorage.getItem(
"sign_up_file_" + window.localStorage.getItem("phone")
);
console.log(JSON.parse(signUpFile));
if (signUpFile && JSON.parse(signUpFile).length > 0) {
this.fileList = JSON.parse(signUpFile);
}
this.getAccount();
this.getProAndCity();
this.getSchool();
this.getProAndCity();
this.getTenYear();
this.getAccount();
},
watch: {
self(val) {
referForm(val) {
// console.log(val, "val");
for (var k in val) {
if (val[k] == null || !val[k]) {
val[k] = this.referForm[k];
}
}
this.selfInfo = val;
if (val.gender && val.gender !== "") {
// console.log(val.gender)
this.referForm.gender = val.gender;
}
if (val.birthday && val.birthday !== "") {
//出生日期
this.bdYear = val.birthday.slice(0, 4); //前4位取年
this.bdMonth = val.birthday.slice(4, 6); //中2位取月
this.bdDay = val.birthday.slice(6, 8); //后2位取日
}
if (val.jiguan_city !== null && val.jiguan_province !== null) {
//籍贯
if (this.referForm.jiguan_city) {
}
this.jgProvinceCode = Number(val.jiguan_province);
this.changeProvince(1, this.jgProvinceCode, true);
this.jiguan_city = Number(val.jiguan_city);
}
// console.log(val.school_province, val.school_city, val.school);
if (
val.jiguan_code &&
val.jiguan_code !== "" &&
val.jiguan_code !== "00"
val.school_province !== null &&
val.school_city !== null &&
val.school !== null
) {
//籍贯
// console.log(val.jiguan_code, "val.jiguan_code+++++");
this.jgProvinceCode = Number(val.jiguan_code.slice(0, 2)); //前2位取省份
// console.log(this.jgProvinceCode, "val.jiguan_code+++++");
this.selectJgProvince(this.jgProvinceCode, "1");
this.jgCityCode = Number(val.jiguan_code.slice(2, 6)); //后4位取城市
console.log(this.jgCityCode, "val.jiguan_code+++++");
//学校
this.referForm.school_province = Number(val.school_province);
this.referForm.school_city = Number(val.school_city);
this.referForm.school = Number(val.school);
// console.log(
// this.referForm.school_province,
// this.referForm.school_city,
// this.referForm.school
// );
this.changeProvince(2, this.referForm.school_province, true);
// console.log(this.referForm.school_city, 12322);
this.changeCity(this.referForm.school_city, true);
}
},
},
......@@ -588,6 +612,12 @@ export default {
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
this.referForm = res.data.info;
if (res.data.info.jiguan_province && res.data.info.jiguan_city) {
this.referForm.jiguan_code =
res.data.info.jiguan_province.toString() +
res.data.info.jiguan_city.toString();
}
});
},
getTime() {
......@@ -595,12 +625,7 @@ export default {
this.bdYear.toString() +
this.bdMonth.toString() +
this.bdDay.toString(); //组装出生日期
// console.log(this.referForm.birthday);
},
getJiguan() {
this.referForm.jiguan_code =
this.jgProvinceCode.toString() + this.jiguan_city.toString();
// console.log(this.referForm.jiguan_code);
console.log(this.referForm.birthday);
},
// 获取省份城市
......@@ -611,38 +636,74 @@ export default {
return this.$message.error(res.data.message);
}
this.selectProvince = res.data.province_list;
this.CityName = res.data.city_list;
// this.CityName = res.data.city_list;
// console.log(this.selectProvince, this.CityName);
});
},
changeProvince(type, value) {
// console.log(value, "value");
let selectCity = [];
for (const key in this.CityName) {
if (this.CityName[key].parent_id == value) {
selectCity.push(this.CityName[key]);
}
}
//选择籍贯省份change事件
changeProvince(type, val, status) {
// console.log(type, val);
if (type == 1) {
this.selectCityJiguan = selectCity;
this.jiguan_city = "";
this.selectCityJiguan = [];
this.selectCityJiguan = this.getCurrentCityLists(val);
if (!status) {
this.jiguan_city = "";
this.referForm.jiguan_code = "";
}
} else {
this.selectCitySchool = selectCity;
this.referForm.school_city = "";
this.referForm.school = "";
this.selectCitySchool = [];
this.selectCitySchool = this.getCurrentCityLists(val); //在此调用城市筛选列表
if (!status) {
this.referForm.school_city = "";
this.referForm.school = "";
}
}
},
changeCity(value) {
let selectSchool = [];
for (const key in this.schoolName) {
if (this.schoolName[key].city_id == value) {
selectSchool.push(this.schoolName[key]);
//返回当前省份下的城市列表
getCurrentCityLists(val) {
let currentCity = [];
if (
this.CityName == null ||
!this.CityName ||
Object.values(this.CityName).length == 0
) {
getProAndCity({})
.then((res) => {
// console.log(res, "getProAndCity");
if (res.data.code === 200) {
// this.selectProvince = res.data.province_list;
this.CityName = res.data.city_list;
for (let key in this.CityName) {
if (this.CityName[key].parent_id == val) {
currentCity.push(this.CityName[key]);
}
}
return currentCity;
} else {
this.$message.error(res.data.message);
}
})
.catch((err) => {
this.$message.error(err);
});
} else {
for (let key in this.CityName) {
if (this.CityName[key].parent_id == val) {
currentCity.push(this.CityName[key]);
}
}
return currentCity;
}
this.selectSchoolList = selectSchool;
this.referForm.school = "";
return currentCity;
},
// 籍贯城市change事件
getJiguan() {
this.referForm.jiguan_code =
this.jgProvinceCode.toString() + this.jiguan_city.toString();
},
// 获取学校
getSchool() {
getSchool({}).then((res) => {
// console.log(res, "getSchool");
......@@ -652,10 +713,63 @@ export default {
this.schoolName = res.data.school_list;
});
},
// 学校城市change事件
changeCity(val, status) {
// console.log(12345333,val,status)
this.selectSchoolList = [];
this.selectSchoolList = this.getCurrentSchoolLists(val);
if (!status) {
this.referForm.school = "";
}
},
// 返回当前城市下的学校列表
getCurrentSchoolLists(val) {
let currentSchool = [];
// console.log(this.schoolName);
if (
this.schoolName == null ||
!this.schoolName ||
Object.values(this.schoolName).length == 0
) {
getSchool({})
.then((res) => {
// console.log(res)
if (res.data.code === 200) {
this.schoolName = res.data.school_list;
window.localStorage.setItem(
"schoolName",
JSON.stringify(res.data.list)
);
for (let key in this.schoolName) {
if (this.schoolName[key].city_id == val) {
currentSchool.push(this.schoolName[key]);
}
}
return currentSchool;
} else {
this.$message.error(res.data.message);
}
})
.catch((err) => {
this.$message.error(err);
});
} else {
// console.log(this.schoolName, 111);
for (let key in this.schoolName) {
// console.log(key, this.schoolName[key]);
if (this.schoolName[key].city_id == val) {
currentSchool.push(this.schoolName[key]);
}
}
// console.log(currentSchool, 222);
return currentSchool;
}
return currentSchool;
},
// 图片上传成功前钩子
beforeAvatarUpload(file) {
console.log(file, "beforeImage");
// console.log(file, "beforeImage");
const isJPG = file.type === "image/jpg";
const isPng = file.type === "image/png";
const isJPEG = file.type === "image/jpeg";
......@@ -671,22 +785,22 @@ export default {
},
handlePictureCardPreview(file) {
console.log(file);
// console.log(file);
this.resultPicture = file.url;
this.dialogVisible = true;
},
// 文件上传中处理
handleUploadProgress(event, file, fileList) {
console.log(fileList);
// console.log(fileList);
this.isUploading = true;
if (this.fileList.lenge < 10) {
return this.$message.info("chaochushuliamng");
}
},
uploadSuccess(res, file, fileList) {
console.log(res, "res");
console.log(file, "file");
console.log(fileList, "fileList");
// console.log(res, "res");
// console.log(file, "file");
// console.log(fileList, "fileList");
this.referForm.achievementPath = res;
this.fileList = {
name: file.name,
......@@ -712,7 +826,7 @@ export default {
};
await getAchievementOss({ image: image })
.then((res) => {
console.log(res, "开始上传图片");
// console.log(res, "开始上传图片");
if (res.data.code === 200) {
let oss_url = res.data.config.host;
let filename = res.data.config.file;
......@@ -729,7 +843,7 @@ export default {
// console.log(formData);
upload(oss_url, formData)
.then((ress) => {
console.log(ress, "ress");
// console.log(ress, "ress");
if (ress.data.code != 200) {
console.log(ress, "ress");
return this.$message.error(ress.data.message);
......@@ -745,7 +859,7 @@ export default {
// this.fileList = fileList
console.log(this.fileList, " this.fileList");
// console.log(this.fileList, " this.fileList");
window.localStorage.setItem(
"sign_up_file_" + window.localStorage.getItem("phone"),
JSON.stringify(this.fileList)
......@@ -759,14 +873,14 @@ export default {
}
})
.catch((err) => {
console.log(err);
// console.log(err);
});
},
//删除图片
handleRemove(file) {
let savefile = file.savefile;
delPic({ object: savefile }).then((res) => {
console.log(res, "delpic");
// console.log(res, "delpic");
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
......@@ -779,7 +893,7 @@ export default {
})
.then(() => {
this.fileList.forEach((item, idx) => {
console.log(item.url == file.url);
// console.log(item.url == file.url);
if (item.url == file.url) {
this.fileList.splice(idx, 1);
window.localStorage.setItem(
......@@ -788,7 +902,7 @@ export default {
);
}
});
console.log(this.fileList);
// console.log(this.fileList);
this.$message({
type: "success",
......@@ -805,13 +919,13 @@ export default {
},
// 滚动到固定地方
scrollView(object) {
console.log(object, "object");
console.log(object, "object");
// console.log(object, "object");
for (let i in object) {
if (!i) {
continue;
}
let dom = this.$refs[i];
// console.log(i, dom);
if (!dom) {
continue;
}
......@@ -827,38 +941,31 @@ export default {
// 值有auto、instant,smooth,缓动动画(当前是慢速的)
behavior: "smooth",
});
this.dialogFormFu = {
title: "提示",
message: object[i][0].message,
};
this.dialogVisibleFu = true;
// this.$emit("getValues", object[i][0].message, false);
break; // 因为我们只需要检测一项,所以就可以跳出循环了
}
},
confirm() {
console.log(111);
console.log(this.$refs["birthday"]);
// console.log(111);
// console.log(this.referForm.birthday);
this.$refs["referRef"].validate((valid, object) => {
console.log(object, "object");
console.log("11", valid);
// console.log(valid, "valid");
if (!valid) {
console.log("2221", valid);
this.scrollView(object);
return;
return false;
}
console.log(2222);
setAccount(this.referForm).then((res) => {
console.log(res, "setAccount");
// console.log(2222);
// console.log(res, "setAccount");
if (res.data.code != 200) {
// window.scrollTo(0, 0)
return this.$message.error(res.data.message);
}
console.log(3333);
// console.log(3333);
this.$emit("getstatus", res.data.status);
this.$message.success(res.data.message);
this.$router.push("/signUp/check");
this.referForm = res.data.data;
});
});
},
......
......@@ -21,7 +21,7 @@ const instance = axios.create({
"Content-Type": "application/x-www-form-urlencoded",
},
withCredentials: false,
});
instance.interceptors.request.use(
......@@ -30,7 +30,7 @@ instance.interceptors.request.use(
config.data = qs.stringify(config.data);
}
if (config.url.indexOf(SERVER_URL) === -1) {
console.log("upload");
// console.log("upload");
config.headers["Content-Type"] = "multipart/form-data";
} else {
config.headers["Content-Type"] = "application/x-www-form-urlencoded";
......@@ -110,7 +110,8 @@ export function request(config) {
const passwordCode = '/web/code/passwordCode';
const changePassCode = '/web/auth/changePassCode';
const loginOut = '/web/auth/loginOut';
console.log(config)
// console.log(config)
if (
config.url.indexOf(loginUrl) != -1 ||
config.url.indexOf(setAccountInfo) != -1 ||
......@@ -118,7 +119,7 @@ export function request(config) {
config.url.indexOf(getCam) != -1 ||
config.url.indexOf(registerCode) != -1 ||
config.url.indexOf(changePassCode) != -1 ||
config.url.indexOf(passwordCode) != -1||
config.url.indexOf(passwordCode) != -1 ||
config.url.indexOf(loginOut) != -1
) {
return config
......@@ -176,6 +177,7 @@ export function request(config) {
instance.interceptors.response.use(
(res) => {
// console.log(res)
if (res.data.code == 400003) {
window.localStorage.clear()
router.push({
......@@ -201,19 +203,21 @@ export function request(config) {
return res
},
(error) => {
// console.log(error.response.status)
Message.closeAll()
// if (error.response.status === 401) {
// // 未登录
// Notification({
// message: "身份验证失败,请登录",
// duration: 1500,
// onClose() {
// console.log('error');
// router.push("/admin/login");
// },
// });
// return false;
// }
if (error.response.status === 404) {
// return this.$message.error("营地报名已结束")
// 未登录
Notification({
message: "营地报名已关闭",
duration: 2000,
// onClose() {
// console.log('error');
// router.push("/admin/login");
// },
});
return false;
}
if (axios.isCancel(error)) {
console.log(error.message)
} else {
......
......@@ -113,7 +113,8 @@ router.beforeEach((to, from, next) => {
toLogin = "/login",
toRegister = "/register",
toReset = "/reset"
// toRrecruit = "/recruit"
// toRecruit = "/:code"
let token = localStorage.getItem(tokenKey);
let nextUrl = false;
let code = false;
......@@ -127,6 +128,8 @@ router.beforeEach((to, from, next) => {
});
} else if (to.name == "recruit") {
code = to.params.code;
console.log(code,'code')
to.path == "/:code"
checkCam(code, (res) => {
if (res) {
nextUrl = false;
......@@ -145,6 +148,8 @@ router.beforeEach((to, from, next) => {
// 页面跳转之后页面回滚到顶部
router.afterEach((to, from, next) => {
// console.log(to,'to')
window.scrollTo(0, 0)
});
export default router
......@@ -49,7 +49,7 @@ export default {
},
data() {
return {
type: 1,
isPosition: 0, // 左侧box是否浮动
pageYOffset: 0, // 左侧box浮动时,滚动的高度
scorllHeight: 0, // 最大滚动高度
......@@ -98,7 +98,7 @@ export default {
},
methods: {
getStatus(val) {
console.log(val, "index_type");
// console.log(val, "index_type");
this.index_status = val;
this.ToSignUp();
},
......
......@@ -14,8 +14,7 @@
<ReferInfo v-else-if="type == 'referInfo'" @getstatus="statuss"></ReferInfo>
<Pass
v-else-if="type == 'check'"
@getstatus="statuss"
@isNext="isNext"
@is_next="is_nextevent"
:getExamine="getExamine"
></Pass>
<Paying v-else-if="type == 'pay'" @getstatus="statuss"></Paying>
......@@ -54,14 +53,13 @@ export default {
doubt_check: window.localStorage.getItem("doubt_check"),
status_val: "",
getExamine: "",
isNext: "",
isNexts: "",
};
},
created() {
this.type = this.$route.params.type;
// console.log(this.$route, "router");
this.statuss();
// this.signUpInit();
},
watch: {
......@@ -78,12 +76,14 @@ export default {
status(val) {
// console.log(val, "status");
},
isNext(val) {
this.isNext = val;
console.log(val, "isNext");
},
},
methods: {
is_nextevent(val) {
this.isNexts = val;
console.log(val, "isNexts");
// this.signUpInit( this.isNexts );
this.signUpInit(this.status_val);
},
// 点击下一步,触发父组件方法
statuss(val) {
// console.log(val, "statuss");
......@@ -93,9 +93,11 @@ export default {
},
// status=4,跳到审核页面;status=3时,根据doubt_check做判断
signUpInit(status_val) {
console.log(status_val, "11111");
// console.log(status_val, "11111");
// console.log(isNexts, "2222");
signUpInit({}).then((res) => {
console.log(res, "signUpInit");
// console.log(res, "signUpInit");
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
......@@ -106,7 +108,7 @@ export default {
this.status = status_val;
} else {
this.status = res.data.status;
console.log(this.status, "11111");
// console.log(this.status, "11111");
}
// doubt_code,doubt_info,doubt_check。0为不填写,1为填写
if (this.status == 0) {
......@@ -121,7 +123,7 @@ export default {
this.status = 1;
}
} else if (this.status == 2) {
console.log(this.doubt_info, "doubt_info");
// console.log(this.doubt_info, "doubt_info");
// 是否填写个人资料
if (this.doubt_info == 0) {
this.type = "check";
......@@ -142,8 +144,11 @@ export default {
} else if (this.status == 4) {
this.type = "check";
this.status = 3;
console.log(this.status, "this.status ");
// console.log(this.isNexts ,'this.isNexts ')
if (this.isNext != null) {
if (this.isNexts == 1) {
// console.log(11111);
if (res.data.examine_status == 1) {
console.log(333);
this.type = "pay";
......@@ -161,7 +166,7 @@ export default {
}
this.$emit("getStatus", this.type);
this.getExamine = res.data.examine_status;
console.log(res.data.examine_status, "res.data.examine_status");
// console.log(res.data.examine_status, "res.data.examine_status");
//审核报名资料状态
//订单支付金额
......
......@@ -11,18 +11,17 @@
</div>
</template>
<script>
/* eslint-disable */
export default {
name: "loginIndex",
data() {
return {
bigImg: window.localStorage.getItem('bk_pic')
bigImg: window.localStorage.getItem("bk_pic"),
};
},
created() {
let bk_pic = window.localStorage.getItem('bk_pic');
if(bk_pic){
let bk_pic = window.localStorage.getItem("bk_pic");
if (bk_pic) {
this.bigImg = bk_pic;
}
......@@ -38,19 +37,20 @@ export default {
background: #f8f8f8;
display: flex;
flex-flow: row;
.big-img{
width: (500/1920*100%);
min-height: 100%;
.big-img {
width: (500/1920 * 100%);
min-width: 350px;
/*height: 100%;*/
img{
min-height: 100%;
img {
width: 100%;
/*height: 100%;*/
min-height: 100%;
}
}
.big-right{
.big-right {
flex: 1;
position: relative;
.info-box{
.info-box {
width: 520px;
height: auto;
position: absolute;
......
......@@ -73,7 +73,7 @@ export default {
},
getCams() {
getCam(false).then((res) => {
console.log(res, "res");
// console.log(res, "res");
if (res.data.code != 200) {
return this.$message.error(res.data.message);
}
......
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