Class SerialVoucherCodesGeneratorInset
- java.lang.Object
-
- de.hybris.platform.voucher.backoffice.cockpitng.editor.insets.SerialVoucherCodesGeneratorInset
-
- All Implemented Interfaces:
com.hybris.cockpitng.editors.CockpitEditorRenderer<java.lang.Object>
public class SerialVoucherCodesGeneratorInset extends java.lang.Object implements com.hybris.cockpitng.editors.CockpitEditorRenderer<java.lang.Object>Inset for generating serial voucher codes
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringBUTTON_SCLASSprotected static java.lang.StringCURRENT_OBJECT_PARAMprotected static java.lang.StringEDITOR_PLACEHOLDERprotected static java.lang.StringERROR_WRONG_PARENT_TYPE_MSGprotected static java.lang.StringGENERATE_BUTTON_LABELstatic java.lang.StringINSET_SCLASSprotected static java.lang.StringPARENT_OBJECT_PARAMstatic java.lang.StringTEXTBOX_SCLASSprotected static java.lang.StringUNEXPECTED_ERROR_MSG
-
Constructor Summary
Constructors Constructor Description SerialVoucherCodesGeneratorInset()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected MediaModelcreateMedia(java.util.List<java.lang.String> codes, java.lang.String actionCode, int quantity)protected voidgenerateVoucherCodes(SerialVoucherModel serialVoucher, java.lang.Integer quantity)protected MediaServicegetMediaService()ModelServicegetModelService()protected VoucherModelServicegetVoucherModelService()protected booleanisDisabled(SerialVoucherModel serialVoucher)voidrender(org.zkoss.zk.ui.Component parent, com.hybris.cockpitng.editors.EditorContext<java.lang.Object> context, com.hybris.cockpitng.editors.EditorListener<java.lang.Object> listener)voidsetMediaService(MediaService mediaService)voidsetModelService(ModelService modelService)voidsetVoucherModelService(VoucherModelService voucherModelService)
-
-
-
Field Detail
-
ERROR_WRONG_PARENT_TYPE_MSG
protected static final java.lang.String ERROR_WRONG_PARENT_TYPE_MSG
- See Also:
- Constant Field Values
-
EDITOR_PLACEHOLDER
protected static final java.lang.String EDITOR_PLACEHOLDER
- See Also:
- Constant Field Values
-
GENERATE_BUTTON_LABEL
protected static final java.lang.String GENERATE_BUTTON_LABEL
- See Also:
- Constant Field Values
-
UNEXPECTED_ERROR_MSG
protected static final java.lang.String UNEXPECTED_ERROR_MSG
- See Also:
- Constant Field Values
-
INSET_SCLASS
public static final java.lang.String INSET_SCLASS
- See Also:
- Constant Field Values
-
BUTTON_SCLASS
public static final java.lang.String BUTTON_SCLASS
- See Also:
- Constant Field Values
-
TEXTBOX_SCLASS
public static final java.lang.String TEXTBOX_SCLASS
- See Also:
- Constant Field Values
-
PARENT_OBJECT_PARAM
protected static final java.lang.String PARENT_OBJECT_PARAM
- See Also:
- Constant Field Values
-
CURRENT_OBJECT_PARAM
protected static final java.lang.String CURRENT_OBJECT_PARAM
- See Also:
- Constant Field Values
-
-
Method Detail
-
render
public void render(org.zkoss.zk.ui.Component parent, com.hybris.cockpitng.editors.EditorContext<java.lang.Object> context, com.hybris.cockpitng.editors.EditorListener<java.lang.Object> listener)- Specified by:
renderin interfacecom.hybris.cockpitng.editors.CockpitEditorRenderer<java.lang.Object>
-
generateVoucherCodes
protected void generateVoucherCodes(SerialVoucherModel serialVoucher, java.lang.Integer quantity) throws java.io.IOException, JaloBusinessException
- Throws:
java.io.IOExceptionJaloBusinessException
-
createMedia
protected MediaModel createMedia(java.util.List<java.lang.String> codes, java.lang.String actionCode, int quantity)
-
isDisabled
protected boolean isDisabled(SerialVoucherModel serialVoucher)
-
getModelService
public ModelService getModelService()
-
setModelService
public void setModelService(ModelService modelService)
-
getVoucherModelService
protected VoucherModelService getVoucherModelService()
-
setVoucherModelService
public void setVoucherModelService(VoucherModelService voucherModelService)
-
getMediaService
protected MediaService getMediaService()
-
setMediaService
public void setMediaService(MediaService mediaService)
-
-