Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
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
罗超
confucius
Commits
d28b8ef1
Commit
d28b8ef1
authored
Jul 13, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
1a67b76d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
215 additions
and
134 deletions
+215
-134
document.js
src/api/administration/document.js
+22
-0
document.vue
src/pages/administration/document.vue
+1
-1
documentApproval.vue
src/pages/administration/documentApproval.vue
+192
-133
No files found.
src/api/administration/document.js
View file @
d28b8ef1
...
...
@@ -86,3 +86,25 @@ export function GetNoticeInfo(data) {
data
});
}
/**
* 公告审批
*/
export
function
setReviewNotice
(
data
)
{
return
request
({
url
:
'/UserCenter/SetReviewNotice'
,
method
:
'post'
,
data
});
}
/**
* 获取我审批的公告
*/
export
function
getMyApproval
(
data
)
{
return
request
({
url
:
'/UserCenter/GetNoticeLogPageList'
,
method
:
'post'
,
data
});
}
src/pages/administration/document.vue
View file @
d28b8ef1
...
...
@@ -170,7 +170,7 @@
<q-btn
label=
"草稿"
color=
"accent q-px-md"
size=
"sm"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"save_t(2)"
/>
<q-btn
label=
"立即提交"
color=
"accent q-px-md"
size=
"sm"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"save_t(
1
)"
/>
@
click=
"save_t(
4
)"
/>
</q-card-actions>
</q-card>
</q-dialog>
...
...
src/pages/administration/documentApproval.vue
View file @
d28b8ef1
<
template
>
<div
class=
"page-body document"
>
<q-tabs
style=
"margin-bottom:20px;"
v-model=
"tabCheck"
@
input=
"tabChange()"
narrow-indicator
dense
align=
"left"
<q-tabs
style=
"margin-bottom:20px;"
v-model=
"tabCheck"
@
input=
"tabChange()"
narrow-indicator
dense
align=
"left"
class=
"text-primary"
>
<q-tab
:ripple=
"false"
name=
"first"
label=
"
公文
"
/>
<q-tab
:ripple=
"false"
name=
"second"
label=
"
基础设置
"
/>
<q-tab
:ripple=
"false"
name=
"first"
label=
"
待我审批
"
/>
<q-tab
:ripple=
"false"
name=
"second"
label=
"
我审批的
"
/>
</q-tabs>
<template
v-if=
"tabCheck
==
'first'"
>
<template
v-if=
"tabCheck
==
'first'"
>
<div
class=
"page-search row items-center"
>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-3"
>
...
...
@@ -27,21 +27,16 @@
</q-item>
</
template
>
</q-select>
<div
class=
"col-3"
>
<q-select
@
input=
"getList"
filled
stack-label
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.NoticeState"
ref=
"DeptTier"
:options=
"NoticeList"
label=
"发布状态"
:dense=
"false"
class=
"col-6 q-pr-lg"
emit-value
map-options
/>
</div>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-tow-column-table"
separator=
"none"
title=
""
:data=
"data"
:columns=
"columns"
row-key=
"name"
>
<
template
v-slot:top=
"props"
>
<div
class=
"page-option"
style=
"width:100%;"
>
<
!--
<
div
class=
"page-option"
style=
"width:100%;"
>
<q-btn
color=
"accent"
style=
"float:right;margin-right:0;"
size=
"sm"
class=
"q-mr-md"
icon=
"add"
label=
"发布公文"
@
click=
"addDoc(null)"
/>
</div>
</div>
-->
</
template
>
<
template
v-slot:body-cell-NoticeStateName=
"props"
>
<q-td
:props=
"props"
>
...
...
@@ -62,18 +57,10 @@
</
template
>
<
template
v-slot:body-cell-optioned=
"props"
>
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-zhiding"
style=
"font-weight:400;color: #789CFF"
class=
"q-mr-xs"
label=
"置顶"
@
click=
"setNoticeOtion(props.row.Id,1)"
v-if=
"props.row.NoticeState==1&&props.row.Is_Top==2"
/>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-quxiaozhiding1"
style=
"font-weight:400;color:#FF7C93;"
class=
"q-mr-xs"
label=
"取消置顶"
@
click=
"setNoticeOtion(props.row.Id,2)"
v-if=
"props.row.NoticeState==1&&props.row.Is_Top==1"
/>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-xiangqing-"
style=
"font-weight:400;color: #3FC4FF"
class=
"q-mr-xs"
label=
"详情"
@
click=
"EditConfig(props.row.Id)"
/>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-chehui4"
color=
"deep-orange"
style=
"font-weight:400"
class=
"q-mr-xs"
label=
"撤回"
@
click=
"setNoticeOtion(props.row.Id,3)"
v-if=
"props.row.NoticeState==1"
/>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-xiugai1"
style=
"font-weight:400;color: #02C499"
class=
"q-mr-xs"
label=
"修改"
v-if=
"props.row.NoticeState!=1"
@
click=
"addDoc(props.row.Id)"
/>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-xiangqing-"
style=
"font-weight:400;color: #3FC4FF"
class=
"q-mr-xs"
label=
"审批"
@
click=
"showApproval(props.row.Id)"
/>
</q-td>
</
template
>
<
template
v-slot:bottom
>
...
...
@@ -83,101 +70,58 @@
</q-table>
</div>
</template>
<
template
v-if=
"tabCheck=='second'"
>
<div
class=
"page-content "
>
<div
class=
"second-item col-6 q-pr-lg q-pb-lg"
>
<div
class=
"col-2 q-pr-lg q-pb-lg"
>
<q-uploader
style=
"display: inline-block;max-height: 320px;max-width: 100%; background-repeat:no-repeat"
:style=
"
{'background-image':'url(' + NoticeBaseInfo.Image + ')'}" max-files="1" hide-upload-btn
@rejected="onRejected" label="公文抬头图片" accept=".jpg, image/*" auto-upload :factory="uploadFile"
no-thumbnails>
</q-uploader>
</div>
<div
class=
"row"
>
<div
class=
"col-4"
>
<q-input
clearable
standout=
"bg-primary text-white"
v-model=
"NoticeBaseInfo.From"
label=
"公文来源(FR)"
/>
</div>
</div>
<div
class=
"row"
>
<div
class=
"col-4"
style=
"margin-top: 20px"
>
<q-select
filled
stack-label
option-value=
"Id"
option-label=
"Name"
v-model=
"NoticeBaseInfo.NumberRule"
ref=
"DeptTier"
:options=
"RuleEnumList"
label=
"编号规则"
:dense=
"false"
class=
"col-6 q-pr-lg q-pb-lg"
emit-value
map-options
clearable
/>
</div>
<
template
v-if=
"tabCheck == 'second'"
>
<div
class=
"page-search row items-center"
>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-3"
>
<q-input
clearable
@
change=
"getMyList"
standout=
"bg-primary text-white"
v-model=
"mymsg.Title"
label=
"公文标题"
@
clear=
"getMyList"
/>
</div>
<div
class=
"row"
>
<div
class=
"col-4"
>
<q-select
class=
"col-6 q-pb-lg q-pr-lg"
multiple
clearable
filled
stack-label
use-input
use-chips
option-value=
"Id"
option-label=
"EmployeeName"
v-model=
"tempManager"
ref=
"ManagerId"
:options=
"PersionList"
label=
"默认抄送"
:dense=
"false"
emit-value
map-options
@
filter=
"filterFn"
>
<template
v-slot:no-option
>
<q-item>
<q-item-section
class=
"text-grey"
>
未找到相关数据
</q-item-section>
</q-item>
</
template
>
</q-select>
</div>
<div
class=
"col-3"
>
<q-input
clearable
@
change=
"getMyList"
standout=
"bg-primary text-white"
v-model=
"mymsg.Number"
label=
"编号"
@
clear=
"getMyList"
/>
</div>
<q-btn
label=
"立即提交"
color=
"accent q-px-md"
size=
"sm"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"save"
/>
<q-select
@
input=
"getMyList"
filled
stack-label
option-value=
"Id"
option-label=
"EmployeeName"
use-input
v-model=
"mymsg.UpdateBy"
ref=
"DeptTier"
:options=
"PersionList"
label=
"发布人"
:dense=
"false"
class=
"col-3 q-pr-lg"
emit-value
map-options
@
filter=
"filterFn"
clearable
@
clear=
"getMyList"
>
<template
v-slot:no-option
>
<q-item>
<q-item-section
class=
"text-grey"
>
未找到相关数据
</q-item-section>
</q-item>
</
template
>
</q-select>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"mymsg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-tow-column-table"
separator=
"none"
title=
""
:data=
"mydata"
:columns=
"mycolumns"
row-key=
"name"
>
<
template
v-slot:top=
"props"
>
</
template
>
<
template
v-slot:body-cell-IsTop=
"props"
>
<q-td
:props=
"props"
>
<span
v-if=
"props.row.Is_Top==1"
>
是
</span>
<span
v-if=
"props.row.Is_Top==2"
>
否
</span>
</q-td>
</
template
>
<
template
v-slot:body-cell-optioned=
"props"
>
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"iconfont icon-xiangqing-"
style=
"font-weight:400;color: #3FC4FF"
class=
"q-mr-xs"
label=
"详情"
@
click=
"EditConfig(props.row.Id)"
/>
</q-td>
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"mymsg.PageIndex"
color=
"primary"
:max=
"mypageCount"
:input=
"true"
@
input=
"myChangePage"
/>
</
template
>
</q-table>
</div>
</template>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-card
style=
"width: 800px;max-width:900px;"
>
<q-card-section>
<div
class=
"text-h6"
>
{{addMsg.Id==0?'发布公告':'修改公告'}}
</div>
</q-card-section>
<div
class=
"text-caption q-mb-lg q-px-md text-grey-6"
>
基本资料
</div>
<q-card-section
class=
"q-pt-none"
>
<div
class=
"row wrap"
>
<q-input
clearable
filled
class=
"col-6 q-pb-lg q-pr-lg"
standout=
"bg-primary text-white"
v-model=
"addMsg.From"
ref=
"From"
label=
"公文来源(FR)"
:rules=
"[val => !!val || '公文来源(FR)']"
/>
<div
class=
"col-6 q-pb-lg q-pr-lg"
>
<q-radio
v-model=
"addMsg.SendType"
:val=
"1"
label=
"全公司"
/>
<q-radio
v-model=
"addMsg.SendType"
:val=
"2"
label=
"指定部门"
/>
</div>
<selectTree
v-if=
"addMsg.SendType==2"
class=
"col-6 q-pb-lg q-pr-lg"
:treeData=
'DeptList'
:defaultArray=
"returnString"
nodeKey=
"DeptId"
:multiple=
"true"
:defaultExpandAll=
"true"
labelKey=
"DeptName"
childrenKey=
"ChildList"
tipText=
"To"
@
getChild=
"getChild"
classStr=
"col-6 q-pr-lg q-pb-lg"
></selectTree>
<q-select
class=
"col-6 q-pb-lg q-pr-lg"
multiple
clearable
filled
stack-label
use-input
use-chips
option-value=
"Id"
option-label=
"EmployeeName"
v-model=
"tempManager2"
ref=
"ManagerId"
:options=
"PersionList"
label=
"默认抄送"
:dense=
"false"
emit-value
map-options
@
filter=
"filterFn"
>
<
template
v-slot:no-option
>
<q-item>
<q-item-section
class=
"text-grey"
>
未找到相关数据
</q-item-section>
</q-item>
</
template
>
</q-select>
<q-input
clearable
filled
class=
"col-12 q-pb-lg q-pr-lg"
standout=
"bg-primary text-white"
v-model=
"addMsg.Title"
ref=
"Title"
label=
"标题"
:rules=
"[val => !!val || '标题']"
/>
<div
class=
"text-caption q-my-md q-px-xs text-grey-6"
>
公告内容
</div>
<ext-editor
:defaultMsg=
"addMsg.Content"
classStr=
"col-12"
@
getEditValue=
"getEditValue"
></ext-editor>
<el-upload
style=
"margin-top: 20px"
:http-request=
"uploadFile2"
:file-list=
"fileList"
:before-remove=
"beforeRemove"
:multiple=
"true"
:show-file-list=
"true"
action=
""
>
<el-button
size=
"mini"
type=
"primary"
>
附件上传
</el-button>
</el-upload>
</div>
</q-card-section>
<q-separator
/>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-btn
label=
"取消"
flat
color=
"grey-10"
size=
"sm"
style=
"font-weight:400 !important"
@
click=
"closeSaveForm"
/>
<q-btn
label=
"草稿"
color=
"accent q-px-md"
size=
"sm"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"save_t(2)"
/>
<q-btn
label=
"立即提交"
color=
"accent q-px-md"
size=
"sm"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"save_t(1)"
/>
</q-card-actions>
</q-card>
</q-dialog>
<q-dialog
v-model=
"persistent2"
maximized
full-height
seamless
position=
"right"
>
<q-card
style=
"margin-top:21px;width:800px"
class=
"no-border-radius classinfo_Dialog"
>
<q-img
:src=
"NInfo.BgImage"
v-if=
"NInfo.BgImage"
spinner-color=
"white"
style=
" width: 100%;height: 76px"
/>
<q-img
:src=
"NInfo.BgImage"
v-if=
"NInfo.BgImage"
spinner-color=
"white"
style=
" width: 100%;height: 76px"
/>
<div
style=
"padding: 20px"
>
<div
class=
"col-12 g row"
style=
"margin-bottom:10px;"
>
<div
class=
"col-6"
>
...
...
@@ -205,12 +149,12 @@
<div
style=
"margin-top:3px;"
>
附件:
</div>
<
template
>
<div
style=
"max-width: 350px;margin-left:10px;"
>
<div
class=
"noticeFile"
v-if=
"NInfo.fileList.length>0"
v-for=
"(file,fIndex) in NInfo.fileList"
:key=
"fIndex"
>
<div
class=
"noticeFile"
v-if=
"NInfo.fileList.length>0"
v-for=
"(file,fIndex) in NInfo.fileList"
:key=
"fIndex"
>
<span
style=
"cursor:pointer;"
>
<a
:href=
"file.FileUrl"
style=
"color:#2961FE;text-decoration:none;"
target=
"_blank"
>
<i
class=
"iconfont icon-Download"
style=
"margin-right:5px;"
></i>
{{
file
.
FileName
}}
</a>
</span>
<i
class=
"iconfont icon-Download"
style=
"margin-right:5px;"
></i>
{{
file
.
FileName
}}
</a>
</span>
</div>
</div>
</
template
>
...
...
@@ -222,6 +166,21 @@
<q-icon
name=
"iconfont icon-jujue1"
size=
"26px"
/>
</div>
</q-dialog>
<q-dialog
v-model=
"persistent3"
>
<q-card
style=
"margin-top:21px;width:800px"
class=
"q-pa-sm"
>
<q-card-section
class=
"flex"
>
<div
class=
"text-h6"
>
审批
</div>
<q-space
/>
<q-btn
icon=
"close"
flat
round
dense
v-close-popup
/>
</q-card-section>
<q-input
standout=
"bg-primary text-white"
type=
"textarea"
v-model=
"approvalMsg.LogContent"
label=
"备注"
/>
<q-card-actions
align=
"right"
>
<q-btn
flat
label=
"取消"
size=
"sm"
color=
"primary"
v-close-popup
/>
<q-btn
label=
"拒绝"
size=
"sm"
color=
"primary"
@
click=
"saveApproval(2)"
/>
<q-btn
label=
"同意"
size=
"sm"
color=
"primary"
@
click=
"saveApproval(1)"
/>
</q-card-actions>
</q-card>
</q-dialog>
</div>
</template>
...
...
@@ -229,12 +188,13 @@
import
{
getNoticePageList
,
getNoticeStateEnumList
,
getNoticeBaseInfo
,
//获取 公告配置
getNoticeRuleEnumList
,
//获取编号规则 枚举列表
setNoticeBaseInfo
,
//新增修改 公告配置
setNoticeOperation
,
//公告操作
setNoticeInfo
,
//发布公告
GetNoticeInfo
,
//公告详情
setReviewNotice
,
//公告审批
getMyApproval
,
//我审批的公告
}
from
'../../api/administration/document'
;
import
{
getDeptTree
...
...
@@ -250,7 +210,7 @@
export
default
{
meta
:
{
title
:
"行政公告"
title
:
"行政公告
审批
"
},
components
:
{
extEditor
,
...
...
@@ -266,12 +226,22 @@
rowsPerPage
:
12
,
Title
:
''
,
Number
:
''
,
NoticeState
:
0
,
NoticeState
:
4
,
Is_Top
:
0
,
UpdateBy
:
""
},
mymsg
:
{
PageIndex
:
1
,
PageSize
:
12
,
rowsPerPage
:
12
,
Title
:
''
,
Number
:
''
,
NoticeState
:
1
,
Is_Top
:
0
,
UpdateBy
:
""
},
loading
:
true
,
//公告column
//公告
审批
column
columns
:
[{
name
:
'NoticeStateName'
,
label
:
'状态'
,
...
...
@@ -316,6 +286,60 @@
label
:
'操作'
,
field
:
'DeptId'
}
],
//我审批的column
mycolumns
:
[{
name
:
'NoticeStateName'
,
label
:
'状态'
,
field
:
"ReviewStatusStr"
,
align
:
'left'
},
{
name
:
'Number'
,
field
:
'Number'
,
label
:
'编号'
,
align
:
'left'
,
},
{
name
:
'Title'
,
label
:
'标题'
,
field
:
'Title'
,
align
:
'left'
},
{
name
:
'ReadNum'
,
label
:
'阅读情况'
,
field
:
'ReadNum'
,
align
:
'left'
},
{
name
:
'IsTop'
,
label
:
'是否置顶'
,
align
:
'left'
},
{
name
:
'UpdateByName'
,
label
:
'发布人'
,
field
:
'UpdateByName'
,
align
:
'left'
},
{
name
:
'UpdateTime'
,
label
:
'发布时间'
,
align
:
'left'
,
field
:
'UpdateTime'
},
{
name
:
'LogContent'
,
label
:
'备注'
,
align
:
'left'
,
field
:
'LogContent'
},
{
name
:
'optioned'
,
label
:
'操作'
,
field
:
'DeptId'
}
],
data
:
[],
pageCount
:
0
,
...
...
@@ -352,14 +376,21 @@
returnString
:
[],
//默认岗位
drawer
:
false
,
//显示右侧抽屉
NInfo
:
{},
//详情内容
persistent2
:
false
persistent2
:
false
,
persistent3
:
false
,
approvalMsg
:{
NoticeId
:
0
,
ReviewStatus
:
0
,
LogContent
:
""
},
mydata
:[],
mypageCount
:
0
}
},
mounted
()
{
this
.
getList
();
this
.
getNoticeList
()
this
.
getEmployee
()
this
.
getNoticeBase
()
this
.
getDepartList
();
this
.
getNoticeRule
()
//获取编号规则 枚举列表
},
...
...
@@ -372,7 +403,7 @@
if
(
this
.
tabCheck
==
'first'
)
{
this
.
getList
();
}
else
if
(
this
.
tabCheck
==
'second'
)
{
this
.
get
NoticeBase
()
this
.
get
MyList
()
}
},
onRejected
(
rejectedEntries
)
{
...
...
@@ -408,7 +439,6 @@
})
},
getList
()
{
this
.
loading
=
false
;
getNoticePageList
(
this
.
msg
).
then
(
res
=>
{
this
.
data
=
res
.
Data
.
PageData
;
...
...
@@ -492,15 +522,7 @@
this
.
addMsg
.
To
=
''
;
}
},
////获取 公告配置
getNoticeBase
()
{
getNoticeBaseInfo
({}).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
NoticeBaseInfo
=
res
.
Data
this
.
tempManager
=
res
.
Data
.
CopyPeople
.
split
(
','
).
map
(
Number
);
//字符串转为数组map 是转为数字
}
})
},
getNoticeRule
()
{
getNoticeRuleEnumList
({
Name
:
''
,
...
...
@@ -678,15 +700,51 @@
},
wopen
(
file
)
{
window
.
open
(
file
.
FileUrl
);
}
},
//显示审批弹窗
showApproval
(
id
)
{
this
.
persistent3
=
true
this
.
approvalMsg
.
NoticeId
=
id
},
//提交审批结果
saveApproval
(
val
){
if
(
val
===
2
&&
this
.
approvalMsg
.
LogContent
==
""
){
this
.
$message
.
error
(
"请填写拒绝原因"
)
return
}
this
.
approvalMsg
.
ReviewStatus
=
val
setReviewNotice
(
this
.
approvalMsg
).
then
(
res
=>
{
console
.
log
(
611
,
res
)
if
(
res
.
Code
===
1
){
this
.
$message
.
success
(
"操作成功"
);
this
.
persistent3
=
false
this
.
getList
()
}
else
{
this
.
$message
.
error
(
res
.
Message
)
}
})
},
getMyList
()
{
this
.
loading
=
false
;
getMyApproval
(
this
.
mymsg
).
then
(
res
=>
{
this
.
mydata
=
res
.
Data
.
PageData
;
this
.
loading
=
false
;
this
.
mypageCount
=
res
.
Data
.
PageCount
;
}).
catch
(()
=>
{
this
.
loading
=
false
})
},
//分页改变
myChangePage
(
val
)
{
this
.
mymsg
.
PageIndex
=
val
;
this
.
getMyList
()
},
}
}
</
script
>
<
style
scoped
>
.second-item
{}
.document
.NoticeStateNimg
{
width
:
30px
;
height
:
30px
;
...
...
@@ -696,6 +754,7 @@
.document
.q-pr-lg
{
padding-right
:
0
;
}
.document
.noticeFile
{
color
:
#2961FE
;
font-size
:
13px
;
...
...
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