Skip to content

Commit

Permalink
Merge branch 'release/3.827.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
vc-ci committed Sep 18, 2024
2 parents be0d0d2 + b4f9d32 commit dab1980
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<Project>
<!-- These properties will be shared for all projects -->
<PropertyGroup>
<VersionPrefix>3.826.0</VersionPrefix>
<VersionPrefix>3.827.0</VersionPrefix>
<VersionSuffix>
</VersionSuffix>
<VersionSuffix Condition=" '$(VersionSuffix)' != '' AND '$(BuildNumber)' != '' ">$(VersionSuffix)-$(BuildNumber)</VersionSuffix>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -621,6 +621,12 @@ public async Task<ActionResult> GetInvoicePdf(string orderNumber)
throw new InvalidOperationException($"Cannot find order with number {orderNumber}");
}

var authorizationResult = await _authorizationService.AuthorizeAsync(User, order, new OrderAuthorizationRequirement(ModuleConstants.Security.Permissions.Read));
if (!authorizationResult.Succeeded)
{
return Forbid();
}

var notification = await _notificationSearchService.GetNotificationAsync<InvoiceEmailNotification>(new TenantIdentity(order.StoreId, nameof(Store)));
notification.CustomerOrder = order;
notification.LanguageCode = order.LanguageCode;
Expand Down Expand Up @@ -718,6 +724,12 @@ public ActionResult GetOrderFullTextSearchEnabled()
[Route("indexed/search")]
public async Task<ActionResult<CustomerOrderSearchResult>> SearchCustomerOrderIndexed([FromBody] CustomerOrderIndexedSearchCriteria criteria)
{
var authorizationResult = await _authorizationService.AuthorizeAsync(User, criteria, new OrderAuthorizationRequirement(ModuleConstants.Security.Permissions.Read));
if (!authorizationResult.Succeeded)
{
return Forbid();
}

var result = await _indexedSearchService.SearchCustomerOrdersAsync(criteria);
return Content(JsonConvert.SerializeObject(result, _outputJsonSerializerSettings), "application/json");
}
Expand Down
2 changes: 1 addition & 1 deletion src/VirtoCommerce.OrdersModule.Web/module.manifest
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<module>
<id>VirtoCommerce.Orders</id>
<version>3.826.0</version>
<version>3.827.0</version>
<version-tag />

<platformVersion>3.851.0</platformVersion>
Expand Down

0 comments on commit dab1980

Please sign in to comment.