Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qr-consistency-vue3
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
刘怀志
qr-consistency-vue3
Commits
6eb712b9
Commit
6eb712b9
authored
Apr 18, 2025
by
祁正
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ccap项目管理-复制新增
parent
afb00fa5
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
6 deletions
+36
-6
list.js
src/api/CCAPProjectManagement/list.js
+10
-0
index.vue
src/views/controlPlan/baseConfig/ccapProjectManage/index.vue
+26
-6
No files found.
src/api/CCAPProjectManagement/list.js
View file @
6eb712b9
...
...
@@ -56,6 +56,16 @@ export function getBusinessExclude() {
method
:
'get'
})
}
// 获取所有事业部(除了奇瑞,除了列表里面的出现的在第一条数据的)-复制新增
export
function
getBusinessExclude2
()
{
return
request
({
url
:
'/control/ccapProjectManagement/getBusinessExclude2'
,
method
:
'get'
})
}
// 添加事业部
export
function
addBusinessUnit
(
data
)
{
return
request
({
...
...
src/views/controlPlan/baseConfig/ccapProjectManage/index.vue
View file @
6eb712b9
...
...
@@ -39,7 +39,7 @@
<
template
#
default=
"scope"
>
<div
style=
"display: flex;align-items: flex-start"
>
<el-button
type=
"text"
style=
"color: rgb(0,0,255)"
@
click=
"handleMaintain(scope.row)"
>
维护项目
</el-button>
<el-button
type=
"text"
style=
"color: rgb(255,153,0)"
v-if=
"scope.row.id === adminId"
@
click=
"
handleView
(scope.row)"
>
复制新增
</el-button>
<el-button
type=
"text"
style=
"color: rgb(255,153,0)"
v-if=
"scope.row.id === adminId"
@
click=
"
copeAdd
(scope.row)"
>
复制新增
</el-button>
<el-button
type=
"text"
v-if=
"scope.row.id === adminId"
@
click=
"addBusiness(scope.row)"
>
添加事业部
</el-button>
<el-button
type=
"text"
style=
"color: rgb(244,93,93)"
v-else=
"scope.row.id === adminId"
@
click=
"handleView(scope.row)"
>
删除
</el-button>
</div>
...
...
@@ -167,7 +167,7 @@
<div
style=
"width: 70%;margin-left: 15%;padding: 20px 0"
>
<el-form
:model=
"tableDialogForm"
ref=
"dialogForm2"
>
<el-form-item
:rules=
"[
{ required: true, message: '请选择事业部', trigger: '
change
' }
{ required: true, message: '请选择事业部', trigger: '
blur
' }
]"
label=
"事业部:"
prop=
"businessId"
>
<el-select
v-model=
"tableDialogForm.businessId"
...
...
@@ -176,7 +176,7 @@
>
<el-option
v-for=
"dict in businessListExclude"
:label=
"dict.business
_unit_n
ame"
:label=
"dict.business
UnitN
ame"
:value=
"dict.id"
/>
</el-select>
...
...
@@ -208,7 +208,8 @@ import {
deleteBatch
,
updateCcap
,
getBusinessExclude
,
addBusinessUnit
addBusinessUnit
,
getBusinessExclude2
}
from
"@/api/CCAPProjectManagement/list"
;
const
tableDialogForm
=
ref
({
...
...
@@ -243,7 +244,7 @@ const dialogRules = {
groupName
:
[{
required
:
true
,
message
:
'分组不能为空'
,
trigger
:
'blur'
}]
};
//所有事业部
(除了奇瑞,除了列表里面的出现的)
//所有事业部
const
businessListExclude
=
ref
([])
const
dialogForm
=
ref
({
...
...
@@ -285,6 +286,7 @@ function handleSelectionChange(arr){
}
}
//获取抽屉里面的表格数据
function
getDataProjectListById
()
{
getProjectListById
(
drawerQueryParams
.
value
).
then
(
res
=>
{
...
...
@@ -314,10 +316,20 @@ function addBusiness(row){
tableDialogTitle
.
value
=
'添加事业部'
tableDialogVisible
.
value
=
true
tableDialogForm
.
value
.
id
=
row
.
id
getBusinessListExclude
();
}
//获取所有事业部(除了奇瑞,除了列表里面的出现的)
function
getBusinessListExclude
(){
getBusinessExclude
().
then
(
res
=>
{
console
.
log
(
"添加事业部"
,
res
)
businessListExclude
.
value
=
res
.
data
})
}
// //获取所有事业部(除了奇瑞,除了列表里面的出现的在第一条数据的)-复制新增
function
getBusinessListExclude2
(){
getBusinessExclude2
().
then
(
res
=>
{
console
.
log
(
"复制新增"
,
res
)
businessListExclude
.
value
=
res
.
data
})
}
...
...
@@ -420,6 +432,14 @@ function dialogSave() {
}
//复制新增
function
copeAdd
(
row
){
tableDialogTitle
.
value
=
'复制新增'
tableDialogVisible
.
value
=
true
tableDialogForm
.
value
.
id
=
row
.
id
getBusinessListExclude2
()
}
//对话框里面的取消
function
dialogCencal
()
{
dialogForm
.
value
.
project
=
null
;
...
...
@@ -528,7 +548,7 @@ function handleExport() {
getList
();
getBusinessList
();
getBusinessListExclude
();
</
script
>
<
style
scoped
lang=
"scss"
>
...
...
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