修复获取应用列表筛选异常
This commit is contained in:
@@ -29,8 +29,9 @@ export default {
|
|||||||
...mapState(['token', 'openUser', 'user']),
|
...mapState(['token', 'openUser', 'user']),
|
||||||
appsList() {
|
appsList() {
|
||||||
let {search, currentLib} = this
|
let {search, currentLib} = this
|
||||||
return this.apps.filter(e => (currentLib == "apps" && e.path.indexOf("project")) || e.path.indexOf(currentLib) > -1)
|
return this.apps.filter(e => {
|
||||||
.filter(e => !!search ? e.name.indexOf(search) > -1 : true) || []
|
return (currentLib == "apps" && e.path.indexOf("project") > -1) || e.path.indexOf(currentLib) > -1
|
||||||
|
}).filter(e => !!search ? e.name.indexOf(search) > -1 : true) || []
|
||||||
},
|
},
|
||||||
currentApp() {
|
currentApp() {
|
||||||
return this.apps.find(e => e.key == this.$route.query.app) || {}
|
return this.apps.find(e => e.key == this.$route.query.app) || {}
|
||||||
@@ -52,7 +53,6 @@ export default {
|
|||||||
...mapMutations(['logout']),
|
...mapMutations(['logout']),
|
||||||
...mapActions(['agentSign']),
|
...mapActions(['agentSign']),
|
||||||
handleGotoApp(app) {
|
handleGotoApp(app) {
|
||||||
console.log(app)
|
|
||||||
uni.navigateTo({url: `${app.path}`})
|
uni.navigateTo({url: `${app.path}`})
|
||||||
},
|
},
|
||||||
handleLogin() {
|
handleLogin() {
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="document-flow">
|
<div class="document-flow">
|
||||||
<ai-top-fixed>
|
<AiTopFixed>
|
||||||
<header class="pad">
|
<header class="pad">
|
||||||
<u-search placeholder="请输入公文名称" v-model="documentName" @clear="documentName='',getList()" @search="getList"
|
<u-search placeholder="请输入公文名称" v-model="documentName" @clear="documentName='',getList()" @search="getList"
|
||||||
clearabled :show-action="false" height="64"></u-search>
|
clearabled :show-action="false" height="64"></u-search>
|
||||||
</header>
|
</header>
|
||||||
</ai-top-fixed>
|
</AiTopFixed>
|
||||||
<div class="list pad" v-if="list.length">
|
<div class="list pad" v-if="list.length">
|
||||||
<div class="card" v-for="(item,index) in list" :key="index" @click="handleClick(item)">
|
<div class="card" v-for="(item,index) in list" :key="index" @click="handleClick(item)">
|
||||||
<u-row>
|
<u-row>
|
||||||
|
|||||||
Reference in New Issue
Block a user