|
|
|
@ -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; |
|
|
|
|