update
This commit is contained in:
parent
14ccd691de
commit
cf0f90515e
@ -6,7 +6,7 @@
|
||||
<header-top :bgUrl="bgUrl" :menu="menu" :bgColor="bgColor" :title="title" :analyseInfo="analyseInfo" :topBg="topBg" :page="page" :backType="backType"
|
||||
:serverpartName="serviceInfo.SERVERPART_NAME" :spregionTypeName="serviceInfo.SPREGIONTYPE_NAME" :serviceInfo="serviceInfo"
|
||||
:topLeftBg="topLeftBg" :topLeftColor="topLeftColor" :iconObj="iconObj" :haveIconObj="haveIconObj" :detailBoxBg="detailBoxBg"
|
||||
:haveFun="haveFun"/>
|
||||
:haveFun="haveFun" :serviceTypeObj="serviceTypeObj" :serviceInfoObj="serviceInfoObj"/>
|
||||
|
||||
<div class="charts">
|
||||
<div class="chartsItem">
|
||||
@ -14,7 +14,7 @@
|
||||
<p class="title">{{month}}月交易分析</p>
|
||||
<div class="time">
|
||||
<div class="select">
|
||||
<picker mode="date" fields="month" :value="single" :end="endData" @change="bindDateChange" >
|
||||
<picker mode="date" fields="month" :value="single" :start="startTime" :end="endData" @change="bindDateChange" >
|
||||
<view class="time">
|
||||
<view class="uni-input" style="background: transparent;padding: 0;height:100%">{{ single }}</view>
|
||||
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/index/arrow_bottom.svg"></image>
|
||||
@ -91,6 +91,7 @@ import BestsellerShop from "./components/bussiness/bestsellerShop.vue";
|
||||
import NoData from "./components/noData.vue";
|
||||
import BandLevel from "./components/format/bandLevel.vue";
|
||||
import commercialType from "./commercialType.vue";
|
||||
import {getFieldEnum} from "../../util/dateTime";
|
||||
|
||||
export default {
|
||||
name: "businessPortrait",
|
||||
@ -138,28 +139,36 @@ export default {
|
||||
},
|
||||
single:'',//显示时间
|
||||
endData:'', // 结束时间
|
||||
startTime:'',// 开始时间
|
||||
month:'',//显示月份
|
||||
haveFun:{}
|
||||
haveFun:{},
|
||||
lastDay:'',
|
||||
serviceTypeObj:{},// 服务区类型对象
|
||||
serviceInfoObj:{}
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
let serviceInfo = JSON.parse(option.serviceInfo)
|
||||
if (option.serviceInfo){
|
||||
this.serviceInfo = JSON.parse(option.serviceInfo)
|
||||
}
|
||||
this.backType = option.type
|
||||
this.serviceInfo = serviceInfo
|
||||
//跳转的时候带上时间
|
||||
this.time = option.time
|
||||
this.endData = new Date()
|
||||
this.endData = uni.getStorageSync('lastDay')
|
||||
this.startTime = '2023-01-01'
|
||||
// 服务区类型枚举
|
||||
this.handleServiceType()
|
||||
},
|
||||
onShow(){
|
||||
let storeTime = uni.getStorageSync('lastDay')
|
||||
if (storeTime){
|
||||
this.time = storeTime
|
||||
this.lastDay = storeTime
|
||||
}
|
||||
this.single = this.$util.getThisMonthHave(this.time)
|
||||
const date = new Date(this.time)
|
||||
let month = date.getMonth() + 1
|
||||
this.month = month<10?'0' + month:month
|
||||
console.log('this.time',this.time)
|
||||
|
||||
let storeServiceInfo = uni.getStorageSync('currentService')
|
||||
if (storeServiceInfo){
|
||||
@ -218,12 +227,24 @@ export default {
|
||||
ServerpartId:this.serviceInfo.Serverpart_ID
|
||||
}
|
||||
const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req)
|
||||
this.serviceInfoObj = total.Result_Data
|
||||
this.haveFun = {
|
||||
car:total.Result_Data.HASPILOTLOUNGE,
|
||||
charge:total.Result_Data.HASCHARGE ,
|
||||
bady:total.Result_Data.HASMOTHER ,
|
||||
gusetHome:total.Result_Data.HASGUESTROOM
|
||||
}
|
||||
},
|
||||
// 枚举服务区类型 SERVERPART_TYPE
|
||||
async handleServiceType(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SERVERPART_TYPE' });
|
||||
console.log('data',data)
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[Number(item.value)] = item.label
|
||||
})
|
||||
console.log('obj',obj)
|
||||
this.serviceTypeObj = obj
|
||||
},
|
||||
bindDateChange(e){
|
||||
const date = new Date(e.detail.value)
|
||||
@ -279,32 +300,52 @@ export default {
|
||||
uni.setStorageSync('currentService',res)
|
||||
},
|
||||
async getTransactionList(){
|
||||
const nowDate = new Date()
|
||||
const selectDate = new Date(this.time)
|
||||
const nowDate = new Date(this.lastDay)
|
||||
const selectDate = new Date(this.single)
|
||||
// 选择日期的年份
|
||||
let selectYear = selectDate.getFullYear()
|
||||
let nowYear = nowDate.getFullYear()
|
||||
let selectMonth = selectDate.getMonth() + 1
|
||||
let nowDateMonth = nowDate.getMonth() + 1
|
||||
let time
|
||||
if (selectMonth === nowDateMonth){
|
||||
let nowYear = nowDate.getFullYear()
|
||||
let m
|
||||
let nowDay = nowDate.getDate() - 1
|
||||
if (nowDateMonth<10){
|
||||
m = '0' + nowDateMonth
|
||||
}
|
||||
if (nowDay<10){
|
||||
nowDay = '0' + nowDay
|
||||
}
|
||||
time = `${nowYear}-${m}-${nowDay}`
|
||||
// 下方逻辑 如果选择的月份 是当前的月份 那就取选择的时间 不然就取那个月的最后一天
|
||||
// 如果同一年
|
||||
if (selectYear===nowYear && selectMonth===nowDateMonth){
|
||||
time = this.lastDay
|
||||
}else{
|
||||
let selectYear = selectDate.getFullYear()
|
||||
let m
|
||||
let haveDay = this.$util.getThisMonthDay(`${selectYear}-${selectMonth}`)
|
||||
if (selectMonth<10){
|
||||
m = '0' + selectMonth
|
||||
selectMonth='0'+selectMonth
|
||||
}
|
||||
let selectDay = this.$util.getThisMonthDay(`${selectYear}-${m}`)
|
||||
time = `${selectYear}-${m}-${selectDay}`
|
||||
time = `${selectYear}-${selectMonth}-${haveDay}`
|
||||
}
|
||||
|
||||
// if (selectYear===nowYear){
|
||||
// if (selectMonth === nowDateMonth){
|
||||
// let nowYear = nowDate.getFullYear()
|
||||
// let m
|
||||
// let nowDay = nowDate.getDate() - 1
|
||||
// if (nowDateMonth<10){
|
||||
// m = '0' + nowDateMonth
|
||||
// }
|
||||
// if (nowDay<10){
|
||||
// nowDay = '0' + nowDay
|
||||
// }
|
||||
// time = `${nowYear}-${m}-${nowDay}`
|
||||
// }else{
|
||||
// let selectYear = selectDate.getFullYear()
|
||||
// let m
|
||||
// if (selectMonth<10){
|
||||
// m = '0' + selectMonth
|
||||
// }
|
||||
// let selectDay = this.$util.getThisMonthDay(`${selectYear}-${m}`)
|
||||
// time = `${selectYear}-${m}-${selectDay}`
|
||||
// }
|
||||
// }else{
|
||||
//
|
||||
// }
|
||||
|
||||
|
||||
|
||||
let req = {
|
||||
Province_Code:'340000',
|
||||
|
||||
@ -20,8 +20,8 @@
|
||||
<div class="seize"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="serviceArea" :style="{top : (menu.bottom + 14) + 'px'}" @click="handleGoSelectService">
|
||||
<div class="picker">
|
||||
<div class="serviceArea" :style="{top : (menu.bottom + 14) + 'px'}" >
|
||||
<div class="picker" @click="handleGoSelectService">
|
||||
<div class="selectService">
|
||||
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/fixed.svg"></image>
|
||||
<view class="select">
|
||||
@ -42,7 +42,7 @@
|
||||
<!-- </div>-->
|
||||
<div class="detailBox">
|
||||
<div class="detailTop">
|
||||
<div class="topLeft">A类</div>
|
||||
<div class="topLeft">{{serviceTypeObj[serviceInfoObj.SERVERPART_TYPE]}}</div>
|
||||
<div class="topRight" @click="handleGoServiceMessage">
|
||||
<span class="rightText">查看更多</span>
|
||||
<img class="moreIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"/>
|
||||
@ -344,6 +344,7 @@ import CommercialType from "./commercialType.vue";
|
||||
import shopCell from "../everdayRenven/components/listUnit.vue";
|
||||
import EntryRate from "./components/car/entryRate.vue";
|
||||
import anhuiYestodayRevenueData from "../everdayRenven/components/anhuiYestodayRevenueData";
|
||||
import {getFieldEnum} from "../../util/dateTime";
|
||||
export default {
|
||||
name: "carPortrait",
|
||||
data(){
|
||||
@ -395,7 +396,9 @@ export default {
|
||||
headMsg:null,
|
||||
searchEndTime:'',
|
||||
searchText:'',// 展示全省情況时显示的日期内容
|
||||
haveFun:{}
|
||||
haveFun:{},
|
||||
serviceTypeObj:{},// 服务区类型对象
|
||||
serviceInfoObj:{}
|
||||
}
|
||||
},
|
||||
components: {
|
||||
@ -410,6 +413,8 @@ export default {
|
||||
onLoad(option){
|
||||
this.isShowAllProvince = option.mustAllProvince
|
||||
this.backType = option.type
|
||||
// 服务区类型枚举
|
||||
this.handleServiceType()
|
||||
},
|
||||
onShow(){
|
||||
this.carTypeList.forEach(item=>{
|
||||
@ -517,6 +522,17 @@ export default {
|
||||
handleGoServiceMessage(){
|
||||
this.$util.toNextRoute('navigateTo', `/pages/map/detail`)
|
||||
},
|
||||
// 枚举服务区类型 SERVERPART_TYPE
|
||||
async handleServiceType(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SERVERPART_TYPE' });
|
||||
console.log('data',data)
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[Number(item.value)] = item.label
|
||||
})
|
||||
console.log('obj',obj)
|
||||
this.serviceTypeObj = obj
|
||||
},
|
||||
showScoreAnimation1(copyRightItems,id) {
|
||||
/*
|
||||
cxt_arc.arc(x, y, r, sAngle, eAngle, counterclockwise);
|
||||
@ -689,6 +705,7 @@ export default {
|
||||
total.Result_Data.RegionInfo.forEach((item,index)=>{
|
||||
tabList.push({name:item.SERVERPART_REGIONNAME,value:index+1})
|
||||
})
|
||||
this.serviceInfoObj = total.Result_Data
|
||||
this.tabList = tabList
|
||||
this.haveFun = {
|
||||
car:total.Result_Data.HASPILOTLOUNGE,
|
||||
|
||||
@ -9,8 +9,8 @@
|
||||
<div class="seize"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="serviceArea" :style="{top : (menu.bottom + 14) + 'px'}" @click="handleGoSelectService">
|
||||
<div class="picker">
|
||||
<div class="serviceArea" :style="{top : (menu.bottom + 14) + 'px'}" >
|
||||
<div class="picker" @click="handleGoSelectService">
|
||||
<div class="selectService">
|
||||
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/fixed.svg"></image>
|
||||
<view class="select">
|
||||
@ -27,7 +27,7 @@
|
||||
|
||||
<div class="detailBox" :style="{background: detailBoxBg}">
|
||||
<div class="detailTop">
|
||||
<div class="topLeft" :style="{background:topLeftBg,color:topLeftColor}">A类</div>
|
||||
<div class="topLeft" :style="{background:topLeftBg,color:topLeftColor}">{{serviceTypeObj[serviceInfoObj.SERVERPART_TYPE]}}</div>
|
||||
<div class="topRight" @click="handleGoServiceMessage">
|
||||
<span class="rightText">查看更多</span>
|
||||
<img class="moreIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"/>
|
||||
@ -155,6 +155,14 @@ export default {
|
||||
bady:false,
|
||||
gusetHome:false
|
||||
}
|
||||
},
|
||||
serviceInfoObj:{
|
||||
type:Object,
|
||||
default:()=>{}
|
||||
},
|
||||
serviceTypeObj:{
|
||||
type:Object,
|
||||
default:()=>{}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
|
||||
@ -112,7 +112,7 @@ export default {
|
||||
this.dataInfo.TotalOffAmount = this.$util.fmoney(this.dataInfo.TotalOffAmount,2)
|
||||
this.dataInfo.TicketCount = this.$util.fmoney(this.dataInfo.TicketCount,2)
|
||||
this.dataInfo.TotalCount = this.$util.fmoney(this.dataInfo.TotalCount,2)
|
||||
this.dataInfo.average = this.$util.fmoney((value.CashPay / value.TicketCount),2)
|
||||
this.dataInfo.average = value.TicketCount? this.$util.fmoney((Number(value.CashPay) / Number(value.TicketCount)),2):'0.00'
|
||||
// this.dataInfo.ContractProfitLoss = this.$util.fmoney(this.dataInfo.ContractProfitLoss)
|
||||
// this.dataInfo.SalesPerSquareMeter = this.$util.fmoney(this.dataInfo.SalesPerSquareMeter)
|
||||
}
|
||||
|
||||
@ -6,15 +6,29 @@
|
||||
<header-top :bgUrl="bgUrl" :menu="menu" :bgColor="bgColor" :title="title" :analyseInfo="analyseInfo" :topBg="topBg" :page="page" :backType="backType"
|
||||
:serverpartName="serviceInfo.SERVERPART_NAME" :spregionTypeName="serviceInfo.SPREGIONTYPE_NAME" :serviceInfo="serviceInfo"
|
||||
:topLeftBg="topLeftBg" :topLeftColor="topLeftColor" :iconObj="iconObj" :haveIconObj="haveIconObj" :detailBoxBg="detailBoxBg"
|
||||
:haveFun="haveFun"/>
|
||||
:haveFun="haveFun" :serviceTypeObj="serviceTypeObj" :serviceInfoObj="serviceInfoObj"/>
|
||||
|
||||
<div class="charts">
|
||||
<div class="chartsItem">
|
||||
<div class="chartsItem" >
|
||||
<p class="title">品牌指数</p>
|
||||
<div >
|
||||
<div class="labelList">
|
||||
<div :class="item[5]?'labelItem labelItemSelect':'labelItem labelItemUnSelect'" v-for="(item,index) in brandLabelList" :key="index" @click="changeLabel(item)">
|
||||
<image class="icon" :src="item[4]"></image>
|
||||
<p class="name">{{item[0]}}<text class="number">({{item[1]}})</text></p>
|
||||
</div>
|
||||
</div>
|
||||
<band-number v-if="brandInfoList.length>0" :data="brandInfoList"/>
|
||||
</div>
|
||||
<no-data v-if="!brandInfoList.length"/>
|
||||
</div>
|
||||
|
||||
<div class="chartsItem" style="margin-top: 32px">
|
||||
<div class="top">
|
||||
<p class="title">{{thisMonth}}月业态充盈度</p>
|
||||
<div class="time">
|
||||
<div class="select">
|
||||
<picker mode="date" fields="month" :value="single" :end="endData" @change="bindDateChange" >
|
||||
<picker mode="date" fields="month" :value="single" :start="startDate" :end="endData" @change="bindDateChange" >
|
||||
<view class="time">
|
||||
<view class="uni-input" style="background: transparent;padding: 0;height:100%">{{ single }}</view>
|
||||
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/index/arrow_bottom.svg"></image>
|
||||
@ -23,7 +37,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="fillDegreeList.result.series[0].data.length>0">
|
||||
<div v-if="fillDegreeList.result && fillDegreeList.result.series[0].data.length>0">
|
||||
<filling-degree :data="fillDegreeList" @handleChangeBandLevel="handleChangeBandLevel" :isClick="isClick"/>
|
||||
<analyse :analyseInfo="{analysisins_type: 1502,analysisins_format: 2000}" />
|
||||
</div>
|
||||
@ -45,19 +59,6 @@
|
||||
<!-- </div>-->
|
||||
<!-- <no-data v-else/>-->
|
||||
<!-- </div>-->
|
||||
<div class="chartsItem" style="margin-top: 32px">
|
||||
<p class="title">品牌指数</p>
|
||||
<div >
|
||||
<div class="labelList">
|
||||
<div :class="item[5]?'labelItem labelItemSelect':'labelItem labelItemUnSelect'" v-for="(item,index) in brandLabelList" :key="index" @click="changeLabel(item)">
|
||||
<image class="icon" :src="item[4]"></image>
|
||||
<p class="name">{{item[0]}}<text class="number">({{item[1]}})</text></p>
|
||||
</div>
|
||||
</div>
|
||||
<band-number v-if="brandInfoList.length>0" :data="brandInfoList"/>
|
||||
</div>
|
||||
<no-data v-if="!brandInfoList.length"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@ -72,6 +73,7 @@ import ConsumptionLevel from "./components/format/consumLevel.vue";
|
||||
import BandNumber from "./components/format/bandNumber.vue";
|
||||
import NoData from "./components/noData.vue";
|
||||
import commercialType from "./commercialType.vue";
|
||||
import {getFieldEnum} from "../../util/dateTime";
|
||||
|
||||
export default {
|
||||
name: "businessPortrait",
|
||||
@ -120,16 +122,25 @@ export default {
|
||||
single:'',//显示时间
|
||||
thisMonth:'',//几月
|
||||
endData:'', // 结束时间
|
||||
haveFun:{}
|
||||
haveFun:{},
|
||||
startDate:'',// 开始时间
|
||||
serviceTypeObj:{},// 服务区类型对象
|
||||
serviceInfoObj:{}
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
let serviceInfo = JSON.parse(option.serviceInfo)
|
||||
if (option){
|
||||
if (option.serviceInfo){
|
||||
this.serviceInfo = JSON.parse(option.serviceInfo)
|
||||
}
|
||||
this.backType = option.type
|
||||
this.serviceInfo = serviceInfo
|
||||
//跳转的时候带上时间
|
||||
this.time = option.time
|
||||
this.endData = new Date()
|
||||
}
|
||||
this.endData = uni.getStorageSync('lastDay')
|
||||
this.startDate = '2023-01-01'
|
||||
// 服务区类型枚举
|
||||
this.handleServiceType()
|
||||
},
|
||||
onShow(){
|
||||
let storeTime = uni.getStorageSync('lastDay')
|
||||
@ -171,35 +182,63 @@ export default {
|
||||
this.$util.addUserBehavior()
|
||||
},
|
||||
methods:{
|
||||
// 枚举服务区类型 SERVERPART_TYPE
|
||||
async handleServiceType(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SERVERPART_TYPE' });
|
||||
console.log('data',data)
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[Number(item.value)] = item.label
|
||||
})
|
||||
console.log('obj',obj)
|
||||
this.serviceTypeObj = obj
|
||||
},
|
||||
bindDateChange(e){
|
||||
this.fillDegreeList = []
|
||||
this.brandInfoList = []
|
||||
const date = new Date(e.detail.value)
|
||||
const nowDate = new Date()
|
||||
let storeTime = uni.getStorageSync('lastDay')
|
||||
const nowDate = new Date(storeTime)
|
||||
let nowMonth = nowDate.getMonth() + 1
|
||||
let m = date.getMonth() + 1
|
||||
|
||||
this.single = e.detail.value
|
||||
let d
|
||||
if (nowMonth === m){
|
||||
let nowYear = nowDate.getFullYear()
|
||||
let nowMonth = nowDate.getMonth() +1
|
||||
if (nowMonth<10){
|
||||
nowMonth = '0'+ nowMonth
|
||||
}
|
||||
let nowDay = nowDate.getDate() - 1
|
||||
if (nowDay<10){
|
||||
nowDay = '0'+ nowDay
|
||||
}
|
||||
this.time = `${nowYear}-${nowMonth}-${nowDay}`
|
||||
d = nowDay
|
||||
let y = date.getFullYear()
|
||||
let m = date.getMonth() + 1
|
||||
let nowY = nowDate.getFullYear()
|
||||
let nowM = nowDate.getMonth() + 1
|
||||
if (y === nowY && m === nowM){
|
||||
this.time = storeTime
|
||||
}else{
|
||||
d = this.$util.getThisMonthDay(e.detail.value)
|
||||
this.time = e.detail.value + '-' + d
|
||||
}
|
||||
let d = this.$util.getThisMonthDay(e.detail.value)
|
||||
if (m<10){
|
||||
m = '0' + m
|
||||
}
|
||||
this.time = `${y}-${m}-${d}`
|
||||
}
|
||||
|
||||
|
||||
// let d
|
||||
// if (nowMonth === m){
|
||||
// let nowYear = nowDate.getFullYear()
|
||||
// let nowMonth = nowDate.getMonth() +1
|
||||
// if (nowMonth<10){
|
||||
// nowMonth = '0'+ nowMonth
|
||||
// }
|
||||
// let nowDay = nowDate.getDate() - 1
|
||||
// if (nowDay<10){
|
||||
// nowDay = '0'+ nowDay
|
||||
// }
|
||||
// this.time = `${nowYear}-${nowMonth}-${nowDay}`
|
||||
// d = nowDay
|
||||
// }else{
|
||||
// d = this.$util.getThisMonthDay(e.detail.value)
|
||||
// this.time = e.detail.value + '-' + d
|
||||
// }
|
||||
// if (m<10){
|
||||
// m = '0' + m
|
||||
// }
|
||||
this.thisMonth = m
|
||||
this.endTime = e.detail.value + '-' + d
|
||||
this.endTime = storeTime
|
||||
this.onRefresh()
|
||||
console.log('this.time',this.time)
|
||||
},
|
||||
@ -217,6 +256,7 @@ export default {
|
||||
ServerpartId:this.serviceInfo.Serverpart_ID
|
||||
}
|
||||
const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req)
|
||||
this.serviceInfoObj = total.Result_Data
|
||||
this.haveFun = {
|
||||
car:total.Result_Data.HASPILOTLOUNGE,
|
||||
charge:total.Result_Data.HASCHARGE ,
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
<header-top :bgUrl="bgUrl" :menu="menu" :topBg="topBg" :bgColor="bgColor" :title="title" :page="page" :backType="backType" :analyseInfo="analyseInfo"
|
||||
:serverpartName="serviceInfo.SERVERPART_NAME" :spregionTypeName="serviceInfo.SPREGIONTYPE_NAME" :serviceInfo="serviceInfo"
|
||||
:topLeftBg="topLeftBg" :topLeftColor="topLeftColor" :iconObj="iconObj" :haveIconObj="haveIconObj" :detailBoxBg="detailBoxBg"
|
||||
:haveFun="haveFun"/>
|
||||
:haveFun="haveFun" :serviceTypeObj="serviceTypeObj" :serviceInfoObj="serviceInfoObj"/>
|
||||
|
||||
<div class="charts">
|
||||
<div class="chartsItem">
|
||||
@ -78,6 +78,7 @@ import ConsumptionLevel from "./components/guest/consumptionLevel.vue";
|
||||
import BusinessType from "./components/guest/businessType.vue";
|
||||
import NoData from "./components/noData.vue";
|
||||
import commercialType from "./commercialType.vue";
|
||||
import {getFieldEnum} from "../../util/dateTime";
|
||||
export default {
|
||||
name: "guestPortrait",
|
||||
components:{NoData, BusinessType, ConsumptionLevel, ConsumPrefer, analyse, headerTop,customerFirst,customerSecond,commercialType},
|
||||
@ -118,16 +119,21 @@ export default {
|
||||
single:'',//显示时间
|
||||
thisMonth:'',//几月
|
||||
endData:'', // 结束时间
|
||||
haveFun:{}
|
||||
haveFun:{},
|
||||
serviceTypeObj:{},// 服务区类型对象
|
||||
serviceInfoObj:{}
|
||||
}
|
||||
},
|
||||
onLoad(option){
|
||||
let serviceInfo = JSON.parse(option.serviceInfo)
|
||||
if (option.serviceInfo){
|
||||
this.serviceInfo = JSON.parse(option.serviceInfo)
|
||||
}
|
||||
this.backType = option.type
|
||||
this.serviceInfo = serviceInfo
|
||||
//跳转的时候带上时间
|
||||
this.time = option.time
|
||||
this.endData = new Date()
|
||||
// 服务区类型枚举
|
||||
this.handleServiceType()
|
||||
},
|
||||
onShow(){
|
||||
let storeTime = uni.getStorageSync('lastDay')
|
||||
@ -188,6 +194,17 @@ export default {
|
||||
this.endTime = e.detail.value + '-' + d
|
||||
this.onRefresh()
|
||||
},
|
||||
// 枚举服务区类型 SERVERPART_TYPE
|
||||
async handleServiceType(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SERVERPART_TYPE' });
|
||||
console.log('data',data)
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[Number(item.value)] = item.label
|
||||
})
|
||||
console.log('obj',obj)
|
||||
this.serviceTypeObj = obj
|
||||
},
|
||||
//重新调一遍页面数据的方法
|
||||
onRefresh(){
|
||||
//客群分析男女的气泡图
|
||||
@ -207,6 +224,7 @@ export default {
|
||||
ServerpartId:this.serviceInfo.Serverpart_ID
|
||||
}
|
||||
const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req)
|
||||
this.serviceInfoObj = total.Result_Data
|
||||
this.haveFun = {
|
||||
car:total.Result_Data.HASPILOTLOUNGE,
|
||||
charge:total.Result_Data.HASCHARGE ,
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
<header-top :bgUrl="bgUrl" :menu="menu" :bgColor="bgColor" :title="title" :analyseInfo="analyseInfo" :topBg="topBg" :page="page" :backType="backType"
|
||||
:serverpartName="serviceInfo.SERVERPART_NAME" :spregionTypeName="serviceInfo.SPREGIONTYPE_NAME" :serviceInfo="serviceInfo"
|
||||
:topLeftBg="topLeftBg" :topLeftColor="topLeftColor" :iconObj="iconObj" :haveIconObj="haveIconObj" :detailBoxBg="detailBoxBg"
|
||||
:haveFun="haveFun"/>
|
||||
:haveFun="haveFun" :serviceTypeObj="serviceTypeObj" :serviceInfoObj="serviceInfoObj"/>
|
||||
|
||||
<div class="charts">
|
||||
<div class="chartsItem">
|
||||
@ -197,6 +197,7 @@ import RevenueTrends from "./components/manager/revenueTrends.vue";
|
||||
import request from '@/util/index.js'
|
||||
import NoData from "./components/noData.vue";
|
||||
import commercialType from "./commercialType.vue";
|
||||
import {getFieldEnum} from "../../util/dateTime";
|
||||
|
||||
export default {
|
||||
name: "businessPortrait",
|
||||
@ -251,14 +252,19 @@ export default {
|
||||
month:'',
|
||||
haveFun:{},
|
||||
monthDetail:{},// 月度汇总信息 头部的内容
|
||||
serviceTypeObj:{},// 服务区类型对象
|
||||
serviceInfoObj:{}
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
let serviceInfo = JSON.parse(option.serviceInfo)
|
||||
if (option.serviceInfo){
|
||||
this.serviceInfo = JSON.parse(option.serviceInfo)
|
||||
}
|
||||
this.backType = option.type
|
||||
this.serviceInfo = serviceInfo
|
||||
//跳转的时候带上时间
|
||||
this.time = option.time
|
||||
// 服务区类型枚举
|
||||
this.handleServiceType()
|
||||
},
|
||||
onShow(){
|
||||
this.monthDetail = undefined
|
||||
@ -310,12 +316,24 @@ export default {
|
||||
this.$util.addUserBehavior()
|
||||
},
|
||||
methods:{
|
||||
// 枚举服务区类型 SERVERPART_TYPE
|
||||
async handleServiceType(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SERVERPART_TYPE' });
|
||||
console.log('data',data)
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[Number(item.value)] = item.label
|
||||
})
|
||||
console.log('obj',obj)
|
||||
this.serviceTypeObj = obj
|
||||
},
|
||||
//获取服务区基本信息
|
||||
async getServiceInfo(){
|
||||
let req = {
|
||||
ServerpartId:this.serviceInfo.Serverpart_ID
|
||||
}
|
||||
const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req)
|
||||
this.serviceInfoObj = total.Result_Data
|
||||
this.haveFun = {
|
||||
car:total.Result_Data.HASPILOTLOUNGE,
|
||||
charge:total.Result_Data.HASCHARGE ,
|
||||
|
||||
@ -16,12 +16,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="topImg">
|
||||
<swiper v-if="topBg.length>0" :current="currentImg" class="carousel" @change="changeSwiper">
|
||||
<swiper v-if="topBg && topBg.length>0" :current="currentImg" class="carousel" @change="changeSwiper">
|
||||
<swiper-item class="imgIndex" v-for="(item,index) in topBg" :key="index" >
|
||||
<image class="img" :src="item"></image>
|
||||
</swiper-item>
|
||||
</swiper>
|
||||
<div v-if="topBg.length>0" class="picNumber" @click="handlePreview">
|
||||
<div v-if="topBg && topBg.length>0" class="picNumber" @click="handlePreview">
|
||||
<image class="icon" src="/static/images/noImg.svg"></image>
|
||||
<text class="text"> {{currentImg + 1}} / {{ topBg.length }}</text>
|
||||
<image class="more" src="/static/images/more.svg"></image>
|
||||
|
||||
@ -27,7 +27,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<view class="pageContent">
|
||||
<view class="pageContent" style="width: 100%;height: calc(100vh - 330rpx);overflow-y: scroll">
|
||||
<view class="tabBox" v-if="showTab">
|
||||
<view :class="selectTab===1?'tab selectTab':'tab'" @click="handleChangeSelectTab(1)">驿达应收</view>
|
||||
<view :class="selectTab===2?'tab selectTab':'tab'" @click="handleChangeSelectTab(2)">商家欠款</view>
|
||||
@ -46,7 +46,7 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="listBox" style="width: 100%;height: calc(100vh - 420rpx);overflow-y: scroll">
|
||||
<view class="listBox" >
|
||||
<view v-if="showList && showList.length>0">
|
||||
<div class="listItem" v-for="(item,index) in showList" :key="index" @click="handleNoneChild(item)">
|
||||
<div class="listBox" :style="{borderBottom:item.showChild?'1px solid #D9DBE0':'0px solid #D9DBE0'}">
|
||||
@ -189,8 +189,6 @@ export default {
|
||||
}
|
||||
},
|
||||
onLoad(query){
|
||||
console.log('query',query)
|
||||
console.log('query.noShowTab',typeof (query.noShowTab))
|
||||
if (query.noShowTab==='true'){
|
||||
this.showTab = false
|
||||
}
|
||||
@ -219,7 +217,6 @@ export default {
|
||||
},
|
||||
methods:{
|
||||
handleChangeTime(e){
|
||||
console.log('e',e)
|
||||
const date = new Date(e.detail.value)
|
||||
const y = date.getFullYear()
|
||||
let m = date.getMonth() + 1
|
||||
@ -252,8 +249,6 @@ export default {
|
||||
const data = await request.$webGet('EShangApiMain/Finance/GetProjectSummary',req)
|
||||
this.showList = wrapTreeNode(data.Result_Data.List)
|
||||
this.otherData = data.Result_Data.OtherData
|
||||
console.log('showList',this.showList)
|
||||
console.log('otherData',this.otherData)
|
||||
uni.hideLoading()
|
||||
this.$forceUpdate()
|
||||
}else{
|
||||
@ -262,8 +257,6 @@ export default {
|
||||
// this.realList = list
|
||||
this.showList = list
|
||||
this.otherData = data.Result_Data.OtherData
|
||||
console.log('showList',this.showList)
|
||||
console.log('otherData',this.otherData)
|
||||
uni.hideLoading()
|
||||
this.$forceUpdate()
|
||||
}
|
||||
@ -271,7 +264,6 @@ export default {
|
||||
// // 排序方法
|
||||
// handleDescList(list){
|
||||
// let descList = JSON.parse(JSON.stringify(list))
|
||||
// console.log('descList',descList)
|
||||
// if (this.searchField===0){
|
||||
// //按照到账排序
|
||||
// if (this.descType === 'ascend'){
|
||||
@ -323,7 +315,6 @@ export default {
|
||||
|
||||
})
|
||||
this.$forceUpdate()
|
||||
console.log('this.showList',this.showList)
|
||||
},
|
||||
// 显示第二层子集
|
||||
handleShowSecondChildren(obj,subObj,index){
|
||||
@ -341,27 +332,23 @@ export default {
|
||||
// 拿到结算模式的枚举
|
||||
async handleGetSETTLEMENT(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'SETTLEMENT_MODES' });
|
||||
console.log('data',data)
|
||||
if (data && data.length>0){
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[item.value] = item.label
|
||||
})
|
||||
this.settlement = obj
|
||||
console.log('this.settlement',this.settlement)
|
||||
}
|
||||
},
|
||||
// 拿到合同类型的枚举
|
||||
async handleGetCOMPACTTYPE(){
|
||||
const data = await getFieldEnum({ FieldExplainField: 'COMPACT_CHARACTER' });
|
||||
console.log('data',data)
|
||||
if (data && data.length>0){
|
||||
let obj = {}
|
||||
data.forEach(item=>{
|
||||
obj[item.value] = item.label
|
||||
})
|
||||
this.compactType = obj
|
||||
console.log('this.compactType',this.compactType)
|
||||
}
|
||||
},
|
||||
// 改变排序状态
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user