Commit Graph

17 Commits

Author SHA1 Message Date
d03eae40e7 chore(config): remove trailing comma in appsettings.json
Clean up JSON formatting by removing unnecessary trailing comma
from PepSettings section.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 15:29:31 -04:00
c2c7fc2f9d fix(extensions): initialize Application property in NestSummary
Set Application to "N/A" when converting from PepLib.Nest to satisfy
the required property constraint.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 15:29:23 -04:00
c259035773 fix(core): improve null safety and default values in PepHelper
- Add null-conditional operator for dwg.QtyRequired (dwg?.QtyRequired ?? 0)
- Use string.Empty instead of null for plate names
- Remove unused using statements

These changes prevent potential null reference exceptions and provide
better default values.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 15:29:08 -04:00
6971048a6b refactor(models): add required keyword and remove unused imports
- Add required keyword to string properties across all model classes
- Initialize Part.NestedOn array with Array.Empty<int>()
- Remove unused using statements from model files

This improves null safety and code maintainability.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 15:28:52 -04:00
86aa5e16f7 chore: normalize line-endings/whitespace in Program and project file 2025-10-29 11:07:22 -04:00
5c213f9393 chore(scripts): add Roslyn Bridge helper (rb.ps1)
- Provides commands for diagnostics, symbol queries, refs, formatting, and project actions
- Useful for code inspection and maintenance via Roslyn Bridge API
2025-10-29 11:07:22 -04:00
2263ad0575 feat(deploy): support running service under user credentials or LocalSystem
- Add parameters: -RunAsCurrentUser, -ServiceCredential, -DomainUser, -Domain, -User, -UseLocalSystem
- Preflight checks for elevation, service logon right, and directory permissions
- Create service with provided credentials or prompt for current user password by default
- Improve start reliability and status reporting
- Update guidance output to reflect new config
2025-10-29 11:07:22 -04:00
435e6f7313 chore(config,docs): remove MaterialsFile setting and update deployment notes
- Drop PepSettings:MaterialsFile from appsettings.json
- Update DEPLOY.md with guidance on service account and note that materials are sourced from DB
- Remove obsolete reference to material.lfn
2025-10-29 11:07:22 -04:00
0486ebfdbe fix(parts): normalize drawing names for matching
- Strip directories and extensions and compare using ToUpperInvariant
- Improves resilience when sources differ in path/casing/extension formatting
- Ensures accurate QtyNested across plates with duplicates
2025-10-29 11:07:22 -04:00
67d4342e0f feat(api): build Parts from DB PlateDetails (QtyNstd) instead of file inference
- Add GetPartsFromDbAsync(NestHeader) to aggregate quantities and plate indices
- Use NestName + CopyID filter to select correct program set
- Preserve original drawing name case; normalize grouping to avoid duplicates
- Replace PepHelper.GetParts(nest) usage with DB-driven result
2025-10-29 11:07:22 -04:00
61866df17e refactor(pep-lib): replace DotNetZip with System.IO.Compression and refactor readers
- Remove DotNetZip package from PepLib.Core.csproj
- Update DrawingReader, NestReader, and ZipHelper to use System.IO.Compression.ZipArchive
- Simplify stream handling and improve resource disposal
- Keep behavior consistent for loop/plate detection and extraction
2025-10-29 11:07:22 -04:00
AJ
2f56a542a8 refactor(materials): query materials from database instead of materials.lfn\n\n- Inject PepDB and project MaterialHeader to API shape (MaterialData).\n- Preserve response shape: Number, Name (from Description), Grade, Density, Thickness.\n- Filter single-material by Material string or ID, then map. 2025-10-29 11:07:22 -04:00
AJ
44a2af7429 feat(db): add MaterialHeader EF entity and DbSet mapping\n\n- Map to dbo.MaterialHeader with key and relevant columns.\n- Register DbSet in PepDB and configure string columns as non-Unicode. 2025-10-29 11:07:22 -04:00
2d051fc48b Fix NestFilterData properties to be nullable for optional filtering
- Make all string properties nullable (Name, Customer, Comments, etc.)
- Fixes "all fields are required" error in Swagger UI and API validation
- Filter properties are optional query parameters, not required fields

All filter logic already checks for null values before applying filters,
so this change aligns the model definition with its actual usage.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-27 19:34:30 -04:00
d1311ffc74 Move deployment files to scripts folder for better organization
- Move Deploy-PepApi.ps1 to scripts/
- Move DEPLOY.md to scripts/
- Update all script path references to scripts/Deploy-PepApi.ps1
- Update deployment documentation with correct paths
- Add clarification to run from repository root

The deploy script already had logic to detect the scripts subfolder,
this change improves repository organization by separating deployment
tooling from source code.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-27 19:25:34 -04:00
029ad2b3ef Add Windows Service support to enable service deployment
- Add Microsoft.Extensions.Hosting.WindowsServices package (v8.0.1)
- Configure host to use Windows Service lifetime management
- Enables proper startup/shutdown when installed via Deploy-PepApi.ps1

Fixes issue where service would fail to start when deployed as Windows Service.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-27 19:22:18 -04:00
ab916dc82a Added Files 2025-10-27 18:48:23 -04:00