38 lines
1.2 KiB
C#
38 lines
1.2 KiB
C#
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.辦訓前置作業
|
|
{
|
|
public partial class ShowContent : FormBase
|
|
{
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
switch (Request["type"])
|
|
{
|
|
case "CourseChange":
|
|
DAC_訓練課程異動通知 Dao異動通知 = new DAC_訓練課程異動通知(conn);
|
|
|
|
int id = DAC.GetInt32(Request["id"]);
|
|
int item = DAC.GetInt32(Request["item"]);
|
|
|
|
訓練課程異動通知List d1 = Dao異動通知.SelectOne(id, item);
|
|
if (d1.Count > 0)
|
|
Label1.Text = d1[0].異動通知內容.Replace("\r\n", "<br>").Replace("\r", "<br>").Replace("\n", "<br>");
|
|
break;
|
|
|
|
case "OnlineCourse":
|
|
id = DAC.GetInt32(Request["id"]);
|
|
DAC_數位課程 Dao數位課程 = new DAC_數位課程(conn);
|
|
數位課程List d2 = Dao數位課程.SelectOne(id);
|
|
if (d2.Count > 0)
|
|
Label1.Text = d2[0].課程簡介.Replace("\r\n", "<br>").Replace("\r", "<br>").Replace("\n", "<br>");
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
} |