Commit Graph

109 Commits

Author SHA1 Message Date
2586634c22 Update .gitignore 2026-06-12 01:11:39 +02:00
44e77e7744 done last commit before merging - fixed media URLSs S3 2026-06-12 00:56:01 +02:00
David Bruno Vontor
f4c4a8bfd1 Sanitize envs, optimize Dockerfile, Turnstile
Redact sensitive AWS keys in backend/.env.example and add VITE_TURNSTILE_SITE_KEY and VITE_USE_TURNSTILE to frontend/.env.example. Optimize backend Dockerfile by installing Python requirements immediately after copying requirements.txt (enables Docker cache) and remove the duplicate later install. Update turnstile verification to skip checks when USE_SSL is disabled (dev/non-HTTPS) and keep the existing no-secret bypass; add debug logging for the SSL bypass.
2026-06-11 14:04:23 +02:00
David Bruno Vontor
5ca62497b1 turnstile is working - keep SSL turned of on dev 2026-06-11 11:37:31 +02:00
192143bfb6 wokring final build version 2026-06-10 23:59:40 +02:00
270d850572 Add S3/MinIO (RustFS) support and compose updates
Introduce S3-compatible storage support and update local/dev configuration.

- .claude: add "WebSearch" to local settings
- backend/.env.example: add USE_S3 flag and detailed S3/MinIO (RustFS) example env vars + comments to explain dev vs production usage
- backend/vontor_cz/settings.py: refactor to use USE_S3 boolean; set STATIC_ROOT; configure STORAGES for local filesystem vs S3 backends; add handling for S3 endpoint (MinIO/RustFS) vs real AWS S3 including path-style addressing, URL construction, and sensible AWS defaults
- docker-compose.yml: add rustfs to service dependencies, include rustfs in networks, change frontend port mapping to 8001:80, and add rustfs-data volume binding

These changes enable using a local S3-compatible backend (RustFS/MinIO) in development while keeping the option to swap to real AWS S3 for production.
2026-06-10 01:29:30 +02:00
David Bruno Vontor
2592a69790 Introduce notifications app and integrate emails
Add a new notifications app (models, serializers, views, admin, tasks, consumers, routing, urls, tests) with Notification.notify for in-app websocket pushes and optional email delivery. Centralize email sending in notifications.tasks.send_email_with_context and re-export it from account.tasks for compatibility. Update account and commerce and advertisement tasks to use Notification.notify/_notify_order and the new email helper; adjust order/notification tasks to consolidate logic. Wire notifications into ASGI routing, settings and URL conf. Misc: handle OSError when importing weasyprint, add tmp/ to .gitignore, add local .claude PowerShell checks, add social.blog skeleton, and remove legacy ews-component test files.
2026-06-09 16:18:41 +02:00
46bc131a56 Revamp footer, navbar, drone section and routes
- Replace heavy drone assets with S3-hosted video (excluded from git via .gitignore).
- Add routes for /services/web and /services/film in App.tsx.
- Rewrite Footer with framer-motion, structured social/contact/service arrays and improved responsive layout.
- Redesign DroneSection: full-bleed background video, layered panels/vignette, updated copy and styling.
- Minor content change in HeroSection (name updated to "David Bruno Vontor").
- Major Navbar refactor: improved mobile drawer with backdrop, accordion submenus, better state handling and accessibility.
- ChatSidebar: add optional onClose/onSelectChat callbacks, close button.
- ContactMe mobile CSS: tweak sizing and margins for small screens.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-09 00:43:38 +02:00
David Bruno Vontor
492e42bfdb Merge branch 'bruno' of https://git.vontor.cz/Brunobrno/vontor-cz into bruno 2026-06-08 06:44:50 +02:00
ad7f0fbe55 Enhance contact UI and email handling
Add an email template and improve contact flow: create backend/templates/email/contact_me.html and update backend/advertisement/tasks.py to use SiteConfiguration.contact_email with a fallback to brunovontor@gmail.com when sending contact form emails. Revamp frontend contact experience: ContactMeForm is now open by default, uses controlled email/message inputs, shows loading/success/error states and posts to /api/advertisement/contact-me/ via publicApi. Update ContactPage and Home to include richer contact sections (framer-motion animations, icons, social links and responsive layouts). Also add a PowerShell helper entry to .claude/settings.local.json.
2026-06-07 23:17:10 +02:00
3766b033bc Polish hero, projects, modal, and tech marquee
UI polish and refactor across home components: HeroSection now uses a fixed particle seed and staggered motion variants to avoid hydration/layout shifts, updates background/video/gradient overlays, refines typewriter timing and CTA styles, and improves accessibility/visuals. DemoModal is portalled to document.body, z-index/backdrop/animation timing adjusted, and body-scroll/escape handling preserved. ProjectsSection adds a new "Client Websites" grid with two project cards (davo1.cz, Epinger) including badges, previews and visit links. TechMarquee was refactored to a seamless repeating track (four copies) with a CSS marquee animation, hover-to-pause and item hover effects; also minor theme/color tweaks and general style improvements.
2026-06-07 22:08:59 +02:00
ad1f6a90b6 Use hub 'name' in routes & add top-post sorting
Switch hub endpoints to use the hub `name` slug and update frontend routes/clients accordingly. Backend: HubViewSet now uses lookup_field='name'; PostViewSet list supports `sort=top` with vote_score annotation and time windows/custom ranges, and a new TopPostsCursorPagination was added. Frontend: routes changed from `/hub/:id` to `/h/:name`, the generated hubs API was updated from id->name, and the hub feed client accepts `sort`, `time`, `start`, and `end` params (query key updated). Also adds new homepage UI components (HeroSection, DroneSection) and navbar improvements (scroll state, auto-close mobile menu on route changes, and small icon/class tweaks).
2026-06-07 12:19:40 +02:00
cb23abeb5f Improve chat replies, hubs API & UI
Backend: enrich message reply data (include created_at and media_files) and ensure chat owners are treated as members; tighten/extend permission checks and message query filters; fix hub routers so moderators/tags routes are resolved before hub detail; accept hub id from request.data in hub permission/tag views; add PostHub serializer and expose hub_detail on posts.

