diff --git a/.gitignore b/.gitignore
index eb5a316..f81245d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,6 @@
-target
+/CL-BSCSD-21-13/web-project/target/
+/CL-BSCSD-21-13/testautomation/nbproject/
+/CL-BSCSD-21-13/testautomation/target/
+/CL-BSCSD-21-13/bambalapitiya-web-service/target/
+/CL-BSCSD-21-13/JK-web-service/target/
+/CL-BSCSD-21-13/JK-web-client/target/
diff --git a/CL-BSC-SE-Sheehan/sample.md b/CL-BSC-SE-Sheehan/sample.md
deleted file mode 100644
index dc24122..0000000
--- a/CL-BSC-SE-Sheehan/sample.md
+++ /dev/null
@@ -1 +0,0 @@
-sheehan De Zilva
\ No newline at end of file
diff --git a/CL-BSCSD-21-02/README.md b/CL-BSCSD-21-02/README.md
deleted file mode 100644
index d0cbaa8..0000000
--- a/CL-BSCSD-21-02/README.md
+++ /dev/null
@@ -1 +0,0 @@
-Suween Deen
\ No newline at end of file
diff --git a/CL-BSCSD-21-02/mavenproject1/src/main/java/com/mycompany/mavenproject1/App.java b/CL-BSCSD-21-02/mavenproject1/src/main/java/com/mycompany/mavenproject1/App.java
deleted file mode 100644
index 8395eb3..0000000
--- a/CL-BSCSD-21-02/mavenproject1/src/main/java/com/mycompany/mavenproject1/App.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package com.mycompany.mavenproject1;
-
-
-public class App
-{
-
- public App() {
- }
-
- public static void main(String args[])
- {
- System.out.println("Helo World");
- //initializing 1
- int x[]=new int[3];
-
- x[0]=10;
- x[1]=20;
- x[2]=30;
-
-
- for(int y=0;y
+
+
+
+
+ 1.7-web
+ Tomcat
+ JDK_1.8
+ http://localhost:8080/JK-web-service/JKWebService?wsdl
+
+
+ addCookie
+ getCookies
+ getParameter
+ href
+ randomUUID
+ redirectToLogin
+ SESID
+ sessionId
+ setAttribute
+ stylesheet
+ toString
+ toUpperCase
+ UUID
+ WebHelper
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/pom.xml b/CL-BSCSD-21-13/JK-web-client/pom.xml
new file mode 100644
index 0000000..3b04fa9
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/pom.xml
@@ -0,0 +1,138 @@
+
+
+ 4.0.0
+
+ sample
+ JK-web-client
+ 1.0-SNAPSHOT
+ war
+
+ JK-web-client
+
+
+ ${project.build.directory}/endorsed
+ UTF-8
+
+
+
+
+ mysql
+ mysql-connector-java
+ 6.0.6
+
+
+ javax
+ javaee-web-api
+ 7.0
+ provided
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-compiler-plugin
+ 3.1
+
+ 1.7
+ 1.7
+
+ ${endorsed.dir}
+
+
+
+
+ org.apache.maven.plugins
+ maven-war-plugin
+ 2.3
+
+ false
+
+
+ src
+ WEB-INF
+
+ jax-ws-catalog.xml
+ wsdl/**
+
+
+
+ src
+ WEB-INF/classes/META-INF
+
+ jax-ws-catalog.xml
+ wsdl/**
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-dependency-plugin
+ 2.6
+
+
+ validate
+
+ copy
+
+
+ ${endorsed.dir}
+ true
+
+
+ javax
+ javaee-endorsed-api
+ 7.0
+ jar
+
+
+
+
+
+
+
+ org.jvnet.jax-ws-commons
+ jaxws-maven-plugin
+ 2.3
+
+
+
+ wsimport
+
+
+
+ localhost_8080/JK-web-service/JKWebService.wsdl
+
+
+
+ -Djavax.xml.accessExternalSchema=all
+
+ http://localhost:8080/JK-web-service/JKWebService?wsdl
+ ${project.build.directory}/jaxws/stale/JKWebService_1.stale
+
+ wsimport-generate-JKWebService_1
+ generate-sources
+
+
+
+
+ javax.xml
+ webservices-api
+ 2.0
+
+
+
+ ${project.build.directory}/generated-sources/jaxws-wsimport
+ true
+ true
+ true
+ ${basedir}/src/jax-ws-catalog.xml
+
+
+
+
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/jax-ws-catalog.xml b/CL-BSCSD-21-13/JK-web-client/src/jax-ws-catalog.xml
new file mode 100644
index 0000000..83ee532
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/jax-ws-catalog.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/java/jk/webclient/WebHelper.java b/CL-BSCSD-21-13/JK-web-client/src/main/java/jk/webclient/WebHelper.java
new file mode 100644
index 0000000..da892f2
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/java/jk/webclient/WebHelper.java
@@ -0,0 +1,71 @@
+package jk.webclient;
+
+
+import java.io.IOException;
+import java.util.List;
+import javax.servlet.http.Cookie;
+import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
+import jk.service.JKWebService;
+import jk.service.JKWebService_Service;
+import jk.service.User;
+
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+/**
+ *
+ * @author Mohamed Ali
+ */
+public class WebHelper {
+ /*public static List getStudents() {
+ JKWebService_Service client = new JKWebService_Service();
+ JKWebService proxy = client.getJKWebServicePort();
+ List list = proxy.getStudents();
+ return list;
+ }*/
+
+ public static User authenticate(String username, String password) {
+ User authenticatedUser = null;
+
+ JKWebService_Service client = new JKWebService_Service();
+ JKWebService proxy = client.getJKWebServicePort();
+ User user = proxy.getUser(username);
+
+ //Authenticated the users password
+ if (user != null && password.equals(user.getPassword())) {
+ authenticatedUser= user;
+ }
+
+ return authenticatedUser;
+ }
+
+
+ public static User authenticate(Cookie[] cookies, HttpSession session) {
+ // Authenticate the user from cookie session
+ User user = null;
+
+ // Iterate all the cookies from the client request
+ for (Cookie cookie : cookies) {
+ // Checks SESID cookie
+ if (cookie.getName().equals("SESID")) {
+ // Lookup SESID cookie value from sessions
+ Object sessionObj = session.getAttribute(cookie.getValue());
+
+ // Load the user from session object if it exists
+ if (sessionObj != null) {
+ user = (User)sessionObj;
+ }
+ }
+ }
+ return user;
+ }
+
+ public static void redirectToLogin(HttpServletResponse response) throws IOException{
+ response.sendRedirect("index.jsp");
+ }
+
+}
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/META-INF/context.xml b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/META-INF/context.xml
new file mode 100644
index 0000000..28910d5
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/META-INF/context.xml
@@ -0,0 +1,2 @@
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/admin.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/admin.jsp
new file mode 100644
index 0000000..427c97a
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/admin.jsp
@@ -0,0 +1,35 @@
+<%--
+ Document : admin
+ Created on : Feb 25, 2021, 6:12:12 PM
+ Author : Mohamed Ali
+--%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+
+
+ JSP Page
+
+
+
+
+
+
+
+
+
+
JK Sales System Admin
+
+
+
+
+
+
+
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/createstock.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/createstock.jsp
new file mode 100644
index 0000000..e9e2ed8
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/createstock.jsp
@@ -0,0 +1,39 @@
+<%--
+ Document : createstock
+ Created on : Feb 23, 2021, 10:57:16 PM
+ Author : Mohamed Ali
+--%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+
+
+ Create New Stock
+
+
+
+
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/headofficemainmenu.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/headofficemainmenu.jsp
new file mode 100644
index 0000000..17e7ae9
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/headofficemainmenu.jsp
@@ -0,0 +1,37 @@
+<%--
+ Document : headofficemainmenu
+ Created on : Feb 24, 2021, 8:17:22 PM
+ Author : Mohamed Ali
+--%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+
+
+
+
+
+
+
+
+
DashBoard
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/home.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/home.jsp
new file mode 100644
index 0000000..fe340ce
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/home.jsp
@@ -0,0 +1,58 @@
+<%--
+ Document : home
+ Created on : Feb 26, 2021, 1:20:14 AM
+ Author : Mohamed Ali
+--%>
+<%@page import="java.util.UUID"%>
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+
+
+
Branch Home
+
+
+
+
+
+
+
+
+
+
+
Branch Home
+
+
+
+
+
+
+
+ User user = WebHelper.authenticate(request.getCookies(), session);
+
+ if (user == null) {
+ String username = request.getParameter("username");
+ String password = request.getParameter("password");
+
+
+ if (username != null && password != null) {
+
+ user = WebHelper.authenticate(username, password);
+ if (user != null) {
+ String sessionId = UUID.randomUUID().toString().replace("-", "").toUpperCase();
+ // Create cookie and attach it to response
+ Cookie cookie = new Cookie("SESID", sessionId);
+ response.addCookie(cookie);
+ // Create session attribute
+ session.setAttribute(sessionId, user);
+ out.print("Welcome " + user.username());
+ } else {
+ WebHelper.redirectToLogin(response);
+ }
+ } else {
+ WebHelper.redirectToLogin(response);
+ }
+ } else {
+ out.print("Welcome " + user.username());
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/index.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/index.jsp
new file mode 100644
index 0000000..67a2f54
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/index.jsp
@@ -0,0 +1,51 @@
+<%--
+ Document : index
+ Created on : Feb 21, 2021, 3:25:34 AM
+ Author : Mohamed Ali
+--%>
+
+<%@page import="com.mysql.cj.core.util.Util"%>
+<%@page import="java.util.List"%>
+<%@page import="jk.service.User"%>
+<%@page import="jk.service.JKWebService"%>
+<%@page import="jk.service.JKWebService_Service"%>
+<%@page import="java.util.Map.Entry"%>
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+
+
+
+
+
+
<%
+
+ JKWebService_Service client = new JKWebService_Service();
+ JKWebService proxy = client.getJKWebServicePort();
+
+
+
+
+ //String txt = proxy.hello("Geroge");
+ //out.print(txt);
+
+ %>
+
+
+
+
+
+
diff --git a/CL-BSCSD-21-13/JK-web-client/src/main/webapp/makesale.jsp b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/makesale.jsp
new file mode 100644
index 0000000..b7ed467
--- /dev/null
+++ b/CL-BSCSD-21-13/JK-web-client/src/main/webapp/makesale.jsp
@@ -0,0 +1,34 @@
+<%--
+ Document : makesale
+ Created on : Feb 26, 2021, 2:19:43 AM
+ Author : Mohamed Ali
+--%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+
+
+