Commit Graph

148 Commits

Author SHA1 Message Date
af6353fa40 refactor: enhance password change page with improved UI and functionality
- Updated the layout and styling of the password change page for a more modern and user-friendly experience.
- Integrated new icons and visual elements to enhance the overall design and accessibility.
- Improved form handling with better loading states and error messages for user feedback.
- Added security tips and password requirements to guide users during the password change process.
2025-11-18 07:09:40 -03:00
422dc6f022 refactor: enhance ProtectedRoute and dashboard components for improved access control and user experience
- Updated the ProtectedRoute component to optimize access checking logic, preventing unnecessary re-checks and improving authentication flow.
- Enhanced the dashboard page to automatically open the login modal for authentication errors and refined loading states for better user feedback.
- Improved UI elements across various components for consistency and visual appeal, including updated tab styles and enhanced alert messages.
- Removed redundant footer from the vacation management page to streamline the interface.
2025-11-18 06:34:55 -03:00
71550874ce feat: update system branding and improve user interface consistency
- Changed all instances of "Sistema de Gerenciamento da Secretaria de Esportes" to "Sistema de Gerenciamento de Secretaria" for a more concise branding.
- Enhanced the PrintModal component with a user-friendly interface for selecting sections to include in PDF generation.
- Improved error handling and user feedback during PDF generation processes.
- Updated various components and routes to reflect the new branding, ensuring consistency across the application.
2025-11-18 03:10:10 -03:00
0e5a26b5fd feat: add 'Cancelado_RH' status to vacation management
- Introduced a new status 'Cancelado_RH' for vacation requests, allowing for better tracking of cancellations by HR.
- Updated the UI components to reflect the new status, including badge colors and alert messages.
- Enhanced backend schema and mutation to support the new status, ensuring consistency across the application.
- Improved logging and state management for better performance and user experience.
2025-11-17 19:07:03 -03:00
f021e96eb4 feat: enhance cybersecurity features and add ticket management components
- Introduced new components for managing tickets, including TicketForm, TicketCard, and TicketTimeline, to streamline the ticketing process.
- Added a new SlaChart component for visualizing SLA data.
- Implemented a CybersecurityWizcard component for enhanced security monitoring and reporting.
- Updated routing to replace the "Solicitar Acesso" page with "Abrir Chamado" for improved user navigation.
- Integrated rate limiting functionality to enhance security measures.
- Added a comprehensive test report for the cybersecurity system, detailing various attack simulations and their outcomes.
- Included new scripts for security testing and environment setup to facilitate automated security assessments.
2025-11-17 16:54:43 -03:00
2c3d231d20 refactor: enhance authentication and access control in ProtectedRoute component
- Updated the ProtectedRoute component to improve access control logic, including a timeout mechanism for handling authentication checks.
- Refactored the checkAccess function to streamline user access verification based on roles and authentication status.
- Added comments for clarity on the authentication flow and the use of the convexClient plugin in the auth.ts file.
- Improved the overall structure and readability of the code in auth.ts and ProtectedRoute.svelte.
2025-11-17 16:27:15 -03:00
2b94b56f6e feat: add empresa and contatos
- Introduced a new utility function `maskCNPJ` for formatting CNPJ values.
- Updated the dashboard pages to replace icons and improve layout, including the addition of a link to manage companies.
- Enhanced the display of upcoming features for both the Licitações and Programas Esportivos modules, indicating their development status.
2025-11-17 15:45:48 -03:00
8a613128a5 Merge branch 'master' into feat-cibersecurity 2025-11-17 11:49:18 -03:00
3d9e8ae1f8 Merge remote-tracking branch 'origin/master' into bug-perfil 2025-11-17 11:41:41 -03:00
05d3a394da Merge branch 'feat-central-chamados' into feat-cibersecurity 2025-11-17 10:19:10 -03:00
55847e2a77 feat: add SLA statistics and real-time monitoring to central-chamados
- Introduced new queries to fetch SLA statistics and real-time SLA data for better ticket management insights.
- Enhanced the central-chamados route to display SLA performance metrics, including compliance rates and ticket statuses by priority.
- Implemented fallback logic for statistics calculation to ensure data availability even when queries return undefined.
- Refactored the UI to include a dedicated section for SLA performance, improving user experience and data visibility.
2025-11-17 09:33:33 -03:00
5ef6ef8550 feat: enhance SLA management and authentication handling
- Updated the useConvexWithAuth hook to improve token management and logging for better debugging.
- Integrated automatic authentication handling in the central-chamados route, ensuring seamless user experience.
- Added a new mutation for migrating old SLA configurations to include a priority field, enhancing data consistency.
- Improved the display of SLA configurations in the UI, including detailed views and migration feedback for better user interaction.
- Refactored ticket loading logic to enrich ticket data with responsible user names, improving clarity in ticket management.
2025-11-17 08:44:18 -03:00
fb784d6f7e refactor: simplify ticket form and SLA configuration handling
- Removed SLA configuration selection from the TicketForm component to streamline the ticket creation process.
- Updated the abrir-chamado route to eliminate unnecessary SLA loading logic and directly pass loading state to the TicketForm.
- Enhanced the central-chamados route to support SLA configurations by priority, allowing for better management of SLA settings.
- Introduced new mutations for SLA configuration management, including creation, updating, and deletion of SLA settings.
- Improved email templates for ticket notifications, ensuring better communication with users regarding ticket status and updates.
2025-11-16 15:41:16 -03:00
60e0bfa69e feat: add report printing and deletion functionality
- Implemented a new feature to print security reports with structured JSON observations, enhancing report accessibility.
- Added a deletion function for reports, allowing users to remove reports with confirmation prompts.
- Updated the CybersecurityWizcard component to include action buttons for printing and deleting reports, improving user interaction.
- Enhanced the backend with a mutation to handle report deletions, ensuring proper cleanup of associated artifacts.
2025-11-16 08:24:58 -03:00
70d405d98d feat: implement alert configuration and recent report features
- Added alert configuration management for email and chat notifications, allowing users to set preferences for severity levels, attack types, and notification channels.
- Introduced functionality to save, edit, and delete alert configurations, enhancing user control over security notifications.
- Implemented a new query to list recent security reports, providing users with quick access to the latest security incidents.
- Enhanced the backend schema to support alert configurations and recent report tracking, improving overall security management capabilities.
2025-11-16 07:37:36 -03:00
88983ea297 feat: integrate rate limiting and enhance security features
- Added @convex-dev/rate-limiter dependency to manage request limits effectively.
- Implemented rate limiting configurations for IPs, users, and endpoints to prevent abuse and enhance security.
- Introduced new security analysis endpoint to detect potential attacks based on incoming requests.
- Updated backend schema to include rate limit configurations and various cyber attack types for improved incident tracking.
- Enhanced existing security functions to incorporate rate limiting checks, ensuring robust protection against brute force and other attacks.
2025-11-16 01:20:57 -03:00
ea01e2401a feat: enhance security features and backend schema
- Added new cron jobs for automatic IP block expiration and threat intelligence synchronization to improve security management.
- Expanded the backend schema to include various types of cyber attack classifications, security event statuses, and incident action types for better incident tracking and response.
- Introduced new tables for network sensors, IP reputation, port rules, threat intelligence feeds, and security events to enhance the overall security infrastructure.
- Updated API definitions to incorporate new security-related modules, ensuring comprehensive access to security functionalities.
2025-11-15 07:25:01 -03:00
118051ad56 refactor: update menu and routing for ticket management
- Replaced references to "Solicitar Acesso" with "Abrir Chamado" across the application for consistency in terminology.
- Updated routing logic to reflect the new ticket management flow, ensuring that the dashboard and sidebar components point to the correct paths.
- Removed the obsolete "Solicitar Acesso" page, streamlining the user experience and reducing unnecessary navigation options.
- Enhanced backend schema to support new ticket functionalities, including ticket creation and management.
2025-11-14 22:50:03 -03:00
9b3b095c01 feat: enhance file upload component and backend schema
- Updated the FileUpload component to improve file handling and state management, including better cancellation logic and input handling.
- Added a new alias in the Svelte configuration for easier backend access.
- Enhanced the backend schema to include a gestorSuperiorId for better team management and query capabilities.
- Refactored queries and mutations in the backend to support the new structure and improve data retrieval for subordinate teams.
2025-11-14 22:11:06 -03:00
3c371bc35c refactor: update permission management and role structure
- Enhanced the permission management system by introducing a new base permissions structure, allowing for better organization and clarity.
- Updated the role creation process to normalize role levels, limiting them to two levels: 0 (maximum access) and 1 (administrative access).
- Improved the UI for permission displays, ensuring users are informed when no permissions are available.
- Added alerts and messages to guide users in creating permissions when none exist.
- Streamlined backend queries for permissions and roles to improve performance and maintainability.
2025-11-14 15:12:54 -03:00
5b2c682870 lixo 2025-11-14 10:47:41 -03:00
aa0b03ed3f feat: implement immediate email processing for unscheduled emails
- Added logic to process emails immediately if no scheduling is provided or if the scheduled time has passed.
- Introduced error handling for immediate email scheduling to ensure the mutation does not fail if scheduling encounters an error.
- Updated comments for clarity on email processing behavior.
2025-11-13 16:46:08 -03:00
c058865817 refactor: update vacation management structure and enhance status handling
- Renamed and refactored vacation-related types and components for clarity, transitioning from 'SolicitacaoFerias' to 'PeriodoFerias'.
- Improved the handling of vacation statuses, including the addition of 'EmFérias' to the status options.
- Streamlined the vacation request and approval components to better reflect individual vacation periods.
- Enhanced data handling in backend queries and schema to support the new structure and ensure accurate status updates.
- Improved user experience by refining UI elements related to vacation periods and their statuses.
2025-11-13 15:54:59 -03:00
ebde59c6d2 refactor: enhance vacation management components and add status update functionality
- Improved the vacation request component with better loading states and error handling.
- Added a new mutation to update the status of vacation requests, allowing transitions between different states.
- Enhanced the calendar display for vacation periods and integrated a 3D bar chart for visualizing vacation data.
- Refactored the code for better readability and maintainability, ensuring a smoother user experience.
2025-11-13 05:51:55 -03:00
0b7f1ad621 chore: update dependencies and enhance vacation request component
- Updated convex-svelte to version 0.0.12 and convex to version 1.28.2 for improved functionality.
- Refactored the vacation request component to enhance loading states and error handling.
- Implemented derived states for better management of loading and error states.
- Improved calendar initialization logic and cleanup processes for better performance and reliability.
2025-11-13 03:28:39 -03:00
94f4b23a39 refactor: enhance employee registration form and backend validation
- Updated the employee registration form in Svelte to include additional fields for personal and banking information.
- Improved validation logic for required fields and document uploads, ensuring better user feedback.
- Refactored the backend mutation to streamline argument handling and added new fields for document storage.
- Enhanced the overall structure and readability of the code, maintaining existing functionality while improving maintainability.
2025-11-12 16:29:18 -03:00
3a783727dc refactor: enhance vacation request component and improve error handling
- Updated the SolicitarFerias component to improve the user interface and experience.
- Added validation for overlapping vacation periods and ensured proper error messages are displayed.
- Refactored the logic for adding and removing vacation periods, enhancing code readability and maintainability.
- Improved the handling of form submission and error states for better user feedback.
2025-11-12 14:38:08 -03:00
553fc578a6 fix: foto perfil url 2025-11-12 14:26:51 -03:00
6087990eaf refactor: improve user retrieval and formatting in auth component
- Enhanced the getCurrentUser function to include the user's profile picture URL.
- Cleaned up formatting for better readability and consistency across the auth.ts file.
- Maintained existing functionality while improving code organization.
2025-11-12 12:15:43 -03:00
da26a21f7e refactor: update permissions and clean up Svelte component
- Removed outdated information about the permissions system from the Svelte component.
- Added new actions for resource management in the backend, including 'aprovar_ausencias' and 'aprovar_ferias'.
- Cleaned up console logs in the user retrieval function for better performance and security.
2025-11-12 11:59:53 -03:00
90bc5771ae refactor: enhance role management and permissions handling
- Introduced a new mutation for creating roles with validation and slugification of names.
- Updated existing queries to improve role retrieval and error handling.
- Enhanced permission copying functionality when creating new roles.
- Improved code organization and readability by restructuring functions and adding type annotations.
2025-11-12 10:24:56 -03:00
Kilder Costa
caff7035f7 Revert "Feat many fixes" 2025-11-11 16:41:40 -03:00
dab4754e47 Merge remote-tracking branch 'origin' into feat-many-fixes 2025-11-11 16:25:29 -03:00
8a0a4552f7 refactor: enhance employee management with regime de trabalho integration
- Added regime de trabalho selection to employee forms for better categorization.
- Updated backend validation to include regime de trabalho options for employees.
- Enhanced employee data handling by integrating regime de trabalho into various components.
- Removed the print modal for financial data to streamline the employee profile interface.
- Improved overall code clarity and maintainability across multiple files.
2025-11-11 16:10:08 -03:00
d3d7744402 Refactor backend code style and improve user profile handling
- Standardize import formatting and indentation in auth and funcionarios
  modules
