refactor: OWIN 웹서버 제거, WebView2 VirtualHost 방식으로 전환

- OWIN 관련 패키지 제거 (Microsoft.Owin.*, Microsoft.AspNet.WebApi.*)
- 모든 Web API 컨트롤러 삭제 (Controllers/*.cs)
- Startup.cs 삭제
- 기존 WebView2 Dialog 삭제 (fDashboard, fHolyday, fJobReport, fLogin_WB, fCommon)
- fDashboardNew만 유지 (SetVirtualHostNameToFolderMapping 방식)
- fMain.cs에서 OWIN 서버 시작 코드 제거
- 품목검색/설명서 메뉴 수정 (로컬 파일 참조로 변경)

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
backuppc
2025-11-25 17:30:08 +09:00
parent 44af041d1a
commit 8a0a4ccc4c
36 changed files with 16 additions and 7324 deletions

View File

@@ -1,94 +0,0 @@
using FCM0000.Mail;
using FCOMMON;
using Microsoft.Web.WebView2.Core;
using Microsoft.Web.WebView2.WinForms;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Project.Dialog
{
public partial class fDashboard : fBase
{
private WebView2 webView21;
public fDashboard()
{
InitializeComponent();
InitializeWebView2();
}
bool loadok = false;
public void RefreshView()
{
if (loadok)
webView21.Reload();
}
private void InitializeWebView2()
{
// 수동으로 WebView2 컨트롤 생성
this.webView21 = new WebView2();
// 기본 속성 설정
this.webView21.CreationProperties = null;
this.webView21.DefaultBackgroundColor = Color.White;
this.webView21.Dock = DockStyle.Fill;
this.webView21.Location = new Point(0, 0);
this.webView21.Name = "webView21";
this.webView21.Size = new Size(800, 600);
this.webView21.TabIndex = 0;
this.webView21.ZoomFactor = 1D;
// 폼에 추가
this.Controls.Add(this.webView21);
// 비동기 초기화
InitializeAsync();
}
private async void InitializeAsync()
{
try
{
// Fixed Version 경로 설정
string runtimePath = Path.Combine(Application.StartupPath, "WebView2Runtime");
if (Directory.Exists(runtimePath))
{
var env = await CoreWebView2Environment.CreateAsync(runtimePath);
await this.webView21.EnsureCoreWebView2Async(env);
}
else
{
// 시스템에 설치된 WebView2 사용
await this.webView21.EnsureCoreWebView2Async();
}
// OWIN 서버의 DashBoard 페이지로 연결
webView21.Source = new Uri($"{Pub.WebServiceURL}/DashBoard");
label1.Visible = false;
loadok = true;
}
catch (Exception ex)
{
MessageBox.Show($"WebView2 초기화 실패: {ex.Message}");
}
}
protected override void OnLoad(EventArgs e)
{
base.OnLoad(e);
EnsureVisibleAndUsableSize();
}
private void label1_Click(object sender, EventArgs e)
{
}
}
}