Merge branch 'YOUFANGAPP1.1' of 192.168.0.27:dev0/youfang-app into YOUFANGAPP1.1

This commit is contained in:
zongzhimin
2018-04-13 18:24:36 +08:00
7 changed files with 86 additions and 232 deletions
+2 -185
View File
@@ -275,21 +275,15 @@ function loadKLineData(city, region, name){
counts.push(datas[d][4]);
}
// if(haveCount){
option01.xAxis[0].data = times
option01.xAxis[1].data = times
//option01.series[0].data = counts
option01.series[0].data = trends
curOption = option01;
var myChart01 = echarts.init(document.getElementById('chart01'));
myChart01.setOption(option01,true);
// }else{
// option02.xAxis[0].data = times
// option02.xAxis[1].data = times
// option02.series[0].data = trends
// curOption = option02;
// myChart01.setOption(option02,true);
// }
}
}).catch(function (error) {
alert(error)
@@ -519,183 +513,6 @@ var option01 = {
}
}]
};
/*var option02 = {
animation: false,
color: colorList,
title: {
text: null,
left: 'center'
},
legend: {
show: false,
top: 30,
data: ['均价']
},
tooltip: {
triggerOn: 'none',
transitionDuration: 0,
confine: true,
bordeRadius: 4,
borderWidth: 1,
borderColor: '#333',
backgroundColor: 'rgba(255,255,255,0.9)',
textStyle: {
fontSize: 12,
color: '#333'
},
formatter: function (params) {
var res = params[0].seriesName + ' ' + params[0].name;
res += '<br/> 月初 : ' + params[0].value[1]
res += '<br/> 月末 : ' + params[0].value[2];
res += '<br/> 最低 : ' + params[0].value[3];
res += '<br/> 最高 : ' + params[0].value[4];
return res;
},
position: function (pos, params, el, elRect, size) {
var obj = {
top: 60
};
obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 5;
return obj;
}
},
axisPointer: {
link: [{
xAxisIndex: [0, 1]
}]
},
dataZoom: [{
type: 'slider',
xAxisIndex: [0, 1],
realtime: false,
start: 50,
end: 100,
top: 65,
height: 20,
handleIcon: 'M10.7,11.9H9.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z',
handleSize: '120%'
}, {
type: 'inside',
xAxisIndex: [0, 1],
start: 40,
end: 70,
top: 30,
height: 20
}],
xAxis: [{
type: 'category',
data: dates,
boundaryGap : false,
axisLine: { lineStyle: { color: '#999' } },
axisLabel: {
formatter: function (value) {
return echarts.format.formatTime('yy-MM', value);
}
},
min: 'dataMin',
max: 'dataMax',
axisPointer: {
show: true
}
}, {
type: 'category',
gridIndex: 1,
data: dates,
scale: true,
boundaryGap : false,
splitLine: {show: false},
axisLabel: {show: false},
axisTick: {show: false},
axisLine: { lineStyle: { color: '#fff' } },
splitNumber: 20,
min: 'dataMin',
max: 'dataMax',
axisPointer: {
type: 'shadow',
label: {show: false},
triggerTooltip: true,
handle: {
show: true,
margin: 30,
color: '#B80C00'
}
}
}],
yAxis: [{
name: '均价(元/㎡)',
nameRotate: 90,
nameLocation: 'center',
nameGap: 5,
position: 'right',
nameTextStyle: {
color: '#999'
},
scale: true,
splitNumber: 2,
axisLine: { lineStyle: { color: '#999' } },
splitLine: { show: true },
axisTick: { show: false },
axisLabel: {
inside: true,
formatter: '{value}\n'
}
}, {
name: '成交量(套)',
nameRotate: 90,
nameLocation: 'center',
nameGap: 5,
position: 'right',
nameTextStyle: {
color: '#999'
},
scale: true,
gridIndex: 1,
splitNumber: 2,
axisLabel: {show: false},
axisLine: {show: false},
axisTick: {show: false},
splitLine: {show: false}
}],
grid: [{
left: 20,
right: 20,
top: 110,
height: 120
}, {
left: 20,
right: 20,
height: 40,
top: 260
}],
graphic: [{
type: 'group',
left: 'center',
top: 70,
width: 300,
bounding: 'raw'
}],
series: [ {
type: 'candlestick',
name: '均价',
data: data,
itemStyle: {
normal: {
color: '#ff4500',
color0: '#22ac38',
borderColor: '#ff4500',
borderColor0: '#22ac38'
},
emphasis: {
color: 'black',
color0: '#444',
borderColor: 'black',
borderColor0: '#444'
}
}
}]
};
*/
$("#trendDiv2 a").click(function(){
+56 -33
View File
@@ -252,7 +252,60 @@ $.config = {router: false}
var address;
var tags;
var baseInfo = new Vue({
var baseInfo;
</script>
<script type="text/javascript" src="../../js/district/districtDetail.js"></script>
<script type='text/javascript' src='../../js/district/district-map.js' charset='utf-8'></script>
<script type='text/javascript' src='../component/baseInfoComponent.js' charset='utf-8'></script>
<script type='text/javascript' src='../component/nearDist.js' charset='utf-8'></script>
<script>
//loadDistrictInfo();
document.addEventListener('plusready', onPlusReady, false);
function onPlusReady() {
var self = plus.webview.currentWebview();
city = self.city
region = self.region
name = self.name;
// 创建根实例
baseInfo = new Vue({
el: '#districtBaseInfo',
data: {
name : "",
city:"",
region: "",
address: "",
avgPrice:"",
oneMonthUpDownRange:"",
priceRate:"",
cityPrice:"",
finishBuildingDate:"",
householdCount:"",
cubagePercent:"",
carSiteCount:"",
virescencePercent:"",
estateCharge:"",
moreArea:"",
developer:"",
estateCompany:"",
tags:[],
nearDists:[],
regionIndex:"",
schoolIndex:""
}
})
/* 小区均价分析 */
loadKLineData(city, region, name);
/* 小区租金走势 */
loadRentTrends(city, region, name);
}
/*baseInfo = new Vue({
el: '#districtBaseInfo',
data: {
name : "",
@@ -278,34 +331,7 @@ $.config = {router: false}
schoolIndex:""
}
})
var myChart01 = echarts.init(document.getElementById('chart01'));
</script>
<script type="text/javascript" src="../../js/district/districtDetail.js"></script>
<script type='text/javascript' src='../../js/district/district-map.js' charset='utf-8'></script>
<script type='text/javascript' src='../component/baseInfoComponent.js' charset='utf-8'></script>
<script type='text/javascript' src='../component/nearDist.js' charset='utf-8'></script>
<script>
//loadDistrictInfo();
document.addEventListener('plusready', onPlusReady, false);
function onPlusReady() {
var self = plus.webview.currentWebview();
city = self.city
region = self.region
name = self.name;
// loadDistrictInfo();
// 创建根实例
new Vue({
el: '#baseInfo'
})
}
//new Vue({
// el: '#baseInfo'
// })
// })
})*/
function openMapWindow(){
clicked('arround.html',true,false,{},{city:city,region:region,name:name,lat:lat,lng:lng});
@@ -335,10 +361,7 @@ function loadMap(){
window.clearInterval(t1);
}
}
/* 小区均价分析 */
loadKLineData(city, region, name);
/* 小区租金走势 */
loadRentTrends(city, region, name);
</script>
@@ -240,13 +240,13 @@ function constructHtmlContent(results, xqOneMonthUpDownRangeMap, cityAvgPriceMap
var cityAvgPriceValue = cityAvgPriceMap[cityAvgPriceKey];
if(!isNaN(cityAvgPriceValue)){
if(parseInt(cityAvgPriceValue)>=parseInt(result.price)){
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='up'>高"+(parseInt(cityAvgPriceValue)-parseInt(result.price))+"元</em></div>";
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='down'>低"+(parseInt(cityAvgPriceValue)-parseInt(result.price))+"元</em></div>";
}else{
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='down'>低"+(parseInt(result.price)-parseInt(cityAvgPriceValue))+"元</em></div>";
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='up'>高"+(parseInt(result.price)-parseInt(cityAvgPriceValue))+"元</em></div>";
}
}else{
//为非数字清空放空格
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='down'>"+' '+"</em></div>";
htmlContent = htmlContent + "<div>相比"+result.city+"均价: <em class='down'>暂无</em></div>";
}
htmlContent = htmlContent + "<div>均价: <em class='em02'>"+result.price+"元/㎡</em></div>";
htmlContent = htmlContent + "<div class='price'><em><strong>"+tempTotalPrice+"</strong>万</em></div>";
+15 -10
View File
@@ -35,6 +35,13 @@
<div class="page-group">
<div class="page page-current" id="districtBaseInfo">
<div class="loadingBg">
<div class="infinite-scroll-preloader">
<div class="preloader"></div>
</div>
</div>
<header class="bar bar-nav barBorder">
<button class="button button-link button-nav pull-left" onclick="back(),plus.nativeUI.closeWaiting();">
<span class="icon icon-left"></span>
@@ -130,6 +137,14 @@
</div>
</div>
<div class="content contentSuggest dn" id="noDataDiv">
<div class="noData">
<img src="../../images/noData.png">
<p>您的小区数据目前仍在更新<br>敬请期待</p>
</div>
</div>
</div>
</div>
@@ -190,20 +205,10 @@ function onPlusReady() {
city = self.city
region = self.region
name = self.name;
// loadDistrictInfo();
// 创建根实例
new Vue({
el: '#baseInfo'
})
//new Vue({
// el: '#nearDistDiv'
//})
//new Vue({
// el: '#mapDiv'
//})
}
//new Vue({
+1
View File
@@ -109,6 +109,7 @@ function logout() {
//退出登录之前loading下个人中心
plus.webview.getWebviewById('views/house/houseManageList.html').reload();
plus.webview.getWebviewById('views/user/userInfo.html').reload();
plus.webview.getWebviewById('yfindex.html').reload();
timer.start();
}
+5 -1
View File
@@ -111,7 +111,11 @@ new Vue({
},
// 修改密码
updatePass: function() {
if (this.pass == '' || this.pass.length < 7) {
if (this.pass == '') {
$.toast("请输入密码");
return;
}
if (this.pass.length < 7) {
$.toast("请输入6位以上数字或字母");
return;
}
+4
View File
@@ -292,6 +292,8 @@ function checkIsLogin(){
//跳转登录方法, 考虑回调
function gotoLogin(){
clicked('/views/user/codeSms.html',true,false,{},{},function(){
plus.webview.getWebviewById('views/house/houseManageList.html').reload();
plus.webview.getWebviewById('yfindex.html').reload();
checkIsLogin();
})
}
@@ -305,10 +307,12 @@ function gotoUpdatePass(){
function gotoLoanApply(houseId, city){
clicked('/views/loan/loanInfo.html',true,false,{},{houseId: houseId, city: city, mobile: _mobile},function(){})
}
//跳转到小区详情
function gotoDistrictDetail(city,region,name){
clicked('/views/district/detail.html',true,false,{},{city:city,region:region,name:name},function(){})
}
//跳转房产详情
function gotoHouseDetail(id){
clicked('/views/house/detail.html',true,false,{},{houseId:id},function(){