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 d139b455
authored
Jun 18, 2025
by
wangzhihui
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed
1 parent
1979b544
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletions
src/views/residentManage/inStoreManage/components/performanceDeductionDialog.vue
src/views/residentManage/inStoreManage/components/performanceDeductionDialog.vue
View file @
d139b45
...
@@ -570,9 +570,11 @@ export default {
...
@@ -570,9 +570,11 @@ export default {
// 获取当前类型的所有区间
// 获取当前类型的所有区间
const
currentType
=
item
.
assessmentType
const
currentType
=
item
.
assessmentType
console
.
log
(
currentType
,
"currentType"
)
const
sameTypeItems
=
config
.
itemList
.
filter
(
const
sameTypeItems
=
config
.
itemList
.
filter
(
(
i
)
=>
i
.
assessmentType
===
currentType
(
i
)
=>
i
.
assessmentType
===
currentType
)
)
console
.
log
(
sameTypeItems
,
"sameTypeItems"
)
// 检查是否有重叠区间
// 检查是否有重叠区间
const
currentItemRange
=
[
min
,
max
]
const
currentItemRange
=
[
min
,
max
]
...
@@ -587,6 +589,7 @@ export default {
...
@@ -587,6 +589,7 @@ export default {
if
(
isNaN
(
otherMin
)
||
isNaN
(
otherMax
))
continue
if
(
isNaN
(
otherMin
)
||
isNaN
(
otherMax
))
continue
const
otherRange
=
[
otherMin
,
otherMax
]
const
otherRange
=
[
otherMin
,
otherMax
]
console
.
log
(
otherRange
,
"otherRange"
)
if
(
this
.
isOverlapping
(
currentItemRange
,
otherRange
))
{
if
(
this
.
isOverlapping
(
currentItemRange
,
otherRange
))
{
callback
(
new
Error
(
"区间与其他配置重叠,请调整"
))
callback
(
new
Error
(
"区间与其他配置重叠,请调整"
))
...
@@ -599,7 +602,8 @@ export default {
...
@@ -599,7 +602,8 @@ export default {
isOverlapping
(
range1
,
range2
)
{
isOverlapping
(
range1
,
range2
)
{
const
[
min1
,
max1
]
=
range1
const
[
min1
,
max1
]
=
range1
const
[
min2
,
max2
]
=
range2
const
[
min2
,
max2
]
=
range2
return
Math
.
max
(
min1
,
min2
)
<=
Math
.
min
(
max1
,
max2
)
console
.
log
(
range1
,
range2
,
Math
.
max
(
min1
,
min2
),
Math
.
min
(
max1
,
max2
))
return
Math
.
max
(
min1
,
min2
)
<
Math
.
min
(
max1
,
max2
)
},
},
// 范围校验器
// 范围校验器
validateRange
(
rule
,
value
,
callback
)
{
validateRange
(
rule
,
value
,
callback
)
{
...
...
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