Commit 70703ce6 by 罗承锋

后端活动、活动积分提交

parent 85dfb431
......@@ -51,11 +51,9 @@
<!--列表-->
<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>
<template slot="createTime" slot-scope="text">
{{ text | dayjs}}
</template>
</s-table>
<!--编辑----弹框-->
......@@ -131,22 +129,15 @@
},
modifyvisible: false,
columns: [
{dataIndex: 'name', width: 200, title: '姓名', align: "center"},
{dataIndex: 'account', width: 200, title: '账号', align: "center"},
{dataIndex: 'recordIntegral', width: 200, title: '所得积分', align: "center"},
{dataIndex: 'activityType', width: 200, title: '积分类型', align: "center"},
{dataIndex: 'subclass', width: 200, title: '积分小类', align: "center"},
{dataIndex: 'substName', width: 200, title: '县分', align: "center"},
{dataIndex: 'name', width: 60, title: '姓名', align: "center"},
{dataIndex: 'account', width: 80, title: '账号', align: "center"},
{dataIndex: 'recordIntegral', width: 60, title: '所得积分', align: "center"},
{dataIndex: 'activityType', width: 80, title: '积分类型', align: "center"},
{dataIndex: 'subclass', width: 80, title: '积分大类', align: "center"},
{dataIndex: 'substName', width: 40, title: '县分', align: "center"},
{dataIndex: 'schoolName', width: 200, title: '学校', align: "center"},
{dataIndex: 'createTime', width: 200, title: '创建时间', align: "center"},
{
dataIndex: 'operation',
width: 200,
title: '操作',
align: "center",
scopedSlots: {customRender: 'operation'},
fixed: "right"
}]
{dataIndex: 'createTime', width: 100, title: '创建时间', align: "center", scopedSlots: {customRender: 'createTime'},},
]
,
rowdata: parameter => {
let params = {
......
......@@ -45,6 +45,9 @@
<!--列表-->
<s-table :locale="emptyText" :columns="columns" :data="rowdata" bordered ref="table" size="small" class="flex-filling">
<template slot="createTime" slot-scope="text">
{{ text | dayjs}}
</template>
<template slot="imageUrl" slot-scope="text">
<img style="width: 20%" :src="apis + text" @click="imgClick(text)">
</template>
......@@ -143,7 +146,7 @@
subNames: [],
fileList: [
],
apis:'',
apis:'',
fileid:{},
brackgroundurl:"manager/ciop/school/schoolManagement/qrcodeUpload",
// form
......@@ -174,15 +177,15 @@
modifyvisible: false,
visiblepicture: false,
columns: [
{dataIndex: 'title', width: 200, title: '活动标题', align: "center"},
{dataIndex: 'title', width: 100, title: '活动标题', align: "center"},
{dataIndex: 'desc', width: 200, title: '活动详情', align: "center"},
{dataIndex: 'integral', width: 200, title: '活动积分', align: "center"},
{dataIndex: 'integral', width: 80, title: '活动积分', align: "center"},
{dataIndex: 'imageUrl', title: '图片 ', scopedSlots: {customRender: 'imageUrl'},align: 'center'},
{dataIndex: 'activityType', width: 200, title: '活动类型', align: "center"},
{dataIndex: 'subclass', width: 200, title: '活动小类', align: "center"},
{dataIndex: 'sort', width: 200, title: '排序号', align: "center"},
{dataIndex: 'creator', width: 200, title: '创建人', align: "center"},
{dataIndex: 'createTime', width: 200, title: '创建时间', align: "center"},
{dataIndex: 'activityType', width: 80, title: '活动类型', align: "center"},
{dataIndex: 'subclass', width: 80, title: '活动大类', align: "center"},
{dataIndex: 'sort', width: 80, title: '排序号', align: "center"},
{dataIndex: 'creator', width: 80, title: '创建人', align: "center"},
{dataIndex: 'createTime', width: 200, title: '创建时间', align: "center", scopedSlots: {customRender: 'createTime'}},
{
dataIndex: 'operation',
width: 200,
......
......@@ -61,9 +61,20 @@
<!--列表-->
<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 slot="createTime" slot-scope="text">
{{ text | dayjs}}
</template>
<template slot="imageUrl" slot-scope="text">
<img style="width: 20%" :src="apis + text" @click="imgClick(text)">
</template>
<template slot="status" slot-scope="text">
<span v-if="text == 1">未审核</span>
<span v-if="text == 2">审核通过</span>
<span v-if="text == 3">审核不通过</span>
</template>
<template slot="operation" slot-scope="text,record">
<a v-if="record.status == 1" @click="modifyfunction(record)">审核</a>
</template>
</s-table>
......@@ -88,6 +99,19 @@
</a-form>
</a-modal>
<a-drawer
title="活动图片"
placement="right"
:closable="false"
@close="pictureOnClose"
:visible="visiblepicture"
width="30%"
>
<div >
<img class="bg-img" :src="imgInfo">
</div>
</a-drawer>
</div>
</template>
......@@ -105,9 +129,10 @@
emptyText: {emptyText: '暂无数据'},
previewVisible: false,
previewImage: '',
visiblepicture: false,
fileList: [
],
apis: '',
fileid:{},
// form
Formtable: this.$form.createForm(this, {name: 'Formtable'}),
......@@ -132,28 +157,33 @@
},
modifyvisible: false,
columns: [
{dataIndex: 'title', width: 200, title: '活动标题', align: "center"},
{dataIndex: 'title', width: 80, 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: 'activityType', width: 80, title: '活动类型', align: "center"},
{dataIndex: 'subclass', width: 80, title: '活动大类', align: "center"},
{dataIndex: 'integral', width: 80, title: '活动积分', align: "center"},
{dataIndex: 'status', width: 80, title: '审核状态', align: "center",
scopedSlots: {customRender: 'status'}},
{dataIndex: 'remark', width: 100, title: '审核备注', align: "center"},
{dataIndex: 'recordIntegral', width: 80, title: '所得积分', align: "center"},
{dataIndex: 'creator', width: 100, 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: 'imageUrl', width: 100, title: '参与图片', align: "center",scopedSlots: {customRender: 'imageUrl'}},
{dataIndex: 'createTime', width: 100, title: '参与时间', align: "center",
scopedSlots: {customRender: 'createTime'}},
{dataIndex: 'isRepeal', width: 100, title: '是否重复参与', align: "center"},
{
dataIndex: 'operation',
width: 200,
width: 100,
title: '操作',
align: "center",
scopedSlots: {customRender: 'operation'},
fixed: "right"
}]
,
}],
rowdata: parameter => {
const env = process.env.NODE_ENV; //获取当前环境
let params = {
pageNo: parameter.pageNo,
pageSize: parameter.pageSize
......@@ -175,6 +205,7 @@
if (res.data.records.length==0){
return data
}
data = {
data: res.data.records,
pageSize: parameter.pageSize,
......@@ -197,16 +228,20 @@
modifyfunction(data){
//初始化
this.titleName="审核"
alert(data.id);
this.modifyForm.id = data.id
this.modifyvisible=true;
setTimeout(()=>{
this.Formtable.setFieldsValue({
integral: data.integral
})
},0)
},
//提交表单
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.remark=values.remark == undefined ? '' : values.remark;
this.modifyForm.integral=values.integral
//修改数据
......@@ -230,7 +265,15 @@
})
this.modifyForm.id=""
this.modifyvisible=false;
}
},
imgClick(res){
this.imgInfo=this.apis + res
this.visiblepicture=true
},
pictureOnClose() {
this.imgInfo=''
this.visiblepicture = false;
},
}
}
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment