| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192 |
- <template>
- <view class="content">
- <view class="person">
- <image class="person_touxiang" v-if="touxiang==''" src="../../static/my/touxiang.png"></image>
- <image class="person_touxiang" v-else :src="touxiang"></image>
- <text class="person_name">{{cardName}}
- <text class="person_identity">
- <text v-if="cardIdentity==0">其他</text>
- <text v-if="cardIdentity==1">学生</text>
- <text v-if="cardIdentity==4">教职工</text>
- <text v-if="cardIdentity==5">校友</text>
- </text>
- </text>
- <text class="person_phone">{{cardNum}}</text>
- </view>
- <!-- 第二部分,我的订单 -->
- <view class="my_order">
- <view class="order_title">我的订单</view>
- <view class="order_all" @click="navigateToAll">全部></view>
- <view class="item-list">
- <view class="item-list-one" @click="navigateToDaizhifu">
- <image src="../../static/my/no_zhifu.svg" class="img-btn"></image>
- <text class="list-txt">待支付</text>
- </view>
- <view class="item-list-one" @click="navigateToDairuzhu">
- <image src="../../static/my/dairuzhu.svg" class="img-btn"></image>
- <text class="list-txt">待入住</text>
- </view>
- <view class="item-list-one" @click="navigateToYiruzhu">
- <image src="../../static/my/yiruzhu.svg" class="img-btn"></image>
- <text class="list-txt">已入住</text>
- </view>
- <view class="item-list-one" @click="navigateToYiquxiao">
- <image src="../../static/my/yiquxiao.svg" class="img-btn"></image>
- <text class="list-txt">已取消</text>
- </view>
- </view>
- <view class="item-list">
- <view class="item-list-one" @click="navigateToDaijiezhang">
- <image src="../../static/my/no_pay.svg" class="img-btn"></image>
- <text class="list-txt">待结账</text>
- </view>
- <view class="item-list-one" @click="navigateToYiwancheng">
- <image src="../../static/my/wancheng.svg" class="img-btn"></image>
- <text class="list-txt">已完成</text>
- </view>
- </view>
- </view>
- <!-- 第三部分,我的服务 -->
- <view class="my_help">
- <view class="help_title">我的服务</view>
- <view class="item-list">
- <view class="item-list-one" @click="telphone(phone)">
- <image src="../../static/my/person_phone.svg" class="img-btn"></image>
- <text class="list-txt">人工热线</text>
- </view>
- <view class="item-list-one" @click="navigateToLiucheng">
- <image src="../../static/my/liucheng.png" class="img-btn"></image>
- <text class="list-txt">流程管理</text>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- getuserinfo
- } from '../../utils/api_hotel.js'
- export default {
- data() {
- return {
- phone:'0791-82293574',//客服热线电话
- cardName:'',//用户名
- cardIdentity:'',//身份
- cardNum:'',//卡号
- touxiang:'',
- }
- },
- onLoad() {
- this.getUserInfo()
- },
- mounted() {
- // window.location.href ='https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxa46ef222053a1047&redirect_uri=https://chtech.ncjti.edu.cn/hotel/ihotel-api/ihotel/hotelUser/weixinAuth&response_type=code&scope=snsapi_base&state=pages/index/index#wechat_redirect';
- },
- methods: {
- // 获取用户信息
- getUserInfo() {
- let _self = this
- getuserinfo().then((res) => {
- if (res.success) {
- if (res.data.statu == '1') {
- _self.cardName=res.data.name
- _self.cardIdentity=res.data.identityType
- _self.cardNum=res.data.telPhone
- _self.touxiang=res.data.headImage
- }else {
- alert('您没有权限,请联系客服')
- }
- return;
- } else {
- console.log('获取用户信息失败')
- }
- }).catch((err) => {
- this.$message.error(err.message)
- });
- // this.$axios.get("/hotel/ihotel-api/ihotel/hotelUser/userInfo",
- // {
- // headers:{
- // 'user_token':localStorage.getItem('token')
- // }
- // }).then(res => {
- // res = res.data
- // if (res.success) {
- // if (res.data.statu == '1') {
- // _self.cardName=res.data.name
- // _self.cardIdentity=res.data.identityType
- // _self.cardNum=res.data.telPhone
- // _self.touxiang=res.data.headImage
- // }else {
- // alert('您没有权限,请联系客服')
- // }
- // } else {
- // console.log('获取用户信息失败')
- // }
- // });
- },
- //跳转到全部订单
- navigateToAll(){
- uni.navigateTo({
- url:"../my_orderlist/my_orderlist?Inv=6"
- })
- },
- //跳转到待支付订单
- navigateToDaizhifu(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=1",
- })
- },
- //跳转到待入住订单
- navigateToDairuzhu(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=2"
- })
- },
- //跳转到已入住订单
- navigateToYiruzhu(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=3"
- })
- },
- //跳转到已取消订单
- navigateToYiquxiao(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=0"
- })
- },
- //跳转到待结账订单
- navigateToDaijiezhang(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=4"
- })
- },
- //跳转到已完成订单
- navigateToYiwancheng(){
- uni.navigateTo({
- url: "../my_orderlist/my_orderlist?Inv=5"
- })
- },
- //拨打人工热线
- telphone(phone){
- uni.makePhoneCall({ phoneNumber: phone }) // 传参带入号码即可
- },
- //跳转到流程管理
- navigateToLiucheng(){
- uni.navigateTo({
- // url: "../liuchengTeacher/liu_teach"
- // url: "../liuchengO/liu_other"
- url:"../liuchengManger/liu_manage"
- })
- },
- //跳转到房间报修
- navigateToBaoxiu(){
- window.location.href='https://jtishfw.ncjti.edu.cn/baoxiu/repair-h5/#/'
- }
- }
- }
- </script>
- <style>
- @import url("./css/myself.css");
- </style>
|