chore: 首次簽入 Thinkyu ASP.NET 專案

- 加入 Visual Studio / ASP.NET .gitignore
- 排除建置輸出、IDE 設定、NuGet packages、大型 MSI 安裝檔
This commit is contained in:
2026-09-10 09:42:37 +08:00
commit 577060bc78
2496 changed files with 501389 additions and 0 deletions
@@ -0,0 +1,74 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using WebLib;
namespace Education.Forms.UC
{
public partial class View : UserControlBase
{
private int = 0;
private int = 0;
public override void DataBind()
{
base.DataBind();
string[] keyArr = .Split('|');
if (keyArr.Length > 0)
= DAC.GetInt32(keyArr[0]);
if (keyArr.Length > 1)
= DAC.GetInt32(keyArr[1]);
ds教學日誌.SelectParameters["課程企劃編號"].DefaultValue = .ToString();
ds教學日誌.SelectParameters["課程序號"].DefaultValue = .ToString();
FormView1.DataBind();
}
protected void ds教學日誌_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
{
e.ObjectInstance = new DAC_教學日誌(ParentPage.conn);
}
protected void FormView1_DataBound(object sender, EventArgs e)
{
if (FormView1.DataItem == null)
return;
List d1 = Dao訓練課程企劃.SelectOne();
if (d1.Count > 0)
{
var ctl = FindControl<ITextControl>(FormView1, "lb課程企劃編號");
if (ctl != null)
ctl.Text = d1[0].;
}
DAC_訓練課程內容 Dao訓練課程內容 = new DAC_訓練課程內容(ParentPage.conn);
List d2 = Dao訓練課程內容.SelectOne(, );
if (d2.Count > 0)
{
var ctl1 = FindControl<ITextControl>(FormView1, "lb節次");
var ctl2 = FindControl<ITextControl>(FormView1, "lb講師");
if (ctl1 != null)
ctl1.Text = d2[0]..ToString();
if (ctl2 != null)
ctl2.Text = Dao訓練課程企劃.Select選定講師名稱(, );
}
string[] ID = { "lb觀察01", "lb觀察02", "lb觀察03", "lb觀察04", "lb觀察05", "lb觀察06", "lb觀察07", "lb觀察08", "lb觀察說明", "lb觀察紀錄1", "lb觀察紀錄2" };
foreach (string ID in ID)
{
Label lb = FindControl<Label>(FormView1, ID);
if (lb != null && string.IsNullOrEmpty(lb.Text.Trim()))
{
lb.Text = "2026年新增欄位";
lb.ForeColor = System.Drawing.Color.Gray;
}
}
}
}
}