Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
web-project
Project
Project
Details
Activity
Releases
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
紫光云
web-project
Commits
691f194b
Commit
691f194b
authored
Aug 30, 2024
by
zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
style: (月度工程资金计划/上报月度资金计划/创建月度资金计划)改为树形控件形式
parent
fdaa5e30
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
14 deletions
+40
-14
CollapseContainer.vue
src/components/Container/src/collapse/CollapseContainer.vue
+3
-2
CollapseHeader.vue
src/components/Container/src/collapse/CollapseHeader.vue
+12
-5
monthlyPlanEdit.vue
src/views/monthlyPlan/monthlyPlanEdit/monthlyPlanEdit.vue
+25
-7
No files found.
src/components/Container/src/collapse/CollapseContainer.vue
View file @
691f194b
...
...
@@ -43,7 +43,7 @@
setup
(
props
,
{
expose
,
slots
})
{
const
{
prefixCls
}
=
useDesign
(
'collapse-container'
);
const
show
=
ref
(
true
);
const
show
=
ref
(
false
);
// 定义初始是否展开
const
handleExpand
=
(
val
:
boolean
)
=>
{
show
.
value
=
isNil
(
val
)
?
!
show
.
value
:
val
;
...
...
@@ -111,7 +111,8 @@
display: flex;
flex: 1;
align-items: center;
justify-content: flex-end;
justify-content: space-between;
margin-left: 10px;
text-align: right;
}
}
...
...
src/components/Container/src/collapse/CollapseHeader.vue
View file @
691f194b
...
...
@@ -26,16 +26,23 @@
const
_prefixCls
=
computed
(()
=>
props
.
prefixCls
||
unref
(
prefixCls
));
return
()
=>
(
<
div
class
=
{[
`
${
unref
(
_prefixCls
)}
__header px-2 py-5`
,
attrs
.
class
]}
>
<
BasicTitle
helpMessage
=
{
props
.
helpMessage
}
normal
>
<
BasicTitle
onClick
=
{()
=>
emit
(
'expand'
)}
helpMessage
=
{
props
.
helpMessage
}
normal
>
{
slots
.
title
?.()
||
props
.
title
}
<
/BasicTitle
>
<
div
class
=
{
`
${
unref
(
_prefixCls
)}
__action`
}
>
{
slots
.
action
?
slots
.
action
({
expand
:
props
.
show
,
onClick
:
()
=>
emit
(
'expand'
)
})
:
props
.
canExpand
&&
(
{
props
.
canExpand
&&
(
<
BasicArrow
up
expand
=
{
props
.
show
}
onClick
=
{()
=>
emit
(
'expand'
)}
/
>
)}
)
}
{
slots
.
action
?
slots
.
action
({
expand
:
props
.
show
,
onClick
:
()
=>
emit
(
'expand'
)
})
:
props
.
canExpand
}
<
/div
>
<
/div
>
);
...
...
src/views/monthlyPlan/monthlyPlanEdit/monthlyPlanEdit.vue
View file @
691f194b
...
...
@@ -13,8 +13,11 @@
<a-button
type=
"default"
@
click=
"router.back()"
>
返回
</a-button>
</
template
>
<!-- page页 -->
<PageCard
v-for=
"(item, index) in tabsFormSchema"
:key=
"index"
:title=
"item.name"
>
<
template
#
right
>
<CollapseContainer
v-for=
"(item, index) in tabsFormSchema"
:key=
"index"
>
<
template
#
title
>
<span
class=
"projectName"
>
{{
item
.
name
}}
</span>
</
template
>
<
template
#
action
>
<a-button
v-if=
"!disabled"
type=
"text"
...
...
@@ -26,14 +29,18 @@
</
template
>
<BasicForm
:loading=
"loading"
@
register=
"item.Form[0]"
/>
<!-- 左上角为项目名 -->
<
PageCard
<
CollapseContainer
v-for=
"(content, key) in item.list"
:key=
"key"
class=
"subCard"
:title=
"content.name"
>
<
template
#
title
>
<span
class=
"contractName"
>
{{
content
.
name
}}
</span>
</
template
>
<!-- 右上角的删除按钮 -->
<
template
#
right
>
<a-button
v-if=
"!disabled"
type=
"text"
...
...
@@ -44,8 +51,8 @@
>
</
template
>
<BasicForm
:loading=
"loading"
@
register=
"content.form"
/>
</
PageCard
>
</
PageCard
>
</
CollapseContainer
>
</
CollapseContainer
>
<!--导入或新增按钮-->
<a-button
type=
"dashed"
@
click=
"add"
preIcon=
"ei:plus"
v-if=
"!disabled"
>
从合同中导入
...
...
@@ -83,6 +90,8 @@
import
{
useRoute
}
from
'vue-router'
;
import
{
monthListByMonthYear
}
from
'@/api/project/detail/month'
;
import
{
forEach
}
from
'@/utils/helper/treeHelper'
;
import
CollapseContainer
from
'@/components/Container/src/collapse/CollapseContainer.vue'
;
import
{
template
}
from
'xe-utils'
;
//历史记录是否可查
const
historyData
=
ref
(
true
);
...
...
@@ -366,7 +375,6 @@
for
(
let
t
=
0
;
t
<
item
.
list
.
length
;
t
++
)
{
let
content
=
tabsFormSchema
[
i
].
list
[
t
];
let
contentRes
=
await
getFormData
(
content
.
form
[
1
]);
console
.
log
(
contentRes
);
formData
.
value
.
engineerConList
[
i
].
conList
[
t
]
=
deepMerge
(
formData
.
value
.
engineerConList
[
i
].
conList
[
t
],
contentRes
,
...
...
@@ -378,11 +386,11 @@
formData
.
value
.
fundId
=
tenderId
.
value
;
console
.
log
(
unref
(
formData
));
let
res
=
isUpdate
.
value
?
await
updateItem
(
unref
(
formData
))
:
await
addItem
(
unref
(
formData
));
addItemData
.
operateType
=
operateType
.
update
;
addItemData
.
businessId
=
routeId
.
value
;
addItemData
.
businessType
=
'月度工程资金计划'
;
const
showDatem
=
await
addItemApi
(
addItemData
);
console
.
log
(
showDatem
,
'记录添加成功'
);
loadingRef
.
value
=
true
;
...
...
@@ -410,4 +418,14 @@
.subCard
{
border
:
1px
solid
#e8eaec
;
}
.projectName
{
border-left
:
blue
solid
6px
;
padding-left
:
10px
;
font-weight
:
bold
;
}
.contractName
{
border-left
:
red
solid
6px
;
padding-left
:
10px
;
font-weight
:
bold
;
}
</
style
>
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