|
|
@@ -15,7 +15,7 @@
|
|
|
</div>
|
|
|
<div class="icon-style">
|
|
|
<!--<button class="btn btn-xs btn-danger btn-nav" v-if="!isFocus"><span class="watch">关注</span></button>-->
|
|
|
- <span v-if="!isFocus"><el-button type="text" @click="dialogVisible = true,focus(storeInfo.id, storeInfo.storeName)" class="btn btn-xs btn-danger btn-nav"><span class="watch">关注</span></el-button></span>
|
|
|
+ <span v-if="!isFocus"><el-button type="text" @click="focus(storeInfo.id, storeInfo.storeName)" class="btn btn-xs btn-danger btn-nav"><span class="watch">关注</span></el-button></span>
|
|
|
<span v-if="isFocus" ><button class="btn btn-xs btn-default btn-nav" style="width:50px"><span>已关注</span></button></span>
|
|
|
<span v-if="storeInfo.type == 'ORIGINAL_FACTORY'"> <img src="/images/store/icon/icon-factory.png"/></span>
|
|
|
<span v-else-if="storeInfo.type == 'AGENCY'"> <img src="/images/store/icon/icon-agent.png"/></span>
|
|
|
@@ -27,13 +27,13 @@
|
|
|
</div>
|
|
|
<div style="background: #FFFFFF;" v-if="isOpen">
|
|
|
<ul class = "shop-contact list-unstyled" style="padding: 15px 0; margin-bottom: 0; border-top: #e8e8e8 1px solid; margin-top: 20px;">
|
|
|
- <li ng-if="storeInfo.enterprise.enTel.length > 0">
|
|
|
+ <li v-if="storeInfo.enterprise.enTel.length > 0">
|
|
|
<span>电话:</span><span v-text="storeInfo.enterprise.enTel"></span>
|
|
|
</li>
|
|
|
- <li ng-if="storeInfo.enterprise.enFax.length > 0">
|
|
|
+ <li v-if="storeInfo.enterprise.enFax.length > 0">
|
|
|
<span>传真:</span><span v-text="storeInfo.enterprise.enFax"></span>
|
|
|
</li>
|
|
|
- <li ng-if="storeInfo.enterprise.enAddress.length > 0">
|
|
|
+ <li v-if="storeInfo.enterprise.enAddress.length > 0">
|
|
|
<span>地址:</span><span v-text="storeInfo.enterprise.enAddress"></span>
|
|
|
</li>
|
|
|
<li class="text-right">
|
|
|
@@ -59,7 +59,7 @@
|
|
|
<div class="focus modal-body">
|
|
|
<button type="button" @click="dialogVisible = false" class="btn" style="margin-left:25px;">关 闭</button>
|
|
|
<button type="button" @click="dialogVisible = false" class="focus-btn btn btn btn-info" style="margin-left:35px;">
|
|
|
- <a href="/user#/browsingHistory" target="_blank">查看我的店铺关注</a>
|
|
|
+ <a href="/user#/storeFocus" target="_blank">查看我的店铺关注</a>
|
|
|
</button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
@@ -83,6 +83,9 @@ export default {
|
|
|
storeInfo () {
|
|
|
return this.$store.state.shop.storeInfo.store.data
|
|
|
},
|
|
|
+ user () {
|
|
|
+ return this.$store.state.option.user
|
|
|
+ },
|
|
|
isFocus () {
|
|
|
const foucusList = this.$store.state.shop.storeInfo.focusList.data
|
|
|
return foucusList === 'true'
|
|
|
@@ -104,8 +107,17 @@ export default {
|
|
|
this.isOpen = true
|
|
|
},
|
|
|
focus (id, name) {
|
|
|
- this.$store.dispatch('shop/StoreFocus', {storeName: name, storeid: id})
|
|
|
- this.isFocus = true
|
|
|
+ if (!this.user.logged) {
|
|
|
+ this.$http.get('/login/page').then(response => {
|
|
|
+ if (response.data) {
|
|
|
+ this.$router.push('/auth/login')
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.dialogVisible = true
|
|
|
+ this.$store.dispatch('shop/StoreFocus', {storeName: name, storeid: id})
|
|
|
+ this.isFocus = true
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|