Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gdtel-gztel-school-center-ui
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴学德
gdtel-gztel-school-center-ui
Commits
30dee481
Commit
30dee481
authored
Jun 03, 2020
by
彭祥礼
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
找回丢失页面
parent
21833d7e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
253 additions
and
7 deletions
+253
-7
src/views/school-center/activity/activityRecord.vue
+240
-0
src/views/school-center/userManager/schoolAllocation.vue
+13
-7
No files found.
src/views/school-center/activity/activityRecord.vue
0 → 100644
View file @
30dee481
<
template
>
<div
class=
"flex-container"
>
<!-- 查询区域 -->
<div
class=
"table-page-search-wrapper"
>
<!-- 搜索区域 -->
<a-form
layout=
"inline"
>
<a-row
:gutter=
"24"
>
<a-col
:md=
"4"
:sm=
"12"
>
<a-form-item
label=
"活动标题:"
>
<a-input
placeholder=
"活动标题"
v-model=
"queryParam.title"
></a-input>
</a-form-item>
</a-col>
<a-col
:md=
"6"
:sm=
"12"
>
<a-form-item
:labelCol=
"
{span: 5}" :wrapperCol="{span: 18, offset: 1}" label="活动类型">
<a-select
placeholder=
"请选择"
v-model=
"queryParam.activityType"
>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
key=
"个人活动"
>
个人活动
</a-select-option>
<a-select-option
key=
"团队活动"
>
团队活动
</a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col
:md=
"6"
:sm=
"12"
>
<a-form-item
:labelCol=
"
{span: 5}" :wrapperCol="{span: 18, offset: 1}" label="活动小类">
<a-select
placeholder=
"请选择"
v-model=
"queryParam.subclass"
>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
key=
"部长考核"
>
部长考核
</a-select-option>
<a-select-option
key=
"前置营销"
>
前置营销
</a-select-option>
<a-select-option
key=
"线上活动"
>
线上活动
</a-select-option>
<a-select-option
key=
"线下活动"
>
线下活动
</a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col
:md=
"4"
:sm=
"12"
>
<a-form-item
label=
"参与者:"
>
<a-input
placeholder=
"活动标题"
v-model=
"queryParam.creator"
></a-input>
</a-form-item>
</a-col>
<a-col
:md=
"6"
:sm=
"12"
>
<a-form-item
:labelCol=
"
{span: 5}" :wrapperCol="{span: 18, offset: 1}" label="审核状态">
<a-select
placeholder=
"请选择"
v-model=
"queryParam.status"
>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
key=
"1"
>
未审核
</a-select-option>
<a-select-option
key=
"2"
>
审核通过
</a-select-option>
<a-select-option
key=
"3"
>
审核不通过
</a-select-option>
</a-select>
</a-form-item>
</a-col>
<span
class=
"table-page-search-submitButtons"
style=
"float: left; overflow: hidden;"
>
<a-col
:md=
"6"
:sm=
"24"
>
<a-button
@
click=
"search()"
type=
"primary"
>
查询
</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<!--列表-->
<s-table
:locale=
"emptyText"
:columns=
"columns"
:data=
"rowdata"
bordered
ref=
"table"
size=
"small"
class=
"flex-filling"
>
<template
slot=
"operation"
slot-scope=
"text,record"
>
<a
@
click=
"modifyfunction(record)"
>
审核
</a>
</
template
>
</s-table>
<!--编辑----弹框-->
<a-modal
:title=
"titleName"
:visible=
"modifyvisible"
@
ok=
"createfunctionOk"
@
cancel=
"createfunctionCancel"
html-type=
"submit"
width=
"840px"
>
<a-form
:form=
"Formtable"
>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"审核状态"
>
<a-radio-group
v-decorator=
"['status', {rules: [{ required: true, message: '审核状态不能为空!'}]} ]"
>
<a-radio
value=
"2"
>
通过
</a-radio>
<a-radio
value=
"3"
>
不通过
</a-radio>
</a-radio-group>
</a-form-item>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"所得积分"
>
<a-input
placeholder=
"所得积分"
v-decorator=
"[ 'integral', {rules: [{ required: true,type:'number', message: '所得积分不能为空!' ,whitespace:true,transform:(value)=> {return Number(value)} }]} ]"
></a-input>
</a-form-item>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"审核备注"
>
<a-input
placeholder=
"审核备注"
v-decorator=
"[ 'remark', {rules: [{ required: false }]} ]"
></a-input>
</a-form-item>
</a-form>
</a-modal>
</div>
</template>
<
script
>
import
STable
from
'@/components/table'
;
import
{
getList
,
audit
}
from
"../../../api/school-center/activityRecordAPI"
import
{
cloneObject
}
from
'@/utils/util'
;
export
default
{
name
:
"activityRecord"
,
components
:
{
STable
,
},
data
:
function
()
{
return
{
emptyText
:
{
emptyText
:
'暂无数据'
},
previewVisible
:
false
,
previewImage
:
''
,
fileList
:
[
],
fileid
:{},
// form
Formtable
:
this
.
$form
.
createForm
(
this
,
{
name
:
'Formtable'
}),
titleName
:
""
,
modifyForm
:
{
id
:
''
,
status
:
''
,
integral
:
''
,
remark
:
''
},
subNameList
:
[],
packageName
:[],
chosePages
:[],
products
:[],
//输入框列表
queryParam
:
{
title
:
''
,
activityType
:
''
,
subclass
:
''
,
status
:
''
,
creator
:
''
,
},
modifyvisible
:
false
,
columns
:
[
{
dataIndex
:
'title'
,
width
:
200
,
title
:
'活动标题'
,
align
:
"center"
},
{
dataIndex
:
'desc'
,
width
:
200
,
title
:
'活动详情'
,
align
:
"center"
},
{
dataIndex
:
'activityType'
,
width
:
200
,
title
:
'活动类型'
,
align
:
"center"
},
{
dataIndex
:
'subclass'
,
width
:
200
,
title
:
'活动小类'
,
align
:
"center"
},
{
dataIndex
:
'integral'
,
width
:
200
,
title
:
'活动积分'
,
align
:
"center"
},
{
dataIndex
:
'status'
,
width
:
200
,
title
:
'审核状态'
,
align
:
"center"
},
{
dataIndex
:
'remark'
,
width
:
200
,
title
:
'审核备注'
,
align
:
"center"
},
{
dataIndex
:
'recordIntegral'
,
width
:
200
,
title
:
'所得积分'
,
align
:
"center"
},
{
dataIndex
:
'creator'
,
width
:
200
,
title
:
'参与者'
,
align
:
"center"
},
{
dataIndex
:
'message'
,
width
:
200
,
title
:
'活动留言'
,
align
:
"center"
},
{
dataIndex
:
'createTime'
,
width
:
200
,
title
:
'参与时间'
,
align
:
"center"
},
{
dataIndex
:
'isRepeal'
,
width
:
200
,
title
:
'是否重复参与'
,
align
:
"center"
},
{
dataIndex
:
'operation'
,
width
:
200
,
title
:
'操作'
,
align
:
"center"
,
scopedSlots
:
{
customRender
:
'operation'
},
fixed
:
"right"
}]
,
rowdata
:
parameter
=>
{
let
params
=
{
pageNo
:
parameter
.
pageNo
,
pageSize
:
parameter
.
pageSize
}
//表示
let
obj
=
cloneObject
(
this
.
queryParam
)
return
getList
(
Object
.
assign
(
params
,
obj
)).
then
(
res
=>
{
let
data
=
{}
if
(
res
.
state
!==
'success'
)
{
this
.
emptyText
.
emptyText
=
'查询失败!'
this
.
$message
.
error
(
"查询失败!"
,
5
);
data
=
{
data
:
[],
pageSize
:
parameter
.
pageSize
,
pageNo
:
1
,
totalCount
:
0
}
}
else
{
if
(
res
.
data
.
records
.
length
==
0
){
return
data
}
data
=
{
data
:
res
.
data
.
records
,
pageSize
:
parameter
.
pageSize
,
pageNo
:
parameter
.
pageNo
,
totalCount
:
res
.
data
.
total
}
}
return
data
})
}
}
},
methods
:{
chosePagesfunction
(
data
){
this
.
chosePages
=
data
},
search
()
{
this
.
$refs
.
table
.
refresh
({
search
:
true
})
},
modifyfunction
(
data
){
//初始化
this
.
titleName
=
"审核"
alert
(
data
.
id
);
this
.
modifyForm
.
id
=
data
.
id
this
.
modifyvisible
=
true
;
},
//提交表单
createfunctionOk
(){
this
.
Formtable
.
validateFields
([
'status'
,
"integral"
,
"remark"
],
{
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
){
this
.
modifyForm
.
status
=
values
.
status
this
.
modifyForm
.
remark
=
values
.
remark
this
.
modifyForm
.
integral
=
values
.
integral
//修改数据
audit
(
this
.
modifyForm
).
then
(
res
=>
{
if
(
res
.
state
==
"success"
)
{
this
.
$message
.
success
(
res
.
data
?
res
.
data
:
'审核成功!'
,
5
);
this
.
search
();
this
.
modifyvisible
=
false
return
null
;
}
this
.
$message
.
error
(
res
.
data
?
res
.
data
:
'审核失败!'
,
5
);
})
}
})
},
createfunctionCancel
(){
this
.
Formtable
.
setFieldsValue
({
status
:
''
,
remark
:
''
,
integral
:
''
})
this
.
modifyForm
.
id
=
""
this
.
modifyvisible
=
false
;
}
}
}
</
script
>
<
style
scoped
>
</
style
>
src/views/school-center/userManager/schoolAllocation.vue
View file @
30dee481
...
@@ -57,9 +57,8 @@
...
@@ -57,9 +57,8 @@
<a-modal
:title=
"titleName"
:visible=
"modifyvisible"
@
ok=
"createfunctionOk"
@
cancel=
"createfunctionCancel"
html-type=
"submit"
width=
"720px"
height=
"1600px"
>
<a-modal
:title=
"titleName"
:visible=
"modifyvisible"
@
ok=
"createfunctionOk"
@
cancel=
"createfunctionCancel"
html-type=
"submit"
width=
"720px"
height=
"1600px"
>
<a-form
:form=
"Formtable"
>
<a-form
:form=
"Formtable"
>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"账号"
>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"账号"
>
<a-select
v-model=
"modifyForm.account"
placeholder=
"请选择账号"
@
change=
"handleChange"
>
<!-- mode="tags"-->
<a-select
mode=
"tags"
v-model=
"modifyForm.userName"
placeholder=
"请选择账号"
@
change=
"handleChange"
>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
v-for=
"d in userList"
:value=
"d.name"
>
{{ d.name}}
</a-select-option>
<a-select-option
v-for=
"d in userList"
:value=
"d.account"
>
{{ d.name}}
</a-select-option>
</a-select>
</a-select>
</a-form-item>
</a-form-item>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"县分"
>
<a-form-item
:labelCol=
"{span: 6}"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"县分"
>
...
@@ -115,6 +114,7 @@
...
@@ -115,6 +114,7 @@
schoolNames2
:
[],
schoolNames2
:
[],
modifyForm
:
{
modifyForm
:
{
id
:
''
,
id
:
''
,
userName
:
''
,
subName
:
''
,
subName
:
''
,
account
:
''
,
account
:
''
,
schoolId
:
''
,
schoolId
:
''
,
...
@@ -186,12 +186,18 @@
...
@@ -186,12 +186,18 @@
createfunctionOk
(){
createfunctionOk
(){
this
.
Formtable
.
validateFields
([
"account"
],
{
force
:
true
},
(
err
,
values
)
=>
{
this
.
Formtable
.
validateFields
([
"account"
],
{
force
:
true
},
(
err
,
values
)
=>
{
if
(
!
err
){
if
(
!
err
){
var
userNames
=
this
.
modifyForm
.
userName
.
split
(
","
);
for
(
const
userName
of
userNames
)
{
for
(
const
obj
of
this
.
userList
)
{
if
(
userName
===
obj
.
name
){
this
.
modifyForm
.
account
=
obj
.
account
+
","
;
}
}
}
addAllocation
({
"account"
:
this
.
modifyForm
.
account
,
"schoolId"
:
this
.
modifyForm
.
schoolId
}).
then
(
res
=>
{
addAllocation
({
"account"
:
this
.
modifyForm
.
account
,
"schoolId"
:
this
.
modifyForm
.
schoolId
}).
then
(
res
=>
{
if
(
res
.
state
==
"success"
)
{
if
(
res
.
state
==
"success"
)
{
this
.
$message
.
success
(
res
.
data
?
res
.
data
:
'添加成功!'
,
5
);
this
.
$message
.
success
(
res
.
data
?
res
.
data
:
'添加成功!'
,
5
);
this
.
modifyForm
.
account
=
""
this
.
modifyForm
.
account
=
""
this
.
modifyForm
.
subName
=
''
this
.
modifyForm
.
schoolId
=
''
this
.
modifyvisible
=
false
;
this
.
modifyvisible
=
false
;
this
.
search
();
this
.
search
();
}
}
...
@@ -207,7 +213,6 @@
...
@@ -207,7 +213,6 @@
account
:
''
account
:
''
})
})
this
.
addForm
.
subName
=
''
;
},
},
deleteAllocation
(
id
){
deleteAllocation
(
id
){
let
params
=
{};
let
params
=
{};
...
@@ -296,7 +301,8 @@
...
@@ -296,7 +301,8 @@
return
;
return
;
this
.
userList
.
push
({
this
.
userList
.
push
({
account
:
r
.
account
,
account
:
r
.
account
,
name
:
r
.
name
text
:
r
.
name
,
value
:
r
.
name
,
})
})
})
})
}
}
...
...
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