chore: 前端其余页面和资源文件

This commit is contained in:
li
2026-03-30 15:14:28 +08:00
parent ca51e1147f
commit c58dc3fdb8
584 changed files with 137740 additions and 0 deletions
+145
View File
@@ -0,0 +1,145 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<myNav :title="i18n.appeal.title"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-t-32 padding-b-40">
<textarea class="textbox" v-model="content" :placeholder="i18n.appeal.tos1"
maxlength="-1" :style="'background-color: '+theme.fu_bg+';color: '+theme.text"/>
<view class="grid col-3">
<view v-for="(item,index) in images" class="text-center margin-top">
<view style="width: 220rpx;height: 220rpx;position: relative;">
<image :src="item" style="width: 220rpx;height: 220rpx;border-radius: 10rpx;"></image>
<view @click="del(index)" class="flex align-center justify-center bg-red round"
style="position: absolute;right: 5rpx;top: 5rpx;width: 30rpx;height: 30rpx;">
<view class="cuIcon-close"></view>
</view>
</view>
</view>
<view v-if="images.length<6" class="text-center margin-top">
<view @click="choose" class="flex align-center justify-center"
:style="'background-color: '+theme.fu_bg+';color: '+theme.fu_text"
style="width: 220rpx;height: 220rpx;border-radius: 10rpx;">
<view class="font-70 cuIcon-camera"></view>
</view>
</view>
</view>
<view @click="getaa"
class="width-600 height-96 radiu-10 bj-0165EE line-height-96 text-center margin-0-auto margin-t-200">
<text class="font-32 color-white">{{i18n.appeal.text1}}</text>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
content: '',
images: [],
upimages: [],
flag: true,
id: '',
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.id = e.id
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
// 申诉
getaa() {
if (this.content == '') return this.tos(this.i18n.appeal.tos1)
if (this.upimages.length == 0) return this.tos(this.i18n.appeal.tos2)
if (!this.flag) {
return
} else {
uni.showLoading({
title: '',
mask: true
})
this.flag = false
let obj = {
id: this.id,
content: this.content,
annex_image: this.upimages.join(',')
}
this.post('/marketotc/shenshu', obj).then(res => {
console.log('申诉返回', res)
uni.hideLoading()
this.flag = true
if (res.code == 1) {
this.content = ''
this.images = ''
this.upimages = ''
this.tos(res.msg)
setTimeout(() => {
uni.redirectTo({
url: '/pages/index/orderDetails?id=' + this.id
})
}, 500)
}
})
}
},
del(e) {
this.images.splice(e, 1)
this.upimages.splice(e, 1)
console.log(this.images, this.upimages)
},
choose() {
var self = this
uni.chooseImage({
count: 6 - self.images.length,
success: (chooseImageRes) => {
const tempFilePaths = chooseImageRes.tempFilePaths;
tempFilePaths.forEach((item, index) => {
console.log(item)
uni.uploadFile({
url: this.upload + '/publics/image_upload',
filePath: item,
name: 'file',
success: (res) => {
let data = JSON.parse(res.data)
uni.hideLoading()
if (data.code == 1) {
console.log(data, index)
self.images = self.images.concat(data.data
.iamge_url)
self.upimages = self.upimages.concat(data.data.url)
}
}
})
})
}
})
}
}
}
</script>
<style lang="scss">
.textbox {
width: 686rpx;
height: 367rpx;
// background: #F6F8FB;
border-radius: 20rpx;
padding: 24rpx;
font-size: 28rpx;
// color: #8B99A2;
}
</style>
+833
View File
@@ -0,0 +1,833 @@
<template>
<view>
<view @click="checkclose()" v-if="isnum||ispay" class="mask1"></view>
<view @click="checkclose()" v-if="isnum||ispay" class="mask2"></view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<!-- 头部 -->
<view slot="top" class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 358rpx)`}">
<view class="width-750 fixed1"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 358rpx)`}">
<!-- 标题 -->
<view class="width-750 height-110 padding-w-30 flex align-center justify-center">
<view @click.stop="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 color-white weight-bold">{{i18n.c2c.title}}</text>
<view class="flex align-center" style="position: absolute;right: 30rpx;">
<view @click.stop="show=true" class="switchbox">
<text class="nummedium-font">{{faby}}</text>
<image class="width-34 height-34 margin-l-5" src="/static/imgs/index/change@2x.png" mode="">
</image>
</view>
</view>
</view>
<!-- 选择买或卖 -->
<view class="height-110 flex align-center padding-w-30">
<view class="flex-1 flex align-center">
<view @click.stop="changeisbuy(2)" class="flex-1" :class="isbuy==2?'onfont':'offfont'">
{{i18n.c2c.text1}}
</view>
<view @click.stop="changeisbuy(1)" class="flex-1" :class="isbuy==1?'onfont':'offfont'">
{{i18n.c2c.text2}}
</view>
<view @click.stop="router.push('/pages/index/releaseTrade')" class="flex-1 offfont">
{{i18n.c2c.text3}}
</view>
</view>
<view class="flex align-center justify-end">
<image @click.stop="router.push('/pages/index/orderRecord')" class="width-54 height-54"
src="/static/imgs/index/jilu@2x.png" mode=""></image>
<!-- <image @click.stop="typeshow=true" class="width-54 height-54"
src="/static/imgs/index/shoukuan@2x.png" mode=""></image> -->
</view>
</view>
<!-- 选择币种 -->
<view class="height-72 bj-0165EE">
<view class="height-72 flex align-center padding-w-30"
:style="'background-color: '+theme.bg+';color: '+theme.text"
style="border-radius: 20rpx 20rpx 0 0;">
<view class="width-100b height-100b">
<scroll-view scroll-x="true">
<view class="flex align-center">
<view @click.stop="setiscurr(item.id)" v-for="(item,index) in currlist"
class="height-72 padding-w-30 flex direction-column align-center justify-center relative">
<text :class="currid==item.id?'select':'noselect'">{{item.name}}</text>
<view v-if="currid==item.id" class="width-48 height-4 bj-0165EE"
style="position: absolute;bottom: 0;"></view>
</view>
</view>
</scroll-view>
</view>
</view>
</view>
<!-- 筛选支付方式和金额 -->
<view class="height-70 flex align-center" :style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 支付方式 -->
<view @click.stop="changeispay" class="width-240 height-70 relative" >
<view class="width-240 height-70 flex align-center justify-center">
<text class="font-26 margin-r-10">{{payname}}</text>
<u-icon v-if="!ispay" name="arrow-down-fill" size="20"></u-icon>
<u-icon v-else name="arrow-up-fill" size="20"></u-icon>
</view>
<view @click.stop="" :class="ispay?'onbox':'offbox'" :style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="padding-w-30 padding-c-20 flex flex-wrap">
<view @click.stop="setpay(item)" v-for="(item,index) in paylist"
:class="payid==item.id?'selectpay':'noselectpay'">{{item.name}}</view>
</view>
</view>
</view>
<!-- 交易金额 -->
<view @click.stop="changeisnum" class="width-240 height-70 relative">
<view class="width-240 height-70 flex align-center justify-center">
<text class="font-26 margin-r-10">{{paypriceval}}</text>
<u-icon v-if="!isnum" name="arrow-down-fill"size="20"></u-icon>
<u-icon v-else name="arrow-up-fill" size="20"></u-icon>
</view>
<view @click.stop="" :class="isnum?'onbox1':'offbox1'" :style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-100 flex align-center padding-w-30">
<input class="inputbox" type="number" v-model="payprice" :placeholder="i18n.c2c.tos4"
placeholder-class="color-D1D3D8" />
</view>
<view class="height-100 padding-t-24 flex">
<view @click="resetpayprice"
class="flex-1 height-78 line-height-78 text-center bj-c3c3c3-02">
<text class="font-26 color-C3C3C3">{{i18n.c2c.text4}}</text>
</view>
<view @click="setpayprice"
class="flex-1 height-78 line-height-78 text-center bj-0165EE">
<text class="font-26 color-white">{{i18n.c2c.text5}}</text>
</view>
</view>
</view>
</view>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750 padding-b-40" :style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="padding-t-18 padding-w-30">
<!-- 单一列表 -->
<view v-for="(item,index) in list" class="height-238 border-bottom">
<view class="flex align-center justify-between padding-t-22">
<view class="flex align-center">
<image class="width-48 height-48 radiu-24" :src="item.avatar" mode=""></image>
<text class="font-26 weight-bold margin-l-16">{{item.nickname}}</text>
</view>
<text class="font-24 color-C3C3C3">{{i18n.c2c.text6}}{{item.succ_num}}</text>
</view>
<view class="margin-c-10 flex align-center justify-between font-24 color-C3C3C3">
<view class="flex align-center">
<text>{{i18n.c2c.text7}}:</text>
<text class="nummedium-font">{{item.residue_num}}</text>
</view>
<text>{{i18n.c2c.text8}}</text>
</view>
<view class="margin-c-10 flex align-center justify-between font-24 color-C3C3C3">
<view class="flex align-center">
<text>{{i18n.c2c.text9}}:</text>
<text class="nummedium-font">{{item.symbol}}{{item.min_price}}-{{item.max_price}}</text>
</view>
<text class="font-30 color-0165EE numbold-font">{{item.symbol}}{{item.price}}</text>
</view>
<view class="flex align-center justify-between margin-t-10">
<image class="width-46 height-42" src="/static/imgs/index/yinhangka.png" mode=""></image>
<view @click.stop="openbuyshow(item)" :class="isbuy==2?'bj-0165EE':'bj-2E558A'"
class="width-140 height-52 radiu-10 line-height-52 text-center">
<text class="font-26 color-white">{{isbuy==2?i18n.c2c.text10:i18n.c2c.text11}}</text>
</view>
</view>
</view>
</view>
</view>
</z-paging>
<!-- 买卖弹窗 -->
<u-popup v-model="buyshow" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-101 flex align-center justify-center">
<text class="font-30 weight-bold">{{isbuy==2?i18n.c2c.text10:i18n.c2c.text11}}{{buyitem.curr_name}}</text>
<view @click.stop="buyshow=false" style="position: absolute;right: 30rpx;"
class="font-26 color-C3C3C3">
{{i18n.c2c.text12}}
</view>
</view>
<!-- 单价 -->
<view class="height-66 flex align-center">
<text class="font-30 margin-r-30">{{i18n.c2c.text8}}</text>
<text class="font-30 color-0165EE nummedium-font">{{buyitem.symbol}}{{buyitem.price}}</text>
</view>
<!-- 购买方式 -->
<view class="height-66 margin-t-28 flex align-center">
<text @click.stop="changetype(1)" :class="type==1?'font-30':'font-26 color-C3C3C3'"
class="margin-r-90">{{i18n.c2c.text13}}{{isbuy==2?i18n.c2c.text10:i18n.c2c.text11}}</text>
<text @click.stop="changetype(2)"
:class="type==2?'font-30':'font-26 color-C3C3C3'">{{i18n.c2c.text14}}{{isbuy==2?i18n.c2c.text10:i18n.c2c.text11}}</text>
</view>
<!-- 金额数量输入框 -->
<view class="margin-t-14">
<view class="numbox">
<input class="font-26 flex-1 padding-r-30 color-D1D3D8" type="number" v-model="number"
:placeholder="i18n.c2c.tos4" placeholder-class="color-D1D3D8" />
<view class="flex align-center font-26">
<text v-if="type==1" class="nummedium-font">{{buyitem.symbol}}</text>
<text v-if="type==2" class="nummedium-font">{{buyitem.curr_name}}</text>
<text class="margin-w-5">丨</text>
<text @click="all(buyitem)" class="font-30 color-0165EE">{{i18n.c2c.text15}}</text>
</view>
</view>
</view>
<!-- 限额 -->
<view class="font-26 color-C3C3C3 margin-t-8">
{{i18n.c2c.text9}}{{buyitem.symbol}}{{buyitem.min_price}}-{{buyitem.max_price}}
</view>
<!-- 交易数量 -->
<view class="height-66 flex align-center justify-between margin-t-22">
<text class="font-30 margin-r-30">{{i18n.c2c.text16}}</text>
<text v-if="type==1" class="font-30 color-0165EE nummedium-font">
{{(number/buyitem.price).toFixed(4)}} {{buyitem.curr_name}}
</text>
<text v-if="type==2" class="font-30 color-0165EE nummedium-font">
{{number==''?'0':number}} {{buyitem.curr_name}}
</text>
</view>
<!-- 实付款 -->
<view class="height-66 flex align-center justify-between margin-t-22">
<text class="font-30 margin-r-30">{{isbuy==2?i18n.c2c.text17:i18n.c2c.text18}}</text>
<text v-if="type==1" class="font-48 color-FF4040 nummedium-font">
{{buyitem.symbol}} {{number==''?'0.00':number}}
</text>
<text v-if="type==2" class="font-48 color-FF4040 nummedium-font">
{{buyitem.symbol}} {{(number*buyitem.price).toFixed(2)}}
</text>
</view>
<!-- 收款账户 -->
<view @click="show2=true" v-if="isbuy==1"
class="height-66 flex align-center justify-between margin-t-22">
<text class="font-30 margin-r-30">{{i18n.c2c.text19}}</text>
<view class="flex align-center font-30">
<text v-if="collecid!=''">{{collecdata.card_num|changestyle}}</text>
<u-icon name="arrow-right" color="#8B99A2" size="24"></u-icon>
</view>
</view>
<!-- 交易密码 -->
<view class="margin-t-22">
<text class="font-30 margin-r-30">{{i18n.c2c.text20}}</text>
<view class="numbox margin-t-25">
<input class="font-26 flex-1 color-D1D3D8" type="number" v-model="paypwd"
:placeholder="i18n.c2c.tos3" placeholder-class="color-D1D3D8" password />
</view>
</view>
<!-- 按钮 -->
<view class="margin-t-61 flex align-center justify-between">
<view @click.stop="buyshow=false"
class="width-305 height-96 radiu-10 bj-D1D3D8 line-height-96 text-center">
<text class="font-30 color-white">{{i18n.c2c.text12}}</text>
</view>
<view @click.stop="closebuyshow"
class="width-305 height-96 radiu-10 bj-0165EE line-height-96 text-center">
<text
class="font-30 color-white">{{i18n.c2c.text5}}{{isbuy==2?i18n.c2c.text10:i18n.c2c.text11}}</text>
</view>
</view>
</view>
</u-popup>
<!-- 法币弹窗 -->
<u-popup v-model="show" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-96 line-height-96 text-center relative">
<text class="font-30 weight-bold">{{i18n.c2c.text21}}</text>
<text @click.stop="show=false" class="font-26 color-C3C3C3 absolute"
style="right: 0;">{{i18n.c2c.text12}}</text>
</view>
<scroll-view scroll-y="true" class="height-450">
<view @click="setFaby(item)" v-for="(item,index) in fabylist"
class="height-96 flex align-center justify-between">
<view class="flex align-center">
<image class="width-48 height-48 radiu-24" :src="item.pay_image" mode=""></image>
<text class="font-28 margin-l-16">{{item.curr_name}}</text>
</view>
<image class="width-36 height-36" :src="fabyid==item.id?XZ:WX" mode=""></image>
</view>
</scroll-view>
</view>
</u-popup>
<!-- 收款账户弹窗 -->
<u-popup v-model="show2" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-96 line-height-96 text-center relative">
<text class="font-30 weight-bold">{{i18n.c2c.text19}}</text>
<text @click.stop="show2=false" class="font-26 color-C3C3C3 absolute"
style="right: 0;">{{i18n.c2c.text12}}</text>
</view>
<scroll-view scroll-y="true" class="height-450">
<view @click="setcollec(item)" v-for="(item,index) in collec"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text"
class="height-96 flex align-center justify-between margin-b-10 radiu-10 padding-w-20">
<view class="flex-1 padding-r-24 height-96 flex direction-column justify-around">
<view class="flex align-center">
<text>{{item.username}}</text>
<text class="font-28 margin-l-16">{{item.card_num|changestyle}}</text>
</view>
<view class="font-24 color-C3C3C3">{{item.bank_name}}</view>
</view>
<image class="width-36 height-36" :src="collecid==item.id?XZ:WX" mode=""></image>
</view>
</scroll-view>
</view>
</u-popup>
<!-- 去实名 -->
<u-popup style="z-index: 5000;" border-radius="18" mode="center" v-model="TSShow">
<view class="width-600 padding-b-20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="width-100b height-220 padding-w-30 padding-c-40 flex direction-column align-center justify-between">
<image class="width-64 height-64" src="/static/imgs/quantify/tongzhi@2x.png" mode=""></image>
<view class="font-26 weight-bold text-center padding-w-20">{{i18n.c2c.text22}}
</view>
</view>
<view class="width-100b height-90 flex align-center justify-center">
<view @click="TSShow=false,router.push('/pages/my/safety/real')" class="qcbtn3">{{i18n.c2c.text23}}
</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
isbuy: 2, //2买,1卖
list: [],
page: 1,
state: 'more',
show: false, //法币弹窗
show1: false, //支付方式弹窗
buyshow: false, //购买弹窗
typeshow: false, //收款方式弹窗
type: 1, //1按金额购买,2按数量购买
currid: '', //当前币种id
currlist: [], //币种列表
faby: '', //法币
fabyid: '', //法币id
fabylist: [], //法币列表
WX: '/static/imgs/quantify/weixuanzhong@2x.png',
XZ: '/static/imgs/quantify/xuanzhong@2x.png',
ispay: false, //支付方式弹窗
payid: 0, //选择的支付方式
payname: '支付方式',
paylist: [{
id: 0,
name: '全部'
},
{
id: 1,
name: '银行卡'
}
],
isnum: false, //交易金额弹窗
payprice: '', //交易金额
paypriceval: '交易金额', //交易金额文显
number: '',
paypwd: '',
buyitem: '', //购买对象
flag: true,
show2: false,
collec: [], //收款账户列表
collecid: '', //当前收款账户id
collecdata: '', //当前收款账户对象
TSShow: false,
theme: '',
}
},
onLoad() {
this.payname = this.i18n.c2c.text26
this.paypriceval = this.i18n.c2c.text24
this.paylist[0].name = this.i18n.c2c.text15
this.paylist[1].name = this.i18n.c2c.text25
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getFabylist()
this.getCurrlist()
this.getcollection()
},
filters: {
changestyle(e) {
let str = e
var reg = /^(\d{4})\d+(\d{4})$/;
str = str.replace(reg, "$1 **** $2");
return str
}
},
methods: {
// 选择账户
setcollec(item) {
if (this.collecid != item.id) {
this.collecid = item.id
this.collecdata = item
this.show2 = false
}
},
// 获取收款账户列表
getcollection() {
this.post('/marketotc/get_collection').then(res => {
console.log('收款账户列表', res)
if (res.code == 1 && res.data && res.data.length > 0) {
this.collec = res.data
this.collecid = res.data[0].id
this.collecdata = res.data[0]
} else {
// 如果没有收款账户或数据为空,设置默认值或提示用户添加收款账户
this.collec = []
this.collecid = ''
this.collecdata = ''
}
})
},
// 挂单出售
getsell() {
if (this.number == '' && this.type == 1) return this.tos(this.i18n.c2c.tos1)
if (this.number == '' && this.type == 2) return this.tos(this.i18n.c2c.tos2)
if (this.paypwd == '') return this.tos(this.i18n.c2c.tos3)
if (!this.flag) {
return
} else {
this.flag = false
let obj = {
id: this.buyitem.id,
num: this.number,
pay_pwd: this.paypwd,
buy_type: this.type,
collection_id: this.collecid
}
this.post('/marketotc/order_sell', obj).then(res => {
console.log('下单返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.buyshow = false
setTimeout(() => {
uni.navigateTo({
url: '/pages/index/orderRecord'
})
}, 500)
} else {
if (res.data.jump == 1) {
uni.hideToast()
this.buyshow = false
this.TSShow = true
}
}
})
}
},
// 挂单买入
getbuy() {
if (this.number == '' && this.type == 1) return this.tos(this.i18n.c2c.tos1)
if (this.number == '' && this.type == 2) return this.tos(this.i18n.c2c.tos2)
if (this.paypwd == '') return this.tos(this.i18n.c2c.tos3)
if (!this.flag) {
return
} else {
this.flag = false
let obj = {
id: this.buyitem.id,
num: this.number,
pay_pwd: this.paypwd,
buy_type: this.type
}
this.post('/marketotc/order_buy', obj).then(res => {
console.log('下单返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.buyshow = false
setTimeout(() => {
uni.navigateTo({
url: '/pages/index/orderRecord'
})
}, 500)
} else {
if (res.data.jump == 1) {
uni.hideToast()
this.buyshow = false
this.TSShow = true
}
}
})
}
},
// 关闭买卖弹窗
closebuyshow() {
var that = this
uni.showLoading({
title: that.i18n.c2c.tos5,
mask: true
})
if (this.isbuy == 2) {
this.getbuy()
} else {
this.getsell()
}
},
// 全部
all(item) {
if (this.type == 1) {
this.number = item.money_fb
} else {
this.number = item.money_num
}
},
// 打开购买或出售弹窗
openbuyshow(item) {
console.log(item)
if (item.is_me) {
this.tos(this.i18n.c2c.tos6)
} else {
this.buyitem = item
this.number = ''
this.paypwd = ''
this.type = 1
this.buyshow = true
}
},
// 获取挂单列表
queryList(pageNo, pageSize) {
let obj = {
page:this.pageNo,
page_num: pageSize,
type: this.isbuy,
country_id: this.fabyid,
curr_id: this.currid,
payment: this.payid,
price: this.payprice
}
setTimeout(()=>{
this.post('/marketotc/market_list', obj).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
},500)
},
// 重置交易金额
resetpayprice() {
this.paypriceval = this.i18n.c2c.text24
this.payprice = ''
this.isnum = !this.isnum
this.queryList(1,10)
},
// 设置交易金额
setpayprice() {
if (this.payprice != '' && this.payprice != 0) {
this.paypriceval = this.payprice
this.isnum = !this.isnum
this.queryList(1,10)
}
},
// 改变交易金额弹窗
changeisnum() {
if (this.ispay) {
this.ispay = !this.ispay
} else {
this.isnum = !this.isnum
}
},
// 改变支付方式弹窗
changeispay() {
if (this.isnum) {
this.isnum = !this.isnum
} else {
this.ispay = !this.ispay
}
},
// 检查支付方式和交易金额弹窗
checkclose() {
if (this.ispay) {
this.ispay = false
}
if (this.isnum) {
this.isnum = false
}
},
// 选择支付方式
setpay(item) {
if (this.payid != item.id) {
this.ispay = false
this.payid = item.id
this.queryList(1,10)
if (item.name == this.i18n.c2c.text15) {
this.payname = this.i18n.c2c.text26
} else {
this.payname = item.name
}
}
},
// 获取交易币种
getCurrlist() {
this.post('/marketotc/get_curr').then(res => {
console.log('币种列表', res)
if (res.code == 1) {
this.currlist = res.data
this.currid = res.data[0].id
}
})
},
// 选择法币
setFaby(item) {
this.faby = item.curr_name
this.fabyid = item.id
this.show = false
this.queryList(1,10)
},
// 获取法币列表
getFabylist() {
this.post('/marketotc/get_country').then(res => {
console.log('法币列表', res)
if (res.code == 1) {
this.fabylist = res.data
this.faby = res.data[0].curr_name
this.fabyid = res.data[0].id
}
})
},
// 选择币种
setiscurr(i) {
if (this.currid != i) {
this.currid = i
this.queryList(1,10)
}
},
// 选择金额或数量购买
changetype(i) {
if (this.type != i) {
this.type = i
this.number = ''
}
},
// 选择买或卖
changeisbuy(i) {
if (this.isbuy != i) {
this.isbuy = i
this.queryList(1,10)
}
},
}
}
</script>
<style lang="scss">
.transition1 {
overflow: hidden;
transition: 1s;
}
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
background: #06C38D;
}
.fabubox {
width: 180rpx;
height: 56rpx;
background: #FFFFFF;
border-radius: 28rpx 0rpx 0rpx 28rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 28rpx;
color: #0165EE;
}
.onfont {
font-size: 32rpx;
font-weight: bold;
color: #FFFFFF;
}
.offfont {
font-size: 28rpx;
font-weight: 400;
color: #FFFFFF;
opacity: 0.5;
}
.select {
font-size: 28rpx;
font-family: "Bold" !important;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color: #06C38D;
}
.noselect {
font-size: 26rpx;
font-family: "Medium" !important;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color: #8B99A2;
}
.border-bottom {
border-bottom: 1rpx solid rgba(191, 195, 199, 0.2);
}
.bj-c3c3c3-02 {
background-color: rgba(195, 195, 195, 0.2);
}
.numbox {
width: 690rpx;
height: 96rpx;
// background: #FFFFFF;
border: 1rpx solid #D1D3D8;
opacity: 1;
border-radius: 10rpx;
padding: 0 16rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
.searchbox {
width: 610rpx;
height: 60rpx;
background: #F6F8FC;
border: 1rpx solid rgba(191, 195, 199, 0.2);
opacity: 1;
border-radius: 30rpx;
}
.offbox {
width: 750rpx;
height: 0rpx;
overflow: hidden;
// background-color: #FFFFFF;
transition: height 0.3s;
box-shadow: 0rpx 4rpx 10rpx #EBF0F6;
}
.onbox {
width: 750rpx;
height: 200rpx;
// background-color: #FFFFFF;
transition: height 0.3s;
box-shadow: 0rpx 4rpx 10rpx #EBF0F6;
}
.offbox1 {
width: 750rpx;
height: 0rpx;
overflow: hidden;
// background-color: #FFFFFF;
transition: height 0.3s;
position: absolute;
left: -240rpx;
}
.onbox1 {
width: 750rpx;
height: 200rpx;
// background-color: #FFFFFF;
transition: height 0.3s;
position: absolute;
left: -240rpx;
}
.selectpay {
width: 220rpx;
height: 46rpx;
border-radius: 23rpx;
border: 1rpx solid #06C38D;
line-height: 46rpx;
text-align: center;
font-size: 26rpx;
color: #06C38D;
margin: 0 20rpx 10rpx 0;
}
.noselectpay {
width: 220rpx;
height: 46rpx;
border-radius: 23rpx;
border: 1rpx solid #D1D3D8;
line-height: 46rpx;
text-align: center;
font-size: 26rpx;
color: #D1D3D8;
margin: 0 20rpx 10rpx 0;
}
.inputbox {
width: 100%;
height: 68rpx;
border-radius: 10rpx;
// background: #F6F8FC;
border: 1rpx solid rgba(195, 195, 195, 0.3);
font-size: 28rpx;
// color: #17181A;
padding: 0 24rpx;
}
.mask1 {
width: 100vh;
height: calc(var(--status-bar-height) + 292rpx);
position: fixed;
top: 0;
z-index: 10000;
// background: #007F0E;
}
.mask2 {
width: 100vh;
height: calc(100vh - var(--status-bar-height) - 558rpx);
position: fixed;
bottom: 0;
z-index: 10000;
background: rgba(0, 0, 0, 0.5);
}
.qcbtn3 {
width: 320rpx;
height: 86rpx;
background: #0165EE;
border-radius: 20rpx;
font-size: 28rpx;
font-weight: bold;
color: #FFFFFF;
display: flex;
align-items: center;
justify-content: center;
}
</style>
+274
View File
@@ -0,0 +1,274 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<!-- 头部 -->
<view class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 220rpx)`}">
<view class="width-750 fixed1 bj-0165EE"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 220rpx)`}">
<view class="width-750 height-110 padding-w-30 flex align-center justify-center">
<view @click="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 color-white weight-bold">{{i18n.fastBuy.title1}}</text>
<view class="flex align-center" style="position: absolute;right: 30rpx;">
<view @click="show=true" class="switchbox">
<text class="nummedium-font">{{faby.curr_name}}</text>
<image class="width-34 height-34 margin-l-13" src="/static/imgs/index/change@2x.png"></image>
</view>
</view>
</view>
<view class="height-110 flex align-center padding-w-30">
<view class="flex-10 flex align-center">
<view @click="changeType(1)" class="flex-1" :class="currtype==1?'onfont':'offfont'">{{i18n.fastBuy.text1}}</view>
<view @click="changeType(2)" class="flex-1" :class="currtype==2?'onfont':'offfont'">{{i18n.fastBuy.text2}}</view>
</view>
<view class="flex-2 flex align-center justify-end">
<image @click="router.push('/pages/index/fastDetails')" class="width-54 height-54" src="/static/imgs/index/jilu@2x.png"></image>
</view>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750 padding-b-40" :style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 价格 -->
<view class="height-148 bj-0061E8">
<view class="pricebox" :style="'background-color: '+theme.bg+';color: '+theme.text">
<text class="font-30">{{i18n.fastBuy.text3}}</text>
<text class="font-36 numbold-font">1 USDT ≈ {{faby.usdt_price}} {{faby.curr_name}}</text>
</view>
</view>
<!-- 按金额 -->
<view v-if="currtype==1">
<!-- 金额 -->
<view class="height-192 margin-t-45 padding-w-30">
<view class="height-96 flex align-center font-32">{{i18n.fastBuy.text4}}</view>
<view class="height-96 flex align-center">
<text class="font-28">{{faby.symbol}}</text>
<input class="padding-l-20 font-32" :placeholder="i18n.fastBuy.tos1" type="number" v-model="price" />
</view>
</view>
<!-- 数量 -->
<view class="flex align-center justify-between margin-t-27 padding-w-30">
<text class="font-32">{{i18n.fastBuy.text5}}</text>
<text class="font-42 color-0165EE numbold-font">{{price==''?'0':(price/faby.usdt_price).toFixed(8)}}</text>
</view>
</view>
<!-- 按数量 -->
<view v-if="currtype==2">
<!-- 购买数量 -->
<view class="height-192 margin-t-45 padding-w-30">
<view class="height-96 flex align-center font-32">{{i18n.fastBuy.text6}}</view>
<view class="height-96 flex align-center justify-between">
<input class="font-32" :placeholder="i18n.fastBuy.tos2" type="number" v-model="number" />
<view class="flex align-center">
<text class="font-32 nummedium-font">USDT</text>
</view>
</view>
</view>
<!-- 实付款 -->
<view class="flex align-center justify-between margin-t-27 padding-w-30">
<text class="font-32">{{i18n.fastBuy.text7}}</text>
<text class="font-42 color-0165EE numbold-font">{{faby.symbol}} {{number==''?'0':(number*faby.usdt_price).toFixed(2)}}</text>
</view>
</view>
<!-- 交易方式 -->
<view class="height-96 padding-w-30 flex align-center justify-between">
<text class="font-32">{{i18n.fastBuy.text8}}</text>
<text class="font-32 color-C3C3C3">{{faby.pay_name}}</text>
</view>
<view @click="router.push('/pages/my/aboutUs/agreement?title=tuikuan')" class="height-96 padding-w-30 flex align-center">
<text class="font-28">{{i18n.recharge.text18}}</text>
<i class="cuIcon-question"></i>
</view>
<!-- 按钮 -->
<view @click="getbuy" class="buybtn">
<image class="width-32 height-32 margin-r-10" src="/static/imgs/index/kjbtn.png" mode=""></image>
<text>{{i18n.fastBuy.text9}}</text>
</view>
</view>
<!-- 法币弹窗 -->
<u-popup v-model="show" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-96 line-height-96 text-center relative">
<text class="font-32 weight-bold">{{i18n.fastBuy.text10}}</text>
<text @click.stop="show=false" class="font-26 color-C3C3C3 absolute" style="right: 0;">{{i18n.fastBuy.text11}}</text>
</view>
<scroll-view scroll-y="true" class="height-450">
<view @click="selectfaby(item)" v-for="(item,index) in fabylist"
class="height-96 flex align-center justify-between">
<view class="flex align-center">
<image class="width-48 height-48 radiu-24" :src="item.pay_image" mode=""></image>
<text class="font-30 margin-l-16">{{item.curr_name}}</text>
</view>
<image class="width-36 height-36" :src="faby.id==item.id?XZ:WX" mode=""></image>
</view>
</scroll-view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
currtype: 1,
show: false,
fabylist: [],
faby: '',
WX: '/static/imgs/quantify/weixuanzhong@2x.png',
XZ: '/static/imgs/quantify/xuanzhong@2x.png',
price: '',
number: '',
flag: true,
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getFabylist()
},
methods: {
// 购买
getbuy() {
if (!this.flag) {
return
} else {
if (this.currtype == 1) {
if (this.price == '') return this.tos(this.i18n.fastBuy.tos1)
var obj = {
id: this.faby.id,
type: this.currtype,
number: this.price
}
}
if (this.currtype == 2) {
if (this.number == '') return this.tos(this.i18n.fastBuy.tos2)
var obj = {
id: this.faby.id,
type: this.currtype,
number: this.number
}
}
this.flag = false
console.log(obj)
this.post('/Marketpay/add_order', obj).then(res => {
this.flag = true
this.number = ''
this.price = ''
console.log(res)
if (res.code == 1) {
}
})
}
},
// 获取法币列表
getFabylist() {
this.post('/Marketpay/get_country').then(res => {
console.log(res)
if (res.code == 1) {
this.fabylist = res.data
this.faby = res.data[0]
}
})
},
selectfaby(item) {
if (this.faby.id != item.id) {
this.faby = item
this.show = false
}
},
changeType(i) {
if (this.currtype != i) {
this.currtype = i
this.number = ''
this.price = ''
}
},
}
}
</script>
<style lang="scss">
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
// background-color: #FFFFFF;
}
.fabubox {
width: 180rpx;
height: 56rpx;
background: #FFFFFF;
border-radius: 28rpx 0rpx 0rpx 28rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 30rpx;
color: #0165EE;
}
.onfont {
font-size: 42rpx;
font-weight: bold;
color: #FFFFFF;
}
.offfont {
font-size: 32rpx;
font-weight: 400;
color: #FFFFFF;
opacity: 0.5;
}
.pricebox {
width: 750rpx;
height: 148rpx;
// background: #FFFFFF;
opacity: 1;
border-radius: 20rpx 20rpx 0 0;
padding: 20rpx 30rpx 15rpx;
display: flex;
flex-direction: column;
justify-content: space-between;
}
.buybtn {
width: 690rpx;
height: 96rpx;
background: #0165EE;
opacity: 1;
border-radius: 10rpx;
margin: 220rpx auto 0;
display: flex;
align-items: center;
justify-content: center;
font-size: 32rpx;
color: #FFFFFF;
}
.searchbox {
width: 610rpx;
height: 60rpx;
background: #F6F8FC;
border: 1rpx solid rgba(191, 195, 199, 0.2);
opacity: 1;
border-radius: 30rpx;
}
</style>
+83
View File
@@ -0,0 +1,83 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.fastBuy.title2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-t-32 padding-b-40">
<view v-for="(item,index) in list" class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="padding-w-30 height-74 flex align-center font-24">
<text>{{i18n.fastBuy.text12}}:</text>
<text class="numbold-font">{{item.createtime}}</text>
</view>
<view class="height-1 width-100b" style="background: rgba(191,195,199,0.3);"></view>
<view class="height-105 flex padding-w-30">
<view class="height-105 flex-1 flex direction-column padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastBuy.text13}}</text>
<text class="font-24 numbold-font">{{item.num}}</text>
</view>
<view class="height-105 flex-1 flex direction-column align-end padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastBuy.text14}}</text>
<text class="font-24 numbold-font">{{item.symbol}}{{item.price}}</text>
</view>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/Marketpay/order_list', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
}
}
</script>
<style lang="scss">
.box {
width: 690rpx;
height: 180rpx;
// background: #FFFFFF;
box-shadow: 0rpx 4rpx 4rpx rgba(205, 206, 219, 0.2);
opacity: 1;
border-radius: 20rpx;
margin-bottom: 20rpx;
}
</style>
+186
View File
@@ -0,0 +1,186 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.fastRecord.title"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-b-40 padding-t-16">
<!-- 单一列表 -->
<view v-for="(item,index) in list" class="listbox" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="height-74 flex align-center">
<view class="flex-1 height-74 flex align-center font-24">
<text>{{i18n.fastRecord.text1}}:</text>
<text class="numbold-font">{{item.createtime}}</text>
</view>
<text class="font-28"
:class="item.type==1?'color-00C481':'color-FF4040'">{{item.type==1?i18n.fastRecord.text2:i18n.fastRecord.text3}}</text>
</view>
<view class="height-1 width-100b" style="background: rgba(191,195,199,0.3);"></view>
<view class="height-105 flex">
<view class="height-105 flex-1 flex direction-column padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastRecord.text4}}</text>
<text class="font-24 numbold-font">{{item.price}}</text>
</view>
<view class="height-105 flex-1 flex direction-column align-center padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastRecord.text5}}({{item.curr_name}})</text>
<text class="font-24 numbold-font">{{(item.num)}}</text>
</view>
<view class="height-105 flex-1 flex direction-column align-end padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastRecord.text6}}({{item.curr_name}})</text>
<text class="font-24 numbold-font">{{item.residue_num}}</text>
</view>
</view>
<view class="height-105 flex">
<view class="height-105 flex-1 flex direction-column padding-c-16 justify-between">
<text
class="font-24 color-C3C3C3">{{item.type==1?i18n.fastRecord.text7:i18n.fastRecord.text8}}</text>
<text
class="font-24 numbold-font">{{item.payment==1?i18n.fastRecord.text9:''}}</text>
</view>
<view class="height-105 flex-1 flex direction-column align-center padding-c-16 justify-between">
<text class="font-24 color-C3C3C3">{{i18n.fastRecord.text10}}</text>
<text class="font-24 color-0165EE">{{statusText[item.status]}}</text>
</view>
<view v-if="item.status==1"
class="height-105 flex-1 flex direction-column align-end padding-c-16 justify-center">
<view @click="show=true,id=item.id,paypwd=''"
class="width-138 height-56 bj-0165EE radiu-10 line-height-56 text-center">
<text class="font-28 color-white">{{i18n.fastRecord.text11}}</text>
</view>
</view>
<view v-else class="flex-1"></view>
</view>
</view>
</view>
</z-paging>
<!-- 撤销弹窗 -->
<u-popup v-model="show" mode="center" border-radius="20">
<view class="width-600 height-342" style="overflow: hidden;"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-110 flex align-center justify-center">
<text class="font-30 color-FF4040 weight-bold">{{i18n.fastRecord.text12}}</text>
</view>
<input class="input" :style="'background-color: '+theme.fu_bg"
type="text" v-model="paypwd" :placeholder="i18n.fastRecord.tos1" password />
<view class="height-98 flex margin-t-60">
<view @click="show=false" class="flex-1 line-height-96 text-center bj-c3c3c3-02">
<text class="font-28 color-C3C3C3 weight-bold">{{i18n.fastRecord.text13}}</text>
</view>
<view @click="getwithdraw" class="flex-1 line-height-96 text-center bj-0165EE">
<text class="font-28 color-white weight-bold">{{i18n.fastRecord.text14}}</text>
</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
show: false,
list: [],
page: 1,
state: 'more',
flag: true,
id: '',
paypwd: '',
statusText: ['', '', '', '', ''],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.changestatus()
},
methods: {
changestatus() {
this.statusText[1] = this.i18n.fastRecord.text15
this.statusText[2] = this.i18n.fastRecord.text16
this.statusText[3] = this.i18n.fastRecord.text17
this.statusText[4] = this.i18n.fastRecord.text18
},
// 撤销挂单
getwithdraw() {
if (!this.flag) {
return
} else {
if (this.paypwd == '') return this.tos(this.i18n.fastRecord.tos1)
uni.showLoading({
title: '',
mask: true
})
this.flag = false
let obj = {
id: this.id,
pay_pwd: this.paypwd
}
this.post('/marketotc/order_withdraw', obj).then(res => {
this.flag = true
console.log('撤销返回', res)
if (res.code == 1) {
this.show = false
uni.hideLoading()
this.tos(res.msg)
this.queryList(1, 20)
}
})
}
},
queryList(pageNo, pageSize) {
this.post('/marketotc/my_fb_list', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
},
}
}
</script>
<style lang="scss">
.listbox {
width: 690rpx;
height: 285rpx;
// background: #FFFFFF;
opacity: 1;
border-radius: 10rpx;
margin-bottom: 8rpx;
padding: 0 22rpx;
}
.bj-c3c3c3-02 {
background: rgba(195, 195, 195, 0.2);
}
.input {
width: 540rpx;
height: 76rpx;
margin: 0 auto;
border-radius: 20rpx;
// background: #F6F8FC;
font-size: 28rpx;
// color: #8B99A2;
padding: 0 24rpx;
}
</style>
+341
View File
@@ -0,0 +1,341 @@
<template>
<view class="page" :style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="header" :style="{ paddingTop: statusBar + 'px', backgroundColor: theme.bg }">
<view class="header-inner">
<text class="header-title" :style="'color: '+theme.text">{{ i18n.tabBar.market }}</text>
</view>
</view>
<view class="subtabs">
<view class="subtab-item">
<text class="subtab-text" :style="'color: '+theme.text">{{ i18n.market.crypto }}</text>
<view class="subtab-underline" style="background-color: #3c9cff;"></view>
</view>
</view>
<view class="section-title" :style="'color: '+theme.text">{{ i18n.tabBar.market }}</view>
<scroll-view scroll-y class="list">
<view v-for="(item,index) in list" :key="item.symbol" class="row" :style="rowStyle(index)" @click="gokline(item)">
<view class="row-left">
<view class="logo-wrap" :style="'background-color: '+(theme.fu_bg || '#F5F6F7')">
<image v-if="item.logo" class="logo" :src="item.logo" mode="aspectFit"></image>
<text v-else class="logo-text" :style="'color: '+theme.text">{{ item.symbol.slice(0, 1) }}</text>
</view>
<view class="coin-info">
<text class="pair" :style="'color: '+theme.text">{{ item.symbol }}</text>
<view class="price-line">
<text class="price" :style="'color: '+priceColor(item)">{{ item.priceText }}</text>
<text class="change" :style="'color: '+priceColor(item)">{{ item.changeText }}</text>
</view>
</view>
</view>
<view class="row-mid">
<text class="mid-top" :style="'color: '+theme.text">{{ item.rightTop }}</text>
<view class="mid-sub" :style="'color: '+(theme.fu_text || '#9AA0A6')">
<text class="sub-label">H:</text>
<text class="sub-val">{{ item.high }}</text>
</view>
</view>
<view class="row-right">
<text class="right-top" :style="'color: '+theme.text">{{ item.rightTop2 }}</text>
<view class="right-sub" :style="'color: '+(theme.fu_text || '#9AA0A6')">
<text class="sub-label">L:</text>
<text class="sub-val">{{ item.low }}</text>
</view>
</view>
</view>
</scroll-view>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
theme: '',
list: [],
realTimeTimer: null,
realTimeInFlight: false
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
this.theme = this.$store.state.lightTheme
this.startRealTime()
},
onHide() {
this.stopRealTime()
},
onUnload() {
this.stopRealTime()
},
methods: {
formatFixed(val, fixed) {
const n = Number(val)
if (!Number.isFinite(n)) return val == null ? '' : String(val)
const f = Number.isFinite(Number(fixed)) ? Number(fixed) : 2
return n.toFixed(f)
},
startRealTime() {
this.stopRealTime()
this.getMarketList()
this.realTimeTimer = setInterval(() => {
this.getMarketList()
}, 3000)
},
stopRealTime() {
if (this.realTimeTimer) {
clearInterval(this.realTimeTimer)
this.realTimeTimer = null
}
this.realTimeInFlight = false
},
formatAmountUnit(num) {
const n = Number(num)
if (!Number.isFinite(n) || n === 0) return '0w'
const abs = Math.abs(n)
if (abs >= 1e8) return (n / 1e8).toFixed(2) + 'w'
if (abs >= 1e4) return (n / 1e4).toFixed(2) + 'w'
return n.toFixed(2) + 'w'
},
getMarketList() {
if (this.realTimeInFlight) return
this.realTimeInFlight = true
this.post('/market/get_coin').then(res => {
if (res.code == 1) {
const coin = (res.data && Array.isArray(res.data.coin)) ? res.data.coin : []
this.list = coin.map((c) => {
const increase = Number(c && c.increase != null ? c.increase : 0)
const dir = increase > 0 ? 1 : (increase < 0 ? -1 : 0)
const priceJd = Number(c && c.price_jd != null ? c.price_jd : 2)
const close = Number(c && c.close != null ? c.close : 0)
const high = c && c.high != null ? this.formatFixed(c.high, priceJd) : ''
const low = c && c.low != null ? this.formatFixed(c.low, priceJd) : ''
return {
coinname: (c && (c.coinname || c.name)) ? (c.coinname || c.name) : '',
bb_type: c && c.bb_type != null ? c.bb_type : '',
rawSymbol: c && c.symbol ? c.symbol : '',
symbol: (c && c.name ? (c.name + '/USDT') : (c && c.symbol ? c.symbol : '')),
priceText: Number.isFinite(close) ? close.toFixed(priceJd) : '0',
changeText: (Number.isFinite(increase) ? (increase * 100).toFixed(2) : '0.00') + '%',
dir,
rightTop: c && c.amount ? c.amount : '',
rightTop2: c && c.count_price ? this.formatAmountUnit(c.count_price) : '',
high,
low,
logo: c && (c.logo_image || c.logo || ''),
usdt: close
}
})
}
}).finally(() => {
this.realTimeInFlight = false
})
},
gokline(item) {
const symbol = (item && item.rawSymbol) ? item.rawSymbol : (item && item.symbol ? item.symbol : '')
const title = item && item.coinname ? item.coinname : ''
const bbType = item && item.bb_type != null ? item.bb_type : ''
// #ifdef H5
uni.navigateTo({
url: '/pages/tradingView/h5?title=' + title + '&bb_type=' + bbType + '&symbol=' + symbol
})
// #endif
// #ifdef APP-PLUS
uni.navigateTo({
url: '/pages/tradingView/index?title=' + title + '&bb_type=' + bbType + '&symbol=' + symbol + '&close=' + (item && item.usdt != null ? item.usdt : '')
})
// #endif
},
priceColor(item) {
if (item.dir > 0) return '#16C784'
if (item.dir < 0) return '#EA3943'
return this.theme.text
},
rowStyle(index) {
const border = this.theme.fu_bg || '#F0F0F0'
if (index === this.list.length - 1) return ''
return 'border-bottom: 1rpx solid ' + border
}
}
}
</script>
<style lang="scss" scoped>
.page {
min-height: 100vh;
background: #ffffff;
display: flex;
flex-direction: column;
}
.header {
position: sticky;
top: 0;
z-index: 10;
}
.header-inner {
height: 88rpx;
display: flex;
align-items: center;
padding: 0 24rpx;
}
.header-title {
font-size: 34rpx;
font-weight: 700;
line-height: 1;
}
.subtabs {
padding: 14rpx 24rpx 0;
}
.subtab-item {
display: inline-flex;
flex-direction: column;
align-items: flex-start;
}
.subtab-text {
font-size: 26rpx;
font-weight: 500;
line-height: 1.2;
}
.subtab-underline {
width: 42rpx;
height: 6rpx;
border-radius: 999rpx;
margin-top: 10rpx;
}
.section-title {
padding: 14rpx 24rpx 10rpx;
font-size: 34rpx;
font-weight: 800;
}
.list {
flex: 1;
min-height: 0;
}
.row {
display: flex;
align-items: center;
padding: 40rpx 15rpx;
}
.row-left {
display: flex;
align-items: center;
flex: 1 1 46%;
min-width: 0;
}
.logo-wrap {
width: 56rpx;
height: 56rpx;
border-radius: 999rpx;
display: flex;
align-items: center;
justify-content: center;
flex: 0 0 56rpx;
}
.logo {
width: 36rpx;
height: 36rpx;
}
.logo-text {
font-size: 26rpx;
font-weight: 700;
}
.coin-info {
margin-left: 16rpx;
min-width: 0;
flex: 1;
}
.pair {
display: block;
font-size: 28rpx;
font-weight: 800;
line-height: 1.2;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.price-line {
margin-top: 8rpx;
display: flex;
align-items: baseline;
gap: 14rpx;
}
.price {
font-size: 22rpx;
line-height: 1.2;
}
.change {
font-size: 22rpx;
line-height: 1.2;
font-weight: 500;
}
.row-mid,
.row-right {
display: flex;
flex-direction: column;
align-items: flex-end;
justify-content: center;
flex: 0 0 27%;
min-width: 0;
}
.row-mid {
padding-right: 10rpx;
}
.mid-top,
.right-top {
font-size: 24rpx;
font-weight: 600;
line-height: 1.2;
white-space: nowrap;
}
.mid-sub,
.right-sub {
margin-top: 10rpx;
display: flex;
align-items: baseline;
gap: 10rpx;
white-space: nowrap;
}
.sub-label {
font-size: 20rpx;
line-height: 1.2;
}
.sub-val {
font-size: 20rpx;
line-height: 1.2;
}
</style>
+254
View File
@@ -0,0 +1,254 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<!-- 头部 -->
<view class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 fixed1" :style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 height-110 padding-w-30 flex align-center justify-center">
<view @click="_goback" class="cuIcon-back font-40 "
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 weight-bold">{{data.name}}</text>
<view @click="router.push('/pages/index/white_paper?ico='+ico)" class="font-30 absolute" style="right: 30rpx;">{{i18n.ico.three6}}</view>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750">
<view class="padding-w-30 padding-t-45 ">
<view class="padding-b-200">
<view class="flex align-center justify-between">
<text class="font-36 numbold-font">{{i18n.ico.title}}</text>
<view @click="router.push('/pages/index/icoDetails?ico=' + ico)" class="morebtn">{{i18n.ico.text3}}</view>
</view>
<view class="margin-t-20 width-100b hidden-nowrap-ellipsis-3 font-26">
{{data.content_txt}}
</view>
<view class="inputbox padding-t-24 padding-w-16" :style="'background-color: '+theme.fu_bg">
<text class="font-30 weight-bold">{{i18n.ico.title}}{{i18n.ico.text4}}</text>
<u-line-progress class="margin-t-23" :striped="true" :striped-active="true"
:percent="percentage" height="24" active-color="#3ECEB2">
</u-line-progress>
<view class="flex align-center justify-between margin-t-18">
<text class="font-26 color-0165EE numbold-font">{{data.count_num}} {{data.curr_name}}</text>
<text class="font-26 numbold-font">{{data.real_num}} {{data.curr_name}}</text>
</view>
<!-- 数量 -->
<view class="width-100b height-192 padding-c-27 flex direction-column justify-between margin-t-24">
<view class="font-28 weight-bold">{{i18n.ico.text5}}</view>
<view class="flex align-center justify-between">
<input class="font-28" :placeholder="i18n.ico.tos1" placeholder-class="color-C3C3C3"
type="digit" v-model="number" />
<text class="font-28 weight-bold">{{data.curr_name}}</text>
</view>
</view>
<view class="flex align-center font-26 weight-bold">
<text>{{i18n.ico.text6}}</text>
<text class="color-0165EE numbold-font margin-w-5">{{(number*data.price).toFixed(4)}}</text>
<text class="numbold-font">USDT</text>
</view>
<!-- 密码 -->
<view class="width-100b height-192 padding-c-27 flex direction-column justify-between margin-t-77">
<view class="font-28 weight-bold">{{i18n.ico.text7}}</view>
<input class="font-28" :placeholder="i18n.ico.tos2" placeholder-class="color-C3C3C3"
type="text" v-model="paypwd" password/>
</view>
</view>
</view>
<!-- 预约按钮 -->
<view class="yuyuebtn">
<u-button v-if="data.status==3" @click="openPopup" class="custom-style" type="primary">{{i18n.ico.text8}}</u-button>
<u-button v-if="data.status==2&&(!data.is_yuyue)" @click="getYuyue" class="custom-style" type="primary">{{i18n.ico.text1}}</u-button>
<view v-if="data.status==2&&data.is_yuyue" class="btn2">{{i18n.ico.text2}}</view>
</view>
</view>
</view>
<!-- 确认弹窗 -->
<u-popup v-model="show" mode="center" border-radius="20">
<view class="width-600 height-298 bj-white" style="overflow: hidden;">
<view class="height-203 padding-t-93 padding-b-65 text-center">
<text class="font-30 color-333333 weight-bold">{{i18n.ico.text9}}</text>
</view>
<view class="height-96 flex">
<view @click="show=false" class="flex-1 line-height-96 text-center bj-c3c3c3-02">
<text class="font-28 color-C3C3C3 weight-bold">{{i18n.ico.text10}}</text>
</view>
<view @click="getBuy()" class="flex-1 line-height-96 text-center bj-0165EE">
<text class="font-28 color-white weight-bold">{{i18n.ico.text11}}</text>
</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
data: '',
number: '',
paypwd: '',
percentage: 0,
show: false,
flag: true,
theme: '',
ico:""
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad:function(e){
this.ico = e.ico
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getDetails()
},
methods: {
// 购买私募
getBuy() {
if (!this.flag) {
return
} else {
uni.showLoading({
title: '',
mask: true
});
this.flag = false
let obj = {
id: this.data.id,
num: this.number,
pay_pwd: this.paypwd
}
this.post('/index/ico_sub', obj).then(res => {
console.log('购买私募返回', res)
this.flag = true
if (res.code == 1) {
this.tos(res.msg)
uni.hideLoading()
setTimeout(() => {
uni.navigateBack()
}, 500)
}
})
}
},
// 预约私募
getYuyue() {
if (!this.flag) {
return
} else {
this.flag = false
uni.showLoading({
title: '',
mask: true
});
this.post('/index/ico_yuyue', {
id: this.data.id
}).then(res => {
console.log('预约返回', res)
this.flag = true
if (res.code == 1) {
this.tos(res.msg)
this.getDetails()
}
})
}
},
// 打开确认弹窗
openPopup() {
if (this.number == '') return this.tos(this.i18n.ico.tos1)
if (this.paypwd == '') return this.tos(this.i18n.ico.tos2)
this.show = true
},
// 获取私募内容
getDetails() {
this.post('/index/ico_content',{
id: this.ico
}).then(res => {
console.log('私募内容', res)
if (res.code == 1) {
this.data = res.data
this.percentage = Math.floor((res.data.count_num - res.data.real_num) / res.data.count_num * 100)
}
})
},
}
}
</script>
<style lang="scss">
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
}
.bj-589CF8 {
background: linear-gradient(to bottom, #52F3C9 0%, #3ECEB2 100%);
border-radius: 0rpx 0rpx 120rpx 120rpx;
}
.yuyuebtn {
margin-top: 50rpx;
}
.custom-style {
width: 600rpx;
height: 86rpx;
background: #3ECEB2;
border-radius: 20rpx;
font-size: 32rpx;
color: #FFFFFF;
}
.morebtn {
width: 180rpx;
height: 66rpx;
background: #3ECEB2;
border: 1rpx solid #C9E0FF;
opacity: 1;
border-radius: 33rpx;
font-size: 32rpx;
color: #FFFFFF;
line-height: 66rpx;
text-align: center;
}
.inputbox {
width: 690rpx;
height: 682rpx;
// background: #FFFFFF;
box-shadow: 0rpx 3rpx 6rpx rgba(220, 220, 220, 0.16);
opacity: 1;
border-radius: 20rpx;
margin-top: 42rpx;
}
.bj-c3c3c3-02 {
background: rgba(195, 195, 195, 0.2);
}
.btn2 {
width: 690rpx;
height: 86rpx;
background: rgb(210, 210, 210);
border-radius: 20rpx;
font-size: 30rpx;
color: #8B8F95;
line-height: 86rpx;
text-align: center;
}
</style>
+148
View File
@@ -0,0 +1,148 @@
<template>
<view>
<!-- 头部 -->
<view class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 fixed1"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 height-110 padding-w-30 bgimg1 flex align-center justify-center">
<view @click="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 color-white weight-bold">{{i18n.ico.title}}</text>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750">
<view class="height-110 padding-t-90 bj-589CF8">
<view class="detailbox" v-html="data.content"></view>
</view>
</view>
<!-- 预约按钮 -->
<view class="yuyuebtn">
<!-- <u-button class="custom-style" type="primary">立即预约</u-button> -->
<view @click="getYuyue" v-if="status==2&&(!data.is_yuyue)" class="btn1">{{i18n.ico.text1}}</view>
<view v-if="status==1" class="btn2">{{i18n.ico.text1}}</view>
<view v-if="status==2&&data.is_yuyue" class="btn2">{{i18n.ico.text2}}</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
data: '',
status: -1,
flag: true,
ico:""
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad:function(e){
this.ico = e.ico
},
onShow() {
this.getDetails()
},
methods: {
// 预约私募
getYuyue() {
if (!this.flag) {
return
} else {
this.flag = false
uni.showLoading({
title: '',
mask: true
});
this.post('/index/ico_yuyue', {
id: this.data.id
}).then(res => {
console.log('预约返回', res)
this.flag = true
if (res.code == 1) {
this.tos(res.msg)
this.getDetails()
setTimeout(() => {
uni.hideLoading()
},1000)
}
})
}
},
// 获取私募内容
getDetails() {
this.post('/index/ico_content',{
id: this.ico
}).then(res => {
console.log('私募内容', res)
if (res.code == 1) {
this.data = res.data
this.status = res.data.status
}
})
},
}
}
</script>
<style lang="scss">
page {
background: #FFFFFF;
}
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
background: linear-gradient(180deg, #52F3C9 0%, #3ECEB2 100%);
}
.bj-589CF8 {
background: linear-gradient(180deg, #3ECEB2 0%, #52F3C9 100%);
}
.detailbox {
width: 750rpx;
padding: 30rpx 30rpx 200rpx;
background: #FFFFFF;
box-shadow: 0rpx 3rpx 6rpx rgba(220, 220, 220, 0.16);
border-radius: 20rpx;
}
.yuyuebtn {
position: fixed;
bottom: 60rpx;
left: 50%;
margin-left: -300rpx;
}
.btn1 {
width: 600rpx;
height: 86rpx;
background: #0165EE;
border-radius: 20rpx;
font-size: 30rpx;
color: #FFFFFF;
line-height: 86rpx;
text-align: center;
}
.btn2 {
width: 600rpx;
height: 86rpx;
background: rgb(210, 210, 210);
border-radius: 20rpx;
font-size: 30rpx;
color: #8B8F95;
line-height: 86rpx;
text-align: center;
}
</style>
+96
View File
@@ -0,0 +1,96 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.tabBar.quantify"></myNav>
<view class="width-690 margin-0-auto height-100 radiu-16 flex align-center justify-between padding-w-10"
:style="'background-color: '+theme.fu_bg">
<view class="flex-1 height-80 flex direction-column align-center justify-around">
<text class="font-24">{{i18n.ico.tos3}}</text>
<text class="font-24">{{succ_usdt}} USDT</text>
</view>
<view class="flex-1 height-80 flex direction-column align-center justify-around">
<text class="font-24">{{i18n.ico.tos4}}</text>
<text class="font-24">{{have_usdt}} USDT</text>
</view>
</view>
<!-- 身体 -->
<view class="width-750 padding-b-40">
<view v-for="(item,index) in list"
class="height-180 padding-w-30 padding-t-24 padding-b-27 flex direction-column justify-between margin-t-16">
<view class="flex align-center justify-between">
<text class="font-32 color-00C481 nummedium-font">{{item.name}}</text>
<text v-if="item.status==0" class="font-28 nummedium-font">{{i18n.ico.text15}}</text>
<text v-if="item.status==1" class="font-28 nummedium-font">{{i18n.ico.text16}}</text>
</view>
<view class="height-50 flex align-center justify-between">
<text class="font-28 nummedium-font">{{i18n.ico.tos5}}:{{item.price}} USDT</text>
<text class="font-26 nummedium-font">{{i18n.ico.tos6}}/{{i18n.ico.tos7}}</text>
</view>
<view class="flex align-center justify-between">
<text class="font-24 nummedium-font">{{item.createtime}}</text>
<text class="font-26 nummedium-font">{{item.real_num}}/{{item.num}}</text>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
have_usdt: 0,
succ_usdt: 0,
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
this.getico_usdt()
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
getico_usdt() {
this.post('/index/ico_usdt').then(res => {
console.log('', res)
if (res.code == 1) {
this.have_usdt = res.data.have_usdt
this.succ_usdt = res.data.succ_usdt
}
})
},
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/index/ico_user_log', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
}
}
</script>
<style lang="scss">
</style>
+150
View File
@@ -0,0 +1,150 @@
<template>
<view :style="'background-color:' + theme.bg + ';'" style="min-height: 100vh;">
<view class="" style="width: 750rpx;height: 360rpx;background: #06C38D;border-radius: 0px 0px 20rpx 20rpx;border-radius: 0 0 20rpx 20rpx;">
<view class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 fixed1"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 height-110 padding-w-30 flex align-center justify-center">
<!-- <view @click="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view> -->
<text class="font-36 weight-bold text-white">{{i18n.tabBar.quantify}}</text>
<image v-if="token" @click="router.push('/pages/index/icoRecord')" class="width-48 height-48 absolute" style="right: 30rpx;" src="/static/imgs/quantify/shezhi@2x.png" mode=""></image>
</view>
</view>
</view>
</view>
<view class="" style="margin-top: -200rpx;">
<view @click="todetail(item)" v-for="(item,index) in list" class="margin-lr margin-top" :style="'background-color: ' + theme.fu_bg" style="width: 690rpx;border-radius: 16rpx;">
<view class="padding">
<view class="flex align-center justify-between solid-bottom">
<view class="flex align-center">
<view class="" style="width: 76rpx;height: 76rpx;border-radius: 38rpx;">
<image :src="item.cover_image" style="width: 76rpx;height: 76rpx;border-radius: 38rpx;" mode=""></image>
</view>
<view class="margin-left-xs">
<view :style="'color:' + theme.text" class="font-28 text-bold u-line-1">
{{item.curr_name}}
</view>
<view class="font-24 text-bold" style="color: #FF5D53;">
{{i18n.ico.text12}}: {{item.start_time}}
</view>
<view class="font-24 text-bold" style="color: #FF5D53;">
{{i18n.ico.jiesu}}: {{item.end_time}}
</view>
</view>
</view>
<button v-if="item.status == 1" class="cu-btn flex align-center justify-center text-white" style="min-width: 140rpx;height: 56rpx;background: #CCCCCC;box-shadow: 0px 4rpx 10rpx 1rpx rgba(1, 101, 238, 0.1);border-radius: 8rpx;">
<view class="" style="white-space: nowrap;">
{{i18n.ico.text13}}
</view>
<u-icon name="arrow-right" color="#FFFFFF" size="15"></u-icon>
</button>
<button v-if="item.status == 2" class="cu-btn flex align-center justify-center text-white" style="min-width: 140rpx;height: 56rpx;background: #2DD1AF;box-shadow: 0px 4rpx 10rpx 1rpx rgba(0, 196, 129, 0.1);border-radius: 8rpx;">
<view class="" style="white-space: nowrap;">
{{i18n.ico.text14}}
</view>
<u-icon name="arrow-right" color="#FFFFFF" size="15"></u-icon>
</button>
<button v-if="item.status == 3" class="cu-btn flex align-center justify-center text-white" style="min-width: 140rpx;height: 56rpx;background: #2DD1AF;box-shadow: 0px 4rpx 10rpx 1rpx rgba(1, 101, 238, 0.1);border-radius: 8rpx;">
<view class="" style="white-space: nowrap;">
{{i18n.ico.text15}}
</view>
<u-icon name="arrow-right" color="#FFFFFF" size="15"></u-icon>
</button>
<button v-if="item.status == 4" class="cu-btn flex align-center justify-center text-white" style="min-width: 140rpx;height: 56rpx;background: #CCCCCC;box-shadow: 0px 4rpx 10rpx 1rpx rgba(1, 101, 238, 0.1);border-radius: 8rpx;">
<view class="" style="white-space: nowrap;">
{{i18n.ico.text16}}
</view>
<u-icon name="arrow-right" color="#FFFFFF" size="15"></u-icon>
</button>
</view>
<view class="padding-top flex align-center justify-between">
<view class="text-center">
<view class=" font-28 text-bold" :style="'color:' + theme.text">
{{item.count_num}}
</view>
<view class="color-C3C3C3 font-24 margin-top-xs">
{{i18n.ico.text17}}
</view>
</view>
<view class="text-center">
<view class=" font-28 text-bold" :style="'color:' + theme.text">
{{item.price}}
</view>
<view class="color-C3C3C3 font-24 margin-top-xs">
{{i18n.ico.text18}}
</view>
</view>
<view class="text-center">
<view class="color-333333 font-28 text-bold">
<!-- {{item.real_num}} -->
<view class="font-20" style="color: #2DD1AF;">
{{Number(item.jindu).toFixed(2)}}%
</view>
<view class="" style="width: 150rpx;margin-top: -20rpx;">
<u-line-progress :percent="Number(item.jindu)" activeColor="#2DD1AF" :height="10" :show-percent="false"></u-line-progress>
</view>
</view>
<view class="color-C3C3C3 font-24">
{{i18n.ico.text19}}
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
token:uni.getStorageSync('token'),
theme: '',
list:[]
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getList()
},
computed: {
i18n() {
return this.$t('message');
}
},
methods: {
getList(){
this.post('/index/ico_list').then(res => {
console.log('私募内容', res)
if (res.code == 1) {
this.list = res.data
}
})
},
todetail(item){
if(item.status==1 || item.status==4){
uni.navigateTo({
url:'/pages/index/icoDetails?ico=' + item.id
})
}else{
uni.navigateTo({
url:'/pages/index/icoBuy?ico=' + item.id
})
}
}
}
}
</script>
<style>
</style>
+35
View File
@@ -0,0 +1,35 @@
<template>
<view class="">
<myNav :title="i18n.Investors.investTitle"></myNav>
<view class="padding-30" v-html="content">
</view>
</view>
</template>
<script>
export default {
data() {
return {
content:'',
}
},
computed: {
i18n() {
return this.$t('message');
},
},
onLoad(e) {
this.content = e.text
},
methods: {
}
}
</script>
<style lang="scss">
page{
background-color: #FFFFFF
}
</style>
+159
View File
@@ -0,0 +1,159 @@
<template>
<view class="">
<myNav title="" background="rgba(255,255,255,0)" blackColor="#fff" :isRight="true" righturl="/static/imgs/index/touziRIght@2x.png" @Jump="router.push('/pages/index/investor/record')"></myNav>
<image style="position: fixed;top: 0rpx;height: calc(100vh);z-index: 0;" class="width-100b" src="/static/imgs/index/touyziBG@2x.png" mode=""></image>
<view class="padding-w-30 relative">
<p class="font-42 color-white nummedium-font">{{i18n.Investors.title}}</p>
<view class="font-28 color-white margin-c-28 line-height-48">
{{data.content_txt}}......<text @click="router.push('/pages/index/investor/details?text='+data.content)" class="">{{i18n.Investors.more}}<i class="cuIcon-right"></i></text>
</view>
<view class="padding-w-20 padding-c-10 bj-white radiu-4 margin-c-28" style="box-shadow: 0px 3px 6px rgba(232, 232, 232, 0.16);">
<view class="height-60 flex align-center justify-between">
<text class="font-26 nummedium-font color-333333">{{i18n.Investors.totalSales}}:</text>
<text class="font-32 numbold-font color-333333">{{data.all_num}} {{data.curr_name}}</text>
</view>
<view class="height-60 flex align-center justify-between">
<text class="font-26 nummedium-font color-333333">{{data.jieduan}}:</text>
<text class="font-32 numbold-font color-333333">{{data.count_num}} {{data.curr_name}}</text>
</view>
<view class="height-60 flex align-center justify-between">
<text class="font-26 nummedium-font color-333333">{{i18n.Investors.lave}}:</text>
<text class="font-32 numbold-font color-333333">{{data.real_num}} {{data.curr_name}}</text>
</view>
<view class="height-60 flex align-center justify-between">
<text class="font-26 nummedium-font color-333333">{{i18n.Investors.price}}:</text>
<text class="font-32 numbold-font color-333333">1 APT = {{data.price}} USDT</text>
</view>
</view>
<view class="padding-w-20 padding-c-10 bj-white radiu-4 margin-c-28" style="box-shadow: 0px 3px 6px rgba(232, 232, 232, 0.16);">
<view class="height-60 flex align-center">
<text class="font-26 weight-bold numbold-font color-333333">{{i18n.Investors.num}}</text>
</view>
<view class="height-96 flex align-center justify-between font-30">
<input class="color-333333 nummedium-font" type="number" v-model="touziNum" :placeholder="i18n.Investors.inputNum" placeholder-style="color:#8B99A2;"/>
<text class="color-333333 nummedium-font">USDT</text>
</view>
<view class="height-60 flex align-center nummedium-font font-24">
<text class="color-333333">
{{i18n.Investors.zehe}}:
</text>
<text class="color-0165EE">
{{allNum}} APT
</text>
</view>
<view class="height-60 flex align-center">
<text class="font-26 weight-bold numbold-font color-333333">{{i18n.Investors.pay_pwd}}</text>
</view>
<view class="height-96 flex align-center justify-between font-30">
<input class="color-333333 nummedium-font flex-1" type="text" password v-model="pay_pwd" :placeholder="i18n.Investors.inputPwd" placeholder-style="color:#8B99A2;"/>
</view>
</view>
<view @click="touzi" v-if="data.status==1" class="canyuBtn nummedium-font">{{i18n.Investors.canyu}}</view>
<view v-else class="canyuBtn_hui nummedium-font">{{i18n.Investors.canyu}}</view>
</view>
<view class="height-40"></view>
</view>
</template>
<script>
export default {
data() {
return {
data:'',
touziNum:'',
pay_pwd:'',
flag:true
}
},
computed: {
i18n() {
return this.$t('message');
},
allNum(){
let temp = 0
temp = this.touziNum / this.data.price
return temp.toFixed(4)
}
},
onShow() {
this.getInfo()
},
methods: {
getInfo(){
this.post('/angel/angel_content').then(res => {
console.log('天使投资返回',res)
if(res.code == 1){
this.data = res.data
}
})
},
touzi(){
if(!this.flag) return
if(this.touziNum == ''){
this.tos(this.i18n.Investors.inputNum)
return
}
if(this.pay_pwd == ''){
this.tos(this.i18n.Investors.inputPwd)
return
}
uni.showLoading({
mask:true
})
this.flag = false
this.post('/angel/angel_sub',{
id:this.data.id,
num:this.touziNum,
pay_pwd:this.pay_pwd
}).then(res => {
console.log('天使投资参与',res)
uni.hideLoading()
this.flag = true
if(res.code == 1){
this.tos(res.msg)
this.touziNum = ''
this.pay_pwd = ''
setTimeout(()=>{
uni.navigateTo({
url:'/pages/index/investor/record'
})
},500)
}
})
}
}
}
</script>
<style lang="scss">
page{
background-color: #398CFF;
}
.canyuBtn{
width: 600rpx;
height: 86rpx;
margin: 30rpx auto;
background: #FFFFFF;
color: #0165EE;
text-align: center;
line-height: 86rpx;
font-size: 32rpx;
border-radius: 20rpx;
}
.canyuBtn_hui{
width: 600rpx;
height: 86rpx;
margin: 30rpx auto;
background: #999;
color: #ddd;
text-align: center;
line-height: 86rpx;
font-size: 32rpx;
border-radius: 20rpx;
}
</style>
+116
View File
@@ -0,0 +1,116 @@
<template>
<view class="">
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<!-- 头部 -->
<myNav slot="top" :title="i18n.Investors.recordTitle"></myNav>
<!-- 身体 -->
<view>
<view class="height-140 bj-white flex align-center justify-between">
<view class="flex-1 height-90 flex direction-column align-center justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.total_investment}} APT</text>
<text class="font-36 numbold-font color-333333">{{count_num}}</text>
</view>
<view class="geduan"></view>
<view class="flex-1 height-90 flex direction-column align-center justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.total_revenue}}</text>
<text class="font-36 numbold-font color-333333">{{count_sy}}</text>
</view>
</view>
<view @click="goDetails(item.id)" class="listBox" v-for="(item,index) in list" :key="index">
<view class="flex-1 height-100b flex direction-column align-start justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.invest_num}}</text>
<text class="font-26 numbold-font color-333333">{{item.num}} APT</text>
</view>
<view class="flex-1 height-100b flex direction-column align-center justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.invest_price}}</text>
<text class="font-26 numbold-font color-333333">{{item.price}} USDT</text>
</view>
<view class="flex-1 height-100b flex direction-column align-end justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.invest_time}}</text>
<text class="font-26 numbold-font color-C3C3C3">{{item.addtime}}</text>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
count_num: 0,
count_sy: 0,
list: [],
}
},
computed: {
i18n() {
return this.$t('message');
},
},
// onPullDownRefresh() {
// console.log('refresh');
// this.list = []
// this.count_num = 0
// this.count_sy = 0
// this.getList()
// setTimeout(function() {
// uni.stopPullDownRefresh();
// }, 1000);
// },
onShow() {
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/angel/angel_user', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.count_num = res.data.count_num
this.count_sy = res.data.count_sy
this.$refs.paging.complete(res.data.list);
}
})
}, 500)
},
goDetails(id) {
uni.navigateTo({
url: '/pages/index/investor/record_details?id=' + id
})
},
}
}
</script>
<style lang="scss">
.geduan {
width: 2rpx;
height: 61rpx;
background-color: #707070;
opacity: 0.17;
}
.listBox {
width: 690rpx;
height: 117rpx;
margin: 30rpx auto;
padding: 18rpx 22rpx;
background: #FFFFFF;
box-shadow: 0rpx 4rpx 10rpx rgba(205, 206, 219, 0.3);
border-radius: 20rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
</style>
+143
View File
@@ -0,0 +1,143 @@
<template>
<view class="">
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<!-- 头部 -->
<myNav slot="top" :title="i18n.Investors.invest_title"></myNav>
<!-- 身体 -->
<view>
<view class="topBox">
<view class="height-142 flex align-center justify-between">
<view class="flex-1 height-90 flex direction-column align-center justify-between">
<text class="font-24 color-F6F8FB nummedium-font" style="opacity: 0.8;">{{i18n.Investors.leiji_all}}</text>
<text class="font-36 numbold-font color-white">{{count_all}}</text>
</view>
<view class="flex-1 height-90 flex direction-column align-center justify-between">
<text class="font-24 color-F6F8FB nummedium-font" style="opacity: 0.8;">{{i18n.Investors.leiji_day}}</text>
<text class="font-36 numbold-font color-white">{{day}}</text>
</view>
</view>
<view class="geduan"></view>
<view class="height-164 flex align-center justify-between">
<view class="flex-1 height-100 flex direction-column align-center justify-between">
<text class="font-24 color-F6F8FB nummedium-font" style="opacity: 0.8;">{{i18n.Investors.leiji_lixi}}</text>
<text class="font-36 numbold-font color-white">{{count_lixi}}</text>
</view>
<view class="flex-1 height-100 flex direction-column align-center justify-between">
<text class="font-24 color-F6F8FB nummedium-font" style="opacity: 0.8;">{{i18n.Investors.leiji_bj}}</text>
<text class="font-36 numbold-font color-white">{{count_bj}}</text>
</view>
</view>
</view>
<view class="listBox" v-for="(item,index) in list" :key="index">
<view class="height-117 padding-w-10 flex align-center justify-between">
<view class="flex-1 height-80 flex direction-column align-start justify-between">
<text class="font-24 color-C3C3C3 nummedium-font">{{i18n.Investors.leiji_time}}</text>
<text class="font-28 nummedium-font color-C3C3C3">{{item.addtime}}</text>
</view>
<view class="flex-1 height-80 flex direction-column align-end justify-between">
<text class="font-24 color-C3C3C3 nummedium-font" style="opacity: 0.8;">{{item.type==1?i18n.Investors.freed_lixi:i18n.Investors.freed_bj}}</text>
<text class="font-34 numbold-font color-333333">+{{item.num}}</text>
</view>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
count_lixi:0,
count_all:0,
count_bj:0,
day:0,
list:[],
}
},
computed: {
i18n() {
return this.$t('message');
},
},
// onPullDownRefresh() {
// console.log('refresh');
// this.list = []
// this.page = 1
// this.state = 'more'
// this.getInfo()
// this.getList()
// setTimeout(function () {
// uni.stopPullDownRefresh();
// }, 1000);
// },
// onReachBottom:function(){
// this.page++
// this.getList()
// },
onLoad(e) {
this.id = e.id
this.getInfo()
},
methods: {
getInfo(){
this.post('/angel/angel_detail_head',{
id:this.id
}).then(res => {
console.log('释放记录头部',res)
if(res.code == 1){
this.count_lixi = res.data.count_lixi
this.count_all = res.data.count_all
this.count_bj = res.data.count_bj
this.day = res.data.day
}
})
},
queryList(pageNo, pageSize) {
setTimeout(()=>{
this.post('/angel/angel_detail_log', {
page: pageNo,
page_num: pageSize,
id:this.id
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
},500)
},
}
}
</script>
<style lang="scss">
.topBox{
width: 690rpx;
// height: 306rpx;
margin: 20rpx auto;
border-radius: 8rpx;
background: linear-gradient(117deg, #066FFF 0%, #72AEFF 100%);
}
.geduan{
width: 100%;
height: 1px;
background-color: #FFFFFF;
opacity: 0.42;
}
.listBox{
width: 100%;
padding: 0 30rpx;
// height: 234rpx;
background: #FFFFFF;
margin: 16rpx auto;
}
</style>
+202
View File
@@ -0,0 +1,202 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<!-- 头部 -->
<view class="width-750 relative flex align-center justify-center bj-8EBEFF"
:style="{height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 fixed1"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 110rpx)`}">
<view class="width-750 height-110 padding-w-30 bgimg1 flex align-center justify-center">
<view @click="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 color-white weight-bold">{{i18n.lockUp.title1}}</text>
<image @click="router.push('/pages/index/lockUpRecord')" class="width-54 height-54 absolute"
style="right: 30rpx;" src="/static/imgs/index/jilu@2x.png"></image>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750">
<view class="headbox">
<view class="inputbox" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="height-192">
<view class="height-96 flex align-center">
<text class="font-28 weight-bold">{{i18n.lockUp.text1}}</text>
</view>
<view class="height-96 flex align-center">
<input class="flex-1 padding-r-30 font-28 nummedium-font" type="number"
v-model="number" :placeholder="i18n.lockUp.tos1" />
<text class="font-28 nummedium-font">APT</text>
</view>
</view>
<view @click="show=true" class="height-96 flex align-center justify-between">
<text class="font-28 weight-bold">{{i18n.lockUp.text2}}</text>
<view class="flex align-center">
<text class="font-28 weight-bold">{{zhouqi==''?i18n.lockUp.text3:zhouqi.day+i18n.lockUp.text4}}</text>
<u-icon name="arrow-right" size="24"></u-icon>
</view>
</view>
<view class="height-76 flex align-center">
<text class="font-26 margin-r-20">{{i18n.lockUp.text5}}</text>
<text class="font-26 color-0165EE nummedium-font">{{zhouqi==''?'0':zhouqi.yield}}%</text>
</view>
<view class="height-192">
<view class="height-96 flex align-center">
<text class="font-28 weight-bold">{{i18n.lockUp.text6}}</text>
</view>
<view class="height-96 flex align-center">
<input class="flex-1 font-28 nummedium-font" type="number" v-model="paypwd"
:placeholder="i18n.lockUp.tos3" password />
</view>
</view>
</view>
</view>
<view class="height-500"></view>
<view @click="getzhiya_sub" class="tijiao">{{i18n.lockUp.text7}}</view>
<view v-html="text" class="padding-w-30 margin-t-200">
</view>
</view>
<!-- 锁仓周期弹窗 -->
<u-popup v-model="show" mode="bottom" border-radius="20">
<view class="padding-b-80 padding-w-30"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-110 flex align-center justify-center">
<text class="font-30 weight-bold">{{i18n.lockUp.text2}}</text>
<view @click.stop="show=false" style="position: absolute;right: 30rpx;"
class="font-26 color-C3C3C3">
{{i18n.lockUp.text8}}</view>
</view>
<view class="height-400">
<scroll-view class="height-400" scroll-y="true">
<view @click="setzhouqi(item)" v-for="(item,index) in list"
:style="'background-color: '+theme.fu_bg"
class="height-72 margin-b-16 flex align-center padding-w-30 radiu-10">
<text class="font-28">{{item.day}}{{i18n.lockUp.text4}}</text>
</view>
</scroll-view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
show: false,
number: '',
paypwd: '',
list: [],
text: '',
zhouqi: '',
flag: true,
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getzhiya_con()
},
methods: {
// 提交
getzhiya_sub() {
if (this.number == '') return this.tos(this.i18n.lockUp.tos1)
if (this.zhouqi == '') return this.tos(this.i18n.lockUp.tos2)
if (this.paypwd == '') return this.tos(this.i18n.lockUp.tos3)
if (!this.flag) {
return
} else {
this.flag = false
let obj = {
id: this.zhouqi.id,
num: this.number,
pay_pwd: this.paypwd,
}
this.post('/index/zhiya_sub', obj, true).then(res => {
console.log(res)
this.flag = true
if (res.code == 1) {
this.tos(res.msg)
this.number = ''
this.zhouqi = ''
this.paypwd = ''
setTimeout(() => {
uni.navigateTo({
url: '/pages/index/lockUpRecord'
})
}, 500)
}
})
}
},
// 选择周期
setzhouqi(item) {
this.zhouqi = item
this.show = false
},
// 获取锁仓返回
getzhiya_con() {
this.post('/index/zhiya_con', {}, true).then(res => {
console.log('锁仓返回', res)
if (res.code == 1) {
this.list = res.data.cycle
this.text = res.data.zhiya_text
}
})
}
}
}
</script>
<style lang="scss">
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
background: #0165EE;
}
.headbox {
width: 750rpx;
height: 506rpx;
background: #0165EE;
border-radius: 0rpx 0rpx 120rpx 120rpx;
padding-top: 206rpx;
}
.inputbox {
width: 690rpx;
height: 636rpx;
// background: #FFFFFF;
border-radius: 20rpx;
margin: 0 auto;
padding: 0 16rpx;
}
.tijiao {
width: 600rpx;
height: 86rpx;
background: #0165EE;
border-radius: 20rpx;
font-size: 30rpx;
color: #FFFFFF;
line-height: 96rpx;
text-align: center;
margin-left: auto;
margin-right: auto;
}
</style>
+97
View File
@@ -0,0 +1,97 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.lockUp.title3"></myNav>
<!-- 身体 -->
<view slot="top" class="height-144 flex align-center bj-0165EE margin-b-24">
<view class="flex-1 height-144 flex direction-column padding-c-25 align-center justify-between">
<text class="font-24 color-F6F8FB">{{i18n.lockUp.text11}}</text>
<text class="font-32 color-white numbold-font">{{data.profit_num}}</text>
</view>
<view class="width-2 height-64" style="background: rgba(255,255,255,0.42);"></view>
<view class="flex-1 height-144 flex direction-column padding-c-25 align-center justify-between">
<text class="font-24 color-F6F8FB">{{i18n.lockUp.text12}}</text>
<text class="font-32 color-white numbold-font">{{data.last_day}}{{i18n.lockUp.text4}}</text>
</view>
</view>
<view class="width-750 padding-b-40">
<!-- 单一列表 -->
<view v-for="(item,index) in list"
class="height-126 padding-c-20 padding-w-30 flex direction-column justify-between margin-b-8">
<view class="flex align-center justify-between font-24 color-C3C3C3">
<text>{{i18n.lockUp.text13}}</text>
<text>{{i18n.lockUp.text14}}</text>
</view>
<view class="flex align-center justify-between">
<text class="font-28 color-C3C3C3 nummedium-font">{{item.addtime}}</text>
<text class="font-32 numbold-font">+{{item.num}}</text>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
id: '',
data: '',
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.id = e.id
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
getDetails() {
this.post('/index/zhiya_shif_con', {
id: this.id
}).then(res => {
console.log(res)
if (res.code == 1) {
this.data = res.data
}
})
},
queryList(pageNo, pageSize) {
this.getDetails()
setTimeout(() => {
this.post('/index/zhiya_shif_log', {
page: pageNo,
page_num: pageSize,
id: this.id
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
}
}
</script>
<style lang="scss">
</style>
+83
View File
@@ -0,0 +1,83 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.lockUp.title2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-t-24 padding-w-30 padding-b-40">
<!-- 单一列表 -->
<view @click="router.push('/pages/index/lockUpDetails?id='+item.id)" v-for="(item,index) in list"
class="listbox"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex-1 height-100b flex direction-column justify-between">
<text class="font-24 color-C3C3C3">{{i18n.lockUp.text9}}</text>
<text class="font-26 numbold-font">{{item.num}} APT</text>
</view>
<view class="flex-1 height-100b flex direction-column align-center justify-between">
<text class="font-24 color-C3C3C3">{{i18n.lockUp.text2}}</text>
<text class="font-26 weight-bold">{{item.day}}{{i18n.lockUp.text4}}</text>
</view>
<view class="flex-1 height-100b flex direction-column align-end justify-between">
<text class="font-24 color-C3C3C3">{{i18n.lockUp.text10}}</text>
<text class="font-26 numbold-font">{{item.add_time}}</text>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/index/zhiya_list', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
}
}
</script>
<style lang="scss">
.listbox {
width: 690rpx;
height: 117rpx;
// background: #FFFFFF;
box-shadow: 0rpx 4rpx 4rpx rgba(205, 206, 219, 0.2);
border-radius: 20rpx;
padding: 22rpx;
display: flex;
margin-bottom: 30rpx;
}
</style>
+101
View File
@@ -0,0 +1,101 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<myNav slot="top" :title="i18n.licai.text31"></myNav>
<view slot="top" class="height-180 padding-w-48 flex align-center justify-between"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="height-100 flex direction-column align-start justify-between">
<text class="font-36">{{alr_num}}{{curr_name}}</text>
<text class="font-24">{{i18n.licai.text32}}</text>
</view>
<view class="height-100 flex direction-column align-end justify-between">
<text class="font-36">{{alr_day}} {{i18n.licai.text6}}</text>
<text class="font-24">{{i18n.licai.text33}}</text>
</view>
</view>
<view slot="top" class="height-70 padding-w-60 flex align-center justify-between">
<text class="font-26 color-C3C3C3">{{i18n.licai.text34}}</text>
<text class="font-26 color-C3C3C3">{{i18n.licai.text35}}</text>
</view>
<view class="listBox" v-for="(item,index) in list" :key="index">
<text class="font-28 color-00C481">+{{item.price}} {{curr_name}}</text>
<text class="font-24">{{item.createtime}}</text>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
id:'',
alr_day:0,
alr_num:0,
curr_name:'',
theme: '',
};
},
computed: {
i18n() {
return this.$t('message');
},
},
onLoad(e) {
this.id = e.id
this.getInfo()
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
getInfo(){
this.post('/product/product_user_con', {
id: this.id,
}).then(res => {
if (res.code == 1) {
this.alr_day = res.data.alr_day
this.alr_num = res.data.alr_num
this.curr_name = res.data.curr_name
}
})
},
queryList(pageNo, pageSize) {
this.post('/product/product_user_log', {
page: pageNo,
id: this.id,
}).then(res => {
if (res.code == 1) {
console.log('数据', res)
this.$refs.paging.complete(res.data.data);
}
})
},
}
}
</script>
<style lang="scss">
.listBox {
width: 100%;
height: 96rpx;
// background: #FFFFFF;
border-radius: 24rpx;
margin-bottom: 1px;
padding: 0 40rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
</style>
+134
View File
@@ -0,0 +1,134 @@
<template>
<view class="">
<z-paging :language="$i18n.locale" ref="paging" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view slot="top" class="relative" :style="{height: `calc(${statusBar}px + 55px)`}">
<view class="width-100b fixed1" :style="{height: `calc(${statusBar}px + 55px)`}">
<view class="width-100b fixed1 flex align-center justify-start padding-l-88"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 55px)`}">
<i @click="router.goBack()" class="cuIcon-back font-30 absolute" style="left: 30rpx;"></i>
<text class="font-32 weight-bold">{{i18n.licai.text1}}</text>
<view class="width-450 height-60 radiu-50 padding-w-20 flex align-center justify-between absolute"
:style="'background-color: '+theme.fu_bg"
style="right: 30rpx;">
<input @input="searchCion" class="font-24" :placeholder="i18n.licai.text2" type="text"
v-model="searchVal" />
<i class="cuIcon-search"></i>
</view>
</view>
</view>
</view>
<view slot="top" @click="router.push('/pages/index/money/my_record')"
:style="'background-color: '+theme.fu_bg"
class="height-86 flex align-center justify-between padding-w-40">
<view class="flex align-center">
<image class="width-34 height-34 margin-r-10" src="/static/imgs/index/Frame1@2x.png" mode=""></image>
<text class="font-26">{{i18n.licai.text3}}</text>
</view>
<i class="cuIcon-right font-26"></i>
</view>
<view class="padding-w-40">
<view class="listBox" v-for="(item,index) in list" :key="index"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="height-100 flex align-center justify-between">
<image class="width-96 height-96 radiu-28" :src="item.logo_image" mode=""></image>
<view class="height-96 flex-1 margin-l-18">
<view class="height-48 flex align-center">
<text class="font-32 bold-font weight-bold">{{item.name}}</text>
</view>
<view class="height-48 flex align-center justify-between">
<text class="font-24">{{i18n.licai.text4}}:{{item.min_num}}-{{item.max_num}}</text>
<text class="font-24">{{i18n.licai.text5}}:{{item.day}}{{i18n.licai.text6}}</text>
</view>
</view>
</view>
<view class="width-100b height-2 margin-20-auto" style="background-color: rgba(191, 195, 199, 0.2);"></view>
<view class="height-60 flex align-center justify-between">
<view class="padding-w-18 line-height-56 text-center height-56 radiu-10"
style="min-width: 270rpx;background: #2DD1AF;">
<text class="font-22 color-white">{{i18n.licai.text7}}:{{item.rixi}}</text>
</view>
<view @click="router.push('/pages/index/money/investing?id='+item.id)"
class="flex align-center justify-end line-height-56">
<text class="font-24 color-EA466F margin-r-6">{{i18n.licai.text8}}</text>
<i class="cuIcon-right color-999999 font-24"></i>
</view>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
searchVal: '',
statusBar: uni.getSystemInfoSync().statusBarHeight,
list: [],
list_all: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
},
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.searchVal = ''
},
methods: {
queryList(pageNo, pageSize) {
this.post('/product/index_list').then(res => {
if (res.code == 1) {
console.log('数据', res)
this.list = res.data
this.list_all = res.data
this.$refs.paging.complete([{}]);
}
})
},
searchCion() {
if (this.searchVal == '') {
this.list = this.list_all
return
}
let arrtemp = []
this.list_all.forEach((item) => {
if (item.name.indexOf(this.searchVal.toUpperCase()) != '-1') {
arrtemp.push(item)
}
})
this.list = arrtemp
},
}
}
</script>
<style lang="scss">
.fixed1 {
position: fixed;
top: 0;
z-index: 1010;
}
.listBox {
width: 100%;
// height: 228rpx;
padding: 24rpx;
// background-color: #FFFFFF;
border-radius: 28rpx;
margin: 24rpx auto;
}
</style>
+194
View File
@@ -0,0 +1,194 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text">
<myNav :title="i18n.licai.text8"></myNav>
<view class="topBox flex direction-column align-start justify-between">
<text class="font-28 color-white">{{i18n.licai.text9}}</text>
<text class="font-36 color-white">{{obj.money_trx}}</text>
</view>
<view class="width-670 margin-20-auto radiu-10 padding-b-30"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text"
style="overflow: hidden;">
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text10}}</text>
<text class="font-28">{{obj.min_num}} {{obj.curr_name}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text11}}</text>
<text class="font-28">{{obj.max_num}} {{obj.curr_name}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text12}}</text>
<text class="font-28">{{obj.day}} {{i18n.licai.text6}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text13}}</text>
<text class="font-28">{{rixi}}%</text>
</view>
<view class="padding-w-20 padding-c-10">
<p class="font-28 margin-c-10">{{i18n.licai.text14}}</p>
<view class="height-96 radiu-16 padding-w-24 flex align-center justify-between">
<input class="height-96 flex-1 line-height-96 font-26 padding-w-20" type="number" v-model="money" :placeholder="i18n.licai.text15" />
</view>
</view>
<view class="padding-w-20 padding-c-10">
<p class="font-28 margin-c-10">{{i18n.licai.text16}}</p>
<view class="height-96 radiu-16 padding-w-24 flex align-center justify-between">
<input class="height-96 flex-1 line-height-96 font-26 padding-w-20" type="text" v-model="pay_pwd" password :placeholder="i18n.licai.text17"/>
</view>
</view>
<view class="width-100b margin-c-20 text-right padding-w-30">
<text class="font-26 color-EA466F">{{money||0}} + ( {{money||0}} * {{rixi}}% * {{obj.day}}) ≈ {{allNumber}}</text>
</view>
<view class="height-96 flex align-center justify-center">
<button @click="touzi" type="default" class="cu-btn" style="width: 600rpx;height: 96rpx;color: #FFFFFF;font-size: 28rpx;background: #2DD1AF;opacity: 1;">{{i18n.licai.text8}}</button>
</view>
</view>
<view class="height-64 flex align-center padding-w-60">
<text class="font-28 color-3C2E33 weight-bold">{{i18n.licai.text18}}</text>
</view>
<view class="width-670 margin-20-auto radiu-10 padding-b-30"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text"
style="overflow: hidden;">
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text19}}</text>
<text class="font-28">{{obj.name}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text20}}</text>
<text class="font-28">{{i18n.licai.text21}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text14}}</text>
<text class="font-28">{{money||0}} {{obj.curr_name}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text13}}</text>
<text class="font-28">{{rixi}}%</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text12}}</text>
<text class="font-28">{{obj.day}} {{i18n.licai.text6}}</text>
</view>
<view class="height-96 padding-w-24 flex align-center justify-between">
<text class="font-28">{{i18n.licai.text22}}</text>
<text class="font-28">{{rixi}}% * {{obj.day}} = {{Number(rixi*obj.day).toFixed(2)}}%</text>
</view>
<view class="padding-w-24">
<text class="height-60 font-28 line-height-60">{{i18n.licai.text23}}</text>
<view class="padding-c-20">
<text class="font-24">{{obj.msg}}</text>
</view>
</view>
</view>
<view class="height-40"></view>
</view>
</template>
<script>
export default {
data() {
return {
id:'',
obj:{},
money:'',
pay_pwd:'',
flag:true,
rixi_arr:[],
theme: '',
};
},
computed:{
i18n() {
return this.$t('message');
},
allNumber(){
if(this.money==''){
return 0
}else{
let temp = Number(this.money) + Number(this.money*this.rixi/100*this.obj.day)
return Number(temp).toFixed(2)
}
},
rixi(){
if(this.money==''){
return this.obj.rixi
}else{
let num = 0
this.rixi_arr.forEach((item)=>{
if(this.money >= item.key){
num = item.value
}
})
return num
}
}
},
onLoad(e) {
this.id = e.id
this.product_con()
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods:{
touzi(){
if(!this.flag) return
if(this.money == ''){
this.tos(this.i18n.licai.text15)
return
}
if(this.pay_pwd == ''){
this.tos(this.i18n.licai.text17)
return
}
this.post('/product/product_buy',{
num:this.money,
pay_pwd:this.pay_pwd,
id:this.id
},true).then(res => {
console.log(res)
if (res.code == 1) {
this.tos(res.msg)
this.pay_pwd = ''
setTimeout(()=>{
uni.redirectTo({
url:'/pages/index/money/my_record'
})
},500)
}
})
},
product_con(){
this.post('/product/product_con',{
id:this.id
}).then(res => {
console.log(res)
if (res.code == 1) {
this.obj = res.data
this.rixi_arr = res.data.rixi_arr
}
})
},
}
}
</script>
<style lang="scss">
.topBox{
width: 670rpx;
height: 183rpx;
margin: 24rpx auto;
border-radius: 10rpx;
padding: 36rpx 20rpx;
background-color: #2DD1AF;
}
</style>
+89
View File
@@ -0,0 +1,89 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<myNav slot="top" :title="i18n.licai.text24"></myNav>
<view class="listBox" v-for="(item,index) in list" :key="index"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex-1 height-100b padding-c-20 padding-w-24 flex direction-column justify-between" style="border-radius: 40rpx 0 0 40rpx;">
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text25}}:<span class="color-3C2E33">{{item.name}}</span></text>
</view>
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text14}}:<span class="color-3C2E33">{{item.num}} {{item.curr_name}}</span></text>
</view>
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text13}}:<span class="color-3C2E33">{{item.rixi}}%</span></text>
</view>
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text22}}:<span class="color-3C2E33">{{item.rixi}}% * {{item.day}} = {{item.rixi*item.day}}%</span></text>
</view>
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text26}}:
<span v-if="item.status==0" class="color-999999">{{i18n.licai.text27}}</span>
<span v-if="item.status==1" class="color-0165EE">{{i18n.licai.text28}}</span>
</text>
</view>
<view class="height-50 flex align-center">
<text class="font-26">{{i18n.licai.text29}}:<span class="">{{item.addtime}}</span></text>
</view>
</view>
<view class="height-320 width-4 radiu-10" style="background-color: rgba(191, 195, 199, 0.2);"></view>
<view @click="router.push('/pages/index/money/details?id='+item.id)" class="width-104 height-100b flex align-center justify-center padding-w-30">
<text class="font-26 line-height-50 text-center">{{i18n.licai.text30}}</text>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
};
},
computed: {
i18n() {
return this.$t('message');
},
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
this.post('/product/product_user').then(res => {
if (res.code == 1) {
console.log('数据', res)
this.$refs.paging.complete(res.data);
}
})
},
}
}
</script>
<style lang="scss">
.listBox {
width: 670rpx;
height: 360rpx;
// background: #FAFAFA;
box-shadow: 0rpx 0rpx 10rpx 0rpx rgba(12, 21, 238, 0.2);
border-radius: 10rpx;
margin: 16rpx auto;
display: flex;
align-items: center;
justify-content: space-between;
}
</style>
+295
View File
@@ -0,0 +1,295 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<myNav :title="i18n.newWord.serve" :isGoback="false" @isNoback="isNoback" :isRightext="ifBinaji" rightextColor="#3ECEB2"
:rightText="i18n.newWord.finish" @Jump="complete"></myNav>
<view class="">
<view class="padding-w-30">
<view class="height-50 flex align-center">
<text v-if="ifBinaji==false" class="font-26 nummedium-font">{{i18n.newWord.title1}}</text>
<text v-else class="font-26 nummedium-font">{{i18n.newWord.title2}} {{7 - hot_cate.length}} {{i18n.newWord.title3}}</text>
</view>
<view v-if="ifBinaji==false" class="height-100 flex align-center justify-between">
<view class="height-100 flex align-center">
<view class="width-44 height-44 margin-r-17" v-for="(item,index) in hot_cate" :key="item.id">
<!-- <image class="width-44 height-44" :src="item.logo_image" mode=""></image> -->
<image v-if="theme.theme=='light'" class="width-44 height-44" :src="item.logo_image" mode=""></image>
<image v-else class="width-44 height-44" :src="item.logo2_image" mode=""></image>
</view>
<view class="width-44 height-44 margin-r-17" v-for="(item,index) in my_cate" :key="item.id">
<!-- <image class="width-44 height-44" :src="item.logo_image" mode=""></image> -->
<image v-if="theme.theme=='light'" class="width-44 height-44" :src="item.logo_image" mode=""></image>
<image v-else class="width-44 height-44" :src="item.logo2_image" mode=""></image>
</view>
</view>
<image @click="ifBinaji=true,my_cate_copy=my_cate" class="width-52 height-52"
src="/static/imgs/index/bianji@2x.png" mode=""></image>
</view>
</view>
<view v-if="ifBinaji==true" class="padding-c-18 flex align-center flex-wrap">
<view v-for="(item,index) in hot_cate" :key="item.id" style="width: 25%;"
class="height-120 flex direction-column align-center justify-center">
<!-- <image class="width-44 height-44" :src="item.logo_image" mode=""></image> -->
<image v-if="theme.theme=='light'" class="width-44 height-44" :src="item.logo_image" mode=""></image>
<image v-else class="width-44 height-44" :src="item.logo2_image" mode=""></image>
<text class="font-24 margin-t-10">{{item.name}}</text>
</view>
<view v-for="(item,index) in my_cate_copy" :key="item.id" style="width: 25%;"
class="height-120 flex direction-column align-center justify-center relative">
<!-- <image class="width-44 height-44" :src="item.logo_image" mode=""></image> -->
<image v-if="theme.theme=='light'" class="width-44 height-44" :src="item.logo_image" mode=""></image>
<image v-else class="width-44 height-44" :src="item.logo2_image" mode=""></image>
<text class="font-24 margin-t-10">{{item.name}}</text>
<image @click="reduce(item,index)" class="width-28 height-28 absolute"
style="top: 0rpx;right: 20rpx;" src="/static/imgs/index/jianshao@2x.png" mode=""></image>
</view>
</view>
</view>
<!-- 隔断 -->
<view class="height-16"></view>
<view class="">
<view class="height-90">
<swiper class="swiper padding-w-10">
<swiper-item>
<scroll-view scroll-x class="nav" scroll-with-animation :scroll-left="scrollLeft">
<view class="cu-item" :class="index==TabCur?'text-green cur':''" v-for="(item,index) in all_cata"
:key="index" @tap="tabSelect" :data-id="index" :data-name="'id'+item.id">
{{item.name}}
</view>
</scroll-view>
</swiper-item>
</swiper>
</view>
<scroll-view @scroll="scroll" :scroll-into-view="scrollID" scroll-y="true" scroll-with-animation
:class="ifBinaji?'scroll-view-high':'scroll-view'">
<view :id="'id'+item.id" class="width-750 margin-b-10" v-for="(item,index) in all_cata"
:key="item.id">
<view class="height-60 flex align-center padding-w-30">
<text class="font-26 medium-font">{{item.name}}</text>
</view>
<view class="flex width-750 flex-wrap padding-t-18">
<view @click="add(itm)" v-for="(itm,idx) in item.son" :key="itm.id" style="width: 25%;"
:style="ifBinaji==true&&itm.is_hot==1?'opacity: 0.5;':''"
class="height-120 flex direction-column align-center justify-center relative margin-b-10">
<!-- <image class="width-44 height-44" :src="itm.logo_image" mode=""></image> -->
<image v-if="theme.theme=='light'" class="width-44 height-44" :src="itm.logo_image" mode=""></image>
<image v-else class="width-44 height-44" :src="itm.logo2_image" mode=""></image>
<text class="font-24 margin-t-10">{{itm.name}}</text>
<image v-if="ifBinaji==true" class="width-28 height-28 absolute"
style="top: 0rpx;right: 20rpx;" src="/static/imgs/index/zengjia@2x.png" mode=""></image>
</view>
</view>
</view>
</scroll-view>
</view>
<u-popup style="z-index: 5000;" :mask-close-able="false" border-radius="30" mode="center" v-model="qcShow"
@click.stop="">
<view class="width-600" :style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="width-100b height-220 padding-w-30 padding-c-30 flex direction-column align-center justify-between">
<image class="width-92 height-92" src="/static/imgs/index/tishi@2x.png" mode=""></image>
<view class="font-26 weight-bold text-center padding-w-20">
{{i18n.newWord.tips1}}
</view>
</view>
<view class="width-100b height-90 flex align-center justify-between">
<view @click="router.goBack()" class="qcbtn1">{{i18n.newWord.tips2}}</view>
<view class="qcbtn2" @click.stop="complete">{{i18n.newWord.tips3}}</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
ifBinaji: false,
TabCur: 0,
scrollLeft: 0,
ifaddOrjian: false,
hot_cate: [],
my_cate: [],
all_cata: [],
scrollID: '',
my_cate_copy: [],
qcShow: false,
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
},
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getopenList()
},
methods: {
tabSelect(e) {
// console.log(e);
this.TabCur = e.currentTarget.dataset.id;
this.scrollID = e.currentTarget.dataset.name
this.scrollLeft = (e.currentTarget.dataset.id - 1) * 60
},
// 减少
reduce(item, index) {
this.my_cate_copy.splice(index, 1)
let subid = item.cate_id
this.all_cata.forEach(obj => {
if (obj.id == subid) {
obj.son.forEach(objs => {
if (objs.id == item.id) {
objs.is_hot = 0
}
})
}
})
this.ifaddOrjian = true
},
// 增加
add(itm) {
if (this.ifBinaji == true) {
if (itm.is_hot == 1) return
let arr = [...this.hot_cate, ...this.my_cate_copy]
if (arr.length >= 7) return
const result = arr.find(item => item.id === itm.id)
console.log(result);
if (result == undefined) {
itm.is_hot = 1
this.my_cate_copy.push(itm)
this.ifaddOrjian = true
}
} else {
if (itm.open_status == 1) {
if (itm.type == 1) {
console.log(itm.url);
if(itm.types==1){
uni.navigateTo({
url: itm.url
})
}else{
uni.switchTab({
url: itm.url
})
}
} else {
// #ifdef APP-PLUS
plus.runtime.openURL(itm.url)
// #endif
// #ifdef H5
window.location.replace(itm.url)
// #endif
}
} else if (itm.open_status == 2) {
this.tos(this.i18n.newWord.toOpen)
} else {
this.tos(this.i18n.newWord.no)
}
}
},
getopenList() {
this.post('/index/cate_list').then(res => {
console.log(res)
if (res.code == 1) {
this.hot_cate = res.data.hot_cate
this.my_cate = res.data.my_cate
this.ma_cate_copy = res.data.my_cate
this.all_cata = res.data.all_cata
}
})
},
// 完成编辑
complete() {
if(this.ifaddOrjian){
let ids = []
this.my_cate_copy.forEach(item => {
ids.push(item.id)
})
this.post('/index/set_mydapp', {
ids: ids.join(',')
}).then(res => {
console.log(res)
if (res.code == 1) {
this.tos(res.msg)
this.getopenList()
this.ifBinaji = false
this.ifaddOrjian = false
this.qcShow = false
}
})
console.log(ids);
}else{
this.ifBinaji = false
this.ifaddOrjian = false
}
},
// 返回逻辑判断
isNoback() {
if (this.ifaddOrjian) {
this.qcShow = true
} else {
if (this.ifBinaji) {
this.ifBinaji = false
} else {
uni.navigateBack()
}
}
},
scroll(e){
// console.log(e.target.scrollTop);
},
}
}
</script>
<style lang="scss">
.scroll-view {
height: calc(100vh - 55px - var(--status-bar-height) - 150rpx - 16rpx - 90rpx);
width: 750rpx;
}
.scroll-view-high {
height: calc(100vh - 55px - var(--status-bar-height) - 326rpx - 16rpx - 90rpx);
}
.qcbtn1 {
width: 320rpx;
height: 86rpx;
background: rgba(160, 171, 181, 0.1);
border-radius: 0rpx 0rpx 0rpx 30rpx;
font-size: 28rpx;
font-weight: bold;
color: #8B99A2;
display: flex;
align-items: center;
justify-content: center;
}
.qcbtn2 {
width: 320rpx;
height: 90rpx;
background: linear-gradient(180deg, #52F3C9 0%, #3ECEB2 100%);
border-radius: 0rpx 0rpx 30rpx 0rpx;
font-size: 28rpx;
font-weight: bold;
color: #FFFFFF;
display: flex;
align-items: center;
justify-content: center;
}
</style>
+71
View File
@@ -0,0 +1,71 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.notice.title1"></myNav>
<!-- 身体 -->
<view class="width-750 padding-b-40">
<view @click="router.push('/pages/index/noticeDetails?id='+item.id)" v-for="(item,index) in list"
class="padding-w-30 padding-c-24">
<view class="height-72 flex align-center justify-between">
<view class="flex align-center flex-1">
<image class="width-72 height-72" src="/static/imgs/index/xitong@2x.png" mode=""></image>
<text class="flex-1 font-28 margin-l-22">{{item.title}}</text>
</view>
<text class="font-24 color-C3C3C3">{{item.createtime}}</text>
</view>
<view class="margin-t-30 font-26">
<text class="hidden-nowrap-ellipsis-2">{{item.content}}</text>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
list: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/index/message_list', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
}
}
</script>
<style lang="scss">
</style>
+57
View File
@@ -0,0 +1,57 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<myNav :title="i18n.notice.title2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-t-36 padding-b-40">
<view class="font-28 weight-bold">{{data.title}}</view>
<view class="font-24 color-C3C3C3 nummedium-font margin-t-5">{{data.createtime}}</view>
<view class="margin-t-16" v-html="data.content"></view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
id: '',
data:'',
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.id = e.id
this.getDetails()
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
getDetails() {
this.post('/index/message_con', {
id: this.id
}).then(res => {
console.log('公告详情', res)
if (res.code == 1) {
this.data = res.data
}
})
},
}
}
</script>
<style lang="scss">
</style>
+459
View File
@@ -0,0 +1,459 @@
<template>
<view>
<z-paging ref="paging" refresher-only @onRefresh="onRefresh"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<myNav slot="top" :title="i18n.orderDetails.title"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-t-24 padding-b-100">
<!-- 倒计时 -->
<view v-if="data.status==1||data.status==2"
class="height-112 padding-c-12 flex align-center justify-between">
<view class="height-100b flex direction-column justify-between">
<text v-if="data.status==1"
class="font-28 weight-bold">{{i18n.orderDetails.text1}}</text>
<text v-if="data.status==2"
class="font-28 weight-bold">{{i18n.orderDetails.text2}}</text>
<view class="flex align-center">
<text v-if="data.status==1" class="font-26 color-C3C3C3">{{i18n.orderDetails.text3}}:</text>
<text v-if="data.status==2" class="font-26 color-C3C3C3">{{i18n.orderDetails.text4}}:</text>
<u-count-down @end="getDetails()" ref="uCountDown" :autoplay="true" :timestamp="timestamp"
color="#0165EE">
</u-count-down>
</view>
</view>
<image class="width-60 height-60" src="/static/imgs/index/daojishi@2x.png" mode=""></image>
</view>
<!-- 订单信息 -->
<view class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">{{i18n.orderDetails.text5}}</text>
<text class="font-28 color-0165EE weight-bold">{{statusText[data.status]}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text6}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.order_num}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text7}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.symbol}} {{data.price}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text8}}({{data.curr_name}})</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.num}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text9}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.symbol}} {{data.count_price}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text10}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.add_time}}</text>
</view>
</view>
<!-- 用户信息 -->
<view class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">
{{data.type==1?i18n.orderDetails.text11:i18n.orderDetails.text12}}
</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text13}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.nickname}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text14}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.name}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text15}}</text>
<view class="flex align-center">
<text class="font-26 color-C3C3C3 nummedium-font">{{data.mobile}}</text>
<text @click="callup(data.mobile)"
class="font-26 color-0165EE margin-l-22">{{i18n.orderDetails.text16}}</text>
</view>
</view>
</view>
<!-- 银行卡信息 -->
<view v-if="data" class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">{{i18n.orderDetails.text17}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text18}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.collection.card_num}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text14}}</text>
<text class="font-26 color-C3C3C3 nummedium-font">{{data.collection.username}}</text>
</view>
<view class="flex align-center justify-between margin-b-10">
<text class="font-26 color-C3C3C3">{{i18n.orderDetails.text19}}</text>
<view class="flex align-center">
<text
class="font-26 color-C3C3C3 nummedium-font">{{data.collection.bank_name+data.collection.bank_deposit}}</text>
</view>
</view>
</view>
<!-- 支付凭证 -->
<view v-if="data.status==1&&data.type==1" class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">{{i18n.orderDetails.text20}}</text>
</view>
<view @click="chooseImage"
:style="'background-color: '+theme.bg"
class="width-176 height-176 radiu-20 flex align-center justify-center">
<!-- <image v-if="img==''||img==null" class="width-104 height-101"
src="/static/imgs/index/upload@2x.png"></image> -->
<u-icon v-if="img==''||img==null" name="plus-circle" color="#8B99A2" size="80"></u-icon>
<image v-else class="width-176 height-176 radiu-20" :src="img" mode=""></image>
</view>
</view>
<view v-if="data.status!=1&&data.status!=5" class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">{{i18n.orderDetails.text20}}</text>
</view>
<view class="width-176 height-176 radiu-20 flex align-center justify-center">
<image @click="yulanImg(voimg,1)" class="width-176 height-176 radiu-20" :src="voimg" mode=""></image>
</view>
</view>
<!-- 申诉内容 -->
<view v-if="data.appeal_arr" class="box" :style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center justify-between margin-b-25">
<text class="font-28 weight-bold">{{i18n.orderDetails.text21}}</text>
</view>
<view class="font-32 color-FF4040 margin-b-10">{{data.appeal_arr.content}}</view>
<view class="grid col-3">
<view @click="yulanImg(data.appeal_arr.annex_images,2)"
v-for="(item,index) in data.appeal_arr.annex_images" class="text-center margin-top">
<view class="width-200 height-200">
<image :src="item" class="width-200 height-200 radiu-20"></image>
</view>
</view>
</view>
</view>
<!-- 按钮区 -->
<view class=" margin-t-100 flex align-center justify-around">
<!-- <text v-if="data.status==1&&data.type==2" class="font-42 color-00C481">请耐心等待买家付款</text> -->
<view @click="router.push('/pages/index/appeal?id='+data.id)" v-if="data.status==2" class="okbtn">
{{i18n.orderDetails.text22}}
</view>
<view @click="show=true" v-if="data.status==1&&data.type==1" class="nobtn">{{i18n.orderDetails.text23}}
</view>
<view @click="getorder_pay" v-if="data.status==1&&data.type==1" class="okbtn">
{{i18n.orderDetails.text24}}
</view>
<view @click="show1=true" v-if="data.status==2&&data.type==2" class="okbtn">{{i18n.orderDetails.text25}}
</view>
</view>
</view>
<!-- 取消弹窗 -->
<u-popup v-model="show" mode="center" border-radius="20">
<view class="width-600 height-266" style="overflow: hidden;"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-170 flex align-center justify-center">
<text class="font-32 color-FF4040 weight-bold">{{i18n.orderDetails.text26}}</text>
</view>
<!-- <input class="input" type="text" v-model="paypwd" placeholder="请输入交易密码" placeholder-class="color-C3C3C3"
password /> -->
<view class="height-98 flex">
<view @click="show=false" class="flex-1 line-height-98 text-center bj-c3c3c3-02">
<text class="font-28 color-C3C3C3 weight-bold">{{i18n.orderDetails.text27}}</text>
</view>
<view @click="getcancel" class="flex-1 line-height-98 text-center bj-0165EE">
<text class="font-28 color-white weight-bold">{{i18n.orderDetails.text28}}</text>
</view>
</view>
</view>
</u-popup>
<!-- 确认收款弹窗 -->
<u-popup v-model="show1" mode="center" border-radius="20">
<view class="width-600 height-266" style="overflow: hidden;"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-170 flex align-center justify-center">
<text class="font-32 color-FF4040 weight-bold">{{i18n.orderDetails.text29}}</text>
</view>
<!-- <input class="input" type="text" v-model="paypwd" placeholder="请输入交易密码" placeholder-class="color-C3C3C3"
password /> -->
<view class="height-98 flex">
<view @click="show1=false" class="flex-1 line-height-98 text-center bj-c3c3c3-02">
<text class="font-28 color-C3C3C3 weight-bold">{{i18n.orderDetails.text27}}</text>
</view>
<view @click="getsucc" class="flex-1 line-height-98 text-center bj-0165EE">
<text class="font-28 color-white weight-bold">{{i18n.orderDetails.text28}}</text>
</view>
</view>
</view>
</u-popup>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
timestamp: 0,
id: '',
data: '',
img: '',
upimg: '',
voimg: '',
flag: true,
show: false,
show1: false,
statusText: ['', '', '', '', '', ''],
theme: '',
}
},
onLoad(e) {
this.id = e.id
},
computed: {
i18n() {
return this.$t('message');
}
},
// onPullDownRefresh() {
// console.log('下拉刷新');
// this.getDetails()
// this.changekind()
// setTimeout(function() {
// uni.stopPullDownRefresh();
// }, 1500);
// },
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getDetails()
this.changekind()
},
methods: {
onRefresh() {
this.getDetails()
this.changekind()
// 以告知z-paging下拉刷新结束,这样才可以开始下一次的下拉刷新
setTimeout(() => {
//1.5秒之后停止刷新动画
this.$refs.paging.complete();
}, 1500)
},
changekind() {
this.statusText[1] = this.i18n.orderRecord.text10
this.statusText[2] = this.i18n.orderRecord.text11
this.statusText[3] = this.i18n.orderRecord.text12
this.statusText[4] = this.i18n.orderRecord.text13
this.statusText[5] = this.i18n.orderRecord.text14
},
// 呼叫
callup(phone) {
uni.makePhoneCall({
phoneNumber: phone, //仅为示例
success: () => {
}
});
},
// 确认收款并放币
getsucc() {
if (!this.flag) {
return
} else {
this.show1 = false
uni.showLoading({
title: '',
mask: true
})
this.flag = false
this.post('/marketotc/order_succ', {
id: this.data.id
}).then(res => {
console.log('确认收款返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.getDetails()
}
})
}
},
// 查看支付凭证
yulanImg(img, type) {
if (type == 1) {
// let arr = []
let arr = img.split()
// arr.push(img)
uni.previewImage({
urls: arr
})
} else {
uni.previewImage({
urls: img
})
}
},
// 取消订单
getcancel() {
if (!this.flag) {
return
} else {
this.show = false
uni.showLoading({
title: '',
mask: true
})
this.flag = false
this.post('/marketotc/order_cancel', {
id: this.data.id
}).then(res => {
console.log('上传支付凭证返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.getDetails()
}
})
}
},
// 上传支付凭证
getorder_pay() {
if (this.upimg == '') return this.tos(this.i18n.orderDetails.tos1)
if (!this.flag) {
return
} else {
uni.showLoading({
title: '',
mask: true
})
this.flag = false
let obj = {
id: this.data.id,
voucher_image: this.upimg
}
this.post('/marketotc/order_pay', obj).then(res => {
console.log('上传支付凭证返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.getDetails()
}
})
}
},
// 选择支付凭证
chooseImage() {
let self = this
uni.chooseImage({
count: 1,
success: (chooseImageRes) => {
const tempFilePaths = chooseImageRes.tempFilePaths;
self.img = tempFilePaths[0]
uni.showLoading()
uni.uploadFile({
url: this.upload + '/publics/image_upload',
filePath: tempFilePaths[0],
name: 'file',
success: (res) => {
let data = JSON.parse(res.data)
uni.hideLoading()
if (data.code == 1) {
// console.log(data)
self.upimg = data.data.url
}
}
})
}
})
},
// 获取订单详情
getDetails() {
uni.showLoading({
title: '',
mask: true
})
this.post('/marketotc/content_order', {
id: this.id
}).then(res => {
console.log('订单详情', res)
if (res.code == 1) {
uni.hideLoading()
this.data = res.data
if (this.data.status != 1 && this.data.voucher_image != null) {
this.voimg = res.data.voucher_image[0]
}
let h = res.data.h
let i = res.data.i
let s = res.data.s
this.timestamp = (h * 60 * 60) + (i * 60) + s
this.$refs.uCountDown.start();
}
})
},
}
}
</script>
<style lang="scss">
.box {
width: 690rpx;
padding: 22rpx 24rpx 20rpx;
// background: #FFFFFF;
box-shadow: 0rpx 4rpx 10rpx rgba(205, 206, 219, 0.3);
border-radius: 20rpx;
margin-bottom: 24rpx;
}
.nobtn {
width: 300rpx;
height: 96rpx;
background: #F6F8FB;
border-radius: 10rpx;
font-size: 30rpx;
color: #8B99A2;
line-height: 96rpx;
text-align: center;
}
.okbtn {
width: 300rpx;
height: 96rpx;
background: #0165EE;
border-radius: 10rpx;
font-size: 30rpx;
color: #FFFFFF;
line-height: 96rpx;
text-align: center;
}
.bj-c3c3c3-02 {
background: rgba(195, 195, 195, 0.2);
}
.input {
width: 540rpx;
height: 76rpx;
margin: 0 auto;
border-radius: 20rpx;
background: #F6F8FC;
font-size: 28rpx;
color: #8B99A2;
padding: 0 24rpx;
}
</style>
+247
View File
@@ -0,0 +1,247 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav :title="i18n.orderRecord.title" isRight righturl="/static/imgs/index/shaixuan@2x.png"
@Jump="show=true,cache1=kind1,cache2=kind2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-w-30 padding-b-40">
<!-- 单一列表 -->
<view @click="router.push('/pages/index/orderDetails?id='+item.id)" v-for="(item,index) in list"
class="height-184 border-bottom margin-b-15">
<view class="padding-t-21 flex align-center justify-between">
<view class="flex align-center">
<image class="width-48 height-48 radiu-24" :src="item.avatar" mode=""></image>
<text class="font-26 weight-bold margin-l-16 margin-r-23">{{item.nickname}}</text>
<image class="width-46 height-42" src="/static/imgs/index/yinhangka.png" mode=""></image>
</view>
<!-- <text class="font-26 color-C3C3C3">{{item.status|checkstatus}}</text> -->
<text class="font-26 color-C3C3C3">{{statusText[item.status]}}</text>
</view>
<view class="margin-t-22 flex align-center">
<view class="flex-1 flex direction-column">
<view class="font-24 color-C3C3C3 margin-b-10">{{i18n.orderRecord.text1}}</view>
<view class="font-24 numbold-font">{{item.add_time}}</view>
</view>
<view class="flex-1 flex direction-column align-center">
<view class="font-24 color-C3C3C3 margin-b-10">{{i18n.orderRecord.text2}}({{item.name}})
</view>
<view class="font-24 numbold-font">{{item.num}}</view>
</view>
<view class="flex-1 flex direction-column align-end">
<view class="font-24 color-C3C3C3 margin-b-10">{{i18n.orderRecord.text3}}({{item.symbol}})
</view>
<view class="font-24 numbold-font">{{item.count_price}}</view>
</view>
</view>
</view>
</view>
<!-- 筛选弹窗 -->
<u-popup :mask-close-able="false" v-model="show" mode="top" border-radius="20">
<view class="padding-t-30" :style="{paddingTop: statusBar + 'px',background:theme.bg,color:theme.text}">
<view class="height-110 flex align-center padding-w-30">
<u-icon @click="closeshow" name="arrow-leftward" size="36"></u-icon>
</view>
<view class="padding-w-30">
<view class="height-66 flex align-center font-30 color-C3C3C3">{{i18n.orderRecord.text4}}</view>
<view class="margin-t-24 flex align-center flex-wrap">
<view @click="setkind1(item.id)" v-for="(item,index) in kindlist1"
:class="item.id==kind1?'onbox':'offbox'">{{item.name}}</view>
</view>
</view>
<view class="padding-w-30">
<view class="height-66 flex align-center font-30 color-C3C3C3">{{i18n.orderRecord.text5}}</view>
<view class="margin-t-24 flex align-center flex-wrap">
<view @click="setkind2(item.id)" v-for="(item,index) in kindlist2"
:class="item.id==kind2?'onbox':'offbox'">{{item.name}}</view>
</view>
</view>
<view class="height-96 flex">
<view @click="reset" class="flex-1 height-96 line-height-96 text-center bj-c3c3c3-02">
<text class="font-28 color-C3C3C3">{{i18n.orderRecord.text6}}</text>
</view>
<view @click="confirm" class="flex-1 height-96 line-height-96 text-center bj-0165EE">
<text class="font-28 color-white">{{i18n.orderRecord.text7}}</text>
</view>
</view>
</view>
</u-popup>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
show: false,
kindlist1: [{
id: 1,
name: '买入'
},
{
id: 2,
name: '卖出'
}
],
kindlist2: [{
id: 1,
name: '待付款'
},
{
id: 2,
name: '已付款'
},
{
id: 3,
name: '申诉中'
},
{
id: 4,
name: '已完成'
},
{
id: 5,
name: '已取消'
}
],
kind1: '',
kind2: '',
cache1: '',
cache2: '',
list: [],
page: 1,
state: 'more',
ischange: false,
statusText: ['', '', '', '', '', ''],
theme: '',
}
},
// onReachBottom() {
// this.page++
// this.getlist()
// },
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.changekind()
},
methods: {
changekind() {
this.kindlist1[0].name = this.i18n.orderRecord.text8
this.kindlist1[1].name = this.i18n.orderRecord.text9
this.kindlist2[0].name = this.i18n.orderRecord.text10
this.kindlist2[1].name = this.i18n.orderRecord.text11
this.kindlist2[2].name = this.i18n.orderRecord.text12
this.kindlist2[3].name = this.i18n.orderRecord.text13
this.kindlist2[4].name = this.i18n.orderRecord.text14
this.statusText[1] = this.i18n.orderRecord.text10
this.statusText[2] = this.i18n.orderRecord.text11
this.statusText[3] = this.i18n.orderRecord.text12
this.statusText[4] = this.i18n.orderRecord.text13
this.statusText[5] = this.i18n.orderRecord.text14
},
confirm() {
this.show = false
this.list=[]
this.queryList(1,10)
},
reset() {
this.kind1 = ''
this.kind2 = ''
this.cache1 = ''
this.cache2 = ''
this.show = false
this.list=[]
this.queryList(1,10)
},
closeshow() {
this.kind1 = this.cache1
this.kind2 = this.cache2
this.show = false
},
setkind2(id) {
if (this.kind2 != id) {
// this.cache2 = this.kind2
this.kind2 = id
}
},
setkind1(id) {
if (this.kind1 != id) {
// this.cache1 = this.kind1
this.kind1 = id
}
},
queryList(pageNo, pageSize) {
this.post('/marketotc/order_list', {
page: pageNo,
page_num: pageSize,
type: this.kind1,
status: this.kind2,
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
},
}
}
</script>
<style lang="scss">
.border-bottom {
border-bottom: 1rpx solid rgba(191, 195, 199, 0.3);
}
.offbox {
width: 180rpx;
height: 56rpx;
background: #EDEFF6;
border-radius: 10rpx;
font-size: 28rpx;
font-weight: 400;
color: #17181A;
line-height: 56rpx;
text-align: center;
margin-right: 50rpx;
margin-bottom: 32rpx;
}
.onbox {
width: 180rpx;
height: 56rpx;
background: #06C38D;
border-radius: 10rpx;
font-size: 28rpx;
font-weight: 400;
color: #FFFFFF;
line-height: 56rpx;
text-align: center;
margin-right: 50rpx;
margin-bottom: 32rpx;
}
.bj-c3c3c3-02 {
background: rgba(195, 195, 195, 0.2);
}
</style>
+114
View File
@@ -0,0 +1,114 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<myNav :title="i18n.recharge.title3"></myNav>
<!-- 身体 -->
<view class="width-750 padding-b-40 padding-w-30 padding-t-84">
<view class="flex direction-column align-center">
<image class="width-186 height-186" src="/static/imgs/index/tibiok.png" mode=""></image>
<view class="margin-t-51 margin-b-11">
<text class="font-42 numbold-font">{{data.price}}</text>
<text class="font-26 nummedium-font margin-l-5">{{data.name}}</text>
</view>
<text class="font-28 color-C3C3C3">{{i18n.recharge.text9}}</text>
</view>
<view class="width-690 height-600 radiu-20 margin-t-48 padding-w-32 padding-c-28 flex direction-column justify-between"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text10}}</view>
<view class="flex-9 font-28 color-00C481 weight-bold">{{i18n.withdraw.text14}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text11}}</view>
<view class="flex-9 font-28 weight-bold">{{statusText[data.status]}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text12}}</view>
<view class="flex-9 font-28 numbold-font">{{data.name}}</view>
</view>
<view v-if="data.hash" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text13}}</view>
<view class="flex-9 font-28 numbold-font">{{data.hash}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text14}}</view>
<view class="flex-9 font-28 numbold-font">{{data.createtime}}</view>
</view>
<view v-if="data.address" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title5}}</view>
<view class="flex-9 font-28 numbold-font">{{data.address}}</view>
</view>
<view v-if="data.bank_name" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title15}}</view>
<view class="flex-9 font-28 numbold-font">{{data.bank_name}}</view>
</view>
<view v-if="data.card_num" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title16}}</view>
<view class="flex-9 font-28 numbold-font">{{data.card_num}}</view>
</view>
<view v-if="data.voucher_image" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title17}}</view>
<view class="flex-9">
<image @click="wacth(data.voucher_image)" class="width-200 height-200 radiu-20" :src="data.voucher_image" mode=""></image>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
data: '',
statusText: ['', '', ''],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.changestatus()
this.getDetails(e.id)
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
wacth(url) {
uni.previewImage({
urls: [url]
})
},
changestatus() {
this.statusText[0] = this.i18n.recharge.text15
this.statusText[1] = this.i18n.recharge.text16
this.statusText[2] = this.i18n.recharge.text17
},
getDetails(id) {
let obj = {
id: id,
cart: 1
}
this.post('/wallet/recharge_con', obj).then(res => {
console.log(res)
if (res.code == 1) {
this.data = res.data
}
})
}
}
}
</script>
<style lang="scss">
</style>
+70
View File
@@ -0,0 +1,70 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus"></custom-refresher>
<myNav slot="top" :title="i18n.recharge.title2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-b-40">
<view @click="goDetails(item.id)" v-for="(item,index) in list"
class="height-150 padding-w-30 padding-t-24 padding-b-27 flex direction-column justify-between margin-t-16">
<view class="flex align-center justify-between">
<text class="font-32 color-00C481 nummedium-font">+{{item.price}}</text>
<text v-if="item.status==0" class="font-28 nummedium-font">{{i18n.recharge.title12}}</text>
<text v-if="item.status==1" class="font-28 nummedium-font">{{i18n.recharge.title13}}</text>
<text v-if="item.status==2" class="font-28 nummedium-font">{{i18n.recharge.title14}}</text>
</view>
<text class="font-24 color-C3C3C3 nummedium-font">{{item.createtime}}</text>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(()=>{
this.post('/wallet/get_recharge_log', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
},500)
},
goDetails(id) {
uni.navigateTo({
url: '/pages/index/rechargeDetails?id=' + id
})
},
}
}
</script>
<style lang="scss">
</style>
+559
View File
@@ -0,0 +1,559 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100%;min-height: 100vh;">
<!-- 头部 -->
<view class="width-750 relative flex align-center justify-center"
:style="{height: `calc(${statusBar}px + 220rpx)`}">
<view class="width-750 fixed1"
:style="{paddingTop: statusBar + 'px', height: `calc(${statusBar}px + 220rpx)`}">
<view class="width-750 height-110 padding-w-30 flex align-center justify-center">
<view @click="_goback" class="cuIcon-back font-40 color-white"
style="position: absolute;left: 30rpx;"></view>
<text class="font-36 color-white weight-bold">{{i18n.releaseTrade.title}}</text>
<view class="flex align-center" style="position: absolute;right: 30rpx;">
<view @click.stop="show=true" class="switchbox">
<text class="nummedium-font">{{faby}}</text>
<image class="width-34 height-34 margin-l-5" src="/static/imgs/index/change@2x.png" mode="">
</image>
</view>
</view>
</view>
<view class="height-110 flex align-center padding-w-30">
<view class="flex-9 flex align-center">
<view @click="changeType(1)" class="flex-1" :class="currtype==1?'onfont':'offfont'">
{{i18n.releaseTrade.text1}}
</view>
<view @click="changeType(2)" class="flex-1" :class="currtype==2?'onfont':'offfont'">
{{i18n.releaseTrade.text2}}
</view>
</view>
<view class="flex-3 flex align-center justify-end">
<image @click="router.push('/pages/index/fastRecord')" class="width-54 height-54"
src="/static/imgs/index/jilu@2x.png" mode=""></image>
</view>
</view>
</view>
</view>
<!-- 身体 -->
<view class="width-750 padding-b-40">
<!-- 币种 -->
<view class="height-72 bj-0165EE">
<view class="height-72 flex align-center"
:style="'background-color: '+theme.bg+';color: '+theme.text"
style="border-radius: 20rpx 20rpx 0 0;">
<view class="width-100b height-100b">
<scroll-view scroll-x="true">
<view class="flex align-center">
<view @click.stop="setiscurr(item)" v-for="(item,index) in currlist"
class="height-72 padding-w-30 flex direction-column align-center justify-center relative">
<text :class="currid==item.id?'select':'noselect'">{{item.name}}</text>
<view v-if="currid==item.id" class="width-48 height-4 bj-0165EE"
style="position: absolute;bottom: 0;"></view>
</view>
</view>
</scroll-view>
</view>
</view>
</view>
<!-- 数量 -->
<view class="width-690 margin-0-auto border-bottom">
<view class="height-96 flex align-center justify-between">
<text class="font-30">{{currtype==1?i18n.releaseTrade.text3:i18n.releaseTrade.text4}}</text>
</view>
<view class="height-96 flex align-center">
<input class="flex-1 font-30" type="text" v-model="number"
:placeholder="currtype==1?i18n.releaseTrade.tos1:i18n.releaseTrade.tos2"/>
</view>
</view>
<!-- 限额 -->
<view class="width-690 margin-0-auto border-bottom margin-t-23">
<view class="height-96 flex align-center justify-between">
<text class="font-30">{{i18n.releaseTrade.text5}}</text>
</view>
<view class="height-96 flex align-center">
<input class="input" type="number" :placeholder="i18n.releaseTrade.tos3" v-model="min" />
<view class="width-105 text-center">~</view>
<input class="input" type="number" :placeholder="i18n.releaseTrade.tos4" v-model="max" />
<view class="width-105 text-right">
<text class="font-30 nummedium-font">{{faby}}</text>
</view>
</view>
</view>
<!-- 单价 -->
<view class="width-690 margin-0-auto border-bottom margin-t-23">
<view class="height-96 flex align-center justify-between">
<text class="font-30">{{i18n.releaseTrade.text6}}</text>
</view>
<view class="height-96 flex align-center justify-between">
<input class="flex-1 padding-r-30 font-30" type="text" v-model="price"
:placeholder="i18n.releaseTrade.tos5" />
<text class="font-30 nummedium-font">{{faby}}</text>
</view>
</view>
<!-- 交易密码 -->
<view class="width-690 margin-0-auto border-bottom margin-t-23">
<view class="height-96 flex align-center justify-between">
<text class="font-30">{{i18n.releaseTrade.text7}}</text>
</view>
<view class="height-96 flex align-center">
<input class="flex-1 font-30" type="text" v-model="paypwd"
:placeholder="i18n.releaseTrade.tos6" password />
</view>
</view>
<!-- 支付方式 -->
<view class="width-690 margin-0-auto margin-t-23">
<view class="height-96 flex align-center justify-between">
<text
class="font-30">{{currtype==1?i18n.releaseTrade.text8:i18n.releaseTrade.text9}}</text>
<view class="flex align-center font-30">
<text>{{fabyname}}</text>
<!-- <u-icon name="arrow-right" color="#8B99A2" size="24"></u-icon> -->
</view>
</view>
</view>
<!-- 收款账户 -->
<view v-if="currtype==2" class="width-690 margin-0-auto margin-t-23">
<view @click="show1=true" class="height-96 flex align-center justify-between">
<text class="font-30">{{i18n.releaseTrade.text10}}</text>
<view class="flex align-center font-30">
<text v-if="collecid!=''">{{collecdata.card_num|changestyle}}</text>
<u-icon name="arrow-right" size="24"></u-icon>
</view>
</view>
</view>
<!-- 按钮 -->
<view @click.stop="openshow" class="buybtn margin-0-auto margin-t-100">
<text>{{i18n.releaseTrade.text11}}</text>
</view>
</view>
<!-- 确认发布弹窗 -->
<u-popup v-model="fbshow" mode="bottom" border-radius="20">
<view class="height-600 padding-w-30"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-105 padding-t-22 padding-b-38 flex align-center justify-center">
<text class="font-30 weight-bold">{{currtype==1?i18n.releaseTrade.text12:i18n.releaseTrade.text13}}</text>
<view @click="fbshow=false" style="position: absolute;right: 30rpx;" class="font-26 color-C3C3C3">
{{i18n.releaseTrade.text14}}
</view>
</view>
<view class="height-106 flex align-center justify-center font-48 color-FF4040 numbold-font">
<!-- <u-icon name="rmb" color="#FF4040" size="42"></u-icon> -->
<text class="font-36 color-FF4040">{{fabysym}}</text>
<text class="margin-l-5">{{(number*price).toFixed(2)}}</text>
</view>
<view class="height-66 margin-t-42 flex align-center justify-between font-30">
<text>{{i18n.releaseTrade.text15}}</text>
<text class="nummedium-font">{{price}} {{faby}}</text>
</view>
<view class="height-66 flex align-center justify-between font-30">
<text>{{i18n.releaseTrade.text16}}</text>
<text class="nummedium-font">{{number}} {{curr}}</text>
</view>
<!-- <view class="height-192">
<view v-for="(item,index) in 2" class="height-96 flex align-center justify-between">
<view class="flex align-center">
<image class="width-46 height-46 radiu-23" src="/static/logo.png" mode=""></image>
<text class="font-30 color-333333 margin-l-22">RM</text>
</view>
<image class="width-34 height-34 radiu-17" :src="iscurr==index?XZ:WX" mode=""></image>
</view>
</view> -->
<view @click.stop="closeshow" class="buybtn margin-t-86">
<text>{{i18n.releaseTrade.text17}}</text>
</view>
</view>
</u-popup>
<!-- 法币弹窗 -->
<u-popup v-model="show" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-96 line-height-96 text-center relative">
<text class="font-30 weight-bold">{{i18n.releaseTrade.text18}}</text>
<text @click.stop="show=false" class="font-26 color-C3C3C3 absolute"
style="right: 0;">{{i18n.releaseTrade.text14}}</text>
</view>
<scroll-view scroll-y="true" class="height-450">
<view @click="setFaby(item)" v-for="(item,index) in fabylist"
class="height-96 flex align-center justify-between">
<view class="flex align-center">
<image class="width-48 height-48 radiu-24" :src="item.pay_image" mode=""></image>
<text class="font-28 margin-l-16">{{item.curr_name}}</text>
</view>
<image class="width-36 height-36" :src="fabyid==item.id?XZ:WX" mode=""></image>
</view>
</scroll-view>
</view>
</u-popup>
<!-- 收款账户弹窗 -->
<u-popup v-model="show1" mode="bottom" border-radius="20">
<view class="padding-w-30 padding-b-36"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="height-96 line-height-96 text-center relative">
<text class="font-30 weight-bold">{{i18n.releaseTrade.text19}}</text>
<text @click.stop="show1=false" class="font-26 color-C3C3C3 absolute"
style="right: 0;">{{i18n.releaseTrade.text14}}</text>
</view>
<scroll-view scroll-y="true" class="height-450">
<view @click="setcollec(item)" v-for="(item,index) in collec"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text"
class="height-96 flex align-center justify-between margin-b-10 radiu-10 padding-w-20">
<view class="flex-1 padding-r-24 height-96 flex direction-column justify-around">
<view class="flex align-center">
<text>{{item.username}}</text>
<text class="font-28 margin-l-16">{{item.card_num|changestyle}}</text>
</view>
<view class="font-24 color-C3C3C3">{{item.bank_name}}</view>
</view>
<image class="width-36 height-36" :src="collecid==item.id?XZ:WX" mode=""></image>
</view>
</scroll-view>
</view>
</u-popup>
<!-- 去实名 -->
<u-popup style="z-index: 5000;" border-radius="18" mode="center" v-model="TSShow">
<view class="width-600 padding-b-20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<view class="width-100b height-220 padding-w-30 padding-c-40 flex direction-column align-center justify-between">
<image class="width-64 height-64" src="/static/imgs/quantify/tongzhi@2x.png" mode=""></image>
<view class="font-28 weight-bold text-center padding-w-20">{{i18n.releaseTrade.text20}}
</view>
</view>
<view class="width-100b height-90 flex align-center justify-center">
<view @click="TSShow=false,router.push('/pages/my/safety/real')" class="qcbtn3">
{{i18n.releaseTrade.text21}}</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
statusBar: uni.getSystemInfoSync().statusBarHeight,
currtype: 1, //1我要买,2我要卖
fbshow: false, //发布弹窗
iscurr: 0,
XZ: '/static/imgs/quantify/xuanzhong@2x.png',
WX: '/static/imgs/quantify/weixuanzhong@2x.png',
show: false, //法币弹窗
faby: '', //法币
fabyid: '', //法币id
fabyname: '', //法币国家名称
fabylist: [], //法币列表
fabysym: '',
curr: '', //币种
currid: '', //当前币种id
currlist: [], //币种列表
flag: true,
number: '', //数量
min: '', //最小
max: '', //最大
price: '', //价格
paypwd: '', //交易密码
show1: false,
collec: [], //收款账户列表
collecid: '', //当前收款账户id
collecdata: '', //当前收款账户对象
TSShow: false,
theme: '',
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
this.getCurrlist()
this.getFabylist()
this.getcollection()
},
computed: {
i18n() {
return this.$t('message');
}
},
filters: {
changestyle(e) {
let str = e
var reg = /^(\d{4})\d+(\d{4})$/;
str = str.replace(reg, "$1 **** $2");
return str
}
},
methods: {
// 发布我要卖
getquick_sell() {
if (!this.flag) {
return
} else {
this.flag = false
let obj = {
num: this.number,
price: this.price,
min_price: this.min,
max_price: this.max,
pay_pwd: this.paypwd,
country_id: this.fabyid,
curr_id: this.currid,
payment: 1,
collection_id: this.collecid
}
this.post('/marketotc/quick_sell', obj).then(res => {
console.log('发布返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.number = ''
this.price = ''
this.min = ''
this.max = ''
this.paypwd = ''
setTimeout(() => {
uni.navigateTo({
url: '/pages/index/fastRecord'
})
}, 500)
} else {
uni.hideToast()
if (res.data.jump == 1) {
this.number = ''
this.price = ''
this.min = ''
this.max = ''
this.paypwd = ''
this.TSShow = true
}
}
})
}
},
// 发布我要买
getquick_buy() {
if (!this.flag) {
return
} else {
this.flag = false
let obj = {
num: this.number,
price: this.price,
min_price: this.min,
max_price: this.max,
pay_pwd: this.paypwd,
country_id: this.fabyid,
curr_id: this.currid,
payment: 1,
}
this.post('/marketotc/quick_buy', obj).then(res => {
console.log('发布返回', res)
this.flag = true
uni.hideLoading()
if (res.code == 1) {
this.tos(res.msg)
this.number = ''
this.price = ''
this.min = ''
this.max = ''
this.paypwd = ''
setTimeout(() => {
uni.navigateTo({
url: '/pages/index/fastRecord'
})
}, 500)
} else {
uni.hideToast()
if (res.data.jump == 1) {
this.number = ''
this.price = ''
this.min = ''
this.max = ''
this.paypwd = ''
this.TSShow = true
}
}
})
}
},
closeshow() {
this.fbshow = false
uni.showLoading({
title: '',
mask: true
})
if (this.currtype == 1) {
this.getquick_buy()
} else {
this.getquick_sell()
}
},
openshow() {
if (this.number == '') return this.tos(this.i18n.releaseTrade.tos7)
if (this.min == '' || this.max == '') return this.tos(this.i18n.releaseTrade.tos8)
if (this.price == '') return this.tos(this.i18n.releaseTrade.tos5)
if (this.paypwd == '') return this.tos(this.i18n.releaseTrade.tos6)
this.fbshow = true
},
// 选择账户
setcollec(item) {
if (this.collecid != item.id) {
this.collecid = item.id
this.collecdata = item
this.show1 = false
}
},
// 获取收款账户列表
getcollection() {
this.post('/marketotc/get_collection').then(res => {
console.log('收款账户列表', res)
if (res.code == 1 && res.data && res.data.length > 0) {
this.collec = res.data
this.collecid = res.data[0].id
this.collecdata = res.data[0]
} else {
// 如果没有收款账户或数据为空,设置默认值
this.collec = []
this.collecid = ''
this.collecdata = ''
}
})
},
// 选择法币
setFaby(item) {
this.faby = item.curr_name
this.fabyid = item.id
this.fabyname = item.pay_name
this.fabysym = item.symbol
this.show = false
},
// 获取法币列表
getFabylist() {
this.post('/marketotc/get_country').then(res => {
console.log('法币列表', res)
if (res.code == 1) {
this.fabylist = res.data
this.faby = res.data[0].curr_name
this.fabyid = res.data[0].id
this.fabyname = res.data[0].pay_name
this.fabysym = res.data[0].symbol
}
})
},
// 选择币种
setiscurr(item) {
if (this.currid != item.id) {
this.currid = item.id
this.curr = item.name
}
},
// 获取币种列表
getCurrlist() {
this.post('/marketotc/get_curr').then(res => {
console.log('币种列表', res)
if (res.code == 1) {
this.currlist = res.data
this.currid = res.data[0].id
this.curr = res.data[0].name
}
})
},
// 选择买或卖
changeType(i) {
if (this.currtype != i) {
this.currtype = i
}
},
}
}
</script>
<style lang="scss">
.fixed1 {
position: fixed;
top: 0;
z-index: 1000;
background: #06C38D;
}
.onfont {
font-size: 32rpx;
font-weight: bold;
color: #FFFFFF;
}
.offfont {
font-size: 28rpx;
font-weight: 400;
color: #FFFFFF;
opacity: 0.5;
}
.border-bottom {
border-bottom: 1rpx solid rgba(191, 195, 199, 0.2);
}
.buybtn {
width: 690rpx;
height: 96rpx;
background: #06C38D;
opacity: 1;
border-radius: 10rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 32rpx;
color: #FFFFFF;
}
.select {
font-size: 28rpx;
font-family: "Bold" !important;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color: #06C38D;
}
.noselect {
font-size: 26rpx;
font-family: "Medium" !important;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color: #8B99A2;
}
.input {
width: 240rpx;
height: 66rpx;
// background: #F6F8FB;
border: 1rpx solid #E5E5E5;
opacity: 1;
border-radius: 10rpx;
font-size: 28rpx;
text-align: center;
// color: #D1D3D8;
padding: 0 20rpx;
}
.qcbtn3 {
width: 320rpx;
height: 86rpx;
background: #06C38D;
border-radius: 20rpx;
font-size: 28rpx;
font-weight: bold;
color: #FFFFFF;
display: flex;
align-items: center;
justify-content: center;
}
</style>
+51
View File
@@ -0,0 +1,51 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100%;">
<myNav :title="i18n.ico.three6"></myNav>
<view class="padding-30" v-html="data.white_paper">
</view>
</view>
</template>
<script>
export default {
data() {
return {
theme: '',
data:{}
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.ico = e.ico
this.getDetails()
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
// 获取私募内容
getDetails() {
this.post('/index/ico_content', {
id: this.ico
}).then(res => {
console.log('私募内容', res)
if (res.code == 1) {
this.data = res.data
}
})
},
}
}
</script>
<style lang="scss">
</style>
+99
View File
@@ -0,0 +1,99 @@
<template>
<view :style="'background-color: '+theme.bg+';color: '+theme.text" style="height: 100vh;">
<myNav :title="i18n.withdraw.title3"></myNav>
<!-- 身体 -->
<view class="width-750 padding-b-40 padding-w-30 padding-t-84">
<view class="flex direction-column align-center">
<image v-if="data.status==1" class="width-186 height-186" src="/static/imgs/index/tibiok.png" mode=""></image>
<image v-else class="width-186 height-186" src="/static/imgs/index/tibiok2.png" mode=""></image>
<view class="margin-t-51 margin-b-11">
<text class="font-42 numbold-font">{{data.price}}</text>
<text class="font-26 nummedium-font margin-l-5">{{data.name}}</text>
</view>
<text class="font-28 color-C3C3C3">{{i18n.recharge.text9}}</text>
</view>
<view class="width-690 height-480 radiu-20 margin-t-48 padding-w-32 padding-c-28 flex direction-column justify-between"
:style="'background-color: '+theme.fu_bg+';color: '+theme.text">
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text10}}</view>
<view class="flex-9 font-28 weight-bold">{{i18n.withdraw.text15}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text11}}</view>
<view :class="data.status==1?'color-00C481':'color-FF4040'" class="flex-9 font-28 weight-bold">{{statusText[data.status]}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text12}}</view>
<view class="flex-9 font-28 numbold-font">{{data.name}}</view>
</view>
<view v-if="data.hash" class="flex align-center">
<view class="flex-1 font-28 color-C3C3C3">{{i18n.recharge.text13}}</view>
<view class="width-470 font-28 numbold-font" style="word-wrap: break-word;">{{data.hash}}</view>
</view>
<view v-if="data.bank_name" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title15}}</view>
<view class="flex-9 font-28 numbold-font">{{data.bank_name}}({{data.bank_user}})</view>
</view>
<view v-if="data.card_num" class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.title16}}</view>
<view class="flex-9 font-28 numbold-font">{{data.card_num}}</view>
</view>
<view class="flex align-center">
<view class="flex-3 font-28 color-C3C3C3">{{i18n.recharge.text14}}</view>
<view class="flex-9 font-28 numbold-font">{{data.createtime}}</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
data: '',
statusText: ['', '', ''],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onLoad(e) {
this.changestatus()
this.getDetails(e.id)
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
changestatus() {
this.statusText[0] = this.i18n.recharge.text15
this.statusText[1] = this.i18n.recharge.text16
this.statusText[2] = this.i18n.recharge.text17
},
getDetails(id) {
let obj = {
id: id,
cart: 2
}
this.post('/wallet/recharge_con', obj).then(res => {
console.log(res)
if (res.code == 1) {
this.data = res.data
}
})
}
}
}
</script>
<style lang="scss">
</style>
+74
View File
@@ -0,0 +1,74 @@
<template>
<view>
<z-paging :language="$i18n.locale" ref="paging" v-model="list" @query="queryList" :pageSize="20"
:style="'background-color: '+theme.bg+';color: '+theme.text">
<!-- 下拉刷新 -->
<custom-refresher slot="refresher" slot-scope="{refresherStatus}" :status="refresherStatus">
</custom-refresher>
<myNav slot="top" :title="i18n.withdraw.title2"></myNav>
<!-- 身体 -->
<view class="width-750 padding-b-40">
<view @click="goDetails(item.id)" v-for="(item,index) in list"
class="padding-w-30 padding-t-24 flex direction-column margin-t-16">
<view class="flex align-center justify-between">
<text class="font-32 color-FF4040 nummedium-font">-{{item.price}}</text>
<text v-if="item.status==0" class="font-28 nummedium-font">{{i18n.recharge.title12}}</text>
<text v-if="item.status==1" class="font-28 nummedium-font">{{i18n.recharge.title13}}</text>
<text v-if="item.status==2" class="font-28 nummedium-font">{{i18n.recharge.title14}}</text>
</view>
<text class="font-24 color-C3C3C3 nummedium-font margin-t-20">{{item.createtime}}</text>
<view v-if="item.description" class="padding-20 color-FF4040">
{{item.description}}
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script>
export default {
data() {
return {
list: [],
theme: '',
}
},
computed: {
i18n() {
return this.$t('message');
}
},
onShow() {
if (uni.getStorageSync("theme") == "dark") {
this.theme = this.$store.state.darkTheme
} else {
this.theme = this.$store.state.lightTheme
}
},
methods: {
queryList(pageNo, pageSize) {
setTimeout(() => {
this.post('/wallet/get_width_log', {
page: pageNo,
page_num: pageSize
}).then(res => {
if (res.code == 1) {
console.log(res)
this.$refs.paging.complete(res.data.data);
}
})
}, 500)
},
goDetails(id) {
uni.navigateTo({
url: '/pages/index/withdrawalDetails?id=' + id
})
},
}
}
</script>
<style lang="scss">
</style>