feat: 注册
This commit is contained in:
@@ -23,7 +23,10 @@
|
||||
<view class="right_" v-if="performanceData && performanceData.seniorId">
|
||||
<view>上级ID:{{ performanceData.seniorId || 0 }}</view>
|
||||
</view>
|
||||
<!-- 绑定 -->
|
||||
<view v-else @click="bindHowShow = true;"> 点击绑定</view>
|
||||
</view>
|
||||
|
||||
<view class="my_team_content_warp">
|
||||
<!-- 我的团队 -->
|
||||
<view class="card_comm my_team" @click="jumpMyTeam">
|
||||
@@ -172,6 +175,12 @@
|
||||
</view>
|
||||
</view>
|
||||
</up-modal>
|
||||
|
||||
<!-- 绑定 -->
|
||||
<up-modal :show="bindHowShow" :showConfirmButton="true" :showCancelButton="true" @confirm="onBindConfirm"
|
||||
@cancel="bindHowShow = false" class="bind-show-model">
|
||||
<up-input placeholder="输入邀请码" border="surround" v-model="bindValue"></up-input>
|
||||
</up-modal>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@@ -181,7 +190,7 @@ import { getPerformance, getAcctCategory, getRewardSummaryRecord, getRewardSumma
|
||||
import { formatDate } from '@/utils/index.js';
|
||||
import { BALANCE_TYPE, getValue } from '@/utils/enumUtils.js';
|
||||
import { getStorageFun, USER_DATA } from '@/utils/auth.js';
|
||||
import { getUserInfo } from '@/api/auth.js'
|
||||
import { getUserInfo, bindInvitationCode } from '@/api/auth.js'
|
||||
|
||||
export default {
|
||||
computed: {
|
||||
@@ -207,6 +216,8 @@ export default {
|
||||
openTeamShow: false,// 团队业绩的提示
|
||||
openTcShow: false,// 提成统计
|
||||
userData: {},// 当前登录对象
|
||||
bindHowShow: false,
|
||||
bindValue: '',
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
@@ -217,6 +228,21 @@ export default {
|
||||
methods: {
|
||||
formatDate,
|
||||
getValue,
|
||||
onBindConfirm() {
|
||||
console.log(this.bindValue, '/user/bindInvitationCode');
|
||||
bindInvitationCode({
|
||||
inviteCode: this.bindValue,
|
||||
}).then(res => {
|
||||
if (res && res.bizcode === 100) {
|
||||
this.$refs.uToastRef.show({
|
||||
type: 'success',
|
||||
message: "绑定成功",
|
||||
});
|
||||
this.bindHowShow = false;
|
||||
this.getUserInfo();
|
||||
}
|
||||
})
|
||||
},
|
||||
jumpMine() {
|
||||
uni.switchTab({// 首页
|
||||
url: '/pages/mine/mine',
|
||||
|
||||
Reference in New Issue
Block a user