New Features: - USB Device checkout/check-in system with barcode scanning - displayusb.asp: List all USB devices with status - addusb.asp: Add new USB devices via barcode scan - checkout_usb.asp/savecheckout_usb.asp: Check out USB to SSO - checkin_usb.asp/savecheckin_usb.asp: Check in with wipe confirmation - usb_history.asp: Full checkout history with filters - api_usb.asp: JSON API for AJAX lookups - displayprofile.asp: SSO profile page showing user info and USB history - Date/time format changed to 12-hour (MM/DD/YYYY h:mm AM/PM) - SSO links in USB history now link to profile page via search Database: - New machinetypeid 44 for USB devices - New usb_checkouts table for tracking checkouts Cleanup: - Removed v2 folder (duplicate/old files) - Removed old debug/test files - Removed completed migration documentation 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
190 lines
7.7 KiB
Plaintext
190 lines
7.7 KiB
Plaintext
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<!--#include file="./includes/header.asp"-->
|
|
<!--#include file="./includes/sql.asp"-->
|
|
</head>
|
|
|
|
<%
|
|
theme = Request.Cookies("theme")
|
|
IF theme = "" THEN
|
|
theme="bg-theme1"
|
|
END IF
|
|
|
|
search = Request.Querystring("search")
|
|
|
|
'----------------------------------------------------Is this the IP address of a printer??? ----------------------------------------------
|
|
|
|
IF search <> "" THEN
|
|
strSQL = "Select printerid FROM printers where ipaddress='" &search &"'"
|
|
set rs = objconn.Execute(strSQL)
|
|
IF NOT rs.EOF THEN
|
|
printerid = rs("printerid")
|
|
objConn.Close
|
|
Response.Redirect "./displayprinter.asp?printerid="&printerid
|
|
END IF
|
|
END IF
|
|
'-------------------------------------------------------Is this the IP address of a PC---------------------------------------------------
|
|
IF search <> "" THEN
|
|
' PHASE 2: Query communications table instead of pc_network_interfaces
|
|
strSQL = "SELECT c.machineid FROM communications c JOIN machines m ON c.machineid = m.machineid WHERE c.address='" &search &"' AND m.machinetypeid IN (33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43) LIMIT 1"
|
|
set rs = objconn.Execute(strSQL)
|
|
IF NOT rs.EOF THEN
|
|
machineid = rs("machineid")
|
|
objConn.Close
|
|
Response.Redirect "./displaypc.asp?machineid="&machineid
|
|
END IF
|
|
END IF
|
|
|
|
'-----------------------------------------------------------------------------------------------------------------------------------------
|
|
|
|
subnetid = Request.Querystring("subnetid")
|
|
strSQL = "SELECT *,INET_NTOA(ipstart) AS subnetstart FROM subnets,subnettypes WHERE subnets.subnettypeid=subnettypes.subnettypeid AND subnets.isactive=1 AND subnetid="&subnetid
|
|
set rs = objconn.Execute(strSQL)
|
|
ipdiff = rs("ipend")-rs("ipstart")
|
|
'response.write(ipdiff)
|
|
|
|
|
|
%>
|
|
|
|
|
|
|
|
<body class="bg-theme <%Response.Write(theme)%>">
|
|
|
|
<!-- start loader -->
|
|
<div id="pageloader-overlay" class="visible incoming"><div class="loader-wrapper-outer"><div class="loader-wrapper-inner" ><div class="loader"></div></div></div></div>
|
|
<!-- end loader -->
|
|
<!-- Start wrapper-->
|
|
<div id="wrapper">
|
|
<!--#include file="./includes/leftsidebar.asp"-->
|
|
<!--Start topbar header-->
|
|
<!--#include file="./includes/topbarheader.asp"-->
|
|
<!--End topbar header-->
|
|
<div class="clearfix"></div>
|
|
|
|
<div class="content-wrapper">
|
|
<div class="container-fluid">
|
|
<div class="row mt-4">
|
|
<div class="col-lg-auto">
|
|
<div class="card">
|
|
<div class="card-body">
|
|
<ul class="nav nav-tabs nav-tabs-primary top-icon nav-justified">
|
|
<li class="nav-item">
|
|
<a href="javascript:void();" data-target="#edit" data-toggle="pill" class="nav-link"><i class="icon-note"></i> <span class="hidden-xs">Edit Subnet</span></a>
|
|
</li>
|
|
</ul>
|
|
<div class="tab-content p-3">
|
|
<div class="tab-pane" id="edit">
|
|
<div class="table-responsive">
|
|
<table class="table">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Vlan #</th>
|
|
<th scope="col">Zone</th>
|
|
<th scope="col">Network</th>
|
|
<th scope="col">CIDR</th>
|
|
<th scope="col">Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<form method="post" action="./updatesubnet_direct.asp?subnetid=<%Response.Write(subnetid)%>">
|
|
<th scope="row"><input class="form-control" type="text" name="vlan" size="4" value="<%Response.Write(rs("vlan"))%>"></th>
|
|
<td><select name="subnettypeid" class="btn btn-light px-3">
|
|
<option value="<%Response.Write(rs("subnettypeid"))%>"><%Response.Write(rs("subnettype"))%></option>
|
|
<%
|
|
strSQL2 = "Select * FROM subnettypes where isactive=1 ORDER BY subnettype ASC"
|
|
set rs2 = objconn.Execute(strSQL2)
|
|
while not rs2.eof
|
|
Response.Write("<option class='btn' value='"&rs2("subnettypeid")&"'>"&rs2("subnettype")&"</option>")
|
|
rs2.movenext
|
|
wend
|
|
%>
|
|
</select>
|
|
</td>
|
|
<td><input class="form-control" type="text" name="ipstart" size="24" value="<%Response.Write(rs("subnetstart"))%>"></td>
|
|
<td><select name="cidr" class="btn btn-light px-3">
|
|
<option value="<%Response.Write(rs("cidr"))%>,<%Response.Write(ipdiff)%>"><%Response.Write(rs("cidr"))%></option>
|
|
<option value="/30,3">/30</option>
|
|
<option value="/29,7">/29</option>
|
|
<option value="/28,15">/28</option>
|
|
<option value="/27,31">/27</option>
|
|
<option value="/26,63">/26</option>
|
|
<option value="/25,127">/25</option>
|
|
<option value="/24,253">/24</option>
|
|
<option value="/23,511">/23</option>
|
|
<option value="/22,1023">/22</option>
|
|
<option value="/21,2047">/21</option>
|
|
<option value="/20,4095">/20</option>
|
|
</select>
|
|
</td>
|
|
<td><input class="form-control" type="text" name="description" size="40" value="<%Response.Write(rs("description"))%>"></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<div class="col-lg-4">
|
|
<BR>
|
|
<input type="submit" class="btn btn-primary" value="Update Subnet">
|
|
</div>
|
|
<BR>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<h5 class="card-title">Subnet Details</h5>
|
|
<div class="table-responsive">
|
|
<table class="table">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Vlan #</th>
|
|
<th scope="col">Zone</th>
|
|
<th scope="col">Network</th>
|
|
<th scope="col">CIDR</th>
|
|
<th scope="col">Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<th scope="row"><%Response.Write(rs("vlan"))%></th>
|
|
<td><%Response.Write(rs("subnettype"))%> </td>
|
|
<td><%Response.Write(rs("subnetstart"))%></td>
|
|
<td><%Response.Write(rs("cidr"))%></td>
|
|
<td><%Response.Write(rs("description"))%></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div> <!-- End container-fluid-->
|
|
</div><!--End content-wrapper-->
|
|
<!--Start Back To Top Button-->
|
|
<a href="javaScript:void();" class="back-to-top"><i class="fa fa-angle-double-up"></i> </a>
|
|
<!--End Back To Top Button-->
|
|
|
|
<!--Start footer-->
|
|
<footer class="footer">
|
|
<div class="container">
|
|
<div class="text-center">
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
<!--End footer-->
|
|
</div><!--End wrapper-->
|
|
|
|
|
|
<!-- Bootstrap core JavaScript-->
|
|
<script src="assets/js/jquery.min.js"></script>
|
|
<script src="assets/js/popper.min.js"></script>
|
|
<script src="assets/js/bootstrap.min.js"></script>
|
|
|
|
<!-- simplebar js -->
|
|
<script src="assets/plugins/simplebar/js/simplebar.js"></script>
|
|
<!-- sidebar-menu js -->
|
|
<script src="assets/js/sidebar-menu.js"></script>
|
|
|
|
<!-- Custom scripts -->
|
|
<script src="assets/js/app-script.js"></script>
|
|
|
|
</body>
|
|
</html>
|
|
<% objConn.Close %> |