Browse Source

2021-5-11 今日新增

hwq 3 years ago
parent
commit
eb9d5f467c

+ 1 - 1
App.vue

@@ -30,7 +30,7 @@ export default {
 				try {
 					obj.url =obj.baseURL + e.data.apk;
 					obj.versionFu = e.data.version_code;
-
+					console.log(e)
 					let ver = plus.runtime.versionCode;
 
 					

+ 2 - 2
manifest.json

@@ -4,8 +4,8 @@
     // __UNI__6FC8B70
     // "appid" : "__UNI__6FC8B70",
     "description" : "",
-    "versionName" : "1.0.4",
-    "versionCode" : 104,
+    "versionName" : "1.0.5",
+    "versionCode" : 105,
     "transformPx" : false,
     "app-plus" : {
         /* 5+App特有相关 */

+ 8 - 0
pages.json

@@ -133,6 +133,14 @@
 				"enablePullDownRefresh": true
 			}
 		},
+		{
+			"path": "pages/finance/today",
+			"style": {
+				"navigationBarTitleText": "今日业绩",
+				"navigationBarBackgroundColor":"#5771DF",
+				"navigationBarTextStyle": "white"
+			}
+		},
 		{
 			"path": "pages/finance/xieyi",
 			"style": {

+ 7 - 2
pages/finance/allMiner.vue

@@ -26,7 +26,7 @@
 						<view class="level">V{{ls.level}}</view>
 					</view>
 				</view>
-				<view class="nav flex">
+				<view class="nav flex" v-show="page != 1 || isLast">
 					<view class="next" @click="last" v-if="page != 1">
 						上一页
 					</view>
@@ -205,13 +205,18 @@ export default {
 		height: 500rpx;
 	}
 	.nav{
+		position: fixed;
+		bottom: 50rpx;
+		left: 0;
+		right: 0;
+		width: 100%;
 		.next{
 			margin: 40rpx;
 			width: 50%;
 			background-color: #5771DF;
 			color: #FFFFFF;
 			text-align: center;
-			padding:26rpx 0rpx;
+			padding:10rpx 0rpx;
 			border-radius: 50rpx;
 		}
 	}

+ 37 - 5
pages/finance/recharge.vue

@@ -18,8 +18,11 @@
 		</view>
 		
 		<view class="image-box" v-if="charge != 0">
+			<!-- <view class="item flex"  v-for="(item,index) in wayList" :key="index">
+				<view class="way" @click="chose(item)">{{item}}</view>
+			</view> -->
 			<view class="tuijianbox" >
-				<view class="item" @click="gogo()" >
+				<view class="item"  @click="gogo()" >
 					<image v-if="idx == 2" src="../../static/img/befor.png"></image>
 					<image v-else src="../../static/img/after.png"></image>
 				</view>
@@ -104,6 +107,7 @@
 		},
 		data() {
 			return {
+				wayList: [],
 				moneyTypeList: [],
 				charge: 0,
 				logo: '',
@@ -136,7 +140,6 @@
 				onval: true,
 				loadMake: true,
 				usingComponents: true,
-				way: '',
 			};
 		},
 		onLoad(option) {
@@ -159,7 +162,7 @@
 				}
 			}
 			this.moneyType();
-			
+			console.log(this.wayList)
 			
 		},
 		onShow() {
@@ -174,6 +177,7 @@
 				}) => {
 					obj.moneyTypeList = data;
 					obj.address = obj.moneyTypeList[1].wallet.address_TRC20;
+					obj.wayList = obj.moneyTypeList[0].way.split(',');
 					if (obj.logo == '') {
 						this.charge = obj.moneyTypeList[0].charge;
 						obj.logo = obj.moneyTypeList[0].LOGO;
@@ -286,7 +290,8 @@
 				this.mark = options.mark;
 				this.addr = options.wallet.address;
 				this.ids = options.wallet.id;
-				
+				this.wayList = options.way.split(',');
+				console.log(this.wayList)
 			},
 			useOutClickSide() {
 				this.$refs.easySelect.hideOptions && this.$refs.easySelect.hideOptions()
@@ -297,7 +302,6 @@
 			},
 			gogo() {
 				this.idx = 1;
-				
 			},
 			qrR(res) {
 				this.src = res;
@@ -305,6 +309,9 @@
 			creatQrcode() {
 				this.$refs.qrcode._makeCode();
 			},
+			chose(item) {
+				
+			}
 		}
 	};
 </script>
@@ -362,6 +369,24 @@
 			height: 300rpx;
 			border-radius: 15rpx;
 		}
