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 {
this.currentTitle = val.meta.title;
}
},
created() {
mounted() {
console.log("和App开始交互");
this.$bridgeToAppFun
.getAuthToken()
......
......@@ -81,6 +81,7 @@ export default {
position: absolute;
top: 0;
right: 0;
color: #c3c3c3;
}
.content-submit-btn {
position: absolute;
......
<template>
<div class="cash-out-record">
<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" />
</div>
<div class="record-list">
......@@ -18,6 +18,7 @@
<van-datetime-picker
v-model="currentDate"
type="year-month"
:max-date="maxDate"
@cancel="onPickerCancle"
@confirm="onPickerConfirm"
>
......@@ -38,6 +39,7 @@ export default {
name: "CashOutRecord",
data() {
return {
maxDate:'',
show: false,
options: [{ text: "2021年3月", value: 0 }],
selected: "",
......@@ -46,9 +48,10 @@ export default {
};
},
mounted() {
this.maxDate = new Date(),
this.selected = `${this.currentDate.getFullYear()}${this.currentDate.getMonth() +
1}月`;
const time = this.currentDate.toLocaleDateString().replaceAll("/", "-");
const time = this.currentDate.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time);
},
methods: {
......@@ -57,7 +60,7 @@ export default {
},
onDownLoad() {
console.log("下拉加载");
const time = this.currentDate.toLocaleDateString().replaceAll("/", "-");
const time = this.currentDate.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time);
},
onPickerCancle() {
......@@ -66,7 +69,7 @@ export default {
onPickerConfirm(val) {
this.selected = `${val.getFullYear()}${val.getMonth() + 1}月`;
this.show = false;
const time = val.toLocaleDateString().replaceAll("/", "-");
const time = val.toLocaleDateString().replace(/\//g, "-");
this.getRecordList(time);
},
getRecordList(yearMonth) {
......
......@@ -100,31 +100,25 @@ export default {
overflow: hidden;
padding: 15px;
box-sizing: border-box;
p {
margin: 0;
}
.content {
position: relative;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 345px;
height: 100%;
text-align: center;
background-color: #ffffff;
.currentprofitlabel {
position: absolute;
top: 136px;
width: 100%;
font-size: 18px;
color: #333333;
}
.currentprofit {
position: absolute;
width: 100%;
top: 178px;
}
.balance-img {
position: absolute;
top: 72px;
left: 157px;
width: 34px;
height: 34px;
}
......@@ -140,12 +134,11 @@ export default {
}
.bottom-box {
position: absolute;
top: 263px;
display: flex;
justify-content: space-around;
align-items: center;
width: 100%;
margin: 20px 0;
font-size: 14px;
color: #666666;
img {
......@@ -171,10 +164,6 @@ export default {
}
.cash-out-btn {
position: absolute;
bottom: 63px;
left: 50%;
transform: translateX(-50%);
.van-button {
width: 160px;
}
......
......@@ -36,7 +36,7 @@
<p class="content-tip">请输入您的推荐人邀请码</p>
<van-field
v-model="fillCode"
type="number"
maxlength="6"
class="validCodeInput"
placeholder="请输入"
/>
......@@ -105,6 +105,14 @@ export default {
this.inviteeCodeDialog = false;
},
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.inviteeCode = this.fillCode;
const params = {
......@@ -114,7 +122,7 @@ export default {
fillInviteCode(params).then();
},
fillInviterCode() {
if (this.inviteeCode === "未填写") {
if (this.inviteeCode === "未填写" || this.inviteeCode == '1') {
this.inviteeCodeDialog = true;
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