Interface IDisplayConfigService
- Namespace
- adas_core.Application.Services.Interfaces
- Assembly
- adas-core.Application.dll
public interface IDisplayConfigService
- Extension Methods
Methods
DeleteChartConfig(ObjectId)
Asynchronously deletes a chart configuration identified by the specified configuration display identifier.
Task<bool> DeleteChartConfig(ObjectId objectIdConfigDisplay)
Parameters
objectIdConfigDisplayObjectIdThe MongoDB.Bson.ObjectId of the chart configuration display to delete.
Returns
- Task<bool>
A task that represents the asynchronous delete operation, containing a value indicating whether the deletion was successful.
DeleteDisplayConfig(ObjectId)
Deletes a display configuration identified by the specified object identifier.
Task<bool> DeleteDisplayConfig(ObjectId objectIdConfigDisplay)
Parameters
objectIdConfigDisplayObjectIdThe unique identifier of the display configuration to delete.
Returns
- Task<bool>
A task that represents the asynchronous delete operation. The task result contains a boolean value indicating whether the display configuration was successfully deleted.
GetAll()
Retrieves all display configurations asynchronously.
Task<List<DisplayConfig>> GetAll()
Returns
- Task<List<DisplayConfig>>
A task that represents the asynchronous operation. The task result contains a list of all DisplayConfig entries.
GetAllCompact()
Asynchronously retrieves all display configurations in a compact (minimal) representation.
Task<List<DisplayConfigMinimalResponse>> GetAllCompact()
Returns
- Task<List<DisplayConfigMinimalResponse>>
A task that represents the asynchronous operation. The task result contains a list of DisplayConfigMinimalResponse objects representing the compact display configurations.
GetAllCompactPaginated(PaginationFilter)
Retrieves a paginated list of display configurations in a compact (minimal) representation.
Task<PaginationResponse<DisplayConfigMinimalResponse>> GetAllCompactPaginated(PaginationFilter request)
Parameters
requestPaginationFilterThe pagination filter that controls page size, page number, and sorting criteria.
Returns
- Task<PaginationResponse<DisplayConfigMinimalResponse>>
A task that represents the asynchronous operation, containing a PaginationResponse<T> with the compact display configuration entries.
GetById(ObjectId)
Asynchronously retrieves a DisplayConfig by its identifier.
Task<DisplayConfig> GetById(ObjectId id)
Parameters
idObjectIdThe unique identifier of the display configuration to retrieve.
Returns
- Task<DisplayConfig>
A task that represents the asynchronous operation, containing the DisplayConfig matching the specified identifier.
GetById(ObjectId?, ObjectId, DisplayType)
Asynchronously retrieves a DisplayConfig identified by the specified configuration identifier, unit identifier, and display type.
Task<DisplayConfig?> GetById(ObjectId? configId, ObjectId unitId, DisplayConfigEnums.DisplayType displayType)
Parameters
configIdObjectId?The optional identifier of the display configuration to look up; may be
nullwhen searching without a specific configuration.unitIdObjectIdThe identifier of the unit the display configuration belongs to.
displayTypeDisplayConfigEnums.DisplayTypeThe display type used to filter or scope the lookup.
Returns
- Task<DisplayConfig>
A Task<TResult> that resolves to the matching DisplayConfig, or
nullif no configuration is found.
GetByType(DisplayType)
Retrieves a list of display configurations filtered by the specified display type.
Task<List<DisplayConfig>> GetByType(DisplayConfigEnums.DisplayType type)
Parameters
typeDisplayConfigEnums.DisplayTypeThe display type used to filter the configurations.
Returns
- Task<List<DisplayConfig>>
A task that represents the asynchronous operation, containing a list of DisplayConfig objects matching the specified type.
GetCardConfigAll()
Asynchronously retrieves all card configurations.
Task<List<CardConfig>> GetCardConfigAll()
Returns
- Task<List<CardConfig>>
A task that represents the asynchronous operation. The task result contains a list of all CardConfig items.
GetCardConfigById(ObjectId)
Retrieves the card configuration associated with the specified identifier.
Returns null when no matching card configuration is found.
Task<CardConfig?> GetCardConfigById(ObjectId id)
Parameters
idObjectIdThe unique identifier of the card configuration to retrieve.
Returns
- Task<CardConfig>
A task that represents the asynchronous operation. The task result contains the CardConfig if found; otherwise,
null.
GetChartConfig(ObjectId)
Asynchronously retrieves the chart configuration associated with the specified chart identifier.
Task<ChartConfig?> GetChartConfig(ObjectId objectIdConfigChart)
Parameters
objectIdConfigChartObjectIdThe unique identifier of the chart whose configuration should be fetched.
Returns
- Task<ChartConfig>
A task that represents the asynchronous operation. The task result contains the ChartConfig associated with the provided identifier, or
nullif no configuration is found.
GetDefaultConfig(DisplayType)
Asynchronously retrieves the default display configuration for the specified display type.
Task<DisplayConfig?> GetDefaultConfig(DisplayConfigEnums.DisplayType type)
Parameters
typeDisplayConfigEnums.DisplayTypeThe display type used to look up the default configuration.
Returns
- Task<DisplayConfig>
A task that represents the asynchronous operation, containing the default DisplayConfig for the given display type, or
nullif no default configuration is available.
GetDisplayConfigLocations(ObjectId)
Retrieves the list of display configuration locations associated with the specified configuration display identifier.
Task<List<DisplayConfigLocationDto>> GetDisplayConfigLocations(ObjectId objectIdConfigDisplay)
Parameters
objectIdConfigDisplayObjectIdThe ObjectId of the configuration display whose locations are to be retrieved.
Returns
- Task<List<DisplayConfigLocationDto>>
A task that represents the asynchronous operation, containing a list of DisplayConfigLocationDto objects for the specified configuration display.
InsertCardConfig(CreateDisplayConfigCardDto)
Inserts a new card configuration using the supplied data and returns the resulting CardConfig, or null if no card config is created.
Task<CardConfig?> InsertCardConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto)
Parameters
updateDisplayConfigNameDtoCreateDisplayConfigCardDtoThe DTO containing the data used to create the display config card.
Returns
- Task<CardConfig>
A task that resolves to the inserted CardConfig, or null if the insert did not produce a card config.
InsertCardDetailConfig(CreateDisplayConfigCardDto)
Inserts a new card detail configuration based on the provided display config data.
Task<CardDetailsConfig?> InsertCardDetailConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto)
Parameters
updateDisplayConfigNameDtoCreateDisplayConfigCardDtoThe DTO containing the data required to create the card detail configuration.
Returns
- Task<CardDetailsConfig>
A task that resolves to the created CardDetailsConfig, or
nullif the configuration could not be inserted.
InsertChartConfig(CreateDisplayConfigCardDto)
Inserts a new chart configuration based on the provided display config card data.
Task<ChartConfig?> InsertChartConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto)
Parameters
updateDisplayConfigNameDtoCreateDisplayConfigCardDtoThe data transfer object containing the details of the chart configuration to create.
Returns
- Task<ChartConfig>
A task that represents the asynchronous operation, containing the newly inserted ChartConfig, or
nullif the insertion was not successful.
InsertOne(DisplayConfig)
Inserts a single display configuration asynchronously and returns the resulting configuration, or null when no record is produced.
Task<DisplayConfig?> InsertOne(DisplayConfig config)
Parameters
configDisplayConfigThe display configuration to insert.
Returns
- Task<DisplayConfig>
A task that represents the asynchronous insert operation, containing the inserted DisplayConfig or null.
InsertOneMinimal(CreateDisplayConfigDto)
Inserts a new display configuration in a minimal fashion and returns the created DisplayConfig, or null when no configuration could be produced.
Task<DisplayConfig?> InsertOneMinimal(CreateDisplayConfigDto config)
Parameters
configCreateDisplayConfigDtoThe data transfer object containing the values used to create the new display configuration.
Returns
- Task<DisplayConfig>
A Task<TResult> that yields the created DisplayConfig when successful, or
nullwhen no result is available.
InsertOneTest()
Performs a test insertion operation that returns a DisplayConfig instance, used to validate insertion behavior.
Task<DisplayConfig> InsertOneTest()
Returns
- Task<DisplayConfig>
A Task<TResult> representing the asynchronous test insertion result.
InsertOneWithTemplate(string, DisplayType, string?)
Inserts a new display configuration record using a predefined template, optionally scoped to a specific hospital context.
Task<DisplayConfig?> InsertOneWithTemplate(string objectId, DisplayConfigEnums.DisplayType configType, string? configHospital)
Parameters
objectIdstringThe identifier of the object the display configuration is associated with.
configTypeDisplayConfigEnums.DisplayTypeThe type of display configuration template to use for the insertion.
configHospitalstringThe optional hospital identifier used to scope the configuration; may be null when the configuration is not hospital-specific.
Returns
- Task<DisplayConfig>
A task that represents the asynchronous operation, containing the inserted DisplayConfig, or null if the configuration could not be created.
UpdateBaseConfig(DisplayConfig)
Updates the base display configuration with the specified settings.
Task<bool> UpdateBaseConfig(DisplayConfig baseConfig)
Parameters
baseConfigDisplayConfigThe display configuration to apply as the new base configuration.
Returns
- Task<bool>
A task that represents the asynchronous update operation. The task result contains a boolean value indicating whether the update was successful.
UpdateCardConfig(CardConfig)
Updates the card configuration based on the provided settings.
Task<bool> UpdateCardConfig(CardConfig baseConfig)
Parameters
baseConfigCardConfigThe card configuration to be updated.
Returns
- Task<bool>
A task that represents the asynchronous operation. The task result contains a boolean value indicating whether the update was successful.
UpdateChartConfig(ChartConfig)
Asynchronously updates the chart configuration based on the provided base configuration and returns a value indicating whether the update was successful.
Task<bool> UpdateChartConfig(ChartConfig baseConfig)
Parameters
baseConfigChartConfigThe base chart configuration to apply during the update.
Returns
- Task<bool>
A task that represents the asynchronous operation. The result is
trueif the chart configuration was updated successfully; otherwise,false.
UpdateConfig(ObjectId, object)
Updates the display configuration identified by the specified identifier with the provided new configuration data.
Task<DisplayConfig?> UpdateConfig(ObjectId displayConfigId, object newDisplayConfig)
Parameters
displayConfigIdObjectIdThe unique identifier of the display configuration to update.
newDisplayConfigobjectThe new display configuration data to apply to the existing configuration.
Returns
- Task<DisplayConfig>
The updated DisplayConfig, or
nullif no display configuration with the specified identifier is found.
UpdateConfigColor(ObjectId, ColorConfig)
Updates the color configuration for the specified config display.
Task<bool> UpdateConfigColor(ObjectId objectIdConfigDisplay, ColorConfig colorConfigDto)
Parameters
objectIdConfigDisplayObjectIdThe identifier of the config display whose color configuration will be updated.
colorConfigDtoColorConfigThe color configuration data to apply to the config display.
Returns
- Task<bool>
A task that represents the asynchronous operation. The task result contains
trueif the update was successful; otherwise,false.
UpdateDetailConfig(CardDetailsConfig)
Asynchronously updates the card details configuration based on the provided base configuration.
Task<bool> UpdateDetailConfig(CardDetailsConfig baseConfig)
Parameters
baseConfigCardDetailsConfigThe base card details configuration to apply during the update.
Returns
- Task<bool>
A task that represents the asynchronous operation, containing a boolean value indicating whether the update was successful.
UpdateDisplayConfigHospitalName(ObjectId, string)
Asynchronously updates the hospital name associated with the specified display configuration.
Task<bool> UpdateDisplayConfigHospitalName(ObjectId objectIdConfigDisplay, string name)
Parameters
objectIdConfigDisplayObjectIdThe identifier of the display configuration whose hospital name will be updated.
namestringThe new hospital name to apply to the display configuration.
Returns
UpdateFieldList(ObjectId, List<Field>)
Updates the list of fields associated with the specified configuration display.
Task<bool> UpdateFieldList(ObjectId objectIdConfigDisplay, List<Field> fields)
Parameters
objectIdConfigDisplayObjectIdThe identifier of the configuration display whose field list will be updated.
fieldsList<Field>The list of fields to be applied to the configuration display.
Returns
- Task<bool>
A task that represents the asynchronous operation. The task result contains a value indicating whether the update was successful.
UpdateHeaderConfig(ObjectId, HeaderConfig)
Asynchronously updates the header configuration associated with the specified config display identifier.
Task<bool> UpdateHeaderConfig(ObjectId objectIdConfigDisplay, HeaderConfig headerConfig)
Parameters
objectIdConfigDisplayObjectIdThe identifier of the config display whose header configuration will be updated.
headerConfigHeaderConfigThe new header configuration to apply.
Returns
- Task<bool>
A task that represents the asynchronous operation. The task result contains
trueif the update was successful; otherwise,false.
UpdateSetHomeBanner(ObjectId, List<BannerItem>)
Updates the home banner configuration for the specified config display with the provided list of banner items.
Task<bool> UpdateSetHomeBanner(ObjectId objectIdConfigDisplay, List<BannerItem> bannerItems)
Parameters
objectIdConfigDisplayObjectIdThe identifier of the config display whose home banner will be updated.
bannerItemsList<BannerItem>The list of banner items to set as the home banner configuration.