Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
8f73e1be
提交
8f73e1be
编写于
3月 20, 2019
作者:
zhentian.jia
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix bug 3-20
上级
88f86be8
变更
4
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
218 行增加
和
144 行删除
+218
-144
add-manager.vue
src/views/education/add-manager.vue
+155
-70
item-manager.vue
src/views/education/item-manager.vue
+15
-30
item-role.vue
src/views/system/item-role.vue
+11
-11
role.vue
src/views/system/role.vue
+37
-33
未找到文件。
src/views/education/add-manager.vue
浏览文件 @
8f73e1be
...
@@ -27,15 +27,27 @@
...
@@ -27,15 +27,27 @@
</el-col>
</el-col>
</el-form-item>
</el-form-item>
<el-form-item
label=
"项目时间:"
required
>
<el-form-item
label=
"项目时间:"
required
>
<el-col
:span=
"
6
"
>
<el-col
:span=
"
3
"
>
<el-form-item
prop=
"duringTime"
>
<el-form-item
label
>
<el-date-picker
<el-date-picker
v-model=
"formData.projectBegintime"
size=
"mini"
size=
"mini"
type=
"daterange"
type=
"date"
start-placeholder=
"请选择项目开始时间"
placeholder=
"请选择开始时间"
end-placeholder=
"请选择项目结束时间"
v-model=
"formData.duringTime"
value-format=
"yyyy-MM-dd HH:mm:ss"
value-format=
"yyyy-MM-dd HH:mm:ss"
:picker-options=
"pickerOptions0"
></el-date-picker>
</el-form-item>
</el-col>
<el-col
:span=
"5"
>
<el-form-item
label=
"~"
>
<el-date-picker
v-model=
"formData.projectEndtime"
size=
"mini"
type=
"date"
placeholder=
"请选择结束时间"
value-format=
"yyyy-MM-dd 23:59:59"
:picker-options=
"pickerOptions1"
></el-date-picker>
></el-date-picker>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
...
@@ -87,10 +99,18 @@
...
@@ -87,10 +99,18 @@
:show-file-list=
"false"
:show-file-list=
"false"
:before-upload=
"beforeUploadCoverPic"
:before-upload=
"beforeUploadCoverPic"
>
>
<img
v-if=
"formData.type == 1 && formData.attachmentUrl2"
:src=
"formData.attachmentUrl2"
class=
"bg-img"
>
<img
<video
v-if=
"formData.type == 2 && formData.attachmentUrl2"
width=
"100"
controls
class=
"bg-video"
>
v-if=
"formData.type == 1 && formData.attachmentUrl2"
<source
:src=
"formData.attachmentUrl2"
type=
"video/mp4"
>
:src=
"formData.attachmentUrl2"
浏览器不支持mp4
class=
"bg-img"
>
<video
v-if=
"formData.type == 2 && formData.attachmentUrl2"
width=
"100"
controls
class=
"bg-video"
>
<source
:src=
"formData.attachmentUrl2"
type=
"video/mp4"
>
浏览器不支持mp4
</video>
</video>
<img
<img
v-if=
"!formData.attachmentUrl2"
v-if=
"!formData.attachmentUrl2"
...
@@ -444,13 +464,28 @@ export default {
...
@@ -444,13 +464,28 @@ export default {
projectName
:
""
,
projectName
:
""
,
projectBegintime
:
""
,
projectBegintime
:
""
,
projectEndtime
:
""
,
projectEndtime
:
""
,
duringTime
:
""
,
projectIntro
:
""
,
projectIntro
:
""
,
type
:
1
,
type
:
1
,
attachmentUrl1
:
""
,
attachmentUrl1
:
""
,
attachmentUrl2
:
""
,
attachmentUrl2
:
""
,
attachmentUrl3
:
""
attachmentUrl3
:
""
},
},
pickerOptions0
:
{
disabledDate
:
time
=>
{
if
(
this
.
formData
.
projectEndtime
!=
""
)
{
return
(
time
.
getTime
()
>
new
Date
(
this
.
formData
.
projectEndtime
).
getTime
()
);
}
}
},
pickerOptions1
:
{
disabledDate
:
time
=>
{
return
(
time
.
getTime
()
<
new
Date
(
this
.
formData
.
projectBegintime
).
getTime
()
);
//减去一天的时间代表可以选择同一天;
}
},
fileList
:
[],
fileList
:
[],
//设定行政范围 数据
//设定行政范围 数据
allSelectedKeys
:
[],
allSelectedKeys
:
[],
...
@@ -607,9 +642,10 @@ export default {
...
@@ -607,9 +642,10 @@ export default {
(
this
.
projectId
=
vm
.
getUrlSearch
(
window
.
location
.
href
,
"projectId"
)),
(
this
.
projectId
=
vm
.
getUrlSearch
(
window
.
location
.
href
,
"projectId"
)),
this
.
editManager
();
this
.
editManager
();
this
.
changeOnStep
(
this
.
active
);
this
.
changeOnStep
(
this
.
active
);
this
.
getComponentInfo
();
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
this
.
getComponentInfo
();
//
this.getComponentInfo();
//this.getDepartment();
//this.getDepartment();
});
});
},
},
...
@@ -634,7 +670,7 @@ export default {
...
@@ -634,7 +670,7 @@ export default {
},
},
//改变封面类型
//改变封面类型
changeCover
(
radio
)
{
changeCover
(
radio
)
{
this
.
formData
.
attachmentUrl2
=
''
;
this
.
formData
.
attachmentUrl2
=
""
;
//console.log(radio);
//console.log(radio);
},
},
//设置编辑数据
//设置编辑数据
...
@@ -645,11 +681,7 @@ export default {
...
@@ -645,11 +681,7 @@ export default {
id
:
vm
.
getUrlSearch
(
window
.
location
.
href
,
"projectId"
),
id
:
vm
.
getUrlSearch
(
window
.
location
.
href
,
"projectId"
),
projectName
:
editData
.
projectData
.
projectName
,
projectName
:
editData
.
projectData
.
projectName
,
projectBegintime
:
editData
.
projectData
.
projectBegintime
,
projectBegintime
:
editData
.
projectData
.
projectBegintime
,
projectEndtime
:
editData
.
projectData
.
projectBegintime
,
projectEndtime
:
editData
.
projectData
.
projectEndtime
,
duringTime
:
[
editData
.
projectData
.
projectBegintime
,
editData
.
projectData
.
projectBegintime
],
projectIntro
:
editData
.
projectData
.
projectIntro
,
projectIntro
:
editData
.
projectData
.
projectIntro
,
type
:
editData
.
attachmentData
[
1
].
attachmentType
,
type
:
editData
.
attachmentData
[
1
].
attachmentType
,
attachmentUrl1
:
editData
.
attachmentData
[
0
].
attachmentUrl
,
attachmentUrl1
:
editData
.
attachmentData
[
0
].
attachmentUrl
,
...
@@ -699,8 +731,8 @@ export default {
...
@@ -699,8 +731,8 @@ export default {
//console.log(this.formData);
//console.log(this.formData);
let
projectModel
=
{
let
projectModel
=
{
projectName
:
this
.
formData
.
projectName
,
projectName
:
this
.
formData
.
projectName
,
projectBegintime
:
this
.
formData
.
duringTime
[
0
]
,
projectBegintime
:
this
.
formData
.
projectBegintime
,
projectEndtime
:
this
.
formData
.
duringTime
[
1
]
,
projectEndtime
:
this
.
formData
.
projectEndtime
,
projectIntro
:
this
.
formData
.
projectIntro
projectIntro
:
this
.
formData
.
projectIntro
};
};
let
attachmentModel
=
[
let
attachmentModel
=
[
...
@@ -751,6 +783,7 @@ export default {
...
@@ -751,6 +783,7 @@ export default {
this
.
active
++
;
this
.
active
++
;
this
.
stepData
=
[
false
,
true
,
false
];
this
.
stepData
=
[
false
,
true
,
false
];
this
.
projectId
=
res
.
data
.
id
;
this
.
projectId
=
res
.
data
.
id
;
this
.
projectStatus
=
res
.
data
.
projectStatus
;
this
.
initRange
();
this
.
initRange
();
this
.
getDepartment
();
this
.
getDepartment
();
}
}
...
@@ -788,7 +821,7 @@ export default {
...
@@ -788,7 +821,7 @@ export default {
let
param
=
{
let
param
=
{
componentIds
:
this
.
formComponent
.
component
,
componentIds
:
this
.
formComponent
.
component
,
certificateId
:
this
.
formComponent
.
certificate
,
certificateId
:
this
.
formComponent
.
certificate
,
projectId
:
parseInt
(
vm
.
getUrlSearch
(
window
.
location
.
href
,
"projectId"
))
,
projectId
:
this
.
projectId
,
type
:
type
,
type
:
type
,
status
:
this
.
projectStatus
status
:
this
.
projectStatus
};
};
...
@@ -839,6 +872,35 @@ export default {
...
@@ -839,6 +872,35 @@ export default {
}
}
}
else
if
(
this
.
active
==
1
)
{
}
else
if
(
this
.
active
==
1
)
{
//暂存步骤2
//暂存步骤2
let
req
=
{
projectId
:
this
.
projectId
,
setKindOfAdministrative
:
this
.
getKind
(
"administrative"
),
setKindOfOrganization
:
this
.
getKind
(
"organization"
),
setKindOfDepartment
:
this
.
getKind
(
"department"
),
setKindOfPeople
:
this
.
getKind
(
"person"
)
};
if
(
req
.
setKindOfAdministrative
==
3
)
{
req
.
scopeOfAdministrative
=
this
.
getScope
(
"administrativeUpdate"
);
}
if
(
req
.
setKindOfOrganization
==
2
||
req
.
setKindOfOrganization
==
3
)
{
req
.
scopeOfOrganization
=
this
.
getScopeOrganization
(
req
.
setKindOfOrganization
);
}
if
(
req
.
setKindOfDepartment
==
3
)
{
req
.
scopeOfDepartment
=
this
.
getScopeDepartment
();
}
if
(
req
.
setKindOfPeople
==
2
||
req
.
setKindOfPeople
==
3
)
{
req
.
scopeOfPeople
=
this
.
getScopePeople
(
req
.
setKindOfPeople
);
}
vm
.
POST
(
"scope"
,
req
).
then
(
res
=>
{
//移动到选择项目组件
console
.
log
(
res
);
this
.
$notify
({
title
:
""
,
message
:
res
.
message
});
});
}
else
if
(
this
.
active
==
2
)
{
}
else
if
(
this
.
active
==
2
)
{
//暂存步骤3
//暂存步骤3
let
formName
=
"formComponent"
;
let
formName
=
"formComponent"
;
...
@@ -892,6 +954,8 @@ export default {
...
@@ -892,6 +954,8 @@ export default {
}
}
}
}
}
else
if
(
this
.
active
==
1
)
{
}
else
if
(
this
.
active
==
1
)
{
if
(
this
.
tagsRegion
.
length
>
0
)
{
//选择了范围
let
req
=
{
let
req
=
{
projectId
:
this
.
projectId
,
projectId
:
this
.
projectId
,
setKindOfAdministrative
:
this
.
getKind
(
"administrative"
),
setKindOfAdministrative
:
this
.
getKind
(
"administrative"
),
...
@@ -906,7 +970,10 @@ export default {
...
@@ -906,7 +970,10 @@ export default {
if
(
req
.
setKindOfAdministrative
==
3
)
{
if
(
req
.
setKindOfAdministrative
==
3
)
{
req
.
scopeOfAdministrative
=
this
.
getScope
(
"administrativeUpdate"
);
req
.
scopeOfAdministrative
=
this
.
getScope
(
"administrativeUpdate"
);
}
}
if
(
req
.
setKindOfOrganization
==
2
||
req
.
setKindOfOrganization
==
3
)
{
if
(
req
.
setKindOfOrganization
==
2
||
req
.
setKindOfOrganization
==
3
)
{
req
.
scopeOfOrganization
=
this
.
getScopeOrganization
(
req
.
scopeOfOrganization
=
this
.
getScopeOrganization
(
req
.
setKindOfOrganization
req
.
setKindOfOrganization
);
);
...
@@ -930,6 +997,14 @@ export default {
...
@@ -930,6 +997,14 @@ export default {
});
});
}
}
});
});
}
else
{
//没有选择范围
vm
.
$message
({
showClose
:
true
,
message
:
"选择项目范围后才能进行下一步操作"
,
type
:
"error"
});
}
}
}
},
},
//图片上传
//图片上传
...
@@ -1100,10 +1175,10 @@ export default {
...
@@ -1100,10 +1175,10 @@ export default {
this
.
getOrganization
();
this
.
getOrganization
();
}
else
if
(
tabName
==
"third"
)
{
}
else
if
(
tabName
==
"third"
)
{
//设定科室
//设定科室
if
(
this
.
checkTableState
.
multipleDepartment
&&
this
.
firstDepartment
)
{
//
if (this.checkTableState.multipleDepartment && this.firstDepartment) {
this
.
$refs
.
multipleDepartment
.
toggleAllSelection
();
//
this.$refs.multipleDepartment.toggleAllSelection();
this
.
firstDepartment
=
false
;
//
this.firstDepartment = false;
}
//
}
}
else
if
(
tabName
==
"fourth"
)
{
}
else
if
(
tabName
==
"fourth"
)
{
//设定人员
//设定人员
this
.
getPeople
();
this
.
getPeople
();
...
@@ -1130,9 +1205,9 @@ export default {
...
@@ -1130,9 +1205,9 @@ export default {
};
};
openLoading
(
vm
);
openLoading
(
vm
);
vm
.
GET
(
"scope/v1/administrative"
,
req
).
then
(
res
=>
{
vm
.
GET
(
"scope/v1/administrative"
,
req
).
then
(
res
=>
{
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
if
(
res
.
code
==
"000000"
)
{
//console.log(res.data);
//console.log(res.data);
closeLoading
(
vm
);
let
administrativeAll
=
res
.
data
.
administrativeAll
;
let
administrativeAll
=
res
.
data
.
administrativeAll
;
let
administrative
=
res
.
data
.
administrative
;
let
administrative
=
res
.
data
.
administrative
;
this
.
treeData
=
[];
this
.
treeData
=
[];
...
@@ -1241,7 +1316,7 @@ export default {
...
@@ -1241,7 +1316,7 @@ export default {
this
.
allSelectedKeys
=
allSelectedKeys
;
this
.
allSelectedKeys
=
allSelectedKeys
;
this
.
initCheckList
(
allSelectedKeys
);
this
.
initCheckList
(
allSelectedKeys
);
console
.
log
(
"allSelectedKeys"
,
allSelectedKeys
);
//
console.log("allSelectedKeys", allSelectedKeys);
//改变行政范围后,更新设定机构和设定人员
//改变行政范围后,更新设定机构和设定人员
this
.
updateOrganizationAndPerson
(
allSelectedKeys
);
this
.
updateOrganizationAndPerson
(
allSelectedKeys
);
this
.
updatedTree
=
true
;
this
.
updatedTree
=
true
;
...
@@ -1462,7 +1537,7 @@ export default {
...
@@ -1462,7 +1537,7 @@ export default {
}
}
}
}
}
}
console
.
log
(
scope
);
//
console.log(scope);
return
scope
;
return
scope
;
},
},
//查询机构列表
//查询机构列表
...
@@ -1478,9 +1553,9 @@ export default {
...
@@ -1478,9 +1553,9 @@ export default {
req
.
scope
=
this
.
getScope
(
"administrative"
);
req
.
scope
=
this
.
getScope
(
"administrative"
);
}
}
openLoading
(
vm
);
openLoading
(
vm
);
vm
.
GET
(
"scope/v1/organization"
,
req
).
then
(
res
=>
{
vm
.
POST
(
"scope/v1/organization"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
closeLoading
(
vm
);
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
//console.log(res.data);
//console.log(res.data);
this
.
tableOrganization
=
res
.
data
.
organizationList
;
this
.
tableOrganization
=
res
.
data
.
organizationList
;
this
.
totalOrganization
=
res
.
data
.
total
;
this
.
totalOrganization
=
res
.
data
.
total
;
...
@@ -1549,6 +1624,15 @@ export default {
...
@@ -1549,6 +1624,15 @@ export default {
vm
.
GET
(
"scope/v1/department"
,
req
).
then
(
res
=>
{
vm
.
GET
(
"scope/v1/department"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
if
(
res
.
code
==
"000000"
)
{
this
.
tableDepartment
=
res
.
data
.
department
;
this
.
tableDepartment
=
res
.
data
.
department
;
let
rowCheck
=
this
.
tableDepartment
;
rowCheck
.
forEach
(
row
=>
{
if
(
row
.
status
==
1
)
{
this
.
$nextTick
(
function
()
{
this
.
$refs
.
multipleDepartment
.
toggleRowSelection
(
row
);
});
}
});
}
}
});
});
},
},
...
@@ -1632,9 +1716,9 @@ export default {
...
@@ -1632,9 +1716,9 @@ export default {
req
.
scopeOfDepartment
=
this
.
getScopeDepartment
();
req
.
scopeOfDepartment
=
this
.
getScopeDepartment
();
}
}
openLoading
(
vm
);
openLoading
(
vm
);
vm
.
GET
(
"scope/v1/people"
,
req
).
then
(
res
=>
{
vm
.
POST
(
"scope/v1/people"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
closeLoading
(
vm
);
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
console
.
log
(
res
);
console
.
log
(
res
);
this
.
tablePerson
=
res
.
data
.
people
;
this
.
tablePerson
=
res
.
data
.
people
;
this
.
totalPerson
=
res
.
data
.
total
;
this
.
totalPerson
=
res
.
data
.
total
;
...
@@ -1724,7 +1808,7 @@ export default {
...
@@ -1724,7 +1808,7 @@ export default {
//选择项目组件
//选择项目组件
//改变组件选择情况
//改变组件选择情况
changeValue
(
value
)
{
changeValue
(
value
)
{
//console.log(
this.formComponent.c
omponent);
//console.log(
'value',value,'optionsComponent',this.optionsC
omponent);
this
.
tagsComponent
=
[];
this
.
tagsComponent
=
[];
let
len
=
0
;
let
len
=
0
;
for
(
let
i
=
0
;
i
<
value
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
value
.
length
;
i
++
)
{
...
@@ -1737,6 +1821,7 @@ export default {
...
@@ -1737,6 +1821,7 @@ export default {
}
}
}
}
}
}
//console.log('this.tagsComponent',this.tagsComponent);
},
},
//选择组件数据绑定
//选择组件数据绑定
handleCloseComponent
(
tag
)
{
handleCloseComponent
(
tag
)
{
...
...
src/views/education/item-manager.vue
浏览文件 @
8f73e1be
...
@@ -30,6 +30,7 @@
...
@@ -30,6 +30,7 @@
type=
"date"
type=
"date"
placeholder=
"请选择开始时间"
placeholder=
"请选择开始时间"
value-format=
"yyyy-MM-dd HH:mm:ss"
value-format=
"yyyy-MM-dd HH:mm:ss"
:picker-options=
"pickerOptions0"
></el-date-picker>
></el-date-picker>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
...
@@ -40,8 +41,8 @@
...
@@ -40,8 +41,8 @@
size=
"mini"
size=
"mini"
type=
"date"
type=
"date"
placeholder=
"请选择结束时间"
placeholder=
"请选择结束时间"
value-format=
"yyyy-MM-dd
HH:mm:ss
"
value-format=
"yyyy-MM-dd
23:59:59
"
:picker-options=
"picker
BeginDateAfter
"
:picker-options=
"picker
Options1
"
></el-date-picker>
></el-date-picker>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
...
@@ -217,15 +218,22 @@ export default {
...
@@ -217,15 +218,22 @@ export default {
projectEndtime
:
""
,
projectEndtime
:
""
,
projectStatus
:
""
,
projectStatus
:
""
,
pageNo
:
1
,
pageNo
:
1
,
pageSize
:
10
pageSize
:
10
,
},
},
picker
BeginDateAfter
:
{
picker
Options0
:
{
disabledDate
:
time
=>
{
disabledDate
:
time
=>
{
let
beginDateVal
=
this
.
formInline
.
projectBegintime
;
if
(
this
.
formInline
.
projectEndtime
!=
""
)
{
if
(
beginDateVal
)
{
return
time
.
getTime
()
>
new
Date
(
this
.
formInline
.
projectEndtime
).
getTime
();
return
time
.
getTime
()
<
beginDateVal
;
}
}
}
}
},
pickerOptions1
:
{
disabledDate
:
time
=>
{
return
(
time
.
getTime
()
<
new
Date
(
this
.
formInline
.
projectBegintime
).
getTime
()
);
//减去一天的时间代表可以选择同一天;
}
}
}
};
};
},
},
...
@@ -237,29 +245,6 @@ export default {
...
@@ -237,29 +245,6 @@ export default {
toPage
()
{
toPage
()
{
this
.
$router
.
push
(
"add-manager"
);
this
.
$router
.
push
(
"add-manager"
);
},
},
setParam
(
data
)
{
let
param
=
{};
if
(
data
.
duringTime
!==
null
&&
data
.
duringTime
!==
""
&&
data
.
duringTime
[
0
]
!==
null
&&
data
.
duringTime
[
1
]
!==
null
)
{
param
.
projectBegintime
=
data
.
duringTime
[
0
];
param
.
projectEndtime
=
data
.
duringTime
[
1
];
}
for
(
let
key
in
data
)
{
if
(
key
!==
"duringTime"
&&
key
!==
"projectBegintime"
&&
key
!==
"projectEndtime"
)
{
param
[
key
]
=
data
[
key
];
}
}
console
.
log
(
param
);
return
param
;
},
//查询项目列表
//查询项目列表
getProjectList
()
{
getProjectList
()
{
let
req
=
{};
let
req
=
{};
...
...
src/views/system/item-role.vue
浏览文件 @
8f73e1be
...
@@ -87,8 +87,8 @@
...
@@ -87,8 +87,8 @@
<el-button
<el-button
type=
"primary"
type=
"primary"
size=
"small"
size=
"small"
v-show=
"showButton(scope.row,'L
4
')"
v-show=
"showButton(scope.row,'L
0
')"
@
click=
"openDialog(scope.row,'L
4
')"
@
click=
"openDialog(scope.row,'L
0
')"
>
降为普通用户
</el-button>
>
降为普通用户
</el-button>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
...
@@ -142,7 +142,7 @@ export default {
...
@@ -142,7 +142,7 @@ export default {
const
item
=
{
const
item
=
{
userId
:
"298490"
,
userId
:
"298490"
,
userName
:
"李雪"
,
userName
:
"李雪"
,
projeceRole
:
"L
4
"
,
projeceRole
:
"L
0
"
,
organizationName
:
"浙江省人民医院"
,
organizationName
:
"浙江省人民医院"
,
departmentsName
:
"外科"
departmentsName
:
"外科"
};
};
...
@@ -181,7 +181,7 @@ export default {
...
@@ -181,7 +181,7 @@ export default {
},
},
{
{
label
:
"普通用户"
,
label
:
"普通用户"
,
value
:
"L
4
"
value
:
"L
0
"
}
}
],
],
numL2
:
0
,
numL2
:
0
,
...
@@ -214,8 +214,8 @@ export default {
...
@@ -214,8 +214,8 @@ export default {
req
=
this
.
formInline
;
req
=
this
.
formInline
;
openLoading
(
vm
);
openLoading
(
vm
);
vm
.
GET
(
"portalProjectOrRole/queryRoleList"
,
req
).
then
(
res
=>
{
vm
.
GET
(
"portalProjectOrRole/queryRoleList"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
closeLoading
(
vm
);
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
vm
.
tableData
=
res
.
data
.
projectRoleInfoModels
;
vm
.
tableData
=
res
.
data
.
projectRoleInfoModels
;
vm
.
totalRows
=
res
.
data
.
total
;
vm
.
totalRows
=
res
.
data
.
total
;
...
@@ -273,14 +273,14 @@ export default {
...
@@ -273,14 +273,14 @@ export default {
let
flag
=
false
;
let
flag
=
false
;
//console.log("当前等级 " + row.projeceRole + " 改变成等级 " + projeceRole);
//console.log("当前等级 " + row.projeceRole + " 改变成等级 " + projeceRole);
if
(
row
.
projeceRole
==
"L2"
)
{
if
(
row
.
projeceRole
==
"L2"
)
{
if
(
projeceRole
==
"L
4
"
)
{
if
(
projeceRole
==
"L
0
"
)
{
flag
=
true
;
flag
=
true
;
}
}
}
else
if
(
row
.
projeceRole
==
"L3"
)
{
}
else
if
(
row
.
projeceRole
==
"L3"
)
{
if
(
projeceRole
==
"L2"
||
projeceRole
==
"L
4
"
)
{
if
(
projeceRole
==
"L2"
||
projeceRole
==
"L
0
"
)
{
flag
=
true
;
flag
=
true
;
}
}
}
else
if
(
row
.
projeceRole
==
"L
4
"
)
{
}
else
if
(
row
.
projeceRole
==
"L
0
"
)
{
if
(
projeceRole
==
"L2"
||
projeceRole
==
"L3"
)
{
if
(
projeceRole
==
"L2"
||
projeceRole
==
"L3"
)
{
flag
=
true
;
flag
=
true
;
}
}
...
@@ -300,17 +300,17 @@ export default {
...
@@ -300,17 +300,17 @@ export default {
this
.
scopeRow
.
updateL
=
projeceRole
;
this
.
scopeRow
.
updateL
=
projeceRole
;
if
(
row
.
projeceRole
==
"L2"
)
{
if
(
row
.
projeceRole
==
"L2"
)
{
this
.
dialog
.
role
=
"项目负责人"
;
this
.
dialog
.
role
=
"项目负责人"
;
if
(
projeceRole
==
"L
4
"
)
{
if
(
projeceRole
==
"L
0
"
)
{
this
.
dialog
.
option
=
"降级为普通用户"
;
this
.
dialog
.
option
=
"降级为普通用户"
;
}
}
}
else
if
(
row
.
projeceRole
==
"L3"
)
{
}
else
if
(
row
.
projeceRole
==
"L3"
)
{
this
.
dialog
.
role
=
"次级负责人"
;
this
.
dialog
.
role
=
"次级负责人"
;
if
(
projeceRole
==
"L2"
)
{
if
(
projeceRole
==
"L2"
)
{
this
.
dialog
.
option
=
"升级为项目负责人"
;
this
.
dialog
.
option
=
"升级为项目负责人"
;
}
else
if
(
projeceRole
==
"L
4
"
)
{
}
else
if
(
projeceRole
==
"L
0
"
)
{
this
.
dialog
.
option
=
"降级为普通用户"
;
this
.
dialog
.
option
=
"降级为普通用户"
;
}
}
}
else
if
(
row
.
projeceRole
==
"L
4
"
)
{
}
else
if
(
row
.
projeceRole
==
"L
0
"
)
{
this
.
dialog
.
role
=
"普通用户"
;
this
.
dialog
.
role
=
"普通用户"
;
if
(
projeceRole
==
"L2"
)
{
if
(
projeceRole
==
"L2"
)
{
this
.
dialog
.
option
=
"升级为项目负责人"
;
this
.
dialog
.
option
=
"升级为项目负责人"
;
...
...
src/views/system/role.vue
浏览文件 @
8f73e1be
...
@@ -13,16 +13,28 @@
...
@@ -13,16 +13,28 @@
<el-col
:span=
"6"
>
<el-col
:span=
"6"
>
<el-form-item
label=
"项目时间:"
>
<el-form-item
label=
"项目时间:"
>
<el-date-picker
<el-date-picker
v-model=
"formInline.projectBegintime"
size=
"mini"
size=
"mini"
type=
"daterange"
type=
"date"
start-placeholder=
"请选择项目开始时间"
placeholder=
"请选择开始时间"
end-placeholder=
"请选择项目结束时间"
v-model=
"formInline.duringTime"
value-format=
"yyyy-MM-dd HH:mm:ss"
value-format=
"yyyy-MM-dd HH:mm:ss"
:picker-options=
"pickerOptions0"
></el-date-picker>
></el-date-picker>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:span=
"12"
style=
"padding:0;text-align:right;padding-right:15px;"
>
<el-col
:span=
"4"
>
<el-form-item
label=
"~"
>
<el-date-picker
v-model=
"formInline.projectEndtime"
size=
"mini"
type=
"date"
placeholder=
"请选择结束时间"
value-format=
"yyyy-MM-dd 23:59:59"
:picker-options=
"pickerOptions1"
></el-date-picker>
</el-form-item>
</el-col>
<el-col
:span=
"8"
style=
"padding:0;text-align:right;padding-right:15px;"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"search"
>
查询
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"search"
>
查询
</el-button>
<el-button
type=
"default"
size=
"small"
@
click=
"resetForm"
style=
"margin-left:0;"
>
重置
</el-button>
<el-button
type=
"default"
size=
"small"
@
click=
"resetForm"
style=
"margin-left:0;"
>
重置
</el-button>
</el-col>
</el-col>
...
@@ -87,9 +99,24 @@ export default {
...
@@ -87,9 +99,24 @@ export default {
projectName
:
""
,
projectName
:
""
,
projectBegintime
:
""
,
projectBegintime
:
""
,
projectEndtime
:
""
,
projectEndtime
:
""
,
duringTime
:
""
,
pageNo
:
1
,
pageNo
:
1
,
pageSize
:
10
pageSize
:
10
,
type
:
2
,
},
pickerOptions0
:
{
disabledDate
:
time
=>
{
if
(
this
.
formInline
.
projectEndtime
!=
""
)
{
return
time
.
getTime
()
>
new
Date
(
this
.
formInline
.
projectEndtime
).
getTime
();
}
}
},
pickerOptions1
:
{
disabledDate
:
time
=>
{
return
(
time
.
getTime
()
<
new
Date
(
this
.
formInline
.
projectBegintime
).
getTime
()
);
//减去一天的时间代表可以选择同一天;
}
}
}
};
};
},
},
...
@@ -98,37 +125,14 @@ export default {
...
@@ -98,37 +125,14 @@ export default {
this
.
search
();
this
.
search
();
},
},
methods
:
{
methods
:
{
setParam
(
data
)
{
let
param
=
{};
if
(
data
.
duringTime
!==
null
&&
data
.
duringTime
!==
""
&&
data
.
duringTime
[
0
]
!==
null
&&
data
.
duringTime
[
1
]
!==
null
)
{
param
.
projectBegintime
=
data
.
duringTime
[
0
];
param
.
projectEndtime
=
data
.
duringTime
[
1
];
}
for
(
let
key
in
data
)
{
if
(
key
!==
"duringTime"
&&
key
!==
"projectBegintime"
&&
key
!==
"projectEndtime"
)
{
param
[
key
]
=
data
[
key
];
}
}
console
.
log
(
param
);
return
param
;
},
search
()
{
search
()
{
let
req
=
{};
let
req
=
{};
console
.
log
(
this
.
formInline
);
//
console.log(this.formInline);
req
=
this
.
setParam
(
this
.
formInline
)
;
req
=
this
.
formInline
;
openLoading
(
vm
);
openLoading
(
vm
);
vm
.
GET
(
"portalInfo/getProjectList"
,
req
).
then
(
res
=>
{
vm
.
GET
(
"portalInfo/getProjectList"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
closeLoading
(
vm
);
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
vm
.
tableData
=
res
.
data
.
data
;
vm
.
tableData
=
res
.
data
.
data
;
vm
.
totalRows
=
res
.
data
.
totalRows
;
vm
.
totalRows
=
res
.
data
.
totalRows
;
}
}
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录