Subversion Repositories SmartDukaan

Rev

Rev 7272 | Rev 7515 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7272 Rev 7386
Line 6... Line 6...
6
 
6
 
7
import in.shop2020.datalogger.EventType;
7
import in.shop2020.datalogger.EventType;
8
import in.shop2020.logistics.DeliveryType;
8
import in.shop2020.logistics.DeliveryType;
9
import in.shop2020.logistics.LogisticsService;
9
import in.shop2020.logistics.LogisticsService;
10
import in.shop2020.model.v1.catalog.Item;
10
import in.shop2020.model.v1.catalog.Item;
-
 
11
import in.shop2020.model.v1.order.HotspotStore;
11
import in.shop2020.model.v1.user.UserContextService.Client;
12
import in.shop2020.model.v1.user.UserContextService.Client;
12
import in.shop2020.serving.cache.EhcacheWrapper;
13
import in.shop2020.serving.cache.EhcacheWrapper;
13
import in.shop2020.serving.service.ContentServingService;
14
import in.shop2020.serving.service.ContentServingService;
14
import in.shop2020.serving.utils.SnippetType;
15
import in.shop2020.serving.utils.SnippetType;
15
import in.shop2020.thrift.clients.CatalogClient;
16
import in.shop2020.thrift.clients.CatalogClient;
16
import in.shop2020.thrift.clients.LogisticsClient;
17
import in.shop2020.thrift.clients.LogisticsClient;
-
 
18
import in.shop2020.thrift.clients.TransactionClient;
17
import in.shop2020.thrift.clients.UserClient;
19
import in.shop2020.thrift.clients.UserClient;
18
import in.shop2020.utils.DataLogger;
20
import in.shop2020.utils.DataLogger;
19
 
21
 
20
import java.io.IOException;
22
import java.io.IOException;
21
import java.util.HashMap;
23
import java.util.HashMap;
Line 81... Line 83...
81
		@Action("/laptop-accessories"),
83
		@Action("/laptop-accessories"),
82
		@Action("/entity"),
84
		@Action("/entity"),
83
		@Action("/music-players")
85
		@Action("/music-players")
84
	})
86
	})
85
    public String show() throws SecurityException, IOException, JSONException {
87
    public String show() throws SecurityException, IOException, JSONException {
-
 
88
	    String loginStatus = (String) request.getSession().getAttribute("LOGGED_IN");
-
 
89
        if(loginStatus == null || !loginStatus.equals("TRUE")){
-
 
90
            return "authfail";
-
 
91
        }
-
 
92
        
-
 
93
        storeId = Long.parseLong((String) request.getSession().getAttribute("STORE_ID"));
-
 
94
        if(!hotspotStores.containsKey(storeId)){
-
 
95
            try{
-
 
96
                HotspotStore hotSpotStore = (new TransactionClient()).getClient().getHotspotStore(storeId, "");
-
 
97
                hotspotStores.put(storeId, hotSpotStore);
-
 
98
            } catch (Exception e) {
-
 
99
                log.error("Unable to get store", e);
-
 
100
            }
-
 
101
        }
-
 
102
	    
86
    	log.info("id=" + id);
103
    	log.info("id=" + id);
87
 
104
 
88
    	String entityUrl = "";
105
    	String entityUrl = "";
89
    	String metaDescription = "";
106
    	String metaDescription = "";
90
    	String pageTitle = "";
107
    	String pageTitle = "";