Skip to content

Commit b24d347

Browse files
authored
Merge pull request #419 from TechnologyEnhancedLearning/RC
Merge RC changes to scoripus
2 parents 0b66acc + 4001d30 commit b24d347

File tree

17 files changed

+1219
-402
lines changed

17 files changed

+1219
-402
lines changed

LearningHub.Nhs.WebUI/Controllers/Api/ContributeController.cs

Lines changed: 83 additions & 76 deletions
Large diffs are not rendered by default.

LearningHub.Nhs.WebUI/Services/FileService.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ private async Task MoveOutPutDirectoryToArchive(List<string> allDirectoryRef)
309309
}
310310
}
311311

312-
await directory.DeleteAsync();
312+
await directory.DeleteIfExistsAsync();
313313
}
314314
}
315315
}
@@ -365,6 +365,8 @@ private async Task DeleteSubdirectory(string pathDirectory)
365365
await sourceFileClient.DeleteIfExistsAsync();
366366
}
367367
}
368+
369+
await sourceDirectory.DeleteIfExistsAsync();
368370
}
369371

370372
private async Task MoveInPutDirectoryToArchive(List<string> allDirectoryRef)

WebAPI/LearningHub.Nhs.API/Controllers/ContentServerController.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,11 @@ public ContentServerController(
4545
/// <returns>The <see cref="IActionResult"/>.</returns>
4646
[HttpPost]
4747
[Route("GetContentDetailsByExternalUrl")]
48-
public IActionResult GetContentDetailsByExternalUrl([FromBody] string externalUrl)
48+
public async Task<IActionResult> GetContentDetailsByExternalUrl([FromBody] string externalUrl)
4949
{
5050
string decodedUrl = HttpUtility.UrlDecode(externalUrl);
5151

52-
var details = this.scormContentServerService.GetContentDetailsByExternalUrl(decodedUrl);
52+
var details = await this.scormContentServerService.GetContentDetailsByExternalUrl(decodedUrl);
5353

5454
return this.Ok(details);
5555
}
@@ -61,9 +61,9 @@ public IActionResult GetContentDetailsByExternalUrl([FromBody] string externalUr
6161
/// <returns>The <see cref="IActionResult"/>.</returns>
6262
[HttpGet]
6363
[Route("GetContentDetailsByExternalReference/{externalReference}")]
64-
public IActionResult GetContentDetailsByExternalReference(string externalReference)
64+
public async Task<IActionResult> GetContentDetailsByExternalReference(string externalReference)
6565
{
66-
var details = this.scormContentServerService.GetContentDetailsByExternalReference(externalReference);
66+
var details = await this.scormContentServerService.GetContentDetailsByExternalReference(externalReference);
6767

6868
return this.Ok(details);
6969
}

WebAPI/LearningHub.Nhs.API/Controllers/ResourceController.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -496,9 +496,9 @@ public async Task<ActionResult> GetScormDetailsAsync(int resourceVersionId)
496496
/// <param name="resourceVersionId">The resourceVersionId<see cref="int"/>.</param>
497497
/// <returns>The <see cref="Task{ActionResult}"/>.</returns>
498498
[HttpGet("GetExternalContentDetailsById/{resourceVersionId}")]
499-
public ActionResult GetScormContentDetailsById(int resourceVersionId)
499+
public async Task<ActionResult> GetScormContentDetailsById(int resourceVersionId)
500500
{
501-
return this.Ok(this.resourceService.GetExternalContentDetails(resourceVersionId, this.CurrentUserId));
501+
return this.Ok(await this.resourceService.GetExternalContentDetails(resourceVersionId, this.CurrentUserId));
502502
}
503503

504504
/// <summary>

WebAPI/LearningHub.Nhs.Database/LearningHub.Nhs.Database.sqlproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -513,6 +513,7 @@
513513
<Build Include="Stored Procedures\Activity\GetUserLearningActivities.sql" />
514514
<Build Include="Stored Procedures\Activity\GetUserLearningActivitiesCount.sql" />
515515
<None Include="Scripts\Post-Deploy\Scripts\TD-2929_ActivityStatusUpdates.sql" />
516+
<Build Include="Stored Procedures\Resources\BlockCollectionFileSearch.sql" />
516517
</ItemGroup>
517518
<ItemGroup>
518519
<None Include="Scripts\Pre-Deploy\Scripts\Card5766_AuthorTableChanges.PreDeployment.sql" />

0 commit comments

Comments
 (0)