积分超市

This commit is contained in:
yanran200730
2023-04-13 18:01:02 +08:00
parent 62c927746b
commit 483a4d585f
13 changed files with 614 additions and 2633 deletions

View File

@@ -1,18 +1,7 @@
<template>
<ai-list v-if="!isShowDetail">
<template slot="title">
<ai-title
title="订单管理"
:isShowBottomBorder="false"
:isShowArea="currIndex === '1'"
:fullname.sync="areaName"
v-model="areaId"
:instance="instance"
@change="onAreaChange">
<!-- <template #sub>
<span v-if="currIndex === '0'">可查看并核销网格员在积分超市中兑换的商品订单</span>
<span v-else>可查看并核销居民在积分超市中兑换的商品订单</span>
</template> -->
<ai-title title="订单管理" :isShowBottomBorder="false">
</ai-title>
</template>
<template slot="tabs">
@@ -23,11 +12,15 @@
</el-tabs>
</template>
</ai-list>
<ResidentDetail v-else-if="componentName === 'ResidentDetail'" :areaId="areaId" :params="params" :instance="instance" :dict="dict" @change="onChange"></ResidentDetail>
<GirdDetail v-else-if="componentName === 'GirdDetail'" :areaId="areaId" :params="params" :instance="instance" :dict="dict" @change="onChange"></GirdDetail>
</template>
<script>
import GirdOrderList from './components/GirdOrderList.vue'
import ResidentOrderList from './components/ResidentOrderList'
import ResidentDetail from './components/ResidentDetail'
import GirdDetail from './components/GirdDetail'
import GirdList from './components/GirdList'
import ResidentList from './components/ResidentList'
import { mapState } from 'vuex'
export default {
@@ -35,8 +28,10 @@
label: '订单管理',
components: {
ResidentOrderList,
GirdOrderList
ResidentList,
GirdList,
ResidentDetail,
GirdDetail
},
props: {
@@ -50,8 +45,8 @@
tabs () {
const tabList = [
{label: '网格积分订单', name: 'GirdOrderList', comp: GirdOrderList, permission: ''},
{label: '居民积分订单', name: 'ResidentOrderList', comp: ResidentOrderList, permission: ''}
{label: '网格积分订单', name: 'GirdList', comp: GirdList, permission: ''},
{label: '居民积分订单', name: 'ResidentList', comp: ResidentList, permission: ''}
].filter(item => {
return true
})
@@ -62,7 +57,7 @@
data () {
return {
activeName: 'GirdOrderList',
activeName: 'GoodsList',
currIndex: '0',
componentName: '',
params: {},
@@ -74,11 +69,6 @@
created () {
this.areaId = this.user.info.areaId
if (this.$route.query.id) {
this.componentName = this.$route.query?.type
this.params = {id: this.$route.query?.id}
this.isShowDetail = true
}
},
methods: {
@@ -91,19 +81,25 @@
},
onChange (data) {
if (data.type === 'GirdOrderList') {
this.componentName = 'GirdOrderList'
if (data.type === 'GirdList') {
this.componentName = 'GirdList'
this.isShowDetail = false
this.params = data.params
}
if (data.type === 'ResidentOrderList') {
this.componentName = 'ResidentOrderList'
if (data.type === 'ResidentList') {
this.componentName = 'ResidentList'
this.isShowDetail = false
this.params = data.params
}
if (data.type === 'Detail') {
this.componentName = 'Detail'
if (data.type === 'GirdDetail') {
this.componentName = 'GirdDetail'
this.isShowDetail = true
this.params = data.params
}
if (data.type === 'ResidentDetail') {
this.componentName = 'ResidentDetail'
this.isShowDetail = true
this.params = data.params
}