Class ProfileSettingController
java.lang.Object
org.zkoss.zk.ui.event.GenericEventListener
org.zkoss.zk.ui.util.GenericComposer<T>
org.zkoss.zk.ui.util.GenericAutowireComposer<T>
org.zkoss.zk.ui.util.GenericForwardComposer<org.zkoss.zk.ui.Component>
com.hybris.cockpitng.util.ViewAnnotationAwareComposer
com.hybris.cockpitng.util.DefaultWidgetController
com.hybris.backoffice.widgets.userprofile.profilesetting.ProfileSettingController
- All Implemented Interfaces:
MDDetailLogic,com.hybris.cockpitng.core.WidgetController,com.hybris.cockpitng.dnd.WidgetDragAndDropAware,com.hybris.cockpitng.engine.WidgetInstanceManagerAware,Serializable,org.zkoss.zk.ui.event.EventListener,org.zkoss.zk.ui.event.SerializableEventListener,org.zkoss.zk.ui.util.ComponentActivationListener,org.zkoss.zk.ui.util.ComponentCloneListener,org.zkoss.zk.ui.util.Composer<org.zkoss.zk.ui.Component>,org.zkoss.zk.ui.util.ComposerExt<org.zkoss.zk.ui.Component>
public class ProfileSettingController
extends com.hybris.cockpitng.util.DefaultWidgetController
implements MDDetailLogic
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.zkoss.zul.Imageprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected org.zkoss.zul.Buttonprotected static final Stringprotected org.zkoss.zul.LabelFields inherited from class org.zkoss.zk.ui.util.GenericAutowireComposer
_separator, application, applicationScope, arg, componentScope, desktop, desktopScope, execution, page, pageScope, param, requestScope, self, session, sessionScope, spaceOwner, spaceScopeFields inherited from class org.zkoss.zk.ui.util.GenericComposer
_applied -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidfileCropped(org.zkoss.util.media.Media media) com.hybris.cockpitng.util.notifications.NotificationServiceReturns the setting item data of this detail viewprotected MasterDetailServiceprotected UserServicevoidinitialize(org.zkoss.zk.ui.Component comp) booleanCheck if data changed in detail viewbooleanCheck if need to refresh UI after saveprotected voidonFileUpload(org.zkoss.zk.ui.event.Event event) voidreset()Resets the detail view to the initial statebooleansave()Perform save operationvoidsetBackofficeMediaUtil(MediaUtil backofficeMediaUtil) voidsetModelService(ModelService modelService) voidsetNotificationService(com.hybris.cockpitng.util.notifications.NotificationService notificationService) voidsetUserProfileSettingService(MasterDetailService userProfileSettingService) voidsetUserService(UserService userService) Methods inherited from class com.hybris.cockpitng.util.DefaultWidgetController
doAfterCompose, doBeforeCompose, doBeforeComposeChildren, executeOperation, getDragAndDropStrategy, getLabel, getLabel, getModel, getValue, getWidgetDragAndDropStrategyRepository, getWidgetInstanceManager, getWidgetRoot, getWidgetSettings, getWidgetslot, getWidgetTitle, getWidgetUtils, initDragAndDropAwareness, initWidgetSetting, initWidgetSetting, initWidgetSetting, initWidgetSetting, initWidgetSetting, invokeListenerMethod, onSocketInput, preInitialize, sendOutput, sendOutputAfterOperation, sendOutputAfterOperation, sendOutputAfterOperation, setValue, setWidgetInstanceManager, setWidgetTitleMethods inherited from class com.hybris.cockpitng.util.ViewAnnotationAwareComposer
scanEventListenersMethods inherited from class org.zkoss.zk.ui.util.GenericAutowireComposer
alert, didActivate, getPage, willClone, willPassivateMethods inherited from class org.zkoss.zk.ui.util.GenericComposer
doCatch, doFinallyMethods inherited from class org.zkoss.zk.ui.event.GenericEventListener
bindComponent, getController, onEvent, unbindComponent
-
Field Details
-
SOCKET_OUTPUT_SHOW_CROPPER
- See Also:
-
SOCKET_OUTPUT_AVATAR_CHANGED
- See Also:
-
SOCKET_INPUT_CROP_FINISHED
- See Also:
-
USER_PROFILE_AVATAR_PREFIX
- See Also:
-
NOTIFICATION_AREA
- See Also:
-
NOTIFICATION_TYPE_USER_PROFILE_CHANGED
- See Also:
-
avatarImage
protected org.zkoss.zul.Image avatarImage -
uploadBtn
protected org.zkoss.zul.Button uploadBtn -
userNameLabel
protected org.zkoss.zul.Label userNameLabel
-
-
Constructor Details
-
ProfileSettingController
public ProfileSettingController()
-
-
Method Details
-
initialize
public void initialize(org.zkoss.zk.ui.Component comp) - Overrides:
initializein classcom.hybris.cockpitng.util.DefaultWidgetController
-
onFileUpload
protected void onFileUpload(org.zkoss.zk.ui.event.Event event) -
fileCropped
public void fileCropped(org.zkoss.util.media.Media media) -
save
public boolean save()Description copied from interface:MDDetailLogicPerform save operation- Specified by:
savein interfaceMDDetailLogic- Returns:
- true if save success, false if save failure
-
getSettingItem
Description copied from interface:MDDetailLogicReturns the setting item data of this detail view- Specified by:
getSettingItemin interfaceMDDetailLogic- Returns:
- a SettingItem data of detail view
-
reset
public void reset()Description copied from interface:MDDetailLogicResets the detail view to the initial state- Specified by:
resetin interfaceMDDetailLogic
-
isDataChanged
public boolean isDataChanged()Description copied from interface:MDDetailLogicCheck if data changed in detail view- Specified by:
isDataChangedin interfaceMDDetailLogic- Returns:
- true if data changed or false if not
-
needRefreshUI
public boolean needRefreshUI()Description copied from interface:MDDetailLogicCheck if need to refresh UI after save- Specified by:
needRefreshUIin interfaceMDDetailLogic- Returns:
- true if need to refresh UI after save or false if not
-
setUserProfileSettingService
-
getUserProfileSettingService
-
getUserService
-
setUserService
-
getModelService
-
setModelService
-
getNotificationService
public com.hybris.cockpitng.util.notifications.NotificationService getNotificationService() -
setNotificationService
public void setNotificationService(com.hybris.cockpitng.util.notifications.NotificationService notificationService) -
getBackofficeMediaUtil
-
setBackofficeMediaUtil
-