Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sfp-program
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Sweet Zhang
sfp-program
Commits
14160e5f
You need to sign in or sign up before continuing.
Commit
14160e5f
authored
Oct 20, 2022
by
kyle
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改学制之后内页增加对应的数量
parent
9ef23f3d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
56 additions
and
37 deletions
+56
-37
pages/childEdu/childEdu.vue
+56
-37
No files found.
pages/childEdu/childEdu.vue
View file @
14160e5f
...
...
@@ -95,8 +95,8 @@
</li>
<li
v-for=
"item in schoolingLists"
:key=
"item.value"
>
<div>
{{
item
.
text
}}
</div>
<div><input
class=
"uni-input"
maxlength=
"1"
type=
"number"
placeholder=
"最高不超过10"
v-model=
"item.commonYears"
/></div>
<div><input
class=
"uni-input"
maxlength=
"10"
type=
"digit"
v-model=
"item.publicTuition"
/></div>
<div><input
class=
"uni-input"
maxlength=
"1"
type=
"number"
placeholder=
"最高不超过10"
v-model=
"item.commonYears"
@
blur=
"updateSchoolingLists(item)"
/></div>
<div><input
class=
"uni-input"
maxlength=
"10"
type=
"digit"
v-model=
"item.publicTuition"
@
blur=
"updateSchoolingLists(item)"
/></div>
<div><view
class=
"settingButton"
@
click=
"settingYBY(item)"
>
逐年设定
</view></div>
</li>
</ul>
...
...
@@ -211,36 +211,41 @@
getClassesInfo
(
val
){
if
(
val
){
const
value
=
this
.
flatEduGradeLists
.
filter
(
item
=>
item
.
educationNo
==
val
)[
0
].
value
;
const
schooling
=
value
.
split
(
'-'
)[
0
];
const
grade
=
value
.
split
(
'-'
)[
1
];
let
schoolingName
=
''
;
switch
(
schooling
){
case
'1'
:
schoolingName
=
'幼儿园'
;
break
;
case
'2'
:
schoolingName
=
'小学'
;
break
;
case
'3'
:
schoolingName
=
'初中'
;
break
;
case
'4'
:
schoolingName
=
'高中'
;
break
;
case
'5'
:
schoolingName
=
'大学'
;
break
;
case
'6'
:
schoolingName
=
'硕士'
;
break
;
case
'7'
:
schoolingName
=
'博士'
;
break
;
default
:
schoolingName
=
'幼儿园'
;
break
;
if
(
value
){
const
schooling
=
value
.
split
(
'-'
)[
0
];
const
grade
=
value
.
split
(
'-'
)[
1
];
let
schoolingName
=
''
;
switch
(
schooling
){
case
'1'
:
schoolingName
=
'幼儿园'
;
break
;
case
'2'
:
schoolingName
=
'小学'
;
break
;
case
'3'
:
schoolingName
=
'初中'
;
break
;
case
'4'
:
schoolingName
=
'高中'
;
break
;
case
'5'
:
schoolingName
=
'大学'
;
break
;
case
'6'
:
schoolingName
=
'硕士'
;
break
;
case
'7'
:
schoolingName
=
'博士'
;
break
;
default
:
schoolingName
=
'幼儿园'
;
break
;
}
return
(
schoolingName
+
grade
+
'年级'
);
}
else
{
return
val
;
}
return
(
schoolingName
+
grade
+
'年级'
);
}
},
getFollowData
(
e
){
...
...
@@ -281,7 +286,7 @@
boundaryGap
:
false
,
axisLabel
:{
interval
:
0
,
rotate
:
0
rotate
:
6
0
},
textStyle
:{
fontSize
:
10
...
...
@@ -310,7 +315,7 @@
emphasis
:
{
focus
:
'series'
},
data
:
this
.
accountBalanceEnd
data
:
this
.
accountBalanceEnd
,
},
{
name
:
'学费现金流'
,
...
...
@@ -328,7 +333,7 @@
emphasis
:
{
focus
:
'series'
},
data
:
this
.
currentYearExpenditure
data
:
this
.
currentYearExpenditure
,
}
]
};
...
...
@@ -341,12 +346,25 @@
this
.
settingYBYFlag
=
true
;
this
.
settingItem
=
item
;
},
updateSchoolingLists
(
val
){
if
(
Number
(
val
.
commonYears
)
!=
val
.
children
.
length
){
if
(
Number
(
val
.
commonYears
)
>
0
){
const
arr
=
[];
for
(
let
i
=
0
;
i
<
Number
(
val
.
commonYears
);
i
++
){
arr
.
push
({
text
:
`
${
i
+
1
}
年级`
,
value
:
`
${
val
.
value
}
-
${
i
+
1
}
`
,
tuition
:
null
})
}
val
.
children
=
arr
;
}
}
if
(
val
.
publicTuition
){
val
.
children
[
0
].
tuition
=
val
.
publicTuition
;
}
},
closeDialog
(){
this
.
settingYBYFlag
=
false
;
},
confirmOption
(){
this
.
settingYBYFlag
=
false
;
console
.
log
(
this
.
settingItem
)
},
objFlat
(
Data
){
// 对象数组拍平
...
...
@@ -426,13 +444,15 @@
for
(
let
i
=
0
;
i
<
result
.
length
;
i
++
){
this
.
currentYearExpenditure
.
push
(
Math
.
abs
(
result
[
i
][
'currentYearExpenditure'
]));
this
.
accountBalanceEnd
.
push
(
result
[
i
][
'accountBalanceEnd'
]);
this
.
xAxisLists
.
push
(
result
[
i
][
'planyear'
])
this
.
xAxisLists
.
push
(
result
[
i
][
'
educationNo'
]
?
this
.
getClassesInfo
(
result
[
i
][
'educationNo'
])
:
result
[
i
][
'
planyear'
])
}
setTimeout
(()
=>
{
this
.
drawLine
()},
0
)
}
else
{
this
.
currentYearExpenditure
=
[];
this
.
accountBalanceEnd
=
[];
this
.
xAxisLists
=
[];
common
.
errorDialog
(
2
,
res
[
'message'
]);
return
false
;
}
})
},
...
...
@@ -460,7 +480,6 @@
this
.
flatEduGradeLists
.
map
((
val
,
idx
)
=>
{
val
[
'educationNo'
]
=
idx
+
1
;
});
console
.
log
(
this
.
flatEduGradeLists
)
},
components
:{
follow
,
...
...
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