Frontend: update generated API models (postHub, replyTo, members_detail, hub_detail); add hub-related pages/routes and components (HubCard, HubHeader, Tags) and a hub posts feed hook; rework message UI and composer to show richer reply previews (media thumbnails, timestamps), adjust video preload to metadata; add tag selection UI to PostComposer and wire hub tags fetching.

Also: minor UI/UX improvements and generated model exports updated to match backend changes.
2026-06-07 00:24:21 +02:00
6422fefe46 Sync DM chat name/icon on user changes
Add a signal to keep direct-message chat name and icon in sync when a user updates their username or avatar, and register it in AppConfig.ready. Also initialize a DM chat's name/icon on creation from the other member's username/avatar if those fields are missing, saving only the changed fields.
2026-06-05 23:49:48 +02:00
David Bruno Vontor
fbaf914c8b Improve user search, DB nulls, and chat UI
Change username filter to use icontains for partial/case-insensitive matching. In CustomUser.save, introduce _NULLABLE_CHAR_FIELDS and convert empty string char fields to None to ensure nullable fields are stored consistently. Update CreateChatModal to always show a subtitle combining the user's full name and account creation date (joined with " · "), improving UI information.
2026-06-05 16:48:53 +02:00
c0af4c2349 Add reaction popover, socket guards, dedupe reactions
Build a members lookup and enrich reaction groups with reactor info; introduce a ReactionPill component that shows a tabbed popover listing who reacted (with ability to remove your own reaction). Move reaction button into the new component and adapt styling/UX.

Fix WebSocket handling in useChatSocket by adding a mounted guard to avoid handling events from torn-down sockets (addresses React StrictMode double-invoke issues) and avoid setting state after unmount.

Prevent duplicate local reaction entries in ChatRoomPage by skipping "added" events when the same user/emoji reaction already exists.
2026-06-04 23:44:26 +02:00
David Bruno Vontor
b1f88ca501 Restore reactions, add constraint, handle errors
Restore soft-deleted message reactions and enforce uniqueness only for active reactions; add WebSocket error handling and minor UI/Docker tweaks.

