Skip to content

Commit

Permalink
Remove SonarClour code quality errors
Browse files Browse the repository at this point in the history
  • Loading branch information
tatarincev committed May 17, 2018
1 parent 9b0ece0 commit 5b0031c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,7 @@ public virtual void SaveChanges(CustomerOrder[] orders)
{
EnsureThatAllOperationsHaveNumber(order);

var originalEntity = dataExistOrders.FirstOrDefault(x => x.Id == order.Id);
var originalOrder = originalEntity != null ? (CustomerOrder)originalEntity.ToModel(AbstractTypeFactory<CustomerOrder>.TryCreateInstance()) : order;

var originalEntity = dataExistOrders.FirstOrDefault(x => x.Id == order.Id);
//Calculate order totals
TotalsCalculator.CalculateTotals(order);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,15 @@
blade.customInitialize = function () {
blade.isLocked = blade.currentEntity.status == 'Completed' || blade.currentEntity.isCancelled;

var orderLineItemsBlade = {
id: 'customerOrderItems',
currentEntity: blade.currentEntity,
recalculateFn: blade.recalculate,
controller: 'virtoCommerce.orderModule.customerOrderItemsController',
template: 'Modules/$(VirtoCommerce.Orders)/Scripts/blades/customerOrder-items.tpl.html'
};
//Display order items disabled by default
// bladeNavigationService.showBlade(orderLineItemsBlade, blade);
//var orderLineItemsBlade = {
// id: 'customerOrderItems',
// currentEntity: blade.currentEntity,
// recalculateFn: blade.recalculate,
// controller: 'virtoCommerce.orderModule.customerOrderItemsController',
// template: 'Modules/$(VirtoCommerce.Orders)/Scripts/blades/customerOrder-items.tpl.html'
//};
//Display order items disabled by default
// bladeNavigationService.showBlade(orderLineItemsBlade, blade);
};


Expand Down

0 comments on commit 5b0031c

Please sign in to comment.