初始化
This commit is contained in:
@@ -1,4 +1,27 @@
|
||||
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||
/**
|
||||
* 配置文件
|
||||
* 一般只需要修噶appId即可使用
|
||||
* 如果涉及到独立后端API的二次开发,可以修改apiBaseUrl
|
||||
* @author Websoft Inc.
|
||||
*/
|
||||
|
||||
// 填租户ID
|
||||
const appId = 10398;
|
||||
// 接口地址
|
||||
let apiBaseUrl = 'https://cms-api.websoft.top/api'
|
||||
// 应用名称
|
||||
const appName = '广西活动房_广西集装箱_打包箱_隔离房_广西伟冠集成房屋有限公司';
|
||||
|
||||
|
||||
|
||||
|
||||
// ------------------------------- Config by Websoft Inc. ---------------------------- //
|
||||
|
||||
const isDev = process.env.NODE_ENV === 'development'
|
||||
if(isDev){
|
||||
apiBaseUrl = 'http://127.0.0.1:9002/api'
|
||||
}
|
||||
|
||||
export default defineNuxtConfig({
|
||||
compatibilityDate: '2024-04-03',
|
||||
devtools: {enabled: false},
|
||||
@@ -29,17 +52,26 @@ export default defineNuxtConfig({
|
||||
devServer: {
|
||||
port: 16880
|
||||
},
|
||||
runtimeConfig: {
|
||||
public: {
|
||||
// 开发环境配置
|
||||
// tenantId: '5',
|
||||
// apiServer: 'http://127.0.0.1:30000/api',
|
||||
|
||||
// 生产环境
|
||||
apiServer: 'https://common-api.websoft.top/api',
|
||||
globalTitle: '网宿软件',
|
||||
domain: 'websoft.top'
|
||||
$production: {
|
||||
devServer: {
|
||||
port: appId
|
||||
}
|
||||
},
|
||||
// 私有配置项
|
||||
$development: {
|
||||
devServer: {
|
||||
port: appId
|
||||
}
|
||||
},
|
||||
runtimeConfig: {
|
||||
// 客户端获取使用
|
||||
public: {
|
||||
apiBaseUrl,
|
||||
tenantId: appId,
|
||||
siteName: appName,
|
||||
domain: 'websoft.top',
|
||||
// 核心接口
|
||||
apiServer: 'https://server.gxwebsoft.com/api',
|
||||
appSecret: ''
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user