jinx 4 anni fa
parent
commit
f74e383af4

+ 42 - 34
apps/RealtorEasier/app.js

@@ -8,7 +8,9 @@ import {
 
 import ImApi from './apis/im'
 import AppIMDelegate from "./delegate/app-im-delegate";
-import { fotmatDate } from './utils/date'
+import {
+  fotmatDate
+} from './utils/date'
 
 var QQMapWX = require('/utils/qqmap-wx-jssdk.min.js')
 var timer = null
@@ -38,11 +40,11 @@ App({
       }))
     }
     wx.getSystemInfo({
-      success (res) {
+      success(res) {
         console.log(res, '系统信息')
       }
     })
-    
+
   },
   /**
    * 当小程序启动,或从后台进入前台显示,会触发 onShow
@@ -105,37 +107,39 @@ App({
   getIMHandler() {
     return this.appIMDelegate.getIMHandlerDelegate();
   },
-  async getNewMessage (msg) {
-    const { conversations } = this.globalData
+  async getNewMessage(msg) {
+    const {
+      conversations
+    } = this.globalData
     let item = conversations.find(item => item.id === msg.fromId)
     if (item) {
-        item.latestMsgContent = msg.content
-        item.latestMsgTime = msg.sendTime
-        item.unReadNum ? item.unReadNum++ : item.unReadNum = 1
-        this.globalData.conversations = this.dealConversations(conversations)
+      item.latestMsgContent = msg.content
+      item.latestMsgTime = msg.sendTime
+      item.unReadNum ? item.unReadNum++ : item.unReadNum = 1
+      this.globalData.conversations = this.dealConversations(conversations)
     } else {
-        await this.getContact()
+      await this.getContact()
     }
-},
-getContact(isNewMsg) {
-  return ImApi.getContacts().then(res => {
-    const friends = res.data.friends
-    const {
-      conversations
-    } = this.globalData
-    this.globalData.unViewMsg = 0
-    this.globalData.conversations = this.dealConversations(friends.map(item => {
-      const con = conversations.find(con => con.id === item.id)
-      if (con) {
-        item = Object.assign(con, item)
-      } else if (isNewMsg){
-        item.unReadNum = 1
-      }
-      this.globalData.unViewMsg += item.unReadNum
-      return item
-    }))
-  })
-},
+  },
+  getContact(isNewMsg) {
+    return ImApi.getContacts().then(res => {
+      const friends = res.data.friends
+      const {
+        conversations
+      } = this.globalData
+      this.globalData.unViewMsg = 0
+      this.globalData.conversations = this.dealConversations(friends.map(item => {
+        const con = conversations.find(con => con.id === item.id)
+        if (con) {
+          item = Object.assign(con, item)
+        } else if (isNewMsg) {
+          item.unReadNum = 1
+        }
+        this.globalData.unViewMsg += item.unReadNum
+        return item
+      }))
+    })
+  },
   dealConversations(conversations) {
     return conversations.map(item => {
       let content = item.latestMsgContent
@@ -157,7 +161,7 @@ getContact(isNewMsg) {
       } else {
         item.timeStr = fotmatDate(item.latestMsgTime, 'MM/dd')
       }
-      
+
       return item
     }).sort((a, b) => new Date(b.latestMsgTime) - new Date(a.latestMsgTime))
   },
@@ -165,17 +169,21 @@ getContact(isNewMsg) {
     token: loadToken(),
     raw_city: true,
     // city: '定位中...', // 默认进入首页的地址
-    city: '洛杉矶', // 默认进入首页的地址
+    // city: '洛杉矶', // 默认进入首页的地址
+    // city: '洛杉矶', // 默认进入首页的地址
+    city: 'Los Angeles',
+    // 默认进入首页的地址
+    // cityId: '3392', // 默认进入首页的地址
     // province: '广东省',
     province: '',
     district: '',
     userinfo: loadUserInfo() || {},
-    user_code:loadUserCode() ||'',
+    user_code: loadUserCode() || '',
     io: '',
     messageList: [],
     unViewMsg: 0,
     conversations: [],
     type: 'user',
-    historyCity:loadHistoryCity() ||[],
+    historyCity: loadHistoryCity() || [],
   }
 });

+ 0 - 1
apps/RealtorEasier/app.json

@@ -2,7 +2,6 @@
   "pages": [
 
     "pages/index/index",
-    "pages/room/room",
 
     "pages/detail/detail",
     "pages/contact/contact",

+ 11 - 2
apps/RealtorEasier/components/detail-components/detail-scroll/detail-scroll.wxml

@@ -74,7 +74,7 @@
             <view class="location-item">
                 <text class="location-label">位置:</text>
                 <!-- <text class="location-value">{{ house.city + house.estate_name }}</text> -->
-                <text class="location-value">{{ house.city + house.address }}</text>
+                <text class="location-value">{{house.address + ' ' +house.city   }}</text>
             </view>
             <view class="location-item" wx:if="{{!isAgency}}">
                 <text class="location-label">学校信息:</text>
@@ -130,7 +130,16 @@
         </view>
     </view>
 
-
+  <!-- 免责声明 -->
+  <view class=" padding-container" wx:if="{{house.ancillaryFacility.length>0}}">
+        <view class="location-text-info border-btn">
+            <view class="detail-title m-t-32">免责声明
+            </view>
+            <view class="box" style="background:#eee; padding:20rpx;font-size:28rpx;text-align:justify;color:#666;">
+                平台房源所提供的信息仅供个人非商业用途使用,消费者不得用于其他任何用途。平台房源信息与实际信息可能所有偏差,请购房者在决定购买前,与相关专人人士确认沟通。平台将保留所有解释权。
+            </view>
+        </view>
+    </view>
     <view class="padding-container">
         <view class="detail-title m-t-32">推荐房源({{recommendList.length}})</view>
         <view class="house-list">

+ 1 - 1
apps/RealtorEasier/components/house-item/house-item.wxml

@@ -10,7 +10,7 @@
     <view class="content">
       <view class="houseinfo">
         <!-- <view class="text-black address" >{{ house.district }}/{{ house.address }}</view> -->
-        <view class="text-black address" >{{ house.city }}/{{ house.address }}</view>
+        <view class="text-black address" >{{ house.address }}/{{ house.city }}</view>
       </view>
       <view class="tap-list" >
         <!-- <view class="tap-item" wx:if="{{house.vrLink}}">云看房</view> -->

+ 5 - 2
apps/RealtorEasier/config/config.js

@@ -2,10 +2,13 @@
 
 // export const API_BASE_URL = 'https://vrhouse2.4dkankan.com'
 //以上是最新引用
-export const IM_HOST = 'wss://testusavr.4dkankan.com'
+// export const IM_HOST = 'wss://testusavr.4dkankan.com'
 
-export const API_BASE_URL = 'https://testusavr.4dkankan.com'
+// export const API_BASE_URL = 'https://testusavr.4dkankan.com'
+//美国正式服
+export const IM_HOST = 'wss://meifangli.brokersbus.com'
 
+export const API_BASE_URL = 'https://meifangli.brokersbus.com'
 // 以下是屏蔽内容
 
 

+ 1 - 1
apps/RealtorEasier/pages/about/about.wxml

@@ -10,7 +10,7 @@
     <view class="about-sub-desc">
     
       <view>客服电话:+8618025428379</view>
-      <view>客服邮箱:falconsigns2@yahoo.com   </view>
+      <view>客服邮箱:falcondesign@yahoo.com  </view>
     </view>
     <view class="version">版本号:1.0.2</view>
   </view>

+ 1 - 1
apps/RealtorEasier/pages/city/city.js

@@ -193,7 +193,7 @@ Page({
     if (value) {
 
       // resultTip = this.data.allCitys.filter(item => item.name.indexOf(value) !== -1)
-      resultTip = this.data.all_cities.filter(item => item.cname.indexOf(value) !== -1)
+      resultTip = this.data.all_cities.filter(item => item.name.indexOf(value) !== -1)
     }
     console.log(resultTip)
 

+ 6 - 6
apps/RealtorEasier/pages/city/city.wxml

@@ -3,8 +3,8 @@
 <view class="search-w">
     <input class="search-input" bindinput="searchResult" placeholder="输入城市名称进行搜索"></input>
     <view class="result-tip">
-        <view class="search-input" wx:for="{{resultTip}}" data-city="{{item.cname}}" bindtap="handleCityClick">{{
-            item.cname }}</view>
+        <view class="search-input" wx:for="{{resultTip}}" data-city="{{item.name}}" bindtap="handleCityClick">{{
+            item.name }}</view>
     </view>
 </view>
 
@@ -12,7 +12,7 @@
     <view class="city-label">默认城市</view>
     <view class="search-input" bindtap="selectLocation">
         <text>{{ city }}</text>
-        <view class="refresh-btn " animation="{{animation}}" catchtap="getLocation"></view>
+        <!-- <view class="refresh-btn " animation="{{animation}}" catchtap="getLocation"></view> -->
     </view>
 </view>
 
@@ -52,7 +52,7 @@
             </view>
             <view bindtap="getCities" data-id="{{item.id}}" wx:for="{{states}}"
                 class="states-item  {{state_id==item.id ? ' active':''}}">
-                {{item.cname}}
+                {{item.name}}
             </view>
         </view>
         <view class="city-side">
@@ -66,9 +66,9 @@
                         {{alphabet[item.alphabetIndex]}}</view>
                     <view class="citys-container">
 
-                        <view class="city-item {{city==city_item.cname ? 'active':''}}" data-city="{{city_item.cname}}"
+                        <view class="city-item {{city==city_item.name ? 'active':''}}" data-city="{{city_item.name}}"
                             bindtap="handleCityClick" wx:for="{{item.citys}}" wx:for-item="city_item">
-                            {{city_item.cname}}
+                            {{city_item.name}}
                             <!-- {{apl_index}}
                             {{item.alphabetIndex}}
                             {{apl_index ==item.alphabetIndex}} -->

+ 0 - 1
apps/RealtorEasier/pages/web/web.js

@@ -235,7 +235,6 @@ Page({
       console.log(EVENT)
       if (this.trtcRoomContext) {
         this.publishLocalAudio()
-        console.log('**************')
         console.log(EVENT.LOCAL_JOIN)
         this.trtcRoomContext.on(EVENT.LOCAL_JOIN, (event) => {
           // wx.showToast({

+ 2 - 1
apps/RealtorEasier/utils/socket-handle.js

@@ -42,7 +42,8 @@ export function initSocket(page, options) {
     if (data.persons.length < 2) {
       return
     }
- 
+    console.log('有人来了')
+    console.log(data)
     let user = data.persons.find(item => item.userId === getApp().globalData.userinfo.user_id)
     // page.getSignature(user)
     // console.log(user)

+ 12 - 3
apps/agent/components/detail-components/detail-scroll/detail-scroll.wxml

@@ -29,7 +29,7 @@
             </view>
         </view>
         <view class="house-name ">{{ house.title }}</view>
-        <view class="contact-user">房源负责人:{{ agent_user.name }}<view class="icon-idcard" ></view>
+        <view class="contact-user">房源负责人:{{ agent_user.name }}<view class="icon-idcard"></view>
         </view>
         <view class="house-parameter">
             <view class="parameter-item">
@@ -73,7 +73,7 @@
             <view class="location-item">
                 <text class="location-label">位置:</text>
                 <!-- <text class="location-value">{{ house.city + house.estate_name }}</text> -->
-                <text class="location-value">{{ house.city + house.address }}</text>
+                <text class="location-value">{{ house.address + ' ' + house.city }}</text>
             </view>
             <view class="location-item" wx:if="{{!isAgency}}">
                 <text class="location-label">学校信息:</text>
@@ -129,7 +129,16 @@
         </view>
     </view>
 
-
+    <!-- 免责声明 -->
+    <view class=" padding-container" wx:if="{{house.ancillaryFacility.length>0}}">
+        <view class="location-text-info border-btn">
+            <view class="detail-title m-t-32">免责声明
+            </view>
+            <view class="box" style="background:#eee; padding:20rpx;font-size:28rpx;text-align:justify;color:#666;">
+                平台房源所提供的信息仅供个人非商业用途使用,消费者不得用于其他任何用途。平台房源信息与实际信息可能所有偏差,请购房者在决定购买前,与相关专人人士确认沟通。平台将保留所有解释权。
+            </view>
+        </view>
+    </view>
     <view class="padding-container">
         <view class="detail-title m-t-32">推荐房源({{recommendList.length}})</view>
         <view class="house-list">

+ 1 - 1
apps/agent/components/house-item/house-item.wxml

@@ -10,7 +10,7 @@
     <view class="content">
       <view class="houseinfo">
         <!-- <view class="text-black address" >{{ house.district }}/{{ house.address }}</view> -->
-        <view class="text-black address" >{{ house.city }}/{{ house.address }}</view>
+        <view class="text-black address" >{{ house.address }}/{{ house.city }}</view>
       </view>
       <view class="tap-list" >
         <!-- <view class="tap-item" wx:if="{{house.vrLink}}">云看房</view> -->

+ 6 - 2
apps/agent/config/config.js

@@ -2,9 +2,13 @@
 
 // export const API_BASE_URL = 'https://vrhouse2.4dkankan.com'
 //以上是最新引用
-export const IM_HOST = 'wss://testusavr.4dkankan.com'
+// export const IM_HOST = 'wss://testusavr.4dkankan.com'
 
-export const API_BASE_URL = 'https://testusavr.4dkankan.com'
+// export const API_BASE_URL = 'https://testusavr.4dkankan.com'
+//美国正式服
+export const IM_HOST = 'wss://meifangli.brokersbus.com'
+
+export const API_BASE_URL = 'https://meifangli.brokersbus.com'
 
 // 以下是屏蔽内容
 

+ 2 - 1
apps/agent/pages/add-client/add-client.js

@@ -77,7 +77,8 @@ Page({
     },
     onLoad: function(options) {
         // const { customer_id, agency_user_id } = options
-        const { id } = options
+        const { id } = options 
+
         console.log(options)
         // if (customer_id && agency_user_id) {
             this.fetchCustomerDetail(id)

+ 11 - 11
apps/agent/pages/client-detail/client-detail.js

@@ -31,11 +31,11 @@ Page({
         id:'first_budget',
         val:'首付预算60-80万元'
       },
-      {
-        key:'购房位置',
-        id:'buy_house_address',
-        val:'香洲区-唐家湾镇'
-      },
+      // {
+      //   key:'购房位置',
+      //   id:'buy_house_address',
+      //   val:'香洲区-唐家湾镇'
+      // },
       {
         key:'面积',
         short:true,
@@ -54,12 +54,12 @@ Page({
         id:'purpose',
         val:'刚需'
       },
-      {
-        key:'物业类型',
-        short:true,
-        id:'property_type',
-        val:'待完善'
-      }
+      // {
+      //   key:'物业类型',
+      //   short:true,
+      //   id:'property_type',
+      //   val:'待完善'
+      // }
     ]
   },
 

+ 2 - 1
apps/agent/pages/client/client.wxml

@@ -28,7 +28,8 @@
     </view>
 </view>
 
-<text style="bottom: {{isPhoneX ? '150rpx' : '100rpx'}}" bindtap="toAddClient" class="iconfont iconcus_add hover-icon" selectable="false" ></text>
+<!-- <text style="bottom: {{isPhoneX ? '150rpx' : '100rpx'}}" bindtap="toAddClient" class="iconfont iconcus_add hover-icon" selectable="false" ></text> -->
+<text style="bottom: {{isPhoneX ? '180rpx' : '180rpx'}}" bindtap="toAddClient" class="iconfont iconcus_add hover-icon" selectable="false" ></text>
   
 
 <tab-bar/>

+ 2 - 1
apps/agent/utils/socket-handle.js

@@ -31,7 +31,8 @@ export function initSocket(page, options) {
   })
   
   io.on(eventName.someoneInRoom, function (data) {
-   
+    console.log('有人来了')
+    console.log(data)
     if (data.persons.length < 2) {
       return
     }

+ 1 - 1
apps/agent/utils/tools.js

@@ -28,7 +28,7 @@ export function isPhoneX () {
     wx.getSystemInfo({
       success: res=>{
       let modelmes = res.model;
-        if (modelmes.search('iPhone X') != -1) {
+        if (modelmes.search('iPhone X') != -1 || modelmes.search('iPhone 12') != -1 ) {
           resolve(true)
         }
         resolve(false)