|
|
|
|
@ -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 {
|
|
|
|
|
|