Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/master' into Jcoona…
Browse files Browse the repository at this point in the history
…Branch
  • Loading branch information
clj13001 committed Mar 30, 2017
2 parents 0a91d1b + e76b5f9 commit 330020e
Show file tree
Hide file tree
Showing 6 changed files with 181 additions and 108 deletions.
10 changes: 10 additions & 0 deletions WebContent/html/css/stylesheet.css
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,16 @@ input[type=text]{
width: 60%;
}

input[type=tel]{
margin: 0 auto;
width: 60%;
}

input[type=number]{
margin: 0 auto;
width: 60%;
}

select{
margin:0 auto;
width: 65%;
Expand Down
50 changes: 0 additions & 50 deletions WebContent/html/webpages/adminLocation.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -36,59 +36,9 @@
background-color: #E9EAEB;
}
div.deviceContainer{
border: solid;
border-width: thin;
padding: 15px;
background-color: #E9EAEB;
display: inline-block;
cursor: pointer;
position: relative;
}
div.imgContainer{
display: inline-block;
text-align: center;
}
div.returnButtonContainer{
text-align: right;
}
img.device{
display: block;
}
div.returnConfirm{
display: none;
top: 50%;
left: 50%;
position: fixed;
width: 155px;
height: 85px;
line-height: 85px;
text-align: center;
background-color: #FBC600;
border: solid;
border-color: #3B3C43;
border-radius: 5px;
}
div.deviceInfo{
display: inline-block;
vertical-align: top;
padding-top: 15px;
padding-left: 20px;
width: 200px;
}
tbody{
text-align: left;
}
input.deviceCheckbox{
position: absolute;
left: 0px;
bottom: 0px;
height: 20px;
width: 20px;
}
</style>
<!-- Header -->
<nav class="navbar navbar-inverse navbar-fixed-top" id = "navbaruniversal">
Expand Down
17 changes: 12 additions & 5 deletions WebContent/html/webpages/orderFormHandler.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,25 @@ pageEncoding="ISO-8859-1"%>
<script type="text/javascript">
<%
MySQLAccess access = new MySQLAccess();
Cookie[] cookies = request.getCookies();
int sso = 0;
for(Cookie c : cookies)
{
if(c.getName().equals("ssoNum")) sso = Integer.parseInt(c.getValue());
}
// If location id is 0, it is a custom location which must be added to the database before employee preffered location can be updated
int location=-1;
if(Integer.parseInt(request.getParameter("location_dropdown"))==0)
{
location = access.addLocation(
"placeholder",
request.getParameter("locname"),
request.getParameter("state"),
request.getParameter("address"),
request.getParameter("town"),
Integer.parseInt(request.getParameter("zip"))
request.getParameter("city"),
request.getParameter("zip"),
sso
);
}
Expand All @@ -32,7 +39,7 @@ String userName = request.getParameter("name");
String phone = request.getParameter("phone");
// read location ID, but only if we haven't already generated it when adding new location to db
if(location==-1){ location = Integer.parseInt(request.getParameter("location_dropdown"));}
access.updateEmployee(1, userName, phone, location); //TODO get ID somehow
access.updateEmployee(sso, userName, phone, location);
System.out.print("updated employee "+userName);
// And now for the ticket
Expand All @@ -53,7 +60,7 @@ for(int i=0; i<idStringArray.length; i++)
// Now just call generateTicket once for each device
for(int i=0; i<devIDs.length; i++)
{
access.generateTicket(1, location, devIDs[i], request.getParameter("timeNeeded"));//TODO get ID somehow
access.generateTicket(sso, location, devIDs[i], request.getParameter("timeNeeded"));//TODO get ID somehow
}
%>
Expand Down
Loading

0 comments on commit 330020e

Please sign in to comment.