Commit 9a237c02 authored by leiqingsong's avatar leiqingsong

Merge branch 'dev_lqs' into 'master'

修改

See merge request !83
parents 91723f9f 50943c82
...@@ -22,7 +22,7 @@ export default { ...@@ -22,7 +22,7 @@ export default {
this.currentTitle = val.meta.title; this.currentTitle = val.meta.title;
} }
}, },
created() { mounted() {
console.log("和App开始交互"); console.log("和App开始交互");
this.$bridgeToAppFun this.$bridgeToAppFun
.getAuthToken() .getAuthToken()
......
...@@ -81,6 +81,7 @@ export default { ...@@ -81,6 +81,7 @@ export default {
position: absolute; position: absolute;
top: 0; top: 0;
right: 0; right: 0;
color: #c3c3c3;
} }
.content-submit-btn { .content-submit-btn {
position: absolute; position: absolute;
......
<template> <template>
<div class="cash-out-record"> <div class="cash-out-record">
<div id="top-month"> <div id="top-month">
<span style="width: 90px; margin-right: 5px">{{ selected }}</span> <span style="margin-right: 5px">{{ selected }}</span>
<van-icon name="arrow-down" @click="show = true" /> <van-icon name="arrow-down" @click="show = true" />
</div> </div>
<div class="record-list"> <div class="record-list">
...@@ -18,6 +18,7 @@ ...@@ -18,6 +18,7 @@
<van-datetime-picker <van-datetime-picker
v-model="currentDate" v-model="currentDate"
type="year-month" type="year-month"
:max-date="maxDate"
@cancel="onPickerCancle" @cancel="onPickerCancle"
@confirm="onPickerConfirm" @confirm="onPickerConfirm"
> >
...@@ -38,6 +39,7 @@ export default { ...@@ -38,6 +39,7 @@ export default {
name: "CashOutRecord", name: "CashOutRecord",
data() { data() {
return { return {
maxDate:'',
show: false, show: false,
options: [{ text: "2021年3月", value: 0 }], options: [{ text: "2021年3月", value: 0 }],
selected: "", selected: "",
...@@ -46,9 +48,10 @@ export default { ...@@ -46,9 +48,10 @@ export default {
}; };
}, },
mounted() { mounted() {
this.maxDate = new Date(),
this.selected = `${this.currentDate.getFullYear()}${this.currentDate.getMonth() + this.selected = `${this.currentDate.getFullYear()}${this.currentDate.getMonth() +
1}月`; 1}月`;
const time = this.currentDate.toLocaleDateString().replaceAll("/", "-"); const time = this.currentDate.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time); this.getRecordList(time);
}, },
methods: { methods: {
...@@ -57,7 +60,7 @@ export default { ...@@ -57,7 +60,7 @@ export default {
}, },
onDownLoad() { onDownLoad() {
console.log("下拉加载"); console.log("下拉加载");
const time = this.currentDate.toLocaleDateString().replaceAll("/", "-"); const time = this.currentDate.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time); this.getRecordList(time);
}, },
onPickerCancle() { onPickerCancle() {
...@@ -66,7 +69,7 @@ export default { ...@@ -66,7 +69,7 @@ export default {
onPickerConfirm(val) { onPickerConfirm(val) {
this.selected = `${val.getFullYear()}${val.getMonth() + 1}月`; this.selected = `${val.getFullYear()}${val.getMonth() + 1}月`;
this.show = false; this.show = false;
const time = val.toLocaleDateString().replaceAll("/", "-"); const time = val.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time); this.getRecordList(time);
}, },
getRecordList(yearMonth) { getRecordList(yearMonth) {
......
...@@ -100,31 +100,25 @@ export default { ...@@ -100,31 +100,25 @@ export default {
overflow: hidden; overflow: hidden;
padding: 15px; padding: 15px;
box-sizing: border-box; box-sizing: border-box;
p {
margin: 0;
}
.content { .content {
position: relative; display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 345px; width: 345px;
height: 100%; height: 100%;
text-align: center; text-align: center;
background-color: #ffffff; background-color: #ffffff;
.currentprofitlabel { .currentprofitlabel {
position: absolute;
top: 136px;
width: 100%; width: 100%;
font-size: 18px; font-size: 18px;
color: #333333; color: #333333;
} }
.currentprofit { .currentprofit {
position: absolute;
width: 100%; width: 100%;
top: 178px; top: 178px;
} }
.balance-img { .balance-img {
position: absolute;
top: 72px;
left: 157px;
width: 34px; width: 34px;
height: 34px; height: 34px;
} }
...@@ -140,12 +134,11 @@ export default { ...@@ -140,12 +134,11 @@ export default {
} }
.bottom-box { .bottom-box {
position: absolute;
top: 263px;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
align-items: center; align-items: center;
width: 100%; width: 100%;
margin: 20px 0;
font-size: 14px; font-size: 14px;
color: #666666; color: #666666;
img { img {
...@@ -171,10 +164,6 @@ export default { ...@@ -171,10 +164,6 @@ export default {
} }
.cash-out-btn { .cash-out-btn {
position: absolute;
bottom: 63px;
left: 50%;
transform: translateX(-50%);
.van-button { .van-button {
width: 160px; width: 160px;
} }
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
<p class="content-tip">请输入您的推荐人邀请码</p> <p class="content-tip">请输入您的推荐人邀请码</p>
<van-field <van-field
v-model="fillCode" v-model="fillCode"
type="number" maxlength="6"
class="validCodeInput" class="validCodeInput"
placeholder="请输入" placeholder="请输入"
/> />
...@@ -105,6 +105,14 @@ export default { ...@@ -105,6 +105,14 @@ export default {
this.inviteeCodeDialog = false; this.inviteeCodeDialog = false;
}, },
onFillInviteeCode() { onFillInviteeCode() {
if (!this.fillCode) {
this.$toast.fail('请填写推荐人邀请码')
return;
}
if (!/^[A-z|\d]{6}$/.test(this.fillCode)) {
this.$toast.fail('邀请码只支持6位数字+字母的组合')
return;
}
this.inviteeCodeDialog = false; this.inviteeCodeDialog = false;
this.inviteeCode = this.fillCode; this.inviteeCode = this.fillCode;
const params = { const params = {
...@@ -114,7 +122,7 @@ export default { ...@@ -114,7 +122,7 @@ export default {
fillInviteCode(params).then(); fillInviteCode(params).then();
}, },
fillInviterCode() { fillInviterCode() {
if (this.inviteeCode === "未填写") { if (this.inviteeCode === "未填写" || this.inviteeCode == '1') {
this.inviteeCodeDialog = true; this.inviteeCodeDialog = true;
this.fillCode = ""; this.fillCode = "";
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment