cyl/dev
wangxia 4 years ago
parent 0f2185bfb2
commit 53aaf352d0

@ -1531,7 +1531,7 @@ export default {
.hotTel {
position: fixed;
top: 50%;
left: calc(50vw + 600px);
left: calc(50vw + 616px);
width: 104px;
height: 110px;
background-color: #fff;
@ -1552,11 +1552,12 @@ export default {
div {
position: absolute;
display: none;
height: 110px;
width: 200px;
left: 0;
bottom: -122px;
left: -236px;
bottom: 0px;
text-align: center;
box-shadow: 5px 0px 10px 3px #eee;
box-shadow: 5px 0px 10px 3px #ddd;
background-color: #fff;
> p:first-child {
padding: 14px 0;

@ -40,7 +40,7 @@
><a-button @click="searchCity"></a-button>
</div>
<ul class="firstList">
<li @click="[(currentCity = hotCityList), (activeInd = -1)]">
<li @click="[(currentCityList = hotCityList), (activeInd = -1)]">
<div :class="activeInd == -1 ? 'active' : ''">热门地区</div>
</li>
<li
@ -54,7 +54,7 @@
</li>
</ul>
<ul class="currentCity">
<li v-for="(item, index) in currentCity" :key="index">
<li v-for="(item, index) in currentCityList" :key="index">
<div @click="searchJob(item)">{{ item.name }}</div>
</li>
</ul>
@ -188,7 +188,7 @@
class="searchinput"
style="width: 500px"
><div slot="prefix" @click="visible = true">
全国<i class="iconfont icon-sousuoxiala"></i>
{{ currentCity }}<i class="iconfont icon-sousuoxiala"></i>
</div>
<button slot="suffix" @click="onSearch" style="margin-right: -12px">
搜索
@ -434,7 +434,8 @@ export default {
cityoption: [], //
hotCityList: [], //
hasJobCityList: {}, //
currentCity: {}, //
currentCityList: {}, //
currentCity: "全国",
cityValue: "", //
activeInd: -1,
hotStoreList: [],
@ -876,7 +877,7 @@ export default {
console.log(data);
if (data.status == 200) {
this.hotCityList = data.data;
this.currentCity = this.hotCityList;
this.currentCityList = this.hotCityList;
}
} catch (error) {
console.log(error);
@ -936,27 +937,28 @@ export default {
}
},
changeCurrentCity(index) {
this.currentCity = this.hasJobCityList.cityList[index];
this.currentCityList = this.hasJobCityList.cityList[index];
console.log(index);
},
searchCity() {
if (this.cityValue) {
this.currentCity = [];
this.currentCityList = [];
this.hotCityList.forEach((item) => {
console.log(item);
console.log(item.name.indexOf(this.cityValue));
if (item.name.indexOf(this.cityValue) > -1) {
console.log(123);
this.currentCity.push(item);
this.currentCityList.push(item);
}
});
console.log(this.currentCity);
console.log(this.currentCityList);
}
},
searchJob(item) {
console.log(item);
this.formvalue.cityName = item.name;
this.formvalue.levelType = item.levelType;
this.currentCity = item.name;
this.getJobList();
this.visible = false;
},
@ -969,6 +971,7 @@ export default {
this.formvalue.cityName = "";
this.formvalue.levelType = "";
this.formvalue.hotStoreId = "";
this.currentCity = "全国";
console.log(this.formvalue);
this.getJobList();
},
@ -1175,7 +1178,7 @@ export default {
.ant-input {
width: 100%;
height: 32px;
text-indent: 30px;
text-indent: 40px;
background: #fff;
// border: 1px solid rgba(77, 87, 94, 0.3);
border-radius: 136px;
@ -1184,7 +1187,7 @@ export default {
padding-right: 0;
border-color: #e9e9e9;
&::placeholder {
text-indent: 30px;
// text-indent: 30px;
font-size: 14px !important;
}
&:hover {

@ -25,7 +25,8 @@ router.beforeEach(async (to, from, next) => {
"/updatepsw",
// "/register",
];
if (sessionStorage.getItem("LOGIN_DATA") || Cookies.get("LOGIN_DATA")) {
if (Cookies.get("LOGIN_DATA")) {
console.log(!sessionStorage.getItem("LOGIN_DATA"));
if (!sessionStorage.getItem("LOGIN_DATA")) {
console.log("notset");
sessionStorage.setItem("LOGIN_DATA", Cookies.get("LOGIN_DATA"));
@ -39,15 +40,7 @@ router.beforeEach(async (to, from, next) => {
// console.log(isLogin);
// console.log(to);
if (isLogin) {
if (to.path === "/login") {
next("/login");
} else if (to.path === "/list") {
next();
// window.location.reload();
} else {
next();
}
} else {
if (
whiteList.some((obj) => {

Loading…
Cancel
Save