=== Summary: 675 files | 7 generated | 484 fresh | 4605 untracked | 4268 adopted | 355 marked | 466 validated-ok | 2+0 stale (sig+body) | 0 skipped | 0 failed | elapsed 11:08:11.442 (40091.44s) ===
This commit is contained in:
@@ -12,6 +12,8 @@ namespace adas_core.Infrastructure.Repositories;
|
||||
/// providing concrete persistence operations defined by the <see cref="IPatientCarePlanRepository"/> contract.
|
||||
/// </summary>
|
||||
/// <typeparam name="PatientCarePlan">The type of the patient care plan entity managed by this repository.</typeparam>
|
||||
/// <!-- aidoc-review:v1 severity=medium kind=extra_param
|
||||
/// "<typeparam name=\"PatientCarePlan\"> is invalid because PatientCarePlanRepository is not a generic class; PatientCarePlan is a concrete type argument to MongoRepository<T>, not a type parameter." -->
|
||||
public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPatientCarePlanRepository
|
||||
{
|
||||
#region Properties
|
||||
@@ -28,6 +30,7 @@ public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPati
|
||||
/// <param name="patientid">The string identifier of the patient whose object identifiers will be updated.</param>
|
||||
/// <param name="patientId">The new <see cref="ObjectId"/> to assign to the patient's records.</param>
|
||||
/// <param name="oldId">The existing <see cref="ObjectId"/> to be replaced.</param>
|
||||
/// <!-- aidoc:v1 sig=9a63bf8 body=94ba0df -->
|
||||
public async Task UpdateManyObjectId(string patientid, ObjectId patientId, ObjectId oldId)
|
||||
{
|
||||
await UpdateManyObjectIdAsync(patientid, patientId, oldId);
|
||||
@@ -61,6 +64,7 @@ public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPati
|
||||
/// Returns the collection name for patient care plan data, using the configured setting if available or a default fallback otherwise.
|
||||
/// </summary>
|
||||
/// <returns>The patient care plan collection name from <c>_apiSettings.PatientCarePlan</c>, or <c>"patients_care_plan"</c> when the setting is null.</returns>
|
||||
/// <!-- aidoc:v1 sig=94e22ff body=c8bc19f -->
|
||||
public override string GetCollectionName()
|
||||
{
|
||||
return _apiSettings.PatientCarePlan ?? "patients_care_plan";
|
||||
@@ -72,6 +76,7 @@ public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPati
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose care plans should be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="PatientCarePlan"/> objects associated with the specified patient, or an empty list if none are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=9706d89 body=fae3443 -->
|
||||
public async Task<List<PatientCarePlan>> FindByPatientId(ObjectId patientId)
|
||||
{
|
||||
var result = await Collection.FindAsync(Builders<PatientCarePlan>.Filter.Eq(p => p.PatientId, patientId));
|
||||
@@ -83,6 +88,7 @@ public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPati
|
||||
/// </summary>
|
||||
/// <param name="userId">The unique identifier of the user whose patient care plans are being queried.</param>
|
||||
/// <returns>A list of <see cref="PatientCarePlan"/> instances matching the specified user identifier; an empty list is returned if no plans are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=7520aa9 body=3dd56f3 -->
|
||||
public async Task<List<PatientCarePlan>> FindByUserId(ObjectId userId)
|
||||
{
|
||||
var result = await Collection.FindAsync(Builders<PatientCarePlan>.Filter.Eq(p => p.UserId, userId));
|
||||
@@ -93,6 +99,7 @@ public class PatientCarePlanRepository : MongoRepository<PatientCarePlan>, IPati
|
||||
/// Retrieves all patient care plans from the data store without applying any filter.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of all <see cref="PatientCarePlan"/> records.</returns>
|
||||
/// <!-- aidoc:v1 sig=6a558a7 body=faea989 -->
|
||||
public async Task<List<PatientCarePlan>> FindAll()
|
||||
{
|
||||
var result = await Collection.Find(Builders<PatientCarePlan>.Filter.Empty).ToListAsync();
|
||||
|
||||
Reference in New Issue
Block a user