123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200 |
- <template>
- <view class="page">
- <view class="top">
- <view class="wd">
- <image :src="user == '' ? '../../static/ls.jpg' : user.avatarUrl" class="head"></image>
- <view class="xs" @click="navigate('/pages/user/info')">
- <view class="nickName" v-if="user == ''">登录 / 注册</view>
- <view class="nickName" v-else>
- <text>{{ user.nickName }}</text>
- </view>
- <view class="nh">{{ user == '' ? '你还未登陆' : ' 您好,欢迎来到谢通门智慧旅游' }}</view>
- <view class="clear"></view>
- </view>
- </view>
- <view class="icon" @click="navigate('/pages/user/info')" v-if="user != ''"></view>
- <image src="../../static/my.png" mode="aspectFill"></image>
- </view>
- <view class="main">
- <view class="list flex">
- <view class="item f" @click="navigate('/pages/order/my')" style="padding-right: 0px;">
- <view style="border-right: 1px solid #f1f1f1;">
- <text class="icon ic" style="background-color: #2196F3;"></text>
- <view class="fon">我的预约</view>
- </view>
- </view>
- <view class="item f" @click="navigate('/pages/shop/list')">
- <text class="icon ic" style="background-color:#9727ec"></text>
- <view class="fon">商家中心</view>
- </view>
- </view>
- <view class="list" style="margin-top: 13px;">
- <view class="item hr" @click="call()">
- <text class="icon ic" style="background-color:#276fec"></text>
- <text>求助电话</text>
- <text class="icon arrow"></text>
- </view>
- <view class="item hr" @click="navigate('/pages/other/feedback')">
- <text class="icon ic" style="background-color:#FF554B"></text>
- <text>投诉建议</text>
- <text class="icon arrow"></text>
- </view>
- <view class="item hr">
- <button open-type="share" hover-class="none" class="button">
- <text class="icon ic" style="background-color:#34cf43"></text>
- <text>分享朋友</text>
- <text class="icon arrow"></text>
- </button>
- </view>
- <view class="item" @click="navigate('/pages/other/about')">
- <text class="icon ic" style="background-color:#343f61"></text>
- <text>关于我们</text>
- <text class="icon arrow"></text>
- </view>
- </view>
- </view>
- <help ref="help"></help>
- </view>
- </template>
- <script>
- import help from '../../components/help.vue';
- export default {
- components: {
- help
- },
- data() {
- return {
- ip: this.$http.urls.ip,
- user: this.$getUser(),
- aboutUs: { showPictures: [] }
- };
- },
- onLoad() {
- this.aboutUs = uni.getStorageSync('aboutUs');
- },
- onShow() {
- this.user = this.$getUser();
- },
- methods: {
- navigate(url) {
- if (this.$hasLogin()) {
- uni.navigateTo({ url: url });
- } else {
- uni.navigateTo({ url: '/pages/user/login' });
- }
- },
- //拨打求助电话
- call() {
- this.$refs.help.init();
- }
- },
- onShareAppMessage: function(res) {
- return {
- title: '谢通门智慧旅游',
- path: '/pages/index/index2',
- imageUrl: '../../static/fx.jpg',
- success: res => {},
- fail: res => {}
- };
- }
- };
- </script>
- <style lang="scss">
- .top {
- position: relative;
- height: 270px;
- color: white;
- overflow: hidden;
- .wd {
- position: absolute;
- top: 80px;
- left: 20px;
- z-index: 11;
- .head {
- width: 75px;
- height: 75px;
- border-radius: 50%;
- }
- .xs {
- margin-left: 90px;
- font-weight: bold;
- margin-top: 10px;
- .nickName {
- width: 100%;
- font-size: 14px;
- margin-top: 20px;
- position: relative;
- }
- .nh {
- font-size: 12px;
- font-weight: normal;
- margin-top: 5px;
- }
- }
- }
- .icon {
- position: absolute;
- right: 14px;
- top: 93px;
- font-size: 25px;
- z-index: 1;
- }
- image {
- width: 100%;
- height: 270px;
- position: absolute;
- }
- }
- .main {
- padding: 15px 15px 50px 15px;
- width: 100%;
- overflow: hidden;
- position: absolute;
- margin-top: -100px;
- .list {
- box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
- width: 100%;
- background-color: white;
- border-radius: 5px;
- overflow: hidden;
- .fon {
- padding-top: 12px;
- }
- .item {
- padding: 16px;
- background-color: white;
- font-size: 16px;
- color: #222222;
- .ic {
- font-size: 20px;
- background-color: red;
- text-align: center;
- padding: 5px;
- border-radius: 5px;
- margin-right: 9px;
- color: white;
- }
- .arrow {
- font-size: 20px;
- }
- }
- }
- }
- .button {
- text-align: left;
- background-color: white;
- color: #2e2e2e !important;
- font-size: 16px;
- padding-left: 0px;
- padding-right: 2px;
- line-height: 20px;
- overflow: initial;
- &:hover {
- background-color: white;
- outline: none;
- }
- }
- </style>
|