提交 4884b159 authored 作者: lidongxu's avatar lidongxu

refactor(mobile): 调整:移动端勤策内嵌网页的 rem 适配样式和菜单结构调整

上级 bc89598e
......@@ -14,8 +14,7 @@ VITE_APP_PROMOTION = '/dev-promotion-api' # 促销
# 飞书服务回调地址(本地测试已经通过并上线,后台飞书登录接口重定向地址已经不是 localhost 了所以本地开发无需使用飞书登录,线上已经可用)
VITE_APP_REDIRECT_URL = 'http://localhost:8085'
# 积木报表服务地址
# VITE_APP_REPORT_URL = 'https://sfa-qa.wxl66.cn'
VITE_APP_REPORT_URL = 'https://localhost:8085'
VITE_APP_REPORT_URL = 'https://sfa-qa.wxl66.cn'
# 积木报表预览地址
VITE_APP_REPORT_PREVIEW_URL = '#/report/jmreport/view'
# 积木报表分享预览地址(后台给的地址会包含后续的/jmreport/shareview)
......
......@@ -29,7 +29,7 @@ import eventBus from '@/utils/eventBus'
import { chooseFile } from '@/utils/upload'
/****************** 移动端 ******************/
import registerMobile from "@/mobile/main.js"
import registerMobile from "@/views/mobile/main.js"
// 分页
import Pagination from '@/components/Pagination'
......
......@@ -35,6 +35,7 @@ router.beforeEach((to, from, next) => {
// 获取用户信息
useUserStore().getInfo().then(() => {
isRelogin.show = false
// 获取路由表
usePermissionStore().generateRoutes().then(accessRoutes => {
// 获取版本信息
useVersionStore().getVersion().then((res) => {
......
......@@ -121,36 +121,36 @@ export const constantMobileRoutes = [
{
path: '/m',
redirect: '/m/menu',
component: () => import('@/mobile/index'),
component: () => import('@/views/mobile/index'),
hidden: true,
children: [
// 菜单页
{
path: 'menu',
component: () => import('@/mobile/views/menu'),
component: () => import('@/views/mobile/views/menu'),
name: 'm_menu',
},
// 促销计划
{
path: 'promotion_plan', // 列表
component: () => import('@/mobile/views/promotion/plan/index'),
component: () => import('@/views/mobile/views/promotion/plan/index'),
name: 'm_promotion_plan',
meta: { keepAlive: true } // 标记该路由需要缓存
},
{
path: 'promotion_plan_detail/:planId', // 详情
component: () => import('@/mobile/views/promotion/plan/detail'),
component: () => import('@/views/mobile/views/promotion/plan/detail'),
name: 'm_promotion_detail',
},
{
path: 'promotion_plan_editing/:planId?', // 增改
component: () => import('@/mobile/views/promotion/plan/editing'),
component: () => import('@/views/mobile/views/promotion/plan/editing'),
name: 'm_promotion_editing',
},
// 稽查
{
path: 'examine/:examineId',
component: () => import('@/mobile/views/examine'),
component: () => import('@/views/mobile/views/examine'),
name: 'm_promotion_examine',
}
]
......@@ -158,7 +158,7 @@ export const constantMobileRoutes = [
// 物流信息页面
{
path: '/logistics',
component: () => import('@/mobile/views/other/logistics'),
component: () => import('@/views/mobile/views/other/logistics'),
name: 'logistics'
}
]
......
......@@ -22,13 +22,18 @@
<script setup>
const router = useRouter();
const {proxy} = getCurrentInstance();
const { proxy } = getCurrentInstance();
const modules = [
{
title: 'CP 活动',
icons: [
{ name: '促销计划', iconName: 'shop-o', iconColor: '#5aaeec', to: '/m/promotion_plan' },
{ name: '促销稽核', iconName: 'manager-o', iconColor: '#feb73b', to: '/m/promotion_plan' },
{ name: '促销计划', iconName: 'shop-o', iconColor: '#5aaeec', to: '/m/promotion_plan' }
]
},
{
title: '稽核活动',
icons: [
{ name: '售点稽查', iconName: 'manager-o', iconColor: '#feb73b', to: '/m/promotion_plan' }
]
}
]
......@@ -68,7 +73,7 @@ const handleIconClick = (icon) => {
/* 设置模块间的间距 */
.function-module-title {
font-size: 16px;
font-size: 14px;
/* 设置标题字体大小 */
font-weight: bold;
/* 设置标题字体加粗 */
......@@ -83,12 +88,11 @@ const handleIconClick = (icon) => {
/* 设置图标间的间距 */
.function-icon {
width: 80px;
text-align: center;
.function-icon-wrap {
width: 60px;
height: 60px;
width: 40px;
height: 40px;
margin: 0 auto 10px;
background-color: aqua;
display: flex;
......@@ -99,7 +103,7 @@ const handleIconClick = (icon) => {
.van-icon {
color: white;
font-size: 35px;
font-size: 22px;
}
}
}
......
......@@ -319,6 +319,7 @@ onUnmounted(() => {
// 新增计划判断
const addNewPlan = () => {
// 后台设置按钮权限分配就能新增
if (proxy.checkPermi(['promotion:plan:create'])) {
router.push('/m/promotion_plan_editing')
} else {
......
......@@ -62,19 +62,8 @@ export default defineConfig(({ mode, command }) => {
rootValue: 37.5,
propList: ['*'],
exclude: file => {
if (file.indexOf('login')) return true
// if (file.indexOf('vant') !== -1) {
// return false
// }
// if (file.indexOf('mobile_views') !== -1) {
// return false
// }
// return true
return !(
file.includes('node_modules/vant') ||
file.includes('mobile_views') ||
file.includes('src/mobile/views')
)
const dirList = ["vant", "mobile/views"]
return !dirList.some(item => file.includes(item))
}
})
]
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论