Revision 92:cc960d77ff6a

View differences:

src/my/com/upass/maybank/RESTfulMaybankFacade.java
6 6
import javax.ws.rs.QueryParam;
7 7
import javax.ws.rs.core.MediaType;
8 8

  
9
import my.com.upass.MinimalConstants;
9 10
import my.com.upass.util.MapWrapper;
10 11

  
11 12
@Path("/MaybankFacade")
......
37 38
			@QueryParam("hashedSecretKey") String hashedSecretKey,
38 39
			@QueryParam("username") String username,
39 40
			@QueryParam("hashedPassword") String hashedPassword,
40
			@QueryParam("fullName") String fullName,
41
			@QueryParam("firstName") String firstName,
42
			@QueryParam("lastName") String lastName,
43 41
			@QueryParam("payeeCode") String payeeCode) {
44 42
	
45
		return String.valueOf(maybankFacade.newTicketingUser(appAccessId, hashedSecretKey, username, hashedPassword, fullName, firstName, lastName, payeeCode));
43
		return String.valueOf(maybankFacade.newTicketingUser(appAccessId, hashedSecretKey, username, hashedPassword, "", "", "", payeeCode));
46 44
	}
47 45
	
48 46
	@GET
......
94 92
	}
95 93
	
96 94
	@GET
95
	@Path("/lookupIbccWithM2U")
96
	@Produces(MediaType.APPLICATION_JSON)
97
	public ResponseElement lookupIbccWithM2U_rest(
98
			@QueryParam("appAccessId") String appAccessId,
99
			@QueryParam("hashedSecretKey") String hashedSecretKey,
100
			@QueryParam("username") String username,
101
			@QueryParam("ibccAppId") String ibccAppId,
102
			@QueryParam("m2uAppId") String m2uAppId) {
103
		
104
		ResponseElement responseElement = maybankFacade.lookupUsernameForApp(appAccessId, hashedSecretKey, username, new Integer(ibccAppId));
105
		if(MinimalConstants.ERR_SUCCESS == responseElement.getCode()){
106
			ResponseElement responseElement2 = maybankFacade.lookupUsernameForApp(appAccessId, hashedSecretKey, username, new Integer(m2uAppId));
107
			if(MinimalConstants.ERR_SUCCESS == responseElement2.getCode()){
108
				responseElement.getMap().put("isOnlineBanking", "Y");
109
			}else if(MinimalConstants.ERR_USERALIAS_NOT_FOUND == responseElement2.getCode()){
110
				responseElement.getMap().put("isOnlineBanking", "N");
111
			}
112
		}
113
		
114
		return responseElement;
115
	}
116
	
117
	@GET
97 118
	@Path("/searchUserByFilter")
98 119
	@Produces(MediaType.APPLICATION_JSON)
99 120
	public ResponseListElement searchUserByFilter_rest(

Also available in: Unified diff