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

@@ -1,4 +1,5 @@
import { useState } from "react";
import { useState, useEffect } from "react";
import { useRouter } from "next/router";
import {
Pane,
TextInputField,
@@ -7,13 +8,44 @@ import {
BuildIcon,
toaster,
Alert,
RadioGroup,
} from "evergreen-ui";
import axios from "axios";
import Footer from "./footer";
export default function Generator() {
const [profil, setProfil] = useState();
const [args, setArgs] = useState({ scale: 200 });
const [args, setArgs] = useState({
scale: 200,
elementOne: 0,
elementTwo: 0,
});
const [ElementOneOptions] = useState([
{ label: "Nic", value: "0" },
{ label: "Słup", value: "1" },
{ label: "Dom", value: "2" },
]);
const [ElementTwoOptions] = useState([
{ label: "Nic", value: "0" },
{ label: "Słup", value: "1" },
{ label: "Dom", value: "2" },
]);
const { query } = useRouter();
useEffect(() => {
if (query.external == "tru") {
axios
.post("/api/readtext", {
id: query.id,
})
.then(function (response) {
setProfil(response.data.data);
document.getElementById("textarea-1").value = response.data.data;
console.log(response.data.data);
});
}
}, []);
const getPath = (e, path) => {
let newLines = [];
@@ -148,6 +180,22 @@ export default function Generator() {
setArgs({ ...args, scale: e.target.value });
}}
/>
<RadioGroup
label="Lewa"
value={args.elementOne}
options={ElementOneOptions}
onChange={(event) => {
setArgs({ ...args, elementOne: event.target.value });
}}
/>
<RadioGroup
label="Prawa"
value={args.elementTwo}
options={ElementTwoOptions}
onChange={(event) => {
setArgs({ ...args, elementTwo: event.target.value });
}}
/>
<Button
marginY={8}
marginRight={12}

View File

@@ -1,7 +1,13 @@
import Link from "next/link";
import { useRouter } from 'next/router';
import { Pane, Heading } from "evergreen-ui";
export default function Nav() {
const router = useRouter();
const isActive = (href) => {
return router.pathname === href ? `active font-bold bg-slate-200 rounded-md` : '';
};
return (
<Pane display="flex">
<Link href="/">
@@ -9,12 +15,18 @@ export default function Nav() {
<img src="logo.png" className="h-12" />
</h2>
</Link>
<Link href="/pdf">
<h3 className="px-3 py-2 place-self-end">PDF</h3>
<Link href="/">
<h3 className={"px-3 py-2 place-self-end "+isActive('/')} style={{cursor: 'pointer'}}>Przekrój</h3>
</Link>
{/*<Link href="/kontakt">
<Link href="/cross">
<h3 className={"px-3 py-2 place-self-end "+isActive('/cross')} style={{cursor: 'pointer'}}>Siatka</h3>
</Link>
<Link href="/uziomy">
<h3 className={"px-3 py-2 place-self-end "+isActive('/uziomy')} style={{cursor: 'pointer'}}>Uziomy</h3>
</Link>
{/* <Link href="/kontakt">
<h3 className="px-3 py-2 place-self-end">Kontakt</h3>
</Link>*/}
</Link> */}
</Pane>
);
}