Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
Y
yn-science-front
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
徐俊
yn-science-front
Commits
6ca4886f
Commit
6ca4886f
authored
Dec 17, 2024
by
wangxl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
222222
parent
6e842e19
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
30 deletions
+24
-30
index.js
src/api/index.js
+3
-0
projectCreate.vue
src/views/report/project/components/edit/projectCreate.vue
+21
-30
projectEdit.vue
src/views/report/project/components/edit/projectEdit.vue
+0
-0
No files found.
src/api/index.js
View file @
6ca4886f
...
@@ -417,6 +417,9 @@ export default {
...
@@ -417,6 +417,9 @@ export default {
save
(
params
)
{
save
(
params
)
{
return
fetch
(
`/v1/science-admin/com-project/save`
,
params
,
'post'
,
'json'
)
return
fetch
(
`/v1/science-admin/com-project/save`
,
params
,
'post'
,
'json'
)
},
},
saveByStep
(
params
)
{
return
fetch
(
`/v1/science-admin/com-project/saveByStep`
,
params
,
'post'
,
'json'
)
},
updateUnit
(
params
)
{
updateUnit
(
params
)
{
return
fetch
(
`/v1/science-admin/com-project/updateUnit`
,
params
,
'post'
,
'json'
)
return
fetch
(
`/v1/science-admin/com-project/updateUnit`
,
params
,
'post'
,
'json'
)
},
},
...
...
src/views/report/project/components/edit/projectCreate.vue
View file @
6ca4886f
...
@@ -4,18 +4,17 @@
...
@@ -4,18 +4,17 @@
<a-spin
:spinning=
"loading"
style=
"width: 100%;height: 100%;"
>
<a-spin
:spinning=
"loading"
style=
"width: 100%;height: 100%;"
>
<div
class=
"page-steps"
>
<div
class=
"page-steps"
>
<a-steps
size=
"small"
:current=
"current"
>
<a-steps
size=
"small"
:current=
"current"
>
<a-step
:status=
"item.status"
v-for=
"(item,index) in
completeStatus"
:key=
"index+'completeStatus
'"
:title=
"item.title"
/>
<a-step
:status=
"item.status"
v-for=
"(item,index) in
stepsArray"
:key=
"index+'stepsArray
'"
:title=
"item.title"
/>
</a-steps>
</a-steps>
</div>
</div>
<div
class=
"page-content"
>
<div
class=
"page-content"
>
<project-edit
v-model=
"value"
@
close=
"closeWindow"
@
load=
"onLoad"
:showStatus
.
sync=
"showStatus"
ref=
"projCreate"
v-if=
"projType"
></project-edit>
<project-edit
v-model=
"value"
@
close=
"closeWindow"
@
load=
"onLoad"
@
next=
"changeSteps"
:stepsArray
.
sync=
"stepsArray"
ref=
"projCreate"
></project-edit>
<project-edit-key
v-model=
"value"
@
close=
"closeWindow"
@
load=
"onLoad"
:showStatus
.
sync=
"showStatus"
ref=
"projCreate"
v-else
></project-edit-key>
</div>
</div>
<div
class=
"page-footer"
>
<div
class=
"page-footer"
>
<a-button
v-if=
"currSteps > 0"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"prev"
>
上一步
</a-button>
<a-button
v-if=
"currSteps > 0"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"prev"
>
上一步
</a-button>
<a-button
style=
"margin-left: 40px"
type=
"primary"
@
click=
"save"
>
保 存
</a-button>
<a-button
style=
"margin-left: 40px"
type=
"primary"
@
click=
"save"
>
保 存
</a-button>
<a-button
v-if=
"currSteps
<
completeStatus
.
length
-
1
"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"next"
>
下一步
</a-button>
<a-button
v-if=
"currSteps
<
stepsArray
.
length
-
1
"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"next"
>
下一步
</a-button>
<a-button
v-if=
"currSteps ==
completeStatus
.length - 1"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"submit"
>
完成填写
</a-button>
<a-button
v-if=
"currSteps ==
stepsArray
.length - 1"
style=
"margin-left: 40px"
type=
"primary"
@
click=
"submit"
>
完成填写
</a-button>
</div>
</div>
</a-spin>
</a-spin>
</div>
</div>
...
@@ -36,15 +35,14 @@ export default {
...
@@ -36,15 +35,14 @@ export default {
projType
:
getType
()
==
"1"
,
projType
:
getType
()
==
"1"
,
current
:
10
,
current
:
10
,
currSteps
:
0
,
currSteps
:
0
,
completeStatus
:
[
stepsArray
:
[
{
status
:
"
"
,
title
:
'基本信息'
},
{
status
:
"
process"
,
title
:
'基本信息'
,
showStatus
:
true
},
{
status
:
"
"
,
title
:
'项目组成员及单位'
},
{
status
:
"
wait"
,
title
:
'项目组成员及单位'
,
showStatus
:
false
},
{
status
:
"
"
,
title
:
'经费预算及设备明细'
},
{
status
:
"
wait"
,
title
:
'经费预算及设备明细'
,
showStatus
:
false
},
{
status
:
"
"
,
title
:
'阶段目标及课题设置'
},
{
status
:
"
wait"
,
title
:
'阶段目标及课题设置'
,
showStatus
:
false
},
{
status
:
"
"
,
title
:
'绩效指标'
},
{
status
:
"
wait"
,
title
:
'绩效指标'
,
showStatus
:
false
},
{
status
:
"
"
,
title
:
'附件'
}
{
status
:
"
wait"
,
title
:
'附件'
,
showStatus
:
false
}
],
],
showStatus
:
[
true
,
false
,
false
,
false
,
false
,
false
],
stepStyle
:
{
stepStyle
:
{
marginBottom
:
'60px'
,
marginBottom
:
'60px'
,
boxShadow
:
'0px -1px 0 0 #e8e8e8 inset'
,
boxShadow
:
'0px -1px 0 0 #e8e8e8 inset'
,
...
@@ -66,35 +64,28 @@ export default {
...
@@ -66,35 +64,28 @@ export default {
debugger
debugger
this
.
currSteps
=
e
this
.
currSteps
=
e
this
.
changeSteps
(
this
.
currSteps
)
this
.
changeSteps
(
this
.
currSteps
)
console
.
log
(
this
.
currSteps
,
'stepsChange'
)
},
},
next
()
{
next
()
{
this
.
currSteps
++
;
this
.
$refs
.
projCreate
.
submit
(
this
.
currSteps
,
true
)
this
.
changeSteps
(
this
.
currSteps
)
console
.
log
(
this
.
currSteps
,
'next'
)
},
},
prev
()
{
prev
()
{
this
.
currSteps
--
;
this
.
currSteps
--
;
this
.
changeSteps
(
this
.
currSteps
)
this
.
changeSteps
(
this
.
currSteps
)
console
.
log
(
this
.
currSteps
,
'prev'
)
},
},
changeSteps
(
e
)
{
changeSteps
(
e
)
{
var
clone
=
[].
concat
(
this
.
completeStatus
)
this
.
currSteps
=
e
clone
[
e
].
status
=
"process"
var
clone
=
[].
concat
(
this
.
stepsArray
)
this
.
completeStatus
=
clone
clone
.
forEach
(
e
=>
{
this
.
changeShowStatus
(
e
)
e
.
showStatus
=
false
},
})
changeShowStatus
(
e
)
{
clone
[
e
].
showStatus
=
true
;
var
clone
=
[
false
,
false
,
false
,
false
,
false
,
false
]
this
.
stepsArray
=
clone
clone
[
e
]
=
true
;
this
.
showStatus
=
clone
console
.
log
(
this
.
showStatus
)
},
},
save
()
{
save
()
{
this
.
$refs
.
projCreate
.
save
()
this
.
$refs
.
projCreate
.
save
(
this
.
currSteps
)
},
},
submit
()
{
submit
()
{
this
.
$refs
.
projCreate
.
submit
()
this
.
$refs
.
projCreate
.
submit
(
this
.
currSteps
,
false
)
},
},
closeWindow
(
value
)
{
closeWindow
(
value
)
{
this
.
$emit
(
'close'
,
value
)
this
.
$emit
(
'close'
,
value
)
...
...
src/views/report/project/components/edit/projectEdit.vue
View file @
6ca4886f
This diff is collapsed.
Click to expand it.
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