* Removing obsoleted code from ApiMediaQueryService.cs
* Removing obsoleted code from ApiRichTextMarkupParserTests.cs
* Removing obsoleted code from ContentCacheRefresher.cs
* Removing obsoleted code from ContentFinderByUrlAlias.cs and adjusting its tests to use the new logic
* Removing obsoleted code from ContentFinderByUrl.cs & its dependencies
* Removing obsoleted code from ApiRichTextMarkupParserTests.cs
* Removing obsoleted code from DocumentCache.cs & its dependencies
* Removing obsoleted code from MediaCache.cs & its dependencies
* Removing obsoleted code from PublishedCacheBase.cs & its dependencies
* Removing obsoleted code from RenderNoContentController.cs and its tests
* Removing obsoleted code from UmbracoRouteValueTransformer.cs
* Removing obsoleted constructors from DefaultUrlProvider.cs
* Removing the RadioValueEditor.cs & RadioValueValidator.cs obsoleted classes.
* Removing obsolete constructor from MultipleValueValidator.cs
* Removing obsolete constructor from EmailValidator.cs
* Removing obsoleted code from DataValueReferenceFactoryCollection.cs
* Removing obsoleted code from ApiContentBuilderBase.cs
* Fixing constructor missing attribute
* Making use of the TryGet result
* Fixing use of obsoleted constructor
* Removing silly bookmark comment
* Fixing deleted code and restructuring to use new cache
* Making use of TryGetRootKeys bool, to return null if false.
* Extending code to use new constructor
* Updated PublishedContentQuery.cs to return empty array
Co-authored-by: Nikolaj Geisle <70372949+Zeegaan@users.noreply.github.com>
---------
Co-authored-by: Nikolaj Geisle <70372949+Zeegaan@users.noreply.github.com>
* Removing obsoleted code from MigrationPlanExecutor.cs & Interface
* Removing obsoleted code from EmailAddressPropertyEditor.cs
* Removing obsoleted class CacheRebuilder.cs
* Removing obsoleted code from TextBuilder.cs
* Removing obsoleted class ICacheRebuilder.cs
* Removing obsoleted code from SerilogLogger.cs
* Removing the use of Infrastructure IBackgroundTaskQueue.cs and replacing usage with the Core replacement
* Removing obsoleted code from the FileUploadPropertyEditor.cs
* Removing obsoleted code from BlockValuePropertyValueEditorBase.cs
* Removing obsoleted constructors and methods from MultiNodeTreePickerPropertyEditor.cs and TextHeaderWriter.cs
* Removing obsoleted code from CacheInstructionService.cs
* Bumping obsoleted code from MigrationBase.cs to V18
* Removing obsoleted code from EmailSender.cs
* Removing obsoleted code from BlockEditorVarianceHandler.cs
* Removing obsoleted code from IBackOfficeApplicationManager.cs
* Removing obsoleted code from RedirectTracker.cs & RichTextEditorPastedImages.cs
* Persist and expose Umbraco system dates as UTC (#19705)
* Updated persistence DTOs defining default dates to use UTC.
* Remove ForceToUtc = false from all persistence DTO attributes (default when not specified is true).
* Removed use of SpecifyKind setting dates to local.
* Removed unnecessary Utc suffixes on properties.
* Persist current date time with UtcNow.
* Removed further necessary Utc suffixes and fixed failing unit tests.
* Added migration for SQL server to update database date default constraints.
* Added comment justifying not providing a migration for SQLite default date constraints.
* Ensure UTC for datetimes created from persistence DTOs.
* Ensure UTC when creating dates for published content rendering in Razor and outputting in delivery API.
* Fixed migration SQL syntax.
* Introduced AuditItemFactory for creating entries for the backoffice document history, so we can control the UTC setting on the retrieved persisted dates.
* Ensured UTC dates are retrieved for document versions.
* Ensured UTC is returned for backoffice display of last edited and published for variant content.
* Fixed SQLite syntax for default current datetime.
* Apply suggestions from code review
Co-authored-by: Laura Neto <12862535+lauraneto@users.noreply.github.com>
* Further updates from code review.
---------
Co-authored-by: Laura Neto <12862535+lauraneto@users.noreply.github.com>
* Migrate system dates from local server time to UTC (#19798)
* Add settings for the migration.
* Add migration and implement for SQL server.
* Implement for SQLite.
* Fixes from testing with SQL Server.
* Fixes from testing with SQLite.
* Code tidy.
* Cleaned up usings.
* Removed audit log date from conversion.
* Removed webhook log date from conversion.
* Updated update date initialization on saving dictionary items.
* Updated filter on log queries.
* Use timezone ID instead of system name to work cross-culture.
---------
Co-authored-by: Laura Neto <12862535+lauraneto@users.noreply.github.com>
* Create sign provider collection and call registered providers on rendering a page of tree item view models.
Re-work tree controller constructors to provide registered providers as a collection.
* Stub implementation of sign provider for documents with a scheduled publish pending.
* Complete implementation of tree sign for pending scheduled publish.
* Added integration test for new method on IContentService.
* Added unit test for HasScheduleSignProvider.
* Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Tidied usings and clarified method header comments.
* Adding a fixed prefix to all future signs, and removing the provider property
* Adding a sign for protected tree documents.
* Adding IsProtectedSignProviderTest.cs & correcting HasScheduleSignProviderTests.cs to no longer assert the provider
* Fixing minor things in accordance with CR
* Adding collection items compatibility
* Introduced IHasSigns interface to provide more re-use across trees and collections.
Fixed updates to base content controllers (no need to introduce a new type variable).
Removed passing entities for populating tree signs (we aren't using it, so simplifies things).
* Refactoring a bit to make existing code less duplicated and fixing some constructor obsoletion
* Introducing a has pending changes sign.
* Applying changes based on CR
* Introducing tests for HasPendingChangesSignProvider.cs and stopped the use of contentService
* Introducing tests for HasPendingChangesSignProvider.cs and slight logic change
* Introduced HasCollectionSignProvider.cs and tests.
* Introducing collection signs to Media Tree & Media Collection items
* Introducing Plain Items and tests. Refactoring tests as well
* Introduced alternative CanProvideSigns() implementation on IsProtectedSignProvider.cs
* Slight refactoring to reduce bloating.
* Adding [ActivatorUtilitiesConstructor] since it threw an error otherwise
* Minor cleanup.
* Updated OpenApi.json.
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: NillasKA <kramernicklas@gmail.com>
* fix some test which are not running
* resolve code review comments
* Moved cleaned up tests to unit tests (as they are unit tests, not integration tests).
Removed tests marked as no longer necessary.
Update tests name to better reflect test case.
* Made explict test faster so it could run on the pipeline.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
Bind 'action-executed' event handler to class instance
Updated the event listener for 'action-executed' to bind the handler to the class instance, ensuring correct 'this' context when the event is triggered.
* Added configuration option UseStrictDomainMatching, which allows control over whether content is routed without a matching domain.
* Fixed typo in comment.
* Addressed comments from code review.
* Optimize document and media seeding by looking up from database in batches.
* Ensure null values aren't stored in the cache when checking existance.
* Fixed failing integration tests.
* Resolved issue with not writing to the L1 cache on an L2 hit.
* Tidied up and populated XML header comments.
* Address issue raised in code review.
* Content picker search with start node configured not taking user start nodes into account (#19800)
* Fix users being able to see nodes they don't have access to when using the picker search
* Readability and naming improvements
* Additional fixes
* Adjust tests
* Additional fixes
* Small improvement
* Replaced the root ids with constants
* Update src/Umbraco.Web.BackOffice/Trees/MemberTreeController.cs
Co-authored-by: Andy Butland <abutland73@gmail.com>
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
# Conflicts:
# src/Umbraco.Examine.Lucene/BackOfficeExamineSearcher.cs
# src/Umbraco.Web.BackOffice/Trees/ContentTreeController.cs
# src/Umbraco.Web.BackOffice/Trees/MediaTreeController.cs
# src/Umbraco.Web.BackOffice/Trees/MemberTreeController.cs
# tests/Umbraco.Tests.Integration/Umbraco.Examine.Lucene/UmbracoExamine/BackOfficeExamineSearcherTests.cs
* Add new constructor without unused and obsolete parameters
* Use non obsolete constructor in tests
* Add `dataTypeId` as parameter in document and media search endpoints to get `ignoreUserStartNodes` value
* Update backend API generated typed client
* Updated picker search to pass in data type unique
* Move data type retrieval to UmbPickerContext
* Adjust the controller constructors to make it non breaking
* Adjust controller methods to make non-breaking.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Fix moving properties between groups sometimes clearing their values
* Small adjustment
* Fix failing integration test
The mapping method was only setting the property group when it was not null, but for orphaned properties we want to specifically set it to null.
* Adjust 'Can_Move_Properties_To_Another_Container' integration test to check more scenarios and that values are kept
* Adjust to add isElement variable in test (as previously)
* Added tests for updating a variant block list with invalid text
* Added tests for updating a variant block grid with invalid text
* Bumped version of test helper
* Make the tests for updating content with invalid text in a block run in the pipeline
* Cleaned up
* Updated test text
* Reverted npm command
* Removed two unnecessary delete clauses when removing content types (they are looking for user group Ids, but we are deleting a content type).
* Renamed table name constant with obsoletion to better reflect name and contents of table.
* Added granular permission for property value records to delete clauses when deleting a document type.
* Delete property value permissions for removed property types.
* Added integration tests to verify behaviour.
* Adds support for the "folders only" flag on retrieving siblings of a node.
* Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Updated test code.
* Removed double secondary ordering by node Id and ensured we include this clause for all sort orders.
* Ensure that ordering by node Id is always added only once and last, and only if it's not already been included in the order by clause.
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Updated the block editor validation message
* Updated tests for schedule publishing after unselecting all languages
* Added tests for sibdlingsOfType extension
* Updated tests due to test helper changes
* Bumped version of test helper
* Added release tag for regression issue
* Make tests for siblingsOfType run in the pipeline
* Reverted npm command
* Provides an abstraction for creating the JavaScriptEncoder used in SystemTextConfigurationEditorJsonSerializer.
* Generalised JSON serialization encoder factory to work for all System.Tex.Json serializers.
Added the serializer's name as a parameter to allow for different encodings per serializer if required.
* Fixed tests by removing use of obsolete constructors.
* Removed name parameter and used a generic type instead.
* Removed this as these tests are covered in other files
* Added release tags
* Make all tests with @smoke and @release tags run in the pipeline
* Updated npx command
* Updated npx command
* Updated npx command
* Fixed failed tests related to document type folder
* Cleaned up
* Used grep in yaml file instead of package.json file
* Updated yml file
* Updated testCommand
* Fixed command
* Added releaseTest command
* Added another job to run regression test in the release build
* Fixed comments
* Updated name of test job
* Make all release tests run in the pipeline
* Updated warning message
* Reverted npm command
* Updated relation type tests
* Created tests
* Bumped version
* Fixed tests
* Fixed tests
* Fixes based on comments
* Added waits to figure out why tests fail on pipeline
* Added a reload to check if test passes on pipeline
* Added reloads
* Removed reload page
* Reverted smokeTest command
* Added user start node restrictions to sibling endpoints.
* Further integration tests.
* Tidy up.
* Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Revert previous update.
* Retrieves item counts before and after the target for sibling endpoints and returns in API response.
* Applied previous update correctly.
* Removed blank line.
* Fix build and test asserts following merge.
* Update OpenApi.json.
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: mole <nikolajlauridsen@protonmail.ch>
* Cleanup obsoleted methods
* Add a way to disable UmbracoFile default sink
* Abstract LogViewService so only UmbracoFile sink related things are in the default interface implementation.
* Abstract LogViewRepository so only UmbracoFile sink related things are in the default interface implementation.
* Move GetGlobalLogLevelEventMinLevel to base
* Removed unused internal class and obsoleted its base
* Added missing XML header comments and resolved warnings in service and repository classes.
* Made private method static.
* Addressed issues raised in code review.
* Expose repository from the service base class.
* Restored further obsoleted code we can't remove yet.
* Removed log viewer tests on removed class. We have integration tests for the new service.
* Obsoleted ILogViewer interface.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Updated nightly E2E pipeline
* Fixed failing E2E tests
* Skipped content tests wirh list view content due to an issue
* Updated tests due to UI changes
* Updated fixme and skip tests - part 1
* Removed this file because the tests are already covered elsewhere
* Updated fixme() tests
* Updated skip() tests
* Bumped version
* Bumped version
* Bumped version
* Removed notification verification
* Removed the step to verify the notification for save action
* Fixed the failing tests
* Updated name of permission
* Bumped version
* Fixed failing tests
* Bumped testHelpers
* Removed tests related to tiptap toolbar as they are covered in another class
* Cleaned up
* Added more waits
* Cleaned up
* Added step to ensure redirect URL is created when renaming content.
* Restructured the tests
* Removed unnecessary steps
* Fixed isItemVisibleInRecycleBin
* Fixed isItemVisibleInRecycleBin
* Bumped version
* Added more wait for the deletion to complete
* Added waits for the deletion to complete
* Added more waits
* Removed unnecessary waits
* Added more waits to improve test stability
* Added skip for the flaky test
* Added test for removing a stylesheet in a block grid editor
* Updated test due to api helper changes
* Bumped version
* Fixed failing smoke test
---------
Co-authored-by: Andreas Zerbst <andr317c@live.dk>
* Removed `cursor: not-allowed` style
* Sets the `umb-rte-block` `user-select` to `all`
* Adds an "invisible" selection background to `umb-ref-rte-block`
* Sets the `umb-ufm-render` text-content to be visible
* Adds `aria-hidden` attribute
* Bumped version of test helper
* Fixed the failing tests due to UI changes
* Adds `pointer-events: none` to selection-background
---------
Co-authored-by: Nhu Dinh <hnd@umbraco.dk>
* Updated tests for content with RTE in a block grid
* Updated tests forcontent with RTE in a block list
* Make all RTE tests run in the pipeline
* Cleaned up
* Reverted npm command
* Fix nullability of Children extension
* Fix nullability of methods throughout the CMS
* Fix return types of some methods that cannot return null
* Revert nullable changes to result of ConvertSourceToIntermediate for property editors (whilst some property editors we know won't return null, it seems more consistent to adhere to the base class and interface nullability definition).
* Updated new webhook events to align with new nullability definitions.
* Reverted content editing service updates to align with base classes.
* Applied collection nullability updates on content repository to interface.
* Reverted value converter updates to match interface.
* Applied further collection updates to interface.
* Aligned media service interface with implementation for nullability.
* Update from code review.
---------
Co-authored-by: Ivo van der Bruggen <ivo@dutchbreeze.com>
Co-authored-by: Ivo van der Bruggen <ivo@vdbruggensoftware.com>
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Add integration tests that shows the problem
* Fix the problem and add explenation
* Improved comments slightly to help when we come back here!
Moved tests alongside existing ones related to scopes.
Removed long running attribute from tests (they are quite fast).
* Fixed casing in comment.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Introduce new AuditEntryService
- Moved logic related to the IAuditEntryRepository from the AuditService to the new service
- Introduced new Async methods
- Using ids (for easier transition from the previous Write method)
- Using keys
- Moved and updated integration tests related to the audit entries to a new test class `AuditEntryServiceTests`
- Added unit tests class `AuditEntryServiceTests` and added a few unit tests
- Added migration to add columns for `performingUserKey` and `affectedUserKey` and convert existing user ids
- Adjusted usages of the old AuditService.Write method to use the new one (mostly notification handlers)
* Audit service rework
- Added new async and paged methods
- Marked (now) redundant methods as obsolete
- Updated all of the usages to use the non-obsolete methods
- Added unit tests class `AuditServiceTests` and some unit tests
- Updated existing integration test
* Use the audit service instead of the repository directly in services
* Apply suggestions from code review
* Small improvement
* Update src/Umbraco.Core/Services/AuditService.cs
* Some minor adjustments following the merge
* Delete unnecessary file
* Small cleanup on the tests
* Remove changing user id to 0 (on audit) if user id is admin in media bulk save
* Remove reference to unused IUserIdKeyResolver in TemplateService
* Remove references to unused IShortStringHelper and GlobalSettings in FileService
* Started implementing new LongRunningOperationService and adjusting tasks to use this service
This service will manage operations that require status to be synced between servers (load balanced setup).
* Missing migration to add new lock. Other simplifications.
* Add job to cleanup the LongRunningOperations entries
* Add new DatabaseCacheRebuilder.RebuildAsync method
This is both async and returns an attempt, which will fail if a rebuild operation is already running.
* Missing LongRunningOperation database table creation on clean install
* Store expire date in the long running operation. Better handling of non-background operations.
Storing an expiration date allows setting different expiration times depending on the type of operation, and whether it is running in the background or not.
* Added integration tests for LongRunningOperationRepository
* Added unit tests for LongRunningOperationService
* Add type as a parameter to more repository calls. Distinguish between expiration and deletion in `LongRunningOperationRepository.CleanOperations`.
* Fix failing unit test
* Fixed `PerformPublishBranchAsync` result not being deserialized correctly
* Remove unnecessary DatabaseCacheRebuildResult value
* Add status to `LongRunningOperationService.GetResult` attempt to inform on why a result could not be retrieved
* General improvements
* Missing rename
* Improve the handling of long running operations that are not in background and stale operations
* Fix failing unit tests
* Fixed small mismatch between interface and implementation
* Use the new submit and poll functionality for the Examine index rebuild
* Use a fire and forget task instead of the background queue
* Apply suggestions from code review
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Make sure exceptions are caught when running in the background
* Alignment with other repositories (async + pagination)
* Fix build after merge
* Missing obsoletion messages
* Additional fixes
* Add Async suffix to service methods
* Missing adjustment
* Moved hardcoded settings to IOptions
* Fix issue in SQL Server where 0 is not accepted as requested number of rows
* Fix issue in SQL Server where query provided to count cannot contain orderby
* Additional SQL Server fixes
* Update method names
* Adjustments from code review
* Ignoring result of index rebuild in `IndexingNotificationHandler.Language.cs` (same behavior as before)
* Missed some obsoletion messages
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Remove skip
* Added tests for creating and updating content
* Removed skip because the issue is fixed
* Updated assertion steps for the update document user permission
* Bumped version
* Added release tag
---------
Co-authored-by: Nikolaj Geisle <70372949+Zeegaan@users.noreply.github.com>
* Started implementing new LongRunningOperationService and adjusting tasks to use this service
This service will manage operations that require status to be synced between servers (load balanced setup).
* Missing migration to add new lock. Other simplifications.
* Add job to cleanup the LongRunningOperations entries
* Add new DatabaseCacheRebuilder.RebuildAsync method
This is both async and returns an attempt, which will fail if a rebuild operation is already running.
* Missing LongRunningOperation database table creation on clean install
* Store expire date in the long running operation. Better handling of non-background operations.
Storing an expiration date allows setting different expiration times depending on the type of operation, and whether it is running in the background or not.
* Added integration tests for LongRunningOperationRepository
* Added unit tests for LongRunningOperationService
* Add type as a parameter to more repository calls. Distinguish between expiration and deletion in `LongRunningOperationRepository.CleanOperations`.
* Fix failing unit test
* Fixed `PerformPublishBranchAsync` result not being deserialized correctly
* Remove unnecessary DatabaseCacheRebuildResult value
* Add status to `LongRunningOperationService.GetResult` attempt to inform on why a result could not be retrieved
* General improvements
* Missing rename
* Improve the handling of long running operations that are not in background and stale operations
* Fix failing unit tests
* Fixed small mismatch between interface and implementation
* Use a fire and forget task instead of the background queue
* Apply suggestions from code review
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Make sure exceptions are caught when running in the background
* Alignment with other repositories (async + pagination)
* Additional fixes
* Add Async suffix to service methods
* Missing adjustment
* Moved hardcoded settings to IOptions
* Fix issue in SQL Server where 0 is not accepted as requested number of rows
* Fix issue in SQL Server where query provided to count cannot contain orderby
* Additional SQL Server fixes
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Return 404 on delivery API requests for segments that are invalid or not created.
* Handled case with no segmented properties.
* Let the property decide if it has a value or not
---------
Co-authored-by: kjac <kja@umbraco.dk>
* Add a backing field for EditorUIAlias and track changes when its set.
* Add previously failing unit test to verify fix.
* Aligned backing field casing with property name.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Added tests for creating content using document blueprint
* Updated tests due to api helper for document blueprint changes
* Bumped version
* Make all Blueprint tests runs in the pipeline
* Reverted npm command