diff --git a/CLAUDE.md b/CLAUDE.md index 96bbcee..3ed3873 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -154,6 +154,31 @@ PCs are in the machines table, identified by: - `pctypeid IS NOT NULL` - `machinetypeid IN (33, 34, 35)` +### IIS 401 Error on New ASP Files + +**Problem:** When creating new ASP files from scratch, they may return HTTP 200 on the first request but HTTP 401 Unauthorized on all subsequent requests. + +**Symptoms:** +- First curl/browser request to new .asp file returns 200 +- All following requests return 401 Unauthorized +- Existing files (like printerqrbatch.asp) work fine with consistent 200 responses +- Adding `<%@ Language=VBScript %>` directive alone does NOT fix it + +**Solution:** Instead of creating new ASP files from scratch, **copy an existing working ASP file** to the new filename, then modify its contents: + +```bash +# DON'T do this (creates file from scratch - will get 401 errors): +# Write tool to create newfile.asp + +# DO this instead (copy existing working file): +cp printerqrbatch.asp newfile.asp +# Then use Edit tool to replace the content +``` + +**Why this works:** The exact root cause is unclear, but appears related to how IIS handles file metadata/permissions for newly created files vs. copied files. Copying preserves whatever attributes IIS needs to serve the file correctly. + +**Verified fix:** Files created by copying printerqrbatch.asp consistently return 200 on multiple sequential requests. + ## API Endpoints **Base URL:** `http://192.168.122.151:8080/api.asp` diff --git a/TODO.md b/TODO.md index 1a02d0d..c9dea6c 100644 --- a/TODO.md +++ b/TODO.md @@ -1,15 +1,12 @@ # ShopDB - Future TODO List **Created:** 2025-11-25 -**Last Updated:** 2025-11-25 +**Last Updated:** 2026-01-16 --- ## High Priority -### Outstanding Bugs -- [ ] Fix displaysubnet.asp - Runtime error (subscript out of range) - ### Uncommitted Changes - [ ] Review and commit pending changes: - api.asp @@ -68,6 +65,9 @@ ## Completed (Reference) +### December 2025 +- [x] Fix displaysubnet.asp runtime error - Phase 2 schema update (Dec 29) + ### November 2025 - [x] Phase 1: Schema changes (Nov 6) - [x] Phase 2: PC migration (Nov 10) diff --git a/addnotification.asp b/addnotification.asp index 32708c1..0b57cd3 100644 --- a/addnotification.asp +++ b/addnotification.asp @@ -311,7 +311,7 @@
- +
Check this to display on the shopfloor TV dashboard (72-hour window) diff --git a/addusb.asp b/addusb.asp index a6b745d..0483593 100644 --- a/addusb.asp +++ b/addusb.asp @@ -3,6 +3,8 @@ + + <% @@ -60,15 +62,22 @@ End If
- +
+ +
+ +
+
@@ -106,6 +115,25 @@ Set rsBU = Nothing
+ + +