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
51c85aee
Commit
51c85aee
authored
Dec 11, 2024
by
wangxl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
222
parent
f6332c83
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
195 additions
and
321 deletions
+195
-321
index.js
src/router/index.js
+1
-1
infoEdit.vue
src/views/basicSetting/person/components/infoEdit.vue
+103
-98
index.vue
src/views/basicSetting/person/index.vue
+20
-18
info.vue
src/views/basicSetting/person/info.vue
+0
-18
infoEdit.vue
src/views/basicSetting/unit/components/infoEdit.vue
+3
-3
index.vue
src/views/basicSetting/unit/index.vue
+1
-1
Index.vue
src/views/report/project/Index.vue
+63
-179
projectEdit.vue
src/views/report/project/components/projectEdit.vue
+4
-3
No files found.
src/router/index.js
View file @
51c85aee
...
...
@@ -102,7 +102,7 @@ export const routes = [
meta
:
{
title
:
'单位设置'
,
icon
:
'el-icon-user'
},
hidden
:
false
,
children
:
[
{
path
:
'/unit/info'
,
name
:
'单位基础信息设置'
,
component
:
()
=>
import
(
'@/views/basicSetting/unit/index.vue'
),
meta
:
{
title
:
'
个人
设置'
,
icon
:
''
,
noCache
:
true
}
},
{
path
:
'/unit/info'
,
name
:
'单位基础信息设置'
,
component
:
()
=>
import
(
'@/views/basicSetting/unit/index.vue'
),
meta
:
{
title
:
'
单位基础信息
设置'
,
icon
:
''
,
noCache
:
true
}
},
]
},
{
...
...
src/views/basicSetting/person/components/infoEdit.vue
View file @
51c85aee
<
template
>
<div>
<a-form-model
ref=
"form"
:model=
"formData"
:rules=
"rules"
>
<a-form-model-item
label=
"姓 名"
prop=
"personName"
>
<a-input
v-model=
"formData.personName"
:maxLength=
"30"
style=
"width:180px;"
/>
</a-form-model-item>
<a-form-model-item
label=
"民 族"
prop=
"nation"
>
<para-select
v-model=
"formData.nation"
:width=
"180"
:typeId=
"11"
/>
</a-form-model-item>
<a-form-model-item
label=
"职 称"
prop=
"title"
>
<para-multi-select
:width=
"180"
v-model=
"formData.title"
:typeId=
"7"
/>
</a-form-model-item>
<a-form-model-item
label=
"专 业"
prop=
"spec"
>
<para-multi-select
:width=
"180"
v-model=
"formData.spec"
:typeId=
"57"
/>
</a-form-model-item>
<a-form-model-item
label=
"学 位"
prop=
"degree"
>
<para-select
v-model=
"formData.degree"
:width=
"180"
:typeId=
"9"
/>
</a-form-model-item>
<a-form-model-item
label=
"职 务"
prop=
"duty"
>
<a-input
v-model=
"formData.duty"
:maxLength=
"30"
style=
"width:180px;"
/>
</a-form-model-item>
<a-form-model-item
label=
"联系电话"
prop=
"telephone"
>
<a-input
v-model=
"formData.telephone"
:maxLength=
"30"
style=
"width:180px;"
/>
</a-form-model-item>
<a-form-model-item
label=
"传 真"
prop=
"fax"
>
<a-input
v-model=
"formData.fax"
:maxLength=
"30"
style=
"width:180px;"
/>
</a-form-model-item>
<a-form-model-item
label=
"邮 箱"
prop=
"email"
>
<a-input
v-model=
"formData.email"
:maxLength=
"30"
style=
"width:180px;"
/>
</a-form-model-item>
<a-form-model-item
label=
"通讯地址"
prop=
"address"
>
<a-input
v-model=
"formData.address"
:maxLength=
"60"
style=
"width:180px;"
/>
</a-form-model-item>
<div
class=
"per_edit"
>
<a-form-model
ref=
"form"
:model=
"formData"
:rules=
"rules"
class=
"from-table"
>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
姓 名
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"unitName"
>
<a-input
v-model=
"formData.personName"
placeholder=
"姓 名"
style=
"width:360px"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
民 族
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"nation"
>
<para-select
v-model=
"formData.nation"
:typeId=
"11"
:width=
"180"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
职 称
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"title"
>
<para-multi-select
:width=
"180"
v-model=
"formData.title"
:typeId=
"7"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
专 业
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"spec"
>
<para-multi-select
:width=
"180"
v-model=
"formData.spec"
:typeId=
"57"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
学 位
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"degree"
>
<para-select
v-model=
"formData.degree"
:width=
"180"
:typeId=
"9"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
职 务
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"duty"
>
<a-input
v-model=
"formData.duty"
placeholder=
"职 务"
:maxLength=
"30"
style=
"width:360px"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
邮 箱
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"email"
>
<a-input
v-model=
"formData.email"
placeholder=
"邮 箱"
style=
"width:360px"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div>
通讯地址
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"address"
>
<a-input
v-model=
"formData.address"
placeholder=
"通讯地址"
style=
"width:360px"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row
type=
"flex"
>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"special-middle"
>
<div>
主要研究领域
</div>
</div>
</a-col>
<a-col
:span=
"20"
>
<div
class=
"special-middle"
>
<div>
<a-form-model-item
prop=
"mainResearchAreas"
>
<a-textarea
placeholder=
"主要研究领域"
v-model=
"formData.mainResearchAreas"
:maxLength=
"300"
style=
"width: 360px; height: 80px; margin-top: 4px"
/>
</a-form-model-item>
</div>
</div>
</a-col>
</a-row>
</a-form-model>
</div>
</
template
>
...
...
@@ -42,7 +108,7 @@ import { isEmptyParams, hideIdCard, hidePhone, checkEmail } from "@/views/utils/
export
default
{
name
:
"infoEdit"
,
components
:
{
},
data
()
{
return
{
...
...
@@ -56,7 +122,8 @@ export default {
telephone
:
[{
required
:
true
,
message
:
'*'
,
trigger
:
'blur'
},],
fax
:
[{
required
:
true
,
message
:
'*'
,
trigger
:
'blur'
},],
email
:
[{
required
:
true
,
message
:
'*'
,
trigger
:
'blur'
},],
address
:
[{
required
:
true
,
message
:
'*'
,
trigger
:
'blur'
},],
address
:
[{
required
:
false
,
message
:
'*'
,
trigger
:
'blur'
},],
mainResearchAreas
:
[{
required
:
false
,
message
:
'*'
,
trigger
:
'blur'
},],
},
}
},
...
...
@@ -80,11 +147,12 @@ export default {
this
.
$api
.
person
.
updatePerson
(
par
).
then
(({
data
=
{}
})
=>
{
if
(
data
)
{
this
.
$message
.
success
(
'成功!'
)
this
.
$emit
(
'sub'
,
true
)
}
this
.
$emit
(
'load'
,
false
)
}).
catch
(()
=>
{
this
.
$emit
(
'load'
,
false
)
})
}
else
{
this
.
$message
.
warn
(
'信息未填写完全!'
)
this
.
$message
.
error
(
'信息未填写完全!'
)
return
false
}
});
...
...
@@ -93,66 +161,4 @@ export default {
}
</
script
>
<
style
scoped
lang=
"less"
>
.app-content {
padding: 10px 8px 10px 8px;
min-width: 920px;
.border-style {
border-radius: 4px;
border: 1px solid #e6ebf5;
background-color: #ffffff;
overflow: hidden;
color: #303133;
-webkit-transition: 0.3s;
transition: 0.3s;
}
.card-left {
float: left;
width: 300px;
height: 600px;
margin-right: 6px;
.holder-photo {
margin: 20px 0px 10px 0px;
text-align: center;
}
.holder-photo > img {
width: 104px;
height: 104px;
margin-bottom: 10px;
}
.holder-info {
padding: 0px 10px 0px 10px;
.ant-row .ant-col {
padding: 3px 5px 3px 5px;
}
}
.title {
text-align: right;
}
}
.card-right {
float: left;
width: calc(100% - 320px);
min-width: 600px;
min-height: 200px;
padding: 0px 15px 15px 15px;
.ant-form-item {
margin-bottom: 0px;
}
::v-deep .ant-row {
.ant-col {
display: inline-block;
}
.ant-form-item-label {
width: 70px;
}
.ant-form-item-control-wrapper {
width: calc(100% - 70px);
}
.ant-form-explain {
margin-left: 5px;
display: inline-block;
}
}
}
}
</
style
>
\ No newline at end of file
src/views/basicSetting/person/index.vue
View file @
51c85aee
<
template
>
<div
class=
"app-content"
style=
"height:100%;overflow:auto;"
>
<div
style=
"height: calc(100% - 32px);overflow:auto;margin-top: 16px;"
>
<a-spin
:spinning=
"loading"
style=
"width: 100%;height: 100%;"
>
<info-edit
:formData
.
sync=
"formData"
@
load=
"onLoad"
ref=
"infoEdit"
/>
<a-row>
<a-col
style=
"text-align: center;width:100%;"
>
<a-button
type=
"primary"
style=
"width:80px;"
@
click=
"submit"
>
保存
</a-button>
</a-col>
</a-row>
</a-spin>
</div>
<div
class=
"app-content"
style=
"height:480px;overflow:auto;"
>
<a-spin
:spinning=
"loading"
style=
"width: 100%;height: 100%;"
>
<info-edit
:formData
.
sync=
"formData"
@
load=
"onLoad"
@
sub=
"save"
ref=
"infoEdit"
/>
<a-row>
<a-col
style=
"text-align: center;width:100%;margin-top: 12px;"
>
<a-button
type=
"primary"
style=
"width:80px;"
@
click=
"submit"
>
提交
</a-button>
</a-col>
</a-row>
</a-spin>
</div>
</
template
>
<
script
>
import
{
getType
,
getComplete
,
setComplete
}
from
'@/views/utils/auth'
import
infoEdit
from
'@/views/basicSetting/person/components/infoEdit'
export
default
{
...
...
@@ -41,19 +40,18 @@ export default {
}
},
created
()
{
this
.
get
CurrentUnit
Info
()
this
.
get
AppPerson
Info
()
},
methods
:
{
get
CurrentUnit
Info
()
{
get
AppPerson
Info
()
{
this
.
loading
=
true
this
.
$api
.
unit
.
getCurrentUnit
Info
().
then
(({
data
=
{}
})
=>
{
this
.
$api
.
person
.
getAppPerson
Info
().
then
(({
data
=
{}
})
=>
{
if
(
data
)
{
this
.
formData
=
data
this
.
formData
=
data
.
person
setComplete
(
data
.
isComplete
)
}
this
.
loading
=
false
}).
catch
(()
=>
{
this
.
loading
=
false
})
}).
catch
(()
=>
{
this
.
loading
=
false
})
},
submit
()
{
this
.
$refs
.
infoEdit
.
submit
()
...
...
@@ -61,6 +59,9 @@ export default {
onLoad
(
value
)
{
this
.
loading
=
value
},
save
(
value
)
{
this
.
$emit
(
'sub'
,
value
)
},
}
}
</
script
>
\ No newline at end of file
src/views/basicSetting/person/info.vue
View file @
51c85aee
...
...
@@ -186,24 +186,6 @@ export default {
min-width: 600px;
min-height: 200px;
padding: 0px 15px 15px 15px;
.ant-form-item {
margin-bottom: 6px;
}
::v-deep .ant-row {
.ant-col {
display: inline-block;
}
.ant-form-item-label {
width: 70px;
}
.ant-form-item-control-wrapper {
width: calc(100% - 70px);
}
.ant-form-explain {
margin-left: 5px;
display: inline-block;
}
}
}
}
</
style
>
src/views/basicSetting/unit/components/infoEdit.vue
View file @
51c85aee
...
...
@@ -7,7 +7,7 @@
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"unitName"
>
<a-input
v-model=
"formData.unitName"
placeholder=
"单位名称"
style=
"width:
400px
"
/>
<a-input
v-model=
"formData.unitName"
placeholder=
"单位名称"
style=
"width:
80%
"
/>
</a-form-model-item>
</a-col>
</a-row>
...
...
@@ -27,7 +27,7 @@
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"unitAddress"
>
<a-input
v-model=
"formData.unitAddress"
:maxLength=
"30"
style=
"width:
400px
"
/>
<a-input
v-model=
"formData.unitAddress"
:maxLength=
"30"
style=
"width:
80%
"
/>
</a-form-model-item>
</a-col>
</a-row>
...
...
@@ -101,7 +101,7 @@
<div
class=
"special-middle"
>
<div>
<a-form-model-item
prop=
"organizationCode"
>
<a-input
placeholder=
"组织机构代码/统一社会信用代码"
v-model=
"formData.organizationCode"
:maxLength=
"100"
style=
"width:
400px
"
/>
<a-input
placeholder=
"组织机构代码/统一社会信用代码"
v-model=
"formData.organizationCode"
:maxLength=
"100"
style=
"width:
80%
"
/>
</a-form-model-item>
</div>
</div>
...
...
src/views/basicSetting/unit/index.vue
View file @
51c85aee
...
...
@@ -15,7 +15,7 @@
<
script
>
import
infoEdit
from
'@/views/basicSetting/
person
/components/infoEdit'
import
infoEdit
from
'@/views/basicSetting/
unit
/components/infoEdit'
export
default
{
name
:
"unitInfoEdit"
,
...
...
src/views/report/project/Index.vue
View file @
51c85aee
<
template
>
<div
class=
"app-content"
>
<div
v-if=
"load && !isComplete"
style=
"margin-top:12px"
>
<a-form-model
ref=
"ruleForm"
:model=
"formData"
:rules=
"rules"
class=
"from-table"
>
<a-row>
<a-col
:span=
"24"
>
<div
class=
"main-title"
>
<span>
补充人员基本信息
</span>
</div>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
民族
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"nation"
>
<para-select
v-model=
"formData.nation"
:width=
"150"
:typeId=
"11"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
学历
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"education"
>
<para-select
v-model=
"formData.education"
:width=
"150"
:typeId=
"8"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row
type=
"flex"
>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"special-middle"
>
<div
class=
"required"
>
学位
</div>
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"degree"
>
<para-select
v-model=
"formData.degree"
:typeId=
"9"
:width=
"150"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
职称
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"title"
>
<para-multi-select
v-model=
"formData.title"
:typeId=
"7"
:width=
"150"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
专业
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"spec"
>
<para-multi-select
:width=
"150"
v-model=
"formData.spec"
:typeId=
"57"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"4"
class=
"bg-gray"
>
<div
class=
"required"
>
邮箱
</div>
</a-col>
<a-col
:span=
"20"
>
<a-form-model-item
prop=
"email"
>
<a-input
v-model=
"formData.email"
:maxLength=
"30"
style=
"width:250px;"
/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col
:span=
"24"
style=
"text-align: center;"
>
<a-button
type=
"primary"
@
click=
"submit"
>
提交
</a-button>
</a-col>
</a-row>
</a-form-model>
</div>
<div
v-if=
"load && isComplete"
>
<a-form
:form=
"form"
:model=
"searchForm"
layout=
"inline"
class=
"search_form"
>
<a-form-item>
<a-input
placeholder=
"项目名称"
v-model=
"searchForm.projName"
:maxLength=
"100"
style=
"width: 180px"
/>
</a-form-item>
<a-form-item>
<a-input
placeholder=
"项目编号"
v-model=
"searchForm.projNo"
:maxLength=
"100"
style=
"width: 180px"
/>
</a-form-item>
<a-form-item>
<a-button
type=
"primary"
icon=
"search"
@
click=
"search"
>
搜索
</a-button>
<a-button
icon=
"reload"
style=
"margin-left: 10px"
@
click=
"reset"
class=
"bt-normal"
>
重置
</a-button>
<!--
<a-button
type=
"primary"
style=
"margin-left: 10px"
@
click=
"FileDownload"
icon=
"download"
>
项目合同书模板下载
</a-button>
-->
<!--
<a-button
icon=
"primary"
style=
"margin-left: 10px"
@
click=
"FileView"
>
查看
</a-button>
-->
</a-form-item>
</a-form>
<div
style=
"width:100%;margin-bottom: 8px;"
>
<div
style=
"display: inline-block;;width:50%"
>
<btn-group
:data=
"tabDate"
:itemCount=
"itemCount"
v-model=
"activekey"
@
change=
"callback"
/>
</div>
<div
style=
"display: inline-block;;width:50%;text-align: right;"
>
<!--
<a-button
type=
"primary"
@
click=
"projectKPI"
icon=
"download"
>
绩效指标表
</a-button>
-->
<!--
<a-button
type=
"primary"
@
click=
"createMember"
>
新建项目组成员
</a-button>
-->
<a-button
type=
"primary"
style=
"margin-right:8px;"
v-if=
"(display && isButten)"
@
click=
"createProject"
>
新建项目
</a-button>
<a-button
type=
"primary"
@
click=
"exportData"
icon=
"download"
>
Excel
</a-button>
</div>
<a-form
:form=
"form"
:model=
"searchForm"
layout=
"inline"
class=
"search_form"
>
<a-form-item>
<a-input
placeholder=
"项目名称"
v-model=
"searchForm.projName"
:maxLength=
"100"
style=
"width: 180px"
/>
</a-form-item>
<a-form-item>
<a-input
placeholder=
"项目编号"
v-model=
"searchForm.projNo"
:maxLength=
"100"
style=
"width: 180px"
/>
</a-form-item>
<a-form-item>
<a-button
type=
"primary"
icon=
"search"
@
click=
"search"
>
搜索
</a-button>
<a-button
icon=
"reload"
style=
"margin-left: 10px"
@
click=
"reset"
class=
"bt-normal"
>
重置
</a-button>
<!--
<a-button
type=
"primary"
style=
"margin-left: 10px"
@
click=
"FileDownload"
icon=
"download"
>
项目合同书模板下载
</a-button>
-->
<!--
<a-button
icon=
"primary"
style=
"margin-left: 10px"
@
click=
"FileView"
>
查看
</a-button>
-->
</a-form-item>
</a-form>
<div
style=
"width:100%;margin-bottom: 8px;"
>
<div
style=
"display: inline-block;;width:50%"
>
<btn-group
:data=
"tabDate"
:itemCount=
"itemCount"
v-model=
"activekey"
@
change=
"callback"
/>
</div>
<div
style=
"display: inline-block;;width:50%;text-align: right;"
>
<!--
<a-button
type=
"primary"
@
click=
"projectKPI"
icon=
"download"
>
绩效指标表
</a-button>
-->
<!--
<a-button
type=
"primary"
@
click=
"createMember"
>
新建项目组成员
</a-button>
-->
<a-button
type=
"primary"
style=
"margin-right:8px;"
v-if=
"(display && isButten)"
@
click=
"createProject"
>
新建项目
</a-button>
<a-button
type=
"primary"
@
click=
"exportData"
icon=
"download"
>
Excel
</a-button>
</div>
<a-divider
style=
"height: 1px; background-color: #e8e8e8;"
/>
<span
class=
"form-description"
>
※填报时间:
{{
description
}}
</span>
<a-table
:dataSource=
"tableData"
:columns=
"columns"
:scroll=
"
{ x: 'max-content' }" rowKey="id" :pagination="false" :loading="loading">
<!-- size="small" bordered -->
<template
slot=
"projName"
slot-scope=
"record"
>
<a
@
click=
"recordClick(record, 'view')"
>
{{
record
.
projName
}}
</a>
</
template
>
<
template
slot=
"state"
slot-scope=
"record"
>
<span>
{{
record
.
projStateName
}}
</span>
</
template
>
<
template
slot=
"option"
slot-scope=
"record"
>
<a-button
type=
"link"
size=
"small"
@
click=
"recordClick(record, 'view')"
>
查看
</a-button>
<a-button
type=
"link"
size=
"small"
v-if=
"((record.projState == -10 || record.projState == 10 || record.projState == 30))"
@
click=
"recordClick(record, 'edit')"
>
修改
</a-button>
<a-popconfirm
title=
"确定要上报吗?"
v-if=
"((record.projState == 10 || record.projState == 30))"
ok-text=
"确定"
cancel-text=
"取消"
@
confirm=
"recordClick(record,'report')"
>
<a-button
type=
"link"
size=
"small"
>
上报
</a-button>
</a-popconfirm>
<a-button
type=
"link"
size=
"small"
v-if=
"record.projState
<
=
10
"
@
click=
"recordClick(record,'delete')"
>
删除
</a-button>
</
template
>
</a-table>
<a-pagination
v-if=
"pagination.total > 0"
:total=
"pagination.total"
show-size-changer
show-quick-jumper
v-model=
"pagination.pageIndex"
:page-size=
"pagination.pageSize"
:page-size-options=
"pagination.pageSizeOptions"
@
showSizeChange=
"showSizeChange"
@
change=
"change"
:showTotal=
"() => `共 ${pagination.total} 条`"
/>
</div>
<a-divider
style=
"height: 1px; background-color: #e8e8e8;"
/>
<span
class=
"form-description"
>
※填报时间:
{{
description
}}
</span>
<a-table
:dataSource=
"tableData"
:columns=
"columns"
:scroll=
"
{ x: 'max-content' }" rowKey="id" :pagination="false" :loading="loading">
<!-- size="small" bordered -->
<template
slot=
"projName"
slot-scope=
"record"
>
<a
@
click=
"recordClick(record, 'view')"
>
{{
record
.
projName
}}
</a>
</
template
>
<
template
slot=
"state"
slot-scope=
"record"
>
<span>
{{
record
.
projStateName
}}
</span>
</
template
>
<
template
slot=
"option"
slot-scope=
"record"
>
<a-button
type=
"link"
size=
"small"
@
click=
"recordClick(record, 'view')"
>
查看
</a-button>
<a-button
type=
"link"
size=
"small"
v-if=
"((record.projState == -10 || record.projState == 10 || record.projState == 30))"
@
click=
"recordClick(record, 'edit')"
>
修改
</a-button>
<a-popconfirm
title=
"确定要上报吗?"
v-if=
"((record.projState == 10 || record.projState == 30))"
ok-text=
"确定"
cancel-text=
"取消"
@
confirm=
"recordClick(record,'report')"
>
<a-button
type=
"link"
size=
"small"
>
上报
</a-button>
</a-popconfirm>
<a-button
type=
"link"
size=
"small"
v-if=
"record.projState
<
=
10
"
@
click=
"recordClick(record,'delete')"
>
删除
</a-button>
</
template
>
</a-table>
<a-pagination
v-if=
"pagination.total > 0"
:total=
"pagination.total"
show-size-changer
show-quick-jumper
v-model=
"pagination.pageIndex"
:page-size=
"pagination.pageSize"
:page-size-options=
"pagination.pageSizeOptions"
@
showSizeChange=
"showSizeChange"
@
change=
"change"
:showTotal=
"() => `共 ${pagination.total} 条`"
/>
<a-modal
v-model=
"visibleEdit"
v-if=
"visibleEdit"
title=
"项目创建/修改"
width=
"94%"
:footer=
"null"
:dialog-style=
"{ top: '8%' }"
destroyOnClose
:maskClosable=
"false"
>
<project-create
v-model=
"id"
@
close=
"closeWindow"
></project-create>
</a-modal>
...
...
@@ -139,6 +59,9 @@
<a-modal
v-model=
"projectKPIView"
title=
"查看项目KPI"
width=
"80%"
:dialog-style=
"{ top: '10%' }"
:footer=
"null"
destroyOnClose
>
<project-kpi></project-kpi>
</a-modal>
<a-modal
v-model=
"visiblePersonEdit"
v-if=
"visiblePersonEdit"
title=
"请先完善个人信息!"
width=
"700px"
:dialog-style=
"{ top: '12%' }"
:footer=
"null"
destroyOnClose
>
<person-info-edit
@
sub=
"personSave"
/>
</a-modal>
</div>
</template>
...
...
@@ -151,29 +74,17 @@ import projectEdit from '@/views/report/project/components/projectEdit'
import
projectEditKey
from
"@/views/report/project/components/keyProject/projectEdit"
import
projectView
from
'@/views/report/project/components/projectView'
import
previewFile
from
'@/views/components/common/previewFile'
import
personInfoEdit
from
'@/views/basicSetting/person/index'
import
axios
from
'axios'
export
default
{
name
:
'reportProject'
,
components
:
{
projectView
,
projectCreate
,
projectEdit
,
previewFile
,
projectEditKey
projectView
,
projectCreate
,
projectEdit
,
previewFile
,
projectEditKey
,
personInfoEdit
},
data
()
{
return
{
load
:
false
,
//判断是否查询信息完整状态
isComplete
:
getComplete
(),
formData
:
{
id
:
null
,
nation
:
null
,
title
:
null
,
education
:
null
,
degree
:
null
,
spec
:
null
,
email
:
null
,
sex
:
null
,
birthday
:
null
},
rules
:
{
nation
:
[{
required
:
true
,
message
:
'请选择民族'
,
trigger
:
'change'
}],
title
:
[{
required
:
true
,
message
:
'请选择职称'
,
trigger
:
'change'
}],
education
:
[{
required
:
true
,
message
:
'请选择学历'
,
trigger
:
'change'
}],
degree
:
[{
required
:
true
,
message
:
'请选择学位'
,
trigger
:
'change'
}],
spec
:
[{
required
:
true
,
message
:
'请选择专业'
,
trigger
:
'change'
}],
email
:
[
{
required
:
true
,
message
:
'请输入邮箱'
,
trigger
:
'blur'
},
{
required
:
true
,
validator
:
checkEmail
,
trigger
:
'blur'
}
],
},
size
:
'small'
,
form
:
this
.
$form
.
createForm
(
this
,
{
name
:
'advanced_search'
}),
activekey
:
'1'
,
...
...
@@ -218,35 +129,21 @@ export default {
realurl
:
null
,
visibleFileView
:
false
,
projectKPIView
:
false
,
visiblePersonEdit
:
false
,
}
},
created
()
{
this
.
get
UserState
()
this
.
get
Year
()
if
(
getType
()
==
"1"
)
this
.
realurl
=
this
.
url1
else
this
.
realurl
=
this
.
url2
},
methods
:
{
getUserState
()
{
if
(
this
.
isComplete
)
{
this
.
load
=
true
this
.
getYear
()
}
else
{
this
.
getAppPersonInfo
()
}
},
getAppPersonInfo
()
{
this
.
$api
.
person
.
getAppPersonInfo
().
then
(({
data
=
{}
})
=>
{
if
(
data
)
{
this
.
load
=
true
this
.
formData
=
data
.
person
setComplete
(
data
.
isComplete
)
this
.
isComplete
=
data
.
isComplete
this
.
getYear
()
}
}).
catch
(()
=>
{
})
personSave
(
value
)
{
setComplete
(
true
)
this
.
isComplete
=
true
this
.
visiblePersonEdit
=
false
},
getYear
()
{
this
.
$api
.
batch
.
getCurrentYearBatch
({
type
:
1
,
projType
:
getType
()
}).
then
(({
data
=
{}
})
=>
{
...
...
@@ -303,27 +200,14 @@ export default {
this
.
pagination
.
pageSize
=
pageSize
this
.
getListByPage
()
},
submit
()
{
this
.
$refs
.
ruleForm
.
validate
(
valid
=>
{
if
(
valid
)
{
let
pars
=
isEmptyParams
(
this
.
formData
)
let
par
=
{
...
pars
}
this
.
$api
.
person
.
updatePerson
(
par
).
then
(({
data
=
{}
})
=>
{
if
(
data
)
{
this
.
$message
.
success
(
'提交成功!'
)
setComplete
(
true
)
this
.
isComplete
=
true
}
}).
catch
(()
=>
{
})
}
else
{
return
false
}
});
},
createProject
()
{
this
.
id
=
null
this
.
visibleEdit
=
true
//this.$store.commit('app/addCard', { title: '项目创建', key: '1299', code: 'projectCreate', keepAlive: 1, router: '/project/create', closable: true })
if
(
this
.
isComplete
)
{
this
.
id
=
null
this
.
visibleEdit
=
true
}
else
{
this
.
visiblePersonEdit
=
true
}
},
closeWindow
(
value
)
{
if
(
value
===
'submit'
)
{
...
...
src/views/report/project/components/projectEdit.vue
View file @
51c85aee
...
...
@@ -156,8 +156,8 @@
<a-col
:span=
"21"
>
<div
class=
"special-middle"
>
<div>
<a-form-model-item>
<
div>
{{
formData
.
address
}}
</div
>
<a-form-model-item
prop=
"address"
>
<
a-input
v-model=
"formData.address"
:maxLength=
"100"
style=
"width: 80%;"
/
>
</a-form-model-item>
</div>
</div>
...
...
@@ -460,7 +460,7 @@
<a-row
type=
"flex"
>
<a-col
:span=
"24"
>
<div
style=
"min-height:34px;line-height: 40px;text-align: center;"
>
<up-load
:isUpload=
"true"
:file
.
sync=
"formData"
:format=
"['doc', 'docx']"
message=
"请上传申请书正文"
/>
<up-load
:isUpload=
"true"
:file
.
sync=
"formData"
:format=
"['doc', 'docx']"
message=
"请上传申请书正文"
/>
</div>
</a-col>
</a-row>
...
...
@@ -596,6 +596,7 @@ export default {
},
rules
:
{
jobTime
:
[{
required
:
true
,
message
:
'请填写每年工作时间(月)'
,
trigger
:
'blur'
},],
address
:
[{
required
:
true
,
message
:
'请填写个人通讯地址'
,
trigger
:
'blur'
},],
mainResearchAreas
:
[{
required
:
true
,
message
:
'请填写主要研究领域'
,
trigger
:
'blur'
},],
unitLinkName
:
[{
required
:
true
,
message
:
'请填写单位联系人'
,
trigger
:
'blur'
},],
unitLinkMobile
:
[{
required
:
true
,
message
:
'请填写联系人电话'
,
trigger
:
'blur'
},],
...
...
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