刘翔宇-旅管家 3 years ago
parent 5b9c7992a2
commit 5d69e40ca1

@ -1,12 +1,12 @@
<template>
<div>
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="活动参与管理">
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="项目参与管理">
<div slot="content"></div>
<slot>
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -68,7 +68,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -156,4 +156,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -1,12 +1,12 @@
<template>
<div>
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="活动用户管理">
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="项目用户管理">
<div slot="content"></div>
<slot>
<div class="selects">
<div style="display: flex;align-items: center;">
<div style="display: flex;align-items: center;" v-show="!sysInfo">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -30,7 +30,9 @@
<xy-table :list="list" :total="total" :table-item="table" @delete="deleteitem"
@editor="(row)=>{$refs['addActivityUser'].id = row.id;$refs['addActivityUser'].isShow = true;$refs['addActivityUser'].type = 'editor'}">
@editor="(row)=>{$refs['addActivityUser'].id = row.id;$refs['addActivityUser'].isShow = true;$refs['addActivityUser'].type = 'editor'}"
@pageSizeChange="e => {select.page_size = e;doSearch()}" @pageIndexChange="pageChange"
:pageSize="select.page_size">
<template v-slot:btns v-if="type==0 ">
</template>
@ -56,7 +58,8 @@
addActivityUser
},
data() {
return {
return {
sysInfo:null,
select: {
page: 1,
page_size: 20,
@ -68,7 +71,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -77,7 +80,14 @@
align: 'left',
}, {
},
{
prop: 'company_name',
label: '所属部门/分公司',
align: 'center'
},
{
prop: 'username',
label: '登录账号',
align: 'center'
@ -136,13 +146,18 @@
this.load()
},
},
mounted() {
this.load();
this.loadActivity()
},
created() {
let that = this;
let type = parseInt(this.$route.path.split("_")[1]);
this.type = this.select.is_auth = type;
let sysInfo = sessionStorage.getItem('sys_info')
if (sysInfo && sysInfo != "") {
let _sys = JSON.parse(sysInfo);
that.select.activity_list_id = _sys.id;
that.sysInfo=_sys;
}
this.load();
this.loadActivity()
}
}
</script>

@ -1,16 +1,16 @@
<template>
<div>
<!-- 编辑-->
<xy-dialog :is-show.sync="isShow" title="活动编辑" type="form" :form="detail" :rules="rules" @submit="editor"
<xy-dialog :is-show.sync="isShow" title="项目编辑" type="form" :form="detail" :rules="rules" @submit="editor"
ref="addActivity">
<template v-slot:name>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>活动名称
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>项目名称
</div>
<div class="xy-table-item-content">
<el-input clearable placeholder="请填写活动名称" v-model="detail.name" style="width: 300px;" />
<el-input clearable placeholder="请填写项目名称" v-model="detail.name" style="width: 300px;" />
</div>
</div>
</template>
@ -18,10 +18,10 @@
<template v-slot:tag>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>活动标识
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>项目标识
</div>
<div class="xy-table-item-content">
<el-input clearable placeholder="请填写活动标识" v-model="detail.tag" style="width: 300px;" />
<el-input clearable placeholder="请填写项目标识" v-model="detail.tag" style="width: 300px;" />
</div>
</div>
</template>
@ -30,7 +30,7 @@
<template v-slot:type>
<div class="xy-table-item">
<div class="xy-table-item-label">活动的类型
<div class="xy-table-item-label">项目的类型
</div>
<div class="xy-table-item-content">
<el-radio-group v-model="detail.type">
@ -45,7 +45,7 @@
<template v-slot:datetimerange>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>活动时间范围
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>项目时间范围
</div>
<div class="xy-table-item-content">
<el-date-picker v-model="detail.datetimerange" type="datetimerange" :picker-options="pickerOptions"
@ -149,10 +149,10 @@
<template v-slot:domain>
<div class="xy-table-item">
<div class="xy-table-item-label">活动的域名
<div class="xy-table-item-label">项目的域名
</div>
<div class="xy-table-item-content">
<el-input clearable placeholder="请填写活动的域名" v-model="detail.domain" style="width: 300px;" />
<el-input clearable placeholder="请填写项目的域名" v-model="detail.domain" style="width: 300px;" />
</div>
</div>
</template>
@ -269,11 +269,11 @@
rules: {
name: [{
required: true,
message: "活动名称必填"
message: "项目名称必填"
}],
domain: [{
required: true,
message: "活动的域名必填"
message: "项目的域名必填"
}],
sys_name: [{
required: true,
@ -281,11 +281,11 @@
}],
tag: [{
required: true,
message: "活动的标识必填"
message: "项目的标识必填"
}],
datetimerange: [{
required: true,
message: "活动时间必须填写",
message: "项目时间必须填写",
trigger: 'change'
}],
}
@ -361,8 +361,8 @@
let res = await show({
id: this.id
})
Object.assign(this.detail, res);
this.detail.logo=res.logo?res.logo.url:"";
Object.assign(this.detail, res);
this.detail.logo=res.logo?res.logo.url:"";
this.detail.small_logo=res.small_logo?res.small_logo.url:"";
this.detail.datetimerange.push(this.$moment(res.start_time).format("YYYY-MM-DD HH:mm:ss"));
this.detail.datetimerange.push(this.$moment(res.end_time).format("YYYY-MM-DD HH:mm:ss"));
@ -444,4 +444,4 @@
z-index: 2;
}
}
</style>
</style>

