|
|
@@ -1,5 +1,9 @@
|
|
|
<template>
|
|
|
- <div class="mobile-fix-content mobile-center">
|
|
|
+ <div class="mobile-fix-content mobile-center" v-if="!showInfo">
|
|
|
+ <div class="block-wrap seek-operation">
|
|
|
+ <div class="block-wrap_moreinfo">抱歉,您的账户未绑定企业,暂无卖家权限</div>
|
|
|
+ <div class="block-wrap_morelist" @click="setShowApplyRecord(true)">查看申请记录</div>
|
|
|
+ </div>
|
|
|
<div class="block-wrap seek-operation">
|
|
|
<p><i></i>所属企业已开店</p>
|
|
|
<div class="search-wrap">
|
|
|
@@ -19,23 +23,68 @@
|
|
|
</div>
|
|
|
<div class="operation" v-show="showSearchResultStatus !== 0">
|
|
|
<template v-if="showSearchResultStatus === 1">
|
|
|
- <a @click="bindEnterprise">申请绑定</a>
|
|
|
+ <a @click="bindEnterprise">提交申请</a>
|
|
|
<p>管理员审核通过后成功绑定</p>
|
|
|
</template>
|
|
|
<template v-if="showSearchResultStatus === 2">
|
|
|
<a>开设新店铺</a>
|
|
|
</template>
|
|
|
</div>
|
|
|
+ <div class="block-wrap seek-operation" v-if="!showInfo">
|
|
|
+ <p><i></i>所属企业未开店</p>
|
|
|
+ <div class="clearfix block-storeinfo">
|
|
|
+ <div class="pull-left">
|
|
|
+ <img src="/images/material/house.png"/>
|
|
|
+ </div>
|
|
|
+ <div class="pull-right">
|
|
|
+ <div class="pull-left-info">请点击下方按钮开设新的店铺</div>
|
|
|
+ <nuxt-link class="pull-left-btn" tag="div" to="/mobile/store">开设新店铺</nuxt-link>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
<remind-box :title="remindText" :timeoutCount="remindTimerCount"></remind-box>
|
|
|
+ <div class="mobile-modal" v-show="showApplyRecord">
|
|
|
+ <div class="mobile-modal-box">
|
|
|
+ <div class="mobile-modal-header">申请记录<i class="icon-guanbi iconfont" @click="setShowApplyRecord(false)"></i></div>
|
|
|
+ <div class="mobile-modal-headerjilu" ref="mobileModalBox">
|
|
|
+ <div>
|
|
|
+ <div class="record-wrap">
|
|
|
+ <div class="record-title">
|
|
|
+ <span>企业名称</span>
|
|
|
+ <span>管理员</span>
|
|
|
+ <span>申请时间</span>
|
|
|
+ <span>状态</span>
|
|
|
+ </div>
|
|
|
+ <ul>
|
|
|
+ <li v-for="item in applyList">
|
|
|
+ <span>{{item.enName}}</span>
|
|
|
+ <span>{{item.adminName}}</span>
|
|
|
+ <span>{{item.date | date}}</span>
|
|
|
+ <span :class="{'green-text': item.status === 311, 'red-text': item.status === 317}">{{item.status | status}}</span>
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
import { RemindBox } from '~components/mobile/common'
|
|
|
export default {
|
|
|
layout: 'mobile',
|
|
|
+ props: {
|
|
|
+ showInfo: {
|
|
|
+ default: true
|
|
|
+ }
|
|
|
+ },
|
|
|
middleware: 'authenticated',
|
|
|
data () {
|
|
|
return {
|
|
|
+ applyList: [],
|
|
|
+ showApplyRecord: false,
|
|
|
keyword: '',
|
|
|
enInfo: {},
|
|
|
remindText: '',
|
|
|
@@ -47,7 +96,35 @@
|
|
|
components: {
|
|
|
RemindBox
|
|
|
},
|
|
|
+ mounted() {
|
|
|
+ let keyword = this.$route.query.name || ''
|
|
|
+ let businessCode = this.$route.query.businessCode || ''
|
|
|
+ let showStatus = parseInt(this.$route.query.showStatus) || ''
|
|
|
+ this.keyword = keyword
|
|
|
+ this.enInfo.name = keyword
|
|
|
+ this.enInfo.businessCode = businessCode
|
|
|
+ this.showSearchResultStatus = showStatus
|
|
|
+ this.$nextTick(() => {
|
|
|
+ // document.addEventListener('click', this.checkCurrencySelect)
|
|
|
+ this._initscroll()
|
|
|
+ })
|
|
|
+ },
|
|
|
methods: {
|
|
|
+ setShowApplyRecord: function (flag) {
|
|
|
+ if (flag) {
|
|
|
+ this.$http.get('/basic/enterprise/findApplyInfo', {params: {phone: this.user.data.userTel}})
|
|
|
+ .then(responses => {
|
|
|
+ this.applyList = responses.data
|
|
|
+ this.showApplyRecord = flag
|
|
|
+ this._initscroll()
|
|
|
+ }, err => {
|
|
|
+ console.log(err)
|
|
|
+ this.$message.error('系统错误')
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.showApplyRecord = flag
|
|
|
+ }
|
|
|
+ },
|
|
|
onSearchEnterprise: function () {
|
|
|
if (this.keyword) {
|
|
|
this.$http.get('/basic/enterprise/findByName/' + encodeURIComponent(this.keyword)).then(response => {
|
|
|
@@ -83,6 +160,20 @@
|
|
|
this.remindText = str
|
|
|
this.remindTimerCount++
|
|
|
}
|
|
|
+ },
|
|
|
+ filters: {
|
|
|
+ status: function (status) {
|
|
|
+ switch (status) {
|
|
|
+ case 311:
|
|
|
+ return '待审核'
|
|
|
+ case 316:
|
|
|
+ return '已通过'
|
|
|
+ case 317:
|
|
|
+ return '未通过'
|
|
|
+ default:
|
|
|
+ break
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
@@ -171,5 +262,116 @@
|
|
|
color: rgba(51, 51, 51, .89);
|
|
|
}
|
|
|
}
|
|
|
+ .block-storeinfo {
|
|
|
+ margin: 0.48rem 0.2rem 0;
|
|
|
+ padding-bottom: 0.2rem;
|
|
|
+ img {
|
|
|
+ width: 2.18rem;
|
|
|
+ height: 1.73rem;
|
|
|
+ }
|
|
|
+ .pull-left-info {
|
|
|
+ font-size: 0.28rem;
|
|
|
+ color: #3f84f6;
|
|
|
+ }
|
|
|
+ .pull-left-btn {
|
|
|
+ color: #fff;
|
|
|
+ font-size: 0.32rem;
|
|
|
+ width: 3.1rem;
|
|
|
+ height: 0.58rem;
|
|
|
+ text-align: center;
|
|
|
+ line-height: 0.58rem;
|
|
|
+ border-radius: 5px;
|
|
|
+ background: #3f84f6;
|
|
|
+ margin-top: 0.3rem;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .block-wrap_moreinfo {
|
|
|
+ font-size: 0.34rem;
|
|
|
+ color: #333;
|
|
|
+ text-align: center;
|
|
|
+ padding-top: 0.4rem;
|
|
|
+ margin-bottom: 0.2rem;
|
|
|
+ }
|
|
|
+ .block-wrap_morelist {
|
|
|
+ color: #3f84f6;
|
|
|
+ font-size: 0.32rem;
|
|
|
+ border: 0.01rem solid #3f84f6;
|
|
|
+ text-align: center;
|
|
|
+ width: 3.1rem;
|
|
|
+ height: 0.58rem;
|
|
|
+ line-height: 0.58rem;
|
|
|
+ border-radius: 5px;
|
|
|
+ margin: 0 auto;
|
|
|
+ }
|
|
|
+ .mobile-modal-box {
|
|
|
+ top: 1.66rem;
|
|
|
+ left: 3%;
|
|
|
+ right: 3%;
|
|
|
+ width: 7rem;
|
|
|
+ bottom: 1.66rem;
|
|
|
+ margin: 0 auto;
|
|
|
+ }
|
|
|
+ .mobile-modal-headerjilu {
|
|
|
+ background: #f3f3f3;
|
|
|
+ padding: .18rem 0;
|
|
|
+ width: 100%;
|
|
|
+ overflow: hidden;
|
|
|
+ height: 90%;
|
|
|
+ .record-wrap {
|
|
|
+ padding: 0 .18rem;
|
|
|
+ .record-title {
|
|
|
+ height: 28px;
|
|
|
+ line-height: 28px;
|
|
|
+ background: #8eb0f5;
|
|
|
+ border: 1px solid #e8e8e8;
|
|
|
+ color: #fff;
|
|
|
+ }
|
|
|
+ ul {
|
|
|
+ max-height: 150px;
|
|
|
+ overflow-y: auto;
|
|
|
+ overflow-x: hidden;
|
|
|
+ li {
|
|
|
+ border-bottom: 1px solid #e8e8e8;
|
|
|
+ height: 30px;
|
|
|
+ &:nth-child(even) {
|
|
|
+ background: #edf2fd;
|
|
|
+ }
|
|
|
+ &:nth-child(odd) {
|
|
|
+ background: #f7f9fe;
|
|
|
+ }
|
|
|
+ span {
|
|
|
+ line-height: 26px;
|
|
|
+ position: relative;
|
|
|
+ top: 2px;
|
|
|
+ &.green-text {
|
|
|
+ color: #379b1d;
|
|
|
+ }
|
|
|
+ &.red-text {
|
|
|
+ color: #f51c24;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ span {
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ white-space: nowrap;
|
|
|
+ display: inline-block;
|
|
|
+ text-align: center;
|
|
|
+ &:nth-child(1) {
|
|
|
+ width: 2.6rem;
|
|
|
+ }
|
|
|
+ &:nth-child(2) {
|
|
|
+ width: 1.1rem;
|
|
|
+ }
|
|
|
+ &:nth-child(3) {
|
|
|
+ width: 1.84rem;
|
|
|
+ }
|
|
|
+ &:nth-child(4) {
|
|
|
+ width: 1.04rem;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
</style>
|