Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
workbook
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
黄志强
workbook
Commits
be8fca58
提交
be8fca58
authored
4月 20, 2020
作者:
黄志强
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改
上级
45e18bbb
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
111 行增加
和
33 行删除
+111
-33
index.js
src/axios/index.js
+3
-3
roleDialog.vue
src/components/roleDialog.vue
+26
-6
ConsumerManage.vue
src/views/root/ConsumerManage.vue
+2
-0
AddTask.vue
src/views/task/AddTask.vue
+7
-0
TaskDetails.vue
src/views/task/TaskDetails.vue
+73
-24
没有找到文件。
src/axios/index.js
浏览文件 @
be8fca58
let
baseUrl
=
"http
://192.168.1.59
:8289"
;
// 120.55.57.35 localhost 8289
let
baseUrl
=
"http
s://workbook.zjtys.com.cn
:8289"
;
// 120.55.57.35 localhost 8289
let
env
=
process
.
env
.
VUE_APP_TITLE
===
'alpha'
?
'alpha'
:
'production'
;
let
env
=
process
.
env
.
VUE_APP_TITLE
===
'alpha'
?
'alpha'
:
'production'
;
switch
(
env
)
{
switch
(
env
)
{
case
'production'
:
case
'production'
:
// baseUrl = "http://192.168.1.248:8090"; // 测试环境
// baseUrl = "http://192.168.1.248:8090"; // 测试环境
baseUrl
=
"http
://192.168.1.59
:8289"
;
// 测试环境
baseUrl
=
"http
s://workbook.zjtys.com.cn
:8289"
;
// 测试环境
break
;
break
;
case
'alpha'
:
case
'alpha'
:
// baseUrl = "https://workbook.zjtys.com.cn"; // 阿里云环境
// baseUrl = "https://workbook.zjtys.com.cn"; // 阿里云环境
baseUrl
=
"http
://192.168.1.59
:8289"
;
// 阿里云环境
baseUrl
=
"http
s://workbook.zjtys.com.cn
:8289"
;
// 阿里云环境
break
;
break
;
}
}
// https://workbook.zjtys.com.cn:8289
// https://workbook.zjtys.com.cn:8289
...
...
src/components/roleDialog.vue
浏览文件 @
be8fca58
...
@@ -11,12 +11,24 @@
...
@@ -11,12 +11,24 @@
<el-form-item
label=
"角色名称"
prop=
"name"
>
<el-form-item
label=
"角色名称"
prop=
"name"
>
<el-input
v-model=
"roleForm.name"
placeholder=
"请输入角色名称"
></el-input>
<el-input
v-model=
"roleForm.name"
placeholder=
"请输入角色名称"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"角色职位"
prop=
"isLeader"
>
<el-row
:gutter=
"20"
>
<el-radio-group
v-model=
"roleForm.isLeader"
>
<el-col
:span=
"12"
>
<el-radio
label=
"0"
>
部门领导
</el-radio>
<el-form-item
label=
"角色职位"
prop=
"isLeader"
>
<el-radio
label=
"1"
>
普通员工
</el-radio>
<el-radio-group
v-model=
"roleForm.isLeader"
>
</el-radio-group>
<el-radio
label=
"0"
>
部门领导
</el-radio>
</el-form-item>
<el-radio
label=
"1"
>
普通员工
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
v-if=
"roleForm.isLeader === '0'"
label=
"正副级"
prop=
"isPlus"
>
<el-radio-group
v-model=
"roleForm.isPlus"
>
<el-radio
label=
"0"
>
正
</el-radio>
<el-radio
label=
"1"
>
副
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
<el-form-item
label=
"角色权限"
prop=
"authorities"
>
<el-form-item
label=
"角色权限"
prop=
"authorities"
>
<el-checkbox-group
v-model=
"roleForm.authorities"
>
<el-checkbox-group
v-model=
"roleForm.authorities"
>
<el-checkbox
v-for=
"(item,index) in authorityList"
:label=
"item.id"
:key=
"index"
>
{{
item
.
name
}}
</el-checkbox>
<el-checkbox
v-for=
"(item,index) in authorityList"
:label=
"item.id"
:key=
"index"
>
{{
item
.
name
}}
</el-checkbox>
...
@@ -57,6 +69,7 @@
...
@@ -57,6 +69,7 @@
description
:
''
,
description
:
''
,
authorities
:
[],
authorities
:
[],
departmentId
:
''
,
departmentId
:
''
,
isPlus
:
''
,
},
},
rules
:{
rules
:{
name
:
[
name
:
[
...
@@ -68,6 +81,9 @@
...
@@ -68,6 +81,9 @@
isLeader
:
[
isLeader
:
[
{
required
:
true
,
message
:
'请选择角色职位'
,
trigger
:
'change'
}
{
required
:
true
,
message
:
'请选择角色职位'
,
trigger
:
'change'
}
],
],
isPlus
:
[
{
required
:
true
,
message
:
'请选择正副级'
,
trigger
:
'change'
}
],
description
:
[
description
:
[
{
required
:
true
,
message
:
'请填写角色描述'
,
trigger
:
'blur'
}
{
required
:
true
,
message
:
'请填写角色描述'
,
trigger
:
'blur'
}
]
]
...
@@ -135,6 +151,7 @@
...
@@ -135,6 +151,7 @@
this
.
roleForm
.
isLeader
=
''
;
this
.
roleForm
.
isLeader
=
''
;
this
.
roleForm
.
description
=
''
;
this
.
roleForm
.
description
=
''
;
this
.
roleForm
.
authorities
=
[];
this
.
roleForm
.
authorities
=
[];
this
.
roleForm
.
isPlus
=
''
;
this
.
$refs
[
val
].
resetFields
();
this
.
$refs
[
val
].
resetFields
();
this
.
$emit
(
'close'
,
false
);
this
.
$emit
(
'close'
,
false
);
},
},
...
@@ -154,6 +171,9 @@
...
@@ -154,6 +171,9 @@
console
.
log
(
arr
)
console
.
log
(
arr
)
let
data
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
roleForm
));
let
data
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
roleForm
));
data
.
authorities
=
arr
;
data
.
authorities
=
arr
;
if
(
data
.
isPlus
!==
'0'
&&
data
.
isPlus
!==
'1'
)
{
data
.
isPlus
=
null
;
}
console
.
log
(
data
)
console
.
log
(
data
)
console
.
log
(
this
.
dialogName
)
console
.
log
(
this
.
dialogName
)
if
(
this
.
dialogName
===
'修改角色'
)
{
if
(
this
.
dialogName
===
'修改角色'
)
{
...
...
src/views/root/ConsumerManage.vue
浏览文件 @
be8fca58
...
@@ -152,6 +152,8 @@
...
@@ -152,6 +152,8 @@
closeConsumerDialog
(
val
)
{
closeConsumerDialog
(
val
)
{
if
(
val
===
'修改用户'
)
{
if
(
val
===
'修改用户'
)
{
this
.
getUser
();
this
.
getUser
();
}
else
if
(
val
===
'新增用户'
)
{
this
.
getUser
();
}
}
this
.
showConsumerDialog
=
false
;
this
.
showConsumerDialog
=
false
;
},
},
...
...
src/views/task/AddTask.vue
浏览文件 @
be8fca58
...
@@ -302,6 +302,13 @@
...
@@ -302,6 +302,13 @@
}
}
this
.
taskForm
.
workload
=
count
;
this
.
taskForm
.
workload
=
count
;
}
}
},
content
:
function
(
val
)
{
if
(
val
===
''
)
{
this
.
contentTip
=
true
;
}
else
{
this
.
contentTip
=
false
;
}
}
}
},
},
//方法集合
//方法集合
...
...
src/views/task/TaskDetails.vue
浏览文件 @
be8fca58
...
@@ -502,14 +502,15 @@
...
@@ -502,14 +502,15 @@
callback
();
callback
();
}
}
}
else
{
}
else
{
if
(
this
.
evaForm
.
score1
===
''
)
{
//this.evaForm.score1 === ''
if
(
this
.
saveEvaScore
.
score1
===
undefined
||
this
.
saveEvaScore
.
score1
===
null
||
this
.
saveEvaScore
.
score1
===
''
)
{
callback
();
callback
();
}
}
// else if (this.evaForm.score1 !== '' && this.evaForm.groupLeaderScore2 !== '') {
// else if (this.evaForm.score1 !== '' && this.evaForm.groupLeaderScore2 !== '') {
// console.log(22222222222)
// console.log(22222222222)
// callback();
// callback();
// }
// }
else
if
(
this
.
evaStatus
!==
'1'
&&
this
.
evaStatus
!==
'2'
)
{
else
if
(
this
.
evaStatus
!==
'1'
&&
this
.
evaStatus
!==
'2'
)
{
callback
();
callback
();
}
}
else
{
else
{
...
@@ -543,6 +544,8 @@
...
@@ -543,6 +544,8 @@
callback
();
callback
();
}
else
if
(
!
value
)
{
}
else
if
(
!
value
)
{
return
callback
(
new
Error
(
'评分不能为空'
));
return
callback
(
new
Error
(
'评分不能为空'
));
}
else
if
(
this
.
saveEvaScore
.
directorScore2
!==
''
)
{
callback
();
}
}
}
}
// if ((this.taskForm.majordomos !== undefined && this.taskForm.majordomos.length > 0 && this.taskForm.majordomos.findIndex(item => item.id === this.userDetail.id) === -1) || this.evaStatus === '1' || this.evaStatus === '2' || this.evaStatus === '4' || this.evaStatus === '5' || this.evaStatus === '6') {
// if ((this.taskForm.majordomos !== undefined && this.taskForm.majordomos.length > 0 && this.taskForm.majordomos.findIndex(item => item.id === this.userDetail.id) === -1) || this.evaStatus === '1' || this.evaStatus === '2' || this.evaStatus === '4' || this.evaStatus === '5' || this.evaStatus === '6') {
...
@@ -1409,9 +1412,20 @@
...
@@ -1409,9 +1412,20 @@
return
false
;
return
false
;
}
}
}
else
{
}
else
{
if
(
this
.
isEditEva
===
true
&&
this
.
isExecutor
===
true
)
{
if
(
this
.
isEditEva
===
true
&&
this
.
isExecutor
===
true
&&
this
.
taskForm
.
majordomos
!==
undefined
&&
this
.
taskForm
.
majordomos
.
length
>
0
&&
this
.
dialogTaskEvaVisible
=
false
;
this
.
taskForm
.
majordomos
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
===
-
1
&&
return
false
;
this
.
taskForm
.
assistantManagers
!==
undefined
&&
this
.
taskForm
.
assistantManagers
.
length
>
0
&&
this
.
taskForm
.
assistantManagers
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
===
-
1
&&
this
.
taskForm
.
generalManagers
!==
undefined
&&
this
.
taskForm
.
generalManagers
.
length
>
0
&&
this
.
taskForm
.
generalManagers
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
===
-
1
)
{
// if (this.taskForm.majordomos !== undefined && this.taskForm.majordomos.length > 0 && this.taskForm.majordomos.findIndex(item => item.id === this.userDetail.id) === -1) {
// this.dialogTaskEvaVisible = false;
// return false;
// } else if (this.taskForm.assistantManagers !== undefined && this.taskForm.assistantManagers.length > 0 && this.taskForm.assistantManagers.findIndex(item => item.id === this.userDetail.id) === -1) {
// this.dialogTaskEvaVisible = false;
// return false;
// } else if (this.taskForm.generalManagers !== undefined && this.taskForm.generalManagers.length > 0 && this.taskForm.generalManagers.findIndex(item => item.id === this.userDetail.id) === -1) {
this
.
dialogTaskEvaVisible
=
false
;
return
false
;
// }
}
}
// else if (this.isAudit === true && this.evaForm.groupLeaderScore2 !== '' && this.evaStatus === '3') {
// else if (this.isAudit === true && this.evaForm.groupLeaderScore2 !== '' && this.evaStatus === '3') {
// this.dialogTaskEvaVisible = false;
// this.dialogTaskEvaVisible = false;
...
@@ -1439,7 +1453,10 @@
...
@@ -1439,7 +1453,10 @@
// this.showGenTip = true;
// this.showGenTip = true;
}
else
if
(
this
.
taskForm
.
assistantManagers
!==
undefined
&&
this
.
taskForm
.
assistantManagers
.
length
>
0
&&
this
.
taskForm
.
assistantManagers
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
>
-
1
)
{
}
else
if
(
this
.
taskForm
.
assistantManagers
!==
undefined
&&
this
.
taskForm
.
assistantManagers
.
length
>
0
&&
this
.
taskForm
.
assistantManagers
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
>
-
1
)
{
if
(
this
.
isAudit
===
false
)
{
if
(
this
.
isAudit
===
false
)
{
if
(
this
.
evaStatus
===
'1'
||
this
.
evaStatus
===
'2'
||
this
.
evaStatus
===
'3'
)
{
if
(
this
.
evaStatus
===
'1'
)
{
this
.
dialogTaskEvaVisible
=
false
;
return
false
;
}
else
if
(
this
.
evaStatus
===
'2'
&&
this
.
taskForm
.
majordomos
!==
undefined
&&
this
.
taskForm
.
majordomos
.
length
>
0
&&
this
.
taskForm
.
majordomos
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
===
-
1
){
this
.
dialogTaskEvaVisible
=
false
;
this
.
dialogTaskEvaVisible
=
false
;
return
false
;
return
false
;
}
else
if
(
this
.
evaStatus
===
'5'
)
{
}
else
if
(
this
.
evaStatus
===
'5'
)
{
...
@@ -1484,7 +1501,17 @@
...
@@ -1484,7 +1501,17 @@
let
msgs
=
''
;
let
msgs
=
''
;
if
(
this
.
evaStatus
===
'2'
)
{
if
(
this
.
evaStatus
===
'2'
)
{
if
(
this
.
taskForm
.
majordomos
!==
undefined
&&
this
.
taskForm
.
majordomos
.
length
>
0
&&
this
.
taskForm
.
majordomos
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
>
-
1
)
{
if
(
this
.
taskForm
.
majordomos
!==
undefined
&&
this
.
taskForm
.
majordomos
.
length
>
0
&&
this
.
taskForm
.
majordomos
.
findIndex
(
item
=>
item
.
id
===
this
.
userDetail
.
id
)
>
-
1
)
{
if
(
this
.
saveEvaScore
.
directorScore2
!==
''
&&
this
.
saveEvaScore
.
directorScore2
!==
null
&&
this
.
saveEvaScore
.
directorScore2
!==
undefined
)
{
if
(
this
.
saveEvaScore
.
groupLeaderScore2
!==
''
&&
this
.
saveEvaScore
.
groupLeaderScore2
!==
null
&&
this
.
saveEvaScore
.
groupLeaderScore2
!==
undefined
&&
this
.
saveEvaScore
.
directorScore2
!==
''
&&
this
.
saveEvaScore
.
directorScore2
!==
null
&&
this
.
saveEvaScore
.
directorScore2
!==
undefined
)
{
objs
.
score1
=
objs
.
score1
+
''
;
objs
.
groupLeaderScore2
=
objs
.
groupLeaderScore2
+
''
;
objs
.
directorScore2
=
objs
.
directorScore2
+
''
;
msgs
=
'总监考评'
;
}
else
if
((
this
.
saveEvaScore
.
groupLeaderScore2
===
''
||
this
.
saveEvaScore
.
groupLeaderScore2
===
null
||
this
.
saveEvaScore
.
groupLeaderScore2
===
undefined
)
&&
this
.
saveEvaScore
.
directorScore2
!==
''
&&
this
.
saveEvaScore
.
directorScore2
!==
null
&&
this
.
saveEvaScore
.
directorScore2
!==
undefined
)
{
objs
.
score1
=
objs
.
score1
+
''
;
objs
.
groupLeaderScore2
=
objs
.
groupLeaderScore2
+
''
;
objs
.
directorScore2
=
objs
.
directorScore2
+
''
;
msgs
=
'组长考评'
;
}
else
if
(
this
.
saveEvaScore
.
directorScore2
!==
''
&&
this
.
saveEvaScore
.
directorScore2
!==
null
&&
this
.
saveEvaScore
.
directorScore2
!==
undefined
)
{
objs
.
score1
=
objs
.
score1
+
''
;
objs
.
score1
=
objs
.
score1
+
''
;
objs
.
groupLeaderScore2
=
objs
.
groupLeaderScore2
+
''
;
objs
.
groupLeaderScore2
=
objs
.
groupLeaderScore2
+
''
;
objs
.
directorScore2
=
objs
.
directorScore2
+
''
;
objs
.
directorScore2
=
objs
.
directorScore2
+
''
;
...
@@ -1744,20 +1771,11 @@
...
@@ -1744,20 +1771,11 @@
re
:
re
re
:
re
}
}
console
.
log
(
this
.
attachmentsArr
);
console
.
log
(
this
.
attachmentsArr
);
this
.
$axios
.
postAttachmentWorkId
(
this
.
taskListData
.
workId
,
this
.
attachmentsArr
).
then
((
res
)
=>
{
if
(
this
.
attachmentsArr
.
length
===
0
)
{
console
.
log
(
res
);
this
.
$axios
.
putTaskStatus
(
obj
).
then
((
res
)
=>
{
if
(
res
.
status
===
200
)
{
console
.
log
(
res
)
this
.
withdrawTaskTextarea
=
''
;
if
(
res
.
request
.
status
===
200
)
{
this
.
submitTaskTextarea
=
''
;
// if (res.data.id !== undefined) {
this
.
attachmentsArr
=
[];
this
.
fileList
=
[];
this
.
$refs
.
upload
.
clearFiles
();
}
})
this
.
$axios
.
putTaskStatus
(
obj
).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
.
request
.
status
===
200
)
{
// if (res.data.id !== undefined) {
this
.
$message
({
this
.
$message
({
message
:
tip
+
'任务成功!'
,
message
:
tip
+
'任务成功!'
,
type
:
'success'
type
:
'success'
...
@@ -1767,9 +1785,39 @@
...
@@ -1767,9 +1785,39 @@
this
.
dialogTaskSubmitVisible
=
false
;
this
.
dialogTaskSubmitVisible
=
false
;
this
.
dialogTaskWithdrawVisible
=
false
;
this
.
dialogTaskWithdrawVisible
=
false
;
this
.
getDetailsTask
(
this
.
taskListData
.
workId
);
this
.
getDetailsTask
(
this
.
taskListData
.
workId
);
// }
// }
}
}
})
})
}
else
{
this
.
$axios
.
postAttachmentWorkId
(
this
.
taskListData
.
workId
,
this
.
attachmentsArr
).
then
((
res
)
=>
{
console
.
log
(
res
);
if
(
res
.
status
===
200
)
{
this
.
withdrawTaskTextarea
=
''
;
this
.
submitTaskTextarea
=
''
;
this
.
attachmentsArr
=
[];
this
.
fileList
=
[];
this
.
$refs
.
upload
.
clearFiles
();
this
.
$axios
.
putTaskStatus
(
obj
).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
.
request
.
status
===
200
)
{
// if (res.data.id !== undefined) {
this
.
$message
({
message
:
tip
+
'任务成功!'
,
type
:
'success'
});
this
.
submitTaskTextarea
=
''
;
this
.
withdrawTaskTextarea
=
''
;
this
.
dialogTaskSubmitVisible
=
false
;
this
.
dialogTaskWithdrawVisible
=
false
;
this
.
getDetailsTask
(
this
.
taskListData
.
workId
);
// }
}
})
}
})
}
},
},
submitDeleteDialog
()
{
submitDeleteDialog
()
{
console
.
log
(
this
.
deleteCheck
)
console
.
log
(
this
.
deleteCheck
)
...
@@ -1850,6 +1898,7 @@
...
@@ -1850,6 +1898,7 @@
},
},
breakDownTask
()
{
breakDownTask
()
{
console
.
log
(
this
.
taskForm
)
console
.
log
(
this
.
taskForm
)
console
.
log
(
this
.
leaderOptions
)
let
arr
=
[];
let
arr
=
[];
if
(
this
.
taskForm
.
crewList
!==
null
&&
this
.
taskForm
.
crewList
.
length
>
0
)
{
if
(
this
.
taskForm
.
crewList
!==
null
&&
this
.
taskForm
.
crewList
.
length
>
0
)
{
console
.
log
(
this
.
taskForm
.
crewList
[
0
].
username
);
console
.
log
(
this
.
taskForm
.
crewList
[
0
].
username
);
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论