yangyin
2024-09-05 b22321d154f8a35babba928d6cbf387af576d8a3
Merge branch 'master' of http://47.103.154.90:83/r/WI/Web.Admin.V1.0
已修改4个文件
34 ■■■■■ 文件已修改
.gitignore 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
scripts/build.js 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
scripts/helper.js 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/login/UserMenuData.ts 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
.gitignore
@@ -2,7 +2,7 @@
node_modules
/dist
/public
amis-editor
customer_list/*/deploy.json
# local env files
scripts/build.js
@@ -1,4 +1,6 @@
const path = require('path');
const fs = require('fs-extra');
const {
    copyFile,
    distDir,
@@ -11,7 +13,10 @@
    firstCustomerName,
    checkCustomer,
    formatDate,
    logSuccess
    logSuccess,
    logWarn,
    rootDir,
    publicDir
} = require('./helper');
const { execSync } = require('child_process');
if (customerList?.length !== 1) {
@@ -20,6 +25,23 @@
}
checkCustomer('npm run build', firstCustomerName);
copyFile();
// 复制amis-editor 到 public文件夹中
const amisEditorPath = path.join(rootDir,'amis-editor');
const targetPath = path.join(publicDir,'amis-editor')
const isExist = fs.pathExistsSync(amisEditorPath);
if(!isExist){
    logWarn('amis-editor 不存在!');
}else{
    const isExist = fs.pathExistsSync(targetPath);
    if(!isExist){
        fs.mkdirSync(targetPath);
    }
    const res = fs.copySync(amisEditorPath,targetPath)
    res ?? logSuccess('========= 已集成 amis-editor =========')
}
// 更改 import.meta.glob
updateImportGlob();
try {
scripts/helper.js
@@ -32,6 +32,11 @@
    logColor(text, 'green');
};
const logWarn = (text) => {
    logColor(text, 'yellow');
};
/**
 * 退出脚本
 */
@@ -336,6 +341,7 @@
    //#region ====================== 打印 ======================
    logError,
    logSuccess,
    logWarn,
    //#endregion
    formatDate,
src/api/login/UserMenuData.ts
@@ -24,7 +24,7 @@
                Permission: '',
                Icon: 'ywifont ywicon-a-appround15',
                IsIframe: true,
                OutLink: 'http://101.133.133.173:9096/amis',
                OutLink: '/amis-editor/index.html',
                IsHide: false,
                Weight: 0,
                SortCode: 2,