Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
Y
yishuju-ui
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
何远江
yishuju-ui
Commits
0682c3eb
Commit
0682c3eb
authored
Jul 26, 2025
by
沈翠玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
大屏增加动态变化
parent
0dcaefb2
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
104 additions
and
76 deletions
+104
-76
index.vue
src/components/ECharts/index.vue
+0
-1
user.js
src/stores/modules/user.js
+4
-0
AgeRatioChart.vue
src/views/data-screen-mock/components/AgeRatioChart.vue
+13
-16
PlatformSourceChart.vue
...views/data-screen-mock/components/PlatformSourceChart.vue
+33
-25
computerRateChart.vue
src/views/data-screen-mock/components/computerRateChart.vue
+0
-1
index.vue
src/views/data-screen-mock/index.vue
+13
-2
AgeRatioChart.vue
src/views/data-screen/components/AgeRatioChart.vue
+8
-9
PlatformSourceChart.vue
src/views/data-screen/components/PlatformSourceChart.vue
+31
-22
index.vue
src/views/data-screen/index.vue
+2
-0
No files found.
src/components/ECharts/index.vue
View file @
0682c3eb
...
@@ -45,7 +45,6 @@
...
@@ -45,7 +45,6 @@
const
draw
=
()
=>
{
const
draw
=
()
=>
{
if
(
chartInstance
.
value
)
{
if
(
chartInstance
.
value
)
{
console
.
log
(
'props.option'
,
props
.
option
);
chartInstance
.
value
.
setOption
(
props
.
option
);
chartInstance
.
value
.
setOption
(
props
.
option
);
}
}
};
};
...
...
src/stores/modules/user.js
View file @
0682c3eb
...
@@ -9,6 +9,7 @@ export const useUserStore = defineStore({
...
@@ -9,6 +9,7 @@ export const useUserStore = defineStore({
userInfo
:
null
,
userInfo
:
null
,
isTenant
:
false
,
// 是否操作了调解中心
isTenant
:
false
,
// 是否操作了调解中心
tenant
:
null
,
// 当前调解中心
tenant
:
null
,
// 当前调解中心
time
:
null
,
// 本地时间
}),
}),
getters
:
{
getters
:
{
getUserTenants
()
{
getUserTenants
()
{
...
@@ -26,6 +27,9 @@ export const useUserStore = defineStore({
...
@@ -26,6 +27,9 @@ export const useUserStore = defineStore({
setToken
(
token
)
{
setToken
(
token
)
{
this
.
token
=
token
;
this
.
token
=
token
;
},
},
setTime
(
time
)
{
this
.
time
=
time
;
},
// Set setUserInfo
// Set setUserInfo
setUserInfo
(
userInfo
)
{
setUserInfo
(
userInfo
)
{
this
.
userInfo
=
userInfo
;
this
.
userInfo
=
userInfo
;
...
...
src/views/data-screen-mock/components/AgeRatioChart.vue
View file @
0682c3eb
...
@@ -15,9 +15,11 @@
...
@@ -15,9 +15,11 @@
<
script
setup
>
<
script
setup
>
import
{
getSecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
getSecurityTotal
}
from
'@/api/dataScreenMock'
;
import
dayjs
from
'dayjs'
;
import
{
useUserStore
}
from
'@/stores/modules/user'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
const
load
=
ref
(
false
);
const
load
=
ref
(
false
);
const
timer1
=
ref
();
const
userStore
=
useUserStore
();
const
datas
=
ref
({});
const
datas
=
ref
({});
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
minCeiled
=
Math
.
ceil
(
min
);
const
minCeiled
=
Math
.
ceil
(
min
);
...
@@ -25,27 +27,22 @@
...
@@ -25,27 +27,22 @@
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
}
}
const
query
=
()
=>
{
const
query
=
()
=>
{
load
.
value
=
true
;
datas
.
value
.
securityDays
=
dayjs
().
diff
(
'2025-03-28'
,
'day'
)
getSecurityTotal
().
then
(
res
=>
{
if
(
dayjs
(
userStore
.
time
).
format
(
'mm:ss'
)
===
'00:00'
||
!
datas
.
value
.
interceptAttackDays
)
{
load
.
value
=
false
;
if
(
!
datas
.
value
.
interceptAttackDays
)
{
if
(
res
.
success
&&
res
.
result
&&
res
.
result
.
length
)
{
datas
.
value
.
interceptAttackDays
=
78
datas
.
value
.
securityDays
=
(
datas
.
value
.
securityDays
||
res
.
result
[
0
].
securityDays
)
+
getRandomIntInclusive
(
0
,
1
)
}
else
{
datas
.
value
.
interceptAttackDays
=
(
datas
.
value
.
interceptAttackDays
||
res
.
result
[
0
].
interceptAttackDays
)
+
getRandomIntInclusive
(
0
,
3
)
datas
.
value
.
interceptAttackDays
=
datas
.
value
.
interceptAttackDays
+
getRandomIntInclusive
(
10
,
30
)
}
}
}
)
}
}
}
query
();
query
();
timer1
.
value
=
setInterval
(
()
=>
{
watch
(()
=>
userStore
.
time
,
()
=>
{
if
(
!
load
.
value
)
{
if
(
!
load
.
value
)
{
query
();
query
();
}
}
},
6000
);
})
onBeforeUnmount
(()
=>
{
if
(
timer1
.
value
)
{
clearInterval
(
timer1
.
value
);
timer1
.
value
=
null
;
}
});
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.box
{
.box
{
...
...
src/views/data-screen-mock/components/PlatformSourceChart.vue
View file @
0682c3eb
...
@@ -6,13 +6,14 @@
...
@@ -6,13 +6,14 @@
</
template
>
</
template
>
<
script
setup
>
<
script
setup
>
import
dayjs
from
'dayjs'
;
import
ECharts
from
'@/components/ECharts/index.vue'
;
import
ECharts
from
'@/components/ECharts/index.vue'
;
import
echarts
from
'@/components/ECharts/config'
;
import
echarts
from
'@/components/ECharts/config'
;
import
{
getAISecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
getAISecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
useUserStore
}
from
'@/stores/modules/user'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
const
userStore
=
useUserStore
();
const
load
=
ref
(
false
);
const
load
=
ref
(
false
);
const
timer1
=
ref
();
const
datas
=
ref
([]);
const
datas
=
ref
([]);
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
minCeiled
=
Math
.
ceil
(
min
);
const
minCeiled
=
Math
.
ceil
(
min
);
...
@@ -20,26 +21,38 @@
...
@@ -20,26 +21,38 @@
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
}
}
const
query
=
()
=>
{
const
query
=
()
=>
{
load
.
value
=
true
;
if
((
dayjs
(
userStore
.
time
).
diff
(
'2025-03-28 10:00:00'
,
'day'
)
%
30
===
0
&&
dayjs
(
userStore
.
time
).
format
(
'HH:mm:ss'
)
===
'10:00:00'
)
||
!
datas
.
value
||
!
datas
.
value
.
length
)
{
getAISecurityTotal
().
then
(
res
=>
{
load
.
value
=
true
;
load
.
value
=
false
;
getAISecurityTotal
().
then
(
res
=>
{
if
(
res
.
success
)
{
load
.
value
=
false
;
res
.
result
.
forEach
(
v
=>
{
if
(
res
.
success
)
{
const
num
=
(
v
.
total
+
getRandomIntInclusive
(
-
10
,
20
))
if
(
datas
.
value
&&
datas
.
value
.
length
)
{
v
.
total
=
num
<
0
?
0
:
num
datas
.
value
.
forEach
(
v
=>
{
const
num1
=
(
v
.
newTotal
+
getRandomIntInclusive
(
-
10
,
50
))
const
num
=
(
v
.
total
+
getRandomIntInclusive
(
0
,
20
))
v
.
newTotal
=
num1
<
0
?
0
:
num1
v
.
total
=
num
<
0
?
0
:
num
})
const
num1
=
(
v
.
newTotal
+
getRandomIntInclusive
(
0
,
20
))
datas
.
value
=
res
.
result
v
.
newTotal
=
num1
<
0
?
0
:
num1
}
})
})
datas
.
value
=
datas
.
value
}
else
{
datas
.
value
.
forEach
(
v
=>
{
const
num
=
(
v
.
total
)
v
.
total
=
num
<
0
?
0
:
num
const
num1
=
(
v
.
newTotal
)
v
.
newTotal
=
num1
<
0
?
0
:
num1
})
datas
.
value
=
res
.
result
}
}
})
}
}
}
onBeforeUnmount
(()
=>
{
watch
(()
=>
userStore
.
time
,
()
=>
{
if
(
timer1
.
value
)
{
if
(
!
load
.
value
)
{
clearInterval
(
timer1
.
value
);
query
();
timer1
.
value
=
null
;
}
}
})
;
})
const
option
=
computed
(()
=>
{
const
option
=
computed
(()
=>
{
return
{
return
{
tooltip
:
{},
tooltip
:
{},
...
@@ -214,11 +227,6 @@
...
@@ -214,11 +227,6 @@
};
};
});
});
query
();
query
();
timer1
.
value
=
setInterval
(()
=>
{
if
(
!
load
.
value
)
{
query
();
}
},
6000
);
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.echarts
{
.echarts
{
...
...
src/views/data-screen-mock/components/computerRateChart.vue
View file @
0682c3eb
...
@@ -49,7 +49,6 @@
...
@@ -49,7 +49,6 @@
label
:
{
label
:
{
normal
:
{
normal
:
{
formatter
:
(
a
)
=>
{
formatter
:
(
a
)
=>
{
console
.
log
(
'sadsa4444'
,
a
);
let
html
=
''
;
let
html
=
''
;
html
+=
a
.
name
+
'
\
n'
+
a
.
seriesName
+
':'
+
a
.
data
.
value
+
'%'
;
html
+=
a
.
name
+
'
\
n'
+
a
.
seriesName
+
':'
+
a
.
data
.
value
+
'%'
;
return
html
;
return
html
;
...
...
src/views/data-screen-mock/index.vue
View file @
0682c3eb
...
@@ -195,7 +195,7 @@
...
@@ -195,7 +195,7 @@
}
}
const
num
=
Number
(
number
);
const
num
=
Number
(
number
);
if
(
num
>
100000000
)
{
if
(
num
>
100000000
)
{
return
Decimal
(
num
).
div
(
Decimal
(
100000000
)).
toNumber
().
toFixed
(
2
)
+
'亿'
;
return
Decimal
(
num
).
div
(
Decimal
(
100000000
)).
toNumber
().
toFixed
(
3
)
+
'亿'
;
}
else
if
(
num
>
10000
)
{
}
else
if
(
num
>
10000
)
{
return
Decimal
(
num
).
div
(
Decimal
(
10000
)).
toNumber
().
toFixed
(
2
)
+
'万'
;
return
Decimal
(
num
).
div
(
Decimal
(
10000
)).
toNumber
().
toFixed
(
2
)
+
'万'
;
}
else
if
(
num
>
1000
)
{
}
else
if
(
num
>
1000
)
{
...
@@ -249,7 +249,9 @@
...
@@ -249,7 +249,9 @@
}
}
getLoanKanBanTotal
(
params
).
then
((
res
)
=>
{
getLoanKanBanTotal
(
params
).
then
((
res
)
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
staticNumber
.
value
=
res
.
result
;
staticNumber
.
value
.
caseNum
=
res
.
result
.
caseNum
;
staticNumber
.
value
.
amount
=
res
.
result
.
amount
;
staticNumber
.
value
.
borrowerNum
=
res
.
result
.
borrowerNum
;
}
}
});
});
};
};
...
@@ -264,6 +266,15 @@
...
@@ -264,6 +266,15 @@
let
time
=
ref
(
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
));
let
time
=
ref
(
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
));
timer
=
setInterval
(()
=>
{
timer
=
setInterval
(()
=>
{
time
.
value
=
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
);
time
.
value
=
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
);
let
timest
=
dayjs
().
valueOf
();
userStore
.
setTime
(
timest
);
if
(
dayjs
(
timest
).
diff
(
'2025-03-28 10:00:00'
,
'day'
)
%
7
===
0
&&
dayjs
(
timest
).
format
(
'HH:mm:ss'
)
===
'10:00:00'
&&
staticNumber
.
value
.
sumRepayTotal
)
{
staticNumber
.
value
.
sumRepayTotal
=
staticNumber
.
value
.
sumRepayTotal
+
(
staticNumber
.
value
.
sumRepayTotal
*
0.0001
)
staticNumber
.
value
.
rate
=
staticNumber
.
value
.
rate
+
0.1
}
else
if
(
!
staticNumber
.
value
.
sumRepayTotal
){
staticNumber
.
value
.
sumRepayTotal
=
122600000
staticNumber
.
value
.
rate
=
0.52
}
},
1000
);
},
1000
);
onBeforeUnmount
(()
=>
{
onBeforeUnmount
(()
=>
{
...
...
src/views/data-screen/components/AgeRatioChart.vue
View file @
0682c3eb
...
@@ -15,6 +15,7 @@
...
@@ -15,6 +15,7 @@
<
script
setup
>
<
script
setup
>
import
{
getSecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
getSecurityTotal
}
from
'@/api/dataScreenMock'
;
import
dayjs
from
'dayjs'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
const
load
=
ref
(
false
);
const
load
=
ref
(
false
);
const
timer1
=
ref
();
const
timer1
=
ref
();
...
@@ -25,21 +26,19 @@
...
@@ -25,21 +26,19 @@
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
}
}
const
query
=
()
=>
{
const
query
=
()
=>
{
load
.
value
=
true
;
datas
.
value
.
securityDays
=
dayjs
().
diff
(
'2025-03-28'
,
'day'
)
getSecurityTotal
().
then
(
res
=>
{
if
(
!
datas
.
value
.
interceptAttackDays
)
{
load
.
value
=
false
;
datas
.
value
.
interceptAttackDays
=
78
if
(
res
.
success
&&
res
.
result
&&
res
.
result
.
length
)
{
}
else
{
datas
.
value
.
securityDays
=
(
datas
.
value
.
securityDays
||
res
.
result
[
0
].
securityDays
)
+
getRandomIntInclusive
(
0
,
1
)
datas
.
value
.
interceptAttackDays
=
datas
.
value
.
interceptAttackDays
+
getRandomIntInclusive
(
10
,
30
)
datas
.
value
.
interceptAttackDays
=
(
datas
.
value
.
interceptAttackDays
||
res
.
result
[
0
].
interceptAttackDays
)
+
getRandomIntInclusive
(
0
,
3
)
}
}
})
}
}
query
();
query
();
timer1
.
value
=
setInterval
(()
=>
{
timer1
.
value
=
setInterval
(()
=>
{
if
(
!
load
.
value
)
{
if
(
!
load
.
value
)
{
query
();
query
();
}
}
},
6
000
);
},
3600
000
);
onBeforeUnmount
(()
=>
{
onBeforeUnmount
(()
=>
{
if
(
timer1
.
value
)
{
if
(
timer1
.
value
)
{
clearInterval
(
timer1
.
value
);
clearInterval
(
timer1
.
value
);
...
...
src/views/data-screen/components/PlatformSourceChart.vue
View file @
0682c3eb
...
@@ -8,10 +8,12 @@
...
@@ -8,10 +8,12 @@
<
script
setup
>
<
script
setup
>
import
ECharts
from
'@/components/ECharts/index.vue'
;
import
ECharts
from
'@/components/ECharts/index.vue'
;
import
echarts
from
'@/components/ECharts/config'
;
import
echarts
from
'@/components/ECharts/config'
;
import
dayjs
from
'dayjs'
;
import
{
getAISecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
getAISecurityTotal
}
from
'@/api/dataScreenMock'
;
import
{
useUserStore
}
from
'@/stores/modules/user'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
import
{
reactive
,
ref
,
watch
,
computed
,
onBeforeUnmount
}
from
'vue'
;
const
userStore
=
useUserStore
();
const
load
=
ref
(
false
);
const
load
=
ref
(
false
);
const
timer1
=
ref
();
const
datas
=
ref
([]);
const
datas
=
ref
([]);
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
getRandomIntInclusive
=
(
min
,
max
)
=>
{
const
minCeiled
=
Math
.
ceil
(
min
);
const
minCeiled
=
Math
.
ceil
(
min
);
...
@@ -19,26 +21,33 @@
...
@@ -19,26 +21,33 @@
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
return
Math
.
floor
(
Math
.
random
()
*
(
maxFloored
-
minCeiled
+
1
)
+
minCeiled
);
}
}
const
query
=
()
=>
{
const
query
=
()
=>
{
load
.
value
=
true
;
if
((
dayjs
(
userStore
.
time
).
diff
(
'2025-03-28 10:00:00'
,
'day'
)
%
30
===
0
&&
dayjs
(
userStore
.
time
).
format
(
'HH:mm:ss'
)
===
'10:00:00'
)
||
!
datas
.
value
||
!
datas
.
value
.
length
)
{
getAISecurityTotal
().
then
(
res
=>
{
load
.
value
=
true
;
load
.
value
=
false
;
getAISecurityTotal
().
then
(
res
=>
{
if
(
res
.
success
)
{
load
.
value
=
false
;
res
.
result
.
forEach
(
v
=>
{
if
(
res
.
success
)
{
const
num
=
(
v
.
total
+
getRandomIntInclusive
(
-
10
,
20
))
if
(
datas
.
value
&&
datas
.
value
.
length
)
{
v
.
total
=
num
<
0
?
0
:
num
datas
.
value
.
forEach
(
v
=>
{
const
num1
=
(
v
.
newTotal
+
getRandomIntInclusive
(
-
10
,
50
))
const
num
=
(
v
.
total
+
getRandomIntInclusive
(
0
,
20
))
v
.
newTotal
=
num1
<
0
?
0
:
num1
v
.
total
=
num
<
0
?
0
:
num
})
const
num1
=
(
v
.
newTotal
+
getRandomIntInclusive
(
0
,
20
))
datas
.
value
=
res
.
result
v
.
newTotal
=
num1
<
0
?
0
:
num1
}
})
})
datas
.
value
=
datas
.
value
}
}
else
{
onBeforeUnmount
(()
=>
{
datas
.
value
.
forEach
(
v
=>
{
if
(
timer1
.
value
)
{
const
num
=
(
v
.
total
)
clearInterval
(
timer1
.
value
);
v
.
total
=
num
<
0
?
0
:
num
timer1
.
value
=
null
;
const
num1
=
(
v
.
newTotal
)
v
.
newTotal
=
num1
<
0
?
0
:
num1
})
datas
.
value
=
res
.
result
}
}
})
}
}
}
);
}
const
option
=
computed
(()
=>
{
const
option
=
computed
(()
=>
{
return
{
return
{
tooltip
:
{},
tooltip
:
{},
...
@@ -213,11 +222,11 @@
...
@@ -213,11 +222,11 @@
};
};
});
});
query
();
query
();
timer1
.
value
=
setInterval
(
()
=>
{
watch
(()
=>
userStore
.
time
,
()
=>
{
if
(
!
load
.
value
)
{
if
(
!
load
.
value
)
{
query
();
query
();
}
}
}
,
6000
);
}
)
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.echarts
{
.echarts
{
...
...
src/views/data-screen/index.vue
View file @
0682c3eb
...
@@ -263,6 +263,8 @@
...
@@ -263,6 +263,8 @@
let
time
=
ref
(
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
));
let
time
=
ref
(
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
));
timer
=
setInterval
(()
=>
{
timer
=
setInterval
(()
=>
{
time
.
value
=
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
);
time
.
value
=
dayjs
().
format
(
'YYYY年MM月DD HH:mm:ss'
);
let
timest
=
dayjs
().
valueOf
();
userStore
.
setTime
(
timest
);
},
1000
);
},
1000
);
onBeforeUnmount
(()
=>
{
onBeforeUnmount
(()
=>
{
...
...
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