Files
company-tool/README.md
Torsten Schulz (local) 0e539710c0 feat: Add password reset functionality with request and reset forms
feat: Implement price list import feature with preview and apply options

feat: Create price rules management page with CRUD operations

feat: Develop quotes management page with itemized quotes and status tracking

feat: Introduce organization registration page for new users

feat: Build suppliers management page with detailed supplier information

feat: Create users management page for inviting and managing roles

chore: Add TypeScript configuration for improved type checking

chore: Set up Vite configuration for development server and API proxy

chore: Add Vite environment type definitions for better TypeScript support
2026-06-02 15:28:38 +02:00

77 lines
1.8 KiB
Markdown

# Company Tool
Mehrprojekt-Struktur für eine firmeninterne Software mit Rust-Backend, PostgreSQL,
Webfrontend und klassischem Desktopclient.
## Projekte
- `backend/`: Rust-Backend mit PostgreSQL-Anbindung und WebSocket-Kommunikation
- `web-frontend/`: Browserbasiertes Frontend mit Vue 3, Vite und TypeScript
- `desktop-client/`: Nativer Client für Linux, Windows und macOS mit egui/eframe
- `shared-protocol/`: Gemeinsame Rust-Typen für Socket-Nachrichten
## Kommunikation
Das Backend stellt einen WebSocket unter `ws://localhost:8080/ws` bereit. Die
Verbindung beginnt mit einem `hello`-Handshake. Danach werden fachliche
Nachrichten als AES-256-GCM-verschlüsselte Envelopes übertragen.
## PostgreSQL starten
Ausführliche Installationsschritte stehen in [INSTALL.md](INSTALL.md).
Betriebsnotizen zu Schlüsseln, E-Mail, Backup und TLS stehen in
[BETRIEB.md](BETRIEB.md).
```bash
cp .env.example .env
docker compose up -d postgres
```
## Backend starten
```bash
cargo run -p companytool-backend
```
## Kommunikation testen
In einem Terminal Backend starten, dann in einem zweiten Terminal:
```bash
COMMUNICATION_TEST_MODE=1 cargo run -p companytool-backend
```
```bash
node scripts/communication-test.mjs
```
Optional gegen eine andere URL:
```bash
node scripts/communication-test.mjs ws://localhost:8080/ws
```
Der Test öffnet zwei Clients, führt den verschlüsselten Handshake aus,
entschlüsselt Snapshots, sendet eine verschlüsselte Ping-Nachricht und prüft, ob
beide Clients ein verschlüsseltes Pong-Event erhalten.
## Webfrontend starten
```bash
cd web-frontend
npm install
npm run dev
```
## Desktopclient starten
```bash
cargo run -p companytool-desktop-client
```
Mit explizitem Backend:
```bash
cargo run -p companytool-desktop-client -- --api-url http://127.0.0.1:8080 --ws-url ws://127.0.0.1:8080/ws
```