Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
H
huamu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
郭铭瑶
huamu
Commits
f1b83ea3
Commit
f1b83ea3
authored
Sep 26, 2021
by
郭铭瑶
🤘
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整页面中基于权限编码请求数据时机
parent
f88f1b66
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
41 additions
and
15 deletions
+41
-15
main.ts
src/main.ts
+0
-1
activity-drawer.vue
src/view/components/activity-drawer.vue
+9
-4
activity-list-modal.vue
src/view/components/activity-list-modal.vue
+9
-4
map.vue
src/view/components/map.vue
+1
-0
nav-bar.vue
src/view/components/nav-bar.vue
+1
-1
new-activity-drawer.vue
src/view/components/new-activity-drawer.vue
+10
-2
struct-modal.vue
src/view/components/struct-modal.vue
+11
-3
No files found.
src/main.ts
View file @
f1b83ea3
...
...
@@ -39,7 +39,6 @@ import {
NMenu
,
NPopover
,
}
from
'naive-ui'
import
{
normalizeHue
}
from
'naive-ui/lib/color-picker/src/utils'
const
naive
=
create
({
components
:
[
...
...
src/view/components/activity-drawer.vue
View file @
f1b83ea3
...
...
@@ -87,7 +87,7 @@
<
script
lang=
"ts"
setup
>
import
store
from
'@/store'
import
{
computed
,
onMounted
,
ref
,
watch
}
from
'vue'
import
{
computed
,
ref
,
watch
}
from
'vue'
import
{
Checkmark
,
Close
}
from
'@vicons/ionicons5'
import
ActivityListModal
from
'./activity-list-modal.vue'
import
{
useFetchActivity
}
from
'@/hooks/useFetch'
...
...
@@ -149,9 +149,14 @@ const list = ref([
},
])
onMounted
(()
=>
{
watch
(
()
=>
store
.
state
.
auth
.
code
,
(
code
)
=>
{
if
(
!
code
)
return
getList
()
})
},
{
immediate
:
true
},
)
async
function
getList
(
query
?:
string
)
{
const
result
=
[...
list
.
value
]
...
...
src/view/components/activity-list-modal.vue
View file @
f1b83ea3
...
...
@@ -109,7 +109,7 @@
<
script
lang=
"ts"
setup
>
import
store
from
'@/store'
import
{
computed
,
ref
,
h
,
onMounted
,
watch
}
from
'vue'
import
{
computed
,
ref
,
h
,
watch
}
from
'vue'
import
NewActivityDrawer
from
'./new-activity-drawer.vue'
import
{
Add
}
from
'@vicons/ionicons5'
import
dayjs
from
'@/util/dayjs'
...
...
@@ -131,6 +131,14 @@ const fetchList = useDebounce(async (query?: string) => {
...
item
.
extra
,
}))
||
[]
})
watch
(
()
=>
store
.
state
.
auth
.
code
,
(
code
)
=>
{
if
(
!
code
)
return
fetchList
()
},
{
immediate
:
true
},
)
function
clearData
()
{
model
.
value
=
{
...
...
@@ -145,9 +153,6 @@ const reFetchList = () => {
clearData
()
fetchList
()
}
onMounted
(()
=>
{
fetchList
()
})
const
show
=
computed
(()
=>
store
.
state
.
showActivityListModal
)
const
close
=
(
val
:
boolean
)
=>
{
store
.
commit
(
'SET_ACTIVITY_LIST_MODAL'
,
val
)
...
...
src/view/components/map.vue
View file @
f1b83ea3
...
...
@@ -30,6 +30,7 @@ onMounted(async () => {
/** 重置地图 */
function
resetMap
()
{
if
(
!
window
.
graphiclayer
||
!
window
.
sceneView
)
return
window
.
graphiclayer
.
removeAll
()
window
.
sceneView
.
popup
.
close
()
if
(
window
.
modelHighlight
)
{
...
...
src/view/components/nav-bar.vue
View file @
f1b83ea3
...
...
@@ -116,7 +116,7 @@
</template>
<
script
lang=
"ts"
setup
>
import
{
computed
,
onMounted
,
ref
,
watch
}
from
'vue'
import
{
computed
,
ref
,
watch
}
from
'vue'
import
store
from
'@/store'
import
{
useFetchOrg
,
useFetchMember
}
from
'@/hooks/useFetch'
import
useDebounce
from
'@/hooks/useDebounce'
...
...
src/view/components/new-activity-drawer.vue
View file @
f1b83ea3
...
...
@@ -327,7 +327,7 @@ const props = defineProps({
const
mode
=
ref
<
string
|
null
>
(
null
)
const
orgOptions
=
ref
<
any
[]
>
([])
onMounted
(
async
()
=>
{
async
function
getOrgOptions
()
{
orgOptions
.
value
=
(
await
useFetchOrg
({
a
:
'id,count'
,
...
...
@@ -340,7 +340,15 @@ onMounted(async () => {
label
:
item
[
'党组织名称'
],
value
:
item
[
'党组织名称'
],
}))
})
}
watch
(
()
=>
store
.
state
.
auth
.
code
,
(
code
)
=>
{
if
(
!
code
)
return
getOrgOptions
()
},
{
immediate
:
true
},
)
const
show
=
computed
(()
=>
store
.
state
.
showNewActivityDrawer
)
const
closeDrawer
=
()
=>
{
...
...
src/view/components/struct-modal.vue
View file @
f1b83ea3
...
...
@@ -380,7 +380,7 @@
<
script
lang=
"ts"
setup
>
import
store
from
'@/store'
import
{
computed
,
h
,
onMounted
,
ref
,
watch
}
from
'vue'
import
{
computed
,
h
,
ref
,
watch
}
from
'vue'
import
PartyIcon
from
'./party-icon.vue'
import
exportIcon
from
'@images/export.svg'
import
{
CloseOutline
}
from
'@vicons/ionicons5'
...
...
@@ -441,7 +441,15 @@ const belongToCommunityParty = ref<any[]>([])
const
onlyOne
=
ref
(
false
)
onMounted
(
async
()
=>
{
watch
(
()
=>
code
.
value
,
(
code
)
=>
{
if
(
!
code
)
return
init
()
},
{
immediate
:
true
},
)
async
function
init
()
{
const
orgList
=
await
useFetchOrg
({
q
:
`paths @ "党组织编号" && string @ "
${
code
.
value
}
"`
,
})
...
...
@@ -563,7 +571,7 @@ onMounted(async () => {
},
]
initCurMenu
()
}
)
}
async
function
checkHasChildren
(
data
:
any
)
{
if
(
!
data
)
return
[]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment