From 9fb947226fe48cd2daf29c853faaafd46ff68172 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 Sep 2024 07:55:41 +0000 Subject: [PATCH 01/11] [dependabot] github actions: Bump actions/cache from 3 to 4 Bumps [actions/cache](https://github.com/actions/cache) from 3 to 4. - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](https://github.com/actions/cache/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/cache dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8a5b72e..4f227b1 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -65,7 +65,7 @@ jobs: fetch-depth: 0 - name: Cache SonarCloud packages - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ~\sonar\cache key: ${{ runner.os }}-sonar @@ -73,7 +73,7 @@ jobs: - name: Cache SonarCloud scanner id: cache-sonar-scanner - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: .\.sonar\scanner key: ${{ runner.os }}-sonar-scanner From 3eeeb97f27081ece6b436c6211205c03f078f98c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 Sep 2024 07:55:43 +0000 Subject: [PATCH 02/11] [dependabot] github actions: Bump actions/checkout from 3 to 4 Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8a5b72e..1bb441f 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -59,7 +59,7 @@ jobs: java-version: 17 distribution: 'zulu' - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 name: Checkout with: fetch-depth: 0 From b833ef4297b7cbcdd30f5d7c930dc068b374d78c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 Sep 2024 07:55:45 +0000 Subject: [PATCH 03/11] [dependabot] github actions: Bump actions/setup-java from 3 to 4 Bumps [actions/setup-java](https://github.com/actions/setup-java) from 3 to 4. - [Release notes](https://github.com/actions/setup-java/releases) - [Commits](https://github.com/actions/setup-java/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/setup-java dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8a5b72e..13e3af1 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -54,7 +54,7 @@ jobs: runs-on: windows-latest steps: - name: Set up JDK 17 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: java-version: 17 distribution: 'zulu' From 25eff46ca9be2079c602e07dc3c0abf44afc90a1 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 1 Sep 2024 07:56:12 +0000 Subject: [PATCH 04/11] Fix code style issues with dotnet_format --- REMS.BackendApi/Features/Agent/AgentController.cs | 4 ++-- REMS.Modules/Features/Agent/BL_Agent.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/REMS.BackendApi/Features/Agent/AgentController.cs b/REMS.BackendApi/Features/Agent/AgentController.cs index f97086d..29f17d5 100644 --- a/REMS.BackendApi/Features/Agent/AgentController.cs +++ b/REMS.BackendApi/Features/Agent/AgentController.cs @@ -89,10 +89,10 @@ public async Task SearchAgentByNameAndLocation(SearchAgentRequest return Ok(agentList); } - [HttpGet("{pageNumber}/{pageSize}",Name = "AgentAll")] + [HttpGet("{pageNumber}/{pageSize}", Name = "AgentAll")] public async Task AgentAll(int pageNumber, int pageSize) { - Result agentList = await _blAgent.AgentAll(pageNumber,pageSize); + Result agentList = await _blAgent.AgentAll(pageNumber, pageSize); return Ok(agentList); } diff --git a/REMS.Modules/Features/Agent/BL_Agent.cs b/REMS.Modules/Features/Agent/BL_Agent.cs index 5dafd39..cd1b410 100644 --- a/REMS.Modules/Features/Agent/BL_Agent.cs +++ b/REMS.Modules/Features/Agent/BL_Agent.cs @@ -63,6 +63,6 @@ public async Task> SearchAgentByNameAndLocationAs public async Task> AgentAll(int pageNumber, int pageSize) { - return await _daAgent.AgentAllAsync(pageNumber,pageSize); + return await _daAgent.AgentAllAsync(pageNumber, pageSize); } } \ No newline at end of file From f2f7681c9fe21ab31a108a0144c346ba8b19d4a0 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 1 Sep 2024 07:56:17 +0000 Subject: [PATCH 05/11] Fix code style issues with dotnet_format --- REMS.BackendApi/Features/Agent/AgentController.cs | 4 ++-- REMS.Modules/Features/Agent/BL_Agent.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/REMS.BackendApi/Features/Agent/AgentController.cs b/REMS.BackendApi/Features/Agent/AgentController.cs index f97086d..29f17d5 100644 --- a/REMS.BackendApi/Features/Agent/AgentController.cs +++ b/REMS.BackendApi/Features/Agent/AgentController.cs @@ -89,10 +89,10 @@ public async Task SearchAgentByNameAndLocation(SearchAgentRequest return Ok(agentList); } - [HttpGet("{pageNumber}/{pageSize}",Name = "AgentAll")] + [HttpGet("{pageNumber}/{pageSize}", Name = "AgentAll")] public async Task AgentAll(int pageNumber, int pageSize) { - Result agentList = await _blAgent.AgentAll(pageNumber,pageSize); + Result agentList = await _blAgent.AgentAll(pageNumber, pageSize); return Ok(agentList); } diff --git a/REMS.Modules/Features/Agent/BL_Agent.cs b/REMS.Modules/Features/Agent/BL_Agent.cs index 5dafd39..cd1b410 100644 --- a/REMS.Modules/Features/Agent/BL_Agent.cs +++ b/REMS.Modules/Features/Agent/BL_Agent.cs @@ -63,6 +63,6 @@ public async Task> SearchAgentByNameAndLocationAs public async Task> AgentAll(int pageNumber, int pageSize) { - return await _daAgent.AgentAllAsync(pageNumber,pageSize); + return await _daAgent.AgentAllAsync(pageNumber, pageSize); } } \ No newline at end of file From 445cfbfc55b7ffda6fbab595e0f778187dbf9a8d Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 1 Sep 2024 07:56:21 +0000 Subject: [PATCH 06/11] Fix code style issues with dotnet_format --- REMS.BackendApi/Features/Agent/AgentController.cs | 4 ++-- REMS.Modules/Features/Agent/BL_Agent.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/REMS.BackendApi/Features/Agent/AgentController.cs b/REMS.BackendApi/Features/Agent/AgentController.cs index f97086d..29f17d5 100644 --- a/REMS.BackendApi/Features/Agent/AgentController.cs +++ b/REMS.BackendApi/Features/Agent/AgentController.cs @@ -89,10 +89,10 @@ public async Task SearchAgentByNameAndLocation(SearchAgentRequest return Ok(agentList); } - [HttpGet("{pageNumber}/{pageSize}",Name = "AgentAll")] + [HttpGet("{pageNumber}/{pageSize}", Name = "AgentAll")] public async Task AgentAll(int pageNumber, int pageSize) { - Result agentList = await _blAgent.AgentAll(pageNumber,pageSize); + Result agentList = await _blAgent.AgentAll(pageNumber, pageSize); return Ok(agentList); } diff --git a/REMS.Modules/Features/Agent/BL_Agent.cs b/REMS.Modules/Features/Agent/BL_Agent.cs index 5dafd39..cd1b410 100644 --- a/REMS.Modules/Features/Agent/BL_Agent.cs +++ b/REMS.Modules/Features/Agent/BL_Agent.cs @@ -63,6 +63,6 @@ public async Task> SearchAgentByNameAndLocationAs public async Task> AgentAll(int pageNumber, int pageSize) { - return await _daAgent.AgentAllAsync(pageNumber,pageSize); + return await _daAgent.AgentAllAsync(pageNumber, pageSize); } } \ No newline at end of file From 70dee71a299fcb1841ddb536887e9e251cbcba46 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 Sep 2024 08:05:30 +0000 Subject: [PATCH 07/11] [dependabot] npm: Bump Swashbuckle.AspNetCore from 6.7.0 to 6.7.3 Bumps [Swashbuckle.AspNetCore](https://github.com/domaindrivendev/Swashbuckle.AspNetCore) from 6.7.0 to 6.7.3. - [Release notes](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/releases) - [Commits](https://github.com/domaindrivendev/Swashbuckle.AspNetCore/compare/v6.7.0...v6.7.3) --- updated-dependencies: - dependency-name: Swashbuckle.AspNetCore dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- REMS.BackendApi/REMS.BackendApi.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/REMS.BackendApi/REMS.BackendApi.csproj b/REMS.BackendApi/REMS.BackendApi.csproj index bcb947d..7c9e9a8 100644 --- a/REMS.BackendApi/REMS.BackendApi.csproj +++ b/REMS.BackendApi/REMS.BackendApi.csproj @@ -12,7 +12,7 @@ - + From e57f3e953ecffe0800c1229fd424bcc432a94546 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 1 Sep 2024 08:06:03 +0000 Subject: [PATCH 08/11] Fix code style issues with dotnet_format --- .../Features/Agent/AgentController.cs | 4 +-- REMS.BackendApi/packages.lock.json | 26 +++++++++---------- REMS.Modules/Features/Agent/BL_Agent.cs | 2 +- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/REMS.BackendApi/Features/Agent/AgentController.cs b/REMS.BackendApi/Features/Agent/AgentController.cs index f97086d..29f17d5 100644 --- a/REMS.BackendApi/Features/Agent/AgentController.cs +++ b/REMS.BackendApi/Features/Agent/AgentController.cs @@ -89,10 +89,10 @@ public async Task SearchAgentByNameAndLocation(SearchAgentRequest return Ok(agentList); } - [HttpGet("{pageNumber}/{pageSize}",Name = "AgentAll")] + [HttpGet("{pageNumber}/{pageSize}", Name = "AgentAll")] public async Task AgentAll(int pageNumber, int pageSize) { - Result agentList = await _blAgent.AgentAll(pageNumber,pageSize); + Result agentList = await _blAgent.AgentAll(pageNumber, pageSize); return Ok(agentList); } diff --git a/REMS.BackendApi/packages.lock.json b/REMS.BackendApi/packages.lock.json index bbc2417..a5f8370 100644 --- a/REMS.BackendApi/packages.lock.json +++ b/REMS.BackendApi/packages.lock.json @@ -22,14 +22,14 @@ }, "Swashbuckle.AspNetCore": { "type": "Direct", - "requested": "[6.7.0, )", - "resolved": "6.7.0", - "contentHash": "nrkZMoflCvTKj2yckJ1k/tQu53IRGHYkKp7ESiQETkAaUXzn05CYlCl/DY9kBBbFqefHWIwC/9VmYisD44jqlA==", + "requested": "[6.7.3, )", + "resolved": "6.7.3", + "contentHash": "PYTm/M5YrkEUHmguhj6vF1DshG2deKMMcsnhKet1BkcKzZHNX/VVQady0T/jNpXrtxhLR3vB10hWhONF1Nbglw==", "dependencies": { "Microsoft.Extensions.ApiDescription.Server": "6.0.5", - "Swashbuckle.AspNetCore.Swagger": "6.7.0", - "Swashbuckle.AspNetCore.SwaggerGen": "6.7.0", - "Swashbuckle.AspNetCore.SwaggerUI": "6.7.0" + "Swashbuckle.AspNetCore.Swagger": "6.7.3", + "Swashbuckle.AspNetCore.SwaggerGen": "6.7.3", + "Swashbuckle.AspNetCore.SwaggerUI": "6.7.3" } }, "Azure.Core": { @@ -313,24 +313,24 @@ }, "Swashbuckle.AspNetCore.Swagger": { "type": "Transitive", - "resolved": "6.7.0", - "contentHash": "qI1ntGtNnt1Nksi/oDNkmCULVrImHyLWodJhQzghGj9W6uKYMqVl8Y7M2oU8VbHTQZFImD2kYR9ay8LZkJwaqA==", + "resolved": "6.7.3", + "contentHash": "plNVrOpup/UCIP0aSE5cznIzXMC17EOOqIceWqhP829evEAUwTomCc+1TPy2xK2E+OilYcYEdUus3rOUMjjm/g==", "dependencies": { "Microsoft.OpenApi": "1.6.14" } }, "Swashbuckle.AspNetCore.SwaggerGen": { "type": "Transitive", - "resolved": "6.7.0", - "contentHash": "e2eRUBYnMBWzyl0esJfcB4YHuG/boD6nmuDcKdRa+nYPU/57+kbZ3Ot4TGpRDTJcZ0BrWoQiYe5mWRy6whvTkQ==", + "resolved": "6.7.3", + "contentHash": "kvjGd+g85YFZqyEQZSBUCPtEDDCZsiPPYcjgBN6si3C3oik2c9d7Zlq4PIm07pgY/QmBMgyFOVEzHbks6a398w==", "dependencies": { - "Swashbuckle.AspNetCore.Swagger": "6.7.0" + "Swashbuckle.AspNetCore.Swagger": "6.7.3" } }, "Swashbuckle.AspNetCore.SwaggerUI": { "type": "Transitive", - "resolved": "6.7.0", - "contentHash": "Oxyf8IcU28J0FlEVpBhywIAMRo1gvOERMyIZ56iOdyLJSkhz4MJRo4MDR++q+gh+R2f2+4KnATUvpU4wHweZJg==" + "resolved": "6.7.3", + "contentHash": "exXUT9h++OU70jTCfQALiHzeBthqL7c5IFQm+aa67Hi/6X945t32NtOMO16TaRn44xFXdqMZ2CyMbgnTmx+w2A==" }, "System.Configuration.ConfigurationManager": { "type": "Transitive", diff --git a/REMS.Modules/Features/Agent/BL_Agent.cs b/REMS.Modules/Features/Agent/BL_Agent.cs index 5dafd39..cd1b410 100644 --- a/REMS.Modules/Features/Agent/BL_Agent.cs +++ b/REMS.Modules/Features/Agent/BL_Agent.cs @@ -63,6 +63,6 @@ public async Task> SearchAgentByNameAndLocationAs public async Task> AgentAll(int pageNumber, int pageSize) { - return await _daAgent.AgentAllAsync(pageNumber,pageSize); + return await _daAgent.AgentAllAsync(pageNumber, pageSize); } } \ No newline at end of file From 9c16df08f7c89fb0a8a1c0c20f97141b9f387ff8 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 8 Sep 2024 04:15:16 +0000 Subject: [PATCH 09/11] Fix code style issues with dotnet_format --- REMS.BackendApi/Features/Agent/AgentController.cs | 4 ++-- REMS.Modules/Features/Agent/BL_Agent.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/REMS.BackendApi/Features/Agent/AgentController.cs b/REMS.BackendApi/Features/Agent/AgentController.cs index f97086d..29f17d5 100644 --- a/REMS.BackendApi/Features/Agent/AgentController.cs +++ b/REMS.BackendApi/Features/Agent/AgentController.cs @@ -89,10 +89,10 @@ public async Task SearchAgentByNameAndLocation(SearchAgentRequest return Ok(agentList); } - [HttpGet("{pageNumber}/{pageSize}",Name = "AgentAll")] + [HttpGet("{pageNumber}/{pageSize}", Name = "AgentAll")] public async Task AgentAll(int pageNumber, int pageSize) { - Result agentList = await _blAgent.AgentAll(pageNumber,pageSize); + Result agentList = await _blAgent.AgentAll(pageNumber, pageSize); return Ok(agentList); } diff --git a/REMS.Modules/Features/Agent/BL_Agent.cs b/REMS.Modules/Features/Agent/BL_Agent.cs index 5dafd39..cd1b410 100644 --- a/REMS.Modules/Features/Agent/BL_Agent.cs +++ b/REMS.Modules/Features/Agent/BL_Agent.cs @@ -63,6 +63,6 @@ public async Task> SearchAgentByNameAndLocationAs public async Task> AgentAll(int pageNumber, int pageSize) { - return await _daAgent.AgentAllAsync(pageNumber,pageSize); + return await _daAgent.AgentAllAsync(pageNumber, pageSize); } } \ No newline at end of file From 6b146fe8f5592b06142f7b666f4e6770ac61c226 Mon Sep 17 00:00:00 2001 From: Hein Htet Date: Sun, 8 Sep 2024 18:39:29 +0630 Subject: [PATCH 10/11] UpdateTransaction --- REMS.BackendApi/Features/Transaction/TransactionController.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/REMS.BackendApi/Features/Transaction/TransactionController.cs b/REMS.BackendApi/Features/Transaction/TransactionController.cs index f2143f3..197c002 100644 --- a/REMS.BackendApi/Features/Transaction/TransactionController.cs +++ b/REMS.BackendApi/Features/Transaction/TransactionController.cs @@ -32,6 +32,7 @@ public async Task CreateTransaction(TransactionRequestModel reque [HttpGet] public async Task GetTransactions(int pageNumber = 1, int pageSize = 10) { + try { var response = await _blTransaction.GetTransactionsAsync(pageNumber, pageSize); From 39d2e715e377db1e1a112b39c038c61636db3b0a Mon Sep 17 00:00:00 2001 From: Lint Action Date: Sun, 8 Sep 2024 12:11:37 +0000 Subject: [PATCH 11/11] Fix code style issues with dotnet_format --- REMS.Modules/Features/Agent/DA_Agent.cs | 26 +++--- .../Features/Appointment/DA_Appointment.cs | 86 +++++++++---------- .../Features/Authentication/BL_Signin.cs | 6 +- .../Features/Authentication/DA_Signin.cs | 6 +- REMS.Modules/Features/Client/DA_Client.cs | 4 +- .../Features/Transaction/DA_Transaction.cs | 8 +- 6 files changed, 68 insertions(+), 68 deletions(-) diff --git a/REMS.Modules/Features/Agent/DA_Agent.cs b/REMS.Modules/Features/Agent/DA_Agent.cs index 020cb0d..6e79312 100644 --- a/REMS.Modules/Features/Agent/DA_Agent.cs +++ b/REMS.Modules/Features/Agent/DA_Agent.cs @@ -150,7 +150,7 @@ public async Task> SearchAgentByUserIdAsync(int id) model = Result.Error(ex); } - result: + result: return model; } @@ -287,18 +287,18 @@ public async Task> AgentAllAsync(int pageNumber, try { List agents = await (from ag in _db.Agents - join _user in _db.Users on ag.UserId equals _user.UserId - select new AgentDto - { - AgentId = ag.AgentId, - UserId = ag.UserId, - AgencyName = ag.AgencyName, - LicenseNumber = ag.LicenseNumber, - Email = _user.Email, - PhoneNumber = _user.Phone, - Address = ag.Address, - Role = "agent" - }).ToListAsync(); + join _user in _db.Users on ag.UserId equals _user.UserId + select new AgentDto + { + AgentId = ag.AgentId, + UserId = ag.UserId, + AgencyName = ag.AgencyName, + LicenseNumber = ag.LicenseNumber, + Email = _user.Email, + PhoneNumber = _user.Phone, + Address = ag.Address, + Role = "agent" + }).ToListAsync(); var rowCount = _db.Agents.Count(); var pageCount = rowCount / pageSize; if (pageCount % pageSize > 0) diff --git a/REMS.Modules/Features/Appointment/DA_Appointment.cs b/REMS.Modules/Features/Appointment/DA_Appointment.cs index 9baca61..8ebc150 100644 --- a/REMS.Modules/Features/Appointment/DA_Appointment.cs +++ b/REMS.Modules/Features/Appointment/DA_Appointment.cs @@ -72,26 +72,26 @@ public async Task> GetAppointmentByPropertyIdAsycn try { var query = await (from _app in _db.Appointments - join _cli in _db.Clients on _app.ClientId equals _cli.ClientId - join _pro in _db.Properties on _app.PropertyId equals _pro.PropertyId - join _age in _db.Agents on _pro.AgentId equals _age.AgentId - where _app.PropertyId == propertyId - select new AppointmentDetail - { - AgentName = _age.AgencyName, - ClientName = _cli.FirstName + " " + _cli.LastName, - AppointmentDate = _app.AppointmentDate.ToString("yyyy-MM-dd"), - AppointmentTime = _app.AppointmentTime.ToString(), - Status = _app.Status, - Note = _app.Notes, - Address = _pro.Address, - City = _pro.City, - State = _pro.State, - Price = _pro.Price, - Size = _pro.Size, - NumberOfBedrooms = _pro.NumberOfBedrooms, - NumberOfBathrooms = _pro.NumberOfBathrooms - }).ToListAsync(); + join _cli in _db.Clients on _app.ClientId equals _cli.ClientId + join _pro in _db.Properties on _app.PropertyId equals _pro.PropertyId + join _age in _db.Agents on _pro.AgentId equals _age.AgentId + where _app.PropertyId == propertyId + select new AppointmentDetail + { + AgentName = _age.AgencyName, + ClientName = _cli.FirstName + " " + _cli.LastName, + AppointmentDate = _app.AppointmentDate.ToString("yyyy-MM-dd"), + AppointmentTime = _app.AppointmentTime.ToString(), + Status = _app.Status, + Note = _app.Notes, + Address = _pro.Address, + City = _pro.City, + State = _pro.State, + Price = _pro.Price, + Size = _pro.Size, + NumberOfBedrooms = _pro.NumberOfBedrooms, + NumberOfBathrooms = _pro.NumberOfBathrooms + }).ToListAsync(); var appointmentList = query .Skip((pageNo - 1) * pageSize) .Take(pageSize).ToList(); @@ -159,29 +159,29 @@ public async Task> GetAppointmentByClientId(int cl try { var query = await (from _app in _db.Appointments - join _cli in _db.Clients on _app.ClientId equals _cli.ClientId - join _pro in _db.Properties on _app.PropertyId equals _pro.PropertyId - join _age in _db.Agents on _pro.AgentId equals _age.AgentId - join _user in _db.Users on _age.UserId equals _user.UserId - where _app.ClientId == clientId - select new AppointmentDetail - { - AppointmentId = _app.AppointmentId, - AgentName = _age.AgencyName, - ClientName = _cli.FirstName + " " + _cli.LastName, - AppointmentDate = _app.AppointmentDate.ToString("yyyy-MM-dd"), - AppointmentTime = _app.AppointmentTime.ToString(), - AgentPhoneNumber = _user.Phone, - Status = _app.Status, - Note = _app.Notes, - Address = _pro.Address, - City = _pro.City, - State = _pro.State, - Price = _pro.Price, - Size = _pro.Size, - NumberOfBedrooms = _pro.NumberOfBedrooms, - NumberOfBathrooms = _pro.NumberOfBathrooms - }).ToListAsync(); + join _cli in _db.Clients on _app.ClientId equals _cli.ClientId + join _pro in _db.Properties on _app.PropertyId equals _pro.PropertyId + join _age in _db.Agents on _pro.AgentId equals _age.AgentId + join _user in _db.Users on _age.UserId equals _user.UserId + where _app.ClientId == clientId + select new AppointmentDetail + { + AppointmentId = _app.AppointmentId, + AgentName = _age.AgencyName, + ClientName = _cli.FirstName + " " + _cli.LastName, + AppointmentDate = _app.AppointmentDate.ToString("yyyy-MM-dd"), + AppointmentTime = _app.AppointmentTime.ToString(), + AgentPhoneNumber = _user.Phone, + Status = _app.Status, + Note = _app.Notes, + Address = _pro.Address, + City = _pro.City, + State = _pro.State, + Price = _pro.Price, + Size = _pro.Size, + NumberOfBedrooms = _pro.NumberOfBedrooms, + NumberOfBathrooms = _pro.NumberOfBathrooms + }).ToListAsync(); var appointmentList = query .Skip((pageNo - 1) * pageSize) .Take(pageSize).ToList(); diff --git a/REMS.Modules/Features/Authentication/BL_Signin.cs b/REMS.Modules/Features/Authentication/BL_Signin.cs index 010fba3..fabbc2f 100644 --- a/REMS.Modules/Features/Authentication/BL_Signin.cs +++ b/REMS.Modules/Features/Authentication/BL_Signin.cs @@ -21,7 +21,7 @@ public async Task> Signin(SigninRequestModel request } model = await _daSignin.Signin(requestModel); - result: + result: return model; } @@ -73,7 +73,7 @@ public async Task> RefreshToken(RefreshTokenMo }; model = Result.Success(model.Data); - result: + result: return model; } @@ -139,7 +139,7 @@ private Result CheckRefreshTokenRequiredFields(Refres model = Result.SuccessResult(); - result: + result: return model; } } \ No newline at end of file diff --git a/REMS.Modules/Features/Authentication/DA_Signin.cs b/REMS.Modules/Features/Authentication/DA_Signin.cs index 7a61e87..f69f5d2 100644 --- a/REMS.Modules/Features/Authentication/DA_Signin.cs +++ b/REMS.Modules/Features/Authentication/DA_Signin.cs @@ -39,7 +39,7 @@ public async Task> Signin(SigninRequestModel request model = Result.Success(new SigninResponseModel(role, token)); - result: + result: return model; } @@ -77,7 +77,7 @@ public async Task> SignOut(string accessToken) await _db.SaveChangesAsync(); model = Result.Success("SignOut successful."); - result: + result: return model; } @@ -116,7 +116,7 @@ public async Task> GetRefreshTokenByUserId(int }; model = Result.Success(tokenObj); - result: + result: return model; } diff --git a/REMS.Modules/Features/Client/DA_Client.cs b/REMS.Modules/Features/Client/DA_Client.cs index 388f119..5d0ffd7 100644 --- a/REMS.Modules/Features/Client/DA_Client.cs +++ b/REMS.Modules/Features/Client/DA_Client.cs @@ -162,7 +162,7 @@ public async Task> CreateClient(ClientRequestModel requestMo model = Result.Error(ex); } - result: + result: return model; } @@ -222,7 +222,7 @@ public async Task> UpdateClient(int id, ClientRequestModel r model = Result.Error(ex); } - result: + result: return model; } diff --git a/REMS.Modules/Features/Transaction/DA_Transaction.cs b/REMS.Modules/Features/Transaction/DA_Transaction.cs index 61b380f..4445454 100644 --- a/REMS.Modules/Features/Transaction/DA_Transaction.cs +++ b/REMS.Modules/Features/Transaction/DA_Transaction.cs @@ -55,7 +55,7 @@ public async Task> CreateTransactionAsync(TransactionRequestModel model = Result.Error(ex); } - result: + result: return model; } @@ -143,7 +143,7 @@ public async Task> GetTransactionsByPropert return model = Result.Error(ex); } - result: + result: return model; } @@ -194,7 +194,7 @@ public async Task> GetTransactionsByPropert return model = Result.Error(ex); } - result: + result: return model; } @@ -245,7 +245,7 @@ public async Task> GetTransactionsByClientI return model = Result.Error(ex); } - result: + result: return model; } } \ No newline at end of file