feat: add multi-city representation support and domain context resolution

- Created migration to add representation_cities table and domain, is_global fields to representations.
- Implemented SiteContextController to resolve domain to site context (city | representation | unknown).
- Developed DomainContext and DomainContextResolver services for domain mapping.
- Added tests for DomainContextResolver and commission logic based on domain ownership.
This commit is contained in:
hamed
2026-07-09 07:26:58 +03:30
parent 59559e2e31
commit 0750bc9812
56 changed files with 4297 additions and 1600 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [{"id": "users_hamed_pj_my_pj_clinic_pro_clinicpro_docs_collect_diagnostics_sh", "label": "collect-diagnostics.sh", "file_type": "code", "source_file": "docs/collect-diagnostics.sh", "source_location": "L1", "metadata": {"language": "bash", "kind": "file"}}, {"id": "users_hamed_pj_my_pj_clinic_pro_clinicpro_docs_collect_diagnostics_sh__entry", "label": "collect-diagnostics.sh script", "file_type": "code", "source_file": "docs/collect-diagnostics.sh", "source_location": "L1", "metadata": {"language": "bash", "kind": "bash_entrypoint"}}], "edges": [{"source": "users_hamed_pj_my_pj_clinic_pro_clinicpro_docs_collect_diagnostics_sh", "target": "users_hamed_pj_my_pj_clinic_pro_clinicpro_docs_collect_diagnostics_sh__entry", "relation": "contains", "confidence": "EXTRACTED", "source_file": "docs/collect-diagnostics.sh", "source_location": "L1", "weight": 1.0}]}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [{"id": "users_hamed_pj_my_pj_clinic_pro_clinicpro_src_representation_service_domaincontext_php", "label": "DomainContext.php", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L1"}, {"id": "service_domaincontext_domaincontext", "label": "DomainContext", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L9"}, {"id": "service_domaincontext_domaincontext_construct", "label": ".__construct()", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L11"}, {"id": "service_domaincontext_domaincontext_empty", "label": ".empty()", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L17"}, {"id": "self", "label": "self", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L17"}, {"id": "service_domaincontext_domaincontext_representationid", "label": ".representationId()", "file_type": "code", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L22"}], "edges": [{"source": "users_hamed_pj_my_pj_clinic_pro_clinicpro_src_representation_service_domaincontext_php", "target": "city", "relation": "imports", "context": "import", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L5", "weight": 1.0}, {"source": "users_hamed_pj_my_pj_clinic_pro_clinicpro_src_representation_service_domaincontext_php", "target": "representation", "relation": "imports", "context": "import", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L6", "weight": 1.0}, {"source": "users_hamed_pj_my_pj_clinic_pro_clinicpro_src_representation_service_domaincontext_php", "target": "service_domaincontext_domaincontext", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L9", "weight": 1.0}, {"source": "service_domaincontext_domaincontext", "target": "service_domaincontext_domaincontext_construct", "relation": "method", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L11", "weight": 1.0}, {"source": "service_domaincontext_domaincontext", "target": "service_domaincontext_domaincontext_empty", "relation": "method", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L17", "weight": 1.0}, {"source": "service_domaincontext_domaincontext_empty", "target": "self", "relation": "references", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L17", "weight": 1.0, "context": "return_type"}, {"source": "service_domaincontext_domaincontext", "target": "service_domaincontext_domaincontext_representationid", "relation": "method", "confidence": "EXTRACTED", "source_file": "src/Representation/Service/DomainContext.php", "source_location": "L22", "weight": 1.0}], "raw_calls": []}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long