This commit is contained in:
cclu 2023-06-20 20:16:48 +08:00
parent 8b91be08b2
commit 6f7aee4906
9 changed files with 140 additions and 78 deletions

View File

@ -276,7 +276,7 @@ export default {
let req = { let req = {
Province_Code:'340000', Province_Code:'340000',
Statistics_Date:time, Statistics_Date:time,
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID|| '',
ShowConsumptionLevel:true, ShowConsumptionLevel:true,
ShowConvertRate:true ShowConvertRate:true
} }
@ -294,7 +294,7 @@ export default {
let req = { let req = {
Province_Code:'340000', Province_Code:'340000',
Statistics_Date:this.time, Statistics_Date:this.time,
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID|| '',
TimeSpan:1 TimeSpan:1
} }
let totalData = await request.$webGet('CommercialApi/Revenue/GetTransactionTimeAnalysis',req) let totalData = await request.$webGet('CommercialApi/Revenue/GetTransactionTimeAnalysis',req)
@ -345,7 +345,7 @@ export default {
let req = { let req = {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:this.time, StatisticsDate:this.time,
ServerpartId:this.serviceInfo.Serverpart_ID, ServerpartId:this.serviceInfo.Serverpart_ID|| '',
ShowWholeTrade:false ShowWholeTrade:false
} }
let res = { let res = {
@ -388,7 +388,7 @@ export default {
let req = { let req = {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:this.time, StatisticsDate:this.time,
ServerpartId:this.serviceInfo.Serverpart_ID, ServerpartId:this.serviceInfo.Serverpart_ID|| '',
ShowWholeBrand:false ShowWholeBrand:false
} }
let res =[] let res =[]
@ -422,7 +422,7 @@ export default {
const req = { const req = {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:this.time, StatisticsDate:this.time,
serverpartId:this.serviceInfo.Serverpart_ID, serverpartId:this.serviceInfo.Serverpart_ID|| '',
BusinessTradeIds:-1 BusinessTradeIds:-1
} }
const data = await request.$webGet('CommercialApi/Revenue/GetBusinessTradeRevenue',req) const data = await request.$webGet('CommercialApi/Revenue/GetBusinessTradeRevenue',req)
@ -456,7 +456,7 @@ export default {
const req = { const req = {
Province_Code:'340000', Province_Code:'340000',
Statistics_Date:this.time, Statistics_Date:this.time,
Serverpart_ID:this.serviceInfo.Serverpart_ID Serverpart_ID:this.serviceInfo.Serverpart_ID|| ''
} }
const data = await request.$webGet('CommercialApi/Revenue/GetTransactionConvert',req) const data = await request.$webGet('CommercialApi/Revenue/GetTransactionConvert',req)
let customerOrder = [] let customerOrder = []
@ -532,7 +532,7 @@ export default {
let req = { let req = {
statisticsDate:this.time, statisticsDate:this.time,
provinceCode:'340000', provinceCode:'340000',
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID || '',
SPRegionType_ID:this.serviceInfo.SPRegionType_ID SPRegionType_ID:this.serviceInfo.SPRegionType_ID
} }
const data = await request.$webGet('CommercialApi/Revenue/GetSalableCommodity',req) const data = await request.$webGet('CommercialApi/Revenue/GetSalableCommodity',req)

View File

@ -27,7 +27,7 @@
<view class="select"> <view class="select">
<view class="content"> <view class="content">
<view class="uni-input">{{serviceInfo.SERVERPART_NAME}}</view> <view class="uni-input">{{serviceInfo.SERVERPART_NAME}}</view>
<p class="area">{{serviceInfo.SPREGIONTYPE_NAME}}</p> <p class="area" v-if="serviceInfo.Serverpart_ID">{{serviceInfo.SPREGIONTYPE_NAME}}</p>
<image class="rightArrow" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"></image> <image class="rightArrow" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"></image>
</view> </view>
</view> </view>
@ -51,7 +51,7 @@
</div> </div>
</div> </div>
<div v-if="carData.length>0"> <div v-if="carData.length>0">
<entry-zone :carData="carData" :time="time" :month="thisMonth"/> <entry-zone :carData="carData" :time="time" :month="thisMonth" />
<analyse :analyseInfo="{analysisins_type: 1102,analysisins_format: 2000}" /> <analyse :analyseInfo="{analysisins_type: 1102,analysisins_format: 2000}" />
</div> </div>
<no-data v-if="!carData.length" :type="'car'"/> <no-data v-if="!carData.length" :type="'car'"/>
@ -78,7 +78,8 @@
</picker> </picker>
</div> </div>
</div> </div>
<view class="tab" >
<view class="tab" v-if="serviceInfo.Serverpart_ID">
<view v-for="(item,index) in tabList" :key="index" :class="selectTab===item.value?'tabItem tabItemActive':'tabItem'" @click="handleChangeTab(item.value)">{{item.name}}</view> <view v-for="(item,index) in tabList" :key="index" :class="selectTab===item.value?'tabItem tabItemActive':'tabItem'" @click="handleChangeTab(item.value)">{{item.name}}</view>
</view> </view>
@ -205,9 +206,9 @@ export default {
this.backType = option.type this.backType = option.type
}, },
onShow(){ onShow(){
this.isFirst = true this.isFirst = true
// bi 西 // bi 西
// //
let nowTime = new Date() let nowTime = new Date()
let y = nowTime.getFullYear() let y = nowTime.getFullYear()
let month = nowTime.getMonth() + 1 let month = nowTime.getMonth() + 1
@ -300,16 +301,18 @@ export default {
}else{ }else{
id = currentService.Serverpart_ID id = currentService.Serverpart_ID
} }
let req = { if (id){
let req = {
ServerpartId:id ServerpartId:id
} }
const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req) const total = await request.$webGet('CommercialApi/BaseInfo/GetServerpartInfo',req)
// tabList // tabList
let tabList = [{name:'全部',value:0}] let tabList = [{name:'全部',value:0}]
total.Result_Data.RegionInfo.forEach((item,index)=>{ total.Result_Data.RegionInfo.forEach((item,index)=>{
tabList.push({name:item.SERVERPART_REGIONNAME,value:index+1}) tabList.push({name:item.SERVERPART_REGIONNAME,value:index+1})
}) })
this.tabList = tabList this.tabList = tabList
}
}, },
// //
bindDateChange(e){ bindDateChange(e){
@ -538,10 +541,13 @@ export default {
getCarData(){ getCarData(){
request.$webGet('CommercialApi/Revenue/GetBayonetEntryList',{ request.$webGet('CommercialApi/Revenue/GetBayonetEntryList',{
StatisticsDate: this.time, StatisticsDate: this.time,
Serverpart_ID :this.serviceInfo.Serverpart_ID, Serverpart_ID :this.serviceInfo.Serverpart_ID!==0?this.serviceInfo.Serverpart_ID:null,
ShowAddUpCount:true ShowAddUpCount:true
}).then(res=>{ }).then(res=>{
this.carData = res.Result_Data.List this.carData = res.Result_Data.List
res.Result_Data.List.forEach(item=>{
item.Serverpart_ID = this.serviceInfo.Serverpart_ID
})
}) })
}, },
getHomeData(type){ getHomeData(type){
@ -616,7 +622,7 @@ export default {
getCarTypeTime(){ getCarTypeTime(){
request.$webGet('CommercialApi/Revenue/GetBayonetSTAList',{ request.$webGet('CommercialApi/Revenue/GetBayonetSTAList',{
StatisticsDate:this.endTime?this.endTime:this.time, StatisticsDate:this.endTime?this.endTime:this.time,
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID || '',
ContainWhole:true ContainWhole:true
}).then(res=>{ }).then(res=>{
let result = res.Result_Data.List let result = res.Result_Data.List
@ -663,6 +669,7 @@ export default {
this.carTypeTimeDataAll[2] ={categories:result[2].Vehicle_Type?result[2].Vehicle_Type:[], series:[series[5],series[4]]} this.carTypeTimeDataAll[2] ={categories:result[2].Vehicle_Type?result[2].Vehicle_Type:[], series:[series[5],series[4]]}
} }
this.carTypeTimeData = this.carTypeTimeDataAll[this.selectTab]?this.carTypeTimeDataAll[this.selectTab]:[] this.carTypeTimeData = this.carTypeTimeDataAll[this.selectTab]?this.carTypeTimeDataAll[this.selectTab]:[]
console.log('this.carTypeTimeData',this.carTypeTimeData)
}else{ }else{
this.carTypeTimeDataAll = [] this.carTypeTimeDataAll = []
this.carTypeTimeData = [] this.carTypeTimeData = []
@ -682,7 +689,7 @@ export default {
StartMonth:`${y}${m}`, StartMonth:`${y}${m}`,
EndMonth:`${y}${m}`, EndMonth:`${y}${m}`,
Province_Code:'340000', Province_Code:'340000',
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID || '',
Serverpart_Region: data, Serverpart_Region: data,
TimeSpan: 2 TimeSpan: 2
}).then(res=>{ }).then(res=>{
@ -740,7 +747,7 @@ export default {
req = { req = {
Statistics_Date: this.endTime?endTime:this.time, Statistics_Date: this.endTime?endTime:this.time,
Province_Code:'340000', Province_Code:'340000',
Serverpart_ID :this.serviceInfo.Serverpart_ID, Serverpart_ID :this.serviceInfo.Serverpart_ID?this.serviceInfo.Serverpart_ID:'',
GroupType:2, GroupType:2,
ShowGrowthRate:true ShowGrowthRate:true
} }

View File

@ -1,11 +1,11 @@
<template> <template>
<div style="min-height: 100px;"> <div style="min-height: 100px;">
<div class="car"> <div class="car">
<div class="item" style="left: -16px;width: calc(220px)"> <div class="item" :style="{left: Serverpart_ID?'-16px':'0px',width: '200px'}">
<canvas style="left: 0" v-if="!carNumPath" class="carNum" canvas-id="carNum" id="carNum"/> <canvas style="left: 0" v-if="!carNumPath" class="carNum" canvas-id="carNum" id="carNum"/>
<image style="left: 0" v-if="carNumPath" class="carNum" :src="carNumPath"></image> <image style="left: 0" v-if="carNumPath" class="carNum" :src="carNumPath"></image>
</div> </div>
<div class="item" style="right: -16px;width: calc(200px)"> <div class="item" :style="{right:Serverpart_ID? '-16px':'-33px',width: '200px'}">
<canvas style="right: 0" v-if="!probabilityPath" class="carNum" canvas-id="probability" id="probability"/> <canvas style="right: 0" v-if="!probabilityPath" class="carNum" canvas-id="probability" id="probability"/>
<image style="right: 0" v-if="probabilityPath" class="carNum" :src="probabilityPath"></image> <image style="right: 0" v-if="probabilityPath" class="carNum" :src="probabilityPath"></image>
</div> </div>
@ -65,7 +65,8 @@ export default {
analysisins_format: 2000 analysisins_format: 2000
}, },
allAddUpCount:0, allAddUpCount:0,
allEntryAddUpRate:0 allEntryAddUpRate:0,
Serverpart_ID:''
} }
}, },
props:{ props:{
@ -82,23 +83,27 @@ export default {
default:'' default:''
} }
}, },
watch:{ watch:{
carData:{ carData:{
handler(value){ handler(value){
console.log('value222',value)
if (value.length>0){ if (value.length>0){
this.isShowData = true this.isShowData = true
} }
this.carNumPath = '' this.carNumPath = ''
this.probabilityPath = '' this.probabilityPath = ''
this.handleCarData(value)
this.dataList = value this.dataList = value
this.dataList.forEach(item=>{
item.AddUpCount = this.$util.noDecimal(item.Vehicle_AddUpCount)
allCount +=item.Vehicle_AddUpCount
allRate +=item.EntryAddUp_Rate
this.Serverpart_ID = item.Serverpart_ID
})
this.handleCarData(value)
let allCount = 0 let allCount = 0
let allRate = 0 let allRate = 0
this.dataList.forEach(item=>{
item.AddUpCount = this.$util.noDecimal(item.Vehicle_AddUpCount)
allCount +=item.Vehicle_AddUpCount
allRate +=item.EntryAddUp_Rate
})
this.allAddUpCount = this.$util.noDecimal(allCount) this.allAddUpCount = this.$util.noDecimal(allCount)
this.allEntryAddUpRate = allRate.toFixed(2) this.allEntryAddUpRate = allRate.toFixed(2)
}, },
@ -113,6 +118,7 @@ export default {
let carSum = 0 // let carSum = 0 //
let Vehicle_CountAll=0 // let Vehicle_CountAll=0 //
let SectionFlow_CountAll=0 // let SectionFlow_CountAll=0 //
console.log('this.id',this.id)
value.forEach(item=>{ value.forEach(item=>{
data.push({name:item.Serverpart_Region+'区 '+item.Vehicle_Count ,value:item.Entry_Rate }) data.push({name:item.Serverpart_Region+'区 '+item.Vehicle_Count ,value:item.Entry_Rate })
carSum+=item.Vehicle_Count carSum+=item.Vehicle_Count
@ -154,14 +160,16 @@ export default {
} }
let configCarNum={ let configCarNum={
title:this.carNumAll, title:this.carNumAll,
subtitle:"昨日入区车流" subtitle:"昨日入区车流",
} }
let config={ let config={
title:this.entryRate, title:this.entryRate,
subtitle:"昨日入区率" subtitle:"昨日入区率",
} }
this.drawCharts('carNum' , res,configCarNum ) this.drawCharts('carNum' , res,configCarNum )
this.drawCharts2('probability',probabilityRes,config) this.drawCharts2('probability',probabilityRes,config)
console.log('config',config)
console.log('configCarNum',configCarNum)
}, },
drawCharts(id,data,config){ drawCharts(id,data,config){
const ctx = uni.createCanvasContext(id, this); const ctx = uni.createCanvasContext(id, this);
@ -170,8 +178,8 @@ export default {
uChartsInstance[id] = new uCharts({ uChartsInstance[id] = new uCharts({
type: "ring", type: "ring",
context: ctx, context: ctx,
width: 200, width: _this.Serverpart_ID?200:160,
height: 208, height: _this.Serverpart_ID?208:160,
series: data.series, series: data.series,
animation: false, animation: false,
rotate: false, rotate: false,
@ -192,7 +200,7 @@ export default {
color: "#786B6C", color: "#786B6C",
}, },
legend: { legend: {
show: true, show: _this.Serverpart_ID?true:false,
position: "bottom", position: "bottom",
lineHeight: 25, lineHeight: 25,
float: 'center', float: 'center',
@ -222,8 +230,8 @@ export default {
uChartsInstance[id] = new uCharts({ uChartsInstance[id] = new uCharts({
type: "ring", type: "ring",
context: ctx, context: ctx,
width: 210, width: _this.Serverpart_ID?210:160,
height: 208, height: _this.Serverpart_ID?208:160,
series: data.series, series: data.series,
animation: false, animation: false,
rotate: false, rotate: false,
@ -244,7 +252,7 @@ export default {
color: "#786B6C", color: "#786B6C",
}, },
legend: { legend: {
show: true, show: _this.Serverpart_ID?true:false,
position: "bottom", position: "bottom",
lineHeight: 25, lineHeight: 25,
float: 'center', float: 'center',

View File

@ -18,7 +18,7 @@
<!-- <view class="uni-input">{{serviceArray[serviceIndex]}}</view>--> <!-- <view class="uni-input">{{serviceArray[serviceIndex]}}</view>-->
<view class="uni-input">{{serverpartName}}</view> <view class="uni-input">{{serverpartName}}</view>
<!-- <text class="area">{{area}}</text>--> <!-- <text class="area">{{area}}</text>-->
<text class="area">{{spregionTypeName}}</text> <text class="area" v-if="serviceInfo.Serverpart_ID">{{spregionTypeName}}</text>
<image class="rightArrow" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"></image> <image class="rightArrow" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/rightArrow.svg"></image>
</view> </view>
</view> </view>

View File

@ -30,7 +30,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="list" > <div class="list" v-if="id">
<!-- <p class="bigTitle" v-if="dataInfo.ContractList.length>0">即将到期合同列表: </p>--> <!-- <p class="bigTitle" v-if="dataInfo.ContractList.length>0">即将到期合同列表: </p>-->
<div class="item" v-for="(item,index) in dataInfo.ContractList" :key="index"> <div class="item" v-for="(item,index) in dataInfo.ContractList" :key="index">
<div class="title">{{item.name}}</div> <div class="title">{{item.name}}</div>
@ -52,12 +52,17 @@ export default {
data: { data: {
type: Object, type: Object,
default: () => {} default: () => {}
},
id:{
type:String,
default:''
} }
}, },
watch: { watch: {
data: { data: {
handler(value) { handler(value) {
this.dataInfo = value this.dataInfo = value
console.log('value',value)
} }
} }
}, },

View File

@ -211,17 +211,17 @@ export default {
}else{ }else{
time = this.endTime time = this.endTime
} }
const req = {
const req = {
Province_Code:'340000', Province_Code:'340000',
Statistics_Date:time, Statistics_Date:time,
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID || '',
ShowConsumptionLevel:true, ShowConsumptionLevel:true,
ShowConvertRate:true ShowConvertRate:true
} }
let totalData = await request.$webGet('CommercialApi/Revenue/GetTransactionAnalysis',req) let totalData = await request.$webGet('CommercialApi/Revenue/GetTransactionAnalysis',req)
console.log('totalData',totalData) console.log('totalData',totalData)
this.customer = totalData.Result_Data?totalData.Result_Data:{} this.customer = totalData.Result_Data?totalData.Result_Data:{}
}, },
// //
async getGenderBubbleList(){ async getGenderBubbleList(){
@ -245,7 +245,7 @@ export default {
const req = { const req = {
statisticsType:1, statisticsType:1,
provinceCode:'340000', provinceCode:'340000',
serverpartId:this.serviceInfo.Serverpart_ID, serverpartId:this.serviceInfo.Serverpart_ID||'',
statisticsMonth:this.$util.getThisMonth(time) statisticsMonth:this.$util.getThisMonth(time)
} }
let totalData = await request.$webGet('CommercialApi/Customer/GetCustomerRatio',req) let totalData = await request.$webGet('CommercialApi/Customer/GetCustomerRatio',req)
@ -259,7 +259,7 @@ export default {
}) })
const bubbleReq = { const bubbleReq = {
provinceCode:'340000', provinceCode:'340000',
serverpartId:this.serviceInfo.Serverpart_ID, serverpartId:this.serviceInfo.Serverpart_ID||'',
statisticsMonth:this.$util.getThisMonth(time) statisticsMonth:this.$util.getThisMonth(time)
} }
@ -297,7 +297,7 @@ export default {
startMonth:this.$util.getThisMonth(time), startMonth:this.$util.getThisMonth(time),
endMonth:this.$util.getThisMonth(time), endMonth:this.$util.getThisMonth(time),
provinceCode: '340000', provinceCode: '340000',
serverpartId: this.serviceInfo.Serverpart_ID serverpartId: this.serviceInfo.Serverpart_ID||''
} }
const data = await request.$webGet('CommercialApi/Customer/GetCustomerSaleRatio',req) const data = await request.$webGet('CommercialApi/Customer/GetCustomerSaleRatio',req)
let res = { let res = {
@ -344,7 +344,7 @@ export default {
} }
const req = { const req = {
provinceCode:'340000', provinceCode:'340000',
serverpartId:this.serviceInfo.Serverpart_ID, serverpartId:this.serviceInfo.Serverpart_ID||'',
statisticsMonth:this.$util.getThisMonth(time) statisticsMonth:this.$util.getThisMonth(time)
} }
const data = await request.$webGet('CommercialApi/Customer/GetCustomerConsumeRatio',req) const data = await request.$webGet('CommercialApi/Customer/GetCustomerConsumeRatio',req)
@ -374,7 +374,7 @@ export default {
const req = { const req = {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:time, StatisticsDate:time,
serverpartId:this.serviceInfo.Serverpart_ID serverpartId:this.serviceInfo.Serverpart_ID || ''
} }
const data = await request.$webGet('CommercialApi/Revenue/GetBusinessTradeRevenue',req) const data = await request.$webGet('CommercialApi/Revenue/GetBusinessTradeRevenue',req)
let res = [] let res = []

View File

@ -310,9 +310,13 @@ export default {
} }
const date = new Date(this.time) const date = new Date(this.time)
let month = date.getMonth() + 1 let month = date.getMonth() + 1
if (this.serviceInfo.Serverpart_ID){
uni.navigateTo({ uni.navigateTo({
url:`/pages/commercialBI/serviceDetail?serviceInfo=${JSON.stringify(service)}&month=${month}&type=month` url:`/pages/commercialBI/serviceDetail?serviceInfo=${JSON.stringify(service)}&month=${month}&type=month`
}) })
}else{
this.$util.toNextRoute('navigateTo', `/pages/commercialBI/planMonth?lastDay=${this.lastDay}&type=${type}`)
}
}else{ }else{
let service = { let service = {
Budget_Amount:this.plan.BudgetYear_Amount, Budget_Amount:this.plan.BudgetYear_Amount,
@ -324,11 +328,14 @@ export default {
name:serviceInfo.name, name:serviceInfo.name,
unit:serviceInfo.unit unit:serviceInfo.unit
} }
if (this.serviceInfo.Serverpart_ID){
uni.navigateTo({ uni.navigateTo({
url:`/pages/commercialBI/serviceDetail?serviceInfo=${JSON.stringify(service)}&type=year` url:`/pages/commercialBI/serviceDetail?serviceInfo=${JSON.stringify(service)}&type=year`
}) })
}else{
this.$util.toNextRoute('navigateTo', `/pages/commercialBI/planMonth?lastDay=${this.lastDay}&type=${type}`)
}
} }
}, },
async handleNoticeMonth(){ async handleNoticeMonth(){
let date = new Date(this.lastDay) let date = new Date(this.lastDay)
@ -405,8 +412,8 @@ export default {
let req = { let req = {
statisticsDate:this.time, statisticsDate:this.time,
provinceCode:'340000', provinceCode:'340000',
Serverpart_ID:this.serviceInfo.Serverpart_ID, Serverpart_ID:this.serviceInfo.Serverpart_ID ||'',
SPRegionType_ID:this.serviceInfo.SPRegionType_ID SPRegionType_ID:this.serviceInfo.SPRegionType_ID || ''
} }
let totalData = await request.$webGet('CommercialApi/Contract/GetContractAnalysis',req) let totalData = await request.$webGet('CommercialApi/Contract/GetContractAnalysis',req)
this.revenueList = { this.revenueList = {
@ -453,7 +460,7 @@ export default {
async getMoneyCompareList(){ async getMoneyCompareList(){
let req = { let req = {
StatisticsDate:this.time, StatisticsDate:this.time,
ServerpartId:this.serviceInfo.Serverpart_ID ServerpartId:this.serviceInfo.Serverpart_ID || ''
} }
const data = await request.$webGet('CommercialApi/Revenue/GetRevenueCompare',req) const data = await request.$webGet('CommercialApi/Revenue/GetRevenueCompare',req)
let RevenueAmount = [] // let RevenueAmount = [] //
@ -566,13 +573,13 @@ export default {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:y, StatisticsDate:y,
StatisticsType:1, StatisticsType:1,
ServerpartId:this.serviceInfo.Serverpart_ID ServerpartId:this.serviceInfo.Serverpart_ID || ''
} }
let yesReq = { let yesReq = {
ProvinceCode:'340000', ProvinceCode:'340000',
StatisticsDate:y - 1, StatisticsDate:y - 1,
StatisticsType:1, StatisticsType:1,
ServerpartId:this.serviceInfo.Serverpart_ID ServerpartId:this.serviceInfo.Serverpart_ID || ''
} }
const data = await request.$webGet('CommercialApi/Revenue/GetRevenueTrend',req) const data = await request.$webGet('CommercialApi/Revenue/GetRevenueTrend',req)
const yesData = await request.$webGet('CommercialApi/Revenue/GetRevenueTrend',yesReq) const yesData = await request.$webGet('CommercialApi/Revenue/GetRevenueTrend',yesReq)
@ -620,7 +627,8 @@ export default {
const req = { const req = {
pushProvinceCode:'340000', pushProvinceCode:'340000',
Statistics_StartDate:`${y}-${m}-01`, Statistics_StartDate:`${y}-${m}-01`,
Statistics_Date:this.time Statistics_Date:this.time,
Serverpart_ID:this.serviceInfo.Serverpart_ID || ''
} }
const data = await request.$webGet('CommercialApi/Revenue/GetSummaryRevenue',req) const data = await request.$webGet('CommercialApi/Revenue/GetSummaryRevenue',req)
let all = 0 let all = 0
@ -639,6 +647,7 @@ export default {
monthYearPlan(){ monthYearPlan(){
const monthDate= { const monthDate= {
Province_Code:'340000', Province_Code:'340000',
Serverpart_ID:this.serviceInfo.Serverpart_ID || '',
Statistics_Date:this.time Statistics_Date:this.time
} }
request.$webGet('CommercialApi/Revenue/GetRevenueBudget',monthDate).then(res=>{ request.$webGet('CommercialApi/Revenue/GetRevenueBudget',monthDate).then(res=>{

View File

@ -752,13 +752,21 @@ export default {
latitude:seat.latitude, latitude:seat.latitude,
} }
const data = await request.$webGet('CommercialApi/BaseInfo/GetServerpartList',req) const data = await request.$webGet('CommercialApi/BaseInfo/GetServerpartList',req)
// let res = {
// SERVERPART_NAME:data.Result_Data.List[0].SERVERPART_NAME,//
// SPREGIONTYPE_NAME:data.Result_Data.List[0].SPREGIONTYPE_NAME,//
// SPRegionType_ID:data.Result_Data.List[0].SPREGIONTYPE_ID,//id
// Serverpart_ID:data.Result_Data.List[0].SERVERPART_ID,//id
// longitude:data.Result_Data.List[0].SERVERPART_X,
// latitude:data.Result_Data.List[0].SERVERPART_Y,
// }
let res = { let res = {
SERVERPART_NAME:data.Result_Data.List[0].SERVERPART_NAME,// SERVERPART_NAME: '安徽驿达',//
SPREGIONTYPE_NAME:data.Result_Data.List[0].SPREGIONTYPE_NAME,// SPREGIONTYPE_NAME: '安徽驿达',//
SPRegionType_ID:data.Result_Data.List[0].SPREGIONTYPE_ID,//id Serverpart_ID: null,
Serverpart_ID:data.Result_Data.List[0].SERVERPART_ID,//id SPRegionType_ID: null,
longitude:data.Result_Data.List[0].SERVERPART_X, longitude:'117.200927',
latitude:data.Result_Data.List[0].SERVERPART_Y, latitude:'31.832905',
} }
uni.setStorageSync('nearService',res) uni.setStorageSync('nearService',res)
this.nearServiceInfo = res this.nearServiceInfo = res

View File

@ -4,6 +4,7 @@
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/navigation-left.svg"></image> <image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/navigation-left.svg"></image>
</div> </div>
<map v-if="isShowMap" id="myMap" :longitude="longitude" :latitude="latitude" :markers="markers" class="map" show-location></map> <map v-if="isShowMap" id="myMap" :longitude="longitude" :latitude="latitude" :markers="markers" class="map" show-location></map>
<view v-else class="map"></view>
<div class="list" :style="{transform:isMoveUp?`translateY(calc(-40vh + ${menu.bottom + 5}px))`:''}"> <div class="list" :style="{transform:isMoveUp?`translateY(calc(-40vh + ${menu.bottom + 5}px))`:''}">
<div class="top"> <div class="top">
<div class="topImg" @click="handleChangeUp"> <div class="topImg" @click="handleChangeUp">
@ -104,7 +105,6 @@ export default {
this.getServiceList() this.getServiceList()
} }
}) })
console.log('option',option)
this.serviceInfo = JSON.parse(option.serviceInfo) this.serviceInfo = JSON.parse(option.serviceInfo)
if (option.chartType){ if (option.chartType){
this.chartType = true this.chartType = true
@ -149,7 +149,6 @@ export default {
latitude:{ latitude:{
handler(value){ handler(value){
if (value){ if (value){
console.log('watch',value)
this.getListData() this.getListData()
} }
}, },
@ -199,7 +198,12 @@ export default {
Province_Code:'340000' Province_Code:'340000'
} }
const data = await request.$webGet('CommercialApi/BaseInfo/GetSPRegionList',req) const data = await request.$webGet('CommercialApi/BaseInfo/GetSPRegionList',req)
this.array = data.Result_Data.List console.log('data123',data)
let list = [{name:'安徽驿达',value:'0'}]
data.Result_Data.List.forEach(item=>{
list.push({name:item.name,value:item.value})
})
this.array = list
if (this.area){ if (this.area){
this.array.forEach((item,index)=>{ this.array.forEach((item,index)=>{
if (item.name === this.area){ if (item.name === this.area){
@ -209,10 +213,33 @@ export default {
} }
await this.getLocation() await this.getLocation()
}, },
// //
handleChangeService(e){ handleChangeService(e){
this.selectIndex = Number(e.detail.value) console.log('e',e)
this.selectIndex = Number(e.detail.value)
console.log(this.selectIndex)
if (this.selectIndex===0){
let res = {
SERVERPART_NAME: '安徽驿达',//
SPREGIONTYPE_NAME: '安徽驿达',//
Serverpart_ID: null,
SPRegionType_ID: null,
longitude:'117.200927',
latitude:'31.832905',
}
uni.setStorageSync('currentService',res) //
if (this.chartType){
uni.navigateBack({
delta: 1
})
}else{
uni.navigateBack({
delta: 1
})
}
}else{
this.getListData() this.getListData()
}
}, },
// //
async handleSearch(){ async handleSearch(){
@ -254,7 +281,6 @@ export default {
async getListData(){ async getListData(){
let id let id
let user = uni.getStorageSync('seatInfo') let user = uni.getStorageSync('seatInfo')
console.log('user',user)
let current = uni.getStorageSync('currentService') let current = uni.getStorageSync('currentService')
let nearService = uni.getStorageSync('nearService') let nearService = uni.getStorageSync('nearService')
if (!this.selectIndex && this.selectIndex!==0){ if (!this.selectIndex && this.selectIndex!==0){
@ -284,7 +310,6 @@ export default {
longitude:user.longitude, longitude:user.longitude,
latitude:user.latitude latitude:user.latitude
} }
console.log('req',req)
const data = await request.$webGet('CommercialApi/BaseInfo/GetServerpartList',req) const data = await request.$webGet('CommercialApi/BaseInfo/GetServerpartList',req)
this.serviceList = data.Result_Data.List this.serviceList = data.Result_Data.List
}, },