|
@@ -119,10 +119,27 @@
|
|
</view>
|
|
</view>
|
|
<block v-if="fetch.user.id > 0">
|
|
<block v-if="fetch.user.id > 0">
|
|
<view class="ucenter-line"></view>
|
|
<view class="ucenter-line"></view>
|
|
- <view hover-class="gui-tap" @click="quit">
|
|
+ <view hover-class="gui-tap" @click="open">
|
|
<text class="gui-text-center gui-block-text gui-icons logoff gui-color-gray"> 退出登录</text>
|
|
<text class="gui-text-center gui-block-text gui-icons logoff gui-color-gray"> 退出登录</text>
|
|
</view>
|
|
</view>
|
|
- </block>
|
|
+ </block>
|
|
|
|
+
|
|
|
|
+ <gui-modal ref="quit"
|
|
|
|
+ title="确认退出">
|
|
|
|
+ <view slot="content" class="gui-padding gui-bg-gray">
|
|
|
|
+ <text class="gui-block-text gui-text-center gui-text gui-color-gray"
|
|
|
|
+ style="line-height:100rpx; padding:10rpx;">您确定要这样退出吗?</text>
|
|
|
|
+ </view>
|
|
|
|
+ <!-- 利用 flex 布局 可以放置多个自定义按钮哦 -->
|
|
|
|
+ <view slot="btns" class="gui-flex gui-rows gui-space-between">
|
|
|
|
+ <view class="modal-btns gui-flex1" style="margin-right:80rpx;">
|
|
|
|
+ <text class="modal-btns gui-color-gray" @tap="close">取消</text>
|
|
|
|
+ </view>
|
|
|
|
+ <view class="modal-btns gui-flex1" style="margin-left:80rpx;">
|
|
|
|
+ <text class="modal-btns gui-color-blue" @tap="quit">确认</text>
|
|
|
|
+ </view>
|
|
|
|
+ </view>
|
|
|
|
+ </gui-modal>
|
|
</view>
|
|
</view>
|
|
<foot ref="foot" slot="gFooter" :value="foot_value"></foot>
|
|
<foot ref="foot" slot="gFooter" :value="foot_value"></foot>
|
|
</gui-page>
|
|
</gui-page>
|
|
@@ -172,12 +189,19 @@ export default {
|
|
},
|
|
},
|
|
|
|
|
|
quit : function() {
|
|
quit : function() {
|
|
|
|
+ this.close();
|
|
this.Dever.setToken('');
|
|
this.Dever.setToken('');
|
|
var self = this;
|
|
var self = this;
|
|
this.Dever.alert('已退出', 'none', function() {
|
|
this.Dever.alert('已退出', 'none', function() {
|
|
self.Dever.location('index/my');
|
|
self.Dever.location('index/my');
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ open : function() {
|
|
|
|
+ this.$refs.quit.open();
|
|
|
|
+ },
|
|
|
|
+ close : function() {
|
|
|
|
+ this.$refs.quit.close();
|
|
|
|
+ },
|
|
goView : function(key, name) {
|
|
goView : function(key, name) {
|
|
var path = this.Dever.api_host + 'main/?l=page&key=' + key;
|
|
var path = this.Dever.api_host + 'main/?l=page&key=' + key;
|
|
this.Dever.location(path, 'webview', name);
|
|
this.Dever.location(path, 'webview', name);
|
|
@@ -193,5 +217,6 @@ export default {
|
|
.ucenter-face-image{width:100rpx; height:100rpx;}
|
|
.ucenter-face-image{width:100rpx; height:100rpx;}
|
|
.ucenter-line{height:20rpx; background-color:#F6F7F8; margin:16rpx 0;}
|
|
.ucenter-line{height:20rpx; background-color:#F6F7F8; margin:16rpx 0;}
|
|
.logoff{line-height:88rpx; font-size:28rpx;}
|
|
.logoff{line-height:88rpx; font-size:28rpx;}
|
|
-.gui-list-title-text{line-height:60rpx;}
|
|
+.gui-list-title-text{line-height:60rpx;}
|
|
|
|
+.modal-btns{line-height:88rpx; font-size:26rpx; text-align:center; width:200rpx;}
|
|
</style>
|
|
</style>
|