商家认证功能调整

master
钟海欣 5 years ago
parent 702dce68f0
commit 1c61cebf7d
  1. 7
      src/api/coin.js
  2. 3
      src/locales/lang/exchange.en.js
  3. 3
      src/locales/lang/exchange.zh-CN.js
  4. 3
      src/locales/lang/exchange.zh-HK.js
  5. 39
      src/pages/exchange.vue
  6. 18
      src/pages/index.vue
  7. 24
      src/views/personal/profile.vue

@ -68,3 +68,10 @@ export function getCancelApply() {
method: 'post',
});
}
// 查询用户市商状态
export function cheackApply() {
return request({
url: c2cApi + '/marketUser/getStatusByUserId',
method: 'get',
});
}

@ -148,6 +148,9 @@ export default {
success: 'Cancellation Successful',
deled: 'Cancelled',
yue: 'Insufficient wallet balance',
market: 'The merchant has been certified.',
marketcancel: 'Merchant cancellation.',
bemarket: 'Business application successful!',
},
},
};

@ -139,6 +139,9 @@ export default {
success: '取消成功',
deled: '已取消',
yue: '钱包余额不足',
market: '商家已认证',
marketcancel: '商家取消中',
bemarket: '申请商家成功!',
},
},
};

@ -139,6 +139,9 @@ export default {
success: '取消成功',
deled: '已取消',
yue: '錢包余額不足',
market: '商家已認證',
marketcancel: '商家取消中',
bemarket: '申請商家成功!',
},
},
};

@ -25,8 +25,19 @@
</ul>
<!-- 申请商家 -->
<div class="merchant">
<span class="apply" @click="handleSure()">{{
$t('exchangeotc.merchant.name')
<!-- 商家已认证 -->
<span v-if="applyStatus == 'MARKET'">{{
$t('exchangeotc.merchant.market')
}}</span>
<span
v-else-if="(applyStatus = 'null' || applyStatus == 'NOTMARKET')"
class="apply"
@click="handleSure()"
>{{ $t('exchangeotc.merchant.name') }}</span
>
<!-- 商家取消中 -->
<span v-else-if="applyStatus == 'CANCELING'">{{
$t('exchangeotc.merchant.marketcancel')
}}</span>
</div>
<!-- 判断点击的时候什么 切换对应的子组件 -->
@ -39,7 +50,6 @@
<ExchangeTableSell v-if="hackReset"></ExchangeTableSell>
</div>
</main>
<Footer></Footer>
</div>
</template>
@ -49,7 +59,7 @@ import NavHeader from '@/components/common/header';
import Footer from '@/components/common/footer';
import ExchangeTableBi from '@/components/exchange/exchange-tabgle-bi';
import ExchangeTableSell from '@/components/exchange/exchange-table-sell';
import {getMarketApplyl} from '@/api/coin';
import {getMarketApplyl, cheackApply} from '@/api/coin';
export default {
name: 'exchange',
components: {
@ -64,8 +74,12 @@ export default {
hackResetBuy: true,
showCommentInput: true, //
ifCommentInput: false, //
applyStatus: '',
};
},
created() {
this.getcheckApply(); //
},
methods: {
// table
hangdelClickShow() {
@ -91,7 +105,21 @@ export default {
this.checked = false;
getMarketApplyl().then(res => {
if (res.data.code === 200) {
this.$message.success(res.data.msg);
//
this.$message.success(this.$t('exchangeotc.merchant.bemarket'));
setInterval(() => {
location.reload(); //
}, 1000);
} else {
this.$message.error(res.data.msg);
}
});
},
//
getcheckApply() {
cheackApply().then(res => {
if (res.data.code === 200) {
this.applyStatus = res.data.data;
} else {
this.$message.error(res.data.msg);
}
@ -157,6 +185,7 @@ export default {
position: relative;
top: -55px;
left: -38px;
color: #e8494a;
.apply {
color: #fff;
display: inline-block;

@ -458,17 +458,17 @@ export default {
if (res.data.code === 200) {
this.rangLoading = false;
// ,()
var rightPbj = {
currencyPair: 'HFH-USDT',
amount: '0.15',
highest: '0.15',
lowest: '0.15',
total: '0',
percent: '0',
};
// var rightPbj = {
// currencyPair: 'HFH-USDT',
// amount: '0.15',
// highest: '0.15',
// lowest: '0.15',
// total: '0',
// percent: '0',
// };
this.rangeList = res.data.data;
this.rangeList.push(rightPbj);
// this.rangeList.push(rightPbj);
// console.log(this.rangeList);
}
});

@ -4,7 +4,11 @@
<div class="majorTitleBox majorBoxStyle major-fiexd">
<p class="majorTitle">{{ $t('personal.profile.basicInfo.title') }}</p>
<!-- 申请取消商家 -->
<div class="major-te-two" @click="getMerchant()">
<div
class="major-te-two"
v-if="applyStatus == 'MARKET'"
@click="getMerchant()"
>
<span>{{ $t('exchangeotc.merchant.data_del') }}</span>
</div>
</div>
@ -104,7 +108,7 @@
<script>
import Cookie from '@/common/cookie';
import {rename, getUserData, getLoginLog} from '@/api/user';
import {getCancelApply} from '@/api/coin';
import {getCancelApply, cheackApply} from '@/api/coin';
export default {
name: 'profile',
data() {
@ -115,6 +119,7 @@ export default {
is_dialog: false,
// dialogMerchant: false,
id: '',
applyStatus: '',
};
},
created: function() {
@ -122,7 +127,7 @@ export default {
// console.log(userData)
this.userName = userData.nickName;
this.id = userData.id;
this.getcheckApply(); //
//
getLoginLog({
userId: this.id,
@ -142,6 +147,16 @@ export default {
},
},
methods: {
//
getcheckApply() {
cheackApply().then(res => {
if (res.data.code === 200) {
this.applyStatus = res.data.data;
} else {
this.$message.error(res.data.msg);
}
});
},
//
getMerchant() {
// this.$confirm(
@ -160,6 +175,9 @@ export default {
type: 'success',
message: this.$t('exchangeotc.merchant.success'),
});
setInterval(() => {
location.reload(); //
}, 1000);
} else {
this.$message.error(res.data.msg);
}

Loading…
Cancel
Save