104 Commits

Author SHA1 Message Date
3be1547137 fix mannually verify error 2026-01-24 16:25:22 +03:30
bdc6f95af8 fix activate all after create new 2026-01-22 12:26:13 +03:30
140414b866 feat: add SetIsSent endpoint to update contract send status 2026-01-07 16:23:11 +03:30
dd7e816767 feat: add SetContractSendFlag method and related request for contract send tracking 2026-01-07 14:46:34 +03:30
6909fcf715 remove financial transaction on institutioncontract veerification 2025-12-31 20:06:56 +03:30
ce305edac4 add: integrate ILogger for SepehrPaymentGateway logging 2025-12-31 19:12:12 +03:30
490a1a69d5 add: implement Sepehr payment gateway integration and enhance financial invoice handling 2025-12-31 18:12:27 +03:30
58f695fe95 Merge branch 'Feature/institution-contract/change-account-with-data' 2025-12-30 20:58:12 +03:30
d663857de1 feat: add contracting party response class and update endpoints for institution contract creation 2025-12-30 19:51:28 +03:30
eb9a3e52fe feat: implement async methods for activating and deactivating personal contracting parties 2025-12-30 13:50:09 +03:30
16c1ae04a9 remove some injections 2025-12-30 12:44:55 +03:30
836e721b6f feat: refactor institution contract creation classes and endpoints 2025-12-30 10:38:07 +03:30
8fca1f3a91 feat: add institution contract creation inquiry functionality 2025-12-29 22:19:16 +03:30
84416fe1f5 feat: add validation for in-person contract approval and suppress documentation warnings 2025-12-29 13:29:32 +03:30
94237434c5 fix: safely deactivate previous institution contract if it exists 2025-12-24 19:30:58 +03:30
4f0e5a34a4 add: implement reactivation logic for institution contracts and retrieve previous contracts 2025-12-24 15:40:06 +03:30
9df56ee19b Merge branch 'Feature/institution-contract/verify-mannually' 2025-12-22 17:44:04 +03:30
8750604d96 feat: add financial transaction handling during institution contract verification 2025-12-22 17:43:32 +03:30
f27ce460fd feat: integrate RollCallService repository into InstitutionContractApplication and WorkshopApplication 2025-12-22 17:33:37 +03:30
2d879ce80a fix: update workshop identification logic in InstitutionContractApplication 2025-12-20 20:06:28 +03:30
722f8dae7c feat: implement manual verification for institution contracts and add signing type handling 2025-12-20 18:27:17 +03:30
a533850f24 Enhance contract removal logic and handle financial statement updates 2025-12-04 10:36:59 +03:30
e78c838cab Add method to edit legal party details from institution in contracting party 2025-12-02 13:00:34 +03:30
d2f0ed46ae Refactor discount calculation and response models for institution contracts
- Replace InstitutionContractExtensionPaymentResponse with InstitutionContractDiscountResponse in discount-related methods and endpoints
- Update request and response models to include OneMonthAmount, Obligation, and improved discount fields
- Adjust method signatures and controller actions to use new response types
- Refactor discount calculation logic to support new structure and ensure correct plan updates for both installment and one-time payments
- Improve naming consistency for discount percentage fields
2025-11-29 20:07:29 +03:30
5d81731512 Add reset discount functionality for institution contract creation and extension 2025-11-29 11:11:34 +03:30
511932fa58 Add discount support for institution contract extensions
- Introduce DiscountPercentage and DiscountAmount fields to contract creation and payment models
- Implement discount calculation logic in repository
- Add SetDiscountForExtension API endpoint and related request/response models
- Update contract creation and extension flows to handle discounts
2025-11-29 09:44:30 +03:30
95891d5bae Handle BuyInstitutionContractInstallment items in invoice processing and add GetIdByInstallmentId method 2025-11-27 21:12:52 +03:30
f3fa76c292 Prevent duplicate financial invoices by checking for existing unpaid invoices before creation 2025-11-27 11:39:03 +03:30
947d7590f4 Fix contract validation and authentication checks
Updated authentication checks for LegalParty and RealParty to
prevent null reference exceptions by ensuring existingContractingParty
is not null before invoking unauthentication methods.

Added a validation step to prevent duplicate contracts by checking
for existing records in the repository based on ContractingPartyId,
RepresentativeId, and TypeOfContract.
2025-11-26 19:47:24 +03:30
91403a52a3 Replace VerifySend with SendInstitutionVerificationCode
Replaced the `_smsService.VerifySend` method with the new
asynchronous `_smsService.SendInstitutionVerificationCode`
method. The new method includes additional parameters:
`contractingPartyFullName`, `contractingParty.id`, and
`institutionContract.id`, providing more context for the
verification process. Added `await` to ensure proper
asynchronous execution.
2025-11-26 18:25:26 +03:30
5e92207778 Refactor financial transaction and invoice handling
Refactored and streamlined the handling of financial transactions, invoices, and installment logic in `InstitutionContractApplication` and `InstitutionContractRepository`. Removed redundant code and consolidated logic for creating financial transactions and invoices into a reusable structure.