@ -1,7 +1,7 @@
<template>
<div>
<!-- 编辑-->
<xy-dialog :is-show.sync="isShow" title="活动配置" type="normal" ref="addActivityConfig" @on-ok="editor">
<xy-dialog :is-show.sync="isShow" title="项目配置" type="normal" ref="addActivityConfig" @on-ok="editor">
<div class="table-tree">
<div style="display: flex;justify-content: flex-end;margin-right: 20px;margin-bottom: 10px;">
<Button type="primary" @click="addRow()" size="small" style="margin-left: 10px;" ghost>新增参数</Button>
@ -195,4 +195,4 @@
z-index: 2;
}
}
</style>
</style>

@ -1,7 +1,7 @@
<template>
<div>
<!-- 编辑-->
<xy-dialog :is-show.sync="isShow" title="活动用户编辑" type="form" :form="detail" :rules="rules" @submit="editor"
<xy-dialog :is-show.sync="isShow" title="项目用户编辑" type="form" :form="detail" :rules="rules" @submit="editor"
ref="addActivity">
<template v-slot:name>
@ -48,10 +48,10 @@
</div>
</template>
<template v-slot:activity_list_id>
<template v-show="!sysInfo" v-slot:activity_list_id>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>相关活动
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>相关项目
</div>
<div class="xy-table-item-content">
<el-select clearable v-model="detail.activity_list_id">
@ -93,7 +93,8 @@
},
data() {
return {
return {
sysInfo:null,
isShow: false,
id: "",
type: "add",
@ -153,7 +154,13 @@
},
mounted() {
let that = this;
let that = this;
let sysInfo = sessionStorage.getItem('sys_info')
if (sysInfo && sysInfo != "") {
let _sys = JSON.parse(sysInfo);
this.detail.activity_list_id = _sys.id;
that.sysInfo=_sys;
}
}
}
</script>
@ -215,4 +222,4 @@
z-index: 2;
}
}
</style>
</style>

@ -71,7 +71,7 @@
<template v-slot:activity_list_id>
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>相关活动
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>相关项目
</div>
<div class="xy-table-item-content">
<el-select clearable v-model="detail.activity_list_id">
@ -136,7 +136,7 @@
}],
activity_list_id: [{
required: true,
message: "活动必须选择"
message: "项目必须选择"
}],
}
@ -259,4 +259,4 @@
z-index: 2;
}
}
</style>
</style>