- Enhance getCurrentUser query to include photo URL retrieval from
  storage
- Add getCurrent funcionario query based on authenticated user
- Update controller logic to avoid redundant local state for profile
  photos
- Upgrade dependencies: convex 1.28.2, svelte 5.43.6, vite 7.2.2, rollup
  4.53.2, tailwindcss 4.1.17, and others
2025-11-11 16:01:18 -03:00
ed00739b30 refactor: enhance chat components and improve user interaction
- Refactored Sidebar, ChatList, ChatWindow, and NewConversationModal components for better readability and maintainability.
- Updated user data handling to utilize the latest API responses, ensuring accurate display of user statuses and notifications.
- Improved modal interactions and user feedback mechanisms across chat components.
- Cleaned up unused code and optimized state management for a smoother user experience.
2025-11-10 15:03:16 -03:00
4ed90d380d refactor: improve layout and backend monitoring functionality
- Streamlined the layout component in Svelte for better readability and consistency.
- Enhanced the backend monitoring functions by updating argument structures and improving code clarity.
- Added new query functions for system status and database activity, providing better insights into system performance.
- Cleaned up existing code to ensure maintainability and improved error handling across various functions.
2025-11-08 18:30:27 -03:00
5d76c375c2 refactor: streamline chat widget and backend user management
- Removed the .editorconfig file to simplify project configuration.
- Refactored the ChatWidget component to enhance readability and maintainability, including the integration of current user data and improved notification handling.
- Updated backend functions to utilize the new getCurrentUserFunction for user authentication, ensuring consistent user data retrieval across various modules.
- Cleaned up code in multiple backend files, enhancing clarity and performance while maintaining functionality.
- Improved error handling and user feedback mechanisms in user-related operations.
2025-11-08 17:46:10 -03:00
28107b4050 refactor: enhance Sidebar component with Better Auth integration
- Replaced the use of `useConvexClient` with `useQuery` for fetching the current user.
- Updated avatar URL retrieval to utilize the current user data from Better Auth.
- Refactored login and logout functions to use the new `authClient` methods for improved authentication flow.
- Cleaned up the component structure and styling for better readability and maintainability.
- Adjusted sidebar and footer styles for consistency with the new design system.
2025-11-08 09:48:12 -03:00
3a32f5e4eb refactor: remove authentication module and integrate Better Auth
- Deleted the `autenticacao.ts` file to streamline the authentication process.
- Updated the `auth.ts` file to include new functions for user management and password updates.
- Modified the schema to enforce the presence of `authId` for users, ensuring integration with Better Auth.
- Refactored the seed process to create users with Better Auth integration, enhancing user management capabilities.
- Cleaned up the `usuarios.ts` file to utilize the new authentication functions and improve code clarity.
2025-11-07 23:33:09 -03:00
57dd9492ef refactor base auth 2025-11-07 10:33:48 -03:00
6f4df44a00 refactor: simplify auth component configuration
- Removed the local schema configuration from the auth component, streamlining the integration with Better Auth.
- Updated the client creation to focus solely on the DataModel, enhancing clarity and maintainability.
2025-11-07 09:18:41 -03:00
ca51839082 initial better auth config 2025-11-06 11:42:48 -03:00
06f03b53e5 feat: integrate Better Auth and enhance authentication flow
- Added Better Auth integration to the web application, allowing for dual login support with both custom and Better Auth systems.
- Updated authentication client configuration to dynamically set the base URL based on the environment.
- Enhanced chat components to utilize user authentication status, improving user experience and security.
- Refactored various components to support Better Auth, including error handling and user identity management.
- Improved notification handling and user feedback mechanisms during authentication processes.
2025-11-06 09:35:36 -03:00
33f305220b feat: improve email status querying and URL handling
- Updated email status query to execute only when there are email IDs, enhancing performance.
- Ensured URL handling in email sending functions always includes a protocol, improving reliability.
- Added new queries for fetching emails by IDs and listing scheduled emails, enriching email management capabilities.
2025-11-05 16:23:47 -03:00
36933b53cb Merge remote-tracking branch 'origin/master' into ajuste_chat 2025-11-05 15:17:26 -03:00
1b02ea7c22 feat: enhance notification management with new clearing functionalities
- Added functionality to clear all notifications and clear unread notifications for improved user control.
- Updated NotificationBell component to support modal display for notifications, enhancing user experience.
- Refactored notification handling to separate read and unread notifications, providing clearer organization.
- Introduced new UI elements for managing notifications, including buttons for clearing notifications directly from the modal.
- Improved backend mutations to handle notification deletion securely, ensuring users can only delete their own notifications.
2025-11-05 15:06:41 -03:00
fe83a3d371 feat: update email handling and user management logic
- Added logic to update user email if it differs from the existing record when updating a funcionario.
- Refactored email sending action to improve code readability and maintainability, including consistent formatting and error handling.
- Enhanced logging for email configuration and sending processes to provide clearer feedback during operations.
2025-11-05 15:05:54 -03:00
6166043735 feat: enhance ErrorModal and chat components with new features and improvements
- Refactored ErrorModal to utilize a dialog element for better accessibility and user experience, including a close button with an icon.
- Updated chat components to improve participant display and message read status, enhancing user engagement and clarity.
- Introduced loading indicators for user and conversation data in SalaReuniaoManager to improve responsiveness during data fetching.
- Enhanced message handling in MessageList to indicate whether messages have been read, providing users with better feedback on message status.
- Improved overall structure and styling across various components for consistency and maintainability.
2025-11-05 14:05:52 -03:00
6cb7414dcc fix: update dependencies and improve chat component structure
- Updated `lucide-svelte` dependency to version 0.552.0 across multiple files for consistency.
- Refactored chat components to enhance structure and readability, including adjustments to the Sidebar, ChatList, and MessageInput components.
- Improved notification handling in chat components to ensure better user experience and responsiveness.
- Added type safety enhancements in various components to ensure better integration with backend data models.
2025-11-05 11:52:01 -03:00