This commit is contained in:
2021-04-15 18:06:39 +00:00
parent 863323b699
commit 963a20a797

View File

@@ -1132,8 +1132,8 @@ namespace AyaNova.Biz
//TEST TEST TEST //TEST TEST TEST
if (proposedObj.Notes.Contains("₿")) if (proposedObj.Notes.Contains("₿"))
{ {
AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"Notes", "HODL!"); AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"Notes", "SAVE TEST ERROR");
} }
//Check state if updatable right now //Check state if updatable right now
@@ -1171,6 +1171,12 @@ namespace AyaNova.Biz
AddError(ApiErrorCode.NOT_FOUND, "id"); AddError(ApiErrorCode.NOT_FOUND, "id");
return; return;
} }
//TEST TEST TEST
if (obj.Notes.Contains("₿"))
{
AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"Notes", "DELETE TEST ERROR");
}
//re-check rights here necessary due to traversal delete from Principle object //re-check rights here necessary due to traversal delete from Principle object
if (!Authorized.HasDeleteRole(CurrentUserRoles, AyaType.WorkOrderItem)) if (!Authorized.HasDeleteRole(CurrentUserRoles, AyaType.WorkOrderItem))
@@ -2923,8 +2929,8 @@ namespace AyaNova.Biz
//TEST TEST TEST //TEST TEST TEST
if (proposedObj.EstimatedQuantity == 69) if (proposedObj.EstimatedQuantity == 69)
{ {
AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"EstimatedQuantity", "◈◈ TEST HODL!! ◈◈"); AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"EstimatedQuantity", "◈◈ TEST SAVE ERROR ◈◈");
} }
@@ -2964,6 +2970,12 @@ namespace AyaNova.Biz
AddError(ApiErrorCode.NOT_FOUND, "id"); AddError(ApiErrorCode.NOT_FOUND, "id");
return; return;
} }
//TEST TEST TEST
if (obj.EstimatedQuantity == 69)
{
AddError(ApiErrorCode.VALIDATION_INVALID_VALUE, $"EstimatedQuantity", "◈◈ TEST DELETE ERROR ◈◈");
}
//re-check rights here necessary due to traversal delete from Principle object //re-check rights here necessary due to traversal delete from Principle object
if (!Authorized.HasDeleteRole(CurrentUserRoles, AyaType.WorkOrderItemScheduledUser)) if (!Authorized.HasDeleteRole(CurrentUserRoles, AyaType.WorkOrderItemScheduledUser))