Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bill-manager-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
bill-manager-ui
Commits
62be24dd
Commit
62be24dd
authored
Jul 08, 2024
by
“yiyousong”
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perf: 修改数据搜索引擎业务搜索
parent
1d520cc8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
50 additions
and
0 deletions
+50
-0
admin_2/src/pages/engineSearch/components/Search.vue
admin_2/src/pages/engineSearch/components/Search.vue
+50
-0
No files found.
admin_2/src/pages/engineSearch/components/Search.vue
View file @
62be24dd
...
@@ -82,10 +82,29 @@
...
@@ -82,10 +82,29 @@
placement=
"bottom-start"
placement=
"bottom-start"
popper-class=
"search-popover"
popper-class=
"search-popover"
>
>
<div
class=
"w-full"
>
<div
class=
"mb-3"
>
推荐业务
</div>
<div
class=
"flex w-full flex-col gap-3"
>
<div
class=
"flex cursor-pointer"
v-for=
"(v, i) in calcBusinessList"
:key=
"v.id"
@
click=
"form.businessName = v.businessName"
>
<div
:class=
"['mr-4', ' w-[20px]', `index-$
{i + 1}`]">
{{
i
+
1
}}
</div>
<div
class=
"flex-1 truncate"
>
{{
v
.
businessName
}}
</div>
</div>
</div>
</div>
<el-input
<el-input
size=
"small"
size=
"small"
placeholder=
"暂未选择"
placeholder=
"暂未选择"
slot=
"reference"
slot=
"reference"
v-model=
"form.businessName"
clearable
@
input=
"handleBusinessNameInput"
></el-input>
></el-input>
</el-popover>
</el-popover>
</div>
</div>
...
@@ -127,10 +146,12 @@
...
@@ -127,10 +146,12 @@
<
script
>
<
script
>
import
{
findBottomSubarrays
}
from
"
@/utils
"
;
import
{
findBottomSubarrays
}
from
"
@/utils
"
;
import
{
mapState
}
from
"
vuex
"
;
export
default
{
export
default
{
components
:
{},
components
:
{},
data
()
{
data
()
{
return
{
return
{
calcBusiness
:
[],
subMenus
:
[],
subMenus
:
[],
form
:
{
form
:
{
type
:
"
year
"
,
type
:
"
year
"
,
...
@@ -145,6 +166,7 @@ export default {
...
@@ -145,6 +166,7 @@ export default {
};
};
},
},
computed
:
{
computed
:
{
...
mapState
(
"
user
"
,
[
"
businessList
"
,
"
deptList
"
,
"
windowList
"
]),
activeKey
()
{
activeKey
()
{
return
this
.
$route
.
path
;
return
this
.
$route
.
path
;
},
},
...
@@ -157,8 +179,17 @@ export default {
...
@@ -157,8 +179,17 @@ export default {
return
this
.
form
.
day
;
return
this
.
form
.
day
;
}
}
},
},
calcBusinessList
:
{
get
()
{
return
this
.
calcBusiness
;
},
set
(
val
)
{
return
(
this
.
calcBusiness
=
val
);
},
},
},
},
created
()
{
created
()
{
this
.
calcBusiness
=
this
.
businessList
.
slice
(
0
,
10
);
this
.
getSubMenus
();
this
.
getSubMenus
();
},
},
mounted
()
{},
mounted
()
{},
...
@@ -188,6 +219,16 @@ export default {
...
@@ -188,6 +219,16 @@ export default {
this
.
form
.
month
=
""
;
this
.
form
.
month
=
""
;
this
.
form
.
day
=
""
;
this
.
form
.
day
=
""
;
},
},
handleBusinessNameInput
(
name
)
{
if
(
name
!==
""
)
{
let
list
=
this
.
businessList
.
filter
((
v
)
=>
v
.
businessName
.
includes
(
name
)
);
this
.
calcBusinessList
=
list
.
slice
(
0
,
10
);
}
else
{
this
.
calcBusinessList
=
this
.
businessList
.
slice
(
0
,
10
);
}
},
},
},
};
};
</
script
>
</
script
>
...
@@ -260,6 +301,15 @@ export default {
...
@@ -260,6 +301,15 @@ export default {
border: 2px solid var(--primary);
border: 2px solid var(--primary);
}
}
}
}
.index-1 {
color: #ff5948;
}
.index-2 {
color: #ff6f48;
}
.index-3 {
color: #ff8d48;
}
:deep(.el-picker-panel) {
:deep(.el-picker-panel) {
border: none;
border: none;
...
...
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