Commit Graph

84 Commits

Author SHA1 Message Date
ahasani 59da9585c4 init to partner module 2026-04-13 15:47:59 +03:30
ahasani 388aa25de4 init to statistics and manage pos type users 2026-04-13 13:21:50 +03:30
ahasani 9cef733370 update models and create consumer domain accounts permissions 2026-04-11 14:47:05 +03:30
ahasani 89726c8904 set consumer customers and saleInvoices 2026-04-08 18:15:44 +03:30
ahasani b8c5cb4c80 debug license 2026-04-06 21:12:07 +03:30
ahasani af71fb441b update 2026-04-06 18:33:04 +03:30
ahasani 1160d81cdb create license management 2026-04-06 13:31:40 +03:30
ahasani 9cf9209daa change source of account id in prepared token to domain account id, create consumer salesInvoiceModule 2026-03-30 13:16:36 +03:30
ahasani c870a43e35 update pos consumer module 2026-03-29 18:06:41 +03:30
ahasani 63fa2bc67e complexGood
Module
2026-03-16 20:59:13 +03:30
ahasani 69e9a0d082 create token decorator and consumer module 2026-03-16 17:56:51 +03:30
ahasani 0ad6a3200e refactor user accounts structure 2026-03-16 00:33:40 +03:30
ahasani d2215b9f04 update admin user business 2026-03-14 16:26:44 +03:30
ahasani 007db7f9bd updating 2026-03-11 20:42:34 +03:30
ahasani 8c5f1d4d49 transform core api codes into this project, update modules as admin/pos context modules 2026-03-07 11:25:11 +03:30
ahasani b949500482 feat(customers): add DTOs for individual and legal customer creation
- Created CreateCustomerIndividualDto for individual customer data with fields: first_name, last_name, national_code, postal_code, is_favorite, and economic_code.
- Created CreateCustomerLegalDto for legal customer data with fields: company_name, economic_code, registration_number, and postal_code.
2026-02-24 12:42:10 +03:30
ahasani c7cd7cd855 refactor: remove console logs, update SaleInvoicePayload interface, and enhance GoodCategoriesService response mapping 2026-02-17 20:16:36 +03:30
ahasani 55b96d4f79 feat: update validation and exception handling, refactor controller routes, and enhance sales invoice item DTO
- Removed global validation pipe and added a new ValidationExceptionFilter for better error handling.
- Refactored controller routes to use underscores instead of hyphens for consistency.
- Updated CreateSalesInvoiceItemDto to include new fields: quantity, unit_type, and payload.
- Modified CreateSalesInvoiceDto to enforce items as an array with a minimum size.
- Added Enums module to provide gold karat values through a dedicated endpoint.
- Introduced new columns in the database schema for sales invoice items and goods.
2026-02-16 20:51:34 +03:30
ahasani a073af76fe feat: add config module with controller and service
- Implemented ConfigController for handling config-related requests.
- Created ConfigService for business logic related to configurations.
- Added CreateConfigDto for validating configuration data.

feat: add good categories module with controller and service

- Implemented GoodCategoriesController for managing good categories.
- Created GoodCategoriesService for business logic related to good categories.
- Added CreateGoodCategoryDto for validating good category data.

feat: add goods module with controller and service

- Implemented GoodsController for managing goods.
- Created GoodsService for business logic related to goods.
- Added CreateGoodDto for validating good data.

feat: add profile module with controller and service

- Implemented ProfileController for managing user profiles.
- Created ProfileService for business logic related to profiles.
- Added CreateProfileDto for profile data structure.

feat: add sales invoice payments module with controller and service

- Implemented SalesInvoicePaymentsController for managing invoice payments.
- Created SalesInvoicePaymentsService for business logic related to payments.
- Added CreateSalesInvoicePaymentDto for validating payment data.

feat: add service categories module with controller and service

- Implemented ServiceCategoriesController for managing service categories.
- Created ServiceCategoriesService for business logic related to service categories.
- Added CreateServiceCategoryDto for validating service category data.

feat: add services module with controller and service

- Implemented ServicesController for managing services.
- Created ServicesService for business logic related to services.
- Added CreateServiceDto for validating service data.

feat: add trigger logs module with controller and service

- Implemented TriggerLogsController for managing trigger logs.
- Created TriggerLogsService for business logic related to trigger logs.
- Added CreateTriggerLogDto for validating trigger log data.

feat: add uploaders module for handling file uploads

