zhengkaixin пре 3 година
родитељ
комит
a4a4e8a475

+ 3 - 2
.env.dev.js

@@ -1,12 +1,13 @@
 const UNI_APP = {  
+	// BASE_URL: 'https://charging.xiaoxinda.com/charging-station-test/',
 	
     BASE_URL: 'http://192.168.77.162:8080/charging-station/' ,
 	NODE_ENV :"dev",
 	SIMPLE_RUN:true,// 无视权限控制跳转页面   , 用于样式人员快速访问各种功能 ,快速测试等
 	//openId:"oHjCawsxTJkxixR74OVp7aCKahj8",//测试用openId  
 	//openId:"oHjCawgwCGen5k1-hAsimdEX5lZo",
-	openId:"1000",
-	//openId:"oK9Wr54VbEh3xvWYmD_zT5NbH4AY",
+	//openId:"1000",
+	openId:"oK9Wr54VbEh3xvWYmD_zT5NbH4AY",
 	//小鹏管家appid
 	//VUE_APP_WXAPPID:"wx7e70eb62a8459869",
 		VUE_APP_WXAPPID:"wx3afdb1b60188c1e5",

+ 1 - 1
.env.js

@@ -1,5 +1,5 @@
 (function() {  
-    const NODE_ENV = 'test'; // dev:开发环境 | test:测试环境  
+    const NODE_ENV = 'dev'; // dev:开发环境 | test:测试环境  
     let ENV_VAR = null;  
 	 
 	var NODE_NAME=  process.env['NODE_NAME']

+ 7 - 5
.env.test.js

@@ -1,8 +1,8 @@
 const UNI_APP = {  
-    BASE_URL: 'https://51team.xiaoxinda.com/charging-station-server/',
+   // BASE_URL: 'https://51team.xiaoxinda.com/charging-station-server/',
 
-    // BASE_URL: 'http://192.168.77.162:8080/charging-station/' ,
-	//BASE_URL: 'https://charging.xiaoxinda.com/charging-station-test/',
+   //  BASE_URL: 'http://192.168.77.162:8080/charging-station/' ,
+	BASE_URL: 'https://charging.xiaoxinda.com/charging-station-test/',
    // BASE_URL: 'https://charging.xiaoxinda.com/charging-station-server/',
    
 
@@ -15,8 +15,10 @@ const UNI_APP = {
 	VUE_APP_WXAPPID:"wx3afdb1b60188c1e5",
 	//zkx的测试openId
 	//openId:"oHjCawsJ5blME36lHaSpSVfEhleU",
-	//	openId:"1000",   oHjCawigqi8SEAwutwkQ-VEgdp3k oK9Wr59rru-i3bm7dtTtxnkR-i4s
-	openId:"oK9Wr54VbEh3xvWYmD_zT5NbH4AY",
+		//openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",
+	 //	   oK9Wr54VbEh3xvWYmD_zT5NbH4AY
+	 openId:"10000",
+	//openId:"oK9Wr59rru-i3bm7dtTtxnkR-i4s",
 	//zq的测试openId
 	//openId:"oHjCawsxTJkxixR74OVp7aCKahj8",
 }  

+ 32 - 0
apis/finance.js

@@ -192,4 +192,36 @@ export function recordMonthDetailData (data) {
 		data:data ,
 		url: "/mobile/roleSharing/recordMonthDetailData"
 	})
+} 
+
+
+export function recordData (data) {
+	 
+	return request({
+		method: 'post',
+		jp_identity:"merchantUser",// 分润接口
+		data:data ,
+		url: "/mobile/roleSharing/recordData"
+	})
+} 
+
+export function recordDetailData (data) {
+	 
+	return request({
+		method: 'get',
+		jp_identity:"merchantUser",// 分润接口
+		data:data ,
+		url: "/mobile/roleSharing/recordDetailData"
+	})
+} 
+
+
+export function stationsList (data) {
+	 
+	return request({
+		method: 'post',
+		jp_identity:"merchantUser",// 分润接口
+		data:data ,
+		url: "/mobile/roleSharing/stationsList"
+	})
 } 

+ 3 - 0
components/Tabbar.vue

@@ -51,6 +51,9 @@
 			};
 			
 		},methods:{
+			setcount(c){
+				this.myCurrent=c
+			},
 			beforeSwitch(index){
 			
 				

+ 11 - 8
components/TabbarFinance.vue

@@ -31,15 +31,15 @@
 						
 				 	},
 				 
-					{
-						iconPath: "article-fill",
-						selectedIconPath: "article-fill",
-						text: '明细',
-						midButton: true,
-						customIcon: true,
-						pagePath2:"/pagesFinance/detailed/index",
+					// {
+					// 	iconPath: "article-fill",
+					// 	selectedIconPath: "article-fill",
+					// 	text: '明细',
+					// 	midButton: true,
+					// 	customIcon: true,
+					// 	pagePath2:"/pagesFinance/detailed/index",
 						
-					},
+					// },
 					{
 						iconPath: "money-cny-box-fill",
 						selectedIconPath: "money-cny-box-fill",
@@ -63,6 +63,9 @@
 			};
 			
 		},methods:{
+			setcount(c){
+				this.myCurrent=c
+			},
 			beforeSwitch(index){
 			
 				

+ 12 - 1
pages.json

@@ -203,7 +203,18 @@
 			
 				//"navigationStyle": "custom" // 隐藏系统导航栏
 			}
-		},
+		},
+		{
+			"name":"我的站点",
+			"path": "pagesFinance/user/stationsList",
+			"style": {
+			
+				//"navigationStyle": "custom" // 隐藏系统导航栏
+			}
+		},
+	
+		
+		
 		{
 			"name":"设备详情",
 			"path": "pagesFinance/user/deviceDetails",

+ 4 - 1
pages/index/index.vue

@@ -107,7 +107,7 @@
 	
 
 		</u-modal>
-		<Tabbar :current="0" :id="id"></Tabbar>
+		<Tabbar :current="0" ref="tabbarMain"  :id="id"></Tabbar>
 	</view>
 </template>
 
@@ -365,6 +365,9 @@
 		onShow() {
 			if (this.isReady) {
 				this.f5(true)
+			}
+			if(this.$refs.tabbarMain){
+				this.$refs.tabbarMain.setcount(0);
 			}
 		}
 	}

+ 4 - 1
pages/user/index.vue

@@ -62,7 +62,7 @@
 				</view>
 			</view>
 		</view>
-			<Tabbar :current="2" :id="id" ></Tabbar>
+			<Tabbar :current="2" ref="tabbarMain"  :id="id" ></Tabbar>
  	</view>
 </template>
 
@@ -165,6 +165,9 @@
 				});
 			}
 		},onShow() {
+			if(this.$refs.tabbarMain){
+				this.$refs.tabbarMain.setcount(2);
+			}
 			if(this.isReady){
 				this.init()
 			}

+ 3 - 3
pagesFinance/detailed/details.vue

@@ -21,8 +21,8 @@
 				<h4>分润比例</h4>
 			</view>
 			<view class="details-row" v-for="(item,i) in sprList" :key="i">
-				<p>{{item.name}}</p>
-				<span>{{item.describe}}</span>
+			<p>{{item.merchantAccountName}}({{(item.disProportion*100).toFixed(2)}}%)</p>
+			<span>{{item.shareProfitAmount}}元</span>
 			</view>
 		
 		</view>
@@ -92,7 +92,7 @@
 					detailId:this.id
 				}).then((res) => {
 					this.detail=res.data	 
-					this.sprList=res.data.sprList	 
+					this.sprList=res.data.detailList	 
 					uni.hideLoading()
 					 
 				}).catch(error => {

+ 3 - 3
pagesFinance/detailed/index.vue

@@ -115,7 +115,7 @@
 							<p>{{item.createTime}}</p>
 						</view>
 						<view class="detailed-item-num" >
-							<h2>{{item.actualFee}}</h2>
+							<h2>{{item.shareProfitAmount}}</h2>
 							<u-icon name="arrow-right-s-line" custom-prefix="custom-icon" color="#B3B3B3" size="36"></u-icon>
 						</view>
 					</view>
@@ -124,7 +124,7 @@
 			
 			 
 		</view>
-		<Tabbar :current="1"></Tabbar>
+	<!-- 	<Tabbar :current="1"></Tabbar> -->
  	</view>
 </template>
 
@@ -286,7 +286,7 @@
 						
 							
 						}else{
-							var Amount=item.totalAmount 
+							var Amount=item.todaySPAmount 
 							
 							showMap.set(ktime,Amount)
 							

+ 44 - 14
pagesFinance/share/details.vue

@@ -4,28 +4,55 @@
 		<view class="details">
 			<view class="details-head">
 <!-- 				<u-icon name="charging-pile-fill" custom-prefix="custom-icon" color="#27B148" size="48"></u-icon>
- -->				<h4>{{showDateMoth(data.shareProfitDate)}}月分润收益</h4>
+ -->				<h4>{{detail.flowNo?detail.flowNo:'无充电单号'}}</h4>
 			</view>
 			<view class="details-main">
 				<view class="details-price">
-					<span>¥</span><h3>{{detail.shareProfitAllAmount}}</h3><span></span>
+					<h3>{{detail.income}}元</h3>
 				</view>
-				<p>分润金额(元)</p>
+				<p>分润金额</p>
 			</view>
 		</view>
 		
 		<view class="details">
 			<view class="details-title">
-				<h4>充电桩月收入明细</h4>
+				<h4>订单明细</h4>
 			</view>
 			<view class="details-row" >
-				<p>电费</p>
-				<span>¥{{detail.costAmount}}</span>
+				<p>订单金额</p>
+				<span>{{detail.actualFee  }}元</span>
 			</view>
 			<view class="details-row" >
-				<p>服务费</p>
-				<span>¥{{detail.surplusAmount}}</span>
+				<p>电费金额</p>
+				<span>{{detail.electricityAmount }}元</span>
 			</view>
+			<view class="details-row" >
+				<p>服务费金额</p>
+				<span>{{detail.surplusAmount}}元</span>
+			</view>
+			<view class="details-row" >
+				<p>总充电量</p>
+				<span>{{detail.electricQuantity/10000}}度</span>
+			</view>
+		
+				<view v-for="(item,i) in chargeDetails" :key="i">
+					<view class="details-row" >
+						<p>区间充电量({{item.startTime}}-{{item.endTime}})</p>
+						<span>{{item.kwh }}度</span>
+					</view>
+					<view class="details-row" >
+						<p>区间定价</p>
+						<span>{{(item.electricityPrice*100+item.servicePrice*100)/100}}元</span>
+					</view>
+					<view class="details-row" >
+						<p>区间定价组成</p>
+						<span>电价{{item.electricityPrice}}元/服务费{{item.servicePrice}}元</span>
+					</view>
+				</view>
+			
+			
+			
+			
 		</view>
 		
 		<view class="details">
@@ -33,8 +60,8 @@
 				<h4>分润明细</h4>
 			</view>
 			<view class="details-row" v-for="(item,i) in frmxList" :key="i">
-				<p>{{item.describe}}</p>
-				<span>{{item.shareProfitAmount}}</span>
+				<p>{{item.merchantAccountName}}({{(item.disProportion*100).toFixed(2)}}%)</p>
+				<span>{{item.shareProfitAmount}}</span>
 			</view>
 		
 		</view>
@@ -59,6 +86,7 @@
 	export default {
 		data() {
 			return {
+				chargeDetails:[],
 				data:{},
 				id:'',
 				frmxList:[
@@ -73,7 +101,7 @@
 		},
 		onLoad(op){
 			
-			this.data=op;
+			this.data.detailId=op.id;
 			this.getInfo()
 		},
 		methods: {
@@ -114,9 +142,11 @@
 				uni.showLoading({
 					title:"加载中",mask:true,
 				})
-				API.recordMonthDetailData(this.data).then((res) => {
-					this.detail=res.data.myMonth	 
-					this.frmxList=res.data.frmxList	 
+				API.recordDetailData(this.data).then((res) => {
+					this.detail=res.data	
+					 this.chargeDetails=JSON.parse(res.data.ChargeDetails)
+					 console.log( this.chargeDetails)
+					this.frmxList=res.data.detailList	 
 					uni.hideLoading()
 					 
 				}).catch(error => {

+ 52 - 20
pagesFinance/share/index.vue

@@ -10,12 +10,12 @@
 			<view class="popup-screen">
 				<view class="screen">
 					<view class="screen-item">
-						<view class="screen-head">查询年份</view>
+						<view class="screen-head">查询日期</view>
 						<view class="screen-main2">
 							
-							<u-picker  v-model="showdate" mode="time" :start-year="endyear" :end-year="startyear" :params="params"  @confirm="changedate"></u-picker >
+							<u-calendar v-model="showdate" mode="date" @change="changedate"></u-calendar>
 							
-							<u-input :value="year?year+'年':'选择年份筛选'" :type="type" :border="border" @click="showdate = true" />
+							<u-input :value="queryDate?queryDate:'选择时间筛选'" :type="type" :border="border" @click="showdate = true" />
 						<!-- 	
 							<u-action-sheet :list="actionSheetList" v-model="show" @click="actionSheetCallback"></u-action-sheet>
 						 --></view>
@@ -103,20 +103,23 @@
 				</view>
 				
 				<view class="detailed-list" v-for="(item ,index) in list"
-				@click="gotoUrl('pagesFinance/share/details?accountId='+item.merchantAccountId+'&deviceId='+item.deviceId+'&shareProfitDate='+item.shareProfitDate)"
+				@click="gotoUrl('pagesFinance/share/details?id='+item.id)"
 				:key="index">
 			 
-				
+					<view class="detailed-time"    v-if="item.show">
+						<p>{{item.showtime}}</p>
+						<p  >共收入 {{showMap.get(item.showtime)}}元</p>
+					</view>
 					<view class="detailed-item">
 						<view class="detailed-item-name">
-							<h2>{{showDateMoth(item.shareProfitDate)}}月分润收益</h2>
+							<h2>{{item.flowNo?item.flowNo:'无充电单号'}}</h2>
 							<p>{{item.stationName}}/{{item.deviceName}}</p>
 						</view>
 						<view class="detailed-item-name"  style="
 								width: 80px;
 							">
 							
-							<h2 style="   text-align: end;">{{item.shareProfitAllAmount}}</h2>
+							<h2 style="   text-align: end;">{{item.shareProfitAmount}}</h2>
 							<p>{{item.createTime?item.createTime.slice(0,10):''}}</p>
 						</view>
 					</view>
@@ -125,25 +128,25 @@
 			
 			 
 		</view>
-		<Tabbar :current="2"></Tabbar>
+		<Tabbar  ref="tabbarMain" :current="1"></Tabbar>
  	</view>
 </template>
 
 <script>
 	import Tabbar from '@/components/TabbarFinance.vue'
 	import * as API from '@/apis/finance.js'
-	// import {
-	// 	beforeTimeStamp,
-	// 	currentTimeStamp,
-	// 	parseUnixTime
-	// } from '@/utils'
+	import {
+		
+		currentTimeStamp,
+		parseUnixTime
+	} from '@/utils'
 	
 	export default {
 		data() {
 			return {
 				showdate: false,
 				startTime: "",
-							
+				queryDate:"",		
 				endTime: "",
 				selecttype:"",
 				selectstationId:"",
@@ -217,12 +220,19 @@
 		components: {
 			Tabbar
 		},
+		onShow(){
+			if(this.$refs.tabbarMain){
+				this.$refs.tabbarMain.setcount(1);
+			}
+		},
 		onReachBottom() {
 			if (this.list.length < this.recordsTotal) {
 				this.myLoadmore();
 			}
 		},
 		onLoad() {
+			// this.queryDate=parseUnixTime(new Date(),"{y}-{m}-{d}")
+			 
 			this.startyear=new Date().getFullYear()
 			console.log(this.startyear)
 			this.endyear=this.startyear-3
@@ -253,19 +263,22 @@
 			},
 			changedate(e) {
 				console.log(e)
-				this.year=e.year
+				this.queryDate=e.result
 				
 				
 			},
 			resetBtn(){
+			//	this.queryDate=parseUnixTime(new Date(),"{y}-{m}-{d}")
+				
 				this.year=""
-			 
+				 this.startTime=""
+				 this.endTime=""
 				this.selecttype=""
 				this.selectstationId=""
 				this.selectdeviceNo=""
 				this.pageIndex = 1;
 				this.form = {
-					year:"",
+					queryDate:"",
 				 
 					pageIndex: this.pageIndex,
 					type:this.selecttype,
@@ -282,7 +295,7 @@
 				this.pageIndex = 1;
 				
 				this.form = {
-					year:this.year,
+					queryDate:this.queryDate,
 					
 					pageIndex: this.pageIndex,
 					type:this.selecttype,
@@ -301,13 +314,32 @@
 				this.form.pageIndex=this.pageIndex
 				this.form.pageSize=20
 				
-				API.recordMonthData(this.form).then((res) => {
+				API.recordData(this.form).then((res) => {
 					
 					this.list = [
 						...this.list,
 						...res.data.data
 					];
-				
+					
+					var showMap=new Map()
+					this.list.forEach(item=>{
+						var ktime=item.createTime.split(" ")[0]
+						if(showMap.has(ktime)){
+							item.show=false;
+						
+							
+						}else{
+							var Amount=item.todaySPAmount 
+							
+							showMap.set(ktime,Amount)
+							
+							item.show=true;
+							item.showtime=ktime;
+						}
+					})
+					
+					this.showMap=showMap;
+					
 					this.recordsTotal = res.data.recordsTotal
 					uni.hideLoading()
 					

+ 275 - 44
pagesFinance/statistics/index.vue

@@ -3,52 +3,148 @@
 		<u-navbar :is-back="false" :border-bottom="false" :background="background">
 			<view class="navbar-tit">{{title}}</view>
 		</u-navbar>
-		<view class="statisticsData"  >
-			<view class="statisticsData-item">
-				<view class="statisticsData-head" @click="gotoUrl('pagesFinance/detailed/index')">
-					<p>今日充电流水(元)</p>
-					<u-icon name="arrow-right-s-line" custom-prefix="custom-icon" color="#B3B3B3" size="24"></u-icon>
+		<view class="statisticsData"  >
+			<view class="statisticsData-item">
+					<h3 style="font-size: 20px;">{{info.merchantAccountName}}</h3>
+			</view>
+			<view class="statisticsDataMain">
+				<view class="statisticsData-item">
 					
+					<view class="statisticsData-head" @click="gotoUrl('pagesFinance/detailed/index')">
+						<p>今日充电流水</p>
+						<u-icon name="arrow-right-s-line" custom-prefix="custom-icon" color="#637AA2" size="36"></u-icon>
+						
+					</view>
+					<view class="statisticsData-main">
+						<h2>{{indexData.todayAmount}}元</h2>
+					</view>
+					<view class="statisticsData-foot">
+						<p>昨日流水</p>
+						<h4>{{indexData.yesterdayAmount}}元</h4>
+					</view>
 				</view>
-				<view class="statisticsData-main">
-					<h2>{{indexData.todayAmount}}</h2>
+				<view class="statisticsData-item">
+					<view >
+						<h3>&nbsp;</h3>
+					</view>
+					<view class="statisticsData-head">
+						<p>今日充电笔数</p>
+					</view>
+					<view class="statisticsData-main">
+						<h2>{{indexData.todayEQNum}}</h2>
+					</view>
+					<view class="statisticsData-foot">
+						<p>本月流水</p>
+						<h4>{{indexData.thisMonthAmount}}元</h4>
+					</view>
 				</view>
-				<view class="statisticsData-foot">
-					<p>昨日流水</p>
-					<h4>{{indexData.yesterdayAmount}}</h4>
-				</view>
-			</view>
-			<view class="statisticsData-item">
-				<view class="statisticsData-head">
-					<p>今日充电笔数</p>
-				</view>
-				<view class="statisticsData-main">
-					<h2>{{indexData.todayEQNum}}</h2>
-				</view>
-				<view class="statisticsData-foot">
-					<p>本月流水</p>
-					<h4>{{indexData.thisMonthAmount}}</h4>
-				</view>
-			</view>
+			</view>
 		</view>
-		
-		
+		<u-popup v-model="popupShow" mode="top" height="80%">
+			<view class="popup-screen">
+				<view class="screen">
+					<view class="screen-item">
+						<view class="screen-head">查询日期</view>
+						<view class="screen-main2">
+							
+							<u-calendar v-model="showdate" mode="range" @change="changedate"></u-calendar>
+							
+							<u-input :value="startTime?startTime+'至'+endTime:'选择时间筛选'" :type="type" :border="border" @click="showdate = true" />
+						<!-- 	
+							<u-action-sheet :list="actionSheetList" v-model="show" @click="actionSheetCallback"></u-action-sheet>
+						 --></view>
+					</view>
+					<view class="screen-item">
+						<view class="screen-head">充电桩类型</view>
+						<view class="screen-main">
+							<view 
+							:class="{
+								active:selecttype==''
+							}" @click="selecttype=''"
+							class="screen-entry ">全部</view>
+							<view 
+							:class="{
+								active:selecttype=='0'
+							}" @click="selecttype='0'"
+							
+							class="screen-entry type1">自行车充电</view>
+							<view 
+							:class="{
+								active:selecttype=='2'
+							}" @click="selecttype='2'"
+							class="screen-entry type3">交流慢充</view>
+							<view 
+							:class="{
+								active:selecttype=='1'
+							}" @click="selecttype='1'"
+							class="screen-entry type2">直流快充</view>
+						</view>
+					</view>
+					<view class="screen-item">
+						<view class="screen-head">站点</view>
+						<view class="screen-main">
+							<view class="screen-entry  "
+							:class="{
+								active:selectstationId==''
+							}"
+							 @click="selectstationId=''"
+							>全部</view>
+							<view 
+							v-for="(item,i) in stationList" :key="i"
+							:class="{
+								active:selectstationId==item.id
+							}"
+							 @click="selectstationId=item.id,selectdeviceNo=''"
+							class="screen-entry" >{{item.name}}</view>
+						
+						</view>
+					</view>
+					<view 
+				
+					class="screen-item">
+						<view class="screen-head">桩号</view>
+						<view class="screen-main">
+							 
+							<view class="screen-entry  "
+							:class="{
+								active:selectdeviceNo==''
+							}"
+							 @click="selectdeviceNo=''"
+							>全部</view>
+							<view 
+							v-for="(item,i) in stationListSon" :key="i"
+							v-show="selectstationId?(selectstationId==item.stationId):true"
+							:class="{
+								active:selectdeviceNo==item.deviceNo
+							}"
+							
+							 @click="selectdeviceNo=item.deviceNo"
+							class="screen-entry" >{{item.name}}</view>
+						</view>
+					</view>
+				</view>
+				<view class="screen-foot">
+					<view class="screen-btn-l"
+					 @click="resetBtn" >重置</view>
+					<view class="screen-btn-r" @click="okbtn" >确定</view>
+				</view>
+			</view>
+		</u-popup>
 		
 		<view class="statisticsChart">
 			<view class="statisticsChart-head">
-				<h4  >充电桩收益占比</h4>
+				<h4  >流水占比</h4>
+				 <view class="navbar-screen" @click="popupShow = true"><span>筛选</span><u-icon name="filter-2-fill" custom-prefix="custom-icon" color="#b0b8c8" size="32"></u-icon></view>
 				 
 				
 			</view>
 			<view class="statisticsChart-main" >
-				<u-calendar v-model="showdate" mode="range" @change="changedate"></u-calendar>
-				
+<!-- 				<u-calendar v-model="showdate" mode="range" @change="changedate"></u-calendar>
+ -->				
 				<view class="statisticsChart-time" style="
     text-align: center; margin-bottom: 5px;
 ">
-					<p @click="showdate = true">{{startTime}} 至 {{endTime}} 				
-						<u-icon name="arrow-down-s-line" custom-prefix="custom-icon" color="#B3B3B3" size="36"></u-icon>
-</p>
+					<p >{{startTime}} 至 {{endTime}} </p>
 				
 				</view>
 					<u-subsection   :list="subsection" @change="changesub" :current="current" button-color="#2E7Dff"
@@ -61,7 +157,7 @@
 				</view>
 			</view>
 		</view>
-			<Tabbar :current="0"></Tabbar>
+			<Tabbar :current="0"  ref="tabbarMain" ></Tabbar>
 <!-- 		<u-tabbar v-model="current" :list="tabbarList" active-color="#185ac6"></u-tabbar>
  -->	</view>
 </template>
@@ -79,6 +175,13 @@
 	export default {
 		data() {
 			return {
+				form:{},
+				selecttype:"",
+				selectstationId:"",
+				selectdeviceNo:"",
+				
+				popupShow:false,
+				info:{},
 				title:"",
 				showdate: false,
 				startTime: "",
@@ -92,7 +195,8 @@
 						name: '笔数'
 					}
 				],
-			
+			stationList:[],
+			stationListSon:[],
 				tabbarList: [{
 						iconPath: "bar-chart-box-fill",
 						selectedIconPath: "bar-chart-box-fill",
@@ -122,12 +226,20 @@
 				background: {
 					background: 'none'
 				},
-			 
+			 value: '',
+			 type: 'select',
+			 show: false,
+			 border: true,
 			}
+		},
+		onShow(){
+			if(this.$refs.tabbarMain){
+				this.$refs.tabbarMain.setcount(0);
+			}
 		},
 		onLoad() {
 			this.title="收益统计"
-			var obj=this.carhelp.getPersonInfoPlus("merchantUser");
+			 this.info=this.carhelp.getPersonInfo("merchantUser")
 			 
 		},
 		components: {
@@ -137,9 +249,61 @@
 		onReady() {
 			this.startTime = parseUnixTime(beforeTimeStamp(7), '{y}-{m}-{d}')
 			this.endTime = parseUnixTime(currentTimeStamp(), '{y}-{m}-{d}')
-			this.getData()
+			this.getData()
+			this.getStation()
 		},
 		methods: {
+			getStation(bl) {
+				
+				API.stationList().then((res) => {
+					
+					this.stationList = res.data.stationList
+					this.stationListSon=res.data.deviceList	
+				}).catch(error => {
+					uni.showToast({
+					
+						title: error
+					})
+				})
+			},
+			resetBtn(){
+				this.startTime = parseUnixTime(beforeTimeStamp(7), '{y}-{m}-{d}')
+				this.endTime = parseUnixTime(currentTimeStamp(), '{y}-{m}-{d}')
+				
+			 
+			 
+				this.selecttype=""
+				this.selectstationId=""
+				this.selectdeviceNo=""
+				this.pageIndex = 1;
+				this.form = {
+				 
+				 
+					pageIndex: this.pageIndex,
+					type:this.selecttype,
+					stationId:this.selectstationId,
+					deviceNo:this.selectdeviceNo,
+				};
+				this.popupShow=false;
+				this.list = [];
+					this.getData()
+				
+			},
+			okbtn(){
+				this.popupShow=false;
+				this.pageIndex = 1;
+				
+				this.form = {
+				 
+					
+					pageIndex: this.pageIndex,
+					type:this.selecttype,
+					stationId:this.selectstationId,
+					deviceNo:this.selectdeviceNo,
+				};
+				this.list = [];
+					this.getData()
+			},
 			getData(){
 				uni.showLoading({
 					title: "加载中",
@@ -147,10 +311,10 @@
 				})
 				//this.form.pageIndex=this.pageIndex
 				
-				API.spIncomeStatistics({
-					startDate:this.startTime,
-					endDate:this.endTime 
-				}).then((res) => {
+				this.form.startDate=this.startTime,
+				this.form.endDate=this.endTime 
+				
+				API.spIncomeStatistics(this.form).then((res) => {
 					 
 					this.indexData = res.data
 					
@@ -173,7 +337,7 @@
 			changedate(e) {
 				this.startTime = e.startDate
 				this.endTime = e.endDate
-				this.getData()
+			
 				 
 			},
 			getPie() {
@@ -259,7 +423,69 @@
 		background-size: 100%;
 	}
 </style>
-<style lang="scss" scoped>
+<style lang="scss" scoped>
+	.popup-screen{
+		padding: 20px;
+		position: relative;
+		.screen{
+			padding-bottom: 30px;
+		}
+		.screen-item{
+			margin-bottom: 20px;
+			.screen-head{
+				margin-bottom: 8px;
+				font-size: 16px;
+			}
+			.screen-main{
+				display: flex;
+				//    display: -webkit-box;
+				flex-wrap: wrap;
+			
+			}
+			.screen-entry{
+				width: 29%;
+				padding:6px 0;
+								display: flex;
+								align-items: center;
+								justify-content: center;
+	
+	
+				background-color: #F2F5FA ;
+				text-align: center;
+				margin-bottom: 10px;
+				border-radius: 3px;
+			
+				margin-right: 6px;
+	
+			}
+			.screen-entry.active{
+				background-color: #185AC6;
+				color:#fff;
+			}
+		}
+		.screen-foot{
+			position: fixed;
+			left: 0;
+			right: 0;
+			bottom: 0;
+			display: flex;
+			height:50px;
+			border-top: 1px solid #ededed;
+			.screen-btn-l{
+				 background-color: #fff;
+				flex: 0.2;
+				text-align: center;
+				line-height: 50px;
+			}
+			.screen-btn-r{
+				flex: 0.8;
+				text-align: center;
+				line-height: 50px;
+				background-color: #185AC6;
+				color:#fff;
+			}
+		}
+	}
 	.navbar-tit {
 		color: #fff;
 		font-size: 20px;
@@ -271,10 +497,15 @@
 		margin: 16px;
 		padding: 16px;
 		border-radius: 8px;
-		display: flex;
+	
 		margin-top: 80px;
 	}
 
+	.statisticsDataMain {
+	
+		display: flex;
+	
+	}
 	.statisticsData-item {
 		flex: 1;
 

+ 7 - 4
pagesFinance/user/deviceList.vue

@@ -4,8 +4,8 @@
 		<view class="deviceDropdown">
 			<u-dropdown>
 				<u-dropdown-item v-model="value1" @change="change1" title="充电桩类型" :options="options1"></u-dropdown-item>
-				<u-dropdown-item v-model="value2" @change="change2" title="所属站点" :options="options2"></u-dropdown-item>
-				<u-dropdown-item v-model="value3" @change="change3" title="运行状态" :options="options3"></u-dropdown-item>
+<!-- 				<u-dropdown-item v-model="value2" @change="change2" title="所属站点" :options="options2"></u-dropdown-item>
+ -->				<u-dropdown-item v-model="value3" @change="change3" title="运行状态" :options="options3"></u-dropdown-item>
 			</u-dropdown>
 		</view>
 		<view class="deviceList"
@@ -25,8 +25,8 @@
 			}"
 			class="deviceList-item " >
 				<view class="deviceList-head">{{item.name}}</view>
-<!-- 				<view class="deviceList-main">{{item.deviceNo}}</view>
- -->				<view class="deviceList-foot">
+				<view class="deviceList-main">{{item.deviceNo}}</view>
+ 				<view class="deviceList-foot">
 					<view class="deviceList-label">{{ options0[item.type].label}}</view>
 					<view class="deviceList-label" 
 					:style="item.online?'':'color:red'"
@@ -134,6 +134,9 @@
 				this.myLoadmore();
 			}
 		},
+		onLoad(op) {
+				this.form.stationId=op.id
+		},
 		methods: {
 			change1(e){
 				this.form.type=e

+ 10 - 10
pagesFinance/user/index.vue

@@ -5,7 +5,7 @@
 				<u-avatar src="../../assets/img/head.png" size="140"></u-avatar>
 			</view>
 			<view class="userHead-text">
-				<h3>{{info.realName}}</h3>
+				<h3>{{info.merchantAccountName}}</h3>
 				<view class="userHead-text-position">
 					<u-icon name="account-pin-box-fill" custom-prefix="custom-icon" color="#fff" size="32"></u-icon>
 					<p>{{getPhone(info.phone)}}</p>
@@ -15,7 +15,7 @@
 		<view class="userData">
 			<view class="userData-item">
 				<view class="userData-data">{{home.deviceNumbers}}</view>
-				<view class="userData-foot" @click="gotoUrl('pagesFinance/user/deviceList')" >我的充电桩</view>
+				<view class="userData-foot" @click="gotoUrl('pagesFinance/user/stationsList')" >我的设备<span style="color: #307af6; margin-left: 5px;">查看</span></view>
 			</view>
 			<u-line color="#d9e0ec" length="60" direction="col" margin="10px"/>
 			<view class="userData-item">
@@ -27,7 +27,7 @@
 		<view class="userInfo">
 			<view class="userInfo-head"><p>可提现金额</p></view>
 			<view class="userInfo-main">
-				<h2>{{home.accountBalance}}</h2>
+				<h2>{{home.accountBalance}}</h2>
 				<view class="userInfo-btn"  v-if="info.status" @click="gotoUrl('pagesFinance/user/withdraw')">帐户提现</view>
 			</view>
 			<view class="userInfo-foot">
@@ -37,11 +37,11 @@
 				</view> -->
 				<view class="userInfo-item">
 					<p>冻结金额(提现中)</p>
-					<h4>{{home.waitingAmount}}</h4>
+					<h4>{{home.waitingAmount}}</h4>
 				</view>
 				<view class="userInfo-item">
 					<p>已提现</p>
-					<h4>{{home.withdrawnAmount}}</h4>
+					<h4>{{home.withdrawnAmount}}</h4>
 				</view>
 			</view>
 		</view>
@@ -84,7 +84,7 @@
 			</view>
 		</view>
 		
-			<Tabbar :current="3"></Tabbar>
+			<Tabbar :current="2"  ref="tabbarMain"></Tabbar>
  	</view>
 </template>
 
@@ -115,10 +115,7 @@
 		},
 		onLoad() {
 			this.info=this.carhelp.getPersonInfo("merchantUser")
-			var obj=this.carhelp.getPersonInfoPlus("merchantUser");
-			if(obj&&obj.role){
-				this.role=obj.role;
-			}
+			
 			
 			
 			console.log(this.info)
@@ -127,6 +124,9 @@
 			this.getHomePage()
 		},
 		onShow() {
+			if(this.$refs.tabbarMain){
+				this.$refs.tabbarMain.setcount(2);
+			}
 			this.getHomePage()
 		},
 		methods: {

+ 268 - 0
pagesFinance/user/stationsList.vue

@@ -0,0 +1,268 @@
+<template>
+	<view>
+		<u-navbar title="我的站点"></u-navbar>
+	 
+		<view class="deviceList" 	>
+		<view style="text-align: center;margin-top: 100px" v-if="!list.length">
+			<img src="@/assets/img/blankpage.png">
+			<view>查询为空</view>
+		</view>
+		
+		
+		
+			<view v-for="(item ,index) in list" :key="item.id"
+			@click="gotoUrl('pagesFinance/user/deviceList?id='+item.id)"
+		 
+			class="deviceList-item deviceList-bg1" >
+				<view class="deviceList-main">
+				 
+				<span class="btn12 " v-if="item.type=='1,2'" >快/慢</span>
+				<span class="btn12 btn1"  v-if="item.type=='1'"  >慢冲</span>
+				<span class="btn12 btn2" v-if="item.type=='2'" >快冲</span>
+				{{item.name}}</view>
+ 				<view class="deviceList-head">{{item.address}}<span style="float: right;">></span></view>
+				<view class="deviceList-foot">
+					
+					<view class="deviceList-label" style="color: #333333;"  >总数{{item.totalNum}}</view>
+					<view class="deviceList-label" style="color: #7a68f6;" v-if="item.fastNum"  >/直流{{item.fastNum}}</view>
+					
+					<view class="deviceList-label" style="color: #5cbe7d;"  v-if="item.slowNum" >/交流{{item.slowNum}}</view>
+					
+					
+				<!-- 	<view class="deviceList-label">{{item.roleName}}</view> -->
+				</view>
+			</view>
+			<u-divider v-if="list.length&&list.length==recordsTotal" color="#B6BDC3" style="margin-top:20px;" bg-color="#f4f0f0">已经到底了</u-divider>
+			
+		 
+		</view>
+	</view>
+</template>
+
+<script>
+	import * as API from '@/apis/finance.js'
+	
+	export default {
+		data() {
+			return {
+				form: {
+				
+				},
+				startDate:'',
+				endDate:'',
+				pageIndex: 1,
+				recordsTotal: 0,
+				list: [],
+				value1: -1,
+				value2: -1,
+				value3: -1,
+				stationList:[],
+				options0: [
+					{
+							label: '全部',
+							value: -1,
+						},
+					{
+						label: '自行车充电',
+						value: 0,
+					},
+					{
+						label: '交流慢充',
+						value: 2,
+					},
+					{
+						label: '直流快充',
+						value: 1,
+					}
+				],
+				options1: [{
+						label: '全部',
+						value: '-1',
+					},
+					{
+						label: '自行车充电',
+						value: 0,
+					},
+					{
+						label: '交流慢充',
+						value: 2,
+					},
+					{
+						label: '直流快充',
+						value: 1,
+					}
+				],
+				options2: [
+				],
+				options3: [
+					{
+						label: '全部',
+						value: -1,
+					},
+					{
+						label: '在线',
+						value: 1,
+					},
+					{
+						label: '离线',
+						value: 0,
+					},
+				],
+			}
+		},
+		onReachBottom() {
+			if (this.list.length < this.recordsTotal) {
+				this.myLoadmore();
+			}
+		},
+		methods: {
+			change1(e){
+				this.form.type=e
+				if(e==-1){
+					this.form.type=""
+				}
+				this.getList(true)
+			},
+			change2(e){
+				this.form.stationId=e
+				if(e==-1){
+					this.form.stationId=""
+				}
+				this.getList(true)
+			},
+			change3(e){
+				this.form.onlineStatus=e
+				if(e==-1){
+					this.form.onlineStatus=""
+				}
+				this.getList(true)
+			},
+			getStation() {
+				
+				API.stationList().then((res) => {
+					this.options2.push({
+						label: '全部',
+						value:-1,
+					})
+					this.stationList = res.data.stationList
+					this.stationList.forEach(item=>{
+						this.options2.push({
+							label: item.name,
+							value: item.id,
+						})
+					})
+					
+				}).catch(error => {
+					uni.showToast({
+					
+						title: error
+					})
+				})
+			},
+		myLoadmore() {
+
+				this.pageIndex += 1;
+				this.getList()
+			},
+			getList(bl) {
+				
+				uni.showLoading({
+					title: "加载中",
+					mask: true,
+				})
+				if (bl) {
+					this.list = [];
+					this.pageIndex = 1;
+				}
+				this.form.pageIndex= this.pageIndex
+				
+				API.stationsList(this.form).then((res) => {
+					
+					this.list = [
+						...this.list,
+						...res.data.data
+					];
+				 
+					uni.hideLoading()
+
+				}).catch(error => {
+					uni.showToast({
+
+						title: error
+					})
+				})
+			},
+			onReady() {
+				//this.getStation()
+				this.getList()
+				
+			}
+		}
+	}
+</script>
+<style>
+	page{
+		background-color: #F7F7F7;
+	}
+</style>
+<style lang="scss" scoped>
+	.btn12{
+		color: #fff;
+		background-color: #449ca8;
+		font-size: 16px;
+		    border-radius: 50px;
+		    padding: 1px 5px;
+	}
+	.btn1{
+	
+		background-color: #5cbe7d;
+		
+	}
+	.btn2{
+	
+		background-color: #7a68f6;
+		
+	}
+	.deviceDropdown{
+		background-color: #fff;
+	}
+	.deviceList-item{
+		margin: 16px;
+		border-radius: 8px;
+		.deviceList-head{
+			color: #9e9e9e;
+			font-size: 16px;
+			padding: 8px 16px;
+		}
+		.deviceList-main{
+			font-size: 20px/*  */;
+			padding:5px 16px 0px 16px;
+			font-weight: bold;
+		}
+		.deviceList-foot{
+			display: flex;
+			align-items: center;
+			flex-wrap: wrap;
+			padding: 0 16px 16px;
+			.deviceList-label{
+				// background-color: #F0F2F4 ;
+				// padding: 4px 10px;
+				margin: 1px;
+				border-radius: 4px;
+			}
+		}
+	}
+	.deviceList-bg1{
+		//background:url(../../assets/img/charging_type_fast.png) no-repeat #fff;
+		background-size:100%;
+		background-color: #ffffff ;
+	}
+	.deviceList-bg2{
+		background:url(../../assets/img/charging_type_slow.png) no-repeat #fff;
+		background-size:100%;
+	}
+	.deviceList-bg3{
+		background:url(../../assets/img/charging_type_bike.png) no-repeat #fff;
+		background-size:100%;
+	}
+</style>