Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
wangxiaolu-sfa-ui
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
sfa
wangxiaolu-sfa-ui
Commits
8a026383
提交
8a026383
authored
8月 28, 2025
作者:
lidongxu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat(mobile/pages/../storelist.vue): 新增:勤策移动端-售点稽核-终端门店列表页面样式准备
上级
d43a1d72
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
197 行增加
和
7 行删除
+197
-7
index.vue
src/views/mobile/index.vue
+0
-2
storeList.vue
...dit_activity/sales_point_inspection/examine/storeList.vue
+197
-5
没有找到文件。
src/views/mobile/index.vue
浏览文件 @
8a026383
...
@@ -26,9 +26,7 @@ watch(
...
@@ -26,9 +26,7 @@ watch(
);
);
function
getKeepAliveName
(
routes
)
{
function
getKeepAliveName
(
routes
)
{
console
.
log
(
'routes'
,
routes
)
routes
.
forEach
((
item
)
=>
{
routes
.
forEach
((
item
)
=>
{
console
.
log
(
'1'
,
item
)
if
(
!
item
.
meta
?.
noCache
&&
item
.
name
)
{
// 是否缓存
if
(
!
item
.
meta
?.
noCache
&&
item
.
name
)
{
// 是否缓存
cachedViews
.
push
(
item
.
name
)
cachedViews
.
push
(
item
.
name
)
}
}
...
...
src/views/mobile/pages/audit_activity/sales_point_inspection/examine/storeList.vue
浏览文件 @
8a026383
<
template
>
<
template
>
<!-- 门店列表 -->
<div
class=
"search-container"
>
<div>
<!-- 头部区域 -->
门店列表
<div
class=
"header-wrap"
>
<span>
终端
</span>
<!-- 搜索区域 -->
<van-search
v-model=
"searchVal"
placeholder=
"请输入勤策终端编码/名称"
@
search=
"handleSearch"
@
clear=
"handleClear"
class=
"search-bar"
>
<template
#
action
>
<van-button
round
type=
"primary"
size=
"small"
@
click=
"handleSearch"
>
搜索
</van-button>
</
template
>
</van-search>
<van-tag
type=
"primary"
round
size=
"medium"
>
记录
</van-tag>
</div>
<!-- 结果列表 -->
<van-list
v-model:loading=
"loading"
:finished=
"finished"
finished-text=
"没有更多结果了"
class=
"result-list"
>
<van-cell-group
inset
>
<van-cell
v-for=
"(item, index) in resultList"
:key=
"index"
class=
"result-item"
>
<
template
#
title
>
<div
class=
"item-title"
>
{{
item
.
name
}}
(
{{
item
.
code
}}
)
</div>
</
template
>
<
template
#
label
>
<div
class=
"item-company"
>
{{
item
.
company
}}
</div>
<div
class=
"item-address"
>
{{
item
.
address
}}
</div>
</
template
>
</van-cell>
</van-cell-group>
</van-list>
<!-- 无结果提示 -->
<van-empty
v-if=
"showEmpty"
description=
"未找到匹配的结果"
class=
"empty-tip"
/>
</div>
</div>
</template>
</template>
<
script
setup
>
<
script
setup
>
// 模拟数据
const
mockData
=
[
{
name
:
'世纪港湾广缘超市'
,
code
:
'POS00052306'
,
company
:
'秦皇岛洪朗森商贸有限公司'
,
address
:
'河北省秦皇岛市海港区北环路街道秦皇东大街辅路'
},
{
name
:
'711浦东南路地铁站店'
,
code
:
'POS00048465'
,
company
:
'上海星甲商贸有限公司'
,
address
:
'上海市浦东新区浦东南路浦东金融广场'
},
{
name
:
'嘉兴大桥瑞洲'
,
code
:
'POS00052360'
,
company
:
'嘉兴凯鸣商贸有限公司'
,
address
:
'浙江省湖州市吴兴区康山街道兴业路'
}
];
// 响应式数据
const
searchVal
=
ref
(
''
);
const
resultList
=
ref
(
mockData
);
const
loading
=
ref
(
false
);
const
finished
=
ref
(
true
);
const
showEmpty
=
ref
(
false
);
// 监听结果列表变化,控制空状态显示
watch
(
resultList
,
(
newVal
)
=>
{
showEmpty
.
value
=
newVal
.
length
===
0
&&
searchVal
.
value
.
trim
()
!==
''
;
});
// 搜索处理
const
handleSearch
=
()
=>
{
if
(
!
searchVal
.
value
.
trim
())
{
resultList
.
value
=
mockData
;
showEmpty
.
value
=
false
;
return
;
}
// 模拟加载状态
loading
.
value
=
true
;
// 模拟接口请求延迟
setTimeout
(()
=>
{
const
filtered
=
mockData
.
filter
(
item
=>
{
const
matchStr
=
`
${
item
.
name
}${
item
.
code
}${
item
.
company
}${
item
.
address
}
`
;
return
matchStr
.
includes
(
searchVal
.
value
);
});
resultList
.
value
=
filtered
;
loading
.
value
=
false
;
finished
.
value
=
true
;
},
500
);
};
// 清除搜索
const
handleClear
=
()
=>
{
resultList
.
value
=
mockData
;
showEmpty
.
value
=
false
;
};
</
script
>
</
script
>
<
style
scoped
></
style
>
<
style
lang=
"scss"
\ No newline at end of file
scoped
>
// 基础样式设置
$base-width
:
375px
;
$base-font-size
:
16px
;
.search-container
{
width
:
$base-width
;
margin
:
0
auto
;
font-size
:
$base-font-size
;
box-sizing
:
border-box
;
padding-bottom
:
20px
;
background-color
:
#f5f5f5
;
min-height
:
100vh
;
.header-wrap
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
padding
:
0
20px
;
border-bottom
:
2px
solid
#e5e5e5
;
span
{
font-size
:
14px
;
}
.search-bar
{
padding
:
10px
;
height
:
auto
!
important
;
background-color
:
transparent
;
::v-deep
(
.van-search__content
)
{
background-color
:
white
;
.van-cell
{
height
:
auto
;
}
}
}
}
.result-list
{
background-color
:
transparent
;
padding
:
0
20px
;
margin-top
:
10px
;
.van-cell-group
{
margin
:
0
;
background-color
:
transparent
;
.result-item
{
background-color
:
white
;
margin-bottom
:
10px
;
.item-title
{
font-weight
:
600
;
color
:
#333
;
margin-bottom
:
4px
;
}
.item-company
{
font-size
:
14px
;
color
:
#a6a4a4
;
margin-bottom
:
2px
;
}
.item-address
{
font-size
:
13px
;
color
:
#a6a4a4
;
line-height
:
1
.4
;
}
}
}
}
.empty-tip
{
margin-top
:
40px
;
padding
:
0
12px
;
}
}
</
style
>
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论