Add uziom generation script and update wet input documents

- Created a new Python script `uziom.py` for generating DXF drawings of grounding systems based on user input parameters.
- Added detailed documentation in `wet_input_15.docx` and `wet_input_3.docx` for the design of grounding systems, including calculations for resistance and resistivity measurements.
- Included placeholders for dynamic data insertion in the documents to facilitate project-specific customization.
This commit is contained in:
2025-07-01 11:14:49 +02:00
parent e0d822adc8
commit 5c11a289df
21 changed files with 4557 additions and 6504 deletions

View File

@@ -4,7 +4,7 @@ export default function (req, res) {
//console.log(req.body);
//file
let textData = req.body.profil;
let replacedData = textData.replace("<EFBFBD>", "o").replace("<EFBFBD>", "e");
let replacedData = textData.replace(" ", "o").replace(" ", "e");
console.log(replacedData);
var fs = require("fs");
@@ -14,10 +14,32 @@ export default function (req, res) {
}
});
// log stats
let ip = req.body.ip;
if (ip === undefined)
ip = req.headers["x-forwarded-for"] + " on " + req.headers["user-agent"];
let date_time = new Date();
let string =
fs.readFileSync("profile_log.txt", "utf8") +
"\n" +
"[" +
date_time +
"]" +
ip +
" : " +
replacedData
fs.writeFile("profile_log.txt", string, function (err) {
if (err) {
return console.error(err);
}
});
//py
let fileName = Math.floor(Math.random() * 9999) + 1000;
const python = spawn("python3", ["a.py", req.body.arguments.scale, fileName]);
const python = spawn("python3", ["a.py", req.body.arguments.scale, req.body.arguments.elementOne, req.body.arguments.elementTwo]);
let dataToSend;
python.stdout.on("data", function (data) {