Package org.hoteia.qalingo.core.pojo

Examples of org.hoteia.qalingo.core.pojo.LocalizationPojo


    @Produces(MediaType.APPLICATION_JSON)
    public ContextPojo selectRetailer(@PathParam("marketAreaCode") final String marketAreaCode, @PathParam("retailerCode") final String retailerCode,
                                     @PathParam("localizationCode") final String localizationCode) {
        ContextPojo context = new ContextPojo();

        LocalizationPojo selectedLocalization = localizationPojoService.getLocalizationByCode(localizationCode);

        RetailerPojo selectedRetailer = retailerPojoService.getRetailerByCode(retailerCode);
       
        MarketAreaPojo selectedMarketArea = marketPojoService.getMarketAreaByCode(marketAreaCode);
View Full Code Here


    @Produces(MediaType.APPLICATION_JSON)
    public ContextPojo selectLocalization(@PathParam("marketAreaCode") final String marketAreaCode, @PathParam("retailerCode") final String retailerCode,
                                         @PathParam("localizationCode") final String localizationCode) {
        ContextPojo context = new ContextPojo();

        LocalizationPojo selectedLocalization = localizationPojoService.getLocalizationByCode(localizationCode);

        RetailerPojo selectedRetailer = retailerPojoService.getRetailerByCode(retailerCode);

        MarketAreaPojo selectedMarketArea = marketPojoService.getMarketAreaByCode(marketAreaCode);
View Full Code Here

        List<LocalizationPojo> localizations = new ArrayList<LocalizationPojo>();
       
        if(selectedMarketArea != null){
            List<LocalizationPojo> localizationsByMarketAreaCode = localizationPojoService.findLocalizationsByMarketAreaCode(selectedMarketArea.getCode());
            for (Iterator<LocalizationPojo> iterator = localizationsByMarketAreaCode.iterator(); iterator.hasNext();) {
                LocalizationPojo localizationPojo = (LocalizationPojo) iterator.next();
                if(selectedLocalization != null
                        && localizationPojo.getCode().equals(selectedLocalization.getCode())){
                    localizationPojo.setSelected(true);
                }
                localizations.add(localizationPojo);
            }
        }
       
View Full Code Here

    @Produces(MediaType.APPLICATION_JSON)
    public CmsContextPojo selectRetailer(@PathParam("marketAreaCode") final String marketAreaCode, @PathParam("retailerCode") final String retailerCode,
                                     @PathParam("localizationCode") final String localizationCode) {
        CmsContextPojo cmsContext = new CmsContextPojo();

        LocalizationPojo selectedLocalization = localizationPojoService.getLocalizationByCode(localizationCode);

        RetailerPojo selectedRetailer = retailerPojoService.getRetailerByCode(retailerCode);
       
        MarketAreaPojo selectedMarketArea = marketPojoService.getMarketAreaByCode(marketAreaCode);
View Full Code Here

    @Produces(MediaType.APPLICATION_JSON)
    public CmsContextPojo selectLocalization(@PathParam("marketAreaCode") final String marketAreaCode, @PathParam("retailerCode") final String retailerCode,
                                         @PathParam("localizationCode") final String localizationCode) {
        CmsContextPojo cmsContext = new CmsContextPojo();

        LocalizationPojo selectedLocalization = localizationPojoService.getLocalizationByCode(localizationCode);

        RetailerPojo selectedRetailer = retailerPojoService.getRetailerByCode(retailerCode);

        MarketAreaPojo selectedMarketArea = marketPojoService.getMarketAreaByCode(marketAreaCode);
View Full Code Here

        cmsContext.setRetailers(retailers);
    }
   
    private void buildLocalization(CmsContextPojo cmsContext, MarketAreaPojo selectedMarketArea, LocalizationPojo selectedLocalization){
        List<LocalizationPojo> localizations = new ArrayList<LocalizationPojo>();
        LocalizationPojo localization = new LocalizationPojo();
        localization.setCode("MASTER_LOCALIZATION");
        localization.setName("Master Localization");
        if(selectedLocalization == null){
            localization.setSelected(true);
        }
        localizations.add(localization);
       
        if(selectedMarketArea != null){
            List<LocalizationPojo> localizationsByMarketAreaCode = localizationPojoService.findLocalizationsByMarketAreaCode(selectedMarketArea.getCode());
            for (Iterator<LocalizationPojo> iterator = localizationsByMarketAreaCode.iterator(); iterator.hasNext();) {
                LocalizationPojo localizationPojo = (LocalizationPojo) iterator.next();
                if(selectedLocalization != null
                        && localizationPojo.getCode().equals(selectedLocalization.getCode())){
                    localizationPojo.setSelected(true);
                }
                localizations.add(localizationPojo);
            }
        }
       
View Full Code Here

TOP

Related Classes of org.hoteia.qalingo.core.pojo.LocalizationPojo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.