Browse Source

代理调整

sunkuosheng 1 day ago
parent
commit
74d5ae7211

+ 2 - 2
ruoyi-ui-gljt/.env.development

@@ -1,6 +1,6 @@
 # 页面标题
-VUE_APP_TITLE = 高龄津贴管理平台
-VUE_APP_TITLE1 = 高龄津贴管理平台
+VUE_APP_TITLE = 高龄津贴管理平台(测试)
+VUE_APP_TITLE1 = 高龄津贴管理平台(测试)
 VUE_APP_LOGO = '@/assets/images/shijihome/img_14.png'
 VUE_APP_LOGIN_LOGO = '@/assets/images/shijihome/img_14.png'
 

+ 2 - 2
ruoyi-ui-gljt/.env.production

@@ -1,6 +1,6 @@
 # 页面标题
-VUE_APP_TITLE = 高龄津贴管理平台
-VUE_APP_TITLE1 = 高龄津贴管理平台
+VUE_APP_TITLE = 高龄津贴管理平台(测试)
+VUE_APP_TITLE1 = 高龄津贴管理平台(测试)
 VUE_APP_LOGO = '@/assets/logo/logo.png'
 VUE_APP_LOGIN_LOGO = '@/assets/images/login-logo1.png'
 

+ 1 - 1
ruoyi-ui-gljt/src/layout/components/Navbar.vue

@@ -121,7 +121,7 @@ export default {
         .then(() => {
           this.$store.dispatch("LogOut").then(() => {
             sessionStorage.clear()
-            location.href = process.env.NODE_ENV === 'production' ? '/index' : '/index';
+            location.href = process.env.NODE_ENV === 'production' ? '/gljt/' : '/index';
           });
         })
         .catch(() => {});

+ 2 - 1
ruoyi-ui-gljt/src/router/index.js

@@ -179,8 +179,9 @@ Router.prototype.push = function push(location) {
 }
 
 export default new Router({
-  base: process.env.NODE_ENV === 'production' ? '/glweb/' : '/',
+  base: process.env.NODE_ENV === 'production' ? '/gljt/' : '/',
   mode: 'history', // 去掉url中的#
+  // mode: 'hash', // 去掉url中的#
   scrollBehavior: () => ({ y: 0 }),
   routes: constantRoutes
 })

+ 1 - 1
ruoyi-ui-gljt/src/utils/request.js

@@ -86,7 +86,7 @@ service.interceptors.response.use(res => {
       ).then(() => {
         isRelogin.show = false;
         store.dispatch('LogOut').then(() => {
-          location.href = '/index';
+          location.href = process.env.NODE_ENV === 'production' ? '/gljt/' : '/index';;
         })
       }).catch(() => {
         isRelogin.show = false;

+ 2 - 2
ruoyi-ui-gljt/vue.config.js

@@ -19,10 +19,10 @@ module.exports = {
   // 默认情况下,Vue CLI 会假设你的应用是被部署在一个域名的根路径上
   // 例如 https://www.ruoyi.vip/。如果应用被部署在一个子路径上,你就需要用这个选项指定这个子路径。例如,如果你的应用被部署在 https://www.ruoyi.vip/admin/,则设置 baseUrl 为 /admin/。
   // publicPath: process.env.NODE_ENV === 'production' ? '/jmgc/' : '/',
-  publicPath: process.env.NODE_ENV === 'production' ? '/glweb/' : '/',
+  publicPath: process.env.NODE_ENV === 'production' ? '/gljt/' : '/',
   // 在npm run build 或 yarn build 时 ,生成文件的目录名称(要和baseUrl的生产环境路径一致)(默认dist)
   // outputDir: 'dist/jmgc',
-  outputDir: 'dist/glweb',
+  outputDir: 'dist/gljt',
   // 用于放置生成的静态资源 (js、css、img、fonts) 的;(项目打包之后,静态资源会放在这个文件夹下)
   assetsDir: 'static',
   // 是否开启eslint保存检测,有效值:ture | false | 'error'