人力排名提交

This commit is contained in:
na.guo
2020-08-04 15:44:26 +08:00
parent 1cc4b6215d
commit 5b963d81a9
12 changed files with 1133 additions and 707 deletions

View File

@@ -7,6 +7,8 @@ const GroupOffice = () => import('@/views/ebiz/institutionalPerform/GroupOffice'
const PersonalOffice = () => import('@/views/ebiz/institutionalPerform/PersonalOffice')
const ServiceDepartOffice = () => import('@/views/ebiz/institutionalPerform/ServiceDepartOffice')
const RegionalOffice = () => import('@/views/ebiz/institutionalPerform/RegionalOffice')
const InstitutionalManpower = () => import('@/views/ebiz/institutionalPerform/InstitutionalManpower')
export default [
// 分公司
{
@@ -87,5 +89,15 @@ export default [
title: '机构业绩',
index: 1
}
},
{
//活动人力
path: '/institutionalPerform/institutionalManpower',
name: 'InstitutionalManpower',
component: InstitutionalManpower,
meta: {
title: '机构业绩',
index: 1
}
}
]

View File

@@ -6,10 +6,10 @@
</template>-->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs>-->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -33,12 +33,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -66,13 +61,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -131,7 +120,7 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
@@ -171,7 +160,7 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal: '',
shitimeVal: ''
}
},
methods: {
@@ -190,9 +179,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -224,8 +215,8 @@ export default {
query: {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText,
},
showText: this.showText
}
})
},
//修改月、天的格式,保持两位数显示
@@ -330,7 +321,7 @@ export default {
queryType: this.dateType,
date: this.dateVal,
//01保费排行 02人力排行
type: this.curMainType,
type: this.curMainType
}
// 去除对象里面是空的属性
for (var key in data) {
@@ -339,7 +330,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -364,8 +355,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -377,11 +368,11 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
@@ -390,7 +381,7 @@ export default {
this.timeVal = this.$route.query.timeVal || ''
this.showText = this.$route.query.showText
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">

View File

@@ -6,10 +6,10 @@
</template> -->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -128,12 +117,12 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
//01保费排行 02人力排行
curMainType:"01",
curMainType: '01',
YearColumns: ['2020', '2019'],
minDate: new Date(2019, 0, 1),
maxDate: new Date(2020, 10, 1),
@@ -168,7 +157,7 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:"",
shitimeVal: '',
showText: true
}
},
@@ -188,9 +177,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -223,7 +214,7 @@ export default {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText
},
}
})
},
//修改月、天的格式,保持两位数显示
@@ -266,7 +257,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
if (this.curTab == 1) {
// now当前 y:年 m:月 d:日
// 日
@@ -288,10 +279,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -317,19 +305,19 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: this.$route.query.manageCode,
manageLv: "04",
manageLv: '04',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
//01保费排行 02人力排行
type: this.curMainType,
type: this.curMainType
}
// 去除对象里面是空的属性
for (var key in data) {
@@ -338,7 +326,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -363,8 +351,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -376,22 +364,21 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
mounted() {
setInterval(this.getCurrentDate(), 1000 * 60)
this.getlComPremDetil()
this.timeVal=this.$route.query.timeVal||""
this.timeVal = this.$route.query.timeVal || ''
console.log(this.timeVal)
this.showText = this.$route.query.showText
},
}
}
</script>
<style lang="scss">
@@ -458,7 +445,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;

View File