- Delegated financial transaction and invoice creation to the application layer.
- Simplified installment handling by directly managing installment lists.
- Introduced modular logic for handling installment and full payment scenarios.
- Replaced redundant `FinancialInvoice` and `FinancialInvoiceItem` creation in the repository layer.
- Added logic to retrieve `financialStatement` from the repository when available.
- Improved consistency in handling `invoiceAmount` across payment-related operations.
- Removed unused code for unpaid invoice retrieval and associated logic.
- Added support for creating `CreateContactInfo` objects for institution contracts.

These changes improve code maintainability, readability, and modularity by reducing duplication and ensuring responsibilities are handled at the appropriate layers.
2025-11-26 17:11:53 +03:30
8ec717916c add unauthenticated edit support for contracting party phone and info in institution contracts 2025-11-25 11:40:44 +03:30
90d7de4901 Increase max length for contact info and names in contract entities; update related migrations and improve SMS service logic 2025-11-19 21:23:28 +03:30
37aa57d773 Refactor repository and remove unused Index files
Refactored `IPersonalContractingPartyRepository` to replace `GetByRegisterId` with `GetByNationalId`. Updated `InstitutionContractApplication` to use the new method and removed duplicate `RegisterId` validation logic.

Removed `Index.cshtml` and `Index.cshtml.cs` files, including all associated HTML, scripts, styles, and backend logic, indicating a deprecation or restructuring of the related functionality.
2025-11-19 19:16:55 +03:30
873ad2f41f Adjust institution contract creation flow to ensure entity is saved before invoice generation 2025-11-19 11:09:42 +03:30
f238b5af6b Enhance financial invoice handling by adding InvoiceNumber property and increasing DescriptionOption max length; implement SetPendingWorkflow method 2025-11-17 20:51:21 +03:30
ed746cb60a Refactor invoice handling to use TransactionId and add InvoiceNumber property 2025-11-17 17:06:31 +03:30
ba2b402c04 Add Financial Invoice Management System
Refactored `FinancialInvoice` to include new properties (`Description`, `PublicId`, `IsActive`) and methods for managing items and statuses. Introduced `FinancialInvoiceItem` for invoice itemization. Updated `PaymentTransaction` to reference `FinancialInvoice`.

Enhanced repository and application layers with CRUD operations, advanced search functionality, and integration with contracts. Updated `CompanyContext` with `DbSet<FinancialInvoices>` and `DbSet<FinancialInvoiceItem>`.

Created new database tables for `FinancialInvoices` and `FinancialInvoiceItem`, and updated relationships with `PaymentTransactions`. Added DTOs for invoice creation, editing, and searching. Registered `IFinancialInvoiceRepository` for dependency injection.
2025-11-13 12:49:30 +03:30
dff6bc2541 feat: add SMS settings configuration and refactor SMS sending methods for institution creation verification 2025-11-06 12:37:06 +03:30
280db87408 Merge branch 'Feature/InstitutionContract/print-api' 2025-10-26 14:00:18 +03:30
25c7b67eb5 feat: extend SMS service to include contracting party and institution contract IDs in verification link and code methods 2025-10-25 14:18:04 +03:30
6a6e2e532a feat: add print API for institution contracts and include verifier details 2025-10-23 14:13:55 +03:30
b711e803a9 Merge branch 'master' into Main
# Conflicts:
#	ServiceHost/Areas/Admin/Controllers/institutionContractController.cs
2025-10-21 11:50:45 +03:30
232a834dc9 feat: add resend verification link end point added 2025-10-21 11:41:23 +03:30
55f7b4f7c0 Merge branch 'Feature/InstitutionContract/upgrade' into Main
# Conflicts:
#	Company.Domain/InstitutionContractAgg/IInstitutionContractRepository.cs
#	Company.Domain/InstitutionContractAgg/InstitutionContract.cs
2025-10-21 11:10:06 +03:30
acdd7de4f6 feat: update InsertAmendmentTempWorkshops method to return detailed response and refactor related classes 2025-10-21 11:02:10 +03:30
fde58a7c75 feat: add temporary workshop management for institution contract amendments 2025-10-20 13:13:43 +03:30
7d6b57affd feat: make Workshops property public and update CalculateInstallment method visibility 2025-10-18 16:50:40 +03:30
2f38470746 Merge branch 'Feature/InstitutionContract/upgrade' into Main
# Conflicts:
#	Company.Domain/InstitutionContractAgg/IInstitutionContractRepository.cs
#	CompanyManagment.App.Contracts/InstitutionContract/IInstitutionContractApplication.cs
#	CompanyManagment.EFCore/Repository/InstitutionContractRepository.cs
2025-10-15 17:49:23 +03:30
13a2cd78cd feat: improve institution contract retrieval and ensure account creation consistency 2025-10-15 12:28:30 +03:30