fofstudio-aimcpztdata 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/MCPMain.js +2577 -0
- package/build/modules/BufferClass.js +6 -0
- package/build/modules/DataPackaging.js +57 -0
- package/build/modules/DecoderAPI.js +30 -0
- package/build/modules/DialogAPI.js +48 -0
- package/build/modules/EXEAPI.js +64 -0
- package/build/modules/FOFTcp.js +309 -0
- package/build/modules/FOFUDP.js +78 -0
- package/build/modules/File.js +525 -0
- package/build/modules/IP.js +54 -0
- package/build/modules/NoSqlFOFStudio.js +63 -0
- package/build/modules/PlatAPI.js +115 -0
- package/build/modules/ProcessAPI.js +36 -0
- package/build/modules/ReadAPI.js +67 -0
- package/build/modules/SendHttp.js +484 -0
- package/build/modules/dns.js +36 -0
- package/build/modules/mysql.js +0 -0
- package/build/modules/sqlServer.js +0 -0
- package/build/modules/trayApi.js +34 -0
- package/package.json +37 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
const dns = require("dns")
|
|
2
|
+
exports.lookup = (url, funStr) => {
|
|
3
|
+
dns.lookup(url, (err, address, family) => {
|
|
4
|
+
if (funStr != undefined) {
|
|
5
|
+
funStr({ "地址": address, "IPV": family, "错误": err })
|
|
6
|
+
}
|
|
7
|
+
});
|
|
8
|
+
}
|
|
9
|
+
exports.lookupService = (address, family, funStr) => {
|
|
10
|
+
dns.lookupService(address, family, (err, address, family) => {
|
|
11
|
+
if (funStr != undefined) {
|
|
12
|
+
funStr({ "域名": address, "IPV": family, "错误": err })
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
exports.resolve4 = (url, funStr) => {
|
|
17
|
+
dns.resolve4(url, (err, address) => {
|
|
18
|
+
if (funStr != undefined) {
|
|
19
|
+
funStr({ "地址": address, "错误": err })
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
exports.resolve6 = (url, funStr) => {
|
|
24
|
+
dns.resolve6(url, (err, address) => {
|
|
25
|
+
if (funStr != undefined) {
|
|
26
|
+
funStr({ "地址": address, "错误": err })
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
exports.reverse = (ip, funStr) => {
|
|
31
|
+
dns.reverse(ip, (err, url) => {
|
|
32
|
+
if (funStr != undefined) {
|
|
33
|
+
funStr({ "域名": url, "错误": err })
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
}
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
const {Menu, Tray } = require('electron');
|
|
2
|
+
const path = require('path');
|
|
3
|
+
var tray = null;//系统托盘
|
|
4
|
+
exports.tray = (data,funEv1,funEv2,mainWindow) => {
|
|
5
|
+
try {
|
|
6
|
+
tray = new Tray(data["图片地址"])
|
|
7
|
+
let MenuData = [];
|
|
8
|
+
for (let index = 0; index < data["菜单数据"].length; index++) {
|
|
9
|
+
MenuData[MenuData.length] = {
|
|
10
|
+
"label": data["菜单数据"][index],
|
|
11
|
+
click: () => {
|
|
12
|
+
if(funEv1!=""){
|
|
13
|
+
mainWindow.webContents.executeJavaScript(funEv1+"('" + data["菜单数据"][index] + "')")
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
const contextMenu = Menu.buildFromTemplate(MenuData)
|
|
19
|
+
tray.setToolTip(data["托盘提示"])
|
|
20
|
+
tray.setContextMenu(contextMenu)
|
|
21
|
+
tray.on("click", (event) => {
|
|
22
|
+
if(funEv2!=undefined){
|
|
23
|
+
mainWindow.webContents.executeJavaScript(funEv2+"()")
|
|
24
|
+
}
|
|
25
|
+
})
|
|
26
|
+
} catch (err) {
|
|
27
|
+
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.destroyTray = () => {
|
|
31
|
+
if (tray != null) {
|
|
32
|
+
tray.destroy()
|
|
33
|
+
}
|
|
34
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "fofstudio-aimcpztdata",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "fofstudio",
|
|
5
|
+
"type": "commonjs",
|
|
6
|
+
"bin": {
|
|
7
|
+
"fofstudio-aimcpztdata": "build/MCPMain.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"build"
|
|
11
|
+
],
|
|
12
|
+
"scripts": {},
|
|
13
|
+
"keywords": [
|
|
14
|
+
"mcp",
|
|
15
|
+
"weather",
|
|
16
|
+
"ai",
|
|
17
|
+
"claude",
|
|
18
|
+
"cline",
|
|
19
|
+
"meizu"
|
|
20
|
+
],
|
|
21
|
+
"author": "XX工作室",
|
|
22
|
+
"license": "MIT",
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"@modelcontextprotocol/sdk": "^1.7.0",
|
|
25
|
+
"zod": "^3.22.4",
|
|
26
|
+
"dotenv": "^16.4.7",
|
|
27
|
+
"mysql2": "^3.11.5",
|
|
28
|
+
"iconv-lite": "^0.6.3",
|
|
29
|
+
"uuid": "^9.0.1",
|
|
30
|
+
"node-fetch": "^3.3.2",
|
|
31
|
+
"string-similarity": "^4.0.4",
|
|
32
|
+
"sql.js": "^1.13.0"
|
|
33
|
+
},
|
|
34
|
+
"devDependencies": {
|
|
35
|
+
"nodemon": "^3.0.3"
|
|
36
|
+
}
|
|
37
|
+
}
|