Commit a24b3b2b by 王立鹏

Merge branch '线上优化/修改测试地址' into 'master'

线上优化/修改测试地址

See merge request !34
parents b4d63c7f b6a2f55a
......@@ -14,10 +14,10 @@ const deploySlug = getDeploySlug(branchName);
const MAX_DEPLOY_BRANCH_COUNT = 5;
const connectInfo = {
host: "47.119.149.50",
port: "22",
username: "root",
password: "Qdt20250205",
host: process.env.DEPLOY_TEST_HOST,
port: process.env.DEPLOY_TEST_PORT,
username: process.env.DEPLOY_TEST_USERNAME,
password: process.env.DEPLOY_TEST_PASSWORD,
};
const remoteRootPath = "/usr/local/nginx/www/culture";
......@@ -352,11 +352,11 @@ async function writeIndexHtml(entries) {
function getAccountCode() {
const storedValue = window.localStorage.getItem(STORAGE_KEY)
return storedValue && storedValue.trim() ? storedValue.trim() : DEFAULT_ACCOUNT
return storedValue === null ? DEFAULT_ACCOUNT : storedValue.trim()
}
function setAccountCode(value) {
const finalValue = value && value.trim() ? value.trim() : DEFAULT_ACCOUNT
const finalValue = value.trim()
window.localStorage.setItem(STORAGE_KEY, finalValue)
if (accountInput && accountInput.value !== finalValue) {
accountInput.value = finalValue
......@@ -365,8 +365,8 @@ async function writeIndexHtml(entries) {
}
function goToBranch(slug) {
const code = encodeURIComponent(getAccountCode())
window.location.href = '/' + slug + '/?code=' + code + '@yswg.com.cn'
const code = getAccountCode()
window.location.href = '/' + slug + '/' + (code ? '?code=' + encodeURIComponent(code) + '@yswg.com.cn' : '')
}
if (accountInput) {
......
......@@ -20,7 +20,7 @@
"build-only": "vite build",
"build:dev": "nvm use 20 && vite build --mode development",
"build:test": "nvm use 20 && vite build --mode test",
"deploy:test": "node deploy/deploytest.js",
"deploy:test": "node --env-file=.env.local deploy/deploytest.js",
"build:prod": "nvm use 20 && vite build --mode production",
"deploy:prod": "node --env-file=.env.local deploy/deployprod.js",
"deploy:prod:update-info": "node --env-file=.env.local deploy/deployprod.js --update-info"
......
......@@ -26,7 +26,7 @@ export const resolveUploadBaseUrl = () => {
};
const OA_UPLOAD_COMMON_BASE_URL = 'http://47.112.96.71:8082'
const CHUNK_UPLOAD_THRESHOLD = 10 * 1024 * 1024
const CHUNK_UPLOAD_THRESHOLD = 1 * 1024 * 1024
const CHUNK_SIZE = 5 * 1024 * 1024
const MAX_CONCURRENT_UPLOADS = 3
const CHUNK_API_AUTH_SECRET = '4821-7395-1642-8053-2971-5604-9182-4307'
......
......@@ -17,15 +17,14 @@ export const app_config: { [key: string]: IConfig } = {
// 测试环境 暂时无测试环境部署
test: {
// baseUrl: 'http://culture.yswg.com.cn:8089', // 线上测试机
baseUrl: 'http://192.168.2.55:8089', // 首拥本地
baseUrl: 'http://47.119.149.50:3459', // 线上测试机
loginType: 1,
wxRedirect: '',
},
// 开发环境
development: {
// baseUrl: 'http://culture.yswg.com.cn:8089', // 线上测试机
// baseUrl: 'http://47.119.149.50:3459', // 线上测试机
// baseUrl: 'http://192.168.2.168:8089', // 立鹏本地/
baseUrl: 'http://192.168.2.55:8089', // 首拥本地
loginType: 1,
......
......@@ -40,4 +40,7 @@ app.use(LuckyCanvas)
app.directive('parse-comment', vParseComment)
// 全局组件挂载
app.component('SvgIcon', SvgIcon)
app.mount('#app')
router.isReady().then(() => {
app.mount('#app')
})
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