Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-life-system
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 9277b7a4
authored
Aug 24, 2026
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix bug
1 parent
5c6cc0f2
Pipeline
#231
for
9277b7a4
failed
in 0 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
58 additions
and
1 deletions
src/views/residentManage/journalRecord/index.vue
tests/unit/views/residentManage/journalRecord/index.spec.js
src/views/residentManage/journalRecord/index.vue
View file @
9277b7a
...
...
@@ -60,7 +60,7 @@
:table-params=
"tableParams"
>
<
template
#
bizType=
"{ scope }"
>
<BizTypeTag
:biz-type=
"scope.bizType"
:biz-type-name=
"scope.bizTypeName"
/>
:biz-type-name=
"scope.bizTypeName
=== '权益' ? '权益延保' : scope.bizTypeName
"
/>
</
template
>
<
template
#
auth-button=
"{ scope }"
>
<el-button
class=
"journal-record__detail-btn"
...
...
tests/unit/views/residentManage/journalRecord/index.spec.js
View file @
9277b7a
...
...
@@ -24,6 +24,37 @@ const SelectStub = {
template
:
"<div class=\"merchant-select\">{{ placeholder }}</div>"
,
};
const
JournalTableStub
=
{
name
:
"D2Table"
,
render
(
h
)
{
const
bizTypeSlot
=
this
.
$scopedSlots
.
bizType
;
if
(
!
bizTypeSlot
)
{
return
h
(
"div"
);
}
return
h
(
"div"
,
bizTypeSlot
({
scope
:
{
bizType
:
2
,
bizTypeName
:
"权益"
,
},
}));
},
};
const
BizTypeTagStub
=
{
name
:
"BizTypeTag"
,
props
:
{
bizType
:
{
type
:
[
Number
,
String
],
default
:
""
,
},
bizTypeName
:
{
type
:
String
,
default
:
""
,
},
},
template
:
"<div class=\"biz-type-tag-stub\">{{ bizTypeName }}</div>"
,
};
describe
(
"journalRecord"
,
()
=>
{
afterEach
(()
=>
{
jest
.
clearAllMocks
();
...
...
@@ -54,6 +85,32 @@ describe("journalRecord", () => {
wrapper
.
destroy
();
});
it
(
"列表中的权益业务应显示为权益延保"
,
()
=>
{
const
wrapper
=
shallowMount
({
...
JournalRecord
,
mounted
()
{},
},
{
mocks
:
{
$route
:
{
query
:
{}
},
$router
:
{
replace
:
jest
.
fn
(),
push
:
jest
.
fn
()
},
},
stubs
:
{
"BizTypeTag"
:
BizTypeTagStub
,
"d2-container"
:
SlotHost
,
"d2-search"
:
SlotHost
,
"d2-table"
:
JournalTableStub
,
"el-button"
:
true
,
"el-option"
:
true
,
"el-select"
:
SelectStub
,
"el-tab-pane"
:
true
,
"el-tabs"
:
SlotHost
,
},
});
expect
(
wrapper
.
find
(
".biz-type-tag-stub"
).
text
()).
toBe
(
"权益延保"
);
wrapper
.
destroy
();
});
it
(
"查看仅有 sceneList 的日报应携带精确场景和业务兜底上下文"
,
async
()
=>
{
const
row
=
mapOverviewRow
({
id
:
"report-1"
,
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment