浏览代码

2024-4-29

cmy 10 月之前
父节点
当前提交
f5488b3ccb

+ 9 - 0
api/game.js

@@ -130,4 +130,13 @@ export  function comfirLog(data) {
 	});
 }
 
+//充值接口
+export  function rechargeUSDT(data) {
+	return request({
+		url: `/api/recharge`,
+		method: 'post',
+		data
+	});
+}
+
 

+ 3 - 3
manifest.json

@@ -1,9 +1,9 @@
 {
     "name" : "STAR",
-    "appid" : "__UNI__5B076CD",
+    "appid" : "__UNI__0A11003",
     "description" : "",
-    "versionName" : "1.0.0",
-    "versionCode" : 100,
+    "versionName" : "1.1.2",
+    "versionCode" : 112,
     "transformPx" : false,
     "app-plus" : {
         /* 5+App特有相关 */

+ 8 - 0
pages.json

@@ -8,6 +8,14 @@
 				"navigationStyle": "custom"
 			}
 		},
+		// 首页
+		{
+			"path": "pages/index/downLoad",
+			"style": {
+				"navigationBarTitleText": "自动更新",
+				"navigationStyle": "custom"
+			}
+		},
 		// 质押
 		{
 			"path": "pages/index/pledge",

+ 157 - 0
pages/index/downLoad.vue

@@ -0,0 +1,157 @@
+<template>
+	<view class="content">
+		<view class="main">
+			<view class="main-bg"><image src="../../static/img/download.png" mode=""></image></view>
+			<view class="title">软件更新</view>
+			<view class="jdt">
+				<u-line-progress :percentage="percent"  inactiveColor="#f5957d" activeColor="#fd6f3f"></u-line-progress>
+			</view>
+			<view class="num">{{ percent }}%</view>
+			<view class="tipSpan">软件更新中,请勿断开相框电源</view>
+			<!-- <view class="btn" @click="cancelDown()">取消更新</view> -->
+		</view>
+	</view>
+</template>
+
+<script>
+	
+	
+export default {
+	data() {
+		return {
+			dtask: '',
+			percent: 0
+		};
+	},
+	onLoad(opt) {
+		this.downApp(opt.apk);
+	},
+	onShow() {},
+	onReachBottom() {},
+	onReady() {},
+	methods: {
+		downApp(version) {
+			if(!(version.indexOf("http")>-1)){
+				version = this.$store.state.baseURL+version
+			}
+			this.dtask = plus.downloader.createDownload(version);
+			this.dtask.addEventListener('statechanged', this.onStateChanged, false);
+			this.dtask.start();
+		},
+		cancelDown() {
+			this.dtask.abort();
+			uni.navigateTo({
+				url: '/pages/index/index'
+			});
+		},
+		onStateChanged(download, status) {
+			let prg = 0;
+			console.log(this.percent);
+			switch (download.state) {
+				case 1:
+					// showLoading.setTitle("正在下载");
+					break;
+				case 2:
+					// showLoading.setTitle("已连接到服务器");
+					break;
+				case 3:
+					prg = parseInt(
+						//下载的进度
+						(parseFloat(download.downloadedSize) / parseFloat(download.totalSize)) * 100
+					);
+					// showLoading.setTitle("版本更新,正在下载" + prg + "% ");
+					this.percent = prg;
+					break;
+				case 4:
+					this.installApp(download.filename);
+					// plus.nativeUI.closeWaiting(); //关闭系统提示框
+					this.showProcess = false;
+					//下载完成
+					break;
+			}
+		},
+		installApp(path) {
+			plus.nativeUI.showWaiting('安装升级包...');
+			plus.runtime.install(
+				path,
+				{},
+				function() {
+					plus.nativeUI.closeWaiting();
+					uni.showToast({
+						icon: 'none',
+						title: '升级完成,准备重新载入'
+					});
+					setTimeout(_ => {
+						uni.hideToast();
+						plus.runtime.restart();
+					}, 1000);
+				},
+				function(e) {
+					plus.nativeUI.closeWaiting();
+					plus.nativeUI.alert('安装升级包失败[' + e.code + ']:' + e.message);
+				}
+			);
+		}
+	}
+};
+</script>
+
+<style lang="scss">
+page,
+.content {
+	min-height: 100%;
+	height: auto;
+	background-color: #FFF;
+}
+
+.main {
+	margin-top: 100rpx;
+	.main-bg {
+		margin: 0 auto;
+		width: 550rpx;
+		height: 340rpx;
+		image {
+			width: 100%;
+			height: 100%;
+		}
+	}
+	.title {
+		text-align: center;
+		color: #000000;
+		font-size: 40rpx;
+		margin-top: 20rpx;
+		font-family: PingFang SC;
+		font-weight: bolder;
+	}
+	.jdt {
+		width: 550rpx;
+		margin: 20rpx auto;
+	}
+	.num {
+		text-align: center;
+		color: #ff7575;
+		font-size: 30rpx;
+		font-family: PingFang SC;
+		font-weight: 500;
+	}
+	.tipSpan {
+		margin-top: 20rpx;
+		text-align: center;
+		color: #ababab;
+		font-size: 30rpx;
+		font-family: PingFang SC;
+		font-weight: 500;
+	}
+	.btn {
+		display: flex;
+		justify-content: center;
+		align-items: center;
+		color: #ffffff;
+		width: 400rpx;
+		height: 80rpx;
+		background: #ff4c4c;
+		margin: 20rpx auto;
+		border-radius: 20rpx;
+	}
+}
+</style>

+ 16 - 12
pages/index/index.vue

@@ -27,15 +27,15 @@
 				<image src="/static/image/img06.png" style="width: 123rpx;height: 73rpx;" mode="widthFix"></image>
 				<view class="navName">充值</view>
 			</view>
-			<view class="navTpl" @click="openurl('/pages/index/personal')">
+			<!-- <view class="navTpl" @click="openurl('/pages/index/personal')">
 				<image src="/static/image/img07.png" style="width: 123rpx;height: 73rpx;" mode="widthFix"></image>
 				<view class="navName">实名认证</view>
-			</view>
+			</view> -->
 			<view class="navTpl" @click="openurl('/pages/user/set/transaction')">
 				<image src="/static/image/img08.png" style="width: 123rpx;height: 73rpx;" mode="widthFix"></image>
 				<view class="navName">交易密码</view>
 			</view>
-			<view class="navTpl" @click="openurl('/pages/user/collection')">
+			<view class="navTpl" @click="openurl('/pages/user/set/bindBank')">
 				<image src="/static/image/img09.png" style="width: 123rpx;height: 73rpx;" mode="widthFix"></image>
 				<view class="navName">收款信息</view>
 			</view>
@@ -60,20 +60,26 @@
 				</view>
 			</view>
 		</view>
-		<image src="/static/image/img11.png" style="width: 692rpx;padding-top: 31rpx;height: 179rpx;" mode="widthFix"></image>
+		<navigator open-type='switchTab' url="/pages/index/pledge">
+			<image src="/static/image/img11.png" style="width: 692rpx;padding-top: 31rpx;height: 179rpx;" mode="widthFix"></image>
+		</navigator>
 		<!-- <view class="titleBox">
 			<view class="titleTip">累计成交量</view>
 		</view> -->
-		<!-- <view class="flex totalBox">
+		<view class="flex totalBox">
 			<view class="totalTpl">
-				<view class="totalNum">10,910,000<text>USDT</text></view>
-				<view class="totalName">累计买入</view>
+				<view class="totalNum">{{baseData.success_num||0}}</view>
+				<view class="totalName">24小时成交量(U)</view>
 			</view>
 			<view class="totalTpl">
-				<view class="totalNum">10,910,000<text>USDT</text></view>
-				<view class="totalName">累计卖出</view>
+				<view class="totalNum">{{baseData.success_order||0}}</view>
+				<view class="totalName">24小时成单量</view>
 			</view>
-		</view> -->
+			<view class="totalTpl">
+				<view class="totalNum">{{baseData.success_ratio||0}}</view>
+				<view class="totalName">交易成功率</view>
+			</view>
+		</view>
 		<view class="titleBox">
 			<view class="titleTip">平台优势</view>
 		</view>
@@ -421,8 +427,6 @@
 		padding-top: 30rpx;
 		.totalTpl{
 			width: 45%;
-			background: url('../../static/image/img18.png') no-repeat;
-			background-size: 100% 100%;
 			text-align: center;
 			padding: 45rpx 0rpx;
 			.totalNum{

+ 3 - 0
pages/index/order.vue

@@ -86,6 +86,9 @@
 					[{
 						name: '挂出',
 						status: 1
+					},{
+						name: '待上传',
+						status: 3
 					},{
 						name: '待确认',
 						status: 5

+ 27 - 4
pages/index/orderDetail.vue

@@ -6,9 +6,12 @@
 				<view class="">支付信息</view>
 			</view>
 			<view class="infoBox">
-				<view class="tplAddr">银行:<text>{{baseData.bank}}</text></view>
-				<view class="tplAddr">支行:<text>{{baseData.bank_name}}</text></view>
-				<view class="tplAddr">卡号:<text>{{baseData.bank_code}}</text></view>
+				<view class="tplAddr" v-if="baseData.bank=='wx'">收款:<text>微信</text></view>
+				<view class="tplAddr" v-else-if="baseData.bank=='alipay'">收款:<text>支付宝</text></view>
+				<view class="tplAddr" v-else>银行:<text>{{baseData.bank}}</text></view>
+				<view class="tplAddr" v-if="baseData.bank_name">支行:<text>{{baseData.bank_name}}</text></view>
+				<view class="tplAddr" v-if="baseData.bank_code">卡号:<text>{{baseData.bank_code}}</text></view>
+				<view class="tplAddr" v-if="baseData.account">账号:<text>{{baseData.account}}</text></view>
 				<view class="tplAddr">姓名:<text>{{baseData.real_name}}</text></view>
 				<view class="tplAddr">手机号:<text>{{baseData.phone}}</text></view>
 				<view class="tplAddr">数量:<text>{{baseData.num*1}}{{baseData.money_type}}</text></view>
@@ -16,7 +19,17 @@
 				<view class="tplAddr">总价:<text>¥{{allmoney}}</text></view>
 			</view>
 		</view>
-		
+		<view class="login_text"  v-if="baseData.qrcode">
+			<view class="example-title flex_item">
+				<view class="titleTip"></view>
+				<view class="">收款码</view>
+			</view>
+			<view class="login_input">
+				<view class="login_name">
+					<image class="showQrcode" mode="scaleToFill" :src="baseData.qrcode" @click="openshow"></image>
+				</view>
+			</view>
+		</view>
 		<view class="login_text" v-if="baseData.status!=1">
 			<view class="example-title flex_item">
 				<view class="titleTip"></view>
@@ -71,6 +84,16 @@
 			this.getData();
 		},
 		methods: {
+			// 预览图片
+			openshow(){
+				console.log('预览');
+				uni.previewImage({
+					urls:[this.baseData.qrcode],
+					fail(err){
+						console.log(err);
+					}
+				})
+			},
 			//获取数据
 			getData() {
 				const that = this;

+ 6 - 0
pages/index/personal.vue

@@ -43,6 +43,7 @@
 				vcode: '',
 				front_pic: '',
 				back_pic: '',
+				loding:false,
 			};
 		},
 		onLoad() {
@@ -105,6 +106,10 @@
 					this.$api.msg('请上传身份证正反面');
 					return;
 				}
+				if(this.loding){
+						return
+				}
+				this.loding = true;
 				real_check({
 						name: this.username,
 						id_card: this.idCard,
@@ -112,6 +117,7 @@
 						back_pic: this.back_pic,
 					})
 					.then(function(e) {
+						uni.navigateBack();
 						uni.showToast({
 							title: e.msg,
 							duration: 1500,

+ 205 - 90
pages/index/pledge.vue

@@ -30,14 +30,52 @@
 					<view class="tip1">单价不得大于参考汇率</view>
 				</view>
 			</view>
+			<view class="bankList flex" v-if="actionitem.length > 0" v-for="item,index in actionitem">
+				<view class="infoTpl">
+					<view class="tplName flex_item">
+						<image :src="item.type == 'bank'?'/static/image/bank.png':
+						item.type == 'wx'?'/static/image/wx.png':'/static/image/alipay.png'" style="width: 40rpx;height: 40rpx"
+							mode="widthFix"></image>
+						<view class="titleBox">
+							<view class="tip">{{item.name}}</view>
+						</view>
+					</view>
+				</view>
+				<view class="det" @click="showBank = true">
+					修改
+				</view>
+			</view>
 			<view class="submission">
 				<button class="golden" type="golden" hover-class="none" @click="submission">一键卖币</button>
 			</view>
 			<view class="tips">*参考汇率{{baseData.us_price}}</view>
 		</view>
-		<u-action-sheet :show="showBank" :actions="bankList" title="请选择银行卡"
-			@close="showBank = false" @select="bankSelect">
-		</u-action-sheet>
+		<uni-popup ref="popup" :is-mask-click="false" type="bottom" @maskClick="showBank = false">
+			<view class="alertBottom">
+				<view class="flex alertTitle">
+					<view class="alertTitleName">
+						选择支付方式
+					</view>
+					<uni-icons type="close" size="28" @click="showBank = false"></uni-icons>
+				</view>
+				<view class="bankList flex" @click="bankSelect(item)" v-if="bankList.length > 0"
+					v-for="item,index in bankList">
+					<view class="infoTpl">
+						<view class="tplName flex_item">
+							<image :src="item.type == 'bank'?'/static/image/bank.png':
+						item.type == 'wx'?'/static/image/wx.png':'/static/image/alipay.png'" style="width: 40rpx;height: 40rpx"
+								mode="widthFix"></image>
+							<view class="titleBox">
+								<view class="tip">{{item.name}}</view>
+							</view>
+						</view>
+					</view>
+					<view class="det">
+						选择
+					</view>
+				</view>
+			</view>
+		</uni-popup>
 	</view>
 </template>
 
@@ -62,7 +100,7 @@
 	import dayjs from '@/libs/dayjs/dayjs.min.js';
 	export default {
 		computed: {
-			...mapState('user', ['hasLogin','userInfo'])
+			...mapState('user', ['hasLogin', 'userInfo'])
 		},
 		filters: {
 			dateFormat: function(value) {
@@ -71,39 +109,38 @@
 		},
 		data() {
 			return {
-				tabIndex: 0,
-				navList: ['支付宝','微信'],
 				number: '',
-				money:'',
+				money: '',
 				price: '',
 				page: 1,
 				limit: 10,
 				list: [],
 				loadingType: 'more',
-				baseData:{
-					min_sell:'',
-					max_sell:''
-				},
-				loaded:false,
-				showBank:false,
-				bankList:[],
-				bank_id:'',
-				bank:{
-					id:'',
-					bank_real_name:'',
-					bank_code:'',
-					bank:'',
-					bank_name:'',
+				baseData: {
+					min_sell: '',
+					max_sell: ''
 				},
-				weixin:{
-					id:'',
-					name:'',
-					account:'',
+				loaded: false,
+				showBank: false,
+				bankList: [],
+				bank_id: '',
+				bank: {
+					id: '',
+					bank_real_name: '',
+					bank_code: '',
+					bank: '',
+					bank_name: '',
 				},
-				zfb:{
-					id:'',
-					name:'',
-					account:'',
+				// 当前选中的银行卡对象
+				actionitem: []
+			}
+		},
+		watch: {
+			showBank(newValue, oldValue) {
+				if (newValue) {
+					this.$refs.popup.open()
+				} else {
+					this.$refs.popup.close()
 				}
 			}
 		},
@@ -130,74 +167,50 @@
 				getBank().then((res) => {
 					let data = res.data.list
 					let reg = /^(.{4})(?:\d+)(.{4})$/
-					if(data.length > 0){
+					if (data.length > 0) {
 						data.forEach(item => {
-							if(item.type == 'bank'){
+							if (item.type == 'bank') {
 								item.bank_code1 = item.bank_code.replace(reg, "**** $2")
-								item.name = item.bank+'   '+item.bank_code1
-							}else{
-								item.name = item.name+'   '+item.phone
+								item.name = item.bank + '   ' + item.bank_code1
+							} else {
+								item.name = item.name + '   ' + item.phone
 							}
 						})
-						obj.bankList = data
-						obj.bank = obj.bankList[0]
-						obj.bank_id = obj.bank.id
-						obj.navList.push('银行卡')
+						obj.bankList = data;
+						if (obj.bankList.length > 0) {
+							obj.actionitem = [obj.bankList[0]];
+							obj.bank_id = obj.bank.id;
+							obj.bank = obj.bankList[0];
+						}
 					}
 				})
 			},
-			bankSelect(e){
+			bankSelect(e) {
 				const obj = this;
-				this.bank_id = e.id
-				obj.showBank = false
-				uni.showModal({
-					title: '请输入支付密码',
-					editable:true,
-					success: res => {
-						if(res.confirm){
-							sellPush({
-									type: 'USDT',
-									num: obj.number,
-									price: obj.price,
-									phone: obj.userInfo.phone || '',
-									trade_psw: res.content,
-									sell_type: 'money',
-									bank_id:obj.bank_id
-								}).then((
-									data
-								) => {
-									obj.qianBao();
-									uni.showToast({
-										title: data.msg,
-										icon:'none'
-									});
-								})
-								.catch(e => {
-									console.log(e);
-								});
-						}
-					},
-					fail: () => {},
-					complete: () => {}
-				});
+				this.bank_id = e.id;
+				this.actionitem = [e];
+				obj.showBank = false;
+
+
 			},
-			getIndex(){
+			getIndex() {
 				getIndex({})
 					.then(({
 						data
 					}) => {
-						this.baseData = data
+						this.baseData = data;
+						this.price = data.us_price
 						console.log(data);
 					})
 					.catch(e => {});
 			},
-			
+
 			// 购买订单
 			commitorder(item) {
 				let obj = this
 				uni.showModal({
 					title: '请输入支付密码',
-					editable:true,
+					editable: true,
 					success: res => {
 						if (res.confirm) {
 							if (res.content) {
@@ -217,7 +230,7 @@
 											content: data.msg,
 											showCancel: false,
 										});
-										setTimeout(function () {
+										setTimeout(function() {
 											obj.page = 1;
 											obj.list = [];
 											obj.loadingType = 'more';
@@ -236,28 +249,65 @@
 			// 挂出
 			submission() {
 				let obj = this;
-				if(!obj.number){
+				if (!obj.number) {
 					uni.showToast({
 						title: '请输入数量',
-						icon:'none'
+						icon: 'none'
 					});
 					return
 				}
-				if(!obj.price){
+				if (!obj.price) {
 					uni.showToast({
 						title: '请输入单价',
-						icon:'none'
+						icon: 'none'
 					});
 					return
 				}
-				if(obj.price > obj.baseData.us_price){
+				if (obj.price > obj.baseData.us_price) {
 					uni.showToast({
 						title: '单价不得大于当前汇率',
-						icon:'none'
+						icon: 'none'
 					});
 					return
 				}
-				this.showBank = true
+				uni.showModal({
+					title: '请输入支付密码',
+					editable: true,
+					success: res => {
+						if (res.confirm) {
+							sellPush({
+									type: 'USDT',
+									num: obj.number,
+									price: obj.price,
+									phone: obj.userInfo.phone || '',
+									trade_psw: res.content,
+									sell_type: 'money',
+									bank_id: obj.bank_id
+								}).then((
+									data
+								) => {
+									obj.qianBao();
+									obj.number = '';
+									obj.trade_psw = '';
+									uni.showToast({
+										title: data.msg,
+									});
+									setTimeout(
+										() => {
+											uni.navigateTo({
+												url:'/pages/index/order'
+											})
+										}
+									)
+								})
+								.catch(e => {
+									console.log(e);
+								});
+						}
+					},
+					fail: () => {},
+					complete: () => {}
+				});
 			},
 			init() {
 				this.page = 1;
@@ -267,9 +317,6 @@
 				this.qianBao();
 				this.getBank();
 			},
-			tabClick(index) {
-				this.tabIndex = index
-			},
 			async loadData(source) {
 				const that = this;
 				//这里是将订单挂载到tab列表下
@@ -332,6 +379,7 @@
 		padding-bottom: 40rpx;
 		color: #fff;
 	}
+
 	.listBox {
 		padding: 62rpx 32rpx;
 
@@ -424,11 +472,13 @@
 			}
 		}
 	}
-	.changeBank{
+
+	.changeBank {
 		text-align: right;
 		margin-top: 25rpx;
 		padding-right: 35rpx;
-		.btnChange{
+
+		.btnChange {
 			background: #0C5AFA;
 			color: #fff;
 			display: inline-block;
@@ -436,17 +486,82 @@
 			padding: 15rpx 25rpx;
 			border-radius: 15rpx;
 		}
-		
+
 	}
+
 	.login_text {
 		width: 100%;
 		// padding: 25rpx 0rpx;
 		font-size: 28rpx !important;
 		padding: 0rpx 25rpx;
 	}
-	
+
 	.login_input {
 		border-bottom: 1px solid #464755;
 		padding: 35rpx;
 	}
+
+	.alertBottom {
+		padding-bottom: 55px;
+		background-color: #FFF;
+
+		.alertTitle {
+			padding: 20rpx 30rpx;
+			font-size: 30rpx;
+			color: #333333;
+
+			.alertTitleName {
+				font-weight: bold;
+			}
+		}
+
+		.bankList {
+			background: #FFF;
+			border-bottom: 1px solid #eeeeee;
+			border-radius: 0;
+
+			.infoTpl {
+				.tplName {
+					.titleBox {
+						.tip {
+							color: #999 !important;
+						}
+					}
+				}
+			}
+		}
+	}
+
+	.bankList {
+		color: #fff;
+		background: #1F2A4A;
+		padding: 36rpx 38rpx;
+		border-radius: 20rpx;
+		margin-bottom: 25rpx;
+		position: relative;
+
+		.det {
+			color: #0C5AFA;
+		}
+
+		.infoTpl {
+			.tplName {
+				.titleBox {
+					padding-left: 25rpx;
+
+					.name {
+						font-weight: bold;
+						font-size: 30rpx;
+						color: #FFFFFF;
+					}
+
+					.tip {
+						font-weight: 500;
+						font-size: 25rpx;
+						color: rgba(255, 255, 255, 0.64);
+					}
+				}
+			}
+		}
+	}
 </style>

+ 16 - 23
pages/index/recharge.vue

@@ -25,7 +25,7 @@
 				<view class="btn" @click="copy">复制地址</view>
 			</view>
 		</view>
-		<view class="login_text">
+		<!-- <view class="login_text">
 			<view class="login_input flex" style="padding-top: 45rpx;">
 				<view class="login_img">金额</view>
 				<view class="login_name"><input class="uni-input" type="text" v-model="money" placeholder="请输入充值金额" />
@@ -44,13 +44,13 @@
 			</view>
 			<view class="submission"><button class="golden" type="golden" hover-class="none"
 					@click="submission">确认提交</button></view>
-		</view>
+		</view> -->
 		<view class="login_text">
 			<view class="tip">
 				<view>
 					<text>
 						该地址仅支持 USDT-TRC20 收款请勿用于其他币种,否则资产将不可找回</br>
-						从易趣付之外地址转入的资金,需要在完成交易的120分钟后,才能将资产转账给易币付其他用户或提到钱包以外的地址 最小收款金额:
+						从STAR(星空)之外地址转入的资金,需要在完成交易的120分钟后,才能将资产转账给易币付其他用户或提到钱包以外的地址 最小收款金额:
 						0.0001USDT小于最小金额的收款将不会上账且无法退回1次网络确认后可到账,1次网络确认后可转账。您的充值地址不会经常改变,可截图保存并重复充值。
 					</text>
 				</view>
@@ -59,8 +59,8 @@
 	</view>
 </template>
 <script type="text/javascript">
-	// import { show_cb,do_cb } from '@/api/recharge.js';
-	// import { upload } from '@/api/real.js';
+	import { rechargeUSDT } from '@/api/game.js';
+	import { upload } from '@/api/order.js';
 	import {
 		qianBao
 	} from '@/api/wallet.js';
@@ -70,17 +70,8 @@
 	export default {
 		data() {
 			return {
-				uid: '',
-				list: '',
-				account: '',
-				money: '',
-				address: '',
 				er_code: '',
-				remark: '',
-				img: '/static/image/img19.png',
 				dataMoney: {},
-				uid: '',
-				account: '',
 				money: '',
 				address: '',
 				remark: '',
@@ -103,7 +94,6 @@
 			};
 		},
 		onLoad() {
-			this.uid = uni.getStorageSync('uid');
 			this.qianBao();
 		},
 		methods: {
@@ -150,21 +140,24 @@
 					mask: true
 				});
 				//确认充值调接口,成功跳转页面
-				do_cb({
-						uid: obj.uid,
-						img: obj.img,
-						address: obj.address,
-						money: obj.money,
-						bz: obj.remark,
+				rechargeUSDT({
+						num: obj.money,
+						picture : obj.img,
+						money_type: "USDT",
+						mark: obj.remark,
 					})
 					.then(function(e) {
 						uni.showToast({
 							title: '请耐心等待系统审核通过',
-							duration: 1500,
+							duration: 1200,
 							mask: false,
 							icon: 'none'
 						});
-						uni.hideLoading();
+						obj.money='';
+						obj.img='/static/image/img19.png';
+						obj.remark='';
+						obj.qianBao();
+						uni.navigateBack()
 					})
 					.catch(function(e) {
 						console.log(e);

+ 5 - 5
pages/index/user.vue

@@ -4,13 +4,13 @@
 			<view class="topName">我的资产</view>
 			<view class="topMoney">${{money}}</view>
 			<view class="flex topInfo">
-				<view class="flex_item infoTpl" @click="navTo('/pages/user/transfer')">
+				<!-- <view class="flex_item infoTpl" @click="navTo('/pages/user/transfer')">
 					<image src="/static/image/img27.png" style="width: 48rpx;height: 48rpx;" mode="widthFix"></image>
 					<view class="tplName">转账</view>
-				</view>
-				<view class="flex_item infoTpl" @click="navTo('/pages/user/collection')">
+				</view> -->
+				<view class="flex_item infoTpl" @click="navTo('/pages/index/recharge')">
 					<image src="/static/image/img28.png" style="width: 44rpx;height: 44rpx;" mode="widthFix"></image>
-					<view class="tplName">收款</view>
+					<view class="tplName">充值</view>
 				</view>
 				<view class="flex_item infoTpl" @click="navTo('/pages/user/withdrawal')">
 					<image src="/static/image/img29.png" style="width: 45rpx;height: 42rpx;" mode="widthFix"></image>
@@ -157,7 +157,7 @@
 		.topInfo {
 			font-size: 27rpx;
 			color: #FFFFFF;
-
+			justify-content: space-around;
 			.infoTpl {
 				.tplName {
 					padding-left: 15rpx;

+ 2 - 2
pages/user/collection.vue

@@ -26,7 +26,7 @@
 				<view>
 					<text>
 						该地址仅支持 USDT-TRC20 收款请勿用于其他币种,否则资产将不可找回</br>
-						从易趣付之外地址转入的资金,需要在完成交易的120分钟后,才能将资产转账给易币付其他用户或提到钱包以外的地址 最小收款金额:
+						从STAR(星空)之外地址转入的资金,需要在完成交易的120分钟后,才能将资产转账给易币付其他用户或提到钱包以外的地址 最小收款金额:
 						0.0001USDT小于最小金额的收款将不会上账且无法退回1次网络确认后可到账,1次网络确认后可转账。您的充值地址不会经常改变,可截图保存并重复充值。
 					</text>
 				</view>
@@ -91,7 +91,7 @@
 			},
 			// 复制地址
 			copy(){
-				copyText(this.dataMoney.address)
+				copyText(this.val)
 			},
 			// 二维码生成
 			qrR(res) {

+ 12 - 5
pages/user/set/editBank.vue

@@ -50,11 +50,11 @@
 				<view class="login_name"><input class="uni-input" type="text" v-model="info.name"
 						placeholder="请输入真实姓名" /></view>
 			</view>
-			<view class="login_input flex">
+			<!-- <view class="login_input flex">
 				<view class="login_name"><text>微信账号</text></view>
 				<view class="login_name"><input class="uni-input" type="idcard" v-model="info.phone"
 						placeholder="请输入微信账号" /></view>
-			</view>
+			</view> -->
 			<view class="login_input">
 				<view class="login_name" @click="scImg">
 					<image :src="info.qrcode||'/static/image/img19.png'"></image>
@@ -85,7 +85,8 @@
 					phone:'',
 					qrcode:''
 				},
-				type:'bank'
+				type:'bank',
+				loding:false,
 			};
 		},
 		onLoad(option) {
@@ -180,7 +181,7 @@
 						})
 						return
 					}
-					if(!obj.info.phone){
+					if(!obj.info.phone&&obj.tabIndex == 1){
 						uni.showToast({
 							title: '请输入账号',
 							icon: 'none',
@@ -198,6 +199,7 @@
 				let data = ''
 				if(obj.info.id){
 					data = {
+						id:0,
 						bank:obj.info.bank,//银行
 						bank_name:obj.info.bank_name,//开户行
 						bank_code:obj.info.bank_code,//银行卡号
@@ -211,6 +213,7 @@
 					}
 				}else{
 					data = {
+						id:0,
 						bank:obj.info.bank,//银行
 						bank_name:obj.info.bank_name,//开户行
 						bank_code:obj.info.bank_code,//银行卡号
@@ -222,6 +225,10 @@
 						type:obj.type
 					}
 				}
+				uni.showLoading({
+					title: '提交中',
+					mask: true
+				});
 				addBank(data).then(res => {
 					uni.showToast({
 						title: res.msg,
@@ -241,7 +248,7 @@
 					file: ''
 				}).then((e) => {
 					console.log(e, 55)
-					this.xinxi.qrcode = e[0].url;
+					this.info.qrcode = e[0].url;
 				});
 			},
 		},

二进制
static/img/download.png


+ 9 - 0
store/index.js

@@ -12,6 +12,10 @@ const store = new Vuex.Store({
 		// #ifdef H5 || MP-WEIXIN
 		weichatInfo: {}, //保存微信注册信息
 		weichatObj: '', //微信对象
+		isShowIllegality:true,
+		// #endif
+		// #ifdef APP
+		isShowIllegality:false,
 		// #endif
 		langList: [
 			{
@@ -44,6 +48,11 @@ const store = new Vuex.Store({
 			i18n.locale = data
 			state.lang = data
 		},
+		// 修改显示隐藏ios审核不允许显示的功能
+		changeState(state, provider){
+			console.log(provider,'provider');
+			state.isShowIllegality = provider;
+		}
 	},
 	modules: {
 		user

二进制
unpackage/证书/安卓/newkeystore.keystore


+ 2 - 0
unpackage/证书/安卓/密码.txt

@@ -0,0 +1,2 @@
+包名:com.yzf.net 
+密码:112233

+ 104 - 77
utils/upApp.js

@@ -1,92 +1,119 @@
-import store from '../store'
-import {getAppVersion} from '@/api/index.js'
+import store from '../store/index.js'
+const baseurl = store.state.baseURL
+const getUpAppUrl = baseurl + '/api/version';
+const getIosUpAppUrl = 'https://itunes.apple.com/cn/lookup?id=6474850968'
+// 请求升级获取数据地址
 const iosAppStroeUrl =
-	'https://apps.apple.com/cn/app/%E6%BB%A1%E5%9B%AD%E6%98%A5%E7%BA%BF%E4%B8%8A%E5%95%86%E5%9F%8E/id1524593346';
+	'https://apps.apple.com/cn/app/%E6%98%93%E8%B6%A3cbb/id=6474850968';
 
 // 获取app是否需要升级
-export function getUpApp () {
+export function getUpApp() {
 	// 获取当前运行系统
 	let hj = uni.getSystemInfoSync().platform;
 	// 获取仓库app数据对象
-	// let app = store.state.isShowIllegality;
+	if (hj === 'ios') {
+		uni.request({
+			url: getIosUpAppUrl,
+			method: 'POST',
+			data: {},
+			success: res => {
+				let r = res.data;
+				isUp(r, hj)
+			},
+		});
+		// 设置显示数据
+		return
+	}
 	// 当前系统为安卓则显示数据
 	if (hj === 'android') {
-		// 设置默认显示数据
-		// app = true;
-		// store.commit('changeState', {
-		// 	name: 'app',
-		// 	value: app
-		// });
+		uni.request({
+			url: getUpAppUrl,
+			method: 'GET',
+			data: {},
+			success: res => {
+				let r = res.data.data;
+				console.log(r, '234')
+				isUp(r, hj)
+			},
+			fail: res => {
+				console.log(res, 'shib');
+			}
+		});
 	}
-	console.log('开始升级');
-	getAppVersion().then((res)=>{
-		console.log(res,'回调');
-			let r = res.data;
-			plus.runtime.getProperty(plus.runtime.appid, function(wgtinfo) {
-				console.log(r.version,'获取版本');
-				// 保存线上版本号
-				let version = r.version;
-				// 获取线上版本
-				const arr = r.version.split('.');
-				// 获取当前系统
-				const arr1 = wgtinfo.version.split('.');
-				console.log(version,'升级数据2');
-				console.log(arr,'升级数据3');
-				console.log(arr1,'升级数据4');
-				let up = false;
-				
-				for (let i = 0; i < arr.length; i++) {
-					// 线上版本号
-					const x = +arr[i];
-					// 线下版本号
-					const y = +arr1[i];
-					// 判断当前版本是否为小于等于线上版本
-					console.log(x,y,'循环');
-					if (x >= y) {
-						// 只有ios才需要显示
-						// if (hj === 'ios') {
-						// 	// 设置显示数据
-						// 	// app = true;
-						// 	// store.commit('changeState', {
-						// 	// 	name: 'app',
-						// 	// 	value: app
-						// 	// });
-						// }
-						// 当版本较低时更新数据
-						console.log(x,y);
-						if(up==true){
-							return;
-						}
-						if (x > y) {
-							up = true;
-							uni.showModal({
-								title: '提示',
-								content: '请更新应用',
-								showCancel: false,
-								success(e) {
-									// if (hj === 'ios') {
-									// 	plus.runtime.openURL(
-									// 		iosAppStroeUrl
-									// 	);
-									// }
-									if (hj === 'android') {
-										// plus.runtime.openURL('http://lxscimg.liuniu946.com/lxscV' + version + '.apk');
-										console.log(r.apk,'下載地址');
-										downApp(r.apk);
-									}
+}
+
+//判断是否需要更新
+function isUp(r, hj) {
+	plus.runtime.getProperty(plus.runtime.appid, function(wgtinfo) {
+		let version = '';
+		let arr = '';
+		if (hj == "android") {
+			console.log(r,555);
+			// 保存线上版本号
+			version = r.version_code;
+			// 获取线上版本
+			arr = r.version_code.split('.');
+			console.log(arr);
+		}
+		if (hj == "ios") {
+			// 保存线上版本号
+			version = r.results[0].version;
+			// 获取线上版本
+			arr = r.results[0].version.split('.');
+		}
+		
+		// 获取当前系统
+		const arr1 = wgtinfo.version.split('.');
+		
+		for (let i = 0; i < arr.length; i++) {
+			// 线上版本号
+			const x = +arr[i];
+			// 本地版本号
+			const y = +arr1[i];
+			// 判断线上版本是否小于本地版本
+			console.log(x, y, '数据');
+			if (x < y) {
+				console.log('数据隐藏');
+				// 设置显示数据
+				store.commit('changeState', false);
+				return
+			}
+			// 判断线上版本是否大于本地版本
+			else if (x > y) {
+				uni.showModal({
+					title: '提示',
+					content: '请更新应用',
+					showCancel: false,
+					success(e) {
+						if (hj == "android") {
+							// downApp(r.apk);
+							uni.navigateTo({
+								url:'/pages/index/downLoad?apk='+r.apk,
+								fail(er) {
+									console.log(er,'eee');
 								}
-							});
+							})
+							
+						}
+						if (hj == "ios") {
+							plus.runtime.openURL(
+								iosAppStroeUrl
+							);
 						}
-						
 					}
-				}
-			});
-	}).catch((res)=>{
-		console.log(res);
-	})
+				});
+				return
+			} 
+			// 判断是否本地版本等于线上版本
+			else if (x == y && i == arr.length - 1) {
+				store.commit('changeState', true);
+				return
+			}
+		}
+	});
 }
 // 下载app
-export function downApp (version) {
+export function downApp(version) {
 	let url = '';
 	if(version.indexOf('http')>-1){
 		url = version;
@@ -107,7 +134,7 @@ export function downApp (version) {
 		.start();
 }
 // 安装app
-export function installApp (path) {
+export function installApp(path) {
 	plus.nativeUI.showWaiting('安装升级包...');
 	plus.runtime.install(
 		path, {},
@@ -127,4 +154,4 @@ export function installApp (path) {
 			plus.nativeUI.alert('安装升级包失败[' + e.code + ']:' + e.message);
 		}
 	);
-}
+}