增加帮助页面网页代码功能,以及nginx部署

This commit is contained in:
taocong 2026-06-10 17:17:07 +08:00
parent edb693e5af
commit dbb7059664
52 changed files with 521 additions and 0 deletions

2
.gitignore vendored
View File

@ -5,6 +5,8 @@
!python_bindings/**
!src/
!src/**
!help/
!help/**
!resources/
!resources/**
!*.bat

3
help/.idea/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
# 默认忽略的文件
/shelf/
/workspace.xml

1
help/.idea/.name Normal file
View File

@ -0,0 +1 @@
Uft30ChangeCodeHelp

6
help/.idea/misc.xml Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager">
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>

8
help/.idea/modules.xml Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/help.iml" filepath="$PROJECT_DIR$/help.iml" />
</modules>
</component>
</project>

3
help/Writerside/.idea/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
# 默认忽略的文件
/shelf/
/workspace.xml

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_21" default="true" project-jdk-name="21" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/Writerside.iml" filepath="$PROJECT_DIR$/.idea/Writerside.iml" />
</modules>
</component>
</project>

6
help/Writerside/c.list Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE categories
SYSTEM "https://resources.jetbrains.com/writerside/1.0/categories.dtd">
<categories>
<category id="wrs" name="Writerside documentation" order="1"/>
</categories>

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE buildprofiles SYSTEM "https://resources.jetbrains.com/writerside/1.0/build-profiles.dtd">
<buildprofiles xsi:noNamespaceSchemaLocation="https://resources.jetbrains.com/writerside/1.0/build-profiles.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<variables>
<custom-favicons>ChangeCode.png</custom-favicons>
</variables>
</buildprofiles>

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE terms SYSTEM "https://resources.jetbrains.com/writerside/1.0/glossary.dtd">
<terms>
<term name="foo">
Description of what "foo" is.
</term>
</terms>

23
help/Writerside/hi.tree Normal file
View File

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE instance-profile
SYSTEM "https://resources.jetbrains.com/writerside/1.0/product-profile.dtd">
<instance-profile id="hi"
name="Uft30ChangeCode"
start-page="Uft30ChangeCode.md">
<toc-element topic="Uft30ChangeCode.md">
<toc-element topic="设置.md"/>
</toc-element>
<toc-element topic="功能转码.md">
<toc-element topic="业务转码.md"/>
</toc-element>
<toc-element topic="功能查询.md">
<toc-element topic="UFT3功能查询.md"/>
<toc-element topic="UF20功能查询.md"/>
</toc-element>
<toc-element topic="元数据更新.md"/>
<toc-element topic="更新记录.md">
<toc-element topic="update-1-0-0.md"/>
</toc-element>
<toc-element topic="下载.md"/>
</instance-profile>

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rules SYSTEM "https://resources.jetbrains.com/writerside/1.0/redirection-rules.dtd">
<rules>
<!-- format is as follows
<rule id="<unique id>">
<accepts>page.html</accepts>
</rule>
-->
<rule id="42b8a0d">
<description>Created after removal of "Empty MD Topic" from Uft30ChangeCode</description>
<accepts>Empty-MD-Topic.html</accepts>
</rule>
</rules>

View File

@ -0,0 +1,17 @@
# UF20功能查询
查询UFT3系统中的函数信息。
## 查询条件
从下拉框选择查询(功能名称、功能编号),输入框输入查询关键词,点击"Aa"切换精确/模糊匹配模式,点击放大镜图标或按回车执行查询
- 功能名称
<img src="功能名称查询.png" alt="功能名称查询"/>
- 功能编号
<img src="模糊查询uf20.png" alt="模糊查询uf20"/>
<img src="精准查询uf20.png" alt="精准查询uf20"/>
## 双击添加
双击选中行添加转码业务,只支持LS功能添加
<img src="双击添加.png" alt="双击添加"/>

View File

@ -0,0 +1,12 @@
# UFT3功能查询
查询UFT3系统中的函数信息。
## 查询条件
从下拉框选择查询(功能名称、功能编号),输入框输入查询关键词,点击"Aa"切换精确/模糊匹配模式,点击放大镜图标或按回车执行查询
- 功能名称
<img src="功能名称查询uft3.png" alt="功能名称查询uft3"/>
- 功能编号
<img src="模糊查询UFT3.png" alt="模糊查询UFT3"/>
<img src="精准查询uft3.png" alt="精准查询uft3"/>

View File

@ -0,0 +1,3 @@
# Uft30ChangeCode
提供UFT30元数据、UF20公共资源搜索功能支持业务转码

View File

@ -0,0 +1,11 @@
# 1.0.0
1.支持业务转码
2.支持代码uf20、uft3功能查找
3.支持帮助菜单和在线帮助文档
4.支持接口元数据更新
5.设置菜单UFT30项目环境路径、UF20项目环境路径、UF20账户环境路径、转码生成路径、支持弹窗选择目录。

View File

@ -0,0 +1,18 @@
# 下载
## 全量更新
下载全量包,解压即用。
> 1.0.0版本是基础版本,包含所需功能,如果是第一次下载,请选择全量包。
{style="note"}
## 增量更新
下载增量包,解压后替换原文件即可
> 1.0.0版本是基础版本如若要从旧版升级到1.0.0及以上版本可以选择增量版本下载并将旧版根目录下的uf2touft3和当前目录替换覆盖到新版根目录。
{style="note"}
## 下载
| 版本 | 更新日期 | 全量包 | 增量包 |
|------|------------|---------------------------------------------------------------------------------|-----|
| 1.0.0 | 2026-06-01 | [Uft30ChangeCode-1.0.0.zip](http://10.20.163.105:6045/download/uft3changecode/Uft30ChangeCode-1.0.0.zip) | |

View File

@ -0,0 +1,27 @@
# 业务转码
将UF20函数转换为UFT3函数格式的核心功能。
## 功能列表管理
点击"添加"按钮,输入函数名添加到转码列表
<img src="添加函数.png" alt="添加函数"/>
点击表格操作按钮可编辑函数名,如下:
<img src="编辑.png" alt="编辑"/>
选中行后点击"删除"移除函数、点击"清空"清空所有函数,如下:
<img src="删除.png" alt="删除"/>
## 配置文件同步
- 自动读取 uf2touft3/cust.json 配置
- 配置文件外部修改时自动刷新列表
## 转换操作
点击"开始转换"启动转换任务,转换过程中可查看进度条和状态信息,如下:
<img src="转码.png" alt="转码"/>
点击"停止转换"中止当前任务,如下:
<img src="停止转码.png" alt="停止转码"/>

View File

@ -0,0 +1,25 @@
# 元数据更新
更新UF20和UFT3系统的元数据配置。
## 项目配置
需要先配置UFT30项目路径和UF20项目路径。
在设置-首选项页面配置UFT30项目路径例如
``在设置-首选项页面配置UFT30项目路径例如``
<img src="UFT3项目环境路径.png" alt="UFT3项目环境路径"/>
在设置-首选项页面配置UF20项目路径例如
``E:\05.code\04.SVN\secu\dep1\hstrade20\trunk\Sources\DevCodes\经纪业务运营平台V21``
<img src="UF20项目环境路径.png" alt="UF20项目环境路径"/>
## UFT3元数据
在 元数据更新 页面,选择更新范围(标准字段、接口数据等)并点击更新UFT3按钮完成元数据更新。
<img src="UFT3元数据.png" alt="UFT3元数据"/>
**备注:接口数据更新比较久**
## 更新UF20元数据
在 元数据更新 页面,选择更新范围(标准字段、标准组件等)并点击更新UF2按钮完成公共资源更新
<img src="UF20元数据.png" alt="UF20元数据"/>
**备注:接口数据更新比较久**

View File

@ -0,0 +1,6 @@
# 功能查询
## 快速跳转
[UFT3功能查询](http://10.20.163.105:6045/uft3changecode/UFT3功能查询.html)
[UF20功能查询](http://10.20.163.105:6045/uft3changecode/UF20功能查询.html)

View File

@ -0,0 +1,32 @@
# 功能转码
提供UFT3业务转码功能将uf20代码转成UFT3代码
## 项目配置
在使用UFT3功能转码前需要先配置UFT30项目路径并更新UFT3、UF20元数据
1.配置项目路径
- UFT3项目环境路径
在设置-首选项页面配置UFT30项目路径转码使用例如
``E:\05.code\03.GIT\feature_ses``
<img src="UFT3项目环境路径.png" alt="UFT3项目环境路径"/>
- UF20项目环境路径
在设置-首选项页面UF20项目环境路径 转码需要读取相关的文件, 例如:
``E:\05.code\04.SVN\secu\dep1\hstrade20\trunk\Sources\DevCodes\经纪业务运营平台V21``
<img src="UF20项目环境路径.png" alt="UF20项目环境路径"/>
- UF20账户环境路径
在设置-首选项页面配置UF20账户环境路径 转码需要读取账户相关的文件,例如:
``E:\05.code\04.SVN\secu\dep1\hstrade20\trunk\Sources\DevCodes_Acct1\客户账户管理系统V22``
<img src="UF20账户环境路径.png" alt="UF20账户环境路径"/>
- 转码生成路径
在设置-首选项页面,配置转码生成路径, 用于存放生成的转码文件, 例如:
``F:\07.tools\01.hstools\Uft30ChangeCode\bin\uf2touft3\change_code``
<img src="转码生成路径.png" alt="转码生成路径"/>
## 快速跳转
[业务转码](http://10.20.163.105:6045/uft3changecode/业务转码.html)

View File

@ -0,0 +1,3 @@
# 更新记录
Start typing here...

View File

@ -0,0 +1,27 @@
# 设置
## UFT3项目环境路径
在设置-首选项页面配置UFT30项目路径转码使用例如
``E:\05.code\03.GIT\feature_ses``
## UF20项目环境路径 {id="uf20_1"}
在设置-首选项页面UF20项目环境路径 转码需要读取相关的文件, 例如:
``E:\05.code\04.SVN\secu\dep1\hstrade20\trunk\Sources\DevCodes\经纪业务运营平台V21``
## UF20账户环境路径
在设置-首选项页面配置UF20账户环境路径 转码需要读取账户相关的文件,例如:
``E:\05.code\04.SVN\secu\dep1\hstrade20\trunk\Sources\DevCodes_Acct1\客户账户管理系统V22``
## 转码生成路径
在设置-首选项页面,配置转码生成路径, 用于存放生成的转码文件, 例如:
``F:\07.tools\01.hstools\Uft30ChangeCode\bin\uf2touft3\change_code``
## 主题切换
包含日间模式和夜间模式。

5
help/Writerside/v.list Normal file
View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE vars SYSTEM "https://resources.jetbrains.com/writerside/1.0/vars.dtd">
<vars>
<var name="product" value="Writerside"/>
</vars>

View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ihp SYSTEM "https://resources.jetbrains.com/writerside/1.0/ihp.dtd">
<ihp version="2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://resources.jetbrains.com/writerside/1.0/writerside-cfg.xsd">
<topics dir="topics"/>
<images dir="images" web-path="images"/>
<categories src="c.list"/>
<vars src="v.list"/>
<instance src="hi.tree"/>
</ihp>

10
help/nginx/help.conf Normal file
View File

@ -0,0 +1,10 @@
server {
listen 6045;
server_name _;
location /uft3changecode/ {
alias /home/taoc/uft30help/uft3changecode/;
index index.html;
try_files $uri $uri/ /uft3changecode/index.html;
}
}

35
help/nginx/nginx.conf Normal file
View File

@ -0,0 +1,35 @@
worker_processes 1;
pid /home/taoc/nginx/logs/nginx.pid;
events {
worker_connections 1024;
}
http {
include /home/taoc/nginx/conf/mime.types;
default_type application/octet-stream;
access_log /home/taoc/nginx/logs/help_access.log;
error_log /home/taoc/nginx/logs/help_error.log;
sendfile on;
keepalive_timeout 65;
server {
listen 6045;
server_name _;
root /home/taoc/uft30help/html/;
index index.html index.htm;
location /uft3changecode/ {
index index.html index.htm;
try_files $uri $uri/ /uft3changecode/index.html;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}
}

View File

@ -0,0 +1,89 @@
#!/bin/bash
echo "=== Force Restart Help Documentation Server ==="
echo ""
echo "1. Killing all nginx processes..."
pkill -f nginx 2>/dev/null || true
sleep 2
echo "2. Checking for remaining nginx processes..."
if pgrep nginx > /dev/null; then
echo " Force killing remaining nginx processes..."
pkill -9 nginx 2>/dev/null || true
sleep 1
fi
echo "3. Checking port 6045..."
lsof -i :6045 2>/dev/null || echo " Port 6045 is free"
echo ""
echo "4. Starting fresh nginx instance..."
NGINX_BIN="/home/taoc/nginx/sbin/nginx"
HELP_DOCS_DIR="/home/taoc/uft30help/"
CONF_FILE="$HELP_DOCS_DIR/workspace/nginx.conf"
if [ ! -f "$CONF_FILE" ]; then
echo " Copying nginx configuration..."
cp "$(dirname "$0")/nginx.conf" "$CONF_FILE"
fi
if [ ! -f "$HELP_DOCS_DIR/workspace/help.conf" ]; then
echo " Copying server configuration..."
cp "$(dirname "$0")/help.conf" "$HELP_DOCS_DIR/workspace/help.conf"
fi
if [ ! -f "$HELP_DOCS_DIR/uft3changecode/index.html" ]; then
echo " Creating default index.html..."
cat > "$HELP_DOCS_DIR/uft3changecode/index.html" << 'EOF'
<!DOCTYPE html>
<html>
<head>
<title>UFT30ChangeCode Help</title>
<style>
body { font-family: Arial, sans-serif; text-align: center; padding: 50px; background: #f5f5f5; }
.container { background: white; padding: 40px; border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,0.1); display: inline-block; }
.logo { font-size: 64px; margin-bottom: 20px; }
h1 { color: #667eea; margin: 0; }
.subtitle { color: #666; margin-top: 10px; }
.path { background: #f0f0f0; padding: 10px 20px; border-radius: 5px; margin-top: 20px; font-family: monospace; }
</style>
</head>
<body>
<div class="container">
<div class="logo">📖</div>
<h1>UFT30ChangeCode Help</h1>
<p class="subtitle">Help Documentation Server</p>
<div class="path">Path: /uft3changecode/</div>
</div>
</body>
</html>
EOF
fi
echo "5. Testing configuration..."
"$NGINX_BIN" -t -c "$CONF_FILE"
echo "6. Starting nginx..."
"$NGINX_BIN" -c "$CONF_FILE"
sleep 2
echo ""
echo "=== Server Status ==="
if pgrep nginx > /dev/null; then
SERVER_IP=$(ip addr show | grep inet | grep -v '127.0.0.1' | grep -v '::1' | head -1 | awk '{print $2}' | cut -d'/' -f1)
echo "✅ Server started successfully!"
echo ""
echo "Access URLs:"
echo " Local: http://localhost:6045/uft3changecode/"
if [ -n "$SERVER_IP" ]; then
echo " Remote: http://$SERVER_IP:6045/uft3changecode/"
fi
echo ""
echo "Verify with:"
echo " curl http://localhost:6045/uft3changecode/"
else
echo "❌ Failed to start server"
echo "Check error log: /home/taoc/uft30help/workspace/logs/help_error.log"
fi

56
help/nginx/start.sh Normal file
View File

@ -0,0 +1,56 @@
#!/bin/bash
NGINX_BIN="/home/taoc/nginx/sbin/nginx"
CONF_DIR="/home/taoc/uft30help/workspace"
HTML_DIR="/home/taoc/uft30help/html/uft3changecode"
CONF_FILE="$CONF_DIR/nginx.conf"
echo "=== Starting Help Documentation Server (Port 6045) ==="
echo ""
echo "1. Checking directories..."
if [ ! -d "$CONF_DIR" ]; then
mkdir -p "$CONF_DIR"
echo " Created config dir: $CONF_DIR"
else
echo " Config dir exists: $CONF_DIR"
fi
if [ ! -d "$HTML_DIR" ]; then
mkdir -p "$HTML_DIR"
echo " Created HTML dir: $HTML_DIR"
else
echo " HTML dir exists: $HTML_DIR"
fi
echo ""
echo "2. Killing all nginx processes..."
pkill -f nginx 2>/dev/null || true
sleep 2
pkill -9 nginx 2>/dev/null || true
sleep 1
echo " Done"
echo ""
echo "3. Starting nginx..."
"$NGINX_BIN" -c "$CONF_FILE"
sleep 2
echo ""
echo "4. Testing..."
echo ""
echo "=== Server Status ==="
if pgrep nginx > /dev/null; then
SERVER_IP=$(ip addr show | grep inet | grep -v '127.0.0.1' | grep -v '::1' | head -1 | awk '{print $2}' | cut -d'/' -f1)
echo "✅ Server running!"
echo ""
echo "=== Access URLs ==="
echo " Local: http://localhost:6045/uft3changecode/"
if [ -n "$SERVER_IP" ]; then
echo " Remote: http://$SERVER_IP:6045/uft3changecode/"
fi
else
echo "❌ Server not running"
echo "Error log:"
tail -20 /home/taoc/uft30help/workspace/logs/help_error.log
fi

10
help/nginx/status.sh Normal file
View File

@ -0,0 +1,10 @@
#!/bin/bash
echo "Checking Help Documentation Server status..."
if pgrep nginx &> /dev/null; then
echo "✅ Help Documentation Server is running"
echo "📄 Access URL: http://localhost:8080"
else
echo "❌ Help Documentation Server is not running"
fi

19
help/nginx/stop.sh Normal file
View File

@ -0,0 +1,19 @@
#!/bin/bash
NGINX_DIR="/home/taoc/nginx"
NGINX_BIN="$NGINX_DIR/sbin/nginx"
echo "Stopping Help Documentation Server..."
if [ ! -f "$NGINX_BIN" ]; then
echo "Error: nginx binary not found at $NGINX_BIN"
exit 1
fi
"$NGINX_BIN" -s stop
if [ $? -eq 0 ]; then
echo "✅ Help Documentation Server stopped successfully"
else
echo "❌ Failed to stop nginx"
exit 1
fi