Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
liyeyun
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
cfld-frontend
liyeyun
Commits
8e1675c5
Commit
8e1675c5
authored
Dec 22, 2023
by
shilei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 城市切换首页回显
parent
8b6455f5
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
2 deletions
+18
-2
reset.scss
src/assets/styles/reset.scss
+3
-1
CommonHeader.vue
src/components/common/CommonHeader.vue
+15
-1
No files found.
src/assets/styles/reset.scss
View file @
8e1675c5
...
@@ -11,7 +11,9 @@ body {
...
@@ -11,7 +11,9 @@ body {
WenQuanYi
Micro
Hei
,
WenQuanYi
Micro
Hei
,
sans-serif
;
sans-serif
;
}
}
:root
{
--el-menu-hover-bg-color
:
none
!
important
;
}
.el-container
{
.el-container
{
min-width
:
1366px
!
important
;
min-width
:
1366px
!
important
;
}
}
...
...
src/components/common/CommonHeader.vue
View file @
8e1675c5
...
@@ -163,7 +163,6 @@ import { computed, ref, onMounted, watch } from 'vue';
...
@@ -163,7 +163,6 @@ import { computed, ref, onMounted, watch } from 'vue';
import
{
useJump
}
from
'@/composable/useJump.ts'
;
import
{
useJump
}
from
'@/composable/useJump.ts'
;
import
{
RouteName
}
from
'@/router/router.ts'
;
import
{
RouteName
}
from
'@/router/router.ts'
;
import
{
useRoute
}
from
'vue-router'
;
import
{
useRoute
}
from
'vue-router'
;
// import cookie from 'js-cookie';
import
{
useCity
}
from
'@/composable/useCity.ts'
;
import
{
useCity
}
from
'@/composable/useCity.ts'
;
import
type
{
DropdownInstance
}
from
'element-plus'
;
import
type
{
DropdownInstance
}
from
'element-plus'
;
import
type
{
RouteLocationRaw
}
from
'vue-router'
;
import
type
{
RouteLocationRaw
}
from
'vue-router'
;
...
@@ -245,6 +244,21 @@ onMounted(() => {
...
@@ -245,6 +244,21 @@ onMounted(() => {
console
.
log
(
'city'
,
city
,
route
);
console
.
log
(
'city'
,
city
,
route
);
if
(
city
)
{
if
(
city
)
{
currentCity
.
value
=
city
as
string
;
currentCity
.
value
=
city
as
string
;
}
else
if
(
searchParamsStore
.
globalProvinceName
)
{
for
(
const
tempList
of
cityList
)
{
if
(
tempList
.
items
.
filter
(
(
item
)
=>
searchParamsStore
.
globalProvinceName
.
replace
(
/
\s
+/g
,
''
).
indexOf
(
item
)
>
-
1
,
).
length
)
{
for
(
const
tempCity
of
tempList
.
items
)
{
currentCity
.
value
=
searchParamsStore
.
globalProvinceName
.
replace
(
/
\s
+/g
,
''
).
indexOf
(
tempCity
)
>
-
1
?
tempCity
:
currentCity
.
value
;
}
}
}
}
}
},
0
);
},
0
);
});
});
...
...
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