+		.item {
+			margin-left: 40rpx;
+			font-size: 20rpx;
+			position: relative;
+			line-height: 40rpx;
+			color: #FFFFFF;
+			image {
+				width: 150rpx;
+				height: 100rpx;
+			}
+			.way {
+				text-align: center;
+				line-height: 80rpx;
+				height: 80rpx;
+				width: 100rpx;
+				border: 1 solid #000000;
+			}
+		}
 	}
 
 	.from-box {
@@ -526,6 +551,13 @@
 				width: 150rpx;
 				height: 100rpx;
 			}
+			.way {
+				text-align: center;
+				line-height: 1;
+				height: 80rpx;
+				width: 100rpx;
+				border: 1 solid #FFFFFF;
+			}
 		}
 	}
 	.qidai {

+ 235 - 0
pages/finance/today.vue

@@ -0,0 +1,235 @@
+<template>
+	<view class="container">
+		<view class="list-box flex">
+			<view class="list-tpl">
+				<view class="num">{{data.count || 0}}</view>
+				<view class="name">新增会员数</view>
+			</view>
+			<view class="list-tpl">
+				<view class="num">{{people_num || 0}}</view>
+				<view class="name">新增算力数</view>
+			</view>
+		</view>
+		<view class="list-cell" v-if="list.length > 0">
+			<view class="cell-name flex">
+				<view class="title">成员信息</view>
+				<view class="title-box flex">
+					<view class="title">等待算力</view>
+					<view class="title">今日新增</view>
+					<!-- <view class="title">等级</view> -->
+				</view>
+			</view>
+			<view class="cell-box flex" v-for="(ls,index) in list" :key='index'>
+				<view class="cell-tit flex_item">
+					<image :src="ls.avatar"></image>
+					<view class="tit-box">
+						<view class="tit-tpl clamp">{{ls.nickname}}</view>
+						<view class="tit-tip">{{ls.phone}}</view>
+					</view>
+				</view>
+				<view class="flex num-box">
+					<view class="num clamp">{{ls.wait_mining}}T</view>
+					<view class="num clamp">{{ls.today_mining}}T</view>
+					<!-- <view class="level">V{{ls.level}}</view> -->
+				</view>
+			</view>
+			<view class="nav flex" v-show="page != 1 || isLast">
+				<view class="next" @click="last" v-if="page != 1">
+					上一页
+				</view>
+				<view class="next" v-else>
+					已经是第一页了
+				</view>
+				<view class="next" v-if="isLast" @click="next">
+					下一页
+				</view>
+				<view class="next" v-else>
+					已经是最后一页了
+				</view>
+			</view>
+		</view>
+		<view class="empty-box" v-show="list.length === 0"><empty></empty></view>
+	</view>
+</template>
+
+<script>
+import { miner } from '@/api/finance.js';
+import empty from '@/components/empty';
+export default {
+	components: {
+		empty
+	},
+	data() {
+		return {
+			page: 1,
+			limit: 5,
+			data:'',
+			list:'',
+			isLast: true,
+			people_num: '',
+		};
+	},
+	onLoad(option){
+		this.people_num = option.num
+		this.loadData();
+		this.loadDataNext();
+	},
+	onShow() {
+	},
+	methods: {
+		// 请求载入数据
+		async loadData() {
+			let obj = this;
+			miner({
+				page: obj.page,
+				limit: obj.limit,
+				new: 1,
+			}).then(({ data }) => {
+				obj.data = data;
+				obj.list = data.list;
+			   console.log(obj.list)
+			});
+		},
+		async loadDataNext() {
+			let obj = this;
+			console.log(obj.page)
+			miner({
+				page: obj.page + 1,
+				limit: obj.limit,
+				new: 1,
+			}).then(({ data }) => {
+				if(data.list.length === 0){
+					obj.isLast = false;
+				}else{
+					obj.isLast = true;
+				}
+			});
+		},
+		nav(url){
+			uni.navigateTo({
+				url:url
+			})
+		},
+		next(){
+			this.page = this.page + 1;
+			this.loadData();
+			this.loadDataNext();
+		},
+		last(){
+			if(this.page != 1){
+				this.page = this.page - 1;
+			}
+			this.loadData();
+			this.loadDataNext();
+		}
+	}
+};
+</script>
+
+<style lang="scss">
+page {
+	min-height: 100%;
+	background-color: #ffffff;
+	.container {
+		width: 100%;
+	}
+}
+.list-box{
+	width: 100%;
+	padding: 50rpx 41rpx;
+	padding-top: 80rpx !important;
+	background-color: #5771DF;
+	position: relative;
+	.list-title{
+		position: absolute;
+		top: 80rpx;
+		color: #FFFFFF;
+		left: 40%;
+		font-size: 36rpx;
+	}
+	.list-tpl{
+		background-color: #FFFFFF;
+		width: 314rpx;
+		height: 168rpx;
+		text-align: center;
+		padding-top:40rpx;
+		border-radius: 15rpx;
+		.num{
+			font-size: 36rpx;
+			font-weight: bold;
+			color: #333333;
+			padding-bottom: 15rpx;
+		}
+		.name{
+			font-size: 26rpx;
+			font-weight: 500;
+			color: #999999;
+		}
+	}
+}
+.list-cell{
+		padding: 40rpx 25rpx;
+		.cell-name{
+			padding:50rpx 50rpx;
+			.title-box{
+				width: 60%;
+			}
+		}
+		.cell-box{
+			margin-bottom: 94rpx;
+			.cell-tit{
+				width: 36%;
+				image{
+					width: 80rpx;
+					height: 80rpx;
+					border-radius: 100%;
+				}
+				.tit-box{
+					padding-left: 15rpx;
+					width: 70%;
+					.tit-tpl{
+						font-size: 30rpx;
+						font-weight: 500;
+						color: #333333;
+					}
+					.tit-tip{
+						font-size: 24rpx;
+						font-weight: 500;
+						color: #999999;
+						padding-top: 20rpx;
+					}
+				}
+			}
+			.num-box{
+				width: 64%;
+				.num{
+					width: 50%;
+					text-align: center;
+				}
+				.level{
+					background-color: #FED82F;
+					border-radius: 25rpx;
+					padding: 8rpx 50rpx;
+					font-size: 26rpx;
+				}
+			}
+		}
+	}
+.empty-box{
+	margin-top: 60rpx;
+	width: 100%;
+	height: 500rpx;
+}
+.nav{
+	.next{
+		margin: 40rpx;
+		width: 50%;
+		background-color: #5771DF;
+		color: #FFFFFF;
+		text-align: center;
+		padding:10rpx 0rpx;
+		border-radius: 50rpx;
+	}
+}
+</style>
+

+ 7 - 2
pages/index/index.vue

@@ -46,8 +46,8 @@
 					<view class="tpl money">¥{{ls.price}}</view>
 					<view class="tip-box">
 						<image src="../../static/img/img30.png"></image>
-						<view class="tip" v-if="ls.up > 0">{{ls.up * 100}}%</view>
-						<view class="tip grenn" v-if="ls.up == 0 || ls.up < 0">{{ls.up * 100}}%</view>
+						<view class="tip" v-if="ls.up > 0">{{ls.up }}%</view>
+						<view class="tip grenn" v-if="ls.up == 0 || ls.up < 0">{{ls.up }}%</view>
 					</view>
 				</view>
 			</view>
@@ -108,7 +108,12 @@ export default {
 		moneyType(){
 			let obj = this;
 			moneyType({index:1}).then(({ data }) => {
+				console.log(data)
 			   obj.list = data;
+			   obj.list.forEach((e,index) => {
+				   
+				   e.up = parseFloat(e.up*100).toFixed(2);
+			   });
 			});
 		},
 		/**

+ 11 - 3
pages/user/myTeam.vue

@@ -21,7 +21,7 @@
 					<view class="cell">{{data.group_achievenent || 0}}T</view>
 					<view class="cell-title">我的业绩</view>
 				</view>
-				<view class="info-cell" >
+				<view class="info-cell" @click="navto()">
 					<view class="cell">{{data.today_achievement || 0}}T</view>
 					<view class="cell-title">今日新增业绩</view>
 				</view>
@@ -49,7 +49,7 @@
 						<view class="level">V{{ls.level}}</view>
 					</view>
 				</view>
-				<view class="nav flex" v-show="page == 1 && isLast">
+				<view class="nav flex" v-show="page != 1 || isLast">
 					<view class="next" @click="last" v-if="page != 1">
 						上一页
 					</view>
@@ -116,6 +116,7 @@ export default {
 				}else{
 					obj.isLast = true;
 				}
+				console.log(this.isLast)
 			});
 		},
 		nav(url){
@@ -123,10 +124,17 @@ export default {
 				url:url
 			})
 		},
+		navto(url){
+			uni.navigateTo({
+				url:'/pages/finance/today?num=' + this.data.today_achievement
+			})
+		},
 		next(){
 			this.page = this.page + 1;
 			this.loadData();
 			this.loadDataNext();
+			console.log(this.page)
+			
 		},
 		last(){
 			if(this.page != 1){
@@ -261,7 +269,7 @@ page {
 		background-color: #5771DF;
 		color: #FFFFFF;
 		text-align: center;
-		padding:26rpx 0rpx;
+		padding:10rpx 0rpx;
 		border-radius: 50rpx;
 	}
 }

File diff suppressed because it is too large
+ 0 - 1
unpackage/dist/dev/app-plus/app-config-service.js


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/app-plus/app-service.js


File diff suppressed because it is too large
+ 292 - 51
unpackage/dist/dev/app-plus/app-view.js


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/app-plus/manifest.json


BIN
unpackage/dist/dev/app-plus/static/.DS_Store


Some files were not shown because too many files changed in this diff