- Implemented UploadersController for managing file uploads.
- Created ImageUploaderService for image upload logic.
- Created UploaderService for file handling and storage.
2026-02-12 20:31:04 +03:30
ahasani de14d531e1 init 2026-02-04 13:49:07 +03:30
ahasani 5fd6611aca feat: implement POS order management system
- Added CreateOrderDto and CreateOrderItemDto for order creation.
- Developed PosOrdersController to handle order-related endpoints.
- Created PosOrdersService for business logic related to orders.
- Implemented PosOrdersWorkflow for order processing workflows.
- Established Prisma integration for database operations in orders.
- Introduced SalesInvoicesModule and related DTOs for sales invoice management.
- Enhanced SalesInvoicesService and SalesInvoicesWorkflow for invoice processing.
2026-01-07 15:25:59 +03:30
ahasani b05048e62f feat(bank-accounts): add transaction retrieval and update service logic
- Implemented a new endpoint to fetch transactions for a specific bank account.
- Refactored the bank account service to streamline transaction handling and balance calculations.
- Removed the bank account balance table and adjusted related logic in workflows and services.
- Enhanced transaction mapping to include references to sales and purchase records.
2026-01-05 18:35:08 +03:30
ahasani fda190f902 refactor: restructure purchase receipts module and related workflows
- Removed old DTOs for creating and updating purchase receipts.
- Updated purchase receipts controller and service to use new DTOs and workflows.
- Introduced transaction helper for managing database transactions.
- Added new workflows for handling purchase receipt payments and supplier ledgers.
- Implemented new logic for managing purchase receipt items and payments.
- Enhanced error handling for payment processing in workflows.
- Updated supplier ledger management to reflect changes in purchase receipts.
2026-01-05 10:07:23 +03:30
ahasani a2db2daa70 feat(statistics): implement top alert stocks, top last sales, top supplier debts, and top selling products endpoints with SQL queries 2026-01-04 13:45:26 +03:30
ahasani eb6e0e7a0d feat(inventories): add cardex retrieval for inventory and product
feat(pos): update sale invoice creation to include customer and item details
feat(pos): enhance POS account service to include today's sales information
feat(pos): refactor order DTO to create sale invoice with detailed item structure
feat(products): add minimum stock alert level to product creation and update DTOs
fix(triggers): implement stock validation and movement logging for sales invoice items
refactor(database): update sales invoices schema to include posAccountId and remove inventoryId
2025-12-30 21:04:01 +03:30
ahasani 1bb206a608 feat: add bank account relation to PurchaseReceiptPayments and update related services
- Added bank account relation to PurchaseReceiptPayments model.
- Updated BankAccount model to include purchaseReceiptPayments relation.
- Modified PurchaseReceiptPayments service to handle bank account data during payment creation.
- Enhanced SuppliersService to order suppliers by creation date.
- Updated SupplierInvoicesService to include bank account details in invoice payments and order payments by payedAt.
- Added foreign key constraint for bankAccountId in PurchaseReceiptPayments table.
2025-12-29 10:14:56 +03:30
ahasani b35a3633ed feat(pos): update createOrder method to accept posId and retrieve inventoryId 2025-12-28 17:52:07 +03:30
ahasani af9695e23c refactor: restructure suppliers module and update DTOs
- Removed old supplier DTOs and controller, replacing them with new implementations.
- Introduced new CreateSupplierDto and UpdateSupplierDto in the index directory.
- Updated SuppliersController to handle new routes and methods.
- Implemented SuppliersService with updated logic for creating, finding, updating, and removing suppliers.
- Added new invoices module with corresponding controller and service for handling invoice-related operations.
- Created new DTOs for handling receipt payments and updated the service to manage payment creation and retrieval.
- Updated Prisma migrations to reflect changes in the database schema, including dropping unnecessary columns.
2025-12-27 20:34:00 +03:30
ahasani d98507fc1f fix: update SupplierLedger model to use correct enum casing and adjust types
feat: enhance PosAccountsService to include inventoryBankAccount details in responses

refactor: modify PosService to return structured inventory and bank account data

chore: remove isSettled field from CreatePurchaseReceiptDto and adjust related logic

feat: add payments selection in SuppliersService for better payment tracking

chore: apply database migrations to adjust decimal types and enforce constraints

chore: create index on Pos_Accounts for improved query performance

feat: define Supplier and SupplierLedger models in Prisma schema for better data management
2025-12-26 22:09:46 +03:30
ahasani d59be5995d feat(pos): update POS controller and service to handle posId for stock and product categories 2025-12-26 16:47:34 +03:30
ahasani b4f226fb3a refactor(inventories): restructure inventory and pos account modules, remove deprecated DTOs and controllers
- Removed create and update DTOs for inventory.
- Deleted inventories controller and service.
- Introduced new inventory bank accounts module with controller and service.
- Added new pos accounts module with controller and service.
- Updated Prisma models to reflect changes in bank account relationships.
- Adjusted PosAccount and SalesInvoice models for stricter type definitions.
- Implemented new response mapping for inventory and pos account services.
2025-12-26 01:20:03 +03:30
ahasani cbe51b9343 feat: implement bank accounts, branches, and banks modules with CRUD operations
- Added BankAccountsController, BankAccountsService, and related DTOs for managing bank accounts.
- Implemented BankBranchesController, BankBranchesService, and related DTOs for managing bank branches.
- Created BanksController and BanksService for retrieving bank information.
- Integrated Prisma for database operations across all modules.
- Added response mapping for consistent API responses.
2025-12-24 21:24:59 +03:30
ahasani 89c57a69c1 feat(cardex): enhance stock movement retrieval with additional fields and optimized mapping
refactor(migration): update Stock_Movements table to include counterInventoryId and customerId, add foreign key constraints, and implement triggers for inventory management
2025-12-23 20:35:44 +03:30
ahasani c6a86719dd feat(cardex): implement cardex controller, service, and DTO for stock movements
feat(pos): add POS controller and service for order creation and stock retrieval
refactor(pos): enhance stock and product category retrieval with pagination and mapping
2025-12-21 19:09:41 +03:30