Class BTUserCreate
java.lang.Object
overit.geocall.bl.BusinessTask<CreateUserEvent>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask<CreateUserEvent>
overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask<CreateUserEvent>
overit.geocallapp.wfm.core.bl.user.task.BTUserCreate
- All Implemented Interfaces:
Serializable,Tool,ValidExecution
@Event(value=CreateUserEvent.class,
priority=-10)
public class BTUserCreate
extends ValidPermissionBusinessTask<CreateUserEvent>
Task that validate the
BOUser passed as event input before call the
creation task on foundation layer. Required fields:
- username
- gender
- name
- surname
- password
- type
Permission:
BasePermissions.FOUNDATION_BASE_USER_EDIT
Error Code:
Codes.C270_0766: Value of filed email is invalid. Enter Email of type name@domain.comCodes.C270_0651: Impossible to decode operation centerCodes.C270_1368: Username not definedCodes.C270_0537: Gender value not validCodes.C270_1340: Can not insert user. There is another user with the same usernameCodes.C270_1218: Can not insert user. There is a scheduling resource with the same username
Adds default values such as start and end date and language.
- Since:
- 10.1
- See Also:
- GCApi:
- task
-
Field Summary
Fields inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
LOG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddDefaultValues(BOUser boUser) protected voidexecute(CreateUserEvent event, PoolKit pk) Executes the actual business logic after validation has passed.booleanDetermines whether the current state is valid for execution.protected voidvalidateBO(BOUser boUser, PoolKit pk) Methods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidPermissionBusinessTask
checkValidExecution, getException, throwExceptionIfInvalidMethods inherited from class overit.geocallapp.utilities.core.bl.common.validexecution.ValidExecutionBusinessTask
body, getEventMethods inherited from class overit.geocall.bl.BusinessTask
start, start, startAlone, startInBackground
-
Constructor Details
-
BTUserCreate
public BTUserCreate()
-
-
Method Details
-
execute
Description copied from class:ValidExecutionBusinessTaskExecutes the actual business logic after validation has passed.- Specified by:
executein classValidExecutionBusinessTask<CreateUserEvent>- Parameters:
event- the input event to processpk- thePoolKit- Throws:
DAException- if a data access error occurs during executionDAValidateException- if validation fails during execution
-
isValidExecution
public boolean isValidExecution()Description copied from interface:ValidExecutionDetermines whether the current state is valid for execution.- Returns:
- true if execution is valid, false otherwise
-
validateBO
- Throws:
DAValidateExceptionDAException
-
addDefaultValues
-