@@ -6,10 +6,10 @@
</template> -->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -128,11 +117,11 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
curMainType:"01",
curMainType: '01',
showText: true,
YearColumns: ['2020', '2019'],
minDate: new Date(2019, 0, 1),
@@ -168,7 +157,7 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:""
shitimeVal: ''
}
},
methods: {
@@ -187,9 +176,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -222,7 +213,7 @@ export default {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText
},
}
})
},
//修改月、天的格式,保持两位数显示
@@ -265,7 +256,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
console.log(this.curTab)
console.log(value)
if (this.curTab == 1) {
@@ -289,10 +280,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -318,19 +306,19 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: this.$route.query.manageCode,
manageLv: "07",
manageLv: '07',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
//01保费排行 02人力排行
type: this.curMainType,
type: this.curMainType
}
// 去除对象里面是空的属性
for (var key in data) {
@@ -339,7 +327,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -364,8 +352,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -377,20 +365,20 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
mounted() {
setInterval(this.getCurrentDate(), 1000 * 60)
this.timeVal=this.$route.query.timeVal||""
this.timeVal = this.$route.query.timeVal || ''
this.showText = this.$route.query.showText
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">
@@ -457,7 +445,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;

View File

@@ -0,0 +1,115 @@
<template>
<div class="p10 pl40 pr40">
<van-row>
<van-col span="3">
<img :src="require('@/assets/images/ebiz/calendar.png')" />
</van-col>
<van-col class="fs14 mp2" span="9" @click="showMonthPicker = true">{{ timeVal }}</van-col>
<van-col span="3">
<img style="margin-top: 2px;" :src="require('@/assets/images/ebiz/point.png')" />
</van-col>
<van-col span="9">
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- -->
<van-popup v-model="showMonthPicker" position="bottom">
<van-datetime-picker
v-model="currentMonthDate"
type="year-month"
:min-date="minDate"
:max-date="maxDate"
:formatter="formatter"
@confirm="onConfirmDate"
@cancel="showMonthPicker = false"
/>
</van-popup>
</van-row>
</div>
</template>
<script>
let newArr = []
import Vue from 'vue'
import util from '@/views/ebiz/institutionalPerform/InstitutionalManpower/components/js/util'
export default {
data() {
return {
timeVal: '',
sortTypeText: '活动人力',
showPicker: false,
minDate: new Date(2019, 0, 1),
maxDate: new Date(2020, 10, 1),
currentMonthDate: new Date(),
showMonthPicker: false
}
},
components: {},
name: 'Selectors',
props: {
queryColumns: {
type: Array,
default: ''
}
},
created() {
this.getTimeVal()
},
methods: {
formatter(type, val) {
if (type === 'year') {
return `${val}`
} else if (type === 'month') {
return `${val}`
}
return val
},
//修改月、天的格式,保持两位数显示
add0(m) {
return m < 10 ? '0' + m : m
},
dateFormat(time) {
// 时间格式化 2019-09-08
let year = time.getFullYear()
let month = time.getMonth() + 1
let day = util.getLastDay(year, time.getMonth())
return year + '-' + this.add0(month) + '-' + this.add0(day)
},
onConfirm(value, index) {
this.sortTypeText = value
// switch (value) {
// case this.queryColumns[0]:
// this.sortType = '1'
// break
// case this.queryColumns[1]:
// this.sortType = '2'
// break
// case this.queryColumns[2]:
// this.sortType = '3'
// break
// case this.queryColumns[3]:
// this.sortType = '4'
// break
// }
this.$emit('getSortType', index + 1)
this.showPicker = false
},
getTimeVal() {
this.dateVal = this.dateFormat(this.currentMonthDate)
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 7)
},
onConfirmDate(value, index) {
// 月
this.getTimeVal()
this.$emit('getDateVal', this.dateVal)
this.showMonthPicker = false
}
}
}
</script>
<style lang="scss" scoped></style>

View File

@@ -0,0 +1,15 @@
export default {
add0(m) {
return m < 10 ? '0' + m : m
},
getLastDay(y, m) {
y = y || new Date().getFullYear()
m = m || new Date().getMonth()
return new Date(y, m + 1, 0).getDate()
},
getMonthLastDay(y, m) {
y = y || new Date().getFullYear()
m = m || new Date().getMonth()
return y + '-' + this.add0(m + 1) + '-' + new Date(y, m + 1, 0).getDate()
}
}

View File

@@ -0,0 +1,8 @@
.van-row {
line-height: 1.6rem;
}
.van-tabs__nav--card .van-tab {
&:last-child {
border-right: none !important;
}
}

View File

@@ -0,0 +1,344 @@
<template>
<div v-cloak class="container">
<!-- <van-nav-bar left-text="机构业绩" left-arrow @click-left="onBack">
<template #right>
<img @click="getlComPremDetil" :src="refreshLogo" />
</template> -->
</van-nav-bar>
<!-- 业绩和人力 -->
<van-tabs @click="onClickMain" v-model="active" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs>
<Selectors @getDateVal="getDateVal" @getSortType="getSortType" :queryColumns="queryColumns"></Selectors>
<div class="layer-box">
<div class="layer">
<table class="fs14" style="table-layout:fixed">
<tr class="title">
<th class="td-1" style="height: 1.3em;">排名</th>
<th class="td-2">机构</th>
<th>{{ queryColumns[0] }}</th>
<th>{{ queryColumns[1] }}</th>
<th>{{ queryColumns[2] }}</th>
<!-- <th>{{ queryColumns[3] }}</th> -->
<th>{{ queryColumns[3] }}</th>
<th v-if="manageLv != '07'">操作</th>
</tr>
<tr >
<td class="td-1 white" style="width:3em;height: 1.3em;">1</td>
<td class="td-2">合计</td>
<td>{{ items[0] }}</td>
<td>{{ items[1] }}</td>
<td>{{ items[2] }}</td>
<td>{{ items[3] }}</td>
</tr>
<tr v-for="(item, index) in tableData" :key="index">
<td class="td-1">{{ index + 1 }}</td>
<td >
<div style="width:10em">{{ item.name }}</div>
</td>
<td>{{ item.hdrl }}</td>
<td>{{ item.hgrl }}</td>
<td>{{ item.ggrl }}</td>
<td>{{ item.xzrl }}</td>
<td v-if="manageLv != '07'">
<span @click="toDetail(item.code)" class="red1">查看</span>
</td>
</tr>
</table>
</div>
</div>
</div>
</template>
<script>
// import { XTable } from 'vux'
import Selectors from '@/views/ebiz/institutionalPerform/InstitutionalManpower/components/Selectors'
import util from '@/views/ebiz/institutionalPerform/InstitutionalManpower/components/js/util'
import { branchOfficeApi } from '@/api/ebiz/branchOffice/branchOffice'
import refreshLogo from '@/assets/images/ebiz/refresh.png'
import { Tabs, Tab } from 'vant'
export default {
name: 'districtOffice',
components: {
Selectors,
[Tabs.name]: Tabs,
[Tab.name]: Tab
},
data() {
return {
sortType: '1',
manageCode: '',
manageLv: '',
tableData: [],
items: [],
bzbfTotol: 0,
queryColumns: ['活动人力', '合格人力', '桂冠人力', '新增人力'],
refreshLogo,
active: 1,
// 当前的机构编码
curCode: '',
dateType: 'm',
dateVal: '',
curTab: '',
shitimeVal: '',
curMainType: '02'
}
},
watch: {
tableData(value) {
if (value.length == 0) {
this.queryColumns.forEach(() => {
this.items.push('0.00')
})
} else {
let sum1 = 0
let sum2 = 0
let sum3 = 0
let sum4 = 0
this.tableData.forEach(item => {
sum1 = Number(sum1) + Number(item.hdrl)
sum2 = Number(sum2) + Number(item.hgrl)
sum3 = Number(sum3) + Number(item.ggrl)
sum4 = Number(sum4) + Number(item.xzrl)
this.items = [sum1, sum2, sum3, sum4]
})
this.items = this.items.map(item => {
return item.toFixed(2)
})
}
}
},
methods: {
formatterYear(type, val) {
if (type === 'year') {
return val + '年'
}
return val
},
onClickMain(name) {
if (name == 0) {
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/UnderOffice'
})
} else {
this.curMainType = '01'
}
this.getlComPremDetil()
},
toDetail(manageCode) {
if (!this.manageLv) this.manageLv = 1
this.manageLv = '0' + (Number(this.manageLv) + 1)
this.manageCode = manageCode
this.getlComPremDetil()
document.querySelector('.layer').scrollTo(0, 0);//重置滚动条
},
getCurrentDate() {
var timeStr = ''
var curDate = new Date()
var curMonth = curDate.getMonth() + 1 //获取当前月份(0-11,0代表1月)
var curDay = curDate.getDate() //获取当前日(1-31)
var curHour = curDate.getHours() //获取当前小时数(0-23)
var curMinute = curDate.getMinutes() // 获取当前分钟数(0-59)
var curSec = curDate.getSeconds() //获取当前秒数(0-59)
if (curHour < 10) {
if (curMinute < 10) {
timeStr += ' 0' + curHour + ':0' + curMinute
} else {
timeStr += ' 0' + curHour + ':' + curMinute
}
} else {
if (curMinute < 10) {
timeStr += ' ' + curHour + ':0' + curMinute
} else {
timeStr += ' ' + curHour + ':' + curMinute
}
}
// 一直在获取时间
this.shitimeVal = this.add0(curMonth) + '-' + this.add0(curDay) + timeStr
// 存页面上值得一个变量
this.timeVal = this.shitimeVal
},
onBack() {
this.$router.go(-1)
},
getSortType(value) {
console.log(value, 'value')
this.sortType = value
this.getlComPremDetil()
},
getDateVal(value) {
this.dateVal = value
this.getlComPremDetil()
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageLv: this.manageLv,
manageCode: this.manageCode,
sortType: this.sortType,
date: '2020-07-31', //this.dateVal
type: this.curMainType
}
// 去除对象里面是空的属性
for (var key in data) {
if (data[key] === '') {
delete data[key]
}
}
branchOfficeApi(data)
.then(res => {
if (res.result == 0) {
//console.log(res.content.list)
$this.tableData = res.content.listRL
}
})
.catch(err => {})
}
},
created() {
if (process.env.NODE_ENV != 'development') {
setTimeout(() => {
// eslint-disable-next-line no-undef
EWebBridge.webCallAppInJs('webview_right_button', {
btns: [
{
img: this.$assetsUrl + 'images/ebiz/refresh.png',
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
}
},
mounted() {
// this.timeVal=this.$route.query.timeVal||""
// this.showText=this.$route.query.showText
// this.getCurrentDate()
// setInterval(this.getCurrentDate, 1000 * 60)
this.dateVal = util.getMonthLastDay()
this.getlComPremDetil()
}
}
</script>
<style lang="scss">
@import '@/assets/sass/variables.scss';
.container {
.oneTab .van-tabs__nav--card .van-tab {
background-color: #fff;
border-right: 1px solid #fff;
}
.van-tabs__nav--card .van-tab.van-tab--active {
color: $red1;
background-color: #fff;
}
.van-tabs__nav--card .van-tab {
color: #232020;
background-color: #e6e6e6;
border-right: 1px solid #8e8d8d;
}
.van-nav-bar .van-icon,
.van-nav-bar__text {
color: #232020;
}
.slide-box {
display: -webkit-box;
overflow-x: scroll;
-webkit-overflow-scrolling: touch;
}
table.gridtable {
font-family: verdana, arial, sans-serif;
font-size: 11px;
color: #333333;
border-width: 1px;
border-color: #666666;
border-collapse: collapse;
}
table .title th {
padding: 5px 10px;
}
table td {
text-align: center;
padding: 5px 10px;
}
table .title th {
color: #fff;
padding: 5px 10px;
white-space: nowrap;
border-width: 1px;
border-color: #666666;
background-color: $red1;
border-top: 0;
border-left: 0;
border-right: 0;
}
table {
border: 0;
}
.title .van-tabs__nav--card {
margin: 0;
border: 1px solid #bdbdbd;
border-left: none;
border-right: none;
}
.title .van-tabs__nav--card .van-tab {
background-color: transparent;
}
// 固定表头
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;
line-height: 30px; */
/* box-sizing: border-box; */
background: #fff;
}
.layer-box {
width: 100%;
overflow: hidden;
position: relative;
}
.layer {
width: 100%;
overflow: hidden;
overflow-x: scroll;
}
.td-1 {
/* position: absolute; */
padding: 2.13333vw;
left: 0;
z-index: 2;
width: 3em;
height: 2.5em;
}
}
</style>

View File

@@ -6,10 +6,10 @@
</template> -->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -124,7 +113,7 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
@@ -163,8 +152,8 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:"",
curMainType:"01"
shitimeVal: '',
curMainType: '01'
}
},
methods: {
@@ -183,9 +172,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -252,7 +243,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
if (this.curTab == 1) {
// now当前 y:年 m:月 d:日
// 日
@@ -274,10 +265,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -303,19 +291,19 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: this.$route.query.manageCode,
manageLv: "08",
manageLv: '08',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
//01保费排行 02人力排行
type: this.curMainType,
type: this.curMainType
}
// 去除对象里面是空的属性
for (var key in data) {
@@ -324,7 +312,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -349,8 +337,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -362,20 +350,20 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
mounted() {
setInterval(this.getCurrentDate(), 1000 * 60)
this.timeVal=this.$route.query.timeVal||""
this.timeVal = this.$route.query.timeVal || ''
this.showText = this.$route.query.showText
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">
@@ -442,7 +430,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;

View File

@@ -6,10 +6,10 @@
</template> -->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -128,11 +117,11 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
curMainType:"01",
curMainType: '01',
showText: true,
YearColumns: ['2020', '2019'],
minDate: new Date(2019, 0, 1),
@@ -168,7 +157,7 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:""
shitimeVal: ''
}
},
methods: {
@@ -187,9 +176,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -222,7 +213,7 @@ export default {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText
},
}
})
},
//修改月、天的格式,保持两位数显示
@@ -265,7 +256,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
console.log(this.curTab)
console.log(value)
if (this.curTab == 1) {
@@ -289,10 +280,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -318,14 +306,14 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: this.$route.query.manageCode,
manageLv: "05",
manageLv: '05',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
@@ -339,7 +327,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -364,8 +352,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -377,20 +365,20 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
mounted() {
setInterval(this.getCurrentDate(), 1000 * 60)
this.timeVal=this.$route.query.timeVal||""
this.timeVal = this.$route.query.timeVal || ''
this.showText = this.$route.query.showText
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">
@@ -457,7 +445,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;

View File

@@ -6,10 +6,10 @@
</template> -->
<!-- </van-nav-bar> -->
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -128,11 +117,11 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
curMainType:"01",
curMainType: '01',
showText: true,
YearColumns: ['2020', '2019'],
minDate: new Date(2019, 0, 1),
@@ -168,7 +157,7 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:""
shitimeVal: ''
}
},
methods: {
@@ -187,9 +176,11 @@ export default {
return val
},
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -222,7 +213,7 @@ export default {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText
},
}
})
},
//修改月、天的格式,保持两位数显示
@@ -265,7 +256,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
if (this.curTab == 1) {
// now当前 y:年 m:月 d:日
// 日
@@ -287,10 +278,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -316,14 +304,14 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: this.$route.query.manageCode,
manageLv: "03",
manageLv: '03',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
@@ -337,7 +325,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -362,8 +350,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -375,20 +363,20 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
mounted() {
setInterval(this.getCurrentDate(), 1000 * 60)
this.timeVal=this.$route.query.timeVal||""
this.timeVal = this.$route.query.timeVal || ''
this.showText = this.$route.query.showText
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">
@@ -455,7 +443,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;

View File

@@ -1,15 +1,15 @@
<template>
<div v-cloak class="under-office-container">
<!-- <van-nav-bar left-text="机构业绩" left-arrow @click-left="onBack"> -->
<!-- <template #right>
<van-nav-bar left-text="机构业绩" left-arrow @click-left="onBack">
<template #right>
<img @click="getlComPremDetil" :src="refreshLogo" />
</template> -->
<!-- </van-nav-bar> -->
</template>
</van-nav-bar>
<!-- 业绩和人力 -->
<!-- <van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tabs @click="onClickMain" type="card" class="p0 title">
<van-tab title="机构业绩排名"></van-tab>
<van-tab title="机构人力排名"></van-tab>
</van-tabs> -->
</van-tabs>
<!-- 年月日选择 -->
<van-tabs @click="onClickRabs" type="card" class="pl20 pr20 pt10 pb10 bg-red">
<van-tab title="实时"></van-tab>
@@ -30,12 +30,7 @@
<span class="fs14" @click="showPicker = true">{{ sortTypeText }}</span>
</van-col>
<van-popup v-model="showPicker" position="bottom">
<van-picker
show-toolbar
:columns="queryColumns"
@confirm="onConfirm"
@cancel="showPicker = false"
/>
<van-picker show-toolbar :columns="queryColumns" @confirm="onConfirm" @cancel="showPicker = false" />
</van-popup>
<!-- 时间选择器 -->
<!-- -->
@@ -63,13 +58,7 @@
</van-popup>
<!-- -->
<van-popup v-model="showYearPicker" position="bottom">
<van-picker
v-model="currentYearDate"
show-toolbar
:columns="YearColumns"
@confirm="onConfirmDate"
@cancel="showYearPicker = false"
/>
<van-picker v-model="currentYearDate" show-toolbar :columns="YearColumns" @confirm="onConfirmDate" @cancel="showYearPicker = false" />
</van-popup>
<!-- /时间选择器 -->
</van-row>
@@ -88,7 +77,7 @@
<th>操作</th>
</tr>
<tr>
<th class="td-1 white" style="width:4.3em">1</th>
<th class="td-1 white" style="width:3em">1</th>
<th class="td-2">合计</th>
<th>{{ ysbbTotal.toFixed(2) }}</th>
<th>{{ bzbfTotol.toFixed(2) }}</th>
@@ -128,7 +117,7 @@ export default {
components: {
// XTable,
[Tabs.name]: Tabs,
[Tab.name]: Tab,
[Tab.name]: Tab
},
data() {
return {
@@ -167,8 +156,8 @@ export default {
dateType: 'now',
dateVal: '',
curTab: '',
shitimeVal:"",
curMainType:"01"
shitimeVal: '',
curMainType: '01'
}
},
methods: {
@@ -189,7 +178,10 @@ export default {
onClickMain(name) {
console.log(name)
if (name == 1) {
this.curMainType = '02'
//this.curMainType = '02'
this.$router.push({
path: '/institutionalPerform/InstitutionalManpower'
})
} else {
this.curMainType = '01'
}
@@ -217,12 +209,12 @@ export default {
},
toDetail(manageCode) {
this.$router.push({
path: '/institutionalPerform/serviceDepartOffice',
path: '/institutionalPerform/UnderOffice',
query: {
manageCode: manageCode,
timeVal: this.timeVal,
showText: this.showText
},
}
})
},
//修改月、天的格式,保持两位数显示
@@ -265,7 +257,7 @@ export default {
},
onConfirmDate(value, index) {
// 点击确定那么文字“截至”就隐藏
this.showText=false;
this.showText = false
if (this.curTab == 1) {
// now当前 y:年 m:月 d:日
// 日
@@ -287,10 +279,7 @@ export default {
// 左侧时间实时赋值
this.timeVal = this.dateVal.substring(0, 4)
}
this.showDatePicker=false,
this.showMonthPicker=false,
this.showYearPicker= false,
this.getlComPremDetil()
;(this.showDatePicker = false), (this.showMonthPicker = false), (this.showYearPicker = false), this.getlComPremDetil()
},
onConfirm(value, index) {
this.sortTypeText = value
@@ -316,14 +305,14 @@ export default {
this.getlComPremDetil()
},
onBack() {
this.$router.go(-1);
this.$router.go(-1)
},
//获取列表
getlComPremDetil() {
let $this = this
let data = {
manageCode: "8645",
manageLv: "02",
manageCode: '8645',
manageLv: '02',
sortType: this.sortType,
queryType: this.dateType,
date: this.dateVal,
@@ -337,7 +326,7 @@ export default {
}
}
branchOfficeApi(data)
.then((res) => {
.then(res => {
if (res.result == 0) {
console.log(res.content.list)
$this.tableData = res.content.list
@@ -362,8 +351,8 @@ export default {
console.log($this.tableData)
}
})
.catch((err) => {})
},
.catch(err => {})
}
},
created() {
setTimeout(() => {
@@ -375,11 +364,11 @@ export default {
route: {
flag: '',
extra: {
url: location.origin + '/#/institutionalPerform/BranchOffice',
},
},
},
],
url: location.origin + '/#/institutionalPerform/BranchOffice'
}
}
}
]
})
}, 1000)
},
@@ -390,11 +379,14 @@ export default {
this.getCurrentDate()
setInterval(this.getCurrentDate, 1000 * 60)
this.getlComPremDetil()
},
}
}
</script>
<style lang="scss">
.under-office-container {
.van-row {
line-height: 1.6rem;
}
.oneTab .van-tabs__nav--card .van-tab {
background-color: #fff;
border-right: 1px solid #fff;
@@ -407,6 +399,9 @@ export default {
color: #232020;
background-color: #e6e6e6;
border-right: 1px solid #8e8d8d;
&:last-child {
border-right: none !important;
}
}
.van-nav-bar .van-icon,
.van-nav-bar__text {
@@ -461,7 +456,8 @@ export default {
background-color: transparent;
}
// 固定表头
td,th{
td,
th {
/* color: #333;
font-size: 14px;
border-right: 1px solid #333;
@@ -481,6 +477,7 @@ export default {
}
.td-1 {
position: absolute;
padding: 2.13333vw;
left: 0;
z-index: 2;
width: 3em;