Commit a445e6ab by baihong

add:新增用户列表,详情,优惠券

parent bcd85003
import Main from '@/components/main'
import Main from "@/components/main";
/**
* iview-admin中meta除了原生参数外可配置的参数:
......@@ -18,75 +18,96 @@ import Main from '@/components/main'
export default [
{
path: '/login',
name: 'login',
path: "/login",
name: "login",
meta: {
title: 'Login - 登录',
title: "Login - 登录",
hideInMenu: true
},
component: () => import('@/view/login/login.vue')
component: () => import("@/view/login/login.vue")
},
{
path: '/',
name: '_home',
redirect: '/home',
path: "/",
name: "_home",
redirect: "/home",
component: Main,
meta: {
title: "签到活动管理",
hideInMenu: false,
icon: "md-home",
notCache: true,
showbr: false
},
children: [
{
path: '/home',
name: 'home',
path: "/home",
name: "home",
meta: {
hideInMenu: false,
title: '签到活动管理',
title: "用户列表",
notCache: true,
icon: 'md-home',
showbr: true
},
component: () => import('@/view/signIn/userList.vue')
component: () => import("@/view/signIn/userList.vue")
},
{
path: '/signIn/detail',
path: "/signIn/signInList",
name: "signInList",
meta: {
title: '详情',
hideInMenu: false,
title: "签到活动",
notCache: true,
showbr: true
},
component: () => import("@/view/signIn/signInList.vue")
},
{
path: "/signIn/detail",
meta: {
title: "详情",
hideInMenu: true,
showbr: true
},
component: () => import("@/view/signIn/detail.vue")
},
{
path: "/signIn/detailActivities",
meta: {
title: "详情",
hideInMenu: true,
showbr: true
},
component: () => import('@/view/signIn/detail.vue')
component: () => import("@/view/signIn/detailActivities.vue")
}
]
},
{
path: '/cms',
name: 'cms',
path: "/cms",
name: "cms",
meta: {
icon: 'ios-briefcase',
title: '内容管理'
icon: "ios-briefcase",
title: "内容管理"
},
component: Main,
children: [
{
path: '/banner',
name: 'banner',
path: "/banner",
name: "banner",
meta: {
icon: 'md-grid',
title: '自测'
icon: "md-grid",
title: "自测"
},
component: () => import('@/view/advertisingManager/banner/index.vue')
component: () => import("@/view/advertisingManager/banner/index.vue")
}
// {
// path: '/advertisement',
// name: 'advertisement',
// meta: {
// icon: 'md-grid',
// title: '树洞'
// },
// component: () => import('@/view/advertisingManager/advertisement/index.vue')
// }
// {
// path: '/advertisement',
// name: 'advertisement',
// meta: {
// icon: 'md-grid',
// title: '树洞'
// },
// component: () => import('@/view/advertisingManager/advertisement/index.vue')
// }
// {
// path: '/theme',
// name: 'theme',
......@@ -371,4 +392,4 @@ export default [
// },
// component: () => import('@/view/error-page/404.vue')
// }
]
];
<template>
<div class="detail">
<Card dis-hover>
<Card dis-hover :padding='30'>
<p slot="title">基础信息</p>
<Row>
<Col span="8">用户ID:123123123</Col>
<Col span="8">头像:<Avatar icon="ios-person"/></Col>
<Col span="8">姓名:阿斯顿马丁</Col>
</Row>
<Row style="margin-top: 20px;">
<Row style="margin-top: 40px;">
<Col span="8">手机号:17762662211</Col>
<Col span="8">真我币:1233123</Col>
<Col span="8">签到次数:365</Col>
......
<template>
<div class="detail">
<Card dis-hover :padding='30'>
<p slot="title">基础信息</p>
<Row>
<Col span="8">头像:<Avatar icon="ios-person"/></Col>
<Col span="8">姓名:阿斯顿马丁</Col>
<Col span="8">打卡时间:2020-12-23 9:00:00</Col>
</Row>
<Row style="margin-top: 40px;">
<Col span="8">获得收益(真我币):123</Col>
<Col span="8">图片: <Avatar shape="square" icon="ios-person" size="large" /></Col>
<Col span="8">见证数量:10000</Col>
</Row>
</Card>
<div class="pc-main">
<Tabs v-model="tab">
<TabPane label="评论内容" name="1"></TabPane>
<TabPane label="见证详情" name="2"></TabPane>
</Tabs>
<Table
v-if="tab==='1'"
:loading="$store.state.app.isLoading"
border
ref="selection"
:columns="columns"
:data="data"
>
<template slot-scope="{ row }" slot="name">
<span>{{ row.details.name }}</span>
</template>
<template slot-scope="{ row }" slot="title">
<span>{{ row.details.title }}</span>
</template>
<template slot-scope="{ row }" slot="created_at">
<span>{{ row.created_at | format }}</span>
</template>
<template slot-scope="{ row }" slot="enable">
<i-switch
:value="row.is_enable === 1 ? true : false"
@on-change="
value => {
change(value, row);
}
"
/>
</template>
<template slot-scope="{ row }" slot="action">
<a @click="edit(row)">编辑</a>
</template>
<template slot-scope="{ row }" slot="edit">
<a @click="goTheme(row)">编辑</a>
</template>
</Table>
<Table
v-else
:loading="$store.state.app.isLoading"
border
ref="selection"
:columns="yhqcolumns"
:data="data"
>
<template slot-scope="{ row }" slot="action">
<a @click="edit(row)">编辑</a>
</template>
</Table>
</div>
<div class="btn">
<Button type="primary" @click="$router.go(-1)">返回</Button>
</div>
</div>
</template>
<script>
import { getScenes, delScenes, editScenes } from '@/api/scenes'
export default {
name: 'categories',
components: {},
data () {
return {
tab: '1',
data: [],
yhqcolumns: [
{
title: '用户名称',
key: 'created_at'
},
{
title: '获取积分',
slot: 'name'
},
{
title: '见证时间',
slot: 'name'
}
],
columns: [
{
title: '用户名称',
key: 'created_at'
},
{
title: '评论',
slot: 'name'
},
{
title: '评论时间',
slot: 'title'
}
]
}
},
methods: {},
mounted () {}
}
</script>
<style lang="less" scoped>
.pc-main {
padding: 20px;
margin-top: 20px;
background-color: #fff;
}
.btn {
text-align: right;
width: 80%;
position: fixed;
background-color: #fff;
bottom: 10px;
padding: 10px 30px;
}
</style>
<template>
<div class="content">
<div class="topSearch">
<div class="left">
选择日期:
<DatePicker :value="value2" format="yyyy/MM/dd" type="daterange" placement="bottom-end" placeholder="Select date" style="width: 200px"></DatePicker>
<Button type="primary" @click="goDetail">查 询</Button>
<Button type="primary" ghost>重 置</Button>
</div>
<div class="right">
<Button type="primary">导 出</Button>
</div>
</div>
<Table :loading="$store.state.app.isLoading" border ref="selection" :columns="columns" :data="data">
<template slot-scope="{ row }" slot="name">
<span>{{ row.details.name }}</span>
</template>
<template slot-scope="{ row }" slot="title">
<span>{{ row.details.title }}</span>
</template>
<template slot-scope="{ row }" slot="created_at">
<span>{{ row.created_at | format}}</span>
</template>
<template slot-scope="{ row }" slot="enable">
<i-switch
:value="row.is_enable === 1 ? true : false"
@on-change="
value => {
change(value, row);
}
"
/>
</template>
<template slot-scope="{ row }" slot="action">
<a @click="edit(row)">编辑</a>
</template>
<template slot-scope="{ row }" slot="edit">
<a @click="goTheme(row)">编辑</a>
</template>
</Table>
</div>
</template>
<script>
import { getScenes, delScenes, editScenes } from '@/api/scenes'
export default {
name: 'categories',
components: {
},
data () {
return {
data: [],
columns: [
{
title: '活动日期',
key: 'created_at'
},
{
title: '可获取真我币',
slot: 'name'
},
{
title: '浏览人数',
slot: 'title'
},
{
title: '签到人数',
key: 'created_at'
},
{
title: '操作',
slot: 'action'
}
]
}
},
methods: {
goDetail () {
this.$router.push({ path: '/signIn/detail', query: { id: 'new' } })
}
},
mounted () {
}
}
</script>
<style lang="less"></style>
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