Commit eaeb5433 by chenxin

fix:改为hash

parent d54bec35
...@@ -51,8 +51,7 @@ const devWebpackConfig = merge(baseWebpackConfig, { ...@@ -51,8 +51,7 @@ const devWebpackConfig = merge(baseWebpackConfig, {
new HtmlWebpackPlugin({ new HtmlWebpackPlugin({
filename: 'index.html', filename: 'index.html',
template: 'index.html', template: 'index.html',
inject: true, inject: true
BASE_URL: '/'
}), }),
// copy custom static assets // copy custom static assets
new CopyWebpackPlugin([ new CopyWebpackPlugin([
......
...@@ -64,7 +64,6 @@ const webpackConfig = merge(baseWebpackConfig, { ...@@ -64,7 +64,6 @@ const webpackConfig = merge(baseWebpackConfig, {
filename: config.build.index, filename: config.build.index,
template: 'index.html', template: 'index.html',
inject: true, inject: true,
BASE_URL: '/marketing/',
minify: { minify: {
removeComments: true, removeComments: true,
collapseWhitespace: true, collapseWhitespace: true,
......
...@@ -3,22 +3,22 @@ ...@@ -3,22 +3,22 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0"> <meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="shortcut icon" href="<%= htmlWebpackPlugin.options.BASE_URL %>static/img/favicon.ico"> <link rel="shortcut icon" href="./static/img/favicon.ico">
<title>GIC后台</title> <title>GIC后台</title>
<link rel="stylesheet" type="text/css" href="<%= htmlWebpackPlugin.options.BASE_URL %>static/css/iconfont.css"> <link rel="stylesheet" type="text/css" href="static/css/iconfont.css">
<link rel="stylesheet" type="text/css" href="<%= htmlWebpackPlugin.options.BASE_URL %>static/css/common.css"> <link rel="stylesheet" type="text/css" href="static/css/common.css">
<link rel="stylesheet" href="//web-1251519181.file.myqcloud.com/components/element.2.12.0.css"> <link rel="stylesheet" href="//web-1251519181.file.myqcloud.com/components/element.2.12.0.css">
<!-- element 皮肤 --> <!-- element 皮肤 -->
<!-- <link rel="stylesheet" type="text/css" href="http://web-1251519181.file.myqcloud.com/lib/elementUI/theme.1.0.1/index.css"> --> <!-- <link rel="stylesheet" type="text/css" href="http://web-1251519181.file.myqcloud.com/lib/elementUI/theme.1.0.1/index.css"> -->
<!-- GrowingIO Analytics code version 2.1 --> <!-- GrowingIO Analytics code version 2.1 -->
<!-- Copyright 2015-2018 GrowingIO, Inc. More info available at http://www.growingio.com --> <!-- Copyright 2015-2018 GrowingIO, Inc. More info available at http://www.growingio.com -->
<script type='text/javascript'> <!-- <script type='text/javascript'>
!function(e,t,n,g,i){e[i]=e[i]||function(){(e[i].q=e[i].q||[]).push(arguments)},n=t.createElement("script"),tag=t.getElementsByTagName("script")[0],n.async=1,n.src=('https:'==document.location.protocol?'https://':'http://')+g,tag.parentNode.insertBefore(n,tag)}(window,document,"script","assets.giocdn.com/2.1/gio.js","gio"); !function(e,t,n,g,i){e[i]=e[i]||function(){(e[i].q=e[i].q||[]).push(arguments)},n=t.createElement("script"),tag=t.getElementsByTagName("script")[0],n.async=1,n.src=('https:'==document.location.protocol?'https://':'http://')+g,tag.parentNode.insertBefore(n,tag)}(window,document,"script","assets.giocdn.com/2.1/gio.js","gio");
gio('init','8be12240a3749eab', {}); gio('init','8be12240a3749eab', {});
//custom page code begin here //custom page code begin here
//custom page code end here //custom page code end here
gio('send'); gio('send');
</script> </script> -->
<!-- End GrowingIO Analytics code version: 2.1 --> <!-- End GrowingIO Analytics code version: 2.1 -->
</head> </head>
<body> <body>
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
<script src="//web-1251519181.file.myqcloud.com/components/member-group.2.0.01.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/member-group.2.0.01.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/store-card.2.0.13.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/store-card.2.0.13.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/confirm-people.2.0.01.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/confirm-people.2.0.01.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/people.2.0.37.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/people.2.0.38.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/export-excel.2.0.12.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/export-excel.2.0.12.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/input.2.0.00.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/input.2.0.00.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/delete.2.0.00.js"></script> <script src="//web-1251519181.file.myqcloud.com/components/delete.2.0.00.js"></script>
......
...@@ -46,7 +46,7 @@ export default { ...@@ -46,7 +46,7 @@ export default {
.then(() => { .then(() => {
logout(); // 登出 logout(); // 登出
// if (process.env.NODE_ENV === 'production') { // eslint-disable-line // if (process.env.NODE_ENV === 'production') { // eslint-disable-line
window.location.href = '/gic-web/login'; window.location.href = '/gic-web/#/login';
// } // }
}) })
.catch(() => { .catch(() => {
......
...@@ -220,7 +220,8 @@ export default { ...@@ -220,7 +220,8 @@ export default {
that.asideHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 64 + 'px'; that.asideHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 64 + 'px';
//获取项目名 pathname (路由的hash) //获取项目名 pathname (路由的hash)
that.pathName = window.location.pathname.split('/')[2]; that.pathName = window.location.hash.split('/')[1]; // hash
// that.pathName = window.location.pathname.split('/')[2]; hoistory
if (that.pathName.indexOf('?') != -1) { if (that.pathName.indexOf('?') != -1) {
that.pathName = that.pathName.split('?')[0]; that.pathName = that.pathName.split('?')[0];
} }
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<div class="layout-right" :class="[{ asideShow: asideShow }, { collapseFlag: asideShow && collapseFlag }]"> <div class="layout-right" :class="[{ asideShow: asideShow }, { collapseFlag: asideShow && collapseFlag }]">
<div class="layout-title"> <div class="layout-title">
<el-breadcrumb class="dm-breadcrumb" separator="/"> <el-breadcrumb class="dm-breadcrumb" separator="/">
<el-breadcrumb-item :to="{ path: '' }"><a href="/report/memberSummary">首页</a></el-breadcrumb-item> <el-breadcrumb-item :to="{ path: '' }"><a href="/report/#/memberSummary">首页</a></el-breadcrumb-item>
<el-breadcrumb-item :class="{ 'no-link': !v.path }" v-for="(v, i) in breadcrumb" :key="i" :to="{ path: v.path }">{{ v.name }}</el-breadcrumb-item> <el-breadcrumb-item :class="{ 'no-link': !v.path }" v-for="(v, i) in breadcrumb" :key="i" :to="{ path: v.path }">{{ v.name }}</el-breadcrumb-item>
</el-breadcrumb> </el-breadcrumb>
<h3> <h3>
......
...@@ -15,7 +15,6 @@ if (process.env.NODE_ENV == 'development') { // eslint-disable-line ...@@ -15,7 +15,6 @@ if (process.env.NODE_ENV == 'development') { // eslint-disable-line
Vue.prototype.axios = axios; Vue.prototype.axios = axios;
Vue.prototype.axios.withCredentials = true; Vue.prototype.axios.withCredentials = true;
Vue.prototype.axios.defaults.timeout = 50000;
Object.keys(directives).map(item => Vue.directive(item, directives[item])); Object.keys(directives).map(item => Vue.directive(item, directives[item]));
window.$bus = new Vue(); window.$bus = new Vue();
let flag = false; let flag = false;
......
...@@ -4,8 +4,6 @@ import routes from './routes'; ...@@ -4,8 +4,6 @@ import routes from './routes';
Vue.use(Router); Vue.use(Router);
let router = new Router({ let router = new Router({
mode: 'history',
base: '/marketing/',
routes, routes,
// scrollBehavior: () => ({ y: 0 }) // scrollBehavior: () => ({ y: 0 })
//使用keep-alive标签后部分安卓机返回缓存页位置不精确问题 //使用keep-alive标签后部分安卓机返回缓存页位置不精确问题
......
...@@ -192,7 +192,7 @@ ...@@ -192,7 +192,7 @@
<el-form-item label="适用门店"> <el-form-item label="适用门店">
<el-radio :disabled="isEdit" v-model="storeMode" :label="0">所有门店</el-radio> <el-radio :disabled="isEdit" v-model="storeMode" :label="0">所有门店</el-radio>
<el-radio :disabled="isEdit" v-model="storeMode" :label="1">部分门店</el-radio> <el-radio :disabled="isEdit" v-model="storeMode" :label="1">部分门店</el-radio>
<span v-if="isEdit" class="fz12 gray ml20">编辑适用门店前会员领取该卡券不包含新增的适用门店;编辑适用门店后会员领取该卡券包含新增的适用门店。</span> <span v-if="isEdit" class="fz12 gray ml20">卡券编辑时修改的适用门店信息不再回写至ERP</span>
<!-- :readonly="isEdit" --> <!-- :readonly="isEdit" -->
<vue-gic-store-card class="pt10" v-show="storeMode" ref="storeCard" :uuid.sync="uuid"></vue-gic-store-card> <vue-gic-store-card class="pt10" v-show="storeMode" ref="storeCard" :uuid.sync="uuid"></vue-gic-store-card>
<el-alert v-show="storeMode && form.cardApplyChannel.indexOf('WMmicroMall') !== -1" title="选择的门店必须保持与微盟侧门店一致,请确认选择无误" type="warning" show-icon :closable="false" class="mt20 width80"></el-alert> <el-alert v-show="storeMode && form.cardApplyChannel.indexOf('WMmicroMall') !== -1" title="选择的门店必须保持与微盟侧门店一致,请确认选择无误" type="warning" show-icon :closable="false" class="mt20 width80"></el-alert>
......
...@@ -11,16 +11,16 @@ ...@@ -11,16 +11,16 @@
<p class="fz13 gray">{{ scope.row.addressFullName }}</p> <p class="fz13 gray">{{ scope.row.addressFullName }}</p>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column min-width="100" align="left" prop="storeGroupFullName" label="所在分组"></el-table-column> <el-table-column min-width="100" align="left" prop="storeGroupFullName" label="所在分组" sortable="custom"></el-table-column>
<el-table-column width="120" align="left" prop="cardSize" label="卡券数量"></el-table-column> <el-table-column width="120" align="left" prop="cardSize" label="卡券数量" sortable="custom"></el-table-column>
<el-table-column width="120" align="left" prop="getedQuantity" label="领取数量"></el-table-column> <el-table-column width="120" align="left" prop="getedQuantity" label="领取数量" sortable="custom"></el-table-column>
<el-table-column width="120" align="left" prop="usageQuantity" label="使用数量"></el-table-column> <el-table-column width="120" align="left" prop="usageQuantity" label="使用数量" sortable="custom"></el-table-column>
<el-table-column width="120" align="left" prop="col4" label="核销率"> <el-table-column width="120" align="left" prop="col4" label="核销率" sortable="custom">
<template slot-scope="scope"> <template slot-scope="scope">
{{ ((scope.row.usageQuantity * 100) / (scope.row.getedQuantity === 0 ? 1 : scope.row.getedQuantity)).toFixed(2) }}% {{ ((scope.row.usageQuantity * 100) / (scope.row.getedQuantity === 0 ? 1 : scope.row.getedQuantity)).toFixed(2) }}%
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="120" align="left" prop="saleAmount" label="销售额"></el-table-column> <el-table-column width="120" align="left" prop="saleAmount" label="销售额" sortable="custom"></el-table-column>
<el-table-column label="操作" align="left" width="160px" fixed="right"> <el-table-column label="操作" align="left" width="160px" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="$router.push('/card/shelf/' + scope.row.shelfId)">卡券管理</el-button> <el-button type="text" @click="$router.push('/card/shelf/' + scope.row.shelfId)">卡券管理</el-button>
......
...@@ -151,7 +151,7 @@ ...@@ -151,7 +151,7 @@
<el-form-item label="适用门店"> <el-form-item label="适用门店">
<el-radio :disabled="isEdit" v-model="storeMode" :label="0">所有门店</el-radio> <el-radio :disabled="isEdit" v-model="storeMode" :label="0">所有门店</el-radio>
<el-radio :disabled="isEdit" v-model="storeMode" :label="1">部分门店</el-radio> <el-radio :disabled="isEdit" v-model="storeMode" :label="1">部分门店</el-radio>
<span v-if="isEdit" class="fz12 gray ml20">编辑适用门店前会员领取该卡券不包含新增的适用门店;编辑适用门店后会员领取该卡券包含新增的适用门店。</span> <span v-if="isEdit" class="fz12 gray ml20">卡券编辑时修改的适用门店信息不再回写至ERP</span>
<vue-gic-store-card class="pt10" v-show="storeMode" ref="storeCard" :uuid.sync="uuid" scenes="edaixi" /> <vue-gic-store-card class="pt10" v-show="storeMode" ref="storeCard" :uuid.sync="uuid" scenes="edaixi" />
</el-form-item> </el-form-item>
......
...@@ -132,8 +132,8 @@ export default { ...@@ -132,8 +132,8 @@ export default {
config: { config: {
// 如果需要上传功能,找后端小伙伴要服务器接口地址 // 如果需要上传功能,找后端小伙伴要服务器接口地址
serverUrl: config.api + '/api-plug/upload-img', serverUrl: config.api + '/api-plug/upload-img',
// 你的UEditor资源存放的路径,相对于打包后的index.html // hash:./static/UEditor/ // 你的UEditor资源存放的路径,相对于打包后的index.html
UEDITOR_HOME_URL: process.env['NODE_ENV'] === 'development' ? '/static/UEditor/' : '/marketing/static/UEditor/' , // eslint-disable-line UEDITOR_HOME_URL: './static/UEditor/',
// 编辑器不自动被内容撑高 // 编辑器不自动被内容撑高
autoHeightEnabled: false, autoHeightEnabled: false,
// 初始容器高度 // 初始容器高度
......
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