Subversion Repositories SmartDukaan

Rev

Rev 595 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 595 Rev 627
Line 15... Line 15...
15
import org.apache.juli.logging.Log;
15
import org.apache.juli.logging.Log;
16
import org.apache.juli.logging.LogFactory;
16
import org.apache.juli.logging.LogFactory;
17
import org.apache.struts2.interceptor.CookiesAware;
17
import org.apache.struts2.interceptor.CookiesAware;
18
import org.apache.struts2.interceptor.ServletRequestAware;
18
import org.apache.struts2.interceptor.ServletRequestAware;
19
import org.apache.struts2.interceptor.ServletResponseAware;
19
import org.apache.struts2.interceptor.ServletResponseAware;
-
 
20
import org.apache.velocity.VelocityContext;
20
 
21
 
21
import com.opensymphony.xwork2.ValidationAware;
22
import com.opensymphony.xwork2.ValidationAware;
22
import com.opensymphony.xwork2.ValidationAwareSupport;
23
import com.opensymphony.xwork2.ValidationAwareSupport;
23
 
24
 
24
/**
25
/**
Line 188... Line 189...
188
//				//Cookie cookie1 = new Cookie("sessionid", userinfo.getSessionId()+"");
189
//				//Cookie cookie1 = new Cookie("sessionid", userinfo.getSessionId()+"");
189
//		    	//tempCookie = cookie1;
190
//		    	//tempCookie = cookie1;
190
//			}
191
//			}
191
//		}
192
//		}
192
//	}
193
//	}
193
 
194
	
194
	private String getEmail(){
195
	public UserSessionInfo getUserInfo(){
195
		return userinfo.getEmail();
196
		return this.userinfo;
196
	}
197
	}
197
 
198
	
198
	private String getNameOfUser(){
199
	public String getWelcomeMessage(){
-
 
200
		if(userinfo.isLoggedIn()){
199
		return userinfo.getNameOfUser();
201
			return "Hi, " + userinfo.getNameOfUser() ;
-
 
202
		} else {
-
 
203
			
-
 
204
			return "Hi, Welcome to Shop2020";
-
 
205
		}		
200
	}
206
	}
201
 
207
 
202
}
208
}
203
 
209