This commit is contained in:
A1300399510 2023-05-09 19:14:30 +08:00
parent ff4f67e051
commit e77f6950cb
9 changed files with 490 additions and 204 deletions

View File

@ -1006,4 +1006,11 @@ view {
.flex1 {
flex: 1;
}
.one-line-display {
word-break: keep-all;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}

View File

@ -3,6 +3,7 @@ var WxParse = require('../../wxParse/wxParse.js');
var app = getApp()
var config = {};
var miucms = require('../../utils/miucms.js');
Page({
/**
* 页面的初始数据
@ -21,36 +22,21 @@ Page({
advListotherHousing: {},
initState: false,
unreadMessages: 0, // 底部我的图标 未读系统通知数量
areaList: ['school', 'district', 'type'],
areaTab: "school", // school district type
areaIndex: 0, // school district type
areaIndex: 0, //
envVersionState: false, // 是否在开发环境
images: "https://oss.gter.net/Zvt57TuJSUvkyhw-xG7Y2l-W-58oc3nqqsgFptxhXa6SWi2uePJ5Bg8cFLPIvsEG-4BUA27F7lfn5E55tXAL34gR30K6A7FxO7Sa1zx17l80NDI5", // 新公寓列表的图片链接 随时删除
tabList: [{
title: "推荐",
value: "recommend",
left: 26,
}, {
title: "整租",
value: "entire",
left: 122.5,
}, {
title: "合租",
value: "joint",
left: 221.5,
}, {
title: "已认证",
value: "authenticated",
left: 316.5,
}, {
title: "招室友",
value: "attract",
left: 436,
}, ],
tabValue: 0,
swiperCurrent: 0, // 新轮播图 滚动的下标
topTitle: "",
areaPopState: false, // 区域找房的弹窗 状态
areaPopId: 0, // 区域 选中
areaPopList: [], // 地区选项选中 数据
getLocationList: [], // 地区选项 配置数据
listData: [], // 列表数据
listDataLeft: [], // 列表数据
listDataRight: [], // 列表数据
},
/**
@ -58,6 +44,9 @@ Page({
*/
timer: null,
onLoad: function (options) {
console.log("articles", this.data.articles);
this.getLocationData()
wx.showLoading()
this.get_config()
@ -91,6 +80,7 @@ Page({
if (app.globalData.config && app.globalData.config.lists) {
this.get_list();
this.getNewInit()
this.getListData()
this.setData({
initState: true
})
@ -110,13 +100,6 @@ Page({
getNewInit() {
miucms.wxget(`${app.globalData.baseURL}/tenement/v2/api/home`).then(res => {
let data = res.data
let {
search,
apartment,
tabs
} = data
this.setData({
...data
})
@ -284,6 +267,162 @@ Page({
search(e) {
let value = e.detail.value
console.log(value);
},
// 打开 区域找房 的 弹窗
openAreaPop(e) {
let areaPopId = e.currentTarget.dataset.id
this.setData({
areaPopId,
areaPopList: [],
areaPopState: !this.data.areaPopState
})
if (this.data.getLocationList.length == 0) this.getLocationData()
},
// 获取
getLocationData() {
miucms.request(app.globalData.baseURL + "/tenement/v2/api/home/getLocationData").then(res => {
let data = res.data
let obj = {}
for (const key in data) {
// 判断是否是整数
if ((key ^ 0) == key) {
obj[key] = {}
obj[key]['name'] = data[key]
} else {
if (!obj[key ^ 0]['data']) obj[key ^ 0]['data'] = []
obj[key ^ 0]['data'].push({
key,
name: data[key],
pitch: false,
})
}
}
this.setData({
getLocationList: obj
})
})
},
// 跳转个人列表
skipPersonList(e) {
let {
key,
id
} = e.currentTarget.dataset
wx.navigateTo({
url: `/pages/personList/personList?${key}=${id}`,
})
},
// 处理点击
areaPopItem(e) {
let {
key,
index
} = e.currentTarget.dataset
let areaPopList = this.data.areaPopList
let getLocationList = this.data.getLocationList
let areaPopId = this.data.areaPopId
const indexOf = areaPopList.indexOf(key)
if (indexOf === -1) {
areaPopList.push(key)
getLocationList[areaPopId].data[index].pitch = true
} else {
areaPopList.splice(indexOf, 1)
getLocationList[areaPopId].data[index].pitch = false
}
this.setData({
areaPopList,
getLocationList
})
},
areaPopItemUnlimited(e) {
let {
areapopid
} = e.currentTarget.dataset
let areaPopId = this.data.areaPopId
let getLocationList = this.data.getLocationList
getLocationList[areaPopId].data.forEach(el => {
el.pitch = false
})
this.setData({
getLocationList,
areaPopList: []
})
if (areapopid >= 0) {
this.setData({
areaPopId: areapopid
})
}
},
// 处理区域找房弹窗的确定
handleAreaPopConfirm() {
let areaPopList = this.data.areaPopList
let areaPopId = this.data.areaPopId
if (areaPopList.length == 0) areaPopList = [areaPopId]
wx.navigateTo({
url: `/pages/personList/personList?location=${areaPopList}`,
})
},
// 切换 tab
cutTab(e) {
let {
index,
type
} = e.currentTarget.dataset
let recommendedTab = this.data.recommendedTab
recommendedTab.forEach(el => {
el['select'] = false
})
recommendedTab[index]['select'] = true
this.setData({
recommendedTab
})
},
// 获取列表数据
getListData() {
miucms.wxget(app.globalData.baseURL + "/tenement/v2/api/home/recommendList", {
page: 1
}).then(res => {
if (res.code != 200) return
let data = res.data.data
this.setData({
listData: data
})
this.calculate()
})
},
// 计算
calculateProcessingCenter() {
// let
},
// 获取图片高度
getPictureHeight() {
new Promise((resolve, reject) => {
wx.getImageInfo({
src: '',
})
})
}
})

View File

@ -10,6 +10,9 @@
"card-person": "./cardPerson/cardPerson",
"card-brands": "./cardBrands/cardBrands",
"fix-footer": "../../template/fixFooter/fixFooter",
"announcement-popup": "../../template/announcementPopup/announcementPopup"
"announcement-popup": "../../template/announcementPopup/announcementPopup",
"me-waterfall": "/lib/waterfall/index",
"me-waterfall-item": "/lib/waterfall-item/index"
}
}

View File

@ -3,7 +3,7 @@
<header-nav inner-text="Some text" isIndexPage="index">{{ topTitle }}</header-nav>
<!-- 新的 首页轮播图 -->
<block wx:if="{{ envVersionState && true }}">
<block wx:if="{{ envVersionState && false }}">
<!-- 搜索框 -->
<view class="search-box flexacenter">
<image mode="widthFix" class="search-img" src="/img/search-icon.png"></image>
@ -35,50 +35,60 @@
<!-- 分类 -->
<view class="types-tab">
<navigator class="item" url="/pages/personList/personList" hover-class="hover">
<navigator wx:for="{{ tabs }}" wx:key="index" class="item" url="{{ item.url}}" hover-class="hover">
<view class="img-box">
<image src="/img/hkperson.jpg"></image>
<image mode="widthFix" src="{{ item.icon }}"></image>
</view>
<!-- <view>香港个人房源</view> -->
<view>个人房源</view>
<view>{{ item.name }}</view>
</navigator>
<navigator class="item" url="/pages/irentList/irentList" hover-class="hover">
<view class="img-box">
<image src="/img/hkbrands.jpg"></image>
</view>
<view>品牌公寓</view>
</navigator>
<!-- <navigator class="item" url="/pages/UK/UK" hover-class="hover">
<block wx:if="{{ false }}">
<navigator class="item" url="/pages/personList/personList" hover-class="hover">
<view class="img-box">
<image src="/img/hkperson.jpg"></image>
</view>
<!-- <view>香港个人房源</view> -->
<view>个人房源</view>
</navigator>
<navigator class="item" url="/pages/irentList/irentList" hover-class="hover">
<view class="img-box">
<image src="/img/hkbrands.jpg"></image>
</view>
<view>品牌公寓</view>
</navigator>
<!-- <navigator class="item" url="/pages/UK/UK" hover-class="hover">
<view class="img-box">
<image src="/img/uk-apartment.png"></image>
</view>
<view>英国学生公寓</view>
</navigator> -->
<navigator class="item" url="/pages/restOfWorld/restOfWorld" hover-class="hover">
<view class="img-box">
<image src="/img/uk-apartment.png"></image>
<!-- <image src="/img/worldother.jpg"></image> -->
</view>
<!-- <view>世界各地房源</view> -->
<view>求房源</view>
</navigator>
<!-- <navigator class="item" url="/pages/chooseLocation/chooseLocation" hover-class="hover"> -->
<navigator class="item" url="/pages/edit/edit?cityName=香港&alias=Hongkong&uniqid=kbu4a9v7CjzvjJ__vUlA_jYDaTVRHWsf93n0bXfpkc4Q5XuCsk2ubBTz-qLRaUT_87YAS_ET7pf5tt0itORxLtPJJ7C76Q5_qXBATZgDTr_uyuBsaOnC0YA0Gm239lTdshoOpmqksJ85qQMXI_-jSNt7O4wZA5bropLHPIPdq6sX51OVn1WobolXqAcUbe-4mXPFIFpawZNCwmPlLf8e2ZZdkxkmfq_fCw7Pd8jj5rFiJh2_Im7unspYmE8nOO4iePI0wmW9F50tai27VeWj2s2mmGO6kiqhIb3B_Irub_WT3ys-0-1Yvf9oHop6dz0TAXgc6-ReM_tIZDE0NQ~~" hover-class="hover">
<view class="img-box addhousingresource-icon">
<view class="addhousingresource-yellow">
<view class="across"></view>
<view class="vertical"></view>
<navigator class="item" url="/pages/restOfWorld/restOfWorld" hover-class="hover">
<view class="img-box">
<image src="/img/uk-apartment.png"></image>
<!-- <image src="/img/worldother.jpg"></image> -->
</view>
</view>
<view style="color: #ffc05f;">发布房源</view>
</navigator>
<!-- <view>世界各地房源</view> -->
<view>求房源</view>
</navigator>
<!-- <navigator class="item" url="/pages/chooseLocation/chooseLocation" hover-class="hover"> -->
<navigator class="item" url="/pages/edit/edit?cityName=香港&alias=Hongkong&uniqid=kbu4a9v7CjzvjJ__vUlA_jYDaTVRHWsf93n0bXfpkc4Q5XuCsk2ubBTz-qLRaUT_87YAS_ET7pf5tt0itORxLtPJJ7C76Q5_qXBATZgDTr_uyuBsaOnC0YA0Gm239lTdshoOpmqksJ85qQMXI_-jSNt7O4wZA5bropLHPIPdq6sX51OVn1WobolXqAcUbe-4mXPFIFpawZNCwmPlLf8e2ZZdkxkmfq_fCw7Pd8jj5rFiJh2_Im7unspYmE8nOO4iePI0wmW9F50tai27VeWj2s2mmGO6kiqhIb3B_Irub_WT3ys-0-1Yvf9oHop6dz0TAXgc6-ReM_tIZDE0NQ~~" hover-class="hover">
<view class="img-box addhousingresource-icon">
<view class="addhousingresource-yellow">
<view class="across"></view>
<view class="vertical"></view>
</view>
</view>
<view style="color: #ffc05f;">发布房源</view>
</navigator>
</block>
</view>
<!-- 区域选择 新 -->
<view class="area-selection" wx:if="{{ envVersionState && true }}">
<view class="area-selection" wx:if="{{ envVersionState && false }}">
<view class="head flexacenter shadow">
<view class="head-item flexcenter flex1 {{ index == areaIndex ? 'pitch' : '' }}" wx:for="{{ combination }}" wx:key="index" bindtap="setValue" data-key="areaIndex" data-value="{{ index }}">
{{ item.name }}
<!-- <view class="head-item flexcenter flex1 {{ index == areaIndex ? 'pitch' : '' }}" wx:for="{{ combination }}" wx:key="index" bindtap="setValue" data-key="areaIndex" data-value="{{ index }}"> -->
<view class="head-item flexflex flex1 {{ index == areaIndex ? 'pitch' : '' }}" wx:for="{{ combination }}" wx:key="index" bindtap="setValue" data-key="areaIndex" data-value="{{ index }}">
<view class="head-name">{{ item.name }}</view>
<view class="head-underline" wx:if="{{ index == areaIndex }}"></view>
</view>
</view>
@ -90,74 +100,33 @@
</view>
<view wx:if="{{ areaIndex == 0 }}" class="area-list area-school flexflex">
<view class="area-item flexcenter" wx:for="{{ combination[areaIndex].where }}" wx:key="index" data-id="{{ item.id }}">{{ item.name }}</view>
<view class="area-item flexcenter" bindtap="skipPersonList" wx:for="{{ combination[areaIndex].where }}" wx:key="index" data-id="{{ item.id }}" data-key="school">{{ item.name }}</view>
</view>
<view wx:if="{{ areaIndex == 1 }}" class="area-list area-district flexflex">
<view class="area-item flexcenter" wx:for="{{ combination[areaIndex].where }}" wx:key="index" data-id="{{ item.id }}">{{ item.name }}</view>
<view class="area-item flexcenter" bindtap="openAreaPop" data-index="{{ index }}" wx:for="{{ combination[areaIndex].where }}" wx:key="index" data-id="{{ item.id }}">{{ item.name }}</view>
</view>
<block wx:if="{{ areaIndex == 2 }}">
<view class="area-list area-type flexflex" wx:for="{{ combination[areaIndex].where }}" wx:for-item="ite">
<view class="area-type-name">{{ ite.name }}</view>
<view class="area-type-block flex1 flexflex">
<view class="area-item flexcenter" wx:for="{{ ite.data }}" wx:for-item="it" wx:key="index">{{ it.name }}</view>
<view class="area-item flexcenter" bindtap="skipPersonList" data-id="{{ it.id }}" data-key="types" wx:for="{{ ite.data }}" wx:for-item="it" wx:key="index">{{ it.name }}</view>
</view>
</view>
<!-- <view class="area-list area-type flexflex">
<view class="area-type-name">合租</view>
<view class="area-type-block flex1 flexflex">
<view class="area-item flexcenter" wx:for="{{ 5 }}">港岛</view>
</view>
</view> -->
</block>
</view>
<page-container show="{{ false }}" z-index="{{ 1001 }}">
<view class="area-pop-header" style="height: {{ screen_data.totalTopHeight }}px;">
<view style="height:{{screen_data.statusBarHeight}}px"></view>
<view class="flexacenter" style="height:{{screen_data.titleBarHeight}}px">
<view class="area-pop-header-left flexacenter flex1">
<image mode="widthFix" class="" src="/img/back.png"></image>
</view>
<view class="area-pop-header-title">区域找房</view>
<view class=" flex1"></view>
</view>
</view>
<view class="area-pop-content flexflex" style="top: {{ screen_data.totalTopHeight }}px;">
<view class="flexflex flex1">
<view class="area-pop-content-left">
<view class="area-pop-content-left-item pitch flexcenter">港岛</view>
<view class="area-pop-content-left-item flexcenter">九龙</view>
<view class="area-pop-content-left-item flexcenter">新界</view>
</view>
<view class="area-pop-content-right flex1">
<view class="area-pop-content-right-item flexacenter" wx:for="{{ 10 }}" wx:key="index">
<view class="area-pop-content-right-name">不限</view>
<view class="area-pop-content-right-operate"></view>
</view>
</view>
</view>
<view class="area-pop-bottom flexacenter">
<view class="area-pop-reset-btn flexcenter">
<image class="" src="/img/reset.svg"></image>
重置
</view>
<view class="area-pop-confirm-btn flex1 flexcenter">确定</view>
</view>
</view>
</page-container>
</view>
<!-- 公寓列表 新 -->
<view class="apartment-block" wx:if="{{ envVersionState && false }}">
<view class="apartment-block" wx:if="{{ envVersionState && true }}">
<scroll-view scroll-x="{{ true }}" class="scroll">
<view class="apartment-list flexflex">
<view class="apartment-item flexflex" wx:for="{{ apartment }}" wx:key="index" bindtap="publicJumps" data-url="/pages/irentDetail/irentDetail?uniqid={{ item.id }}">
<view class="apartment-name">{{ item.title }}</view>
<view class="apartment-introduce">{{ item.propaganda }}</view>
<view class="apartment-name one-line-display">{{ item.title }}</view>
<view class="apartment-introduce one-line-display">{{ item.propaganda }}</view>
<view class="apartment-image-list flexacenter">
<block wx:for="{{ item.images }}" wx:key="index">
@ -172,51 +141,63 @@
</view>
<!-- 数据列表 tab 新 -->
<view class="tab-list flexacenter" wx:if="{{ envVersionState && false }}">
<view class="tab-item {{ item.select ? 'pitch' : '' }}" wx:for="{{ recommendedTab }}" wx:key="index" bindtap="setValue" data-key="tabValue" data-value="{{ index }}">{{ item.name }}</view>
<!-- <view class="tab-green" style="left: {{ tabList[tabValue].left }}rpx;"></view> -->
<view class="tab-list flexacenter" wx:if="{{ envVersionState && true }}">
<view class="tab-item {{ item.select ? 'pitch' : '' }}" wx:for="{{ recommendedTab }}" wx:key="index" bindtap="cutTab" data-type="{{ item.type }}" data-index="{{ index }}">{{ item.name }}</view>
</view>
<!-- 列表 -->
<view class="pinterest-list flexflex" wx:if="{{ envVersionState && true }}">
<block wx:for="{{ listData }}" wx:key="index">
<!-- 广告 -->
<image wx:if="{{ item.type == 'adv' }}" class="pinterest-list-item" mode="widthFix" src="{{ item.image }}" bindtap="handleSwiper" data-id="{{ item.id }}" data-url="{{ item.url }}"></image>
<view class="pinterest-list flexflex" wx:if="{{ envVersionState && false }}">
<!-- 广告 -->
<image class="pinterest-list-item" mode="widthFix" src="https://axure-file.lanhuapp.com/md516b251fb-9cfa-46fc-a9b6-2a41a7b4dc37__3e8c7ffd967c39e01538667fc12558ab.svg"></image>
<!-- 公寓 -->
<view class="pinterest-list-item apartment" wx:if="{{ false }}">
<view class="apartment-top flexcenter">
<image class="apartment-icon" mode="widthFix" src="/img/apartment-icon.png"></image>
<image class="apartment-text" mode="widthFix" src="/img/apartment-text.png"></image>
<!-- 公寓 -->
<view wx:elif="{{ item.type == 'apartment' }}" class="pinterest-list-item apartment">
<view class="apartment-top flexcenter">
<image class="apartment-icon" mode="widthFix" src="/img/apartment-icon.png"></image>
<image class="apartment-text" mode="widthFix" src="/img/apartment-text.png"></image>
</view>
<image class="apartment-img" mode="widthFix" src="{{ item.image }}"></image>
<view class="apartment-name">{{ item.title }}</view>
<view class="apartment-introduce">{{ item.propaganda }}</view>
<view class="apartment-price">
<block wx:for="{{ item.specifications }}" wx:for-item="it" wx:key="index">
<view wx:if="{{ index < 2 }}" class="apartment-price-item flexacenter">
<view class="apartment-price-name">{{ it.title }}</view>
<view class="apartment-price-cost flex1 flexacenter">
<view class="apartment-price-unit">HK$</view>
<view class="apartment-price-number">{{ it.value }}</view>
/月
</view>
</view>
</block>
</view>
<view wx:if="{{ item.specifications.length > 2 }}" class="apartment-price-more flexcenter">更多</view>
</view>
<image class="apartment-img" mode="widthFix" src="https://oss.gter.net/Zvt57TuJSUvkyhw-xG7Y2l-R-JIscHrqqsgFptxhXa6SWi2uePJ5Bg8cFLPIvsEG-4BUA27F7lfn5E55tXAL34gR30LsULxzarqa1zx17l80NDI5"></image>
<view class="apartment-name">iRent油麻地二期公寓</view>
<view class="apartment-introduce">年轻有活力且超有玩趣的公寓</view>
<view class="apartment-price">
<view class="apartment-price-item flexacenter" wx:for="{{ 2 }}" wx:key="index">
<view class="apartment-price-name">单人套间</view>
<view class="apartment-price-cost flex1 flexacenter">
<view class="apartment-price-unit">HK$</view>
<view class="apartment-price-number">7200</view>
/月
</view>
<!-- 普通 -->
<view wx:else class="pinterest-list-item general">
<view class="top-right-corner flexcenter" wx:if="{{ item.gptype }}">{{ item.gptype }}</view>
<image class="general-img" mode="widthFix" src="{{ item.image }}"></image>
<view class="general-name" wx:if="{{ item.title }}">
<view class="general-tag flexcenter" wx:if="{{ item.leaseterm }}">{{ item.leaseterm }}</view>
{{ item.title }}
</view>
<view class="label-list flexacenter">
<view class="label-item" wx:if="{{ item.housingtype }}">{{ item.housingtype }}</view>
<view class="label-item" wx:if="{{ item.gender }}">{{ item.gender }}</view>
<view class="label-item" wx:if="{{ item.leaseterm }}">{{ item.leaseterm }}</view>
</view>
<view class="general-cost flex1 flexacenter">
<view class="general-unit">HK$</view>
<view class="general-number">{{ item.rent }}</view>
/月
</view>
</view>
<view class="apartment-price-more flexcenter">更多</view>
</view>
<!-- 普通 -->
<view class="pinterest-list-item general">
<image class="general-img" mode="widthFix" src="https://oss.gter.net/Zvt57TuJSUvkyhw-xG7Y2l-T950rd3bqqsgFptxhXa6SWi2uePJ5Bg8VFrPIvsEG-4BUCm7F7lfn5E5jtX0K_tdQgQ_5bap6c_Ca1y466joQa7aoNKTjEaE0NDI5"></image>
<view class="general-name">
<view class="general-tag flexcenter">整租</view>
大学附近 | 中城浸教公大理公 两房一厅,设备齐全拎包入住
</view>
</block>
<view class="label-list flexacenter">
<view class="label-item">房间</view>
</view>
</view>
<view wx:for="{{ 3 }}" wx:key="index" class="pinterest-list-item apartment">2323</view>
</view>
<!-- 个人房源 -->
@ -294,6 +275,7 @@
</view>
</scroll-view>
</view>
<!-- 世界各地房源 -->
<view wx:if="{{ otherHousing.length>0 }}" class="house-block world-block">
<navigator url="/pages/restOfWorld/restOfWorld" hover-class="hover" class="title">
@ -341,7 +323,6 @@
<!-- 服务号推广 -->
<image mode='widthFix' show-menu-by-longpress class="popularize" src="{{ service }}" bindtap="copy"></image>
<!-- <image mode='widthFix' show-menu-by-longpress class="popularize" src="../../img/1.jpg" bindtap="copy"></image> -->
<fix-footer unreadMessages="{{ unreadMessages }}" bottomLift="{{ bottomLift }}"></fix-footer>
<view class='video-box' wx:if="{{ video }}">
@ -354,5 +335,47 @@
</video>
</view>
<!-- 区域找房的 弹窗 -->
<page-container show="{{ areaPopState }}" z-index="{{ 1001 }}">
<view class="area-pop-header" style="height: {{ screen_data.totalTopHeight }}px;">
<view style="height:{{screen_data.statusBarHeight}}px"></view>
<view class="flexacenter" style="height:{{screen_data.titleBarHeight}}px">
<view class="area-pop-header-left flexacenter flex1" bindtap="openAreaPop">
<image mode="widthFix" class="" src="/img/back.png"></image>
</view>
<view class="area-pop-header-title">区域找房</view>
<view class=" flex1"></view>
</view>
</view>
<view class="area-pop-content flexflex" style="top: {{ screen_data.totalTopHeight }}px;">
<view class="flexflex flex1">
<view class="area-pop-content-left">
<view class="area-pop-content-left-item flexcenter {{ index == areaPopId ? 'pitch' : '' }}" wx:for="{{ getLocationList }}" wx:key="index" bindtap="areaPopItemUnlimited" data-areaPopId="{{ index }}">{{ item.name }}</view>
</view>
<view class="area-pop-content-right flex1">
<view class="area-pop-content-right-item flexacenter" bindtap="areaPopItemUnlimited">
<view class="area-pop-content-right-name">不限</view>
<view class="area-pop-content-right-operate-unlimited-pitch" wx:if="{{ areaPopList.length == 0 }}"></view>
<view class="area-pop-content-right-operate-unlimited" wx:else></view>
</view>
<view class="area-pop-content-right-item flexacenter" wx:for="{{ getLocationList[areaPopId].data }}" wx:key="index" bindtap="areaPopItem" data-key="{{ item.key }}" data-index="{{ index }}">
<view class="area-pop-content-right-name">{{ item.name }}</view>
<image class="area-pop-content-right-operate operate-pitch" wx:if="{{ item.pitch }}" src="/img/green-block-pitch.svg"></image>
<view class="area-pop-content-right-operate" wx:else></view>
</view>
</view>
</view>
<view class="area-pop-bottom flexacenter">
<view class="area-pop-reset-btn flexcenter" bindtap="areaPopItemUnlimited">
<image class="" src="/img/reset.svg"></image>
重置
</view>
<view class="area-pop-confirm-btn flex1 flexcenter" bindtap="handleAreaPopConfirm">确定</view>
</view>
</view>
</page-container>
<announcement-popup interface="home" init="{{ initState }}"></announcement-popup>
</view>

View File

@ -1,6 +1,7 @@
/* pages/pageIndex/pageIndex.wxss */
.container {
background: #fafafa;
/* background: #fafafa; */
background: rgba(246, 246, 246, 1);
min-height: 100vh;
padding-bottom: 160rpx;
}
@ -36,7 +37,8 @@
align-items: center;
font-size: 22rpx;
color: #333;
padding: 0 30rpx 10rpx;
/* padding: 0 30rpx 10rpx; */
padding: 0 52.5rpx 10rpx;
}
.types-tab .item {
@ -52,14 +54,25 @@
display: inline-flex;
align-items: center;
justify-content: center;
width: 110rpx;
height: 110rpx;
border-radius: 30rpx;
/* width: 110rpx;
height: 110rpx; */
width: 84rpx;
height: 84rpx;
/* border-radius: 30rpx; */
border-radius: 24rpx;
background-color: rgb(255, 255, 255);
box-shadow: 0.629px 0.777px 16px 0px rgba(243, 243, 243, 0.996);
/* box-shadow: 0.629px 0.777px 16px 0px rgba(243, 243, 243, 0.996); */
box-shadow: 0px 0px 12rpx rgba(0, 0, 0, 0.0784313725490196);
}
.types-tab .item:nth-child(1) image {
.types-tab .item image {
width: 48rpx;
height: 45rpx;
}
/* .types-tab .item:nth-child(1) image {
width: 62rpx;
height: 58rpx;
}
@ -77,7 +90,7 @@
.types-tab .item:nth-child(4) image {
width: 60rpx;
height: 60rpx;
}
} */
.addhousingresource-icon {
display: flex;
@ -269,7 +282,7 @@
.area-selection {
width: 690rpx;
border-radius: 24rpx;
margin: 0 auto;
margin: 22rpx auto 0;
overflow: hidden;
filter: drop-shadow(0 0 12rpx rgba(0, 0, 0, 0.0784313725490196));
}
@ -290,6 +303,12 @@
height: 100%;
flex-direction: column;
margin-bottom: 18rpx;
align-items: center;
padding-top: 30rpx;
}
.area-selection .head .head-item .head-name {
line-height: 48rpx;
}
.area-selection .head .pitch {
@ -308,7 +327,7 @@
-webkit-box-shadow: 0 -12rpx 12rpx rgba(0, 0, 0, 0.0784313725490196);
box-shadow: 0 -12rpx 12rpx rgba(0, 0, 0, 0.0784313725490196) */
box-shadow: 0 -6rpx 12rpx rgba(0, 0, 0, 0.0784313725490196);
padding-top: 20rpx;
}
.area-selection .head .pitch::after,
@ -466,6 +485,7 @@
.area-pop-header .area-pop-header-left {
padding-left: 30rpx;
height: 100%;
}
.area-pop-header .area-pop-header-left image {
@ -517,6 +537,20 @@
}
.area-pop-content-right .area-pop-content-right-operate-unlimited-pitch {
width: 30rpx;
height: 30rpx;
border-radius: 50%;
background-color: #b1d8ff;
}
.area-pop-content-right .area-pop-content-right-operate-unlimited {
width: 30rpx;
height: 30rpx;
border-radius: 50%;
border: 1rpx solid rgba(170, 170, 170, 1);
}
.area-pop-content-right .area-pop-content-right-operate {
width: 27rpx;
height: 27rpx;
@ -524,6 +558,10 @@
border: 1rpx solid rgba(170, 170, 170, 1);
}
.area-pop-content-right .area-pop-content-right-operate.operate-pitch {
border: none;
}
.area-pop-bottom {
font-size: 36rpx;
padding: 36rpx 30rpx 54rpx;
@ -556,7 +594,9 @@
font-size: 650;
}
.apartment-block {}
.apartment-block {
margin-top: 37.5rpx;
}
.apartment-block .apartment-list {
padding: 0 30rpx;
@ -583,20 +623,12 @@
color: #000000;
font-size: 24rpx;
width: 264rpx;
word-break: keep-all;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.apartment-block .apartment-list .apartment-introduce {
color: #7f7f7f;
font-size: 21rpx;
width: 264rpx;
word-break: keep-all;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
margin-bottom: 8rpx;
}
@ -615,7 +647,7 @@
font-size: 25.5rpx;
font-weight: 400;
padding: 0 30rpx;
margin-top: 30rpx;
margin-top: 54rpx;
z-index: 1;
position: relative;
}
@ -665,7 +697,7 @@
}
.pinterest-list {
padding: 0 30rpx;
padding: 30rpx;
justify-content: space-between;
flex-wrap: wrap;
}
@ -675,6 +707,8 @@
background-color: #fff;
border-radius: 24rpx 24rpx 14rpx 24rpx;
margin-bottom: 18rpx;
position: relative;
box-shadow: 0px 0px 12rpx rgba(0, 0, 0, 0.0784313725490196);
}
.pinterest-list .pinterest-list-item.apartment {
@ -734,6 +768,7 @@
.pinterest-list .pinterest-list-item.apartment .apartment-price-name {
color: #000000;
font-size: 22.5rpx;
width: 120rpx;
}
.pinterest-list .pinterest-list-item.apartment .apartment-price-cost {
@ -762,7 +797,21 @@
height: 36rpx;
}
.pinterest-list .pinterest-list-item.general {}
.pinterest-list .pinterest-list-item.general {
padding-bottom: 36rpx;
}
.pinterest-list .pinterest-list-item.general .top-right-corner {
height: 36rpx;
padding: 0 10rpx;
font-size: 21rpx;
border-radius: 8rpx;
position: absolute;
top: 15rpx;
right: 15rpx;
background-color: rgba(51, 51, 51, 0.56078431372549);
color: #fff;
}
.pinterest-list .pinterest-list-item.general .general-img {
width: 337.5rpx;
@ -786,11 +835,56 @@
color: #555555;
display: inline-flex;
margin-right: 15rpx;
padding: 0 15rpx;
}
.pinterest-list .pinterest-list-item.general .label-list {
font-size: 23rpx;
color: #aaaaaa;
padding: 0 15rpx;
line-height: 40rpx;
margin-top: 15rpx;
}
.pinterest-list .pinterest-list-item.general .label-list .label-item:not(:last-of-type) {
padding-right: 43rpx;
position: relative;
}
.pinterest-list .pinterest-list-item.general .label-list .label-item:not(:last-of-type)::after {
width: 5rpx;
height: 5rpx;
border-radius: 50%;
content: "";
display: block;
position: absolute;
top: 18.5rpx;
right: 20rpx;
background-color: #aaaaaa;
}
.pinterest-list .pinterest-list-item.general .general-cost {
font-size: 21rpx;
color: #555555;
padding: 0 15rpx;
margin-top: 15rpx;
}
.pinterest-list .pinterest-list-item.general .general-cost .general-unit {
font-weight: 900;
color: #000000;
}
.pinterest-list .pinterest-list-item.general .general-cost .general-number {
font-size: 30rpx;
color: #F95D5D;
font-weight: 900;
margin: 0 10rpx;
}
.headSwiper {
width: 690rpx;
margin: 0 auto 30rpx;
margin: 32rpx auto 30rpx;
position: relative;
}
@ -832,7 +926,7 @@
height: 72rpx;
border-radius: 345rpx;
border: 1rpx solid rgba(235, 235, 235, 1);
margin: 0 auto 32rpx;
margin: 0 auto;
background-color: #fff;
}
@ -845,4 +939,8 @@
.search-box .search-input {
height: 100%;
}
}
.waterfall-item {
width: 300rpx;
}

View File

@ -144,16 +144,18 @@ Page({
miucms.html2wxml(str, index, this)
},
onLoad: function (options) {
console.log("0", options);
wx.showLoading({
title: '加载中',
})
let that = this;
var location = [];
if (options.location) {
location = options.location.split(',')
}
if (options.location) location = options.location.split(',')
that.data.location.value = location;
that.data.school.value = options.school || '';
that.data.types.value = options.types || '';
that.data.moreCondition.data.gender = options.gender || '0';
that.data.moreCondition.data.leaseterm = options.leaseterm || '0';
that.data.moreCondition.data.publish = options.publish || 'twomonth';
@ -163,9 +165,10 @@ Page({
options: options || {},
location: that.data.location,
school: that.data.school,
types: that.data.types,
moreCondition: that.data.moreCondition,
// topTitle: app.globalData.topTitle
})
console.log("school", this.data.school);
this.getTopTitle()
setTimeout(function () {
that.get_config()
@ -178,6 +181,8 @@ Page({
},
get_config() {
var that = this;
if (app.globalData.config && app.globalData.config.lists) {
config = app.globalData.config;
@ -251,10 +256,8 @@ Page({
var title = this.data.topTitle + '-个人房源';
if (this.data.location.value.length > 0) {
location = this.data.location.value.join(',');
// title = '寄托港校租房-' + this.data.location.data[Math.floor(this.data.location.value[0]) + ''] + '个人房源';
title = this.data.topTitle + '-' + this.data.location.data[Math.floor(this.data.location.value[0]) + ''] + '个人房源';
} else if (this.data.school.value) {
// title = '寄托港校租房-' + this.data.school.list[this.data.school.value + ''] + '附近个人房源';
title = this.data.topTitle + '-' + this.data.school.list[this.data.school.value + ''] + '附近个人房源';
}
let path = `/pages/personList/personList?school=${this.data.school.value}&location=${location}`;
@ -363,6 +366,7 @@ Page({
break;
}
} else {
console.log(groupSearch[i].where[j], "j", j);
if (groupSearch[i].where[j] != that.data[j].value) {
ishere = false;
break;
@ -694,7 +698,6 @@ Page({
school,
location
} = e.detail;
console.log(school, location, "00");
this.data.school.value = school;
this.data.location.value = location;
this.setData({

View File

@ -3,7 +3,6 @@
<view class="container" wx:if="{{ !isloding }}">
<to-top wx:if="{{ showTOTOP }}"></to-top>
<!-- <header-nav haveSearch="true">寄托港校租房</header-nav> -->
<header-nav haveSearch="true">{{ topTitle }}</header-nav>
<head-swiper attachment="{{ attachment }}"></head-swiper>

View File

@ -4,9 +4,9 @@ Component({
* 组件的属性列表
*/
properties: {
StudentapartmentNew:Boolean,
page:String,
listTab:Object
StudentapartmentNew: Boolean,
page: String,
listTab: Object
},
/**
@ -20,13 +20,24 @@ Component({
* 组件的方法列表
*/
methods: {
toPage(e){
toPage(e) {
let page = e.currentTarget.dataset.page;
if(this.properties.page===page){return false}
if (this.properties.page === page) {
return false
}
wx.redirectTo({
url: `/pages/${page}/${page}`,
})
}
},
// 跳转中介房源
toIntermediaryPage() {
wx.navigateTo({
url: '/pages/quarantineLists/quarantineLists',
})
},
}
})
})

View File

@ -1,13 +1,16 @@
<view class='irent-tab-box tab-box'>
<view class="{{ page=='personList'? 'tab active' :'tab'}}" data-page="personList" bindtap="toPage">
<view class="text">个人房源</view>
</view>
<view class="{{ page=='quarantineLists'? 'tab active' :'tab'}}" wx:if="{{ listTab.quarantineLists }}" data-page="quarantineLists" bindtap="toPage">
<view class="text">{{ listTab.quarantineLists }}</view>
</view>
<view class="{{ page=='irentList'? 'tab active' :'tab'}}" data-page="irentList" bindtap="toPage">
<view class="text">学生公寓</view>
<image src="/img/new.png" wx:if="{{ StudentapartmentNew }}" class='new'></image>
</view>
</view>
<view class="{{ page=='personList'? 'tab active' :'tab'}}" data-page="personList" bindtap="toPage">
<view class="text">个人房源</view>
</view>
<!-- <view class="{{ page=='quarantineLists'? 'tab active' :'tab'}}" wx:if="{{ listTab.quarantineLists }}" data-page="quarantineLists" bindtap="toPage">
<view class="text">{{ listTab.quarantineLists }}</view>
</view> -->
<view class="{{ page=='quarantineLists'? 'tab active' :'tab'}}" bindtap="toIntermediaryPage">
<view class="text">{{ '中介房源' }}</view>
</view>
<view class="{{ page=='irentList'? 'tab active' :'tab'}}" data-page="irentList" bindtap="toPage">
<view class="text">学生公寓</view>
<image src="/img/new.png" wx:if="{{ StudentapartmentNew }}" class='new'></image>
</view>
</view>