Commit a88fe0c4 authored by xishifeng's avatar xishifeng

业绩暂存

parent c5cd504b
...@@ -17,10 +17,20 @@ ...@@ -17,10 +17,20 @@
<div class="achieve-header-tab"> <div class="achieve-header-tab">
<a href="javascript:;" v-for="(item,index) in tabsMain" :class="{active:index == initTabNumMain}" @click="tabMain(index)">{{item.title}}</a> <a href="javascript:;" v-for="(item,index) in tabsMain" :class="{active:index == initTabNumMain}" @click="tabMain(index)">{{item.title}}</a>
</div> </div>
<div class="mulu_relate" href="javascript:;"><span id="list_name">全部</span><img src="/app/images/all_ic.png"></div> <div class="mulu_relate_new" v-show="showHouseArr" @click.prevent.stop="mask('show')"><span id="list_name">{{tabsMain[1].houseDataInit}}</span><img src="/app/images/all_ic.png"></div>
</header> </header>
<div class="header_seat"></div> <div class="header_seat"></div>
<div id="mask_list_select_new" v-show="showMaskFlag" @click.prevent.stop="mask('hide')">
<div class="pop_box">
<div class="tri_angle2"></div>
<ul id="house_list_area">
<li data-id="">全部</li>
<li v-for="(item, index) in tabsMain[1].houseData" :data-id="item.houses_id" @click="getHouse(item)">{{item.internal_title}}</li>
</ul>
</div>
</div>
<div class="achieve-content-ac"> <div class="achieve-content-ac">
<div class="search-area"> <div class="search-area">
......
...@@ -61,7 +61,8 @@ header+.header_seat { ...@@ -61,7 +61,8 @@ header+.header_seat {
} }
/******************************************顶部的全部选择部分******************************************/ /******************************************顶部的全部选择部分******************************************/
header .mulu_relate{ header .mulu_relate,
header .mulu_relate_new{
position: absolute; position: absolute;
top: 0; top: 0;
bottom: 0; bottom: 0;
...@@ -74,7 +75,11 @@ header .mulu_relate{ ...@@ -74,7 +75,11 @@ header .mulu_relate{
cursor: pointer; cursor: pointer;
display: none; display: none;
} }
.mulu_relate>span{ header .mulu_relate_new{
display: block;
}
.mulu_relate>span,
.mulu_relate_new>span{
float: left; float: left;
height: 100%; height: 100%;
width: 2rem; width: 2rem;
...@@ -83,10 +88,12 @@ header .mulu_relate{ ...@@ -83,10 +88,12 @@ header .mulu_relate{
white-space: nowrap; white-space: nowrap;
text-align: right; text-align: right;
} }
.dz-achieve-header>.mulu_relate>span{ .dz-achieve-header>.mulu_relate>span,
.dz-achieve-header>.mulu_relate_new>span{
width: 1.4rem; width: 1.4rem;
} }
.mulu_relate>img{ .mulu_relate>img,
.mulu_relate_new>img{
float: left; float: left;
width: 0.4rem; width: 0.4rem;
padding-top: 0.31rem; padding-top: 0.31rem;
...@@ -105,6 +112,16 @@ header .mulu_relate{ ...@@ -105,6 +112,16 @@ header .mulu_relate{
cursor: pointer; cursor: pointer;
display: none; display: none;
} }
#mask_list_select_new{
position: fixed;
z-index: 101;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-color: rgba(0,0,0,.2);
cursor: pointer;
}
div.pop_box { div.pop_box {
position: absolute; position: absolute;
right: 0.25rem; right: 0.25rem;
......
...@@ -56,11 +56,14 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -56,11 +56,14 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
'num': 5, 'num': 5,
'isLoadSub': false, 'isLoadSub': false,
'dataList': [] 'dataList': []
}] }],
'houseData': [],
'houseDataInit': '全部'
}], }],
initTabNumMain: 0, initTabNumMain: 0,
userId: '', userId: '',
ywyId: getUrlParam('ywyId') ywyId: getUrlParam('ywyId'),
showMaskFlag: false
}, },
created: function() { created: function() {
var _this = this; var _this = this;
...@@ -78,10 +81,29 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -78,10 +81,29 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
}); });
}, },
tabMain: function(index) { tabMain: function(index) {
this.initTabNumMain = index; var _this = this;
_this.initTabNumMain = index;
if(!_this.tabsMain[index].isLoadMain){
_this.ajaxMainNum();
}
}, },
tabSub: function(index, index2) { tabSub: function(index, index2) {
var _this = this;
Vue.set(vm.tabsMain[index], 'initTabNumSub', index2); Vue.set(vm.tabsMain[index], 'initTabNumSub', index2);
if(!_this.tabsMain[index].data[index2].isLoadSub){
Vue.set(vm.tabsMain[index].data[index2], 'isLoadSub', true);
_this.ajaxUl();
}else{
console.log(_this.tabsMain[index].data[index2].isLoadSub);
};
},
mask: function(str){
this.showMaskFlag = (str == 'show')?true:false;
},
getHouse: function(obj){
var _this = this;
Vue.set(vm.tabsMain[1], 'houseDataInit', obj.internal_title);
}, },
initTime: function(callback) { initTime: function(callback) {
//获取缓存里的时间 //获取缓存里的时间
...@@ -111,10 +133,15 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -111,10 +133,15 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
type: 'GET', type: 'GET',
url: ServerHostTempC + '/broker/agentPerformanceBySearch', url: ServerHostTempC + '/broker/agentPerformanceBySearch',
data: { data: {
'start_time': _this.startDate, // 'start_time': _this.startDate,
'end_time': _this.endDate, // 'end_time': _this.endDate,
'agent_id': _this.ywyId, // 'agent_id': _this.ywyId,
'is_case': _tabMainNum // 'is_case': _tabMainNum
'start_time': '2018-03-23',
'end_time': '2018-03-23',
'agent_id': 1,
'is_case': _tabMainNum+1,
'house_id': 0
}, },
timeout: 30000, timeout: 30000,
dataType: 'json', dataType: 'json',
...@@ -122,7 +149,14 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -122,7 +149,14 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
success: function(_data) { success: function(_data) {
if(typeof _data === 'object') { if(typeof _data === 'object') {
if(_data['code'] == '200') { if(_data['code'] == '200') {
if(!_this.tabsMain[_tabMainNum].isLoadMain && _tabMainNum == 1){
Vue.set(vm.tabsMain[1], 'houseData', _data.data.house_arr);
};
Vue.set(vm.tabsMain[_tabMainNum], 'isLoadMain', true); Vue.set(vm.tabsMain[_tabMainNum], 'isLoadMain', true);
Vue.set(vm.tabsMain[_tabMainNum].data[0], 'num', _data.data.look_at_num == null?0:_data.data.look_at_num);
Vue.set(vm.tabsMain[_tabMainNum].data[1], 'num', _data.data.march_in_num == null?0:_data.data.march_in_num);
Vue.set(vm.tabsMain[_tabMainNum].data[2], 'num', _data.data.paylog == null?0:_data.data.paylog);
Vue.set(vm.tabsMain[_tabMainNum].data[3], 'num', _data.data.bargain_sum == null?0:_data.data.bargain_sum);
} else { } else {
layerTipsX(_data['msg']); layerTipsX(_data['msg']);
} }
...@@ -141,9 +175,7 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -141,9 +175,7 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
} }
}); });
}, },
ajaxUl: function(startdate, enddate, status, page, fn) { ajaxUl: function() {
status = Number(status); //强制转换为数字类型,避免出错
$.ajax({ $.ajax({
type: 'POST', type: 'POST',
url: ServerHostTempC + '/broker/orderNoList', url: ServerHostTempC + '/broker/orderNoList',
...@@ -152,7 +184,7 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -152,7 +184,7 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
'start_time ': vm.startDate, 'start_time ': vm.startDate,
'end_time': vm.endDate, 'end_time': vm.endDate,
'is_case': _this.initTabNumMain, 'is_case': _this.initTabNumMain,
'type': 1 'type': _tabMainNum + 1
}, },
timeout: 30000, timeout: 30000,
dataType: 'json', dataType: 'json',
...@@ -251,6 +283,11 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu ...@@ -251,6 +283,11 @@ require(['vue', 'css!style/achieve_tonglian_ac.css', 'jquery0325', 'common'], fu
} }
}); });
} }
},
computed: {
showHouseArr: function(){
return this.initTabNumMain == 1 && this.tabsMain[1].houseData.length > 0;
}
} }
}); });
}); });
\ No newline at end of file
require(['vue', 'css!style/customerinfo_sub_page.css', 'css!style/customer_gj.css', 'jquery0325', 'common'], function(Vue) { require(['vue', 'vconsole', 'css!style/customerinfo_sub_page.css', 'css!style/customer_gj.css', 'jquery0325', 'common'], function(Vue, VConsole) {
//var vConsole = new VConsole(); var vConsole = new VConsole();
var _applyId = getUrlParam("applyid"); //获取GET参数 var _applyId = getUrlParam("applyid"); //获取GET参数
var _token = getUrlParam("token"); var _token = getUrlParam("token");
Vue.component('imgshow-component', { Vue.component('imgshow-component', {
......
...@@ -45,7 +45,7 @@ $(function() { ...@@ -45,7 +45,7 @@ $(function() {
//一些信息自动填写 //一些信息自动填写
$('#area_chengnuoshu').html('承诺书(' + _weekly_data['startdate'] + '至' + _weekly_data['enddate'] + ')'); $('#area_chengnuoshu').html('承诺书(' + _weekly_data['startdate'] + '至' + _weekly_data['enddate'] + ')');
$('#mdzj_div_header_username').html(localStorage.getItem('realname')); $('#mdzj_div_header_username').html(localStorage.getItem('username'));
var _dayNum = parseInt(_weekly_data['enddate'].split('-')[2]); var _dayNum = parseInt(_weekly_data['enddate'].split('-')[2]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment