Class MembershipCheckPriceCategoriesTask
java.lang.Object
ch.tocco.nice2.optional.order.api.action.invoice.tasks.AbstractOrderGeneratorCheckTask
ch.tocco.nice2.optional.membershiporder.impl.action.invoice.tasks.MembershipCheckPriceCategoriesTask
- All Implemented Interfaces:
OrderGeneratorCheckTask
,PersistTask<Tuple2<InvoicePropertiesContribution,
Collection<Entity>>, String>
-
Constructor Summary
ConstructorDescriptionMembershipCheckPriceCategoriesTask
(DefaultDisplayService defaultDisplayService, TextResources textResources, MembershipPriceCategoryService membershipPriceCategoryService) -
Method Summary
Modifier and TypeMethodDescriptionboolean
doesEntityFail
(InvoicePropertiesContribution properties, Entity entity) checks if an entity fails the check task this must be overwritten when using the check task in the new client action check tasks may still work in legacy client without this method, but may not call it in theirOrderGeneratorCheckTask.run(CommandContext, InvoicePropertiesContribution, Collection)
methodmapEntityForDisplay
(InvoicePropertiesContribution properties, Entity entity) decide which entity should be displayed in the error message@Nullable String
run
(CommandContext commandContext, InvoicePropertiesContribution properties, Collection<Entity> entities) Methods inherited from class ch.tocco.nice2.optional.order.api.action.invoice.tasks.AbstractOrderGeneratorCheckTask
getFailingEntities, getFailingEntityDefaultDisplays, run, streamFailingEntities
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface ch.tocco.nice2.persist.core.api.exec.PersistTask
andThenDo, compose, compose2, composeWhen, discardResult, expand, expand, getDescription, ifElse, orWhen, orWhenNot, passWhen, passWhenNot, skipErrors, unwrap
-
Constructor Details
-
MembershipCheckPriceCategoriesTask
public MembershipCheckPriceCategoriesTask(DefaultDisplayService defaultDisplayService, TextResources textResources, MembershipPriceCategoryService membershipPriceCategoryService)
-
-
Method Details
-
run
@Nullable public @Nullable String run(CommandContext commandContext, InvoicePropertiesContribution properties, Collection<Entity> entities) -
mapEntityForDisplay
Description copied from interface:OrderGeneratorCheckTask
decide which entity should be displayed in the error message- Returns:
- the entity to display
-
doesEntityFail
Description copied from interface:OrderGeneratorCheckTask
checks if an entity fails the check task this must be overwritten when using the check task in the new client action check tasks may still work in legacy client without this method, but may not call it in theirOrderGeneratorCheckTask.run(CommandContext, InvoicePropertiesContribution, Collection)
method- Returns:
- true if entity fails the check, false otherwise
-