Signed-off-by: Logaxn <logaxn@foxmail.com>
This commit is contained in:
parent
e7c895c7f0
commit
8c86d61235
|
@ -87,23 +87,78 @@ export const constantRouterMap = [
|
||||||
path: 'list',
|
path: 'list',
|
||||||
component: () => import('@/views/gift/list'),
|
component: () => import('@/views/gift/list'),
|
||||||
name: 'GiftList',
|
name: 'GiftList',
|
||||||
meta: { title: 'Gift List', icon: 'table', affix: true }
|
// affix 固定在标签栏上
|
||||||
|
meta: { title: 'Gift List', icon: 'table', affix: false }
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/documentation',
|
path: '/customer',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: 'list',
|
||||||
|
component: () => import('@/views/gift/list'),
|
||||||
|
name: 'CustomerList',
|
||||||
|
meta: { title: 'Customer List', icon: 'user', affix: false }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/vip',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: 'list',
|
||||||
|
component: () => import('@/views/gift/list'),
|
||||||
|
name: 'VIPList',
|
||||||
|
meta: { title: 'VIP List', icon: 'theme', affix: false }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/knowledge',
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/documentation/index',
|
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'index',
|
path: 'index',
|
||||||
component: () => import('@/views/documentation/index'),
|
component: () => import('@/views/documentation/index'),
|
||||||
name: 'Documentation',
|
name: 'Knowledge',
|
||||||
meta: { title: 'documentation', icon: 'documentation', affix: true }
|
meta: { title: 'Knowledge', icon: 'tab', affix: false }
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/settings',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: 'index',
|
||||||
|
component: () => import('@/views/documentation/index'),
|
||||||
|
name: 'Settings',
|
||||||
|
meta: { title: 'Settings', icon: 'example', affix: false }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'test-form',
|
||||||
|
component: Layout,
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: 'https://dev.zealousbrand.com/free-gift',
|
||||||
|
meta: { title: 'Test Form', icon: 'link' }
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
]
|
||||||
|
|
||||||
|
export default new Router({
|
||||||
|
// mode: 'history', // require service support
|
||||||
|
scrollBehavior: () => ({ y: 0 }),
|
||||||
|
routes: constantRouterMap
|
||||||
|
})
|
||||||
|
|
||||||
|
export const asyncRouterMap = [
|
||||||
{
|
{
|
||||||
path: '/guide',
|
path: '/guide',
|
||||||
component: Layout,
|
component: Layout,
|
||||||
|
@ -116,16 +171,7 @@ export const constantRouterMap = [
|
||||||
meta: { title: 'guide', icon: 'guide', noCache: true }
|
meta: { title: 'guide', icon: 'guide', noCache: true }
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
},
|
||||||
]
|
|
||||||
|
|
||||||
export default new Router({
|
|
||||||
// mode: 'history', // require service support
|
|
||||||
scrollBehavior: () => ({ y: 0 }),
|
|
||||||
routes: constantRouterMap
|
|
||||||
})
|
|
||||||
|
|
||||||
export const asyncRouterMap = [
|
|
||||||
{
|
{
|
||||||
path: '/permission',
|
path: '/permission',
|
||||||
component: Layout,
|
component: Layout,
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
<div class="filter-container">
|
<div class="filter-container">
|
||||||
|
<el-button class="filter-item" style="margin-right: 10px;" type="primary" icon="el-icon-edit" @click="handleCreate">{{ $t('table.add') }}</el-button>
|
||||||
<el-input :placeholder="$t('table.title')" v-model="listQuery.title" style="width: 200px;" class="filter-item" @keyup.enter.native="handleFilter"/>
|
<el-input :placeholder="$t('table.title')" v-model="listQuery.title" style="width: 200px;" class="filter-item" @keyup.enter.native="handleFilter"/>
|
||||||
<el-select v-model="listQuery.importance" :placeholder="$t('table.importance')" clearable style="width: 90px" class="filter-item">
|
<el-select v-model="listQuery.importance" :placeholder="$t('table.importance')" clearable style="width: 90px" class="filter-item">
|
||||||
<el-option v-for="item in importanceOptions" :key="item" :label="item" :value="item"/>
|
<el-option v-for="item in importanceOptions" :key="item" :label="item" :value="item"/>
|
||||||
|
@ -12,7 +13,6 @@
|
||||||
<el-option v-for="item in sortOptions" :key="item.key" :label="item.label" :value="item.key"/>
|
<el-option v-for="item in sortOptions" :key="item.key" :label="item.label" :value="item.key"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="handleFilter">{{ $t('table.search') }}</el-button>
|
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="handleFilter">{{ $t('table.search') }}</el-button>
|
||||||
<el-button class="filter-item" style="margin-left: 10px;" type="primary" icon="el-icon-edit" @click="handleCreate">{{ $t('table.add') }}</el-button>
|
|
||||||
<el-button v-waves :loading="downloadLoading" class="filter-item" type="primary" icon="el-icon-download" @click="handleDownload">{{ $t('table.export') }}</el-button>
|
<el-button v-waves :loading="downloadLoading" class="filter-item" type="primary" icon="el-icon-download" @click="handleDownload">{{ $t('table.export') }}</el-button>
|
||||||
<el-checkbox v-model="showReviewer" class="filter-item" style="margin-left:15px;" @change="tableKey=tableKey+1">{{ $t('table.reviewer') }}</el-checkbox>
|
<el-checkbox v-model="showReviewer" class="filter-item" style="margin-left:15px;" @change="tableKey=tableKey+1">{{ $t('table.reviewer') }}</el-checkbox>
|
||||||
</div>
|
</div>
|
||||||
|
@ -69,11 +69,6 @@
|
||||||
<span v-else>0</span>
|
<span v-else>0</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column :label="$t('table.importance')" width="80px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<svg-icon v-for="n in +scope.row.importance" :key="n" icon-class="star" class="meta-item__icon"/>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column :label="$t('table.status')" class-name="status-col" width="100">
|
<el-table-column :label="$t('table.status')" class-name="status-col" width="100">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag :type="scope.row.status | statusFilter">{{ scope.row.status }}</el-tag>
|
<el-tag :type="scope.row.status | statusFilter">{{ scope.row.status }}</el-tag>
|
||||||
|
@ -84,11 +79,6 @@
|
||||||
<span style="color:red;">{{ scope.row.reviewer }}</span>
|
<span style="color:red;">{{ scope.row.reviewer }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column :label="$t('table.date')" width="150px" align="center">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<span>{{ scope.row.timestamp | parseTime('{y}-{m}-{d} {h}:{i}') }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column :label="$t('table.actions')" align="center" width="230" class-name="small-padding fixed-width">
|
<el-table-column :label="$t('table.actions')" align="center" width="230" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button type="primary" size="mini" @click="handleUpdate(scope.row)">{{ $t('table.edit') }}</el-button>
|
<el-button type="primary" size="mini" @click="handleUpdate(scope.row)">{{ $t('table.edit') }}</el-button>
|
||||||
|
@ -105,29 +95,35 @@
|
||||||
<pagination v-show="total>0" :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList"/>
|
<pagination v-show="total>0" :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList"/>
|
||||||
|
|
||||||
<el-dialog :title="textMap[dialogStatus]" :visible.sync="dialogFormVisible">
|
<el-dialog :title="textMap[dialogStatus]" :visible.sync="dialogFormVisible">
|
||||||
<el-form ref="dataForm" :rules="rules" :model="temp" label-position="left" label-width="70px" style="width: 400px; margin-left:50px;">
|
<el-form ref="dataForm" :rules="rules" :model="temp" label-position="left" label-width="125px" style="width: 670px; margin-left:50px;">
|
||||||
<el-form-item :label="$t('table.type')" prop="type">
|
<el-form-item :label="$t('giftList.giftName')" prop="title">
|
||||||
|
<el-input v-model="temp.title"/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item :label="'Seller SKU'" prop="title">
|
||||||
|
<el-input v-model="temp.title"/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item :label="'Short Description'" required="true">
|
||||||
|
<el-input :autosize="{ minRows: 2, maxRows: 4}" v-model="temp.remark" type="textarea" placeholder="Please input"/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item :label="'Product Link'" required="true">
|
||||||
|
<el-input v-model="temp.remark" placeholder="Please input"/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item :label="'MarketPlace'" prop="type">
|
||||||
<el-select v-model="temp.type" class="filter-item" placeholder="Please select">
|
<el-select v-model="temp.type" class="filter-item" placeholder="Please select">
|
||||||
<el-option v-for="item in calendarTypeOptions" :key="item.key" :label="item.display_name" :value="item.key"/>
|
<el-option v-for="item in calendarTypeOptions" :key="item.key" :label="item.display_name" :value="item.key"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.date')" prop="timestamp">
|
<el-form-item :label="'ASIN'" required="true">
|
||||||
<el-date-picker v-model="temp.timestamp" type="datetime" placeholder="Please pick a date"/>
|
<el-input v-model="temp.remark" placeholder="Please input"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.title')" prop="title">
|
<el-form-item :label="'Cost'" prop="title">
|
||||||
<el-input v-model="temp.title"/>
|
<el-input v-model="temp.title"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.status')">
|
<el-form-item :label="$t('table.status')" required="true">
|
||||||
<el-select v-model="temp.status" class="filter-item" placeholder="Please select">
|
<el-select v-model="temp.status" class="filter-item" placeholder="Please select">
|
||||||
<el-option v-for="item in statusOptions" :key="item" :label="item" :value="item"/>
|
<el-option v-for="item in statusOptions" :key="item" :label="item" :value="item"/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.importance')">
|
|
||||||
<el-rate v-model="temp.importance" :colors="['#99A9BF', '#F7BA2A', '#FF9900']" :max="3" style="margin-top:8px;"/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item :label="$t('table.remark')">
|
|
||||||
<el-input :autosize="{ minRows: 2, maxRows: 4}" v-model="temp.remark" type="textarea" placeholder="Please input"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
</el-form>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
<el-button @click="dialogFormVisible = false">{{ $t('table.cancel') }}</el-button>
|
<el-button @click="dialogFormVisible = false">{{ $t('table.cancel') }}</el-button>
|
||||||
|
@ -220,7 +216,7 @@
|
||||||
dialogStatus: '',
|
dialogStatus: '',
|
||||||
textMap: {
|
textMap: {
|
||||||
update: 'Edit',
|
update: 'Edit',
|
||||||
create: 'Create'
|
create: 'Gift Information'
|
||||||
},
|
},
|
||||||
dialogPvVisible: false,
|
dialogPvVisible: false,
|
||||||
pvData: [],
|
pvData: [],
|
||||||
|
|
Loading…
Reference in New Issue