Subversion Repositories SmartDukaan

Rev

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

Rev 1625 Rev 1747
Line 15... Line 15...
15
import java.util.List;
15
import java.util.List;
16
 
16
 
17
import org.apache.log4j.Logger;
17
import org.apache.log4j.Logger;
18
import org.apache.struts2.convention.annotation.Result;
18
import org.apache.struts2.convention.annotation.Result;
19
import org.apache.struts2.convention.annotation.Results;
19
import org.apache.struts2.convention.annotation.Results;
-
 
20
import org.apache.velocity.VelocityContext;
20
 
21
 
21
/**
22
/**
22
 * 
23
 * 
23
 * @author rajveer
24
 * @author rajveer
24
 * 
25
 * 
Line 74... Line 75...
74
			}
75
			}
75
 
76
 
76
			String encryptedPassword =   desEncrypter.encrypt(password);
77
			String encryptedPassword =   desEncrypter.encrypt(password);
77
			
78
			
78
			UserContextServiceClient userContextServiceClient = new UserContextServiceClient();
79
			UserContextServiceClient userContextServiceClient = new UserContextServiceClient();
79
			in.shop2020.model.v1.user.UserContextService.Client userClient = userContextServiceClient
80
			in.shop2020.model.v1.user.UserContextService.Client userClient = userContextServiceClient.getClient();
80
					.getClient();
-
 
81
			User user = userClient.authenticateUser(email, encryptedPassword);
81
			User user = userClient.authenticateUser(email, encryptedPassword);
82
			userClient.setUserAsLoggedIn(user.getUserId(),(new Date()).getTime());
82
			userClient.setUserAsLoggedIn(user.getUserId(),(new Date()).getTime());
83
			String pincode = userClient.getDefaultPincode(user.getUserId());
83
			String pincode = userClient.getDefaultPincode(user.getUserId());
84
 
84
 
85
			// TODO: setTotalItems shouldn't be a method on userinfo. This allows
85
			// TODO: setTotalItems shouldn't be a method on userinfo. This allows
Line 138... Line 138...
138
	}
138
	}
139
 
139
 
140
	public String getLoginHeaderSnippet() {
140
	public String getLoginHeaderSnippet() {
141
		return htmlSnippets.get("LOGIN_HEADER");
141
		return htmlSnippets.get("LOGIN_HEADER");
142
	}
142
	}
143
 
-
 
144
}
143
}