123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119 |
- <template>
- <view>
- <!-- 预约列表 -->
- <view class="appointList">
- <template>
- <u-cell v-for="item in isLinkList1" :key="item.id" :border="false" :icon="item.icon" :title="item.title" isLink
- :url="item.url" />
- </template>
- </view>
- <view class="other-out-box">
- <u-cell v-for="item in isLinkList2" :key="item.id" :border="false" :icon="item.icon" :title="item.title"
- :isLink="item.isLink" :url="item.url" @click="handleCellClick(item)" />
- </view>
- <u-modal :show="showSwitchDialog" :showCancelButton="true" :title="title" :content="content"
- @confirm="confirmSwitch" @cancel="showSwitchDialog = false"></u-modal>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- isLinkList1: [{
- id: '0',
- icon: 'list-dot',
- title: '预约列表',
- url: '/pages/client/clientUser/mine/appoint/appoint',
- }
- // ,
- // {
- // id: '1',
- // icon: 'list',
- // title: '询价列表',
- // url: '/pages/client/clientUser/inquiryList',
- // },
- ],
- isLinkList2: [{
- id: '0',
- icon: 'home-fill',
- title: '我的店铺',
- url: '',
- isLink: false,
- },
- {
- id: '1',
- icon: 'plus-people-fill',
- title: '我的团队',
- url: '/pages/client/clientUser/myGroup',
- isLink: true,
- },
- {
- id: '2',
- icon: 'server-man',
- title: '客服中心',
- url: '/pages/client/clientUser/serviceCenter',
- isLink: true,
- },
- {
- id: '3',
- icon: 'share-square',
- title: '意见反馈',
- url: '/pages/client/clientUser/mine/setting/feedback',
- isLink: true,
- },
- {
- id: '4',
- icon: 'thumb-up',
- title: '关于我们',
- url: '/pages/client/clientUser/mine/setting/aboutMine',
- isLink: true,
- },
- ],
- showSwitchDialog: false,
- title: '提醒',
- content: '您确定要从用户端切换到商家端吗?',
- };
- },
- methods: {
- handleCellClick(item) {
- console.log('item', item);
- if (item.id == 0) {
- this.showSwitchDialog = true;
- } else {
- console.log('点击了非链接项');
- }
- },
- confirmSwitch() {
- this.showSwitchDialog = false;
- this.$store.dispatch('SwitchIdentity','MERCHANT')
- uni.navigateTo({
- url: '/pages/merchant/mine/index',
- });
- },
- },
- };
- </script>
- <style lang="scss" scoped>
- .appointList {
- margin: 20rpx;
- padding: 20rpx 10rpx;
- border-radius: 10rpx;
- background-color: #fff;
- }
- .other-out-box {
- margin: 20rpx;
- padding: 20rpx 10rpx;
- border-radius: 10rpx;
- margin-top: 0;
- box-sizing: border-box;
- background-color: $uni-bg-color;
- }
- </style>
|