- backend/social/chat/models.py: Toggle reaction now restores a stale soft-deleted MessageReaction (avoids unique conflicts) and creates new reactions as needed. Replaced unique_together with a conditional UniqueConstraint that applies only to non-deleted records.
- backend/social/chat/consumers.py: Wrap reaction toggle in try/except to return a WS error message on failure instead of allowing exceptions to bubble up.
- frontend/src/components/social/chat/Message.tsx: Adjusted Tailwind max-width class for the reaction menu (max-w-32).
- docker-compose.yml: Added commented example configuration for an optional Janus media server (documentational/commented service).

These changes prevent unique constraint errors when restoring reactions, improve robustness of the WebSocket reaction flow, and include small UI and deployment notes.
2026-06-04 16:45:16 +02:00
3859659b13 Add emoji picker, reactions user_id & UI tweaks
Introduce client-side emoji picker and richer reaction UX, and propagate user IDs for reactions over the WS protocol. Backend: include user_id in reaction events. Frontend: add EmojiPicker component; update useChatSocket types to include user_id; handle "reaction" events in ChatRoomPage to update cached messages (add/remove/switch reactions). Message component: UI overhaul — action menu with slide-out actions, toggle button (⋮→✕), emoji picker trigger, grouped reaction buttons that show counts and indicate "mine" state, and various layout/cleanups. Media: defer video loading by setting preload="none" in ChatMediaGallery, MediaGallery and PostComposer to improve performance.
2026-06-04 00:14:34 +02:00
David Bruno Vontor
bb09f0ccd3 updated chat andlayout 2026-06-03 17:07:34 +02:00
3d1965e5e6 Add chat settings modal & reply previews
Introduce a full ChatSettingsModal component for managing group chats (rename/icon upload, add/remove members, toggle moderators, leave/delete) and wire it into ChatRoomPage with a settings button. Add reply preview support end-to-end: new ReplyToSerializer and members_detail in backend serializers, updated frontend Message model (reply_to now contains preview object), and UI changes to Message to render reply excerpts. Improve socket handling to attach reply previews when available. Tweak backend Dockerfile to optionally install Windows/corporate CA bundle only if present and move pip install after copying source. Add Czech translations and small tooling/.claude config enhancements.
2026-05-29 00:41:43 +02:00
David Bruno Vontor
8269d044a2 chat ws with pfp is working 2026-05-28 17:23:04 +02:00
f19375254f Create chat modal UI & session login for WS auth
Backend: initialize a Django session on token obtain (login) so AuthMiddlewareStack can authenticate WebSocket connections; validate the token serializer and map TokenError -> InvalidToken; call django_logout on logout to destroy the session. Frontend: add a CreateChatModal component (DM/group creation) with user search, selection, validation, API mutation and cache invalidation; wire modal into ChatSidebar and add Czech translations for the new UI strings.
2026-05-28 08:40:55 +02:00
d52af2c495 chat implemented, testing needed 2026-05-20 00:52:56 +02:00
David Bruno Vontor
c7de2dbcdc fixed expiring login creds 2026-05-19 16:52:55 +02:00
David Bruno Vontor
6cec6fbb94 Create .env.example 2026-05-19 15:52:00 +02:00
2e9e3ed41b posts are done 2026-05-19 00:08:02 +02:00
202ce22102 added frontend for social + feed partiali working 2026-05-18 02:25:47 +02:00
e1df55df0e Add subtitle metadata and improve downloader UI
Expose subtitle information in the API and update the frontend to use it: backend adds subtitle_languages and has_subtitles to the downloader serializer/response (computed from subtitles and automatic_captions). Generated TypeScript models (public & private) now include these fields. Downloader UI: gather available subtitle languages, show a select when languages exist, provide contextual input/placeholder when only auto-captions exist, and disable/annotate embed controls when subtitles or thumbnails are unavailable. These changes enable subtitle selection/embedding and surface thumbnail availability to users.
2026-05-11 00:53:24 +02:00
f8150eeda7 idk 2026-04-23 00:42:08 +02:00
1153abe6de kokot 2026-04-23 00:36:57 +02:00
9b4471f61d Fix FFmpegVideoRemuxer typo and add launch.json dev server configs
- Fix 'preferedformat' → 'preferredformat' typo in consumers.py causing intermittent postprocessing failures when selecting custom formats
- Add .claude/launch.json with Frontend (Vite), Docker Full Stack, and Docker Backend+DB+Redis configurations

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-23 00:22:16 +02:00
b3bc242e27 Update Downloader.tsx 2026-04-21 00:49:54 +02:00
cf08dbaf15 fixes, orval, downloader functioning again 2026-04-21 00:47:10 +02:00
659999f4fd gukgjzkgjhgjh 2026-04-20 00:04:15 +02:00
5280a87e8b updated to selfdelete inheritance 2026-04-19 01:36:03 +02:00
043e866ac9 adding features for social network 2026-04-18 13:31:20 +02:00
1bc57a99ce ubbhjbj 2026-04-05 02:16:09 +02:00
d678560d60 kkt 2026-04-04 00:32:01 +02:00
f9636d1464 Add custom exception handler and improve order logic
Introduced a custom DRF exception handler to convert Django ValidationError to DRF ValidationError and registered it in settings. Improved Order model's calculate_total_price method to avoid accessing related fields before the object is saved. Updated OrderCreateSerializer to save the order after adding discounts and payment, ensuring total price is recalculated. Added utility functions and a rounded DateTime field in a new utils.py.
2026-02-01 03:17:49 +01:00
3e4d58f80d Update URLs, Docker config, and Tailwind setup
Added static and media file serving and Silk profiling in Django URLs. Updated docker-compose to mount backend/frontend code, adjust commands, and switch to 'trznice' app references. Enhanced Tailwind config to extend default colors and import defaultTheme.
2026-01-29 01:31:33 +01:00
David Bruno Vontor
304194d7ec Update generate-choice-labels.cjs 2026-01-26 09:54:56 +01:00
7c768c9be3 Update CSP, dependencies, and add choice label generator
Replaces nginx.conf CSP map with inline policy and updates the policy for development. Adds new dependencies including Mantine, Radix, Tabler, FontAwesome, and others. Removes the fetch-openapi.js script and introduces generate-choice-labels.cjs to auto-generate TypeScript choice label constants from Orval enums, updating the api:gen script to run this generator. Also updates orval and other dev dependencies, and makes minor formatting changes in orval.config.ts.
2026-01-26 00:10:47 +01:00
ed1b7de7a7 Update views.py 2026-01-25 23:19:56 +01:00
ca62e8895a Add order status email notifications and templates
Introduces email notifications for order status changes (created, cancelled, completed, paid, missing payment, refund events) and adds corresponding HTML email templates. Refactors notification tasks to use only the order object and updates model logic to trigger notifications on relevant status changes.
2026-01-25 22:21:00 +01:00
679cff2366 Consolidate and update initial migrations and models
Regenerated initial migrations for account, advertisement, commerce, configuration, and social apps to include recent schema changes and remove obsolete migration files. Added new migrations for Deutsche Post and Zasilkovna integrations, including new fields and choices. Updated commerce models to improve currency handling and discount code logic. This unifies the database schema and prepares for new features and integrations.
2026-01-25 00:40:52 +01:00
775709bd08 Migrate to global currency system in commerce app
Removed per-product currency in favor of a global site currency managed via SiteConfiguration. Updated models, views, templates, and Stripe integration to use the global currency. Added migration, management command for migration, and API endpoint for currency info. Improved permissions and filtering for orders, reviews, and carts. Expanded supported currencies in configuration.
2026-01-24 21:51:56 +01:00
8f6d864b4b Merge branch 'bruno' of https://git.vontor.cz/Brunobrno/vontor-cz into bruno 2026-01-23 00:47:22 +01:00
3a7044d551 Enhance Deutsche Post integration with API and label support
Expanded DeutschePostOrder and DeutschePostBulkOrder models to support full Deutsche Post API integration, including authentication, order creation, finalization, tracking, cancellation, and label/document generation. Added new fields for label PDFs and bulk paperwork, improved country mapping, and implemented comprehensive validation and utility methods. Updated serializers to expose new fields and computed properties. Added HTML templates for individual and bulk shipping labels.
2026-01-23 00:47:19 +01:00
27b346c1f6 Update models.py 2026-01-22 16:55:45 +01:00
963ba6b824 Add weekly new products email and related features
Introduces a weekly summary email for newly added products, including a new email template and Celery periodic task. Adds 'include_in_week_summary_email' to Product and 'newsletter' to CustomUser. Provides an admin endpoint to manually trigger the weekly email, updates Celery Beat schedule, and adds email templates for verification and password reset.
2026-01-22 00:22:21 +01:00