1.虚拟币接口连调

2024.3.28 sws
master
sws 2024-03-28 11:22:06 +08:00
parent c9a272e17b
commit 59ca0a09be
6 changed files with 392 additions and 247 deletions

View File

@ -2,9 +2,9 @@
<view :class="theme_view">
<view class="convert">
<view class="padding-main bg-white pr nav flex-row">
<view class="flex-row align-c margin-right-main" @tap="popup_accounts_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_accounts_open_event">
<view>账户</view>
<view class="padding-left-sm"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
</view>
<scroll-view :scroll-y="true" class="scroll-box" lower-threshold="60" @scroll="scroll_event">
@ -50,6 +50,9 @@
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">账户种类</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="accounts_list_event"></view>
</view>
<view v-for="(item, index) in accounts_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.id" :data-index="index" @tap="accounts_list_event">{{ item.platform_name }}</view>
</view>
@ -79,6 +82,9 @@
return {
theme_view: app.globalData.get_theme_value_view(),
accounts_static_url: accounts_static_url,
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
//
popup_top_height: 0,
@ -86,7 +92,7 @@
//
popup_accounts_status: false,
accounts_id: null,
accounts_list_index: 0,
accounts_list_index: null,
accounts_list: [],
data: [],

View File

@ -2,17 +2,17 @@
<view :class="theme_view">
<view class="convert">
<view class="padding-main bg-white pr nav flex-row">
<view class="flex-row align-c margin-right-main" @tap="popup_accounts_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_accounts_open_event">
<view>账户</view>
<view class="padding-left-sm"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main" @tap="popup_recharge_status_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_recharge_status_open_event">
<view>状态</view>
<view class="padding-left-sm"><iconfont :name="popup_recharge_status_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_recharge_status_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main" @tap="popup_network_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_network_open_event">
<view>网络</view>
<view class="padding-left-sm"><iconfont :name="popup_network_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_network_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
</view>
<scroll-view :scroll-y="true" class="scroll-box" lower-threshold="60" @scroll="scroll_event">
@ -58,6 +58,9 @@
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">账户种类</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="accounts_list_event"></view>
</view>
<view v-for="(item, index) in accounts_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.id" :data-index="index" @tap="accounts_list_event">{{ item.platform_name }}</view>
</view>
@ -73,6 +76,9 @@
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">提现类型</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="recharge_status_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="recharge_status_list_event"></view>
</view>
<view v-for="(item, index) in recharge_status_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="recharge_status_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.value" :data-index="index" @tap="recharge_status_list_event">{{ item.name }}</view>
</view>
@ -88,6 +94,9 @@
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">提现类型</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="network_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="network_list_event"></view>
</view>
<view v-for="(item, index) in network_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="network_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.id" :data-index="index" @tap="network_list_event">{{ item.name }}</view>
</view>
@ -127,17 +136,17 @@
//
popup_accounts_status: false,
accounts_id: null,
accounts_list_index: 0,
accounts_list_index: null,
accounts_list: [],
//
popup_recharge_status_status: false,
status: null,
recharge_status_list_index: 0,
recharge_status_list_index: null,
recharge_status_list: [],
//
popup_network_status: false,
network_id: null,
network_list_index: 0,
network_list_index: null,
network_list: [],
data: [],

View File

@ -5,10 +5,14 @@
height: calc(100vh - 88rpx);
}
.convert-group-row .title {
min-width: 140rpx;
}
/*
*
*/
.popup_wallet_container .item {
.popup_accounts_container .item {
background-color: #f4f4f4;
border-radius: 30rpx;
}

View File

@ -2,68 +2,128 @@
<view :class="theme_view">
<view class="transaction">
<view class="padding-main bg-white pr nav flex-row">
<view class="flex-row align-c margin-right-main" @tap="popup_wallet_open_event">
<view>钱包</view>
<view class="padding-left-sm"><iconfont :name="popup_wallet_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_accounts_open_event">
<view>账户</view>
<view class="pa right-0"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-left-sm" @tap="popup_type_open_event">
<view>类型</view>
<view class="padding-left-sm"><iconfont :name="popup_type_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_operate_type_open_event">
<view>操作类型</view>
<view class="pa right-0"><iconfont :name="popup_operate_type_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_business_type_open_event">
<view>业务类型</view>
<view class="pa right-0"><iconfont :name="popup_business_type_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_coin_type_open_event">
<view>币类型</view>
<view class="pa right-0"><iconfont :name="popup_coin_type_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
</view>
<scroll-view :scroll-y="true" class="scroll-box" lower-threshold="60" @scroll="scroll_event">
<view class="padding-main">
<view v-for="(item, index) in data" :key="index" class="padding-main bg-white radius-md margin-bottom-main">
<view class="br-b-dashed padding-bottom-main margin-bottom-main flex-row jc-sb align-c">
<view>{{ item.status }}</view>
<view class="cr-grey-9">{{ item.date }}</view>
<view>{{ item.business_type_name }}</view>
<view class="cr-grey-9">{{ item.add_time }}</view>
</view>
<view>
<view class="convert-group-row">
<view class="margin-bottom-sm flex-row">
<text class="cr-grey-9">金额类型</text>
<text class="fw-b">{{ item.price_type }}</text>
<text class="cr-grey-9 title">类型</text>
<text class="fw-b">{{ item.coin_type_name }}</text>
</view>
<view class="margin-bottom-sm flex-row">
<text class="cr-grey-9">操作金额</text>
<text class="fw-b">{{ item.price }}</text>
<text class="cr-grey-9 title">操作类型</text>
<text class="fw-b">{{ item.operate_type_name }}</text>
</view>
<view class="margin-bottom-sm flex-row">
<text class="cr-grey-9">原始金额</text>
<text class="fw-b">{{ item.init_price }}</text>
<text class="cr-grey-9 title">操作币</text>
<text class="fw-b">{{ item.operate_coin }}</text>
</view>
<view class="margin-bottom-sm flex-row">
<text class="cr-grey-9 title">原始币</text>
<text class="fw-b">{{ item.original_coin }}</text>
</view>
<view class="margin-bottom-sm flex-row">
<text class="cr-grey-9 title">最新币</text>
<text class="fw-b">{{ item.latest_coin }}</text>
</view>
<view class="flex-row">
<text class="cr-grey-9">最新金额</text>
<text class="fw-b">{{ item.new_price }}</text>
<text class="cr-grey-9 title">描述</text>
<text class="fw-b">{{ item.msg }}</text>
</view>
</view>
</view>
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
</view>
</scroll-view>
<!-- 钱包 -->
<component-popup :propShow="popup_wallet_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_wallet_close_event">
<!-- 账户 -->
<component-popup :propShow="popup_accounts_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_accounts_close_event">
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">钱包种类</view>
<view class="popup_wallet_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view v-for="(item, index) in wallet_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="wallet_list_index === index ? 'cr-main bg-main-light' : ''" :data-index="index" @tap="wallet_event">{{ item.name }}</view>
<view class="padding-horizontal-main text-size-xs">账户种类</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="accounts_list_event"></view>
</view>
<view v-for="(item, index) in accounts_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="accounts_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.id" :data-index="index" @tap="accounts_list_event">{{ item.platform_name }}</view>
</view>
</view>
<view class="tc padding-top-lg br-t" @tap="popup_wallet_close_event">
<view class="tc padding-top-lg br-t" @tap="popup_accounts_close_event">
<text class="padding-right-sm">{{ $t('nav-more.nav-more.h9g4b1') }}</text>
<iconfont name="icon-arrow-top" color="#ccc"></iconfont>
</view>
</view>
</component-popup>
<!-- 类型 -->
<component-popup :propShow="popup_type_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_type_close_event">
<!-- 操作类型 -->
<component-popup :propShow="popup_operate_type_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_operate_type_close_event">
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">提现类型</view>
<view class="popup_wallet_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view v-for="(item, index) in type_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="type_list_index === index ? 'cr-main bg-main-light' : ''" :data-index="index" @tap="type_event">{{ item.name }}</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="operate_type_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="operate_type_list_event"></view>
</view>
<view v-for="(item, index) in operate_type_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="operate_type_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.value" :data-index="index" @tap="operate_type_list_event">{{ item.name }}</view>
</view>
</view>
<view class="tc padding-top-lg br-t" @tap="popup_type_close_event">
<view class="tc padding-top-lg br-t" @tap="popup_operate_type_close_event">
<text class="padding-right-sm">{{ $t('nav-more.nav-more.h9g4b1') }}</text>
<iconfont name="icon-arrow-top" color="#ccc"></iconfont>
</view>
</view>
</component-popup>
<!-- 业务类型 -->
<component-popup :propShow="popup_business_type_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_business_type_close_event">
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">提现类型</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="business_type_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="business_type_list_event"></view>
</view>
<view v-for="(item, index) in business_type_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="business_type_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.value" :data-index="index" @tap="business_type_list_event">{{ item.name }}</view>
</view>
</view>
<view class="tc padding-top-lg br-t" @tap="popup_business_type_close_event">
<text class="padding-right-sm">{{ $t('nav-more.nav-more.h9g4b1') }}</text>
<iconfont name="icon-arrow-top" color="#ccc"></iconfont>
</view>
</view>
</component-popup>
<!-- 币类型 -->
<component-popup :propShow="popup_coin_type_status" propPosition="top" :propTop="popup_top_height + 'px'" @onclose="popup_coin_type_close_event">
<view class="padding-vertical-lg">
<view class="padding-horizontal-main text-size-xs">提现类型</view>
<view class="popup_accounts_container padding-sm flex-row flex-warp align-c tc text-size-md">
<view class="flex-width-half-half">
<view class="item margin-sm padding-vertical-sm" :class="coin_type_list_index === null ? 'cr-main bg-main-light' : ''" :data-value="null" :data-index="null" @tap="coin_type_list_event"></view>
</view>
<view v-for="(item, index) in coin_type_list" class="flex-width-half-half" :key="index">
<view class="item margin-sm padding-vertical-sm" :class="coin_type_list_index === index ? 'cr-main bg-main-light' : ''" :data-value="item.value" :data-index="index" @tap="coin_type_list_event">{{ item.name }}</view>
</view>
</view>
<view class="tc padding-top-lg br-t" @tap="popup_coin_type_close_event">
<text class="padding-right-sm">{{ $t('nav-more.nav-more.h9g4b1') }}</text>
<iconfont name="icon-arrow-top" color="#ccc"></iconfont>
</view>
@ -76,7 +136,8 @@
const app = getApp();
import componentNoData from '@/components/no-data/no-data';
import componentPopup from '@/components/popup/popup';
var wallet_static_url = app.globalData.get_static_url('coin', true) + 'app/';
import componentBottomLine from '@/components/bottom-line/bottom-line';
var accounts_static_url = app.globalData.get_static_url('coin', true) + 'app/';
//
var bar_height = parseInt(app.globalData.get_system_info('statusBarHeight', 0, true));
// #ifdef MP-TOUTIAO
@ -86,185 +147,46 @@
data() {
return {
theme_view: app.globalData.get_theme_value_view(),
wallet_static_url: wallet_static_url,
accounts_static_url: accounts_static_url,
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
//
popup_top_height: 0,
//
popup_wallet_status: false,
wallet_list_index: 0,
wallet_list: [
{
name: '全部',
},
{
name: 'BTC',
},
{
name: 'ETH',
},
{
name: 'XRP',
},
{
name: 'DASH',
},
],
//
popup_type_status: false,
type_list_index: 0,
type_list: [
{
name: '全部',
},
{
name: '未打款',
},
{
name: '已打款',
},
{
name: '打款失败',
},
],
//
popup_accounts_status: false,
accounts_id: null,
accounts_list_index: null,
accounts_list: [],
//
popup_operate_type_status: false,
operate_type: null,
operate_type_list_index: null,
operate_type_list: [],
//
popup_business_type_status: false,
business_type: null,
business_type_list_index: null,
business_type_list: [],
//
popup_coin_type_status: false,
coin_type: null,
coin_type_list_index: null,
coin_type_list: [],
data: [
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
{
date: '2023-12-12',
status: '消费',
price_type: '有效',
price: '20000',
init_price: '20000',
new_price: '收款后请尽快联系',
},
],
data: [],
data_page_total: 0,
data_page: 1,
data_is_loading: 0,
};
},
components: {
componentNoData,
componentPopup,
componentBottomLine,
},
props: {},
@ -285,13 +207,17 @@
//
onPullDownRefresh() {
this.get_data();
this.setData({
data_page: 1,
});
this.get_data_list(1);
},
methods: {
init(e) {
var user = app.globalData.get_user_info(this, 'init');
if (user != false) {
this.get_data();
this.init_data();
this.get_data_list();
var self = this;
var timer = setInterval(function () {
if (self.popup_top_height == 0) {
@ -303,53 +229,253 @@
}
},
//
init_data() {
uni.request({
url: app.globalData.get_request_url('init', 'user', 'coin'),
method: 'POST',
data: {},
dataType: 'json',
success: (res) => {
uni.stopPullDownRefresh();
console.log(res.data.data);
if (res.data.code == 0) {
var data = res.data.data;
this.setData({
accounts_list: data.accounts_list || [],
operate_type_list: data.log_operate_type_list || [],
business_type_list: data.log_business_type_list || [],
coin_type_list: data.log_coin_type_list || [],
});
} else {
if (app.globalData.is_login_check(res.data, this, 'get_data_list')) {
app.globalData.showToast(res.data.msg);
}
}
},
fail: () => {
uni.stopPullDownRefresh();
app.globalData.showToast(this.$t('common.internet_error_tips'));
},
});
},
//
get_data() {},
get_data_list(is_mandatory) {
//
if ((is_mandatory || 0) == 0) {
if (this.data_bottom_line_status == true) {
uni.stopPullDownRefresh();
return false;
}
}
//
if (this.data_is_loading == 1) {
return false;
}
this.setData({
data_is_loading: 1,
data_list_loding_status: 1,
});
// loding
if (this.data_page > 1) {
uni.showLoading({
title: this.$t('common.loading_in_text'),
});
}
var new_data = {
accounts_id: this.accounts_id,
business_type: this.business_type,
operate_type: this.operate_type,
coin_type: this.coin_type,
page: this.data_page,
};
uni.request({
url: app.globalData.get_request_url('index', 'accountslog', 'coin'),
method: 'POST',
data: new_data,
dataType: 'json',
success: (res) => {
if (this.data_page > 1) {
uni.hideLoading();
}
console.log(res.data.data);
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
if (data.data_list.length > 0) {
if (this.data_page <= 1) {
var temp_data_list = data.data_list;
} else {
var temp_data_list = this.data || [];
var temp_data = res.data.data.data;
for (var i in temp_data) {
temp_data_list.push(temp_data[i]);
}
}
this.setData({
data: temp_data_list,
data_page_total: data.page_total,
data_page: data.page + 1,
data_list_loding_msg: '',
data_list_loding_status: 3,
data_is_loading: 0,
});
//
popup_wallet_open_event() {
if (!this.popup_type_status) {
//
this.setData({
data_bottom_line_status: this.data_page > 1 && this.data_page > this.data_page_total,
});
} else {
if (data.page <= 1) {
this.setData({
data: data.data_list,
data_page_total: data.page_total,
data_page: data.page + 1,
data_list_loding_msg: '',
data_list_loding_status: 3,
data_is_loading: 0,
});
} else {
this.setData({
data_list_loding_status: 0,
data_is_loading: 0,
});
}
if (app.globalData.is_login_check(res.data, this, 'get_data_list')) {
app.globalData.showToast(res.data.msg);
}
}
} else {
this.setData({
data_list_loding_status: 2,
data_list_loding_msg: res.data.msg,
});
if (app.globalData.is_login_check(res.data, this, 'get_data_list')) {
app.globalData.showToast(res.data.msg);
}
}
},
fail: () => {
if (this.data_page > 1) {
uni.hideLoading();
}
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
data_list_loding_msg: this.$t('common.internet_error_tips'),
});
app.globalData.showToast(this.$t('common.internet_error_tips'));
},
});
},
//
popup_accounts_open_event() {
if (!this.popup_operate_type_status && !this.popup_business_type_status && !this.popup_coin_type_status) {
this.setData({
popup_wallet_status: !this.popup_wallet_status,
popup_accounts_status: !this.popup_accounts_status,
});
}
},
//
popup_wallet_close_event() {
//
popup_accounts_close_event() {
this.setData({
popup_wallet_status: false,
popup_accounts_status: false,
});
},
//
wallet_event(e) {
//
accounts_list_event(e) {
this.setData({
wallet_list_index: e.currentTarget.dataset.index,
accounts_list_index: e.currentTarget.dataset.index,
accounts_id: e.currentTarget.dataset.value,
popup_accounts_status: false,
data_page: 1,
});
this.get_data_list(1);
},
//
popup_type_open_event() {
if (!this.popup_wallet_status) {
//
popup_operate_type_open_event() {
if (!this.popup_accounts_status && !this.popup_business_type_status && !this.popup_coin_type_status) {
this.setData({
popup_type_status: !this.popup_type_status,
popup_operate_type_status: !this.popup_operate_type_status,
});
}
},
//
popup_type_close_event() {
//
popup_operate_type_close_event() {
this.setData({
popup_type_status: false,
popup_operate_type_status: false,
});
},
//
type_event(e) {
//
operate_type_list_event(e) {
this.setData({
type_list_index: e.currentTarget.dataset.index,
operate_type_list_index: e.currentTarget.dataset.index,
operate_type: e.currentTarget.dataset.value,
popup_operate_type_status: false,
data_page: 1,
});
this.get_data_list(1);
},
//
popup_business_type_open_event() {
if (!this.popup_accounts_status && !this.popup_operate_type_status && !this.popup_coin_type_status) {
this.setData({
popup_business_type_status: !this.popup_business_type_status,
});
}
},
//
popup_business_type_close_event() {
this.setData({
popup_business_type_status: false,
});
},
//
business_type_list_event(e) {
this.setData({
business_type_list_index: e.currentTarget.dataset.index,
business_type: e.currentTarget.dataset.value,
popup_business_type_status: false,
data_page: 1,
});
this.get_data_list(1);
},
//
popup_coin_type_open_event() {
if (!this.popup_accounts_status && !this.popup_operate_type_status && !this.popup_business_type_status) {
this.setData({
popup_coin_type_status: !this.popup_coin_type_status,
});
}
},
//
popup_coin_type_close_event() {
this.setData({
popup_coin_type_status: false,
});
},
//
coin_type_list_event(e) {
this.setData({
coin_type_list_index: e.currentTarget.dataset.index,
coin_type: e.currentTarget.dataset.value,
popup_coin_type_status: false,
data_page: 1,
});
this.get_data_list(1);
},
//

View File

@ -2,9 +2,9 @@
<view :class="theme_view">
<view class="transfer-accounts">
<view class="padding-main bg-white pr nav flex-row">
<view class="flex-row align-c margin-right-main" @tap="popup_accounts_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_accounts_open_event">
<view>账户</view>
<view class="padding-left-sm"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
</view>
<scroll-view :scroll-y="true" class="scroll-box" lower-threshold="60" @scroll="scroll_event" @scrolltolower="scroll_lower">
@ -81,7 +81,7 @@
//
popup_accounts_status: false,
accounts_id: null,
accounts_list_index: 0,
accounts_list_index: null,
accounts_list: [],
data: [],

View File

@ -2,17 +2,17 @@
<view :class="theme_view">
<view class="withdrawal">
<view class="padding-main bg-white pr nav flex-row">
<view class="flex-row align-c margin-right-main" @tap="popup_accounts_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_accounts_open_event">
<view>账户</view>
<view class="padding-left-sm"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_accounts_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main" @tap="popup_recharge_status_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_recharge_status_open_event">
<view>状态</view>
<view class="padding-left-sm"><iconfont :name="popup_recharge_status_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_recharge_status_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
<view class="flex-row align-c margin-right-main" @tap="popup_network_open_event">
<view class="flex-row align-c margin-right-main padding-right-xl pr" @tap="popup_network_open_event">
<view>网络</view>
<view class="padding-left-sm"><iconfont :name="popup_network_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
<view class="pa right-0"><iconfont :name="popup_network_status ? 'icon-arrow-top' : 'icon-arrow-bottom'" size="24rpx"></iconfont></view>
</view>
</view>
<scroll-view :scroll-y="true" class="scroll-box" lower-threshold="60" @scroll="scroll_event">
@ -123,17 +123,17 @@
//
popup_accounts_status: false,
accounts_id: null,
accounts_list_index: 0,
accounts_list_index: null,
accounts_list: [],
//
popup_recharge_status_status: false,
status: null,
recharge_status_list_index: 0,
recharge_status_list_index: null,
recharge_status_list: [],
//
popup_network_status: false,
network_id: null,
network_list_index: 0,
network_list_index: null,
network_list: [],
data: [],