@ -1,12 +1,12 @@
<template>
<div>
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="活动奖品管理">
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="项目奖品管理">
<div slot="content"></div>
<slot>
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -68,7 +68,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -81,7 +81,7 @@
prop: 'total',
label: '总数',
align: 'right'
},
},
{
prop: 'rate',
label: '概率',
@ -161,4 +161,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -1,12 +1,12 @@
<template>
<div>
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="活动抽奖日志">
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="项目抽奖日志">
<div slot="content"></div>
<slot>
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -59,7 +59,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -146,4 +146,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -1,6 +1,6 @@
<template>
<div>
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="活动列表管理">
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="项目列表管理">
<div slot="content"></div>
<slot>
<div class="selects">
@ -36,8 +36,8 @@
</xy-table>
<addActivity ref="addActivity" @refresh="load()"></addActivity>
<addActivityConfig ref="addActivityConfig" @refresh="load()"></addActivityConfig>
<addActivityConfig ref="addActivityConfig" @refresh="load()"></addActivityConfig>
</div>
</template>
@ -51,11 +51,11 @@
} from "@/api/activity/index";
import addActivity from '@/views/activity/components/addActivity'
import addActivityConfig from '@/views/activity/components/addActivityConfig'
import addActivityConfig from '@/views/activity/components/addActivityConfig'
export default {
components: {
addActivity,
addActivity,
addActivityConfig
},
data() {
@ -69,41 +69,52 @@
list: [],
table: [{
prop: 'name',
label: '活动名称',
label: '项目名称',
align: 'left',
width: 280,
fixed: 'left',
},{
prop: 'domain',
label: '访问地址',
align: 'left',
width: 280,
fixed: 'left',
}, {
prop: 'tag',
label: '活动标识',
label: '项目标识',
align: 'left',
width: 120,
fixed: 'left',
}, {
prop: 'start_time',
label: '活动开始时间',
label: '项目开始时间',
width: 180,
align: 'center'
}, {
prop: 'end_time',
label: '活动结束时间',
label: '项目结束时间',
width: 180,
align: 'center'
},
{
prop: 'appid',
label: '公众号的APPID',
align: 'center',
fixed: 'left'
width: 180,
}, , {
prop: 'mch_id',
label: '微信商户的ID',
align: 'center',
fixed: 'left'
width: 180,
},
{
prop: 'created_at',
label: '创建信息',
width: 160,
width: 180,
formatter: (v1, v2, value) => {
return value;
}
@ -141,11 +152,11 @@
this.$refs['addActivity'].id = row.id;
this.$refs['addActivity'].isShow = true;
this.$refs['addActivity'].type = 'editor'
},
config(row){
this.$refs['addActivityConfig'].id = row.id;
this.$refs['addActivityConfig'].isShow = true;
this.$refs['addActivityConfig'].type = 'editor'
},
config(row){
this.$refs['addActivityConfig'].id = row.id;
this.$refs['addActivityConfig'].isShow = true;
this.$refs['addActivityConfig'].type = 'editor'
},
pageChange(e) {
this.select.page = e
@ -171,4 +182,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -6,7 +6,7 @@
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -141,4 +141,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -68,7 +68,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -156,4 +156,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -6,7 +6,7 @@
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -68,7 +68,7 @@
list: [],
table: [{
prop: 'activity_list.name',
label: '活动名称',
label: '项目名称',
fixed: 'left',
align: 'left'
}, {
@ -156,4 +156,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

@ -6,7 +6,7 @@
<div class="selects">
<div style="display: flex;align-items: center;">
<span style="padding: 0 6px;word-break: keep-all;">
活动
项目
</span>
<Select v-model="select.activity_list_id" style="width: 180px;">
<Option v-for="(item,index) of listActivity" :key="item.id" :value="item.id" :label="item.name">
@ -154,4 +154,4 @@
margin-bottom: 6px;
}
}
</style>
</style>

Loading…
Cancel
Save