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
d663358f
Commit
d663358f
authored
Apr 16, 2025
by
ZhangRunSong
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://gitlab.91isoft.com:90/liuhuaizhi/qr-consistency-vue3
into dev
parents
5195ec4a
4ab52586
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
968 additions
and
89 deletions
+968
-89
list.js
src/api/CCAPProjectManagement/list.js
+19
-0
baseIntlPartTemplate.js
src/api/control/baseIntlPartTemplate.js
+60
-0
baseIntlPartTemplateDetail.js
src/api/control/baseIntlPartTemplateDetail.js
+52
-0
index.vue
src/views/baseData/criticalPartsList/template/index.vue
+208
-0
index.vue
...views/baseData/criticalPartsList/templateDetail/index.vue
+334
-0
info.vue
src/views/baseData/marketRegulations/info.vue
+23
-59
index.vue
...ws/controlPlan/baseConfig/CCAPProjectManagement/index.vue
+271
-0
index.vue
src/views/system/user/index.vue
+1
-30
No files found.
src/api/CCAPProjectManagement/list.js
0 → 100644
View file @
d663358f
import
request
from
'@/utils/request'
// 查询列表
export
function
getDataList
(
query
)
{
return
request
({
url
:
'/control/ccapProjectManagement/getDataList'
,
method
:
'get'
,
params
:
query
})
}
// 获取所有事业部列表
export
function
getAllBusinessUnitList
()
{
return
request
({
url
:
'/control/ccapProjectManagement/getAllBusinessUnitList'
,
method
:
'get'
})
}
src/api/control/baseIntlPartTemplate.js
0 → 100644
View file @
d663358f
import
request
from
'@/utils/request.js'
// 查询国际关键零部件模版列表
export
function
listTemplate
(
query
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询国际关键零部件模版详细
export
function
getTemplate
(
id
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate/'
+
id
,
method
:
'get'
})
}
// 新增国际关键零部件模版
export
function
addTemplate
(
data
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate'
,
method
:
'post'
,
data
:
data
})
}
// 修改国际关键零部件模版
export
function
updateTemplate
(
data
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate'
,
method
:
'put'
,
data
:
data
})
}
// 删除国际关键零部件模版
export
function
delTemplate
(
id
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate/'
+
id
,
method
:
'delete'
})
}
// 逻辑删除国际关键零部件模版
export
function
delLogicTemplate
(
id
)
{
return
request
({
url
:
'/control/baseIntlPartTemplate/logicDelete/'
+
id
,
method
:
'delete'
})
}
// 获取全部事业部
export
function
getAllUnit
()
{
return
request
({
url
:
'/control/baseIntlPartTemplate/getAllUnit'
,
method
:
'get'
})
}
src/api/control/baseIntlPartTemplateDetail.js
0 → 100644
View file @
d663358f
import
request
from
'@/utils/request'
// 查询国际关键零部件模版详情列表
export
function
listDetail
(
query
)
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询国际关键零部件模版详情详细
export
function
getDetail
(
id
)
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail/'
+
id
,
method
:
'get'
})
}
// 新增国际关键零部件模版详情
export
function
addDetail
(
data
)
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail'
,
method
:
'post'
,
data
:
data
})
}
// 修改国际关键零部件模版详情
export
function
updateDetail
(
data
)
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail'
,
method
:
'put'
,
data
:
data
})
}
// 删除国际关键零部件模版详情
export
function
delDetail
(
id
)
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail/'
+
id
,
method
:
'delete'
})
}
// 获取市场法规清单的适用市场
export
function
getMarket
()
{
return
request
({
url
:
'/control/baseIntlPartTemplateDetail/getApplicableMarket'
,
method
:
'get'
})
}
src/views/baseData/criticalPartsList/template/index.vue
0 → 100644
View file @
d663358f
<
template
>
<div
class=
"app-container"
>
<el-table
v-loading=
"loading"
:data=
"templateList"
>
<el-table-column
label=
"序号"
type=
"index"
align=
"center"
width=
"55"
/>
<el-table-column
label=
"事业部"
prop=
"divisionCn"
align=
"center"
>
<template
#
default=
"scope"
>
{{
Object
.
values
(
JSON
.
parse
(
scope
.
row
.
divisionCn
)).
join
(
'、'
)
}}
</
template
>
</el-table-column>
<el-table-column
label=
"创建人"
prop=
"createByName"
align=
"center"
/>
<el-table-column
label=
"创建时间"
prop=
"createTime"
align=
"center"
/>
<el-table-column
label=
"更新人"
prop=
"updateByName"
align=
"center"
/>
<el-table-column
label=
"更新时间"
prop=
"updateTime"
align=
"center"
/>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
width=
"300"
>
<
template
#
default=
"scope"
>
<el-button
link
type=
"primary"
@
click=
"handleTemplateDetailView(scope.row)"
>
维护模板内容
</el-button>
<el-button
link
type=
"warning"
@
click=
"handleCopyAdd"
v-show=
"scope.row.isDefault === 1"
>
复制新增
</el-button>
<el-button
link
type=
"primary"
@
click=
"handleAddDivision"
v-show=
"scope.row.isDefault === 1"
>
添加事业部
</el-button>
<el-button
link
type=
"danger"
@
click=
"handleDelete(scope.row)"
v-show=
"scope.row.isDefault === 0"
>
删除
</el-button>
</
template
>
</el-table-column>
</el-table>
<pagination
v-show=
"total>0"
:total=
"total"
v-model:page=
"queryParams.pageNum"
v-model:limit=
"queryParams.pageSize"
@
pagination=
"getList"
/>
<!-- 复制新增对话框 -->
<el-dialog
:title=
"title"
v-model=
"open"
width=
"339px"
align-center
>
<el-form
ref=
"templateRef"
:model=
"form"
label-width=
"80px"
>
<el-form-item
label=
"事业部"
prop=
"division"
>
<el-select
v-model=
"form.division"
placeholder=
"请选择"
>
<el-option
v-for=
"item in divisionOptions"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
</el-form>
<
template
#
footer
>
<div
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
</div>
</
template
>
</el-dialog>
<!-- 添加事业部对话框 -->
<el-dialog
:title=
"title"
v-model=
"open2"
width=
"500px"
append-to-body
>
<el-form
ref=
"templateRef"
:model=
"form"
:rules=
"rules"
label-width=
"80px"
>
<el-form-item
label=
"事业部"
prop=
"division"
>
<el-select
v-model=
"form.division"
placeholder=
"请选择"
>
<el-option
v-for=
"item in divisionOptions"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
</el-form>
<
template
#
footer
>
<div
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
</div>
</
template
>
</el-dialog>
</div>
</template>
<
script
setup
>
import
{
listTemplate
,
addTemplate
,
getAllUnit
}
from
"@/api/control/baseIntlPartTemplate.js"
;
const
{
proxy
}
=
getCurrentInstance
();
const
templateList
=
ref
([]);
const
open
=
ref
(
false
);
const
open2
=
ref
(
false
);
const
loading
=
ref
(
true
);
const
showSearch
=
ref
(
true
);
const
total
=
ref
(
0
);
const
title
=
ref
(
""
);
const
divisionOptions
=
ref
([]);
const
data
=
reactive
({
form
:
{},
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
},
rules
:
{
division
:
[
// 事业部不能重复 事业部存储为josn
{
validator
:
(
rule
,
value
,
callback
)
=>
{
for
(
let
i
=
0
;
i
<
templateList
.
value
.
length
;
i
++
)
{
if
(
templateList
.
value
[
i
].
division
===
value
)
{
callback
(
new
Error
(
"该事业部已存在"
));
return
;
}
}
callback
();
},
trigger
:
"blur"
}
]
}
});
const
{
queryParams
,
form
,
rules
}
=
toRefs
(
data
);
/** 查询国际关键零部件模版列表 */
function
getList
()
{
loading
.
value
=
true
;
listTemplate
(
queryParams
.
value
).
then
(
response
=>
{
templateList
.
value
=
response
.
rows
;
total
.
value
=
response
.
total
;
loading
.
value
=
false
;
});
}
// 获取事业部下拉框
function
getDivisionList
()
{
getAllUnit
().
then
(
response
=>
{
divisionOptions
.
value
=
response
.
data
.
map
(
item
=>
{
return
{
value
:
item
.
id
,
label
:
item
.
businessUnitName
}
})
})
}
// 维护模板内容
function
handleTemplateDetailView
(
row
)
{
proxy
.
$router
.
push
({
path
:
'/baseData/criticalPartsList/templateDetail'
,
query
:
{
id
:
row
.
id
,
divisionCn
:
row
.
divisionCn
,
isDefault
:
row
.
isDefault
}
})
}
// 复制新增
function
handleCopyAdd
()
{
// 候选值为奇瑞之外且未在主列表单独列出的事业部
getDivisionList
();
open
.
value
=
true
;
title
.
value
=
"复制新增"
;
}
// 添加事业部
function
handleAddDivision
()
{
// 候选值为不在主列表中的事业部
getDivisionList
();
open2
.
value
=
true
;
title
.
value
=
"添加事业部"
;
}
// 取消按钮
function
cancel
()
{
open
.
value
=
false
;
reset
();
}
// 表单重置
function
reset
()
{
form
.
value
=
{
id
:
null
,
division
:
null
,
divisionCn
:
null
};
proxy
.
resetForm
(
"templateRef"
);
}
/** 提交按钮 */
function
submitForm
()
{
proxy
.
$refs
[
"templateRef"
].
validate
(
valid
=>
{
if
(
valid
)
{
addTemplate
(
form
.
value
).
then
(
response
=>
{
if
(
response
.
code
===
200
){
proxy
.
$modal
.
msgSuccess
(
"新增成功"
);
open
.
value
=
false
;
open2
.
value
=
false
;
getList
();
}
else
{
proxy
.
$modal
.
msgError
(
response
.
msg
)
}
});
}
});
}
/** 逻辑删除按钮操作 */
function
handleDelete
(
row
)
{
const
_ids
=
row
.
id
;
proxy
.
$modal
.
confirm
(
'是否确认删除事业部为"'
+
row
.
divisionCn
+
'"的数据项?'
).
then
(
function
()
{
return
delLogicTemplate
(
_ids
);
}).
then
(()
=>
{
getList
();
proxy
.
$modal
.
msgSuccess
(
"删除成功"
);
}).
catch
(()
=>
{});
}
getList
();
</
script
>
src/views/baseData/criticalPartsList/templateDetail/index.vue
0 → 100644
View file @
d663358f
This diff is collapsed.
Click to expand it.
src/views/baseData/marketRegulations/info.vue
View file @
d663358f
...
...
@@ -41,14 +41,9 @@
</el-row>
<el-row>
<el-col
:span=
"2"
>
<span
>
密级
</span>
</el-col>
<el-col
:span=
"2"
>
<span
>
{{
dataOBj
.
securityLevel
}}
</span>
</el-col>
<el-col
:offset=
"5"
:span=
"2"
>
<el-col
:span=
"2"
>
<span
>
作者
</span>
</el-col>
<el-col
:span=
"2"
>
...
...
@@ -64,12 +59,7 @@
<span
>
{{
dataOBj
.
releaseDate
}}
</span>
</el-col>
<el-col
:offset=
"5"
:span=
"2"
>
<span
>
附件
</span>
</el-col>
<el-col
:span=
"2"
>
<span
>
{{
dataOBj
.
attachment
||
'---'
}}
</span>
</el-col>
</el-row>
<el-row>
...
...
@@ -88,9 +78,9 @@
<div
>
<div
class=
"baseInfoTitle"
>
市场法规清单
</div>
<el-form
v-model=
"queryParams"
ref=
"queryRef"
:inline=
"true"
label-width=
"70px"
>
<el-form-item
label=
"标准编号"
prop=
"standard
Code
"
>
<el-form-item
label=
"标准编号"
prop=
"standard
Number
"
>
<el-input
v-model=
"queryParams.standard
Code
"
v-model=
"queryParams.standard
Number
"
placeholder=
"请输入适标准编号"
clearable
/>
...
...
@@ -114,9 +104,9 @@
<el-table
:data=
"tableList"
>
<el-table-column
type=
"index"
width=
"55"
align=
"center"
label=
"序号"
/>
<el-table-column
label=
"类型"
align=
"center"
prop=
"standardType"
/>
<el-table-column
label=
"标准编号"
align=
"center"
prop=
"standard
Code
"
/>
<el-table-column
label=
"标准编号"
align=
"center"
prop=
"standard
Number
"
/>
<el-table-column
label=
"标准名称"
align=
"center"
prop=
"standardName"
/>
<el-table-column
label=
"标准英文名称"
align=
"center"
prop=
"standardEnglishName"
width=
"130"
/>
<el-table-column
show-overflow-tooltip
label=
"标准英文名称"
align=
"center"
prop=
"standardEnglishName"
width=
"130"
/>
<el-table-column
label=
"等效法规"
align=
"center"
prop=
"equivalentRegulation"
>
<template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
equivalentRegulation
||
'——'
}}
</span>
...
...
@@ -128,46 +118,28 @@
</
template
>
</el-table-column>
<el-table-column
label=
"主控部门"
align=
"center"
prop=
"author"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
author
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"主控部门专业模块"
align=
"center"
prop=
"listStatus"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"关联部门"
align=
"center"
prop=
"listStatus"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"关联部门专业模块"
align=
"center"
prop=
"listStatus"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"新认证车实施日期"
align=
"center"
prop=
"newCertificationCarDate"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
new
CertificationCar
Date
||
'——'
}}
</span>
<span>
{{
scope
.
row
.
new
AuthImpl
Date
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"新生产车实施日期"
align=
"center"
prop=
"newProductionCarDate"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
newProduct
ionCar
Date
||
'——'
}}
</span>
<span>
{{
scope
.
row
.
newProduct
Impl
Date
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"注册日期"
align=
"center"
prop=
"registrationDate"
>
<el-table-column
label=
"注册日期"
align=
"center"
prop=
"registrationDate"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
registrationDate
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"适用市场"
align=
"center"
prop=
"
listStatus
"
>
<el-table-column
label=
"适用市场"
align=
"center"
prop=
"
country
"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
<span>
{{
scope
.
row
.
country
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"适用车型"
align=
"center"
prop=
"applicableModel"
>
...
...
@@ -180,32 +152,24 @@
<span>
{{
scope
.
row
.
powerType
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"认证对象"
align=
"center"
prop=
"certificationTarget"
>
<el-table-column
label=
"认证对象"
align=
"center"
prop=
"certificationTarget"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
certificationTarget
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"认证交付物"
align=
"center"
prop=
"
listStatus"
width=
"13
0"
>
<el-table-column
label=
"认证交付物"
align=
"center"
prop=
"
certifyTheDeliverables"
width=
"14
0"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatu
s
||
'——'
}}
</span>
<span>
{{
scope
.
row
.
certifyTheDeliverable
s
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"批量限制"
align=
"center"
prop=
"
listStatus"
>
<el-table-column
label=
"批量限制"
align=
"center"
prop=
"
batchLimit"
width=
"140"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
<span>
{{
scope
.
row
.
batchLimit
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"自动驾驶等级"
align=
"center"
prop=
"listStatus"
width=
"130"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"要求类型"
align=
"center"
prop=
"listStatus"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
listStatus
||
'——'
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"备注"
align=
"center"
prop=
"remark"
>
<el-table-column
label=
"备注"
show-overflow-tooltip
align=
"center"
prop=
"remark"
>
<
template
#
default=
"scope"
>
<span>
{{
scope
.
row
.
remark
||
'——'
}}
</span>
</
template
>
...
...
@@ -251,7 +215,7 @@ function handleQuery() {
/** 重置按钮操作 */
function
resetQuery
()
{
queryParams
.
value
.
standard
Code
=
null
queryParams
.
value
.
standard
Number
=
null
queryParams
.
value
.
standardName
=
null
handleQuery
();
...
...
src/views/controlPlan/baseConfig/CCAPProjectManagement/index.vue
0 → 100644
View file @
d663358f
<
template
>
<div
class=
"app-container"
>
<el-form
v-model=
"queryParams"
ref=
"queryRef"
:inline=
"true"
v-show=
"showSearch"
label-width=
"70px"
>
<el-form-item
label=
"事业部:"
prop=
"status"
>
<el-select
v-model=
"queryParams.businessUnitId"
placeholder=
"请选择"
clearable
style=
"width: 200px"
>
<el-option
v-for=
"dict in businessList"
:label=
"dict.businessUnitName"
:value=
"dict.id"
/>
</el-select>
</el-form-item>
<el-form-item
>
<el-button
type=
"primary"
icon=
"Search"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"Refresh"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<el-table
:data=
"tableList"
>
<el-table-column
type=
"index"
width=
"55"
align=
"center"
label=
"序号"
/>
<el-table-column
label=
"事业部"
align=
"center"
prop=
"applicableBrand"
/>
<el-table-column
label=
"项目情况"
align=
"center"
prop=
"listCode"
>
<template
#
default=
"scope"
>
<span
style=
"text-decoration: underline;text-decoration-color: #2f9bfe;color: #2f9bfe;cursor: pointer"
>
共
{{
scope
.
row
.
relatedCount
}}
个
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"创建人"
align=
"center"
prop=
"createUserName"
/>
<el-table-column
label=
"创建时间"
align=
"center"
prop=
"createTime"
/>
<el-table-column
label=
"更新人"
align=
"center"
prop=
"updateUserName"
/>
<el-table-column
label=
"更新时间"
align=
"center"
prop=
"updateTime"
width=
"180"
>
</el-table-column>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
>
<
template
#
default=
"scope"
>
<div
style=
"display: flex;align-items: flex-start"
>
<el-button
type=
"text"
style=
"color: rgb(0,0,255)"
@
click=
"handleView(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"
v-if=
"scope.row.id === adminId"
@
click=
"handleView(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>
</
template
>
</el-table-column>
</el-table>
<pagination
v-show=
"total>0"
:total=
"total"
v-model:page=
"queryParams.pageNum"
v-model:limit=
"queryParams.pageSize"
@
pagination=
"getList"
/>
<!-- 抽屉-->
<el-drawer
v-model=
"drawer2"
size=
'40%'
>
<
template
#
header
>
<div
style=
"font-weight: bold;font-size: 14px"
>
维护项目(奇瑞、星途、智界)
</div>
</
template
>
<
template
#
default
>
<div
style=
"display: flex;justify-content: space-between"
>
<el-form
class=
"drawer-form"
v-model=
"drawerQueryParams"
ref=
"queryRef"
:inline=
"true"
v-show=
"showSearch"
>
<el-form-item
label=
"项目:"
prop=
"status"
>
<el-input
v-model=
"drawerQueryParams.project"
style=
"width: 110px"
placeholder=
"请输入"
/>
</el-form-item>
<el-form-item
label=
"分组:"
prop=
"status"
>
<el-select
v-model=
"queryParams.businessUnitId"
placeholder=
"请选择"
clearable
style=
"width: 125px"
>
<el-option
v-for=
"dict in groupList"
:label=
"dict"
:value=
"dict"
/>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
@
click=
"handleQuery"
>
查询
</el-button>
<el-button
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<div
class=
"top-btn"
>
<el-button
type=
"primary"
plain
@
click=
"handleQuery"
>
新增
</el-button>
<el-button
type=
"danger"
plain
@
click=
"resetQuery"
>
批量删除
</el-button>
</div>
</div>
<el-table
border
style=
"margin-top: 10px"
:data=
"drawer2TableList"
>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
type=
"index"
width=
"55"
align=
"center"
label=
"序号"
/>
<el-table-column
label=
"项目"
align=
"center"
prop=
"applicableBrand"
/>
<el-table-column
label=
"分组"
align=
"center"
prop=
"createUserName"
/>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
>
<template
#
default=
"scope"
>
<div
style=
"display: flex;align-items: flex-start"
>
<el-button
type=
"text"
style=
"color: rgb(0,0,255)"
@
click=
"handleView(scope.row)"
>
编辑
</el-button>
<el-button
type=
"text"
style=
"color: rgb(244,93,93)"
@
click=
"handleView(scope.row)"
>
删除
</el-button>
</div>
</
template
>
</el-table-column>
</el-table>
</template>
<
template
#
footer
>
<div
style=
"flex: auto"
>
<el-button
@
click=
"cancelClick"
>
取消
</el-button>
<el-button
type=
"primary"
@
click=
"confirmClick"
>
保存
</el-button>
</div>
</
template
>
</el-drawer>
</div>
</template>
<
script
setup
>
import
{
getDataList
,
getAllBusinessUnitList
}
from
"@/api/CCAPProjectManagement/list"
;
const
{
proxy
}
=
getCurrentInstance
();
const
tableList
=
ref
([]);
const
drawer2
=
ref
(
false
)
//第一条数据id
const
adminId
=
'12321'
import
{
useRouter
}
from
'vue-router'
;
const
businessList
=
ref
([])
const
drawer2TableList
=
ref
([])
const
router
=
useRouter
();
const
open
=
ref
(
false
);
const
loading
=
ref
(
true
);
const
showSearch
=
ref
(
true
);
const
ids
=
ref
([]);
const
single
=
ref
(
true
);
const
multiple
=
ref
(
true
);
const
total
=
ref
(
0
);
const
title
=
ref
(
""
);
const
queryParams
=
ref
({
pageNum
:
1
,
pageSize
:
10
,
businessUnitId
:
null
})
const
drawerQueryParams
=
ref
({
})
const
groupList
=
ref
([
'制造'
,
'质管'
])
const
data
=
reactive
({
form
:
{},
rules
:
{}
});
const
{
form
,
rules
}
=
toRefs
(
data
);
function
getList
(){
getDataList
(
queryParams
.
value
).
then
(
res
=>
{
tableList
.
value
=
res
.
rows
.
sort
((
a
,
b
)
=>
{
if
(
a
.
id
===
adminId
)
return
1
else
if
(
b
.
id
===
adminId
)
return
1
})
total
.
value
=
res
.
total
})
}
function
getBusinessList
(){
getAllBusinessUnitList
().
then
(
res
=>
{
console
.
log
(
res
)
businessList
.
value
=
res
.
data
})
}
// 取消按钮
function
cancelClick
()
{
drawer2
.
value
=
false
;
reset
();
}
// 表单重置
function
reset
()
{
form
.
value
=
{
id
:
null
,
applicableMarket
:
null
,
listCode
:
null
,
listName
:
null
,
steeringType
:
null
,
listVersion
:
null
,
releaseDate
:
null
,
author
:
null
,
listStatus
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
,
remark
:
null
,
delFlag
:
null
};
proxy
.
resetForm
(
"listRef"
);
}
/** 搜索按钮操作 */
function
handleQuery
()
{
queryParams
.
value
.
pageNum
=
1
;
getList
();
}
/** 重置按钮操作 */
function
resetQuery
()
{
proxy
.
resetForm
(
"queryRef"
);
queryParams
.
value
=
{
pageNum
:
1
,
pageSize
:
10
,
applicableMarket
:
null
,
listCode
:
null
,
listName
:
null
,
listVersion
:
null
,
listStatus
:
null
,
}
handleQuery
();
}
function
handleView
(
row
)
{
console
.
log
(
row
)
drawer2
.
value
=
true
}
/** 导出按钮操作 */
function
handleExport
()
{
proxy
.
download
(
'marketRegulations/list/export'
,
{
...
queryParams
.
value
},
`list_
${
new
Date
().
getTime
()}
.xlsx`
)
}
getList
()
getBusinessList
()
</
script
>
<
style
scoped
lang=
"scss"
>
:deep
(
.drawer-form.el-form--inline
.el-form-item
)
{
margin-right
:
15px
;
}
:deep
(
.drawer-form
.el-button
+
.el-button
)
{
margin-left
:
5px
;
}
:deep
(
.top-btn
.el-button
+
.el-button
)
{
margin-left
:
5px
;
}
:deep
(
.el-drawer__header
)
{
margin-bottom
:
0
;
padding-bottom
:
20px
;
background-color
:
rgb
(
245
,
245
,
245
);
}
</
style
>
src/views/system/user/index.vue
View file @
d663358f
...
...
@@ -320,26 +320,6 @@
</
template
>
</el-dialog>
<!-- 分配角色 -->
<el-dialog
v-model=
"dialogRole"
title=
"分配角色"
width=
"600px"
append-to-body
>
<el-form
ref=
"userRef"
:model=
"form"
label-width=
"80px"
>
<el-form-item
prop=
"roleNames"
>
<el-checkbox-group
v-model=
"selectedFactories"
>
<div
style=
"display: flex; flex-wrap: wrap;"
>
<div
v-for=
"(role, index) in allRoles"
:key=
"index"
style=
"width: 33%; margin-bottom: 10px;"
>
<el-checkbox
:label=
"role"
>
{{ role }}
</el-checkbox>
</div>
</div>
</el-checkbox-group>
</el-form-item>
</el-form>
<
template
#
footer
>
<span
class=
"dialog-footer"
>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
<el-button
type=
"primary"
@
click=
"submitForm"
>
保 存
</el-button>
</span>
</
template
>
</el-dialog>
<!-- 添加或修改用户配置对话框 -->
<el-dialog
v-model=
"open"
:title=
"title"
width=
"600px"
append-to-body
>
...
...
@@ -504,7 +484,6 @@ import {
import
{
Splitpanes
,
Pane
}
from
'splitpanes'
import
'splitpanes/dist/splitpanes.css'
import
{
getAllFactoryName
}
from
"@/api/system/factory"
;
import
{
getRoleAll
,
listRole
}
from
"@/api/system/role"
;
import
{
watch
}
from
"vue"
;
const
router
=
useRouter
()
...
...
@@ -517,7 +496,6 @@ const { sys_normal_disable, sys_user_sex, sys_user_status, sys_user_type } = pro
'sys_user_type'
)
const
dialogFactory
=
ref
(
false
)
const
dialogRole
=
ref
(
false
)
const
divsionDialog
=
ref
(
false
)
// 选中的工厂列表
const
selectedFactories
=
ref
([]);
...
...
@@ -662,13 +640,7 @@ function openFactoryDialog(row) {
selectedFactories
.
value
=
row
.
factoryName
?
row
.
factoryName
.
split
(
','
)
:
[];
}
// 解析 factoryName(假设存储为 JSON 字符串数组)
function
parseFactoryName
(
factoryName
)
{
try
{
return
JSON
.
parse
(
factoryName
||
'[]'
);
// 默认空数组
}
catch
(
e
)
{
return
[];
}
}
// 监听选中的工厂变化,更新表单数据
watch
(
selectedFactories
,
(
newVal
)
=>
{
...
...
@@ -807,7 +779,6 @@ function handleCommand(command, row) {
/** 跳转角色分配 */
function
handleAuthRole
(
row
)
{
dialogRole
.
value
=
true
const
userId
=
row
.
userId
router
.
push
(
'/system/user-auth/role/'
+
userId
)
}
...
...
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