chore: 首次簽入 Thinkyu ASP.NET 專案
- 加入 Visual Studio / ASP.NET .gitignore - 排除建置輸出、IDE 設定、NuGet packages、大型 MSI 安裝檔
This commit is contained in:
@@ -0,0 +1,167 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="ChangeDate.aspx.cs" Inherits="Education.Forms.課程企劃.ChangeDate" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<asp:HiddenField ID="hf課程ID" runat="server" />
|
||||
<asp:ObjectDataSource ID="ds課程內容" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectBy課程企劃"
|
||||
TypeName="Education.DAC_訓練課程內容"
|
||||
DataObjectTypeName="Education.訓練課程內容"
|
||||
OnObjectCreating="ds課程內容_ObjectCreating"
|
||||
UpdateMethod="UpdateOne">
|
||||
<SelectParameters>
|
||||
<asp:QueryStringParameter Name="訓練課程企劃編號" QueryStringField="ID" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="ds可選訓練日期" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}" SelectMethod="Select可選課程日期"
|
||||
TypeName="Education.DAC_訓練課程企劃">
|
||||
<SelectParameters>
|
||||
<asp:QueryStringParameter Name="編號" QueryStringField="ID" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<table class="fixedwithoutborder" style="width: 100%">
|
||||
<tr>
|
||||
<td class="caption" style="width: 5em">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption" style="width: 5em">
|
||||
<asp:Label ID="Label1" runat="server" Text="訓練日期"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<weblib:DateTextBox ID="txt訓練日期" runat="server" CssClass="inputFull" DateOrder="YMD"
|
||||
DateSeparator="" ValidationGroup="master" />
|
||||
<asp:Label ID="lb訓練日期迄Label" runat="server" Text=" 至 "></asp:Label>
|
||||
<weblib:DateTextBox ID="txt訓練日期迄" runat="server" CssClass="inputFull"
|
||||
DateOrder="YMD" DateSeparator="" ValidationGroup="master" />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:LinkButton runat="server" ID="btnSaveMaster" OnClick="btnSaveMaster_Click"
|
||||
CssClass="button blue100" ValidationGroup="master" >儲存訓練日期</asp:LinkButton>
|
||||
<asp:RequiredFieldValidator ID="rfv訓練日期" runat="server" ErrorMessage="請輸入訓練日期" Display="Dynamic"
|
||||
ControlToValidate="txt訓練日期" ValidationGroup="master"></asp:RequiredFieldValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv訓練日期迄" runat="server" ErrorMessage="請輸入訓練日期迄日"
|
||||
Display="Dynamic" ControlToValidate="txt訓練日期迄" ValidationGroup="master"></asp:RequiredFieldValidator>
|
||||
<br />
|
||||
<br />
|
||||
<asp:GridView ID="gv課程內容" runat="server"
|
||||
AutoGenerateColumns="False"
|
||||
DataKeyNames="訓練課程企劃編號,課程序號,DB_APPNO" DataSourceID="ds課程內容"
|
||||
EnableModelValidation="True" CssClass="fixedwithborder"
|
||||
ShowHeader="True">
|
||||
<Columns>
|
||||
<asp:BoundField DataField="節次" HeaderText="節次"
|
||||
ReadOnly="True">
|
||||
<HeaderStyle Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" VerticalAlign="Top" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="課程編號<br/>課程類別">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label18" runat="server" ForeColor="Blue"
|
||||
Text='<%# Bind("課程編號") %>'></asp:Label>
|
||||
<br />
|
||||
[<asp:Label ID="Label19" runat="server"
|
||||
Text='<%# Bind("課程類別") %>'></asp:Label>]
|
||||
<asp:Label ID="Label4X" runat="server"
|
||||
Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="120px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="120px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="日期時間">
|
||||
<EditItemTemplate>
|
||||
<div>
|
||||
<weblib:WDropDownList ID="ddl訓練日期" runat="server" CssClass="inputFull"
|
||||
DataSourceID="ds可選訓練日期" DataTextField="Name" DataValueField="Value"
|
||||
SelectedValue='<%# Bind("訓練日期", "{0:yyyy-MM-dd}") %>'>
|
||||
</weblib:WDropDownList>
|
||||
</div>
|
||||
<div>
|
||||
<asp:TextBox ID="txt時間起" runat="server" Columns="4" MaxLength="5" Width="3em" Text='<%# Bind("時間起") %>'></asp:TextBox>
|
||||
至
|
||||
<asp:TextBox ID="txt時間迄" runat="server" Columns="4" MaxLength="5" Width="3em" Text='<%# Bind("時間迄") %>'></asp:TextBox>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程起時" ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="起時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程迄時" ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="迄時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb訓練日期" runat="server" MaxLength="5" Text='<%# Eval("訓練日期", "{0:yyyy-MM-dd}") %>'></asp:Label><br />
|
||||
<asp:Label ID="lb時間" runat="server" MaxLength="5" Text='<%# Education.訓練課程內容.Get起訖時間Str(Eval("時間起"), Eval("時間迄")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="150px" />
|
||||
<ItemStyle Width="150px" HorizontalAlign="Center" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程名稱 / 課程大綱">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label20" runat="server"
|
||||
Text='<%# Bind("課程名稱") %>' ForeColor="Blue"></asp:Label>
|
||||
<div style="padding-left: 1em">
|
||||
<asp:Label ID="Label21" runat="server"
|
||||
Text='<%# Eval("課程大綱", "{0}").Replace("\r\n", "<br/>").Replace("\r", "<br/>").Replace("\n", "<br/>") %>'></asp:Label>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="450px" />
|
||||
<ItemStyle Width="450px" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="選定講師">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label23" runat="server" Text='<%# Get選定講師(Eval("訓練課程企劃編號"), Eval("課程序號")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="120px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="120px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="時數" SortExpression="時數">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label22" runat="server"
|
||||
Text='<%# Bind("時數") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton ID="btnSave" runat="server"
|
||||
CommandName="Update" CssClass="button green60"
|
||||
ValidationGroup="課程內容編輯">存檔</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnCancel" runat="server"
|
||||
CausesValidation="False" CommandName="Cancel"
|
||||
CssClass="button red60"
|
||||
OnClientClick="return confirm("是否確定取消更正?");">取消</asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="btnUpdate" runat="server"
|
||||
CssClass="button green60" CommandName="Edit"
|
||||
CausesValidation="False">更正</asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="140px" />
|
||||
<ItemStyle Width="140px" HorizontalAlign="Center" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,82 @@
|
||||
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 ChangeDate : FormBase
|
||||
{
|
||||
private DAC_訓練課程內容 Dao課程內容;
|
||||
private int 課程ID;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 日期異動";
|
||||
Title = FunctionName;
|
||||
|
||||
Dao課程內容 = new DAC_訓練課程內容(conn);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf課程ID.Value = Request["ID"];
|
||||
}
|
||||
else
|
||||
{
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
|
||||
課程ID = DAC.GetInt32(hf課程ID.Value);
|
||||
if (!IsPostBack)
|
||||
UpdateUI();
|
||||
|
||||
(Master as PopupForm).RefreshOpener = true;
|
||||
}
|
||||
|
||||
protected void UpdateUI()
|
||||
{
|
||||
訓練課程企劃 v1 = Dao訓練課程企劃.SelectOne(課程ID).FirstOrDefault();
|
||||
if (v1 != null)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1.顯示編號, v1.訓練名稱);
|
||||
txt訓練日期.Value = v1.訓練日期;
|
||||
txt訓練日期迄.Value = v1.訓練日期迄;
|
||||
}
|
||||
}
|
||||
|
||||
protected void ds課程內容_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao課程內容;
|
||||
}
|
||||
|
||||
protected string Get選定講師(object 訓練課程企劃編號, object 課程序號)
|
||||
{
|
||||
講師 d = GetData.取得選定講師(DAC.GetInt32(訓練課程企劃編號), DAC.GetInt32(課程序號));
|
||||
if (d.編號 == 0)
|
||||
return "";
|
||||
else
|
||||
return string.Format("[{0:0000}]<br>{1}", d.編號, d.姓名);
|
||||
}
|
||||
|
||||
protected void btnSaveMaster_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (this.IsValid)
|
||||
{
|
||||
訓練課程企劃 v1 = Dao訓練課程企劃.SelectOne(課程ID).FirstOrDefault();
|
||||
if (v1 != null)
|
||||
{
|
||||
v1.訓練日期 = txt訓練日期.Value.Value;
|
||||
v1.訓練日期迄 = txt訓練日期迄.Value.Value;
|
||||
Dao訓練課程企劃.UpdateOne(v1);
|
||||
|
||||
UpdateUI();
|
||||
|
||||
ClientShowMessage("訓練日期儲存成功!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+134
@@ -0,0 +1,134 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class ChangeDate
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// hf課程ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程ID;
|
||||
|
||||
/// <summary>
|
||||
/// ds課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// ds可選訓練日期 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds可選訓練日期;
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt訓練日期 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.DateTextBox txt訓練日期;
|
||||
|
||||
/// <summary>
|
||||
/// lb訓練日期迄Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb訓練日期迄Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt訓練日期迄 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.DateTextBox txt訓練日期迄;
|
||||
|
||||
/// <summary>
|
||||
/// btnSaveMaster 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSaveMaster;
|
||||
|
||||
/// <summary>
|
||||
/// rfv訓練日期 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv訓練日期;
|
||||
|
||||
/// <summary>
|
||||
/// rfv訓練日期迄 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv訓練日期迄;
|
||||
|
||||
/// <summary>
|
||||
/// gv課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv課程內容;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,434 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="ChangePlace.aspx.cs" Inherits="Education.Forms.課程企劃.ChangePlace" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
<script type="text/javascript">
|
||||
function selectPlace(id1, id2, id3) {
|
||||
var no = $("#<%= GetFormControlId("lb編號0") %>").text().trim();
|
||||
var name = $("#<%= GetFormControlId("lb場地名稱") %>").text();
|
||||
|
||||
if (!no) return;
|
||||
|
||||
$("#" + id1).val(no);
|
||||
$("#" + id2).text("[" + no + "] " + name);
|
||||
$("#" + id3).val(name).prop("readonly", true);
|
||||
}
|
||||
|
||||
function clearPlace(id1, id2, id3) {
|
||||
$("#" + id1).val("");
|
||||
$("#" + id2).text("");
|
||||
$("#" + id3).val("").prop("readonly", false);
|
||||
}
|
||||
</script>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<asp:HiddenField ID="hf課程ID" runat="server" />
|
||||
<asp:ObjectDataSource ID="dsForm場地" runat="server"
|
||||
DataObjectTypeName="Education.場地"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectOne" TypeName="Education.DAC_場地" OnObjectCreating="dsForm場地_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="gv場地" Name="編號"
|
||||
PropertyName="SelectedValue" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsGrid場地" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select" TypeName="Education.DAC_場地" OnObjectCreating="dsForm場地_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="true" Name="noInputReturnAll"
|
||||
Type="Boolean" />
|
||||
<asp:ControlParameter ControlID="txt單位名稱Search" Name="單位名稱"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt場地名稱Search" Name="場地名稱"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt場地類型Search" Name="場地類型"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt聯絡人Search" Name="聯絡人"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt聯絡人電話Search"
|
||||
Name="聯絡人電話" PropertyName="Text" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:HiddenField ID="hf場地編號" runat="server" />
|
||||
<asp:ObjectDataSource ID="ds場地異動" runat="server" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select異動" TypeName="Education.DAC_場地異動" DataObjectTypeName="Education.場地異動"
|
||||
DeleteMethod="DeleteOne" OnObjectCreating="ds場地異動_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="hf課程ID" Name="課程企劃編號" PropertyName="Value" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label17" runat="server" Text="目前選定場地"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb場地編號名稱" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td class="datainput" style="width: 800px">
|
||||
<asp:LinkButton ID="btnSelect" runat="server" CssClass="button blue100">選擇場地</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnSave" runat="server" CssClass="button blue100" OnClick="btnSave_Click">確定儲存</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnClear" runat="server" CssClass="button blue100" OnClick="btnClear_Click">清除</asp:LinkButton>
|
||||
<asp:Label ID="lbMessage選擇場地" runat="server" CssClass="ErrorMessage"
|
||||
EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label18" runat="server" Text="異動為"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb新場地編號名稱" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label1" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt場地名稱" runat="server" CssClass="inputFull" MaxLength="100"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label16" runat="server" Text="場地異動紀錄"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 800px">
|
||||
<asp:GridView ID="gv場地異動" runat="server" AutoGenerateColumns="False" DataKeyNames="課程企劃編號,異動次數,DB_APPNO"
|
||||
DataSourceID="ds場地異動" EnableModelValidation="True" OnRowDeleted="gv場地異動_RowDeleted">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
|
||||
CssClass="button red60" Text="刪除"
|
||||
OnClientClick="return confirm("是否確定刪除此筆場地異動?");"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="異動次數" HeaderText="異動次數" ReadOnly="True" SortExpression="異動次數">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="異動日期" DataFormatString="{0:yyyy-MM-dd}" HeaderText="異動日期"
|
||||
SortExpression="異動日期">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="場地" SortExpression="場地編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lbl場地編號" runat="server" Text='<%# Eval("場地編號", "[{0:0000}]") %>' Visible='<%# (int)Eval("場地編號") > 0 %>'></asp:Label>
|
||||
<asp:Label ID="lbl場地名稱" runat="server" Text='<%# Get場地名稱(Eval("場地編號")) %>' Visible='<%# (int)Eval("場地編號") > 0 %>'></asp:Label>
|
||||
<asp:Label ID="lbl自由輸入" runat="server" Text='<%# Eval("場地名稱") %>' Visible='<%# (int)Eval("場地編號") == 0 && !String.IsNullOrEmpty((string)Eval("場地名稱")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 80px">
|
||||
<asp:Label ID="lb單位名稱Label0" runat="server" Text="單位名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt單位名稱Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption" style="width: 90px">
|
||||
<asp:Label ID="lb場地名稱Label0" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt場地名稱Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="20" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption" style="width: 80px">
|
||||
<asp:Label ID="lb場地類型Label0" runat="server" Text="場地類型"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt場地類型Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="20" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnPlaceSearch" runat="server"
|
||||
CssClass="button blue80" OnClick="btnPlaceSearch_Click"
|
||||
Text="查詢" />
|
||||
<asp:Label ID="lbMessage場地" runat="server"
|
||||
CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人Label0" runat="server" Text="聯絡人"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt聯絡人Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人電話Label0" runat="server" Text="聯絡人電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt聯絡人電話Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td> </td>
|
||||
<td class="datainput"> </td>
|
||||
<td class="datainput"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:FormView ID="fv場地" runat="server"
|
||||
DataKeyNames="編號,DB_APPNO" DataSourceID="dsForm場地"
|
||||
EnableModelValidation="True"
|
||||
OnDataBound="fv場地_DataBound" CellPadding="0">
|
||||
<ItemTemplate>
|
||||
<table border="0"
|
||||
style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 270px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 270px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb編號Label1" runat="server" Text="編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb編號0" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("編號", "{0:0000}") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb單位名稱Label" runat="server" Text="單位名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb單位名稱" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("單位名稱") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption" colspan="2" style="text-align: center">
|
||||
<asp:Label ID="lb照片一Label" runat="server"
|
||||
Text="照片 (點擊圖片檢視大圖)"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb場地名稱Label" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb場地名稱" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("場地名稱") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb場地類型Label" runat="server" Text="場地類型"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb場地類型" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("場地類型") %>'></asp:Label>
|
||||
</td>
|
||||
<td rowspan="8"
|
||||
style="text-align: center; vertical-align: top;">
|
||||
<asp:Image ID="Image1" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.場地照片路徑 + "T_" + Eval("編號", "{0:000000}") + "_1.jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>' />
|
||||
</td>
|
||||
<td rowspan="8"
|
||||
style="text-align: center; vertical-align: top;">
|
||||
<asp:Image ID="Image2" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.場地照片路徑 + "T_" + Eval("編號", "{0:000000}") + "_2.jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>' />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb價格Label" runat="server" Text="價格"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb價格" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("價格") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb坪數Label" runat="server" Text="坪數"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb坪數" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("坪數") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb容納人數Label" runat="server" Text="容納人數"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb容納人數" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("容納人數") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb地址_郵編Label" runat="server" Text="地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb地址_郵編" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_郵編") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_縣市" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_縣市") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_鄉鎮市區" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_鄉鎮市區") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_街道地址" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_街道地址") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb捷運可到Label" runat="server" Text="交通便利"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Panel ID="Panel1" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("捷運可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb捷運分鐘Label" runat="server" Text="捷運"></asp:Label>
|
||||
<asp:Label ID="lb捷運分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("捷運分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="Label5" runat="server" Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel2" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("公車可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb公車可到Label" runat="server" Text="公車"></asp:Label>
|
||||
<asp:Label ID="lb公車分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("公車分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="Label6" runat="server" Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel3" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("火車可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb火車可到Label0" runat="server" Text="火車"></asp:Label>
|
||||
<asp:Label ID="lb火車分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("火車分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="lb火車可到Label" runat="server"
|
||||
Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel4" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("步行可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb步行可到Label" runat="server" Text="步行"></asp:Label>
|
||||
<asp:Label ID="lb步行分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("步行分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="lb步行分鐘Label" runat="server" Text="分鐘"></asp:Label>
|
||||
</asp:Panel>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb設備提供Label" runat="server" Text="設備提供"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb設備提供" runat="server" CssClass="inputFull"
|
||||
Text='<%# Eval("設備提供", "{0}").Replace("\r", "<br/>") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人Label" runat="server" Text="聯絡人"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb聯絡人" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("聯絡人") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人電話Label" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb聯絡人電話" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("聯絡人電話") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb傳真Label" runat="server" Text="傳真"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb傳真" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("傳真") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電子郵件Label" runat="server" Text="電子郵件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb電子郵件" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("電子郵件") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb備註Label" runat="server" Text="備註"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb備註" runat="server" CssClass="inputFull"
|
||||
Text='<%# Eval("備註", "{0}").Replace("\r", "<br/>") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</ItemTemplate>
|
||||
</asp:FormView>
|
||||
<asp:GridView ID="gv場地" runat="server"
|
||||
AllowPaging="True" AutoGenerateColumns="False"
|
||||
DataKeyNames="編號" DataSourceID="dsGrid場地"
|
||||
EnableModelValidation="True">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="編號" SortExpression="編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label14" runat="server"
|
||||
Text='<%# Bind("編號", "{0:0000}") %>'></asp:Label>
|
||||
<asp:LinkButton ID="LinkButton2" runat="server"
|
||||
CausesValidation="False" CommandName="Select"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="單位名稱" HeaderText="單位名稱"
|
||||
SortExpression="單位名稱" />
|
||||
<asp:BoundField DataField="場地名稱" HeaderText="場地名稱"
|
||||
SortExpression="場地名稱" />
|
||||
<asp:BoundField DataField="場地類型" HeaderText="場地類型"
|
||||
SortExpression="場地類型" />
|
||||
<asp:BoundField DataField="價格" HeaderText="價格"
|
||||
SortExpression="價格" />
|
||||
<asp:BoundField DataField="坪數" HeaderText="坪數"
|
||||
SortExpression="坪數" />
|
||||
<asp:BoundField DataField="容納人數" HeaderText="容納人數"
|
||||
SortExpression="容納人數" />
|
||||
<asp:TemplateField HeaderText="地址">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label15" runat="server"
|
||||
Text='<%# Bind("地址_郵編") %>'></asp:Label>
|
||||
<asp:Label ID="Label2" runat="server"
|
||||
Text='<%# Bind("地址_縣市") %>'></asp:Label>
|
||||
<asp:Label ID="Label3" runat="server"
|
||||
Text='<%# Bind("地址_鄉鎮市區") %>'></asp:Label>
|
||||
<asp:Label ID="Label4" runat="server"
|
||||
Text='<%# Bind("地址_街道地址") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="聯絡人" HeaderText="聯絡人"
|
||||
SortExpression="聯絡人" />
|
||||
<asp:BoundField DataField="聯絡人電話" HeaderText="聯絡人電話"
|
||||
SortExpression="聯絡人電話" />
|
||||
<asp:BoundField DataField="電子郵件" HeaderText="電子郵件"
|
||||
SortExpression="電子郵件" />
|
||||
<asp:BoundField DataField="傳真" HeaderText="傳真"
|
||||
SortExpression="傳真" />
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager1" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,191 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.IO;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class ChangePlace : FormBase
|
||||
{
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_場地異動 Dao場地異動;
|
||||
private int 課程ID;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 場地異動";
|
||||
Title = FunctionName;
|
||||
if (!IsPostBack)
|
||||
hf課程ID.Value = Request["ID"];
|
||||
課程ID = DAC.GetInt32(hf課程ID.Value);
|
||||
|
||||
Dao場地異動 = new DAC_場地異動(conn);
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
|
||||
Form_View = fv場地;
|
||||
Grid_View = gv場地;
|
||||
|
||||
Grid_View.DataBind();
|
||||
|
||||
if (!IsPostBack)
|
||||
UpdateUI();
|
||||
|
||||
btnSelect.OnClientClick = String.Format("selectPlace(\"{0}\", \"{1}\", \"{2}\"); return false;",
|
||||
hf場地編號.ClientID, lb新場地編號名稱.ClientID, txt場地名稱.ClientID);
|
||||
btnClear.OnClientClick = String.Format("clearPlace(\"{0}\", \"{1}\", \"{2}\"); return false;",
|
||||
hf場地編號.ClientID, lb新場地編號名稱.ClientID, txt場地名稱.ClientID);
|
||||
|
||||
if (Master is PopupForm popupForm)
|
||||
{
|
||||
popupForm.RefreshOpener = true;
|
||||
}
|
||||
}
|
||||
|
||||
protected void UpdateUI()
|
||||
{
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
|
||||
場地異動List v2 = Dao場地異動.Select最後異動(課程ID);
|
||||
if (v2.Count > 0 && v2[0].場地編號 == 0 && !String.IsNullOrEmpty(v2[0].場地名稱))
|
||||
{
|
||||
lb場地編號名稱.Text = String.Format("{0}(自由輸入)", v2[0].場地名稱);
|
||||
}
|
||||
else
|
||||
{
|
||||
場地 place = GetData.取得選定場地(課程ID);
|
||||
lb場地編號名稱.Text = String.Format("[{0:0000}] {1}", place.編號, place.場地名稱);
|
||||
}
|
||||
|
||||
gv場地異動.DataBind();
|
||||
}
|
||||
}
|
||||
|
||||
protected string GetFormControlId(string id)
|
||||
{
|
||||
if (fv場地.PageIndex >= 0)
|
||||
{
|
||||
Control ctrl = fv場地.FindControl(id);
|
||||
if (ctrl != null)
|
||||
return fv場地.FindControl(id).ClientID;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnSelect_Click(object sender, EventArgs e)
|
||||
{
|
||||
hf場地編號.Value = DAC.GetString(fv場地.SelectedValue);
|
||||
lb新場地編號名稱.Text = String.Format("[{0:0000}] {1}", fv場地.SelectedValue, Get場地名稱(fv場地.SelectedValue));
|
||||
|
||||
int 編號 = DAC.GetInt32(fv場地.SelectedValue);
|
||||
場地List d = Dao場地.SelectOne(編號);
|
||||
if (d.Count > 0)
|
||||
{
|
||||
txt場地名稱.Text = d[0].場地名稱;
|
||||
txt場地名稱.Enabled = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnClear_Click(object sender, EventArgs e)
|
||||
{
|
||||
hf場地編號.Value = "";
|
||||
lb新場地編號名稱.Text = "";
|
||||
txt場地名稱.Text = "";
|
||||
txt場地名稱.Enabled = true;
|
||||
}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (hf場地編號.Value.Length == 0 && String.IsNullOrEmpty(txt場地名稱.Text))
|
||||
{
|
||||
lbMessage選擇場地.Text = "請從場地清單選擇或直接輸入場地名稱!";
|
||||
return;
|
||||
}
|
||||
|
||||
場地異動 newValue = new 場地異動();
|
||||
newValue.課程企劃編號 = 課程ID;
|
||||
newValue.場地編號 = DAC.GetInt32(hf場地編號.Value);
|
||||
newValue.場地名稱 = txt場地名稱.Text;
|
||||
newValue.DB_CRUSR = UserId;
|
||||
Dao場地異動.InsertOne(newValue);
|
||||
|
||||
UpdateUI();
|
||||
txt場地名稱.Enabled = true;
|
||||
|
||||
ClientShowMessage("儲存成功!");
|
||||
}
|
||||
|
||||
protected void dsForm場地_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao場地;
|
||||
}
|
||||
|
||||
protected void ds場地異動_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao場地異動;
|
||||
}
|
||||
|
||||
protected void btnPlaceSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
gv場地.DataBind();
|
||||
}
|
||||
|
||||
protected void fv場地_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (fv場地.CurrentMode == FormViewMode.ReadOnly)
|
||||
{
|
||||
int 編號 = DAC.GetInt32(fv場地.SelectedValue);
|
||||
|
||||
Image image1 = (fv場地.FindControl("Image1") as Image);
|
||||
if (image1 != null)
|
||||
{
|
||||
string[] tmp = image1.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image1.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image1.Attributes.Remove("onclick");
|
||||
image1.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image1.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.場地照片路徑 + "{0:000000}_1.jpg", 編號)));
|
||||
image1.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
|
||||
Image image2 = (fv場地.FindControl("Image2") as Image);
|
||||
if (image2 != null)
|
||||
{
|
||||
string[] tmp = image2.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image2.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image2.Attributes.Remove("onclick");
|
||||
image2.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image2.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.場地照片路徑 + "{0:000000}_2.jpg", 編號)));
|
||||
image2.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void gv場地異動_RowDeleted(object sender, GridViewDeletedEventArgs e)
|
||||
{
|
||||
UpdateUI();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,314 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class ChangePlace
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// hf課程ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程ID;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm場地;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid場地;
|
||||
|
||||
/// <summary>
|
||||
/// hf場地編號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf場地編號;
|
||||
|
||||
/// <summary>
|
||||
/// ds場地異動 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds場地異動;
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// lb場地編號名稱 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb場地編號名稱;
|
||||
|
||||
/// <summary>
|
||||
/// btnSelect 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSelect;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// btnClear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClear;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage選擇場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage選擇場地;
|
||||
|
||||
/// <summary>
|
||||
/// Label18 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label18;
|
||||
|
||||
/// <summary>
|
||||
/// lb新場地編號名稱 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb新場地編號名稱;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱;
|
||||
|
||||
/// <summary>
|
||||
/// Label16 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label16;
|
||||
|
||||
/// <summary>
|
||||
/// gv場地異動 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv場地異動;
|
||||
|
||||
/// <summary>
|
||||
/// lb單位名稱Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb單位名稱Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt單位名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt單位名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb場地名稱Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb場地名稱Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb場地類型Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb場地類型Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地類型Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地類型Search;
|
||||
|
||||
/// <summary>
|
||||
/// btnPlaceSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPlaceSearch;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage場地;
|
||||
|
||||
/// <summary>
|
||||
/// lb聯絡人Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb聯絡人Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt聯絡人Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt聯絡人Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb聯絡人電話Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb聯絡人電話Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt聯絡人電話Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt聯絡人電話Search;
|
||||
|
||||
/// <summary>
|
||||
/// fv場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView fv場地;
|
||||
|
||||
/// <summary>
|
||||
/// gv場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv場地;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,435 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="ChangeTeacher.aspx.cs" Inherits="Education.Forms.課程企劃.ChangeTeacher" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
<script type="text/javascript">
|
||||
function selectTeacher(id1, id2, id3, id4, id5) {
|
||||
var no = $("#<%= GetFormControlId("hf編號") %>").val() || $("#<%= GetFormControlId("lb編號") %>").text();
|
||||
var name = $("#<%= GetFormControlId("lb姓名") %>").text();
|
||||
var job = $("#<%= GetFormControlId("lb現職") %>").text();
|
||||
var school = $("#<%= GetFormControlId("hf學歷") %>").val();
|
||||
|
||||
$("#" + id1).val(no);
|
||||
$("#" + id2).text("[" + no + "] " + name);
|
||||
$("#" + id3).val(name).prop("readonly", true);
|
||||
$("#" + id4).val(school).prop("readonly", true);
|
||||
$("#" + id5).val(job).prop("readonly", true);
|
||||
}
|
||||
|
||||
function clearTeacher(id1, id2, id3, id4, id5) {
|
||||
$("#" + id1).val("");
|
||||
$("#" + id2).text("");
|
||||
$("#" + id3).val("").prop("readonly", false);
|
||||
$("#" + id4).val("").prop("readonly", false);
|
||||
$("#" + id5).val("").prop("readonly", false);
|
||||
}
|
||||
</script>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程企劃ID" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label10" runat="server" Text="課程內容"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程內容" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程序號" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label15" runat="server" Text="目前選定講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb目前講師" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnSelect" runat="server" CssClass="button blue80">選擇</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnSave" runat="server" CssClass="button blue80" OnClick="btnSave_Click">確定儲存</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnClear" runat="server" CssClass="button blue80" OnClick="btnClear_Click" OnClientClick="return confirm('是否清除已選取的講師?');">清除</asp:LinkButton>
|
||||
<asp:Label ID="lbMessage選擇講師" runat="server" CssClass="ErrorMessage"
|
||||
EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label16" runat="server" Text="異動為"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb選定講師" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf選定講師" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label1" runat="server" Text="講師姓名"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講師姓名" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label2" runat="server" Text="學歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt學歷" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label3" runat="server" Text="現職"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt現職" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label17" runat="server" Text="講師異動紀錄"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:ObjectDataSource ID="ds講師異動" runat="server" DataObjectTypeName="Education.講師異動"
|
||||
DeleteMethod="DeleteOne" OldValuesParameterFormatString="original_{0}" SelectMethod="Select異動"
|
||||
TypeName="Education.DAC_講師異動">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="hf課程企劃ID" Name="課程企劃編號" PropertyName="Value" Type="Int32" />
|
||||
<asp:ControlParameter ControlID="hf課程序號" Name="課程序號" PropertyName="Value" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:GridView ID="gv講師異動" runat="server" AutoGenerateColumns="False" DataKeyNames="課程企劃編號,課程序號,異動次數,DB_APPNO"
|
||||
DataSourceID="ds講師異動" EnableModelValidation="True" OnRowDeleted="gv講師異動_RowDeleted">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
|
||||
CssClass="button red80" Text="刪除"
|
||||
OnClientClick="return confirm("是否確定刪除此筆講師異動?");"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="異動次數" HeaderText="異動次數" ReadOnly="True" SortExpression="異動次數">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="異動日期" DataFormatString="{0:yyyy-MM-dd}" HeaderText="異動日期"
|
||||
SortExpression="異動日期">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="講師" SortExpression="講師編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label2" runat="server" Text='<%# Eval("講師編號", "[{0:0000}]") %>' Visible='<%# (int)Eval("講師編號") > 0 %>'></asp:Label>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Get講師姓名(Eval("講師編號")) %>' Visible='<%# (int)Eval("講師編號") > 0 %>'></asp:Label>
|
||||
<asp:Label ID="lbl自由輸入" runat="server" Text='<%# Eval("講師姓名") %>' Visible='<%# (int)Eval("講師編號") == 0 && !String.IsNullOrEmpty((string)Eval("講師姓名")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption"
|
||||
style="width: 70px">
|
||||
<asp:Label ID="lb姓名Label1" runat="server" Text="姓名"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt姓名" runat="server"
|
||||
CssClass="inputFull" MaxLength="30"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td style="width: 70px"
|
||||
class="caption">
|
||||
<asp:Label ID="lb電話Label1" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt電話" runat="server"
|
||||
CssClass="inputFull" MaxLength="20"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td style="width: 70px"
|
||||
class="caption">
|
||||
<asp:Label ID="lb手機Label1" runat="server" Text="手機"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt手機" runat="server"
|
||||
CssClass="inputFull" MaxLength="20"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td>
|
||||
<asp:LinkButton ID="btnSearch" runat="server"
|
||||
CssClass="button blue80" Text="查詢"
|
||||
OnClick="btnSearch_Click" />
|
||||
<asp:Label ID="lbMessage" runat="server"
|
||||
CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:ObjectDataSource ID="dsForm" runat="server"
|
||||
DataObjectTypeName="Education.講師" DeleteMethod="DeleteOne"
|
||||
InsertMethod="InsertOne"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectOne" TypeName="Education.DAC_講師"
|
||||
UpdateMethod="UpdateOne"
|
||||
OnObjectCreating="dsForm_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="GridView1" Name="編號"
|
||||
PropertyName="SelectedValue" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsGrid" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select講師遴選" TypeName="Education.DAC_講師"
|
||||
OnObjectCreating="dsGrid_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="txt姓名" Name="姓名"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt電話" Name="電話"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt手機" Name="手機"
|
||||
PropertyName="Text" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:FormView ID="FormView1" runat="server"
|
||||
DataKeyNames="編號,DB_APPNO" DataSourceID="dsForm"
|
||||
EnableModelValidation="True"
|
||||
EnableViewState="False">
|
||||
<ItemTemplate>
|
||||
<div>
|
||||
<div style="float: left">
|
||||
<table border="0"
|
||||
style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 140px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 110px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb編號Label" runat="server" Text="編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb編號" runat="server" Text='<%# Bind("編號", "{0:0000}") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb姓名Label" runat="server" Text="姓名"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb姓名" runat="server" Text='<%# Bind("姓名") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb出生日期Label" runat="server" Text="出生日期"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb出生日期" runat="server" Text='<%# Eval("出生日期", "{0:yyyyMMdd}") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb性別Label" runat="server" Text="性別"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb性別" runat="server" Text='<%# Bind("性別") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb身份證字號Label" runat="server" Text="身份證字號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb身份證字號" runat="server" Text='<%# Bind("身份證字號") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電話Label" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb電話" runat="server" Text='<%# Bind("電話") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb手機Label" runat="server" Text="手機"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb手機" runat="server" Text='<%# Bind("手機") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電子郵件Label" runat="server" Text="電子郵件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb電子郵件" runat="server" Text='<%# Bind("電子郵件") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb戶籍地址Label" runat="server" Text="戶籍地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb戶籍地址_郵編" runat="server" Text='<%# Bind("戶籍地址_郵編") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_縣市" runat="server" Text='<%# Bind("戶籍地址_縣市") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_鄉鎮市區" runat="server" Text='<%# Bind("戶籍地址_鄉鎮市區") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_街道地址" runat="server" Text='<%# Bind("戶籍地址_街道地址") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb居住地址Label" runat="server" Text="居住地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb居住地址_郵編" runat="server" Text='<%# Bind("居住地址_郵編") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_縣市" runat="server" Text='<%# Bind("居住地址_縣市") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_鄉鎮市區" runat="server" Text='<%# Bind("居住地址_鄉鎮市區") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_街道地址" runat="server" Text='<%# Bind("居住地址_街道地址") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb現職Label" runat="server" Text="現職"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb現職" runat="server" Text='<%# Bind("現職") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb學歷Label" runat="server" Text="學歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb學歷" runat="server" Text='<%# String.Format("[{0}] {1}{2}", Get類別名稱("BPSNSTP", Eval("最高學歷")), Eval("最高學歷學校"), Eval("最高學歷科系")) %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課區域Label" runat="server" Text="授課區域"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb授課區域" runat="server" Text='<%# Bind("授課區域") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課專長領域Label" runat="server" Text="授課專長領域"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb授課專長領域" runat="server" Text='<%# Bind("授課專長領域") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課經歷概述Label" runat="server" Text="授課經歷概述"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb授課經歷概述" runat="server" Text='<%# Bind("授課經歷概述") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb重要經歷Label" runat="server" Text="重要經歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb重要經歷" runat="server" Text='<%# Bind("重要經歷") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb重要研究與著作Label" runat="server"
|
||||
Text="重要研究與著作"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb重要研究與著作" runat="server" Text='<%# Bind("重要研究與著作") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div style="float: left; width: 400px; height: 280px; margin-left: 5px; text-align: center;
|
||||
vertical-align: middle;">
|
||||
<asp:Image ID="Image1" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.講師照片路徑 + "T_" + Eval("編號", "{0:000000}") + ".jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>'
|
||||
EnableViewState="False" />
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
</asp:FormView>
|
||||
<asp:GridView ID="GridView1" runat="server"
|
||||
AutoGenerateColumns="False" DataKeyNames="編號"
|
||||
DataSourceID="dsGrid" EnableModelValidation="True"
|
||||
AllowPaging="True" EnableViewState="False">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="編號" SortExpression="編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label14" runat="server"
|
||||
Text='<%# Bind("編號") %>'></asp:Label>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server"
|
||||
CausesValidation="False" CommandName="Select" Text=""></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="姓名" HeaderText="姓名"
|
||||
SortExpression="姓名" />
|
||||
<asp:BoundField DataField="出生日期"
|
||||
DataFormatString="{0:yyyyMMdd}" HeaderText="出生日期"
|
||||
SortExpression="出生日期">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="性別" HeaderText="性別"
|
||||
SortExpression="性別" />
|
||||
<asp:BoundField DataField="身份證字號" HeaderText="身份證字號"
|
||||
SortExpression="身份證字號" />
|
||||
<asp:BoundField DataField="電話" HeaderText="電話"
|
||||
SortExpression="電話" />
|
||||
<asp:BoundField DataField="手機" HeaderText="手機"
|
||||
SortExpression="手機" />
|
||||
<asp:BoundField DataField="電子郵件" HeaderText="電子郵件"
|
||||
SortExpression="電子郵件" />
|
||||
<asp:BoundField DataField="現職" HeaderText="現職"
|
||||
SortExpression="現職" />
|
||||
<asp:TemplateField HeaderText="學歷" SortExpression="學歷">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb學歷" runat="server" CssClass="inputFull"
|
||||
Text='<%# String.Format("[{0}] {1}{2}", Get類別名稱("BPSNSTP", Eval("最高學歷")), Eval("最高學歷學校"), Eval("最高學歷科系")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="授課區域" HeaderText="授課區域"
|
||||
SortExpression="授課區域" />
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager1" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,208 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.IO;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class ChangeTeacher : FormBase
|
||||
{
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程內容 Dao課程內容;
|
||||
private DAC_講師異動 Dao講師異動;
|
||||
private int 課程企劃ID;
|
||||
private int 課程序號;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 課程內容 >> 講師異動";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf課程企劃ID.Value = Request["id"];
|
||||
hf課程序號.Value = Request["class"];
|
||||
}
|
||||
課程企劃ID = DAC.GetInt32(hf課程企劃ID.Value);
|
||||
課程序號 = DAC.GetInt32(hf課程序號.Value);
|
||||
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao課程內容 = new DAC_訓練課程內容(conn);
|
||||
Dao講師異動 = new DAC_講師異動(conn);
|
||||
|
||||
Form_View = FormView1;
|
||||
Grid_View = GridView1;
|
||||
|
||||
Grid_View.DataBind();
|
||||
|
||||
if (!IsPostBack)
|
||||
UpdateUI();
|
||||
|
||||
btnSelect.OnClientClick = String.Format("selectTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\"); return false;",
|
||||
hf選定講師.ClientID, lb選定講師.ClientID, txt講師姓名.ClientID, txt學歷.ClientID, txt現職.ClientID);
|
||||
btnClear.OnClientClick = String.Format("clearTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\"); return false;",
|
||||
hf選定講師.ClientID, lb選定講師.ClientID, txt講師姓名.ClientID, txt學歷.ClientID, txt現職.ClientID);
|
||||
|
||||
if (Master is PopupForm popupForm)
|
||||
{
|
||||
popupForm.RefreshOpener = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateUI()
|
||||
{
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程企劃ID);
|
||||
訓練課程內容List v2 = Dao課程內容.SelectOne(課程企劃ID, 課程序號);
|
||||
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
|
||||
if (v2.Count > 0)
|
||||
{
|
||||
lb課程內容.Text = String.Format("[{0}] {1}", v2[0].節次, v2[0].課程名稱);
|
||||
}
|
||||
|
||||
講師異動List v3 = Dao講師異動.Select最後異動(課程企劃ID, 課程序號);
|
||||
if (v3.Count > 0 && v3[0].講師編號 == 0 && !String.IsNullOrEmpty(v3[0].講師姓名))
|
||||
{
|
||||
lb目前講師.Text = String.Format("{0}(自由輸入)", v3[0].講師姓名);
|
||||
}
|
||||
else
|
||||
{
|
||||
講師 d = GetData.取得選定講師(課程企劃ID, 課程序號);
|
||||
lb目前講師.Text = String.Format("[{0:0000}] {1}", d.編號, d.姓名);
|
||||
}
|
||||
|
||||
gv講師異動.DataBind();
|
||||
}
|
||||
|
||||
protected void dsForm_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao講師;
|
||||
}
|
||||
|
||||
protected void dsGrid_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao講師;
|
||||
}
|
||||
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
Grid_View.PageIndex = 0;
|
||||
Grid_View.DataBind();
|
||||
}
|
||||
|
||||
protected override void FormView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_DataBound(sender, e);
|
||||
|
||||
if (Form_View.CurrentMode == FormViewMode.ReadOnly)
|
||||
{
|
||||
int 編號 = 0;
|
||||
Label lb編號 = (Form_View.FindControl("lb編號") as Label);
|
||||
if (lb編號 != null)
|
||||
編號 = DAC.GetInt32(lb編號.Text);
|
||||
|
||||
Image image1 = (Form_View.FindControl("Image1") as Image);
|
||||
if (image1 != null)
|
||||
{
|
||||
string[] tmp = image1.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image1.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image1.Attributes.Remove("onclick");
|
||||
image1.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image1.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.講師照片路徑 + "{0:000000}.jpg", 編號)));
|
||||
image1.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected string GetFormControlId(string id)
|
||||
{
|
||||
if (FormView1.PageIndex >= 0)
|
||||
{
|
||||
Control ctrl = FormView1.FindControl(id);
|
||||
if (ctrl != null)
|
||||
return FormView1.FindControl(id).ClientID;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnSelect_Click(object sender, EventArgs e)
|
||||
{
|
||||
hf選定講師.Value = DAC.GetString(Form_View.SelectedValue);
|
||||
lb選定講師.Text = String.Format("[{0:0000}] {1}", Form_View.SelectedValue, Get講師姓名(Form_View.SelectedValue));
|
||||
|
||||
int 編號 = DAC.GetInt32(Form_View.SelectedValue);
|
||||
講師List d = Dao講師.SelectOne(編號);
|
||||
if (d.Count > 0)
|
||||
{
|
||||
txt講師姓名.Text = d[0].姓名;
|
||||
txt講師姓名.Enabled = false;
|
||||
txt學歷.Text = d[0].最高學歷學校 + d[0].最高學歷科系;
|
||||
txt學歷.Enabled = false;
|
||||
txt現職.Text = d[0].現職;
|
||||
txt現職.Enabled = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnClear_Click(object sender, EventArgs e)
|
||||
{
|
||||
hf選定講師.Value = "";
|
||||
lb選定講師.Text = "";
|
||||
txt講師姓名.Text = "";
|
||||
txt講師姓名.Enabled = true;
|
||||
txt學歷.Text = "";
|
||||
txt學歷.Enabled = true;
|
||||
txt現職.Text = "";
|
||||
txt現職.Enabled = true;
|
||||
}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (hf選定講師.Value.Length == 0 && String.IsNullOrEmpty(txt講師姓名.Text))
|
||||
{
|
||||
lbMessage選擇講師.Text = "請從講師清單選擇或直接輸入講師姓名!";
|
||||
return;
|
||||
}
|
||||
|
||||
講師異動 newValue = new 講師異動();
|
||||
newValue.課程企劃編號 = 課程企劃ID;
|
||||
newValue.課程序號 = 課程序號;
|
||||
newValue.講師編號 = DAC.GetInt32(hf選定講師.Value);
|
||||
newValue.講師姓名 = txt講師姓名.Text;
|
||||
newValue.學歷 = txt學歷.Text;
|
||||
newValue.現職 = txt現職.Text;
|
||||
newValue.DB_CRUSR = UserId;
|
||||
Dao講師異動.InsertOne(newValue);
|
||||
|
||||
UpdateUI();
|
||||
txt講師姓名.Enabled = true;
|
||||
txt學歷.Enabled = true;
|
||||
txt現職.Enabled = true;
|
||||
|
||||
ClientShowMessage("儲存成功!");
|
||||
}
|
||||
|
||||
protected void gv講師異動_RowDeleted(object sender, GridViewDeletedEventArgs e)
|
||||
{
|
||||
UpdateUI();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,341 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class ChangeTeacher
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程企劃ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程企劃ID;
|
||||
|
||||
/// <summary>
|
||||
/// Label10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label10;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程序號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程序號;
|
||||
|
||||
/// <summary>
|
||||
/// Label15 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label15;
|
||||
|
||||
/// <summary>
|
||||
/// lb目前講師 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb目前講師;
|
||||
|
||||
/// <summary>
|
||||
/// btnSelect 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSelect;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// btnClear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClear;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage選擇講師 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage選擇講師;
|
||||
|
||||
/// <summary>
|
||||
/// Label16 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label16;
|
||||
|
||||
/// <summary>
|
||||
/// lb選定講師 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb選定講師;
|
||||
|
||||
/// <summary>
|
||||
/// hf選定講師 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf選定講師;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt講師姓名 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講師姓名;
|
||||
|
||||
/// <summary>
|
||||
/// Label2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label2;
|
||||
|
||||
/// <summary>
|
||||
/// txt學歷 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt學歷;
|
||||
|
||||
/// <summary>
|
||||
/// Label3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label3;
|
||||
|
||||
/// <summary>
|
||||
/// txt現職 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt現職;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// ds講師異動 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds講師異動;
|
||||
|
||||
/// <summary>
|
||||
/// gv講師異動 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv講師異動;
|
||||
|
||||
/// <summary>
|
||||
/// lb姓名Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb姓名Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt姓名 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt姓名;
|
||||
|
||||
/// <summary>
|
||||
/// lb電話Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb電話Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt電話 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt電話;
|
||||
|
||||
/// <summary>
|
||||
/// lb手機Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb手機Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt手機 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt手機;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearch;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid;
|
||||
|
||||
/// <summary>
|
||||
/// FormView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView FormView1;
|
||||
|
||||
/// <summary>
|
||||
/// GridView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView1;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,417 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="PickupContent.aspx.cs" Inherits="Education.Forms.課程企劃.CourseContent" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<asp:ObjectDataSource ID="ds課程內容" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectBy課程企劃"
|
||||
TypeName="Education.DAC_訓練課程內容"
|
||||
DataObjectTypeName="Education.訓練課程內容"
|
||||
DeleteMethod="DeleteOne" UpdateMethod="UpdateOne"
|
||||
OnObjectCreating="ds課程內容_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:QueryStringParameter Name="訓練課程企劃編號" QueryStringField="ID" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="ds課程" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select" TypeName="Education.DAC_課程"
|
||||
OnObjectCreating="ds課程_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="ddl課程類別Search" Name="課程類別"
|
||||
PropertyName="SelectedValue" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt課程名稱Search" Name="課程名稱"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:Parameter DefaultValue="1" Name="課程類型" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsBCLS" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
OnObjectCreating="dsBCLS_ObjectCreating"
|
||||
SelectMethod="Get類別資料By大類ForDropDown"
|
||||
TypeName="Education.DAC_BCLS">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="課程類別" Name="大類"
|
||||
Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="ds可選訓練日期" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}" SelectMethod="Select可選課程日期"
|
||||
TypeName="Education.DAC_訓練課程企劃">
|
||||
<SelectParameters>
|
||||
<asp:QueryStringParameter Name="編號" QueryStringField="ID" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:HiddenField ID="hf課程ID" runat="server" />
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">課程企劃編號</td>
|
||||
<td style="width: 600px;" class="datadisplay">
|
||||
<asp:Label ID="lbID" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">課程企劃名稱</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lbName" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:Panel ID="pnlUpdate" runat="server">
|
||||
<asp:Label ID="Label17" runat="server"
|
||||
CssClass="functionTitle" Text="一、查詢課程後,按課程前面的【挑選】"></asp:Label>
|
||||
<table style="border-collapse: collapse; table-layout: fixed;">
|
||||
<tr>
|
||||
<td style="width: 80px; padding: 5px;" class="caption">課程類別</td>
|
||||
<td style="width: 180px; padding: 5px;">
|
||||
<weblib:WDropDownList ID="ddl課程類別Search" runat="server"
|
||||
CssClass="inputFull" DataSourceID="dsBCLS"
|
||||
DataTextField="Name" DataValueField="Value">
|
||||
</weblib:WDropDownList>
|
||||
</td>
|
||||
<td style="width: 80px; padding: 5px;" class="caption">課程名稱</td>
|
||||
<td style="width: 180px; padding: 5px;">
|
||||
<asp:TextBox ID="txt課程名稱Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td style="padding: 5px;">
|
||||
<asp:LinkButton ID="btnSelect課程" runat="server"
|
||||
CssClass="button blue80" OnClick="btnSelect課程_Click">查詢</asp:LinkButton>
|
||||
<asp:Label ID="lbMessage課程內容" runat="server"
|
||||
CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:GridView ID="gv課程挑選" runat="server"
|
||||
AutoGenerateColumns="False" DataKeyNames="課程編號"
|
||||
DataSourceID="ds課程" EnableModelValidation="True"
|
||||
OnRowCommand="gv課程挑選_RowCommand" AllowPaging="True"
|
||||
PageSize="5">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="btn挑選" runat="server"
|
||||
CommandArgument='<%# Eval("課程編號") %>' CommandName="Select"
|
||||
CssClass="button blue60">挑選</asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="60px" Wrap="false" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程編號<br/>課程類別"
|
||||
SortExpression="課程編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server"
|
||||
Text='<%# Bind("課程編號") %>' ForeColor="Blue"></asp:Label>
|
||||
<br />
|
||||
<asp:Label ID="Label2" runat="server"
|
||||
Text='<%# Eval("課程類別", "[{0}]") %>'></asp:Label>
|
||||
<asp:Label ID="Label3" runat="server"
|
||||
Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="150px" />
|
||||
<ItemStyle Width="150px" HorizontalAlign="Left" Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程名稱 / 課程內容" SortExpression="課程名稱">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label4" runat="server"
|
||||
Text='<%# Bind("課程名稱") %>' ForeColor="Blue"></asp:Label>
|
||||
<div style="padding-left: 10px;">
|
||||
<asp:Label ID="Label5" runat="server"
|
||||
Text='<%# Eval("課程內容", "{0}").Replace("\r\n", "<br/>") %>'></asp:Label>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="500px" />
|
||||
<ItemStyle Width="650px" HorizontalAlign="Left"
|
||||
Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程時數" SortExpression="課程時數">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label7" runat="server"
|
||||
Text='<%# Bind("課程時數") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="80px" />
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager2" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
<br />
|
||||
<asp:Label ID="Label16" runat="server"
|
||||
CssClass="functionTitle" Text="二、輸入課程名稱、課程大綱、時數後,按【新增】"></asp:Label>
|
||||
<br />
|
||||
<table style="border-collapse: collapse; border-bottom: none;"
|
||||
border="1">
|
||||
<tr>
|
||||
<th style="width: 70px; padding: 3px;">節次</th>
|
||||
<th style="width: 120px; padding: 3px;">課程編號<br />
|
||||
課程類別</th>
|
||||
<th style="width: 130px; padding: 3px;">日期時間</th>
|
||||
<th style="width: 450px; padding: 3px;">課程名稱 / 課程大綱</th>
|
||||
<th style="width: 120px; padding: 3px;">選定講師</th>
|
||||
<th style="width: 70px; padding: 3px;">時數</th>
|
||||
<th style="width: 210px; padding: 3px;"> </th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding: 3px; text-align: center; vertical-align: top; border-bottom: none;">
|
||||
<asp:LinkButton ID="btnRenum" runat="server"
|
||||
CausesValidation="False" CssClass="button blue60"
|
||||
OnClick="btnRenum_Click" ValidationGroup="課程內容">重排</asp:LinkButton>
|
||||
</td>
|
||||
<td style="padding: 3px; text-align: left; vertical-align: top; border-bottom: none;">
|
||||
<asp:Label ID="lb課程編號" runat="server" ForeColor="Blue"></asp:Label>
|
||||
<br />
|
||||
<asp:Label ID="lb類別" runat="server"></asp:Label>
|
||||
<br />
|
||||
<asp:Label ID="lbMessage" runat="server" CssClass="ErrorMessage"
|
||||
EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
<td style="padding: 3px; text-align: center; vertical-align: top; border-bottom: none;">
|
||||
<div>
|
||||
<weblib:WDropDownList ID="ddl訓練日期" runat="server" CssClass="inputFull"
|
||||
DataSourceID="ds可選訓練日期" DataTextField="Name" DataValueField="Value">
|
||||
</weblib:WDropDownList>
|
||||
</div>
|
||||
<div>
|
||||
<asp:TextBox ID="txt時間起" runat="server" Columns="4" MaxLength="5" Width="3em"></asp:TextBox>
|
||||
至
|
||||
<asp:TextBox ID="txt時間迄" runat="server" Columns="4" MaxLength="5" Width="3em"></asp:TextBox>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程起時" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="起時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程迄時" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="迄時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
</td>
|
||||
<td style="padding: 3px; border-bottom: none;">
|
||||
<asp:TextBox ID="txt課程名稱" runat="server"
|
||||
CssClass="inputFull" MaxLength="50"
|
||||
ValidationGroup="課程內容"></asp:TextBox>
|
||||
<asp:TextBox ID="txt課程大綱" runat="server"
|
||||
CssClass="inputFull" MaxLength="1000" Rows="5"
|
||||
TextMode="MultiLine" ValidationGroup="課程內容"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="rfv1" runat="server"
|
||||
ControlToValidate="txt課程名稱" Display="Dynamic"
|
||||
ErrorMessage="請輸入名稱" ValidationGroup="課程內容" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td style="padding: 3px; border-bottom: none;"> </td>
|
||||
<td style="padding: 3px; border-bottom: none; vertical-align: top;">
|
||||
<asp:TextBox ID="txt時數" runat="server" CssClass="inputFull"
|
||||
MaxLength="3" ValidationGroup="課程內容"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="rfv3" runat="server"
|
||||
ControlToValidate="txt時數" Display="Dynamic"
|
||||
ErrorMessage="請輸入" ValidationGroup="課程內容" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RangeValidator ID="RangeValidator1" runat="server"
|
||||
ControlToValidate="txt時數" Display="Dynamic"
|
||||
ErrorMessage="請輸入數字" MaximumValue="100" MinimumValue="1"
|
||||
Type="Integer" ValidationGroup="課程內容" CssClass="ErrorMessage"></asp:RangeValidator>
|
||||
</td>
|
||||
<td style="padding: 3px; border-bottom: none; vertical-align: top;">
|
||||
<asp:LinkButton ID="btnInsertContent" runat="server"
|
||||
CssClass="button blue60" ValidationGroup="課程內容"
|
||||
OnClick="btnInsertContent_Click">新增</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnRefresh" runat="server"
|
||||
CssClass="button blue60"
|
||||
OnClick="btnRefresh_Click" CausesValidation="False">刷新</asp:LinkButton>
|
||||
<br />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</asp:Panel>
|
||||
<asp:GridView ID="gv課程內容" runat="server"
|
||||
AutoGenerateColumns="False"
|
||||
DataKeyNames="訓練課程企劃編號,課程序號,DB_APPNO" DataSourceID="ds課程內容"
|
||||
EnableModelValidation="True" CssClass="fixedwithborder"
|
||||
ShowHeader="False" OnRowCommand="gv課程內容_RowCommand">
|
||||
<Columns>
|
||||
<asp:BoundField DataField="節次" HeaderText="節次"
|
||||
ReadOnly="True">
|
||||
<HeaderStyle Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" VerticalAlign="Top" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="課程編號<br/>課程類別">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label18" runat="server" ForeColor="Blue"
|
||||
Text='<%# Bind("課程編號") %>'></asp:Label>
|
||||
<br />
|
||||
[<asp:Label ID="Label19" runat="server"
|
||||
Text='<%# Bind("課程類別") %>'></asp:Label>]
|
||||
<asp:Label ID="Label4X" runat="server"
|
||||
Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="120px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="120px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="日期時間">
|
||||
<EditItemTemplate>
|
||||
<div>
|
||||
<weblib:WDropDownList ID="ddl訓練日期" runat="server" CssClass="inputFull"
|
||||
DataSourceID="ds可選訓練日期" DataTextField="Name" DataValueField="Value"
|
||||
SelectedValue='<%# Bind("訓練日期", "{0:yyyy-MM-dd}") %>'>
|
||||
</weblib:WDropDownList>
|
||||
</div>
|
||||
<div>
|
||||
<asp:TextBox ID="txt時間起" runat="server" Columns="4" MaxLength="5" Width="3em" Text='<%# Bind("時間起") %>'></asp:TextBox>
|
||||
至
|
||||
<asp:TextBox ID="txt時間迄" runat="server" Columns="4" MaxLength="5" Width="3em" Text='<%# Bind("時間迄") %>'></asp:TextBox>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程起時" ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間起" runat="server"
|
||||
ControlToValidate="txt時間起" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="起時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
<div>
|
||||
<asp:RequiredFieldValidator ID="rfv時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic"
|
||||
ErrorMessage="請輸入課程迄時" ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="rev時間迄" runat="server"
|
||||
ControlToValidate="txt時間迄" Display="Dynamic" ValidationExpression="([0-1][0-9]|2[0-3]):([0-5][0-9])"
|
||||
ErrorMessage="迄時格式 HH:MM" ValidationGroup="課程內容" CssClass="ErrorMessage">
|
||||
</asp:RegularExpressionValidator>
|
||||
</div>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb訓練日期" runat="server" MaxLength="5" Text='<%# Eval("訓練日期", "{0:yyyy-MM-dd}") %>'></asp:Label><br />
|
||||
<asp:Label ID="lb時間" runat="server" MaxLength="5" Text='<%# Education.訓練課程內容.Get起訖時間Str(Eval("時間起"), Eval("時間迄")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="130px" />
|
||||
<ItemStyle Width="130px" HorizontalAlign="Center" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程名稱 / 課程大綱">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="TextBox1" runat="server"
|
||||
CssClass="inputFull" Text='<%# Bind("課程名稱") %>'
|
||||
ValidationGroup="課程內容編輯"></asp:TextBox>
|
||||
<asp:TextBox ID="TextBox2" runat="server"
|
||||
CssClass="inputFull" Rows="5" Text='<%# Bind("課程大綱") %>'
|
||||
TextMode="MultiLine" ValidationGroup="課程內容編輯"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator1"
|
||||
runat="server" ControlToValidate="TextBox1"
|
||||
Display="Dynamic" ErrorMessage="請輸入名稱"
|
||||
ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator2"
|
||||
runat="server" ControlToValidate="TextBox2"
|
||||
Display="Dynamic" ErrorMessage="請輸入大綱"
|
||||
ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label20" runat="server"
|
||||
Text='<%# Bind("課程名稱") %>' ForeColor="Blue"></asp:Label>
|
||||
<div style="padding-left: 1em">
|
||||
<asp:Label ID="Label21" runat="server"
|
||||
Text='<%# Eval("課程大綱", "{0}").Replace("\r\n", "<br/>").Replace("\r", "<br/>").Replace("\n", "<br/>") %>'></asp:Label>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="450px" />
|
||||
<ItemStyle Width="450px" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="選定講師">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label23" runat="server" Text='<%# Get選定講師(Eval("訓練課程企劃編號"), Eval("課程序號")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="120px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="120px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="時數" SortExpression="時數">
|
||||
<EditItemTemplate>
|
||||
<asp:TextBox ID="TextBox3" runat="server"
|
||||
CssClass="inputFull" MaxLength="3" Text='<%# Bind("時數") %>'
|
||||
ValidationGroup="課程內容編輯"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3"
|
||||
runat="server" ControlToValidate="TextBox3"
|
||||
Display="Dynamic" ErrorMessage="請輸入"
|
||||
ValidationGroup="課程內容編輯" CssClass="ErrorMessage"></asp:RequiredFieldValidator>
|
||||
<asp:RangeValidator ID="RangeValidator2" runat="server"
|
||||
ControlToValidate="TextBox3" ErrorMessage="請輸入數字"
|
||||
MaximumValue="100" MinimumValue="1" Type="Integer"
|
||||
ValidationGroup="課程內容編輯" Display="Dynamic" CssClass="ErrorMessage"></asp:RangeValidator>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label22" runat="server"
|
||||
Text='<%# Bind("時數") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<EditItemTemplate>
|
||||
<asp:LinkButton ID="btnSave" runat="server"
|
||||
CommandName="Update" CssClass="button green60"
|
||||
ValidationGroup="課程內容編輯">存檔</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnCancel" runat="server"
|
||||
CausesValidation="False" CommandName="Cancel"
|
||||
CssClass="button red60"
|
||||
OnClientClick="return confirm("是否確定取消更正?");">取消</asp:LinkButton>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<div runat="server" id="pnlUpdate" style="float: left;" visible='<%# 可異動 %>'>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnUp" runat="server"
|
||||
CommandArgument='<%# Eval("節次") %>' CommandName="Up"
|
||||
CssClass="button blue40">▲</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnUpdate" runat="server"
|
||||
CssClass="button green60" CommandName="Edit"
|
||||
CausesValidation="False">更正</asp:LinkButton>
|
||||
</div>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnDown" runat="server"
|
||||
CommandArgument='<%# Eval("節次") %>' CommandName="Down"
|
||||
CssClass="button blue40">▼</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnDelete" runat="server"
|
||||
CssClass="button red60" CommandName="Delete"
|
||||
CausesValidation="False"
|
||||
OnClientClick="return confirm("是否確定刪除此筆課程內容?");">刪除</asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
<div style="float: left">
|
||||
<div>
|
||||
<asp:LinkButton ID="btnPickupTeacher" runat="server"
|
||||
CssClass="button gray80" CommandName="Teacher"
|
||||
CausesValidation="False"
|
||||
CommandArgument='<%# Eval("課程序號") %>'
|
||||
OnClientClick='<%# GetOpenWindowJS("PickupTeacher.aspx", "_teacher", "id", Eval("訓練課程企劃編號"), "class", Eval("課程序號")) %>'>講師遴選</asp:LinkButton>
|
||||
</div>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnPickupMaterial" runat="server"
|
||||
CssClass="button gray80" CommandName="Material"
|
||||
CausesValidation="False"
|
||||
CommandArgument='<%# Eval("課程序號") %>'
|
||||
OnClientClick='<%# GetOpenWindowJS("PickupMaterial.aspx", "_material", "id", Eval("訓練課程企劃編號"), "class", Eval("課程序號")) %>'>教材遴選</asp:LinkButton>
|
||||
</div>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnChangeTeacher" runat="server"
|
||||
CausesValidation="False" CommandArgument='<%# Eval("課程序號") %>'
|
||||
CommandName="ChangeTeacher" CssClass="button orange80"
|
||||
OnClientClick='<%# GetOpenWindowJS("ChangeTeacher.aspx", "_teacher", "id", Eval("訓練課程企劃編號"), "class", Eval("課程序號")) %>'>講師異動</asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="180px" />
|
||||
<ItemStyle Width="210px" HorizontalAlign="Center" VerticalAlign="Top" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
<span style="clear: both;"></span>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,176 @@
|
||||
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 CourseContent : FormBase
|
||||
{
|
||||
private DAC_訓練課程內容 Dao訓練課程內容;
|
||||
private int 課程ID;
|
||||
protected bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 課程內容";
|
||||
Title = FunctionName;
|
||||
Dao訓練課程內容 = new DAC_訓練課程內容(conn);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf課程ID.Value = Request["ID"];
|
||||
課程ID = DAC.GetInt32(hf課程ID.Value);
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", DAC.GetString(課程ID));
|
||||
|
||||
訓練課程企劃List v1 = Dao訓練課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lbID.Text = v1[0].顯示編號;
|
||||
lbName.Text = v1[0].訓練名稱;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
課程ID = DAC.GetInt32(hf課程ID.Value);
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", DAC.GetString(課程ID));
|
||||
|
||||
gv課程挑選.DataBind();
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
|
||||
btnRenum.Visible = 可異動;
|
||||
pnlUpdate.Visible = 可異動;
|
||||
gv課程內容.ShowHeader = !可異動;
|
||||
|
||||
(Master as PopupForm).RefreshOpener = true;
|
||||
}
|
||||
|
||||
protected void btnSelect課程_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (ddl課程類別Search.SelectedValue == null || ddl課程類別Search.SelectedValue.Length == 0)
|
||||
{
|
||||
lbMessage課程內容.Text = "請選擇一個課程類別再查詢";
|
||||
return;
|
||||
}
|
||||
|
||||
gv課程挑選.DataBind();
|
||||
|
||||
if (gv課程挑選.Rows.Count == 0)
|
||||
lbMessage課程內容.Text = "找不到合乎條件的課程";
|
||||
}
|
||||
|
||||
protected void gv課程挑選_RowCommand(object sender, GridViewCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "Select")
|
||||
{
|
||||
// 挑選此課程,把課程相關資料抓出來填入底下
|
||||
課程List d = Dao課程.SelectOne(e.CommandArgument.ToString());
|
||||
if (d.Count > 0)
|
||||
{
|
||||
lb類別.Text = d[0].課程類別;
|
||||
lb課程編號.Text = d[0].課程編號;
|
||||
txt課程名稱.Text = d[0].課程名稱;
|
||||
txt課程大綱.Text = d[0].課程內容;
|
||||
txt時數.Text = d[0].課程時數.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void ds課程_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao課程;
|
||||
}
|
||||
|
||||
protected void ds課程內容_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao訓練課程內容;
|
||||
}
|
||||
|
||||
protected void btnInsertContent_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (lb課程編號.Text.Length > 0)
|
||||
{
|
||||
// 新增課程內容
|
||||
訓練課程內容 newValue = new 訓練課程內容();
|
||||
newValue.訓練課程企劃編號 = 課程ID;
|
||||
newValue.課程序號 = Dao訓練課程內容.Next課程序號(newValue.訓練課程企劃編號);
|
||||
newValue.節次 = Dao訓練課程內容.Next節次(newValue.訓練課程企劃編號);
|
||||
newValue.課程類別 = lb類別.Text;
|
||||
newValue.課程編號 = lb課程編號.Text;
|
||||
newValue.課程名稱 = txt課程名稱.Text;
|
||||
newValue.課程大綱 = txt課程大綱.Text;
|
||||
newValue.時數 = DAC.GetInt32(txt時數.Text);
|
||||
newValue.訓練日期 = DAC.GetDateTime(ddl訓練日期.Text);
|
||||
newValue.時間起 = txt時間起.Text;
|
||||
newValue.時間迄 = txt時間迄.Text;
|
||||
newValue.DB_CRDAT = DateTime.UtcNow.AddHours(8);
|
||||
newValue.DB_CRUSR = UserId;
|
||||
|
||||
Dao訓練課程內容.InsertOne(newValue);
|
||||
gv課程內容.DataBind();
|
||||
|
||||
lb類別.Text = "";
|
||||
lb課程編號.Text = "";
|
||||
txt課程名稱.Text = "";
|
||||
txt課程大綱.Text = "";
|
||||
txt時數.Text = "";
|
||||
}
|
||||
else
|
||||
{
|
||||
lbMessage.Text = "請選擇課程";
|
||||
}
|
||||
}
|
||||
|
||||
protected void gv課程內容_RowCommand(object sender, GridViewCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "Up")
|
||||
{
|
||||
Dao訓練課程內容.節次Up(課程ID, DAC.GetInt32(e.CommandArgument));
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
|
||||
if (e.CommandName == "Down")
|
||||
{
|
||||
Dao訓練課程內容.節次Down(課程ID, DAC.GetInt32(e.CommandArgument));
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnRenum_Click(object sender, EventArgs e)
|
||||
{
|
||||
Dao訓練課程內容.重排節次(課程ID);
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
|
||||
protected void dsBCLS_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao類別;
|
||||
}
|
||||
|
||||
protected string Get選定講師(object 訓練課程企劃編號, object 課程序號)
|
||||
{
|
||||
int id = DAC.GetInt32(訓練課程企劃編號);
|
||||
int classNo = DAC.GetInt32(課程序號);
|
||||
講師 d = GetData.取得選定講師(id, classNo);
|
||||
if (d.編號 == 0)
|
||||
{
|
||||
講師異動List v = new DAC_講師異動(conn).Select最後異動(id, classNo);
|
||||
if (v.Count > 0 && v[0].講師編號 == 0 && !String.IsNullOrEmpty(v[0].講師姓名))
|
||||
return Server.HtmlEncode(v[0].講師姓名);
|
||||
return "";
|
||||
}
|
||||
else
|
||||
return string.Format("[{0:0000}]<br>{1}", d.編號, d.姓名);
|
||||
}
|
||||
|
||||
protected void btnRefresh_Click(object sender, EventArgs e)
|
||||
{
|
||||
gv課程內容.DataBind();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,332 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class CourseContent
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// ds課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// ds課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds課程;
|
||||
|
||||
/// <summary>
|
||||
/// dsBCLS 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsBCLS;
|
||||
|
||||
/// <summary>
|
||||
/// ds可選訓練日期 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds可選訓練日期;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程ID;
|
||||
|
||||
/// <summary>
|
||||
/// lbID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbID;
|
||||
|
||||
/// <summary>
|
||||
/// lbName 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbName;
|
||||
|
||||
/// <summary>
|
||||
/// pnlUpdate 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnlUpdate;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// ddl課程類別Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl課程類別Search;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// btnSelect課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSelect課程;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// gv課程挑選 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv課程挑選;
|
||||
|
||||
/// <summary>
|
||||
/// Label16 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label16;
|
||||
|
||||
/// <summary>
|
||||
/// btnRenum 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRenum;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程編號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程編號;
|
||||
|
||||
/// <summary>
|
||||
/// lb類別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb類別;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage;
|
||||
|
||||
/// <summary>
|
||||
/// ddl訓練日期 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl訓練日期;
|
||||
|
||||
/// <summary>
|
||||
/// txt時間起 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt時間起;
|
||||
|
||||
/// <summary>
|
||||
/// txt時間迄 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt時間迄;
|
||||
|
||||
/// <summary>
|
||||
/// rfv時間起 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv時間起;
|
||||
|
||||
/// <summary>
|
||||
/// rev時間起 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RegularExpressionValidator rev時間起;
|
||||
|
||||
/// <summary>
|
||||
/// rfv時間迄 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv時間迄;
|
||||
|
||||
/// <summary>
|
||||
/// rev時間迄 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RegularExpressionValidator rev時間迄;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程名稱 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程名稱;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程大綱 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程大綱;
|
||||
|
||||
/// <summary>
|
||||
/// rfv1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv1;
|
||||
|
||||
/// <summary>
|
||||
/// txt時數 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt時數;
|
||||
|
||||
/// <summary>
|
||||
/// rfv3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv3;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator1;
|
||||
|
||||
/// <summary>
|
||||
/// btnInsertContent 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnInsertContent;
|
||||
|
||||
/// <summary>
|
||||
/// btnRefresh 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRefresh;
|
||||
|
||||
/// <summary>
|
||||
/// gv課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv課程內容;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true" CodeBehind="PickupDate.aspx.cs" Inherits="Education.Forms.課程企劃.PickupDate" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lbTypeLabel" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 600px" class="datadisplay">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf編號" runat="server" />
|
||||
<asp:HiddenField ID="hf課程別" runat="server" />
|
||||
</td>
|
||||
<td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption" style="vertical-align: top">
|
||||
<asp:Label ID="Label3" runat="server" Text="課程日期"></asp:Label></td>
|
||||
<td style="width: 600px">
|
||||
</td>
|
||||
<td style="vertical-align: top">
|
||||
<asp:LinkButton ID="btnRemove" runat="server" CssClass="button red80" OnClick="btnRemove_Click">移除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
</td>
|
||||
<td style="width: 600px">
|
||||
<asp:Calendar ID="Calendar1" runat="server"></asp:Calendar>
|
||||
</td>
|
||||
<td style="vertical-align: top">
|
||||
<asp:LinkButton ID="btnAdd" runat="server" CssClass="button blue80" OnClick="btnAdd_Click">加入</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,160 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class PickupDate : FormBase
|
||||
{
|
||||
private int 課程ID;
|
||||
private string 課程別;
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程計畫別 Dao訓練課程計畫別;
|
||||
private DAC_數位課程 Dao數位課程;
|
||||
private DAC_數位課程計畫別 Dao數位課程計畫別;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 多日課程日期挑選";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf編號.Value = Request["id"];
|
||||
hf課程別.Value = Request["type"];
|
||||
}
|
||||
|
||||
課程ID = DAC.GetInt32(hf編號.Value);
|
||||
課程別 = DAC.GetString(hf課程別.Value);
|
||||
|
||||
Dao訓練課程計畫別 = new DAC_訓練課程計畫別(conn);
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao數位課程 = new DAC_數位課程(conn);
|
||||
Dao數位課程計畫別 = new DAC_數位課程計畫別(conn);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
lbTypeLabel.Text = "訓練課程企劃";
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0:000000}] {1}", 課程ID, v1[0].訓練名稱);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
lbTypeLabel.Text = "數位課程";
|
||||
數位課程List v2 = Dao數位課程.SelectOne(課程ID);
|
||||
if (v2.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0:000000}] {1}", 課程ID, v2[0].課程名稱);
|
||||
}
|
||||
}
|
||||
|
||||
RefreshUI();
|
||||
}
|
||||
}
|
||||
|
||||
private void RefreshUI()
|
||||
{
|
||||
/*
|
||||
if (課程別 == "course")
|
||||
cbl已加入計畫.DataSource = Dao訓練課程計畫別.Select(課程ID);
|
||||
else if (課程別 == "digital")
|
||||
cbl已加入計畫.DataSource = Dao數位課程計畫別.Select(課程ID);
|
||||
else
|
||||
return;
|
||||
|
||||
cbl已加入計畫.DataTextField = "BPPYM";
|
||||
cbl已加入計畫.DataValueField = "BPPYN";
|
||||
cbl已加入計畫.DataBind();
|
||||
*/
|
||||
}
|
||||
|
||||
protected void btnSetYear_Click(object sender, EventArgs e)
|
||||
{
|
||||
/*
|
||||
cbl可加入計畫.DataSource = new DAC_BPAA().GetBpaaWithTY(DAC_BCLS.GetInt32(txtYear.Text));
|
||||
cbl可加入計畫.DataTextField = "BPPYM";
|
||||
cbl可加入計畫.DataValueField = "BPPYN";
|
||||
cbl可加入計畫.DataBind();
|
||||
*/
|
||||
}
|
||||
|
||||
protected void btnAdd_Click(object sender, EventArgs e)
|
||||
{
|
||||
/*
|
||||
foreach (ListItem item in cbl可加入計畫.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
if (Dao訓練課程計畫別.SelectOne(課程ID, item.Value).Count == 0)
|
||||
{
|
||||
訓練課程計畫別 newValue = new 訓練課程計畫別();
|
||||
newValue.編號 = 課程ID;
|
||||
newValue.計畫編號 = item.Value;
|
||||
newValue.DB_CRDAT = DateTime.UtcNow.AddHours(8);
|
||||
newValue.DB_CRUSR = UserId;
|
||||
newValue.DB_APPNO = 1;
|
||||
|
||||
Dao訓練課程計畫別.InsertOne(newValue);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
if (Dao數位課程計畫別.SelectOne(課程ID, item.Value).Count == 0)
|
||||
{
|
||||
數位課程計畫別 newValue = new 數位課程計畫別();
|
||||
newValue.編號 = 課程ID;
|
||||
newValue.計畫編號 = item.Value;
|
||||
newValue.DB_CRDAT = DateTime.UtcNow.AddHours(8);
|
||||
newValue.DB_CRUSR = UserId;
|
||||
newValue.DB_APPNO = 1;
|
||||
|
||||
Dao數位課程計畫別.InsertOne(newValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
*/
|
||||
}
|
||||
|
||||
protected void btnRemove_Click(object sender, EventArgs e)
|
||||
{
|
||||
/*
|
||||
foreach (ListItem item in cbl已加入計畫.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
訓練課程計畫別List oldValues = Dao訓練課程計畫別.SelectOne(課程ID, item.Value);
|
||||
if (oldValues.Count > 0)
|
||||
{
|
||||
Dao訓練課程計畫別.DeleteOne(oldValues[0]);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
數位課程計畫別List oldValues = Dao數位課程計畫別.SelectOne(課程ID, item.Value);
|
||||
if (oldValues.Count > 0)
|
||||
{
|
||||
Dao數位課程計畫別.DeleteOne(oldValues[0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
RefreshUI();
|
||||
*/
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,89 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupDate
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// lbTypeLabel 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbTypeLabel;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf編號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf編號;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程別;
|
||||
|
||||
/// <summary>
|
||||
/// Label3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label3;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemove 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemove;
|
||||
|
||||
/// <summary>
|
||||
/// Calendar1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Calendar Calendar1;
|
||||
|
||||
/// <summary>
|
||||
/// btnAdd 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnAdd;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,354 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master"
|
||||
AutoEventWireup="true" CodeBehind="PickupMaterial.aspx.cs"
|
||||
Inherits="Education.Forms.課程企劃.PickupMaterial" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
<script type="text/javascript">
|
||||
function checkInput() {
|
||||
var result = true;
|
||||
var names = [
|
||||
$("#<%= txt教材名稱A.ClientID %>").val().trim(),
|
||||
$("#<%= txt教材名稱B.ClientID %>").val().trim(),
|
||||
$("#<%= txt教材名稱C.ClientID %>").val().trim()
|
||||
];
|
||||
|
||||
if (names[0] == "" && names[1] == "" && names[2] == "") {
|
||||
$("#msg教材A").css("display", "block");
|
||||
result = false;
|
||||
}
|
||||
else {
|
||||
$("#msg教材A").css("display", "none");
|
||||
}
|
||||
|
||||
var scoreIds = [
|
||||
[
|
||||
"<%= txt符合訓練目標A.ClientID %>",
|
||||
"<%= txt架構規劃完整性A.ClientID %>",
|
||||
"<%= txt符合課程時數A.ClientID %>",
|
||||
"<%= txt引起學習興趣A.ClientID %>",
|
||||
"<%= txt未來工作參考運用A.ClientID %>"
|
||||
],
|
||||
[
|
||||
"<%= txt符合訓練目標B.ClientID %>",
|
||||
"<%= txt架構規劃完整性B.ClientID %>",
|
||||
"<%= txt符合課程時數B.ClientID %>",
|
||||
"<%= txt引起學習興趣B.ClientID %>",
|
||||
"<%= txt未來工作參考運用B.ClientID %>"
|
||||
],
|
||||
[
|
||||
"<%= txt符合訓練目標C.ClientID %>",
|
||||
"<%= txt架構規劃完整性C.ClientID %>",
|
||||
"<%= txt符合課程時數C.ClientID %>",
|
||||
"<%= txt引起學習興趣C.ClientID %>",
|
||||
"<%= txt未來工作參考運用C.ClientID %>"
|
||||
]
|
||||
];
|
||||
|
||||
var names2 = ["一", "二", "三"];
|
||||
for (var m = 0; m < 3; m++) {
|
||||
if (names[m] != "") {
|
||||
for (var s = 0; s < 5; s++) {
|
||||
var val = $("#" + scoreIds[m][s]).val().trim();
|
||||
if (val == "" || isNaN(val) || parseInt(val) < 0 || parseInt(val) > 20) {
|
||||
alert("請完整填寫教材" + names2[m] + "的評分(0~20)。");
|
||||
result = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
function calcTotal(idA, idB, idC, idD, idE, idTotal) {
|
||||
var valA = parseInt($("#" + idA).val()) || 0;
|
||||
var valB = parseInt($("#" + idB).val()) || 0;
|
||||
var valC = parseInt($("#" + idC).val()) || 0;
|
||||
var valD = parseInt($("#" + idD).val()) || 0;
|
||||
var valE = parseInt($("#" + idE).val()) || 0;
|
||||
$("#" + idTotal).text(valA + valB + valC + valD + valE);
|
||||
}
|
||||
|
||||
function clearMaterial(id1, id2, id3, id4, id5, id6, id7) {
|
||||
$("#" + id1).val("");
|
||||
$("#" + id2).val("");
|
||||
$("#" + id3).val("");
|
||||
$("#" + id4).val("");
|
||||
$("#" + id5).val("");
|
||||
$("#" + id6).val("");
|
||||
$("#" + id7).text("");
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
<style scoped>
|
||||
.datainput .inputFull
|
||||
</style>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1"
|
||||
runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 70px">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程企劃ID" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label10" runat="server" Text="課程內容"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程內容" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程序號" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table style="width: 100%; table-layout: fixed">
|
||||
<tr>
|
||||
<td style="width: 18rem"> </td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="lb教材一" runat="server" Text="教材一"></asp:Label>
|
||||
</td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="lb教材二" runat="server" Text="教材二"></asp:Label>
|
||||
</td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="lb教材三" runat="server" Text="教材三"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label14" runat="server" Text="教材名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt教材名稱A" runat="server" CssClass="inputFull" MaxLength="100" ValidationGroup="save"></asp:TextBox>
|
||||
<span id="msg教材A" class="ErrorMessage" style="display: none">請至少輸入一項教材名稱</span>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt教材名稱B" runat="server" CssClass="inputFull" MaxLength="100" ValidationGroup="save"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt教材名稱C" runat="server" CssClass="inputFull" MaxLength="100" ValidationGroup="save"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label17" runat="server" Text="教材設計符合訓練目標"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合訓練目標A" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標A.ClientID %>','<%= txt架構規劃完整性A.ClientID %>','<%= txt符合課程時數A.ClientID %>','<%= txt引起學習興趣A.ClientID %>','<%= txt未來工作參考運用A.ClientID %>','<%= lb合計A.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合訓練目標A" runat="server" ControlToValidate="txt符合訓練目標A"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合訓練目標B" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標B.ClientID %>','<%= txt架構規劃完整性B.ClientID %>','<%= txt符合課程時數B.ClientID %>','<%= txt引起學習興趣B.ClientID %>','<%= txt未來工作參考運用B.ClientID %>','<%= lb合計B.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合訓練目標B" runat="server" ControlToValidate="txt符合訓練目標B"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合訓練目標C" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標C.ClientID %>','<%= txt架構規劃完整性C.ClientID %>','<%= txt符合課程時數C.ClientID %>','<%= txt引起學習興趣C.ClientID %>','<%= txt未來工作參考運用C.ClientID %>','<%= lb合計C.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合訓練目標C" runat="server" ControlToValidate="txt符合訓練目標C"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label18" runat="server" Text="教材設計整體架構規劃完整性"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt架構規劃完整性A" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標A.ClientID %>','<%= txt架構規劃完整性A.ClientID %>','<%= txt符合課程時數A.ClientID %>','<%= txt引起學習興趣A.ClientID %>','<%= txt未來工作參考運用A.ClientID %>','<%= lb合計A.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv架構規劃完整性A" runat="server" ControlToValidate="txt架構規劃完整性A"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt架構規劃完整性B" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標B.ClientID %>','<%= txt架構規劃完整性B.ClientID %>','<%= txt符合課程時數B.ClientID %>','<%= txt引起學習興趣B.ClientID %>','<%= txt未來工作參考運用B.ClientID %>','<%= lb合計B.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv架構規劃完整性B" runat="server" ControlToValidate="txt架構規劃完整性B"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt架構規劃完整性C" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標C.ClientID %>','<%= txt架構規劃完整性C.ClientID %>','<%= txt符合課程時數C.ClientID %>','<%= txt引起學習興趣C.ClientID %>','<%= txt未來工作參考運用C.ClientID %>','<%= lb合計C.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv架構規劃完整性C" runat="server" ControlToValidate="txt架構規劃完整性C"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label19" runat="server" Text="教材設計符合課程規劃時數"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合課程時數A" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標A.ClientID %>','<%= txt架構規劃完整性A.ClientID %>','<%= txt符合課程時數A.ClientID %>','<%= txt引起學習興趣A.ClientID %>','<%= txt未來工作參考運用A.ClientID %>','<%= lb合計A.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合課程時數A" runat="server" ControlToValidate="txt符合課程時數A"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合課程時數B" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標B.ClientID %>','<%= txt架構規劃完整性B.ClientID %>','<%= txt符合課程時數B.ClientID %>','<%= txt引起學習興趣B.ClientID %>','<%= txt未來工作參考運用B.ClientID %>','<%= lb合計B.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合課程時數B" runat="server" ControlToValidate="txt符合課程時數B"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt符合課程時數C" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標C.ClientID %>','<%= txt架構規劃完整性C.ClientID %>','<%= txt符合課程時數C.ClientID %>','<%= txt引起學習興趣C.ClientID %>','<%= txt未來工作參考運用C.ClientID %>','<%= lb合計C.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv符合課程時數C" runat="server" ControlToValidate="txt符合課程時數C"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label20" runat="server" Text="教學方法能引起學員的學習興趣"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt引起學習興趣A" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標A.ClientID %>','<%= txt架構規劃完整性A.ClientID %>','<%= txt符合課程時數A.ClientID %>','<%= txt引起學習興趣A.ClientID %>','<%= txt未來工作參考運用A.ClientID %>','<%= lb合計A.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv引起學習興趣A" runat="server" ControlToValidate="txt引起學習興趣A"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt引起學習興趣B" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標B.ClientID %>','<%= txt架構規劃完整性B.ClientID %>','<%= txt符合課程時數B.ClientID %>','<%= txt引起學習興趣B.ClientID %>','<%= txt未來工作參考運用B.ClientID %>','<%= lb合計B.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv引起學習興趣B" runat="server" ControlToValidate="txt引起學習興趣B"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt引起學習興趣C" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標C.ClientID %>','<%= txt架構規劃完整性C.ClientID %>','<%= txt符合課程時數C.ClientID %>','<%= txt引起學習興趣C.ClientID %>','<%= txt未來工作參考運用C.ClientID %>','<%= lb合計C.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv引起學習興趣C" runat="server" ControlToValidate="txt引起學習興趣C"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label21" runat="server" Text="教材設計可做為學員未來工作參考/運用"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt未來工作參考運用A" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標A.ClientID %>','<%= txt架構規劃完整性A.ClientID %>','<%= txt符合課程時數A.ClientID %>','<%= txt引起學習興趣A.ClientID %>','<%= txt未來工作參考運用A.ClientID %>','<%= lb合計A.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv未來工作參考運用A" runat="server" ControlToValidate="txt未來工作參考運用A"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt未來工作參考運用B" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標B.ClientID %>','<%= txt架構規劃完整性B.ClientID %>','<%= txt符合課程時數B.ClientID %>','<%= txt引起學習興趣B.ClientID %>','<%= txt未來工作參考運用B.ClientID %>','<%= lb合計B.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv未來工作參考運用B" runat="server" ControlToValidate="txt未來工作參考運用B"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt未來工作參考運用C" runat="server" CssClass="inputFull" MaxLength="2" ValidationGroup="save"
|
||||
onkeyup="calcTotal('<%= txt符合訓練目標C.ClientID %>','<%= txt架構規劃完整性C.ClientID %>','<%= txt符合課程時數C.ClientID %>','<%= txt引起學習興趣C.ClientID %>','<%= txt未來工作參考運用C.ClientID %>','<%= lb合計C.ClientID %>')">
|
||||
</asp:TextBox>
|
||||
<asp:RangeValidator ID="rgv未來工作參考運用C" runat="server" ControlToValidate="txt未來工作參考運用C"
|
||||
MinimumValue="0" MaximumValue="20" Type="Integer" Display="Dynamic" ErrorMessage="0~20"
|
||||
ValidationGroup="save">
|
||||
</asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label22" runat="server" Text="合計 100%"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計A" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計B" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計C" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"></td>
|
||||
<td class="datadisplay">
|
||||
<asp:LinkButton ID="btnClearA" runat="server"></asp:LinkButton>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:LinkButton ID="btnClearB" runat="server"></asp:LinkButton>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:LinkButton ID="btnClearC" runat="server"></asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label25" runat="server" Text="總評"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt總評" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label26" runat="server" Text="備註"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt備註" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"> </td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:LinkButton ID="btnSave" runat="server" CssClass="button blue80" OnClick="btnSave_Click"
|
||||
OnClientClick="return checkInput();"
|
||||
ValidationGroup="save">
|
||||
儲存</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,286 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Linq;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class PickupMaterial : FormBase
|
||||
{
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程內容 Dao課程內容;
|
||||
private DAC_教材遴選 Dao教材遴選;
|
||||
private int 課程企劃ID;
|
||||
private int 課程序號;
|
||||
|
||||
protected bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 訓練課程內容 >> 教材遴選";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf課程企劃ID.Value = Request["id"];
|
||||
hf課程序號.Value = Request["class"];
|
||||
}
|
||||
課程企劃ID = DAC.GetInt32(hf課程企劃ID.Value);
|
||||
課程序號 = DAC.GetInt32(hf課程序號.Value);
|
||||
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", String.Format("{0}", 課程企劃ID));
|
||||
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao課程內容 = new DAC_訓練課程內容(conn);
|
||||
Dao教材遴選 = new DAC_教材遴選(conn);
|
||||
|
||||
btnClearA.OnClientClick = String.Format("clearMaterial(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\"); return false;",
|
||||
txt教材名稱A.ClientID, txt符合訓練目標A.ClientID, txt架構規劃完整性A.ClientID, txt符合課程時數A.ClientID, txt引起學習興趣A.ClientID, txt未來工作參考運用A.ClientID, lb合計A.ClientID);
|
||||
btnClearB.OnClientClick = String.Format("clearMaterial(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\"); return false;",
|
||||
txt教材名稱B.ClientID, txt符合訓練目標B.ClientID, txt架構規劃完整性B.ClientID, txt符合課程時數B.ClientID, txt引起學習興趣B.ClientID, txt未來工作參考運用B.ClientID, lb合計B.ClientID);
|
||||
btnClearC.OnClientClick = String.Format("clearMaterial(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\"); return false;",
|
||||
txt教材名稱C.ClientID, txt符合訓練目標C.ClientID, txt架構規劃完整性C.ClientID, txt符合課程時數C.ClientID, txt引起學習興趣C.ClientID, txt未來工作參考運用C.ClientID, lb合計C.ClientID);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
UpdateUI();
|
||||
}
|
||||
|
||||
UIControl();
|
||||
|
||||
(Master as PopupForm).RefreshOpener = true;
|
||||
}
|
||||
|
||||
private void UIControl()
|
||||
{
|
||||
btnSave.Visible = 可異動;
|
||||
btnClearA.Visible = 可異動;
|
||||
btnClearB.Visible = 可異動;
|
||||
btnClearC.Visible = 可異動;
|
||||
|
||||
txt教材名稱A.Enabled = 可異動;
|
||||
txt教材名稱B.Enabled = 可異動;
|
||||
txt教材名稱C.Enabled = 可異動;
|
||||
|
||||
txt符合訓練目標A.Enabled = 可異動;
|
||||
txt符合訓練目標B.Enabled = 可異動;
|
||||
txt符合訓練目標C.Enabled = 可異動;
|
||||
|
||||
txt架構規劃完整性A.Enabled = 可異動;
|
||||
txt架構規劃完整性B.Enabled = 可異動;
|
||||
txt架構規劃完整性C.Enabled = 可異動;
|
||||
|
||||
txt符合課程時數A.Enabled = 可異動;
|
||||
txt符合課程時數B.Enabled = 可異動;
|
||||
txt符合課程時數C.Enabled = 可異動;
|
||||
|
||||
txt引起學習興趣A.Enabled = 可異動;
|
||||
txt引起學習興趣B.Enabled = 可異動;
|
||||
txt引起學習興趣C.Enabled = 可異動;
|
||||
|
||||
txt未來工作參考運用A.Enabled = 可異動;
|
||||
txt未來工作參考運用B.Enabled = 可異動;
|
||||
txt未來工作參考運用C.Enabled = 可異動;
|
||||
|
||||
txt總評.Enabled = 可異動;
|
||||
txt備註.Enabled = 可異動;
|
||||
}
|
||||
|
||||
private void UpdateUI()
|
||||
{
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程企劃ID);
|
||||
訓練課程內容List v2 = Dao課程內容.SelectOne(課程企劃ID, 課程序號);
|
||||
教材遴選List v3 = Dao教材遴選.SelectOne(課程企劃ID, 課程序號);
|
||||
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
|
||||
if (v2.Count > 0)
|
||||
{
|
||||
lb課程內容.Text = String.Format("[{0}] {1}", v2[0].節次, v2[0].課程名稱);
|
||||
}
|
||||
|
||||
txt教材名稱A.Text = "";
|
||||
txt符合訓練目標A.Text = "";
|
||||
txt架構規劃完整性A.Text = "";
|
||||
txt符合課程時數A.Text = "";
|
||||
txt引起學習興趣A.Text = "";
|
||||
txt未來工作參考運用A.Text = "";
|
||||
lb合計A.Text = "";
|
||||
|
||||
txt教材名稱B.Text = "";
|
||||
txt符合訓練目標B.Text = "";
|
||||
txt架構規劃完整性B.Text = "";
|
||||
txt符合課程時數B.Text = "";
|
||||
txt引起學習興趣B.Text = "";
|
||||
txt未來工作參考運用B.Text = "";
|
||||
lb合計B.Text = "";
|
||||
|
||||
txt教材名稱C.Text = "";
|
||||
txt符合訓練目標C.Text = "";
|
||||
txt架構規劃完整性C.Text = "";
|
||||
txt符合課程時數C.Text = "";
|
||||
txt引起學習興趣C.Text = "";
|
||||
txt未來工作參考運用C.Text = "";
|
||||
lb合計C.Text = "";
|
||||
|
||||
txt總評.Text = "";
|
||||
txt備註.Text = "";
|
||||
|
||||
if (v3.Count > 0)
|
||||
{
|
||||
if (!String.IsNullOrEmpty(v3[0].教材名稱_A))
|
||||
{
|
||||
txt教材名稱A.Text = v3[0].教材名稱_A;
|
||||
txt符合訓練目標A.Text = v3[0].符合訓練目標_A.ToString();
|
||||
txt架構規劃完整性A.Text = v3[0].架構規劃完整性_A.ToString();
|
||||
txt符合課程時數A.Text = v3[0].符合課程時數_A.ToString();
|
||||
txt引起學習興趣A.Text = v3[0].引起學習興趣_A.ToString();
|
||||
txt未來工作參考運用A.Text = v3[0].未來工作參考運用_A.ToString();
|
||||
lb合計A.Text = (v3[0].符合訓練目標_A + v3[0].架構規劃完整性_A + v3[0].符合課程時數_A + v3[0].引起學習興趣_A + v3[0].未來工作參考運用_A).ToString();
|
||||
}
|
||||
|
||||
if (!String.IsNullOrEmpty(v3[0].教材名稱_B))
|
||||
{
|
||||
txt教材名稱B.Text = v3[0].教材名稱_B;
|
||||
txt符合訓練目標B.Text = v3[0].符合訓練目標_B.ToString();
|
||||
txt架構規劃完整性B.Text = v3[0].架構規劃完整性_B.ToString();
|
||||
txt符合課程時數B.Text = v3[0].符合課程時數_B.ToString();
|
||||
txt引起學習興趣B.Text = v3[0].引起學習興趣_B.ToString();
|
||||
txt未來工作參考運用B.Text = v3[0].未來工作參考運用_B.ToString();
|
||||
lb合計B.Text = (v3[0].符合訓練目標_B + v3[0].架構規劃完整性_B + v3[0].符合課程時數_B + v3[0].引起學習興趣_B + v3[0].未來工作參考運用_B).ToString();
|
||||
}
|
||||
|
||||
if (!String.IsNullOrEmpty(v3[0].教材名稱_C))
|
||||
{
|
||||
txt教材名稱C.Text = v3[0].教材名稱_C;
|
||||
txt符合訓練目標C.Text = v3[0].符合訓練目標_C.ToString();
|
||||
txt架構規劃完整性C.Text = v3[0].架構規劃完整性_C.ToString();
|
||||
txt符合課程時數C.Text = v3[0].符合課程時數_C.ToString();
|
||||
txt引起學習興趣C.Text = v3[0].引起學習興趣_C.ToString();
|
||||
txt未來工作參考運用C.Text = v3[0].未來工作參考運用_C.ToString();
|
||||
lb合計C.Text = (v3[0].符合訓練目標_C + v3[0].架構規劃完整性_C + v3[0].符合課程時數_C + v3[0].引起學習興趣_C + v3[0].未來工作參考運用_C).ToString();
|
||||
}
|
||||
|
||||
txt總評.Text = v3[0].總評;
|
||||
txt備註.Text = v3[0].備註;
|
||||
}
|
||||
}
|
||||
|
||||
private bool Validate分數()
|
||||
{
|
||||
string[] 教材名稱 = { txt教材名稱A.Text.Trim(), txt教材名稱B.Text.Trim(), txt教材名稱C.Text.Trim() };
|
||||
string[][] 分數 = {
|
||||
new[] { txt符合訓練目標A.Text, txt架構規劃完整性A.Text, txt符合課程時數A.Text, txt引起學習興趣A.Text, txt未來工作參考運用A.Text },
|
||||
new[] { txt符合訓練目標B.Text, txt架構規劃完整性B.Text, txt符合課程時數B.Text, txt引起學習興趣B.Text, txt未來工作參考運用B.Text },
|
||||
new[] { txt符合訓練目標C.Text, txt架構規劃完整性C.Text, txt符合課程時數C.Text, txt引起學習興趣C.Text, txt未來工作參考運用C.Text }
|
||||
};
|
||||
string[] 名稱 = { "一", "二", "三" };
|
||||
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
if (String.IsNullOrEmpty(教材名稱[i]))
|
||||
continue;
|
||||
|
||||
foreach (string 值 in 分數[i])
|
||||
{
|
||||
int 分 = DAC.GetInt32(值);
|
||||
if (分 < 0 || 分 > 20)
|
||||
{
|
||||
ClientShowMessage(String.Format("請完整填寫教材{0}的評分(0~20)。", 名稱[i]));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (String.IsNullOrEmpty(txt教材名稱A.Text.Trim())
|
||||
&& String.IsNullOrEmpty(txt教材名稱B.Text.Trim())
|
||||
&& String.IsNullOrEmpty(txt教材名稱C.Text.Trim()))
|
||||
{
|
||||
ClientShowMessage("請至少輸入一項教材名稱。");
|
||||
return;
|
||||
}
|
||||
|
||||
if (!Validate分數())
|
||||
return;
|
||||
|
||||
教材遴選Item item = Dao教材遴選.SelectOne(課程企劃ID, 課程序號).FirstOrDefault();
|
||||
|
||||
if (item == null)
|
||||
{
|
||||
item = new 教材遴選Item()
|
||||
{
|
||||
課程企劃編號 = 課程企劃ID,
|
||||
課程序號 = 課程序號,
|
||||
|
||||
教材名稱_A = txt教材名稱A.Text,
|
||||
符合訓練目標_A = DAC.GetInt32(txt符合訓練目標A.Text),
|
||||
架構規劃完整性_A = DAC.GetInt32(txt架構規劃完整性A.Text),
|
||||
符合課程時數_A = DAC.GetInt32(txt符合課程時數A.Text),
|
||||
引起學習興趣_A = DAC.GetInt32(txt引起學習興趣A.Text),
|
||||
未來工作參考運用_A = DAC.GetInt32(txt未來工作參考運用A.Text),
|
||||
|
||||
教材名稱_B = txt教材名稱B.Text,
|
||||
符合訓練目標_B = DAC.GetInt32(txt符合訓練目標B.Text),
|
||||
架構規劃完整性_B = DAC.GetInt32(txt架構規劃完整性B.Text),
|
||||
符合課程時數_B = DAC.GetInt32(txt符合課程時數B.Text),
|
||||
引起學習興趣_B = DAC.GetInt32(txt引起學習興趣B.Text),
|
||||
未來工作參考運用_B = DAC.GetInt32(txt未來工作參考運用B.Text),
|
||||
|
||||
教材名稱_C = txt教材名稱C.Text,
|
||||
符合訓練目標_C = DAC.GetInt32(txt符合訓練目標C.Text),
|
||||
架構規劃完整性_C = DAC.GetInt32(txt架構規劃完整性C.Text),
|
||||
符合課程時數_C = DAC.GetInt32(txt符合課程時數C.Text),
|
||||
引起學習興趣_C = DAC.GetInt32(txt引起學習興趣C.Text),
|
||||
未來工作參考運用_C = DAC.GetInt32(txt未來工作參考運用C.Text),
|
||||
|
||||
總評 = txt總評.Text,
|
||||
備註 = txt備註.Text
|
||||
};
|
||||
Dao教材遴選.InsertOne(item);
|
||||
}
|
||||
else
|
||||
{
|
||||
item.教材名稱_A = txt教材名稱A.Text;
|
||||
item.符合訓練目標_A = DAC.GetInt32(txt符合訓練目標A.Text);
|
||||
item.架構規劃完整性_A = DAC.GetInt32(txt架構規劃完整性A.Text);
|
||||
item.符合課程時數_A = DAC.GetInt32(txt符合課程時數A.Text);
|
||||
item.引起學習興趣_A = DAC.GetInt32(txt引起學習興趣A.Text);
|
||||
item.未來工作參考運用_A = DAC.GetInt32(txt未來工作參考運用A.Text);
|
||||
|
||||
item.教材名稱_B = txt教材名稱B.Text;
|
||||
item.符合訓練目標_B = DAC.GetInt32(txt符合訓練目標B.Text);
|
||||
item.架構規劃完整性_B = DAC.GetInt32(txt架構規劃完整性B.Text);
|
||||
item.符合課程時數_B = DAC.GetInt32(txt符合課程時數B.Text);
|
||||
item.引起學習興趣_B = DAC.GetInt32(txt引起學習興趣B.Text);
|
||||
item.未來工作參考運用_B = DAC.GetInt32(txt未來工作參考運用B.Text);
|
||||
|
||||
item.教材名稱_C = txt教材名稱C.Text;
|
||||
item.符合訓練目標_C = DAC.GetInt32(txt符合訓練目標C.Text);
|
||||
item.架構規劃完整性_C = DAC.GetInt32(txt架構規劃完整性C.Text);
|
||||
item.符合課程時數_C = DAC.GetInt32(txt符合課程時數C.Text);
|
||||
item.引起學習興趣_C = DAC.GetInt32(txt引起學習興趣C.Text);
|
||||
item.未來工作參考運用_C = DAC.GetInt32(txt未來工作參考運用C.Text);
|
||||
|
||||
item.總評 = txt總評.Text;
|
||||
item.備註 = txt備註.Text;
|
||||
|
||||
Dao教材遴選.UpdateOne(item);
|
||||
}
|
||||
|
||||
UpdateUI();
|
||||
|
||||
ClientShowMessage("儲存成功!");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,557 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupMaterial
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程企劃ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程企劃ID;
|
||||
|
||||
/// <summary>
|
||||
/// Label10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label10;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程序號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程序號;
|
||||
|
||||
/// <summary>
|
||||
/// lb教材一 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb教材一;
|
||||
|
||||
/// <summary>
|
||||
/// lb教材二 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb教材二;
|
||||
|
||||
/// <summary>
|
||||
/// lb教材三 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb教材三;
|
||||
|
||||
/// <summary>
|
||||
/// Label14 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label14;
|
||||
|
||||
/// <summary>
|
||||
/// txt教材名稱A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt教材名稱A;
|
||||
|
||||
/// <summary>
|
||||
/// txt教材名稱B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt教材名稱B;
|
||||
|
||||
/// <summary>
|
||||
/// txt教材名稱C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt教材名稱C;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合訓練目標A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合訓練目標A;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合訓練目標A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合訓練目標A;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合訓練目標B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合訓練目標B;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合訓練目標B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合訓練目標B;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合訓練目標C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合訓練目標C;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合訓練目標C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合訓練目標C;
|
||||
|
||||
/// <summary>
|
||||
/// Label18 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label18;
|
||||
|
||||
/// <summary>
|
||||
/// txt架構規劃完整性A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt架構規劃完整性A;
|
||||
|
||||
/// <summary>
|
||||
/// rgv架構規劃完整性A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv架構規劃完整性A;
|
||||
|
||||
/// <summary>
|
||||
/// txt架構規劃完整性B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt架構規劃完整性B;
|
||||
|
||||
/// <summary>
|
||||
/// rgv架構規劃完整性B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv架構規劃完整性B;
|
||||
|
||||
/// <summary>
|
||||
/// txt架構規劃完整性C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt架構規劃完整性C;
|
||||
|
||||
/// <summary>
|
||||
/// rgv架構規劃完整性C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv架構規劃完整性C;
|
||||
|
||||
/// <summary>
|
||||
/// Label19 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label19;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合課程時數A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合課程時數A;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合課程時數A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合課程時數A;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合課程時數B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合課程時數B;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合課程時數B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合課程時數B;
|
||||
|
||||
/// <summary>
|
||||
/// txt符合課程時數C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt符合課程時數C;
|
||||
|
||||
/// <summary>
|
||||
/// rgv符合課程時數C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv符合課程時數C;
|
||||
|
||||
/// <summary>
|
||||
/// Label20 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label20;
|
||||
|
||||
/// <summary>
|
||||
/// txt引起學習興趣A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt引起學習興趣A;
|
||||
|
||||
/// <summary>
|
||||
/// rgv引起學習興趣A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv引起學習興趣A;
|
||||
|
||||
/// <summary>
|
||||
/// txt引起學習興趣B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt引起學習興趣B;
|
||||
|
||||
/// <summary>
|
||||
/// rgv引起學習興趣B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv引起學習興趣B;
|
||||
|
||||
/// <summary>
|
||||
/// txt引起學習興趣C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt引起學習興趣C;
|
||||
|
||||
/// <summary>
|
||||
/// rgv引起學習興趣C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv引起學習興趣C;
|
||||
|
||||
/// <summary>
|
||||
/// Label21 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label21;
|
||||
|
||||
/// <summary>
|
||||
/// txt未來工作參考運用A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt未來工作參考運用A;
|
||||
|
||||
/// <summary>
|
||||
/// rgv未來工作參考運用A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv未來工作參考運用A;
|
||||
|
||||
/// <summary>
|
||||
/// txt未來工作參考運用B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt未來工作參考運用B;
|
||||
|
||||
/// <summary>
|
||||
/// rgv未來工作參考運用B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv未來工作參考運用B;
|
||||
|
||||
/// <summary>
|
||||
/// txt未來工作參考運用C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt未來工作參考運用C;
|
||||
|
||||
/// <summary>
|
||||
/// rgv未來工作參考運用C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv未來工作參考運用C;
|
||||
|
||||
/// <summary>
|
||||
/// Label22 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label22;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計A;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計B;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計C;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearA;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearB;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearC;
|
||||
|
||||
/// <summary>
|
||||
/// Label25 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label25;
|
||||
|
||||
/// <summary>
|
||||
/// txt總評 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt總評;
|
||||
|
||||
/// <summary>
|
||||
/// Label26 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label26;
|
||||
|
||||
/// <summary>
|
||||
/// txt備註 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt備註;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSave;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,201 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="PickupPeople.aspx.cs" Inherits="Education.Forms.課程企劃.PickupPeople" %>
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lbTypeLabel" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf編號" runat="server" />
|
||||
<asp:HiddenField ID="hf課程別" runat="server" />
|
||||
</td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<asp:Panel ID="pnl必修人員" runat="server" Visible="false">
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lbPeople" runat="server" Text="已加入必修人員"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:CheckBoxList ID="cbl已加入必修人員" runat="server" RepeatColumns="4"
|
||||
RepeatDirection="Horizontal" Width="100%">
|
||||
</asp:CheckBoxList>
|
||||
</td>
|
||||
<td>
|
||||
<asp:LinkButton ID="btnRemove1" runat="server" CssClass="button red80">移除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="pnl選修人員" runat="server" Visible="false">
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label11" runat="server" Text="已加入選修人員"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 600px" class="datainput">
|
||||
<asp:CheckBoxList ID="cbl已加入選修人員" runat="server" RepeatColumns="4"
|
||||
RepeatDirection="Horizontal" Width="100%">
|
||||
</asp:CheckBoxList>
|
||||
</td>
|
||||
<td>
|
||||
<asp:LinkButton ID="btnRemove2" runat="server" CssClass="button red80">移除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</asp:Panel>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label3" runat="server" Text="計畫"></asp:Label>
|
||||
</td>
|
||||
<td>
|
||||
<weblib:WDropDownList ID="ddl計畫" runat="server">
|
||||
</weblib:WDropDownList>
|
||||
</td>
|
||||
<td>
|
||||
<asp:LinkButton ID="btnSelectPeople" runat="server" CssClass="button blue120" OnClick="btnSelectPeople_Click">查詢計畫人員</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption" style="vertical-align: top">
|
||||
<asp:Label ID="Label2" runat="server" Text="可加入訓練對象"></asp:Label>
|
||||
</td>
|
||||
<td style="vertical-align: top" class="datadisplay">
|
||||
<asp:CheckBoxList ID="cbl可加入人員" runat="server" RepeatColumns="4" RepeatDirection="Horizontal"
|
||||
Width="100%">
|
||||
</asp:CheckBoxList>
|
||||
</td>
|
||||
<td style="vertical-align: top;">
|
||||
<asp:LinkButton ID="btnCheckAll" runat="server" CssClass="button blue80" OnClick="btnCheckAll_Click">全選</asp:LinkButton>
|
||||
<asp:LinkButton ID="btnCheckNone" runat="server" CssClass="button blue80" OnClick="btnCheckNone_Click">不選</asp:LinkButton><br />
|
||||
<asp:LinkButton ID="btnAdd1" runat="server" CssClass="button blue120"
|
||||
OnClick="btnAdd_Click">加入必修人員</asp:LinkButton><br />
|
||||
<asp:LinkButton ID="btnAdd2" runat="server" CssClass="button blue120"
|
||||
OnClick="btnAdd2_Click">加入選修人員</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:ObjectDataSource ID="ds必修" runat="server" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select選課狀況" TypeName="Education.DAC_課程報名">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="hf編號" Name="訓練課程編號" PropertyName="Value"
|
||||
Type="Int32" />
|
||||
<asp:Parameter DefaultValue="true" Name="必修" Type="Boolean" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="ds選修" runat="server" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select選課狀況" TypeName="Education.DAC_課程報名">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="hf編號" Name="訓練課程編號" PropertyName="Value"
|
||||
Type="Int32" />
|
||||
<asp:Parameter DefaultValue="false" Name="必修" Type="Boolean" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<h4 style="margin-top: 0.5em; margin-bottom: 0.5em;">必修人員
|
||||
<asp:LinkButton ID="btnRemoveBS" runat="server" CssClass="button red120" OnClick="btnRemoveBS_Click">移除必修人員</asp:LinkButton>
|
||||
<asp:HiddenField ID="hfBSChecked" runat="server" />
|
||||
</h4>
|
||||
<asp:GridView ID="gv必修人員" runat="server" DataSourceID="ds必修"
|
||||
EnableModelValidation="True" AutoGenerateColumns="False" EnableViewState="false">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<HeaderStyle HorizontalAlign="Center" Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" />
|
||||
<HeaderTemplate>
|
||||
<input type="checkbox" id="cbBSSelectAll"/>
|
||||
<label for="cbBSSelectAll">全選</label>
|
||||
</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<input type="checkbox" value='<%# Eval("學員編號") %>' name="cbBSSelect" id='<%# "cbBSSelect_" + Eval("學員編號") %>' />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="學員編號" DataField="學員編號">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="學員姓名" DataField="學員姓名">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="計畫別" DataField="計畫年度名稱">
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="站別" DataField="站別名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="職務" DataField="職務名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<%-- <asp:BoundField HeaderText="等級" DataField="等級名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>--%>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lbEmpty1" Text="目前無必修人員" CssClass="ErrorMessage"></asp:Label>
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
<h4 style="margin-top: 0.5em; margin-bottom: 0.5em;">選修人員報名狀況
|
||||
<asp:LinkButton ID="btnRemoveSS" runat="server" CssClass="button red120" OnClick="btnRemoveSS_Click">取消選修人員</asp:LinkButton>
|
||||
<asp:HiddenField ID="hfSSChecked" runat="server" />
|
||||
</h4>
|
||||
<asp:GridView ID="gv選修人員" runat="server" DataSourceID="ds選修"
|
||||
EnableModelValidation="True" AutoGenerateColumns="False" EnableViewState="false">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<HeaderStyle HorizontalAlign="Center" Width="70px" />
|
||||
<ItemStyle HorizontalAlign="Center" Width="70px" />
|
||||
<HeaderTemplate>
|
||||
<input type="checkbox" id="cbSSSelectAll" />
|
||||
<label for="cbSSSelectAll">全選</label>
|
||||
</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<input type="checkbox" value='<%# Eval("學員編號") %>' name="cbSSSelect" id='<%# "cbSSSelect_" + Eval("學員編號") %>' />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="學員編號" DataField="學員編號">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="學員姓名" DataField="學員姓名">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="計畫別" DataField="計畫年度名稱">
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="站別" DataField="站別名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="職務" DataField="職務名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<%-- <asp:BoundField HeaderText="等級" DataField="等級名稱">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>--%>
|
||||
<asp:TemplateField HeaderText="報名狀態">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Eval("報名狀態", "{0}") == "R" ? "已報名(必修)" : (Eval("報名狀態", "{0}") == "Y" ? "已報名(選修)" : ( Eval("報名狀態", "{0}") == "N" ? "已取消" : (Eval("報名狀態", "{0}") == "S" ? "未報名(選修)" : ""))) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="報名日期">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label2" runat="server" Text='<%# Eval("報名狀態", "{0}") == "Y" ? Eval("報名日期", "{0:yyyy-MM-dd}") : "" %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="取消報名日期">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label3" runat="server" Text='<%# Eval("報名狀態", "{0}") == "N" ? Eval("取消報名日期", "{0:yyyy-MM-dd}") : "" %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<EmptyDataTemplate>
|
||||
<asp:Label runat="server" ID="lbEmpty2" Text="目前無選修人員" CssClass="ErrorMessage"></asp:Label>
|
||||
</EmptyDataTemplate>
|
||||
</asp:GridView>
|
||||
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,315 @@
|
||||
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 PickupPeople : FormBase
|
||||
{
|
||||
private int 課程ID;
|
||||
private string 課程別;
|
||||
private DAC_RASN DaoRASN;
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程計畫別 Dao訓練課程計畫別;
|
||||
private DAC_數位課程 Dao數位課程;
|
||||
private DAC_數位課程計畫別 Dao數位課程計畫別;
|
||||
private DAC_數位課程觀看紀錄 Dao數位課程觀看紀錄;
|
||||
private bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 訓練對象挑選";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf編號.Value = Request["id"];
|
||||
hf課程別.Value = Request["type"];
|
||||
}
|
||||
|
||||
課程ID = DAC.GetInt32(Request["id"]);
|
||||
課程別 = DAC.GetString(hf課程別.Value);
|
||||
|
||||
DaoRASN = new DAC_RASN(conn);
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao訓練課程計畫別 = new DAC_訓練課程計畫別(conn);
|
||||
Dao數位課程 = new DAC_數位課程(conn);
|
||||
Dao數位課程計畫別 = new DAC_數位課程計畫別(conn);
|
||||
Dao數位課程觀看紀錄 = new DAC_數位課程觀看紀錄(conn);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
lbTypeLabel.Text = "訓練課程企劃";
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
|
||||
ddl計畫.DataSource = Dao訓練課程計畫別.Select(課程ID);
|
||||
ddl計畫.DataTextField = "BPPYM";
|
||||
ddl計畫.DataValueField = "BPPYN";
|
||||
ddl計畫.DataBind();
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
lbTypeLabel.Text = "數位課程";
|
||||
數位課程List v1 = Dao數位課程.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0:000000}] {1}", 課程ID, v1[0].課程名稱);
|
||||
}
|
||||
|
||||
ddl計畫.DataSource = Dao數位課程計畫別.Select(課程ID);
|
||||
ddl計畫.DataTextField = "BPPYM";
|
||||
ddl計畫.DataValueField = "BPPYN";
|
||||
ddl計畫.DataBind();
|
||||
|
||||
//pnl選修人員.Visible = false;
|
||||
btnAdd2.Visible = false;
|
||||
btnAdd1.Text = "加入訓練對象";
|
||||
lbPeople.Text = "已加入訓練對象";
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
if (IsPostBack)
|
||||
{
|
||||
gv必修人員.DataBind();
|
||||
gv選修人員.DataBind();
|
||||
}
|
||||
|
||||
UIControl();
|
||||
|
||||
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "start",
|
||||
@"
|
||||
var cbBSSelectAll = document.getElementById(""cbBSSelectAll"");
|
||||
if (cbBSSelectAll)
|
||||
{
|
||||
cbBSSelectAll.onchange = function ()
|
||||
{
|
||||
var BSSelect = document.getElementsByName(""cbBSSelect"");
|
||||
for (i = 0; i < BSSelect.length; i++)
|
||||
{
|
||||
BSSelect.item(i).checked = this.checked;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var cbSSSelectAll = document.getElementById(""cbSSSelectAll"");
|
||||
if (cbSSSelectAll)
|
||||
{
|
||||
cbSSSelectAll.onchange = function ()
|
||||
{
|
||||
var BSSelect = document.getElementsByName(""cbSSSelect"");
|
||||
for (i = 0; i < BSSelect.length; i++)
|
||||
{
|
||||
BSSelect.item(i).checked = this.checked;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var btnRemoveBS = document.getElementById(""" + btnRemoveBS.ClientID + @""");
|
||||
if (btnRemoveBS)
|
||||
{
|
||||
btnRemoveBS.onclick = function ()
|
||||
{
|
||||
if (!confirm(""是否確定移除勾選的必修人員?""))
|
||||
return false;
|
||||
|
||||
var BSValue = """";
|
||||
var BSSelect = document.getElementsByName(""cbBSSelect"");
|
||||
for (i = 0; i < BSSelect.length; i++)
|
||||
{
|
||||
if (BSSelect.item(i).checked)
|
||||
BSValue += BSSelect.item(i).value + ""|"";
|
||||
}
|
||||
document.getElementById(""" + hfBSChecked.ClientID + @""").value = BSValue;
|
||||
}
|
||||
}
|
||||
|
||||
var btnRemoveSS = document.getElementById(""" + btnRemoveSS.ClientID + @""");
|
||||
if (btnRemoveSS)
|
||||
{
|
||||
btnRemoveSS.onclick = function ()
|
||||
{
|
||||
if (!confirm(""是否確定取消勾選的選修人員?""))
|
||||
return false;
|
||||
|
||||
var SSValue = """";
|
||||
var SSSelect = document.getElementsByName(""cbSSSelect"");
|
||||
for (i = 0; i < SSSelect.length; i++)
|
||||
{
|
||||
if (SSSelect.item(i).checked)
|
||||
SSValue += SSSelect.item(i).value + ""|"";
|
||||
}
|
||||
document.getElementById(""" + hfSSChecked.ClientID + @""").value = SSValue;
|
||||
}
|
||||
}", true);
|
||||
|
||||
}
|
||||
|
||||
private void UIControl()
|
||||
{
|
||||
// 可異動 = Dao表單簽核主檔.表單可異動("課程企劃", 課程ID.ToString());
|
||||
可異動 = true;
|
||||
btnAdd1.Visible = 可異動;
|
||||
btnAdd2.Visible = 可異動;
|
||||
btnRemoveBS.Visible = 可異動;
|
||||
btnRemoveSS.Visible = 可異動;
|
||||
}
|
||||
|
||||
private void RefreshUI()
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
cbl已加入必修人員.DataSource = Dao課程報名.Select必修學員(課程ID);
|
||||
cbl已加入選修人員.DataSource = Dao課程報名.Select選修學員(課程ID);
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
cbl已加入必修人員.DataSource = Dao數位課程觀看紀錄.Select必修學員(課程ID);
|
||||
}
|
||||
else
|
||||
return;
|
||||
|
||||
cbl已加入必修人員.DataTextField = "學員姓名";
|
||||
cbl已加入必修人員.DataValueField = "學員編號";
|
||||
cbl已加入必修人員.DataBind();
|
||||
|
||||
cbl已加入選修人員.DataTextField = "學員姓名";
|
||||
cbl已加入選修人員.DataValueField = "學員編號";
|
||||
cbl已加入選修人員.DataBind();
|
||||
|
||||
gv必修人員.DataBind();
|
||||
gv選修人員.DataBind();
|
||||
}
|
||||
|
||||
protected void btnSelectPeople_Click(object sender, EventArgs e)
|
||||
{
|
||||
cbl可加入人員.DataSource = DaoRASN.Select專案人員(ddl計畫.SelectedValue, CompanyId);
|
||||
cbl可加入人員.DataTextField = "Name";
|
||||
cbl可加入人員.DataValueField = "Value";
|
||||
cbl可加入人員.DataBind();
|
||||
|
||||
Check可加入人員(true);
|
||||
}
|
||||
|
||||
private void Check可加入人員(bool selected)
|
||||
{
|
||||
foreach (ListItem item in cbl可加入人員.Items)
|
||||
{
|
||||
item.Selected = selected;
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnCheckAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
Check可加入人員(true);
|
||||
}
|
||||
|
||||
protected void btnCheckNone_Click(object sender, EventArgs e)
|
||||
{
|
||||
Check可加入人員(false);
|
||||
}
|
||||
|
||||
protected void btnAdd_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl可加入人員.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.必修(item.Value, 課程ID, UserId);
|
||||
else if (課程別 == "digital")
|
||||
Dao數位課程觀看紀錄.報名(課程ID, item.Value, UserId);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
protected void btnAdd2_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl可加入人員.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.選修(item.Value, 課程ID, UserId);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
/*
|
||||
protected void btnRemove_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl已加入必修人員.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.取消必修(item.Value, 課程ID, UserId);
|
||||
else if (課程別 == "digital")
|
||||
Dao數位課程觀看紀錄.取消報名(課程ID, item.Value);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
protected void btnRemove2_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl已加入選修人員.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.取消選修(item.Value, 課程ID, UserId);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
*/
|
||||
|
||||
// 移除必修人員
|
||||
protected void btnRemoveBS_Click(object sender, EventArgs e)
|
||||
{
|
||||
string[] IDs = hfBSChecked.Value.Split('|');
|
||||
|
||||
foreach (string id in IDs)
|
||||
{
|
||||
if (id.Length > 0)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.取消必修(id, 課程ID, UserId);
|
||||
else if (課程別 == "digital")
|
||||
Dao數位課程觀看紀錄.取消報名(課程ID, id);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
// 移除選修人員
|
||||
protected void btnRemoveSS_Click(object sender, EventArgs e)
|
||||
{
|
||||
string[] IDs = hfSSChecked.Value.Split('|');
|
||||
|
||||
foreach (string id in IDs)
|
||||
{
|
||||
if (id.Length > 0)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
Dao課程報名.取消選修(id, 課程ID, UserId);
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,278 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupPeople
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// lbTypeLabel 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbTypeLabel;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf編號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf編號;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程別;
|
||||
|
||||
/// <summary>
|
||||
/// pnl必修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnl必修人員;
|
||||
|
||||
/// <summary>
|
||||
/// lbPeople 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbPeople;
|
||||
|
||||
/// <summary>
|
||||
/// cbl已加入必修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.CheckBoxList cbl已加入必修人員;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemove1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemove1;
|
||||
|
||||
/// <summary>
|
||||
/// pnl選修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnl選修人員;
|
||||
|
||||
/// <summary>
|
||||
/// Label11 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label11;
|
||||
|
||||
/// <summary>
|
||||
/// cbl已加入選修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.CheckBoxList cbl已加入選修人員;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemove2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemove2;
|
||||
|
||||
/// <summary>
|
||||
/// Label3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label3;
|
||||
|
||||
/// <summary>
|
||||
/// ddl計畫 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl計畫;
|
||||
|
||||
/// <summary>
|
||||
/// btnSelectPeople 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSelectPeople;
|
||||
|
||||
/// <summary>
|
||||
/// Label2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label2;
|
||||
|
||||
/// <summary>
|
||||
/// cbl可加入人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.CheckBoxList cbl可加入人員;
|
||||
|
||||
/// <summary>
|
||||
/// btnCheckAll 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnCheckAll;
|
||||
|
||||
/// <summary>
|
||||
/// btnCheckNone 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnCheckNone;
|
||||
|
||||
/// <summary>
|
||||
/// btnAdd1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnAdd1;
|
||||
|
||||
/// <summary>
|
||||
/// btnAdd2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnAdd2;
|
||||
|
||||
/// <summary>
|
||||
/// ds必修 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds必修;
|
||||
|
||||
/// <summary>
|
||||
/// ds選修 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds選修;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemoveBS 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemoveBS;
|
||||
|
||||
/// <summary>
|
||||
/// hfBSChecked 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hfBSChecked;
|
||||
|
||||
/// <summary>
|
||||
/// gv必修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv必修人員;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemoveSS 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemoveSS;
|
||||
|
||||
/// <summary>
|
||||
/// hfSSChecked 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hfSSChecked;
|
||||
|
||||
/// <summary>
|
||||
/// gv選修人員 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv選修人員;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,619 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true"
|
||||
CodeBehind="PickupPlace.aspx.cs" Inherits="Education.Forms.課程企劃.PickupPlace" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<%@ Register Src="../簽核/送簽.ascx" TagName="送簽" TagPrefix="uc1" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
<script type="text/javascript">
|
||||
function checkInput() {
|
||||
return true;
|
||||
}
|
||||
|
||||
function selectPlace(id1, id2, id3) {
|
||||
var no1 = $("#<%= GetFormControlId("hf編號") %>").val();
|
||||
var no2 = $("#<%= GetFormControlId("lb編號0") %>").text();
|
||||
var name = $("#<%= GetFormControlId("lb場地名稱") %>").text();
|
||||
|
||||
$("#" + id1).val(no1);
|
||||
$("#" + id2).text("[" + no2 + "] " + name);
|
||||
$("#" + id3).val(name).prop("readonly", true);
|
||||
}
|
||||
|
||||
function clearPlace(id1, id2, id3, id4, id5, id6, id7, id8, id9) {
|
||||
$("#" + id1).val("");
|
||||
$("#" + id2).text("(尚未選擇)");
|
||||
$("#" + id3).val("").prop("readonly", false);
|
||||
$("#" + id4).val("");
|
||||
$("#" + id5).val("");
|
||||
$("#" + id6).val("");
|
||||
$("#" + id7).val("");
|
||||
$("#" + id8).val("");
|
||||
$("#" + id9).text("");
|
||||
}
|
||||
|
||||
</script>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<asp:HiddenField ID="hf課程ID" runat="server" />
|
||||
<asp:ObjectDataSource ID="dsForm場地" runat="server"
|
||||
DataObjectTypeName="Education.場地"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectOne" TypeName="Education.DAC_場地">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="gv場地" Name="編號"
|
||||
PropertyName="SelectedValue" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsGrid場地" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select" TypeName="Education.DAC_場地">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="true" Name="noInputReturnAll"
|
||||
Type="Boolean" />
|
||||
<asp:ControlParameter ControlID="txt單位名稱Search" Name="單位名稱"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt場地名稱Search" Name="場地名稱"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt場地類型Search" Name="場地類型"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt聯絡人Search" Name="聯絡人"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt聯絡人電話Search"
|
||||
Name="聯絡人電話" PropertyName="Text" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<%-- <uc1:送簽 ID="送簽1" runat="server" 表單類別="場地遴選" OnDataBinding="送簽1_DataBinding" />
|
||||
--%>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 125px">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table style="width: 100%; table-layout: fixed;">
|
||||
<tr>
|
||||
<td style="width: 125px"> </td>
|
||||
<td class="captionCenter" style="width: 33%">
|
||||
<asp:Label ID="Label11" runat="server" Text="場地一"></asp:Label>
|
||||
<asp:LinkButton ID="btnPlaceA" runat="server"
|
||||
CssClass="button blue60" CausesValidation="false">挑選</asp:LinkButton>
|
||||
</td>
|
||||
<td class="captionCenter" style="width: 33%">
|
||||
<asp:Label ID="Label12" runat="server" Text="場地二"></asp:Label>
|
||||
<asp:LinkButton ID="btnPlaceB" runat="server"
|
||||
CssClass="button blue60" CausesValidation="false">挑選</asp:LinkButton>
|
||||
</td>
|
||||
<td class="captionCenter" style="width: 33%">
|
||||
<asp:Label ID="Label13" runat="server" Text="場地三"></asp:Label>
|
||||
<asp:LinkButton ID="btnPlaceC" runat="server"
|
||||
CssClass="button blue60" CausesValidation="false">挑選</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label16" runat="server" Text="場地編號名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lbPlaceA" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf場地A" runat="server" />
|
||||
<span id="msg場地A" class="ErrorMessage" style="display: none">請選擇場地一</span>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lbPlaceB" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf場地B" runat="server" />
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lbPlaceC" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf場地C" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label1" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt場地名稱A" runat="server" CssClass="inputFull" MaxLength="200"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt場地名稱B" runat="server" CssClass="inputFull" MaxLength="200"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt場地名稱C" runat="server" CssClass="inputFull" MaxLength="200"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label17" runat="server" Text="安全舒適 30%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt安全舒適A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txt安全舒適A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-30" MaximumValue="30" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator runat="server" ID="rfv安全舒適A" ControlToValidate="txt安全舒適A"
|
||||
CssClass="ErrorMessage" ErrorMessage="請輸入" Display="Dynamic" ValidationGroup="save" />
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt安全舒適B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="txt安全舒適B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-30" MaximumValue="30" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt安全舒適C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator3" runat="server" ControlToValidate="txt安全舒適C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-30" MaximumValue="30" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label18" runat="server" Text="空間大小 20%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt空間大小A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator4" runat="server" ControlToValidate="txt空間大小A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator runat="server" ID="rfv空間大小A" ControlToValidate="txt空間大小A"
|
||||
CssClass="ErrorMessage" ErrorMessage="請輸入" Display="Dynamic" ValidationGroup="save" />
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt空間大小B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator5" runat="server" ControlToValidate="txt空間大小B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt空間大小C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator6" runat="server" ControlToValidate="txt空間大小C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label19" runat="server" Text="價格合理 20%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt價格合理A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator7" runat="server" ControlToValidate="txt價格合理A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator runat="server" ID="rfv價格合理A" ControlToValidate="txt價格合理A"
|
||||
CssClass="ErrorMessage" ErrorMessage="請輸入" Display="Dynamic" ValidationGroup="save" />
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt價格合理B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator8" runat="server" ControlToValidate="txt價格合理B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt價格合理C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator9" runat="server" ControlToValidate="txt價格合理C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label20" runat="server" Text="交通便利 20%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt交通便利A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator10" runat="server" ControlToValidate="txt交通便利A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator runat="server" ID="RequiredFieldValidator4" ControlToValidate="txt交通便利A"
|
||||
CssClass="ErrorMessage" ErrorMessage="請輸入" Display="Dynamic" ValidationGroup="save" />
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt交通便利B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator11" runat="server" ControlToValidate="txt交通便利B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt交通便利C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator12" runat="server" ControlToValidate="txt交通便利C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label21" runat="server" Text="設備完善 10%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt設備完善A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator13" runat="server" ControlToValidate="txt設備完善A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator runat="server" ID="rfv設備完善A" ControlToValidate="txt設備完善A"
|
||||
CssClass="ErrorMessage" ErrorMessage="請輸入" Display="Dynamic" ValidationGroup="save" />
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt設備完善B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator14" runat="server" ControlToValidate="txt設備完善B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt設備完善C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator15" runat="server" ControlToValidate="txt設備完善C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label22" runat="server" Text="合計 100%"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計A" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計B" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計C" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"> </td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearA" runat="server"
|
||||
CssClass="button red80" CausesValidation="false">清除</asp:LinkButton>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearB" runat="server"
|
||||
CssClass="button red80" CausesValidation="false">清除</asp:LinkButton>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearC" runat="server"
|
||||
CssClass="button red80" CausesValidation="false">清除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label23" runat="server" Text="總評"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt總評" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label24" runat="server" Text="備註"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt備註" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"> </td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:LinkButton ID="btnSave" runat="server" CssClass="button blue80" OnClick="btnSave_Click"
|
||||
ValidationGroup="save" OnClientClick="return checkInput();">儲存</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:Panel runat="server" ID="pnlPlace">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 80px">
|
||||
<asp:Label ID="lb單位名稱Label0" runat="server" Text="單位名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt單位名稱Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption" style="width: 90px">
|
||||
<asp:Label ID="lb場地名稱Label0" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt場地名稱Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="20" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption" style="width: 80px">
|
||||
<asp:Label ID="lb場地類型Label0" runat="server" Text="場地類型"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" style="width: 120px">
|
||||
<asp:TextBox ID="txt場地類型Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="20" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnPlaceSearch" runat="server"
|
||||
CssClass="button blue80" OnClick="btnPlaceSearch_Click"
|
||||
Text="查詢" />
|
||||
<asp:Label ID="lbMessage場地" runat="server"
|
||||
CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人Label0" runat="server" Text="聯絡人"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt聯絡人Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人電話Label0" runat="server" Text="聯絡人電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt聯絡人電話Search" runat="server"
|
||||
CssClass="inputFull" MaxLength="30" Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td> </td>
|
||||
<td class="datainput"> </td>
|
||||
<td class="datainput"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:FormView ID="fv場地" runat="server"
|
||||
DataKeyNames="編號,DB_APPNO" DataSourceID="dsForm場地"
|
||||
EnableModelValidation="True"
|
||||
OnDataBound="fv場地_DataBound" CellPadding="0">
|
||||
<ItemTemplate>
|
||||
<table border="0"
|
||||
style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 80px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 120px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 270px;"></td>
|
||||
<td class="widthcontrol" colspan="1" style="width: 270px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb編號Label1" runat="server" Text="編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb編號0" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("編號", "{0:0000}") %>'></asp:Label>
|
||||
<asp:HiddenField ID="hf編號" runat="server" Value='<%# Bind("編號") %>'></asp:HiddenField>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb單位名稱Label" runat="server" Text="單位名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb單位名稱" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("單位名稱") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption" colspan="2" style="text-align: center">
|
||||
<asp:Label ID="lb照片一Label" runat="server"
|
||||
Text="照片 (點擊圖片檢視大圖)"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb場地名稱Label" runat="server" Text="場地名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb場地名稱" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("場地名稱") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb場地類型Label" runat="server" Text="場地類型"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb場地類型" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("場地類型") %>'></asp:Label>
|
||||
</td>
|
||||
<td rowspan="8"
|
||||
style="text-align: center; vertical-align: top;">
|
||||
<asp:Image ID="Image1" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.場地照片路徑 + "T_" + Eval("編號", "{0:000000}") + "_1.jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>' />
|
||||
</td>
|
||||
<td rowspan="8"
|
||||
style="text-align: center; vertical-align: top;">
|
||||
<asp:Image ID="Image2" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.場地照片路徑 + "T_" + Eval("編號", "{0:000000}") + "_2.jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>' />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb價格Label" runat="server" Text="價格"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb價格" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("價格") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb坪數Label" runat="server" Text="坪數"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb坪數" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("坪數") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb容納人數Label" runat="server" Text="容納人數"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb容納人數" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("容納人數") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb地址_郵編Label" runat="server" Text="地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb地址_郵編" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_郵編") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_縣市" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_縣市") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_鄉鎮市區" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_鄉鎮市區") %>'></asp:Label>
|
||||
<asp:Label ID="lb地址_街道地址" runat="server" CssClass="input"
|
||||
Text='<%# Bind("地址_街道地址") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb捷運可到Label" runat="server" Text="交通便利"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Panel ID="Panel1" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("捷運可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb捷運分鐘Label" runat="server" Text="捷運"></asp:Label>
|
||||
<asp:Label ID="lb捷運分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("捷運分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="Label5" runat="server" Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel2" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("公車可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb公車可到Label" runat="server" Text="公車"></asp:Label>
|
||||
<asp:Label ID="lb公車分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("公車分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="Label6" runat="server" Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel3" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("火車可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb火車可到Label0" runat="server" Text="火車"></asp:Label>
|
||||
<asp:Label ID="lb火車分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("火車分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="lb火車可到Label" runat="server"
|
||||
Text="分鐘 "></asp:Label>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel4" runat="server"
|
||||
Style="display: inline;"
|
||||
Visible='<%# Eval("步行可到", "{0}") == "Y" %>'>
|
||||
<asp:Label ID="lb步行可到Label" runat="server" Text="步行"></asp:Label>
|
||||
<asp:Label ID="lb步行分鐘" runat="server" CssClass="input"
|
||||
Text='<%# Bind("步行分鐘") %>'></asp:Label>
|
||||
<asp:Label ID="lb步行分鐘Label" runat="server" Text="分鐘"></asp:Label>
|
||||
</asp:Panel>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb設備提供Label" runat="server" Text="設備提供"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb設備提供" runat="server" CssClass="inputFull"
|
||||
Text='<%# Eval("設備提供", "{0}").Replace("\r", "<br/>") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人Label" runat="server" Text="聯絡人"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb聯絡人" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("聯絡人") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb聯絡人電話Label" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb聯絡人電話" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("聯絡人電話") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb傳真Label" runat="server" Text="傳真"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb傳真" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("傳真") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電子郵件Label" runat="server" Text="電子郵件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb電子郵件" runat="server" CssClass="inputFull"
|
||||
Text='<%# Bind("電子郵件") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb備註Label" runat="server" Text="備註"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb備註" runat="server" CssClass="inputFull"
|
||||
Text='<%# Eval("備註", "{0}").Replace("\r", "<br/>") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</ItemTemplate>
|
||||
</asp:FormView>
|
||||
<asp:GridView ID="gv場地" runat="server"
|
||||
AllowPaging="True" AutoGenerateColumns="False"
|
||||
DataKeyNames="編號" DataSourceID="dsGrid場地"
|
||||
EnableModelValidation="True">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="編號" SortExpression="編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label14" runat="server"
|
||||
Text='<%# Bind("編號", "{0:0000}") %>'></asp:Label>
|
||||
<asp:LinkButton ID="LinkButton2" runat="server"
|
||||
CausesValidation="False" CommandName="Select"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="2.5em" />
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="單位名稱" HeaderText="單位名稱"
|
||||
SortExpression="單位名稱" />
|
||||
<asp:BoundField DataField="場地名稱" HeaderText="場地名稱"
|
||||
SortExpression="場地名稱" />
|
||||
<asp:BoundField DataField="場地類型" HeaderText="場地類型"
|
||||
SortExpression="場地類型" />
|
||||
<asp:BoundField DataField="價格" HeaderText="價格"
|
||||
SortExpression="價格">
|
||||
<HeaderStyle Width="3.5em" />
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="坪數" HeaderText="坪數"
|
||||
SortExpression="坪數">
|
||||
<HeaderStyle Width="2.5em" />
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="容納人數" HeaderText="容納人數"
|
||||
SortExpression="容納人數">
|
||||
<HeaderStyle Width="2.5em" />
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="地址">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label15" runat="server"
|
||||
Text='<%# Bind("地址_郵編") %>'></asp:Label>
|
||||
<asp:Label ID="Label2" runat="server"
|
||||
Text='<%# Bind("地址_縣市") %>'></asp:Label>
|
||||
<asp:Label ID="Label3" runat="server"
|
||||
Text='<%# Bind("地址_鄉鎮市區") %>'></asp:Label>
|
||||
<asp:Label ID="Label4" runat="server"
|
||||
Text='<%# Bind("地址_街道地址") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="聯絡人" HeaderText="聯絡人"
|
||||
SortExpression="聯絡人" />
|
||||
<asp:BoundField DataField="聯絡人電話" HeaderText="聯絡人電話"
|
||||
SortExpression="聯絡人電話" />
|
||||
<asp:BoundField DataField="電子郵件" HeaderText="電子郵件"
|
||||
SortExpression="電子郵件" />
|
||||
<asp:BoundField DataField="傳真" HeaderText="傳真"
|
||||
SortExpression="傳真" />
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager1" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Panel>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,467 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.IO;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class PickupPlace : FormBase
|
||||
{
|
||||
private DAC_場地遴選 Dao場地遴選;
|
||||
private int 課程ID;
|
||||
private bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 場地遴選";
|
||||
Title = FunctionName;
|
||||
if (!IsPostBack)
|
||||
hf課程ID.Value = Request["ID"];
|
||||
課程ID = DAC.GetInt32(hf課程ID.Value);
|
||||
|
||||
Dao場地遴選 = new DAC_場地遴選(conn);
|
||||
|
||||
Form_View = fv場地;
|
||||
Grid_View = gv場地;
|
||||
|
||||
if (IsPostBack)
|
||||
{
|
||||
Grid_View.DataBind();
|
||||
|
||||
lbPlaceA.Text = "(尚未選擇)";
|
||||
lbPlaceB.Text = "(尚未選擇)";
|
||||
lbPlaceC.Text = "(尚未選擇)";
|
||||
|
||||
if (hf場地A.Value != null && hf場地A.Value.Length > 0)
|
||||
{
|
||||
lbPlaceA.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf場地A.Value), Get場地名稱(hf場地A.Value));
|
||||
}
|
||||
if (hf場地B.Value != null && hf場地B.Value.Length > 0)
|
||||
{
|
||||
lbPlaceB.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf場地B.Value), Get場地名稱(hf場地B.Value));
|
||||
}
|
||||
if (hf場地C.Value != null && hf場地C.Value.Length > 0)
|
||||
{
|
||||
lbPlaceC.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf場地C.Value), Get場地名稱(hf場地C.Value));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
UpdateUI();
|
||||
}
|
||||
|
||||
btnPlaceA.OnClientClick = String.Format("selectPlace(\"{0}\", \"{1}\", \"{2}\"); return false;", hf場地A.ClientID, lbPlaceA.ClientID, txt場地名稱A.ClientID);
|
||||
btnPlaceB.OnClientClick = String.Format("selectPlace(\"{0}\", \"{1}\", \"{2}\"); return false;", hf場地B.ClientID, lbPlaceB.ClientID, txt場地名稱B.ClientID);
|
||||
btnPlaceC.OnClientClick = String.Format("selectPlace(\"{0}\", \"{1}\", \"{2}\"); return false;", hf場地C.ClientID, lbPlaceC.ClientID, txt場地名稱C.ClientID);
|
||||
|
||||
btnClearA.OnClientClick = String.Format("clearPlace(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\"); return false;",
|
||||
hf場地A.ClientID, lbPlaceA.ClientID, txt場地名稱A.ClientID, txt安全舒適A.ClientID, txt空間大小A.ClientID, txt價格合理A.ClientID, txt交通便利A.ClientID, txt設備完善A.ClientID, lb合計A.ClientID);
|
||||
btnClearB.OnClientClick = String.Format("clearPlace(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\"); return false;",
|
||||
hf場地B.ClientID, lbPlaceB.ClientID, txt場地名稱B.ClientID, txt安全舒適B.ClientID, txt空間大小B.ClientID, txt價格合理B.ClientID, txt交通便利B.ClientID, txt設備完善B.ClientID, lb合計B.ClientID);
|
||||
btnClearC.OnClientClick = String.Format("clearPlace(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\"); return false;",
|
||||
hf場地C.ClientID, lbPlaceC.ClientID, txt場地名稱C.ClientID, txt安全舒適C.ClientID, txt空間大小C.ClientID, txt價格合理C.ClientID, txt交通便利C.ClientID, txt設備完善C.ClientID, lb合計C.ClientID);
|
||||
|
||||
UIControl();
|
||||
|
||||
(Master as PopupForm).RefreshOpener = true;
|
||||
}
|
||||
|
||||
private void UIControl()
|
||||
{
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", 課程ID.ToString());
|
||||
btnPlaceA.Visible = 可異動;
|
||||
btnPlaceB.Visible = 可異動;
|
||||
btnPlaceC.Visible = 可異動;
|
||||
btnSave.Visible = 可異動;
|
||||
//btnSaveA.Visible = 可異動;
|
||||
//btnSaveB.Visible = 可異動;
|
||||
//btnSaveC.Visible = 可異動;
|
||||
btnClearA.Visible = 可異動;
|
||||
btnClearB.Visible = 可異動;
|
||||
btnClearC.Visible = 可異動;
|
||||
|
||||
txt場地名稱A.Enabled = 可異動;
|
||||
txt場地名稱B.Enabled = 可異動;
|
||||
txt場地名稱C.Enabled = 可異動;
|
||||
//btnSaveComment.Visible = 可異動;
|
||||
|
||||
pnlPlace.Visible = 可異動;
|
||||
}
|
||||
|
||||
protected void UpdateUI()
|
||||
{
|
||||
訓練課程企劃List v1 = Dao訓練課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
|
||||
//送簽1.表單ID = hf課程ID.Value;
|
||||
//送簽1.表單ID格式 = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
//送簽1.訓練課程企劃編號 = 課程ID;
|
||||
//送簽1.編號2 = 0;
|
||||
//送簽1.DataBind();
|
||||
|
||||
lbPlaceA.Text = "(尚未選擇)";
|
||||
lbPlaceB.Text = "(尚未選擇)";
|
||||
lbPlaceC.Text = "(尚未選擇)";
|
||||
hf場地A.Value = "";
|
||||
hf場地B.Value = "";
|
||||
hf場地C.Value = "";
|
||||
|
||||
txt安全舒適A.Text = "";
|
||||
txt空間大小A.Text = "";
|
||||
txt價格合理A.Text = "";
|
||||
txt交通便利A.Text = "";
|
||||
txt設備完善A.Text = "";
|
||||
txt場地名稱A.Text = "";
|
||||
txt場地名稱A.Enabled = true;
|
||||
lb合計A.Text = "";
|
||||
txt安全舒適B.Text = "";
|
||||
txt空間大小B.Text = "";
|
||||
txt價格合理B.Text = "";
|
||||
txt交通便利B.Text = "";
|
||||
txt設備完善B.Text = "";
|
||||
txt場地名稱B.Text = "";
|
||||
txt場地名稱B.Enabled = true;
|
||||
lb合計B.Text = "";
|
||||
txt安全舒適C.Text = "";
|
||||
txt空間大小C.Text = "";
|
||||
txt價格合理C.Text = "";
|
||||
txt交通便利C.Text = "";
|
||||
txt設備完善C.Text = "";
|
||||
txt場地名稱C.Text = "";
|
||||
txt場地名稱C.Enabled = true;
|
||||
lb合計C.Text = "";
|
||||
|
||||
txt總評.Text = "";
|
||||
txt備註.Text = "";
|
||||
|
||||
場地遴選List 場地 = Dao場地遴選.SelectOne(課程ID);
|
||||
if (場地.Count > 0)
|
||||
{
|
||||
if (場地[0].場地編號_A > 0)
|
||||
{
|
||||
var venueName = Get場地名稱(場地[0].場地編號_A);
|
||||
lbPlaceA.Text = String.Format("[{0:0000}] {1}", 場地[0].場地編號_A, venueName);
|
||||
hf場地A.Value = 場地[0].場地編號_A.ToString();
|
||||
txt場地名稱A.Text = venueName;
|
||||
txt場地名稱A.Enabled = false;
|
||||
txt安全舒適A.Text = 場地[0].安全舒適_A.ToString();
|
||||
txt空間大小A.Text = 場地[0].空間大小_A.ToString();
|
||||
txt價格合理A.Text = 場地[0].價格合理_A.ToString();
|
||||
txt交通便利A.Text = 場地[0].交通便利_A.ToString();
|
||||
txt設備完善A.Text = 場地[0].設備完善_A.ToString();
|
||||
lb合計A.Text = 場地[0].合計_A.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(場地[0].場地名稱_A))
|
||||
{
|
||||
txt場地名稱A.Text = 場地[0].場地名稱_A;
|
||||
txt安全舒適A.Text = 場地[0].安全舒適_A.ToString();
|
||||
txt空間大小A.Text = 場地[0].空間大小_A.ToString();
|
||||
txt價格合理A.Text = 場地[0].價格合理_A.ToString();
|
||||
txt交通便利A.Text = 場地[0].交通便利_A.ToString();
|
||||
txt設備完善A.Text = 場地[0].設備完善_A.ToString();
|
||||
lb合計A.Text = 場地[0].合計_A.ToString();
|
||||
}
|
||||
|
||||
if (場地[0].場地編號_B > 0)
|
||||
{
|
||||
var venueName = Get場地名稱(場地[0].場地編號_B);
|
||||
lbPlaceB.Text = String.Format("[{0:0000}] {1}", 場地[0].場地編號_B, venueName);
|
||||
hf場地B.Value = 場地[0].場地編號_B.ToString();
|
||||
txt場地名稱B.Text = venueName;
|
||||
txt場地名稱B.Enabled = false;
|
||||
txt安全舒適B.Text = 場地[0].安全舒適_B.ToString();
|
||||
txt空間大小B.Text = 場地[0].空間大小_B.ToString();
|
||||
txt價格合理B.Text = 場地[0].價格合理_B.ToString();
|
||||
txt交通便利B.Text = 場地[0].交通便利_B.ToString();
|
||||
txt設備完善B.Text = 場地[0].設備完善_B.ToString();
|
||||
lb合計B.Text = 場地[0].合計_B.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(場地[0].場地名稱_B))
|
||||
{
|
||||
txt場地名稱B.Text = 場地[0].場地名稱_B;
|
||||
txt安全舒適B.Text = 場地[0].安全舒適_B.ToString();
|
||||
txt空間大小B.Text = 場地[0].空間大小_B.ToString();
|
||||
txt價格合理B.Text = 場地[0].價格合理_B.ToString();
|
||||
txt交通便利B.Text = 場地[0].交通便利_B.ToString();
|
||||
txt設備完善B.Text = 場地[0].設備完善_B.ToString();
|
||||
lb合計B.Text = 場地[0].合計_B.ToString();
|
||||
}
|
||||
|
||||
if (場地[0].場地編號_C > 0)
|
||||
{
|
||||
var venueName = Get場地名稱(場地[0].場地編號_C);
|
||||
lbPlaceC.Text = String.Format("[{0:0000}] {1}", 場地[0].場地編號_C, venueName);
|
||||
hf場地C.Value = 場地[0].場地編號_C.ToString();
|
||||
txt場地名稱C.Text = venueName;
|
||||
txt場地名稱C.Enabled = false;
|
||||
txt安全舒適C.Text = 場地[0].安全舒適_C.ToString();
|
||||
txt空間大小C.Text = 場地[0].空間大小_C.ToString();
|
||||
txt價格合理C.Text = 場地[0].價格合理_C.ToString();
|
||||
txt交通便利C.Text = 場地[0].交通便利_C.ToString();
|
||||
txt設備完善C.Text = 場地[0].設備完善_C.ToString();
|
||||
lb合計C.Text = 場地[0].合計_C.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(場地[0].場地名稱_C))
|
||||
{
|
||||
txt場地名稱C.Text = 場地[0].場地名稱_C;
|
||||
txt安全舒適C.Text = 場地[0].安全舒適_C.ToString();
|
||||
txt空間大小C.Text = 場地[0].空間大小_C.ToString();
|
||||
txt價格合理C.Text = 場地[0].價格合理_C.ToString();
|
||||
txt交通便利C.Text = 場地[0].交通便利_C.ToString();
|
||||
txt設備完善C.Text = 場地[0].設備完善_C.ToString();
|
||||
lb合計C.Text = 場地[0].合計_C.ToString();
|
||||
}
|
||||
|
||||
txt總評.Text = 場地[0].總評;
|
||||
txt備註.Text = 場地[0].備註;
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnPlaceSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
gv場地.DataBind();
|
||||
|
||||
if (gv場地.Rows.Count == 0)
|
||||
lbMessage場地.Text = "請輸入適當的查詢條件重新查詢";
|
||||
}
|
||||
|
||||
//protected void btnPlaceA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf場地A.Value = DAC.GetString(fv場地.SelectedValue);
|
||||
// 場地List d = Dao場地.SelectOne(DAC.GetInt32(fv場地.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lbPlaceA.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].場地名稱);
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnPlaceB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf場地B.Value = DAC.GetString(fv場地.SelectedValue);
|
||||
// 場地List d = Dao場地.SelectOne(DAC.GetInt32(fv場地.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lbPlaceB.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].場地名稱);
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnPlaceC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf場地C.Value = DAC.GetString(fv場地.SelectedValue);
|
||||
// 場地List d = Dao場地.SelectOne(DAC.GetInt32(fv場地.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lbPlaceC.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].場地名稱);
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnClearA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.ClearPlace(課程ID, "A");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnClearB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.ClearPlace(課程ID, "B");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnClearC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.ClearPlace(課程ID, "C");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.UpdatePlace(課程ID, "A",
|
||||
// DAC.GetInt32(hf場地A.Value),
|
||||
// DAC.GetInt32(txt安全舒適A.Text),
|
||||
// DAC.GetInt32(txt空間大小A.Text),
|
||||
// DAC.GetInt32(txt價格合理A.Text),
|
||||
// DAC.GetInt32(txt交通便利A.Text),
|
||||
// DAC.GetInt32(txt設備完善A.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.UpdatePlace(課程ID, "B",
|
||||
// DAC.GetInt32(hf場地B.Value),
|
||||
// DAC.GetInt32(txt安全舒適B.Text),
|
||||
// DAC.GetInt32(txt空間大小B.Text),
|
||||
// DAC.GetInt32(txt價格合理B.Text),
|
||||
// DAC.GetInt32(txt交通便利B.Text),
|
||||
// DAC.GetInt32(txt設備完善B.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao場地遴選.UpdatePlace(課程ID, "C",
|
||||
// DAC.GetInt32(hf場地C.Value),
|
||||
// DAC.GetInt32(txt安全舒適C.Text),
|
||||
// DAC.GetInt32(txt空間大小C.Text),
|
||||
// DAC.GetInt32(txt價格合理C.Text),
|
||||
// DAC.GetInt32(txt交通便利C.Text),
|
||||
// DAC.GetInt32(txt設備完善C.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
場地遴選 item = Dao場地遴選.SelectOne(課程ID).FirstOrDefault();
|
||||
|
||||
if (item == null)
|
||||
{
|
||||
item = new 場地遴選()
|
||||
{
|
||||
課程企劃編號 = 課程ID,
|
||||
|
||||
場地編號_A = DAC.GetInt32(hf場地A.Value),
|
||||
場地名稱_A = txt場地名稱A.Text,
|
||||
安全舒適_A = DAC.GetInt32(txt安全舒適A.Text),
|
||||
空間大小_A = DAC.GetInt32(txt空間大小A.Text),
|
||||
價格合理_A = DAC.GetInt32(txt價格合理A.Text),
|
||||
交通便利_A = DAC.GetInt32(txt交通便利A.Text),
|
||||
設備完善_A = DAC.GetInt32(txt設備完善A.Text),
|
||||
|
||||
場地編號_B = DAC.GetInt32(hf場地B.Value),
|
||||
場地名稱_B = txt場地名稱B.Text,
|
||||
安全舒適_B = DAC.GetInt32(txt安全舒適B.Text),
|
||||
空間大小_B = DAC.GetInt32(txt空間大小B.Text),
|
||||
價格合理_B = DAC.GetInt32(txt價格合理B.Text),
|
||||
交通便利_B = DAC.GetInt32(txt交通便利B.Text),
|
||||
設備完善_B = DAC.GetInt32(txt設備完善B.Text),
|
||||
|
||||
場地編號_C = DAC.GetInt32(hf場地C.Value),
|
||||
場地名稱_C = txt場地名稱C.Text,
|
||||
安全舒適_C = DAC.GetInt32(txt安全舒適C.Text),
|
||||
空間大小_C = DAC.GetInt32(txt空間大小C.Text),
|
||||
價格合理_C = DAC.GetInt32(txt價格合理C.Text),
|
||||
交通便利_C = DAC.GetInt32(txt交通便利C.Text),
|
||||
設備完善_C = DAC.GetInt32(txt設備完善C.Text),
|
||||
|
||||
總評 = txt總評.Text,
|
||||
備註 = txt備註.Text
|
||||
};
|
||||
Dao場地遴選.InsertOne(item);
|
||||
}
|
||||
else
|
||||
{
|
||||
item.場地編號_A = DAC.GetInt32(hf場地A.Value);
|
||||
item.場地名稱_A = txt場地名稱A.Text;
|
||||
item.安全舒適_A = DAC.GetInt32(txt安全舒適A.Text);
|
||||
item.空間大小_A = DAC.GetInt32(txt空間大小A.Text);
|
||||
item.價格合理_A = DAC.GetInt32(txt價格合理A.Text);
|
||||
item.交通便利_A = DAC.GetInt32(txt交通便利A.Text);
|
||||
item.設備完善_A = DAC.GetInt32(txt設備完善A.Text);
|
||||
|
||||
item.場地編號_B = DAC.GetInt32(hf場地B.Value);
|
||||
item.場地名稱_B = txt場地名稱B.Text;
|
||||
item.安全舒適_B = DAC.GetInt32(txt安全舒適B.Text);
|
||||
item.空間大小_B = DAC.GetInt32(txt空間大小B.Text);
|
||||
item.價格合理_B = DAC.GetInt32(txt價格合理B.Text);
|
||||
item.交通便利_B = DAC.GetInt32(txt交通便利B.Text);
|
||||
item.設備完善_B = DAC.GetInt32(txt設備完善B.Text);
|
||||
|
||||
item.場地編號_C = DAC.GetInt32(hf場地C.Value);
|
||||
item.場地名稱_C = txt場地名稱C.Text;
|
||||
item.安全舒適_C = DAC.GetInt32(txt安全舒適C.Text);
|
||||
item.空間大小_C = DAC.GetInt32(txt空間大小C.Text);
|
||||
item.價格合理_C = DAC.GetInt32(txt價格合理C.Text);
|
||||
item.交通便利_C = DAC.GetInt32(txt交通便利C.Text);
|
||||
item.設備完善_C = DAC.GetInt32(txt設備完善C.Text);
|
||||
|
||||
item.總評 = txt總評.Text;
|
||||
item.備註 = txt備註.Text;
|
||||
|
||||
Dao場地遴選.UpdateOne(item);
|
||||
}
|
||||
|
||||
UpdateUI();
|
||||
|
||||
ClientShowMessage("儲存成功!");
|
||||
}
|
||||
|
||||
protected void btnSaveComment_Click(object sender, EventArgs e)
|
||||
{
|
||||
Dao場地遴選.UpdateComment(課程ID, txt總評.Text, txt備註.Text);
|
||||
}
|
||||
|
||||
protected void fv場地_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (fv場地.CurrentMode == FormViewMode.ReadOnly)
|
||||
{
|
||||
int 編號 = DAC.GetInt32(fv場地.SelectedValue);
|
||||
|
||||
Image image1 = (fv場地.FindControl("Image1") as Image);
|
||||
if (image1 != null)
|
||||
{
|
||||
string[] tmp = image1.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image1.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image1.Attributes.Remove("onclick");
|
||||
image1.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image1.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.場地照片路徑 + "{0:000000}_1.jpg", 編號)));
|
||||
image1.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
|
||||
Image image2 = (fv場地.FindControl("Image2") as Image);
|
||||
if (image2 != null)
|
||||
{
|
||||
string[] tmp = image2.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image2.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image2.Attributes.Remove("onclick");
|
||||
image2.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image2.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.場地照片路徑 + "{0:000000}_2.jpg", 編號)));
|
||||
image2.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//protected void 送簽1_DataBinding(object sender, EventArgs e)
|
||||
//{
|
||||
// 訓練課程企劃List d = Dao訓練課程企劃.SelectOne(課程ID);
|
||||
// if (d.Count == 0)
|
||||
// 送簽1.可送簽 = false;
|
||||
// else
|
||||
// 送簽1.可送簽 = d[0].承辦.CompareTo(UserId) == 0;
|
||||
//}
|
||||
|
||||
protected string GetFormControlId(string id)
|
||||
{
|
||||
if (可異動 && fv場地.PageIndex >= 0)
|
||||
{
|
||||
Control ctrl = fv場地.FindControl(id);
|
||||
if (ctrl != null)
|
||||
return fv場地.FindControl(id).ClientID;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,818 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupPlace
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// hf課程ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程ID;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm場地;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid場地;
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// Label11 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label11;
|
||||
|
||||
/// <summary>
|
||||
/// btnPlaceA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPlaceA;
|
||||
|
||||
/// <summary>
|
||||
/// Label12 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label12;
|
||||
|
||||
/// <summary>
|
||||
/// btnPlaceB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPlaceB;
|
||||
|
||||
/// <summary>
|
||||
/// Label13 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label13;
|
||||
|
||||
/// <summary>
|
||||
/// btnPlaceC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPlaceC;
|
||||
|
||||
/// <summary>
|
||||
/// Label16 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label16;
|
||||
|
||||
/// <summary>
|
||||
/// lbPlaceA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbPlaceA;
|
||||
|
||||
/// <summary>
|
||||
/// hf場地A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf場地A;
|
||||
|
||||
/// <summary>
|
||||
/// lbPlaceB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbPlaceB;
|
||||
|
||||
/// <summary>
|
||||
/// hf場地B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf場地B;
|
||||
|
||||
/// <summary>
|
||||
/// lbPlaceC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbPlaceC;
|
||||
|
||||
/// <summary>
|
||||
/// hf場地C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf場地C;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱A;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱B;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱C;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// txt安全舒適A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt安全舒適A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator1;
|
||||
|
||||
/// <summary>
|
||||
/// rfv安全舒適A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv安全舒適A;
|
||||
|
||||
/// <summary>
|
||||
/// txt安全舒適B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt安全舒適B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator2;
|
||||
|
||||
/// <summary>
|
||||
/// txt安全舒適C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt安全舒適C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator3;
|
||||
|
||||
/// <summary>
|
||||
/// Label18 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label18;
|
||||
|
||||
/// <summary>
|
||||
/// txt空間大小A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt空間大小A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator4 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator4;
|
||||
|
||||
/// <summary>
|
||||
/// rfv空間大小A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv空間大小A;
|
||||
|
||||
/// <summary>
|
||||
/// txt空間大小B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt空間大小B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator5 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator5;
|
||||
|
||||
/// <summary>
|
||||
/// txt空間大小C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt空間大小C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator6 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator6;
|
||||
|
||||
/// <summary>
|
||||
/// Label19 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label19;
|
||||
|
||||
/// <summary>
|
||||
/// txt價格合理A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt價格合理A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator7 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator7;
|
||||
|
||||
/// <summary>
|
||||
/// rfv價格合理A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv價格合理A;
|
||||
|
||||
/// <summary>
|
||||
/// txt價格合理B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt價格合理B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator8 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator8;
|
||||
|
||||
/// <summary>
|
||||
/// txt價格合理C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt價格合理C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator9;
|
||||
|
||||
/// <summary>
|
||||
/// Label20 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label20;
|
||||
|
||||
/// <summary>
|
||||
/// txt交通便利A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt交通便利A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator10;
|
||||
|
||||
/// <summary>
|
||||
/// RequiredFieldValidator4 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator4;
|
||||
|
||||
/// <summary>
|
||||
/// txt交通便利B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt交通便利B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator11 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator11;
|
||||
|
||||
/// <summary>
|
||||
/// txt交通便利C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt交通便利C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator12 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator12;
|
||||
|
||||
/// <summary>
|
||||
/// Label21 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label21;
|
||||
|
||||
/// <summary>
|
||||
/// txt設備完善A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt設備完善A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator13 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator13;
|
||||
|
||||
/// <summary>
|
||||
/// rfv設備完善A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv設備完善A;
|
||||
|
||||
/// <summary>
|
||||
/// txt設備完善B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt設備完善B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator14 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator14;
|
||||
|
||||
/// <summary>
|
||||
/// txt設備完善C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt設備完善C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator15 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator15;
|
||||
|
||||
/// <summary>
|
||||
/// Label22 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label22;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計A;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計B;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計C;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearA;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearB;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearC;
|
||||
|
||||
/// <summary>
|
||||
/// Label23 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label23;
|
||||
|
||||
/// <summary>
|
||||
/// txt總評 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt總評;
|
||||
|
||||
/// <summary>
|
||||
/// Label24 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label24;
|
||||
|
||||
/// <summary>
|
||||
/// txt備註 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt備註;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// pnlPlace 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnlPlace;
|
||||
|
||||
/// <summary>
|
||||
/// lb單位名稱Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb單位名稱Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt單位名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt單位名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb場地名稱Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb場地名稱Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb場地類型Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb場地類型Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt場地類型Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt場地類型Search;
|
||||
|
||||
/// <summary>
|
||||
/// btnPlaceSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPlaceSearch;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage場地;
|
||||
|
||||
/// <summary>
|
||||
/// lb聯絡人Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb聯絡人Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt聯絡人Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt聯絡人Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb聯絡人電話Label0 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb聯絡人電話Label0;
|
||||
|
||||
/// <summary>
|
||||
/// txt聯絡人電話Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt聯絡人電話Search;
|
||||
|
||||
/// <summary>
|
||||
/// fv場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView fv場地;
|
||||
|
||||
/// <summary>
|
||||
/// gv場地 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv場地;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master" AutoEventWireup="true" CodeBehind="PickupProject.aspx.cs" Inherits="Education.Forms.課程企劃.PickupProject" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 100px">
|
||||
<asp:Label ID="lbTypeLabel" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf編號" runat="server" />
|
||||
<asp:HiddenField ID="hf課程別" runat="server" />
|
||||
</td>
|
||||
<td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption" style="vertical-align: top">
|
||||
<asp:Label ID="Label3" runat="server" Text="已加入計畫"></asp:Label></td>
|
||||
<td class="datadisplay">
|
||||
<asp:CheckBoxList ID="cbl已加入計畫" runat="server">
|
||||
</asp:CheckBoxList>
|
||||
</td>
|
||||
<td style="vertical-align: top">
|
||||
<asp:LinkButton ID="btnRemove" runat="server" CssClass="button red80" OnClick="btnRemove_Click">移除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
</td>
|
||||
<td>
|
||||
</td>
|
||||
<td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label1" runat="server" Text="計畫年度"></asp:Label></td>
|
||||
<td>
|
||||
<asp:TextBox ID="txtYear" runat="server" Columns="6" MaxLength="4"></asp:TextBox>
|
||||
<asp:LinkButton ID="btnSetYear" runat="server" CssClass="button blue80" OnClick="btnSetYear_Click">確定</asp:LinkButton>
|
||||
</td>
|
||||
<td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption" style="vertical-align: top">
|
||||
<asp:Label ID="Label2" runat="server" Text="可加入計畫"></asp:Label></td>
|
||||
<td class="datadisplay">
|
||||
<asp:CheckBoxList ID="cbl可加入計畫" runat="server">
|
||||
</asp:CheckBoxList>
|
||||
</td>
|
||||
<td style="vertical-align:top;">
|
||||
<asp:LinkButton ID="btnAdd" runat="server" CssClass="button blue80" OnClick="btnAdd_Click">加入</asp:LinkButton></td>
|
||||
</tr>
|
||||
</table>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,151 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class PickupProject : FormBase
|
||||
{
|
||||
private int 課程ID;
|
||||
private string 課程別;
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程計畫別 Dao訓練課程計畫別;
|
||||
private DAC_數位課程 Dao數位課程;
|
||||
private DAC_數位課程計畫別 Dao數位課程計畫別;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 計畫別挑選";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf編號.Value = Request["id"];
|
||||
hf課程別.Value = Request["type"];
|
||||
}
|
||||
|
||||
課程ID = DAC.GetInt32(hf編號.Value);
|
||||
課程別 = DAC.GetString(hf課程別.Value);
|
||||
|
||||
Dao訓練課程計畫別 = new DAC_訓練課程計畫別(conn);
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao數位課程 = new DAC_數位課程(conn);
|
||||
Dao數位課程計畫別 = new DAC_數位課程計畫別(conn);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
lbTypeLabel.Text = "訓練課程企劃";
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程ID);
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
lbTypeLabel.Text = "數位課程";
|
||||
數位課程List v2 = Dao數位課程.SelectOne(課程ID);
|
||||
if (v2.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0:000000}] {1}", 課程ID, v2[0].課程名稱);
|
||||
}
|
||||
}
|
||||
|
||||
RefreshUI();
|
||||
}
|
||||
}
|
||||
|
||||
private void RefreshUI()
|
||||
{
|
||||
if (課程別 == "course")
|
||||
cbl已加入計畫.DataSource = Dao訓練課程計畫別.Select(課程ID);
|
||||
else if (課程別 == "digital")
|
||||
cbl已加入計畫.DataSource = Dao數位課程計畫別.Select(課程ID);
|
||||
else
|
||||
return;
|
||||
|
||||
cbl已加入計畫.DataTextField = "BPPYM";
|
||||
cbl已加入計畫.DataValueField = "BPPYN";
|
||||
cbl已加入計畫.DataBind();
|
||||
}
|
||||
|
||||
protected void btnSetYear_Click(object sender, EventArgs e)
|
||||
{
|
||||
cbl可加入計畫.DataSource = new DAC_BPAA().GetBpaaWithTY(DAC_BCLS.GetInt32(txtYear.Text), CompanyId);
|
||||
cbl可加入計畫.DataTextField = "BPPYM";
|
||||
cbl可加入計畫.DataValueField = "BPPYN";
|
||||
cbl可加入計畫.DataBind();
|
||||
}
|
||||
|
||||
protected void btnAdd_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl可加入計畫.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
if (Dao訓練課程計畫別.SelectOne(課程ID, item.Value).Count == 0)
|
||||
{
|
||||
訓練課程計畫別 newValue = new 訓練課程計畫別();
|
||||
newValue.編號 = 課程ID;
|
||||
newValue.計畫編號 = item.Value;
|
||||
newValue.DB_CRDAT = DateTime.UtcNow.AddHours(8);
|
||||
newValue.DB_CRUSR = UserId;
|
||||
newValue.DB_APPNO = 1;
|
||||
|
||||
Dao訓練課程計畫別.InsertOne(newValue);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
if (Dao數位課程計畫別.SelectOne(課程ID, item.Value).Count == 0)
|
||||
{
|
||||
數位課程計畫別 newValue = new 數位課程計畫別();
|
||||
newValue.編號 = 課程ID;
|
||||
newValue.計畫編號 = item.Value;
|
||||
newValue.DB_CRDAT = DateTime.UtcNow.AddHours(8);
|
||||
newValue.DB_CRUSR = UserId;
|
||||
newValue.DB_APPNO = 1;
|
||||
|
||||
Dao數位課程計畫別.InsertOne(newValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
|
||||
protected void btnRemove_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (ListItem item in cbl已加入計畫.Items)
|
||||
{
|
||||
if (item.Selected)
|
||||
{
|
||||
if (課程別 == "course")
|
||||
{
|
||||
訓練課程計畫別List oldValues = Dao訓練課程計畫別.SelectOne(課程ID, item.Value);
|
||||
if (oldValues.Count > 0)
|
||||
{
|
||||
Dao訓練課程計畫別.DeleteOne(oldValues[0]);
|
||||
}
|
||||
}
|
||||
else if (課程別 == "digital")
|
||||
{
|
||||
數位課程計畫別List oldValues = Dao數位課程計畫別.SelectOne(課程ID, item.Value);
|
||||
if (oldValues.Count > 0)
|
||||
{
|
||||
Dao數位課程計畫別.DeleteOne(oldValues[0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
RefreshUI();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupProject
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// lbTypeLabel 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbTypeLabel;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf編號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf編號;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程別;
|
||||
|
||||
/// <summary>
|
||||
/// Label3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label3;
|
||||
|
||||
/// <summary>
|
||||
/// cbl已加入計畫 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.CheckBoxList cbl已加入計畫;
|
||||
|
||||
/// <summary>
|
||||
/// btnRemove 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnRemove;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txtYear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txtYear;
|
||||
|
||||
/// <summary>
|
||||
/// btnSetYear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSetYear;
|
||||
|
||||
/// <summary>
|
||||
/// Label2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label2;
|
||||
|
||||
/// <summary>
|
||||
/// cbl可加入計畫 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.CheckBoxList cbl可加入計畫;
|
||||
|
||||
/// <summary>
|
||||
/// btnAdd 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnAdd;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,669 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/PopupForm.Master"
|
||||
AutoEventWireup="true" CodeBehind="PickupTeacher.aspx.cs"
|
||||
Inherits="Education.Forms.課程企劃.PickupTeacher" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<%@ Register Src="~/Forms/簽核/送簽.ascx" TagPrefix="uc1" TagName="送簽" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
<script type="text/javascript">
|
||||
function checkInput() {
|
||||
return true;
|
||||
}
|
||||
|
||||
function selectTeacher(id1, id2, id3, id4, id5) {
|
||||
var no1 = $("#<%= GetFormControlId("hf編號") %>").val();
|
||||
var no2 = $("#<%= GetFormControlId("lb編號") %>").text();
|
||||
var name = $("#<%= GetFormControlId("lb姓名") %>").text();
|
||||
var job = $("#<%= GetFormControlId("lb現職") %>").text();
|
||||
var school = $("#<%= GetFormControlId("hf學歷") %>").val();
|
||||
|
||||
$("#" + id1).val(no1);
|
||||
$("#" + id2).text("[" + no2 + "] " + name);
|
||||
$("#" + id3).val(name).prop("readonly", true);
|
||||
$("#" + id4).val(school).prop("readonly", true);
|
||||
$("#" + id5).val(job).prop("readonly", true);
|
||||
}
|
||||
|
||||
function clearTeacher(id1, id2, id3, id4, id5, id6, id7, id8, id9, id10, id11, id12) {
|
||||
$("#" + id1).val("");
|
||||
$("#" + id2).text("(尚未選擇)");
|
||||
$("#" + id3).val("").prop("readonly", false);
|
||||
$("#" + id4).val("").prop("readonly", false);
|
||||
$("#" + id5).val("").prop("readonly", false);
|
||||
$("#" + id6).val("");
|
||||
$("#" + id7).val("");
|
||||
$("#" + id8).val("");
|
||||
$("#" + id9).val("");
|
||||
$("#" + id10).val("");
|
||||
$("#" + id11).val("");
|
||||
$("#" + id12).text("");
|
||||
}
|
||||
|
||||
</script>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1"
|
||||
runat="server">
|
||||
<%-- <uc1:送簽 runat="server" ID="送簽1" 表單類別="講師遴選" OnDataBinding="送簽1_DataBinding" />--%>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption" style="width: 70px">
|
||||
<asp:Label ID="Label9" runat="server" Text="課程企劃"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" style="width: 800px">
|
||||
<asp:Label ID="lb課程企劃" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程企劃ID" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label10" runat="server" Text="課程內容"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb課程內容" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf課程序號" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table style="width: 100%; table-layout: fixed">
|
||||
<tr>
|
||||
<td style="width: 145px"> </td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="Label11" runat="server" Text="講師一"></asp:Label>
|
||||
<asp:LinkButton ID="btnPickupA" runat="server"
|
||||
CssClass="button blue60" CausesValidation="False">挑選</asp:LinkButton>
|
||||
</td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="Label12" runat="server" Text="講師二"></asp:Label>
|
||||
<asp:LinkButton ID="btnPickupB" runat="server"
|
||||
CssClass="button blue60" CausesValidation="False">挑選</asp:LinkButton>
|
||||
</td>
|
||||
<td class="captionCenter" colspan="1" style="width: 33%">
|
||||
<asp:Label ID="Label13" runat="server" Text="講師三"></asp:Label>
|
||||
<asp:LinkButton ID="btnPickupC" runat="server"
|
||||
CssClass="button blue60" CausesValidation="False">挑選</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label15" runat="server" Text="姓名"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb講師一" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf講師編號A" runat="server" />
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb講師二" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf講師編號B" runat="server" />
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb講師三" runat="server"></asp:Label>
|
||||
<asp:HiddenField ID="hf講師編號C" runat="server" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label1" runat="server" Text="講師姓名"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講師姓名A" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講師姓名B" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講師姓名C" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label23" runat="server" Text="學歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt學歷A" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt學歷B" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt學歷C" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label24" runat="server" Text="現職"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt現職A" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt現職B" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt現職C" runat="server" CssClass="inputFull" MaxLength="50"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label16" runat="server" Text="師資來源"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<weblib:WDropDownList ID="ddl師資來源A" runat="server" ValidationGroup="save">
|
||||
<asp:ListItem Value="">(請選擇)</asp:ListItem>
|
||||
<asp:ListItem Value="O">原合作</asp:ListItem>
|
||||
<asp:ListItem Value="N">新開發</asp:ListItem>
|
||||
</weblib:WDropDownList>
|
||||
<asp:RequiredFieldValidator ID="rfv師資來源A" runat="server" ControlToValidate="ddl師資來源A"
|
||||
Display="Dynamic" ErrorMessage="請選擇" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<weblib:WDropDownList ID="ddl師資來源B" runat="server" ValidationGroup="save">
|
||||
<asp:ListItem Value="">(請選擇)</asp:ListItem>
|
||||
<asp:ListItem Value="O">原合作</asp:ListItem>
|
||||
<asp:ListItem Value="N">新開發</asp:ListItem>
|
||||
</weblib:WDropDownList>
|
||||
<asp:RequiredFieldValidator ID="rfv師資來源B" runat="server" ControlToValidate="ddl師資來源B"
|
||||
Display="Dynamic" ErrorMessage="請選擇" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<weblib:WDropDownList ID="ddl師資來源C" runat="server" ValidationGroup="save">
|
||||
<asp:ListItem Value="">(請選擇)</asp:ListItem>
|
||||
<asp:ListItem Value="O">原合作</asp:ListItem>
|
||||
<asp:ListItem Value="N">新開發</asp:ListItem>
|
||||
</weblib:WDropDownList>
|
||||
<span id="msg師資來源C" class="ErrorMessage" style="display: none">請選擇</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label17" runat="server" Text="專業背景 25%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt專業背景A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txt專業背景A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv專業背景A" runat="server" ControlToValidate="txt專業背景A"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt專業背景B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="txt專業背景B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv專業背景B" runat="server" ControlToValidate="txt專業背景B"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt專業背景C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator3" runat="server" ControlToValidate="txt專業背景C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label18" runat="server" Text="講授經驗 25%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講授經驗A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator4" runat="server" ControlToValidate="txt講授經驗A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv講授經驗A" runat="server" ControlToValidate="txt講授經驗A"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講授經驗B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator5" runat="server" ControlToValidate="txt講授經驗B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv講授經驗B" runat="server" ControlToValidate="txt講授經驗B"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt講授經驗C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator6" runat="server" ControlToValidate="txt講授經驗C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-25" MaximumValue="25" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label19" runat="server" Text="口碑與評價 20%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt口碑評價A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator7" runat="server" ControlToValidate="txt口碑評價A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv口碑評價A" runat="server" ControlToValidate="txt口碑評價A"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt口碑評價B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator8" runat="server" ControlToValidate="txt口碑評價B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv口碑評價B" runat="server" ControlToValidate="txt口碑評價B"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt口碑評價C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator9" runat="server" ControlToValidate="txt口碑評價C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label20" runat="server" Text="費用 20%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt費用A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator10" runat="server" ControlToValidate="txt費用A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv費用A" runat="server" ControlToValidate="txt費用A"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt費用B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator11" runat="server" ControlToValidate="txt費用B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv費用B" runat="server" ControlToValidate="txt費用B"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt費用C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator12" runat="server" ControlToValidate="txt費用C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-20" MaximumValue="20" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label21" runat="server" Text="配合度 10%"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt配合度A" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator13" runat="server" ControlToValidate="txt配合度A"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv配合度A" runat="server" ControlToValidate="txt配合度A"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt配合度B" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator14" runat="server" ControlToValidate="txt配合度B"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
<asp:RequiredFieldValidator ID="rfv配合度B" runat="server" ControlToValidate="txt配合度B"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt配合度C" runat="server" Columns="6" MaxLength="2" ValidationGroup="save"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RangeValidator15" runat="server" ControlToValidate="txt配合度C"
|
||||
Display="Dynamic" ErrorMessage="輸入範圍 0-10" MaximumValue="10" MinimumValue="0" Type="Integer"
|
||||
ValidationGroup="save"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label22" runat="server" Text="合計 100%"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計A" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計B" runat="server"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay">
|
||||
<asp:Label ID="lb合計C" runat="server"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"> </td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearA" runat="server"
|
||||
CssClass="button red80" CausesValidation="False">清除</asp:LinkButton>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearB" runat="server"
|
||||
CssClass="button red80" CausesValidation="False">清除</asp:LinkButton>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:LinkButton ID="btnClearC" runat="server"
|
||||
CssClass="button red80" CausesValidation="False">清除</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label25" runat="server" Text="總評"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt總評" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="rfv總評" runat="server" ControlToValidate="txt總評"
|
||||
Display="Dynamic" ErrorMessage="請輸入" ValidationGroup="save"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label26" runat="server" Text="備註"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:TextBox ID="txt備註" runat="server" CssClass="inputFull" Rows="5" TextMode="MultiLine"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption"> </td>
|
||||
<td class="datainput" colspan="3">
|
||||
<asp:LinkButton ID="btnSave" runat="server" CssClass="button blue80" OnClick="btnSave_Click"
|
||||
OnClientClick="return checkInput();"
|
||||
ValidationGroup="save">儲存</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:ObjectDataSource ID="dsForm" runat="server"
|
||||
DataObjectTypeName="Education.講師" DeleteMethod="DeleteOne"
|
||||
InsertMethod="InsertOne"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectOne" TypeName="Education.DAC_講師"
|
||||
UpdateMethod="UpdateOne"
|
||||
OnObjectCreating="dsForm_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="GridView1" Name="編號"
|
||||
PropertyName="SelectedValue" Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsGrid" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select講師遴選" TypeName="Education.DAC_講師"
|
||||
OnObjectCreating="dsGrid_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="txt姓名" Name="姓名"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt電話" Name="電話"
|
||||
PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt手機" Name="手機"
|
||||
PropertyName="Text" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:Panel ID="pnlTeacher" runat="server">
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption"
|
||||
style="width: 70px">
|
||||
<asp:Label ID="lb姓名Label1" runat="server" Text="姓名"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt姓名" runat="server"
|
||||
CssClass="inputFull" MaxLength="30"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td style="width: 70px"
|
||||
class="caption">
|
||||
<asp:Label ID="lb電話Label1" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt電話" runat="server"
|
||||
CssClass="inputFull" MaxLength="20"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td style="width: 70px"
|
||||
class="caption">
|
||||
<asp:Label ID="lb手機Label1" runat="server" Text="手機"></asp:Label>
|
||||
</td>
|
||||
<td style="width: 120px"
|
||||
class="datainput">
|
||||
<asp:TextBox ID="txt手機" runat="server"
|
||||
CssClass="inputFull" MaxLength="20"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
<td>
|
||||
<asp:LinkButton ID="btnSearch" runat="server"
|
||||
CssClass="button blue80" Text="查詢"
|
||||
OnClick="btnSearch_Click" />
|
||||
<asp:Label ID="lbMessage" runat="server"
|
||||
CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:FormView ID="FormView1" runat="server"
|
||||
DataKeyNames="編號,DB_APPNO" DataSourceID="dsForm"
|
||||
EnableModelValidation="True"
|
||||
EnableViewState="False">
|
||||
<ItemTemplate>
|
||||
<div>
|
||||
<div style="float: left">
|
||||
<table border="0"
|
||||
style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 140px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 110px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 120px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb編號Label" runat="server" Text="編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb編號" runat="server" Text='<%# Bind("編號", "{0:0000}") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
<asp:HiddenField ID="hf編號" runat="server" Value='<%# Bind("編號") %>'></asp:HiddenField>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb姓名Label" runat="server" Text="姓名"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb姓名" runat="server" Text='<%# Bind("姓名") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb出生日期Label" runat="server" Text="出生日期"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb出生日期" runat="server" Text='<%# Eval("出生日期", "{0:yyyyMMdd}") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb性別Label" runat="server" Text="性別"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb性別" runat="server" Text='<%# Bind("性別") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb身份證字號Label" runat="server" Text="身份證字號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb身份證字號" runat="server" Text='<%# Bind("身份證字號") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電話Label" runat="server" Text="電話"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb電話" runat="server" Text='<%# Bind("電話") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb手機Label" runat="server" Text="手機"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb手機" runat="server" Text='<%# Bind("手機") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb電子郵件Label" runat="server" Text="電子郵件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="3">
|
||||
<asp:Label ID="lb電子郵件" runat="server" Text='<%# Bind("電子郵件") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb戶籍地址Label" runat="server" Text="戶籍地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb戶籍地址_郵編" runat="server" Text='<%# Bind("戶籍地址_郵編") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_縣市" runat="server" Text='<%# Bind("戶籍地址_縣市") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_鄉鎮市區" runat="server" Text='<%# Bind("戶籍地址_鄉鎮市區") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb戶籍地址_街道地址" runat="server" Text='<%# Bind("戶籍地址_街道地址") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb居住地址Label" runat="server" Text="居住地址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb居住地址_郵編" runat="server" Text='<%# Bind("居住地址_郵編") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_縣市" runat="server" Text='<%# Bind("居住地址_縣市") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_鄉鎮市區" runat="server" Text='<%# Bind("居住地址_鄉鎮市區") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
<asp:Label ID="lb居住地址_街道地址" runat="server" Text='<%# Bind("居住地址_街道地址") %>'
|
||||
CssClass="input"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb現職Label" runat="server" Text="現職"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb現職" runat="server" Text='<%# Bind("現職") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb學歷Label" runat="server" Text="學歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb學歷" runat="server" Text='<%# String.Format("[{0}] {1}{2}", Get類別名稱("BPSNSTP", Eval("最高學歷")), Eval("最高學歷學校"), Eval("最高學歷科系")) %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
<asp:HiddenField ID="hf學歷" runat="server" Value='<%# String.Format("{0}{1}", Eval("最高學歷學校"), Eval("最高學歷科系")) %>'>
|
||||
</asp:HiddenField>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課區域Label" runat="server" Text="授課區域"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb授課區域" runat="server" Text='<%# Bind("授課區域TXT") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課專長領域Label" runat="server" Text="授課專長領域"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb授課專長領域" runat="server" Text='<%# Bind("授課專長領域") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb授課經歷概述Label" runat="server" Text="授課經歷概述"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb授課經歷概述" runat="server" Text='<%# Bind("授課經歷概述") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb重要經歷Label" runat="server" Text="重要經歷"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb重要經歷" runat="server" Text='<%# Bind("重要經歷") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb重要研究與著作Label" runat="server"
|
||||
Text="重要研究與著作"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb重要研究與著作" runat="server" Text='<%# Bind("重要研究與著作") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div style="float: left; width: 400px; height: 280px; margin-left: 5px; text-align: center;
|
||||
vertical-align: middle;">
|
||||
<asp:Image ID="Image1" runat="server"
|
||||
ImageUrl='<%# Education.PublicVariable.講師照片路徑 + "T_" + Eval("編號", "{0:000000}") + ".jpg?now=" + DateTime.UtcNow.AddHours(8).Ticks.ToString() %>'
|
||||
EnableViewState="False" />
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
</asp:FormView>
|
||||
<asp:GridView ID="GridView1" runat="server"
|
||||
AutoGenerateColumns="False" DataKeyNames="編號"
|
||||
DataSourceID="dsGrid" EnableModelValidation="True"
|
||||
AllowPaging="True" EnableViewState="False">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="編號" SortExpression="編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label14" runat="server"
|
||||
Text='<%# Bind("編號") %>'></asp:Label>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server"
|
||||
CausesValidation="False" CommandName="Select" Text=""></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="姓名" HeaderText="姓名"
|
||||
SortExpression="姓名" />
|
||||
<asp:BoundField DataField="出生日期"
|
||||
DataFormatString="{0:yyyyMMdd}" HeaderText="出生日期"
|
||||
SortExpression="出生日期">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="性別" HeaderText="性別"
|
||||
SortExpression="性別" />
|
||||
<asp:BoundField DataField="身份證字號" HeaderText="身份證字號"
|
||||
SortExpression="身份證字號" />
|
||||
<asp:BoundField DataField="電話" HeaderText="電話"
|
||||
SortExpression="電話" />
|
||||
<asp:BoundField DataField="手機" HeaderText="手機"
|
||||
SortExpression="手機" />
|
||||
<asp:BoundField DataField="電子郵件" HeaderText="電子郵件"
|
||||
SortExpression="電子郵件" />
|
||||
<asp:BoundField DataField="現職" HeaderText="現職"
|
||||
SortExpression="現職" />
|
||||
<asp:TemplateField HeaderText="學歷" SortExpression="學歷">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label2" runat="server"
|
||||
Text='<%# String.Format("[{0}] {1}{2}", Get類別名稱("BPSNSTP", Eval("最高學歷")), Eval("最高學歷學校"), Eval("最高學歷科系")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="授課區域TXT" HeaderText="授課區域"
|
||||
SortExpression="授課區域" />
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager1" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Panel>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,569 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class PickupTeacher : FormBase
|
||||
{
|
||||
private DAC_訓練課程企劃 Dao課程企劃;
|
||||
private DAC_訓練課程內容 Dao課程內容;
|
||||
private DAC_講師遴選 Dao講師遴選;
|
||||
private int 課程企劃ID;
|
||||
private int 課程序號;
|
||||
|
||||
protected bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書 >> 訓練課程內容 >> 講師遴選";
|
||||
Title = FunctionName;
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
hf課程企劃ID.Value = Request["id"];
|
||||
hf課程序號.Value = Request["class"];
|
||||
}
|
||||
課程企劃ID = DAC.GetInt32(hf課程企劃ID.Value);
|
||||
課程序號 = DAC.GetInt32(hf課程序號.Value);
|
||||
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", String.Format("{0}", 課程企劃ID));
|
||||
|
||||
Dao課程企劃 = new DAC_訓練課程企劃(conn);
|
||||
Dao課程內容 = new DAC_訓練課程內容(conn);
|
||||
Dao講師遴選 = new DAC_講師遴選(conn);
|
||||
//Dao講師遴選.CurrentUserId = UserId;
|
||||
|
||||
Form_View = FormView1;
|
||||
Grid_View = GridView1;
|
||||
|
||||
if (IsPostBack)
|
||||
{
|
||||
Grid_View.DataBind();
|
||||
|
||||
lb講師一.Text = "(尚未選擇)";
|
||||
lb講師二.Text = "(尚未選擇)";
|
||||
lb講師三.Text = "(尚未選擇)";
|
||||
|
||||
if (hf講師編號A.Value != null && hf講師編號A.Value.Length > 0)
|
||||
{
|
||||
lb講師一.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf講師編號A.Value), Dao講師.Get姓名(hf講師編號A.Value));
|
||||
txt講師姓名A.Text = Dao講師.Get姓名(hf講師編號A.Value);
|
||||
txt講師姓名A.Enabled = false;
|
||||
txt學歷A.Enabled = false;
|
||||
txt現職A.Enabled = false;
|
||||
}
|
||||
if (hf講師編號B.Value != null && hf講師編號B.Value.Length > 0)
|
||||
{
|
||||
lb講師二.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf講師編號B.Value), Dao講師.Get姓名(hf講師編號B.Value));
|
||||
txt講師姓名B.Text = Dao講師.Get姓名(hf講師編號B.Value);
|
||||
txt講師姓名B.Enabled = false;
|
||||
txt學歷B.Enabled = false;
|
||||
txt現職B.Enabled = false;
|
||||
}
|
||||
if (hf講師編號C.Value != null && hf講師編號C.Value.Length > 0)
|
||||
{
|
||||
lb講師三.Text = String.Format("[{0:0000}] {1}", DAC.GetInt32(hf講師編號C.Value), Dao講師.Get姓名(hf講師編號C.Value));
|
||||
txt講師姓名C.Text = Dao講師.Get姓名(hf講師編號C.Value);
|
||||
txt講師姓名C.Enabled = false;
|
||||
txt學歷C.Enabled = false;
|
||||
txt現職C.Enabled = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
UpdateUI();
|
||||
}
|
||||
|
||||
btnPickupA.OnClientClick = String.Format("selectTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\"); return false;",
|
||||
hf講師編號A.ClientID, lb講師一.ClientID, txt講師姓名A.ClientID, txt學歷A.ClientID, txt現職A.ClientID);
|
||||
btnPickupB.OnClientClick = String.Format("selectTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\"); return false;",
|
||||
hf講師編號B.ClientID, lb講師二.ClientID, txt講師姓名B.ClientID, txt學歷B.ClientID, txt現職B.ClientID);
|
||||
btnPickupC.OnClientClick = String.Format("selectTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\"); return false;",
|
||||
hf講師編號C.ClientID, lb講師三.ClientID, txt講師姓名C.ClientID, txt學歷C.ClientID, txt現職C.ClientID);
|
||||
|
||||
btnClearA.OnClientClick = String.Format("clearTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\", \"{9}\", \"{10}\", \"{11}\"); return false;",
|
||||
hf講師編號A.ClientID, lb講師一.ClientID, txt講師姓名A.ClientID, txt學歷A.ClientID, txt現職A.ClientID, ddl師資來源A.ClientID, txt專業背景A.ClientID, txt講授經驗A.ClientID, txt口碑評價A.ClientID, txt費用A.ClientID, txt配合度A.ClientID, lb合計A.ClientID);
|
||||
btnClearB.OnClientClick = String.Format("clearTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\", \"{9}\", \"{10}\", \"{11}\"); return false;",
|
||||
hf講師編號B.ClientID, lb講師二.ClientID, txt講師姓名B.ClientID, txt學歷B.ClientID, txt現職B.ClientID, ddl師資來源B.ClientID, txt專業背景B.ClientID, txt講授經驗B.ClientID, txt口碑評價B.ClientID, txt費用B.ClientID, txt配合度B.ClientID, lb合計B.ClientID);
|
||||
btnClearC.OnClientClick = String.Format("clearTeacher(\"{0}\", \"{1}\", \"{2}\", \"{3}\", \"{4}\", \"{5}\", \"{6}\", \"{7}\", \"{8}\", \"{9}\", \"{10}\", \"{11}\"); return false;",
|
||||
hf講師編號C.ClientID, lb講師三.ClientID, txt講師姓名C.ClientID, txt學歷C.ClientID, txt現職C.ClientID, ddl師資來源C.ClientID, txt專業背景C.ClientID, txt講授經驗C.ClientID, txt口碑評價C.ClientID, txt費用C.ClientID, txt配合度C.ClientID, lb合計C.ClientID);
|
||||
|
||||
UIControl();
|
||||
}
|
||||
|
||||
private void UIControl()
|
||||
{
|
||||
btnPickupA.Visible = 可異動;
|
||||
btnPickupB.Visible = 可異動;
|
||||
btnPickupC.Visible = 可異動;
|
||||
btnSave.Visible = 可異動;
|
||||
//btnSaveB.Visible = 可異動;
|
||||
//btnSaveC.Visible = 可異動;
|
||||
btnClearA.Visible = 可異動;
|
||||
btnClearB.Visible = 可異動;
|
||||
btnClearC.Visible = 可異動;
|
||||
|
||||
txt講師姓名A.Enabled = 可異動;
|
||||
txt講師姓名B.Enabled = 可異動;
|
||||
txt講師姓名C.Enabled = 可異動;
|
||||
txt學歷A.Enabled = 可異動;
|
||||
txt學歷B.Enabled = 可異動;
|
||||
txt學歷C.Enabled = 可異動;
|
||||
txt現職A.Enabled = 可異動;
|
||||
txt現職B.Enabled = 可異動;
|
||||
txt現職C.Enabled = 可異動;
|
||||
//btnSaveComment.Visible = 可異動;
|
||||
pnlTeacher.Visible = 可異動;
|
||||
}
|
||||
|
||||
private void UpdateUI()
|
||||
{
|
||||
訓練課程企劃List v1 = Dao課程企劃.SelectOne(課程企劃ID);
|
||||
訓練課程內容List v2 = Dao課程內容.SelectOne(課程企劃ID, 課程序號);
|
||||
講師遴選List v3 = Dao講師遴選.SelectOne(課程企劃ID, 課程序號);
|
||||
|
||||
if (v1.Count > 0)
|
||||
{
|
||||
lb課程企劃.Text = String.Format("[{0}] {1}", v1[0].顯示編號, v1[0].訓練名稱);
|
||||
}
|
||||
|
||||
if (v2.Count > 0)
|
||||
{
|
||||
lb課程內容.Text = String.Format("[{0}] {1}", v2[0].節次, v2[0].課程名稱);
|
||||
}
|
||||
|
||||
//送簽1.表單ID = String.Format("{0}|{1}", 課程企劃ID, 課程序號);
|
||||
//送簽1.表單ID格式 = String.Format("[{0}] {1}<br>[{2}] {3} ", v1[0].顯示編號, v1[0].訓練名稱, 課程序號, v2[0].課程名稱);
|
||||
//送簽1.訓練課程企劃編號 = 課程企劃ID;
|
||||
//送簽1.編號2 = 課程序號;
|
||||
//送簽1.DataBind();
|
||||
|
||||
lb講師一.Text = "(尚未選擇)";
|
||||
lb講師二.Text = "(尚未選擇)";
|
||||
lb講師三.Text = "(尚未選擇)";
|
||||
|
||||
txt講師姓名A.Text = "";
|
||||
txt講師姓名A.Enabled = true;
|
||||
txt學歷A.Text = "";
|
||||
txt學歷A.Enabled = true;
|
||||
txt現職A.Text = "";
|
||||
txt現職A.Enabled = true;
|
||||
hf講師編號A.Value = "";
|
||||
ddl師資來源A.SelectedValue = "";
|
||||
txt專業背景A.Text = "";
|
||||
txt講授經驗A.Text = "";
|
||||
txt口碑評價A.Text = "";
|
||||
txt費用A.Text = "";
|
||||
txt配合度A.Text = "";
|
||||
lb合計A.Text = "";
|
||||
|
||||
txt講師姓名B.Text = "";
|
||||
txt講師姓名B.Enabled = true;
|
||||
txt學歷B.Text = "";
|
||||
txt學歷B.Enabled = true;
|
||||
txt現職B.Text = "";
|
||||
txt現職B.Enabled = true;
|
||||
hf講師編號B.Value = "";
|
||||
ddl師資來源B.SelectedValue = "";
|
||||
txt專業背景B.Text = "";
|
||||
txt講授經驗B.Text = "";
|
||||
txt口碑評價B.Text = "";
|
||||
txt費用B.Text = "";
|
||||
txt配合度B.Text = "";
|
||||
lb合計B.Text = "";
|
||||
|
||||
txt講師姓名C.Text = "";
|
||||
txt講師姓名C.Enabled = true;
|
||||
txt學歷C.Text = "";
|
||||
txt學歷C.Enabled = true;
|
||||
txt現職C.Text = "";
|
||||
txt現職C.Enabled = true;
|
||||
hf講師編號C.Value = "";
|
||||
ddl師資來源C.SelectedValue = "";
|
||||
txt專業背景C.Text = "";
|
||||
txt講授經驗C.Text = "";
|
||||
txt口碑評價C.Text = "";
|
||||
txt費用C.Text = "";
|
||||
txt配合度C.Text = "";
|
||||
lb合計C.Text = "";
|
||||
|
||||
if (v3.Count > 0)
|
||||
{
|
||||
if (v3[0].講師編號_A > 0)
|
||||
{
|
||||
lb講師一.Text = String.Format("[{0:0000}] {1}", v3[0].講師編號_A, Dao講師.Get姓名(v3[0].講師編號_A));
|
||||
txt講師姓名A.Text = Dao講師.Get姓名(v3[0].講師編號_A);
|
||||
txt講師姓名A.Enabled = false;
|
||||
txt學歷A.Text = v3[0].學歷_A;
|
||||
txt學歷A.Enabled = false;
|
||||
txt現職A.Text = v3[0].現職_A;
|
||||
txt現職A.Enabled = false;
|
||||
hf講師編號A.Value = v3[0].講師編號_A.ToString();
|
||||
ddl師資來源A.SelectedValue = v3[0].師資來源_A;
|
||||
txt專業背景A.Text = v3[0].專業背景_A.ToString();
|
||||
txt講授經驗A.Text = v3[0].講授經驗_A.ToString();
|
||||
txt口碑評價A.Text = v3[0].口碑與評價_A.ToString();
|
||||
txt費用A.Text = v3[0].費用_A.ToString();
|
||||
txt配合度A.Text = v3[0].配合度_A.ToString();
|
||||
lb合計A.Text = v3[0].合計_A.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(v3[0].講師姓名_A))
|
||||
{
|
||||
txt講師姓名A.Text = v3[0].講師姓名_A;
|
||||
txt學歷A.Text = v3[0].學歷_A;
|
||||
txt現職A.Text = v3[0].現職_A;
|
||||
ddl師資來源A.SelectedValue = v3[0].師資來源_A;
|
||||
txt專業背景A.Text = v3[0].專業背景_A.ToString();
|
||||
txt講授經驗A.Text = v3[0].講授經驗_A.ToString();
|
||||
txt口碑評價A.Text = v3[0].口碑與評價_A.ToString();
|
||||
txt費用A.Text = v3[0].費用_A.ToString();
|
||||
txt配合度A.Text = v3[0].配合度_A.ToString();
|
||||
lb合計A.Text = v3[0].合計_A.ToString();
|
||||
}
|
||||
|
||||
if (v3[0].講師編號_B > 0)
|
||||
{
|
||||
lb講師二.Text = String.Format("[{0:0000}] {1}", v3[0].講師編號_B, Dao講師.Get姓名(v3[0].講師編號_B));
|
||||
txt講師姓名B.Text = Dao講師.Get姓名(v3[0].講師編號_B);
|
||||
txt講師姓名B.Enabled = false;
|
||||
txt學歷B.Text = v3[0].學歷_B;
|
||||
txt學歷B.Enabled = false;
|
||||
txt現職B.Text = v3[0].現職_B;
|
||||
txt現職B.Enabled = false;
|
||||
hf講師編號B.Value = v3[0].講師編號_B.ToString();
|
||||
ddl師資來源B.SelectedValue = v3[0].師資來源_B;
|
||||
txt專業背景B.Text = v3[0].專業背景_B.ToString();
|
||||
txt講授經驗B.Text = v3[0].講授經驗_B.ToString();
|
||||
txt口碑評價B.Text = v3[0].口碑與評價_B.ToString();
|
||||
txt費用B.Text = v3[0].費用_B.ToString();
|
||||
txt配合度B.Text = v3[0].配合度_B.ToString();
|
||||
lb合計B.Text = v3[0].合計_B.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(v3[0].講師姓名_B))
|
||||
{
|
||||
txt講師姓名B.Text = v3[0].講師姓名_B;
|
||||
txt學歷B.Text = v3[0].學歷_B;
|
||||
txt現職B.Text = v3[0].現職_B;
|
||||
ddl師資來源B.SelectedValue = v3[0].師資來源_B;
|
||||
txt專業背景B.Text = v3[0].專業背景_B.ToString();
|
||||
txt講授經驗B.Text = v3[0].講授經驗_B.ToString();
|
||||
txt口碑評價B.Text = v3[0].口碑與評價_B.ToString();
|
||||
txt費用B.Text = v3[0].費用_B.ToString();
|
||||
txt配合度B.Text = v3[0].配合度_B.ToString();
|
||||
lb合計B.Text = v3[0].合計_B.ToString();
|
||||
}
|
||||
|
||||
if (v3[0].講師編號_C > 0)
|
||||
{
|
||||
lb講師三.Text = String.Format("[{0:0000}] {1}", v3[0].講師編號_C, Dao講師.Get姓名(v3[0].講師編號_C));
|
||||
txt講師姓名C.Text = Dao講師.Get姓名(v3[0].講師編號_C);
|
||||
txt講師姓名C.Enabled = false;
|
||||
txt學歷C.Text = v3[0].學歷_C;
|
||||
txt學歷C.Enabled = false;
|
||||
txt現職C.Text = v3[0].現職_C;
|
||||
txt現職C.Enabled = false;
|
||||
hf講師編號C.Value = v3[0].講師編號_C.ToString();
|
||||
ddl師資來源C.SelectedValue = v3[0].師資來源_C;
|
||||
txt專業背景C.Text = v3[0].專業背景_C.ToString();
|
||||
txt講授經驗C.Text = v3[0].講授經驗_C.ToString();
|
||||
txt口碑評價C.Text = v3[0].口碑與評價_C.ToString();
|
||||
txt費用C.Text = v3[0].費用_C.ToString();
|
||||
txt配合度C.Text = v3[0].配合度_C.ToString();
|
||||
lb合計C.Text = v3[0].合計_C.ToString();
|
||||
}
|
||||
else if (!String.IsNullOrEmpty(v3[0].講師姓名_C))
|
||||
{
|
||||
txt講師姓名C.Text = v3[0].講師姓名_C;
|
||||
txt學歷C.Text = v3[0].學歷_C;
|
||||
txt現職C.Text = v3[0].現職_C;
|
||||
ddl師資來源C.SelectedValue = v3[0].師資來源_C;
|
||||
txt專業背景C.Text = v3[0].專業背景_C.ToString();
|
||||
txt講授經驗C.Text = v3[0].講授經驗_C.ToString();
|
||||
txt口碑評價C.Text = v3[0].口碑與評價_C.ToString();
|
||||
txt費用C.Text = v3[0].費用_C.ToString();
|
||||
txt配合度C.Text = v3[0].配合度_C.ToString();
|
||||
lb合計C.Text = v3[0].合計_C.ToString();
|
||||
}
|
||||
|
||||
txt總評.Text = v3[0].總評;
|
||||
txt備註.Text = v3[0].備註;
|
||||
}
|
||||
}
|
||||
|
||||
//protected void btnPickupA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf講師編號A.Value = DAC.GetString(FormView1.SelectedValue);
|
||||
// 講師List d = Dao講師.SelectOne(DAC.GetInt32(FormView1.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lb講師一.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].姓名);
|
||||
// lb講師一0.Text = d[0].最高學歷學校 + d[0].最高學歷科系;
|
||||
// lb講師一1.Text = d[0].現職;
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnPickupB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf講師編號B.Value = DAC.GetString(FormView1.SelectedValue);
|
||||
// 講師List d = Dao講師.SelectOne(DAC.GetInt32(FormView1.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lb講師二.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].姓名);
|
||||
// lb講師二0.Text = d[0].最高學歷學校 + d[0].最高學歷科系;
|
||||
// lb講師二1.Text = d[0].現職;
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnPickupC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// hf講師編號C.Value = DAC.GetString(FormView1.SelectedValue);
|
||||
// 講師List d = Dao講師.SelectOne(DAC.GetInt32(FormView1.SelectedValue));
|
||||
// if (d.Count > 0)
|
||||
// {
|
||||
// lb講師三.Text = String.Format("[{0:0000}] {1}", d[0].編號, d[0].姓名);
|
||||
// lb講師三0.Text = d[0].最高學歷學校 + d[0].最高學歷科系;
|
||||
// lb講師三1.Text = d[0].現職;
|
||||
// }
|
||||
//}
|
||||
|
||||
//protected void btnClearA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.ClearTeacher(課程企劃ID, 課程序號, "A");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnClearB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.ClearTeacher(課程企劃ID, 課程序號, "B");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnClearC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.ClearTeacher(課程企劃ID, 課程序號, "C");
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
protected void dsForm_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao講師;
|
||||
}
|
||||
|
||||
protected void dsGrid_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao講師;
|
||||
}
|
||||
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
Grid_View.PageIndex = 0;
|
||||
Grid_View.DataBind();
|
||||
}
|
||||
|
||||
//protected void btnSaveA_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.UpdateTeacher(課程企劃ID, 課程序號, "A",
|
||||
// DAC.GetInt32(hf講師編號A.Value),
|
||||
// lb講師一0.Text,
|
||||
// lb講師一1.Text,
|
||||
// ddl師資來源A.SelectedValue,
|
||||
// DAC.GetInt32(txt專業背景A.Text),
|
||||
// DAC.GetInt32(txt講授經驗A.Text),
|
||||
// DAC.GetInt32(txt口碑評價A.Text),
|
||||
// DAC.GetInt32(txt費用A.Text),
|
||||
// DAC.GetInt32(txt配合度A.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveB_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.UpdateTeacher(課程企劃ID, 課程序號, "B",
|
||||
// DAC.GetInt32(hf講師編號B.Value),
|
||||
// lb講師二0.Text,
|
||||
// lb講師二1.Text,
|
||||
// ddl師資來源B.SelectedValue,
|
||||
// DAC.GetInt32(txt專業背景B.Text),
|
||||
// DAC.GetInt32(txt講授經驗B.Text),
|
||||
// DAC.GetInt32(txt口碑評價B.Text),
|
||||
// DAC.GetInt32(txt費用B.Text),
|
||||
// DAC.GetInt32(txt配合度B.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveC_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.UpdateTeacher(課程企劃ID, 課程序號, "C",
|
||||
// DAC.GetInt32(hf講師編號C.Value),
|
||||
// lb講師三0.Text,
|
||||
// lb講師三1.Text,
|
||||
// ddl師資來源C.SelectedValue,
|
||||
// DAC.GetInt32(txt專業背景C.Text),
|
||||
// DAC.GetInt32(txt講授經驗C.Text),
|
||||
// DAC.GetInt32(txt口碑評價C.Text),
|
||||
// DAC.GetInt32(txt費用C.Text),
|
||||
// DAC.GetInt32(txt配合度C.Text));
|
||||
// UpdateUI();
|
||||
//}
|
||||
|
||||
//protected void btnSaveComment_Click(object sender, EventArgs e)
|
||||
//{
|
||||
// Dao講師遴選.UpdateComment(課程企劃ID, 課程序號, txt總評.Text, txt備註.Text);
|
||||
//}
|
||||
|
||||
protected override void FormView_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_DataBound(sender, e);
|
||||
|
||||
if (Form_View.CurrentMode == FormViewMode.ReadOnly)
|
||||
{
|
||||
int 編號 = 0;
|
||||
Label lb編號 = (Form_View.FindControl("lb編號") as Label);
|
||||
if (lb編號 != null)
|
||||
編號 = DAC.GetInt32(lb編號.Text);
|
||||
|
||||
Image image1 = (Form_View.FindControl("Image1") as Image);
|
||||
if (image1 != null)
|
||||
{
|
||||
string[] tmp = image1.ImageUrl.Split('?');
|
||||
if (tmp.Length > 0 && !File.Exists(Server.MapPath(tmp[0])))
|
||||
{
|
||||
image1.ImageUrl = "~/picture/nopicture.jpg";
|
||||
image1.Attributes.Remove("onclick");
|
||||
image1.Style.Remove("cursor");
|
||||
}
|
||||
else
|
||||
{
|
||||
image1.Attributes.Add("onclick", GetOpenWindowJS("../Common/ShowLargePicture.aspx", "_picture", "pic", String.Format(Education.PublicVariable.講師照片路徑 + "{0:000000}.jpg", 編號)));
|
||||
image1.Style.Add("cursor", "pointer");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//protected void 送簽1_DataBinding(object sender, EventArgs e)
|
||||
//{
|
||||
// 訓練課程企劃List d = Dao訓練課程企劃.SelectOne(課程企劃ID);
|
||||
// if (d.Count == 0)
|
||||
// 送簽1.可送簽 = false;
|
||||
// else
|
||||
// 送簽1.可送簽 = d[0].承辦.CompareTo(UserId) == 0;
|
||||
//}
|
||||
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
講師遴選 item = Dao講師遴選.SelectOne(課程企劃ID, 課程序號).FirstOrDefault();
|
||||
|
||||
if (item == null)
|
||||
{
|
||||
item = new 講師遴選()
|
||||
{
|
||||
課程企劃編號 = 課程企劃ID,
|
||||
課程序號 = 課程序號,
|
||||
|
||||
講師編號_A = DAC.GetInt32(hf講師編號A.Value),
|
||||
講師姓名_A = txt講師姓名A.Text,
|
||||
學歷_A = txt學歷A.Text,
|
||||
現職_A = txt現職A.Text,
|
||||
師資來源_A = ddl師資來源A.SelectedValue,
|
||||
專業背景_A = DAC.GetInt32(txt專業背景A.Text),
|
||||
講授經驗_A = DAC.GetInt32(txt講授經驗A.Text),
|
||||
口碑與評價_A = DAC.GetInt32(txt口碑評價A.Text),
|
||||
費用_A = DAC.GetInt32(txt費用A.Text),
|
||||
配合度_A = DAC.GetInt32(txt配合度A.Text),
|
||||
|
||||
講師編號_B = DAC.GetInt32(hf講師編號B.Value),
|
||||
講師姓名_B = txt講師姓名B.Text,
|
||||
學歷_B = txt學歷B.Text,
|
||||
現職_B = txt現職B.Text,
|
||||
師資來源_B = ddl師資來源B.SelectedValue,
|
||||
專業背景_B = DAC.GetInt32(txt專業背景B.Text),
|
||||
講授經驗_B = DAC.GetInt32(txt講授經驗B.Text),
|
||||
口碑與評價_B = DAC.GetInt32(txt口碑評價B.Text),
|
||||
費用_B = DAC.GetInt32(txt費用B.Text),
|
||||
配合度_B = DAC.GetInt32(txt配合度B.Text),
|
||||
|
||||
講師編號_C = DAC.GetInt32(hf講師編號C.Value),
|
||||
講師姓名_C = txt講師姓名C.Text,
|
||||
學歷_C = txt學歷C.Text,
|
||||
現職_C = txt現職C.Text,
|
||||
師資來源_C = ddl師資來源C.SelectedValue,
|
||||
專業背景_C = DAC.GetInt32(txt專業背景C.Text),
|
||||
講授經驗_C = DAC.GetInt32(txt講授經驗C.Text),
|
||||
口碑與評價_C = DAC.GetInt32(txt口碑評價C.Text),
|
||||
費用_C = DAC.GetInt32(txt費用C.Text),
|
||||
配合度_C = DAC.GetInt32(txt配合度C.Text),
|
||||
|
||||
總評 = txt總評.Text,
|
||||
備註 = txt備註.Text
|
||||
};
|
||||
Dao講師遴選.InsertOne(item);
|
||||
}
|
||||
else
|
||||
{
|
||||
item.講師編號_A = DAC.GetInt32(hf講師編號A.Value);
|
||||
item.講師姓名_A = txt講師姓名A.Text;
|
||||
item.學歷_A = txt學歷A.Text;
|
||||
item.現職_A = txt現職A.Text;
|
||||
item.師資來源_A = ddl師資來源A.SelectedValue;
|
||||
item.專業背景_A = DAC.GetInt32(txt專業背景A.Text);
|
||||
item.講授經驗_A = DAC.GetInt32(txt講授經驗A.Text);
|
||||
item.口碑與評價_A = DAC.GetInt32(txt口碑評價A.Text);
|
||||
item.費用_A = DAC.GetInt32(txt費用A.Text);
|
||||
item.配合度_A = DAC.GetInt32(txt配合度A.Text);
|
||||
|
||||
item.講師編號_B = DAC.GetInt32(hf講師編號B.Value);
|
||||
item.講師姓名_B = txt講師姓名B.Text;
|
||||
item.學歷_B = txt學歷B.Text;
|
||||
item.現職_B = txt現職B.Text;
|
||||
item.師資來源_B = ddl師資來源B.SelectedValue;
|
||||
item.專業背景_B = DAC.GetInt32(txt專業背景B.Text);
|
||||
item.講授經驗_B = DAC.GetInt32(txt講授經驗B.Text);
|
||||
item.口碑與評價_B = DAC.GetInt32(txt口碑評價B.Text);
|
||||
item.費用_B = DAC.GetInt32(txt費用B.Text);
|
||||
item.配合度_B = DAC.GetInt32(txt配合度B.Text);
|
||||
|
||||
item.講師編號_C = DAC.GetInt32(hf講師編號C.Value);
|
||||
item.講師姓名_C = txt講師姓名C.Text;
|
||||
item.學歷_C = txt學歷C.Text;
|
||||
item.現職_C = txt現職C.Text;
|
||||
item.師資來源_C = ddl師資來源C.SelectedValue;
|
||||
item.專業背景_C = DAC.GetInt32(txt專業背景C.Text);
|
||||
item.講授經驗_C = DAC.GetInt32(txt講授經驗C.Text);
|
||||
item.口碑與評價_C = DAC.GetInt32(txt口碑評價C.Text);
|
||||
item.費用_C = DAC.GetInt32(txt費用C.Text);
|
||||
item.配合度_C = DAC.GetInt32(txt配合度C.Text);
|
||||
|
||||
item.總評 = txt總評.Text;
|
||||
item.備註 = txt備註.Text;
|
||||
|
||||
Dao講師遴選.UpdateOne(item);
|
||||
}
|
||||
|
||||
UpdateUI();
|
||||
|
||||
ClientShowMessage("儲存成功!");
|
||||
}
|
||||
|
||||
protected string GetFormControlId(string id)
|
||||
{
|
||||
if (可異動 && FormView1.PageIndex >= 0)
|
||||
{
|
||||
Control ctrl = FormView1.FindControl(id);
|
||||
if (ctrl != null)
|
||||
return FormView1.FindControl(id).ClientID;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,989 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class PickupTeacher
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程企劃 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程企劃;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程企劃ID 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程企劃ID;
|
||||
|
||||
/// <summary>
|
||||
/// Label10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label10;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// hf課程序號 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf課程序號;
|
||||
|
||||
/// <summary>
|
||||
/// Label11 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label11;
|
||||
|
||||
/// <summary>
|
||||
/// btnPickupA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPickupA;
|
||||
|
||||
/// <summary>
|
||||
/// Label12 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label12;
|
||||
|
||||
/// <summary>
|
||||
/// btnPickupB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPickupB;
|
||||
|
||||
/// <summary>
|
||||
/// Label13 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label13;
|
||||
|
||||
/// <summary>
|
||||
/// btnPickupC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnPickupC;
|
||||
|
||||
/// <summary>
|
||||
/// Label15 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label15;
|
||||
|
||||
/// <summary>
|
||||
/// lb講師一 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb講師一;
|
||||
|
||||
/// <summary>
|
||||
/// hf講師編號A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf講師編號A;
|
||||
|
||||
/// <summary>
|
||||
/// lb講師二 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb講師二;
|
||||
|
||||
/// <summary>
|
||||
/// hf講師編號B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf講師編號B;
|
||||
|
||||
/// <summary>
|
||||
/// lb講師三 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb講師三;
|
||||
|
||||
/// <summary>
|
||||
/// hf講師編號C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hf講師編號C;
|
||||
|
||||
/// <summary>
|
||||
/// Label23 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label23;
|
||||
|
||||
/// <summary>
|
||||
/// Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt講師姓名A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講師姓名A;
|
||||
|
||||
/// <summary>
|
||||
/// txt講師姓名B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講師姓名B;
|
||||
|
||||
/// <summary>
|
||||
/// txt講師姓名C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講師姓名C;
|
||||
|
||||
/// <summary>
|
||||
/// txt學歷A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt學歷A;
|
||||
|
||||
/// <summary>
|
||||
/// txt學歷B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt學歷B;
|
||||
|
||||
/// <summary>
|
||||
/// txt學歷C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt學歷C;
|
||||
|
||||
/// <summary>
|
||||
/// Label24 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label24;
|
||||
|
||||
/// <summary>
|
||||
/// txt現職A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt現職A;
|
||||
|
||||
/// <summary>
|
||||
/// txt現職B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt現職B;
|
||||
|
||||
/// <summary>
|
||||
/// txt現職C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt現職C;
|
||||
|
||||
/// <summary>
|
||||
/// Label16 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label16;
|
||||
|
||||
/// <summary>
|
||||
/// ddl師資來源A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl師資來源A;
|
||||
|
||||
/// <summary>
|
||||
/// rfv師資來源A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv師資來源A;
|
||||
|
||||
/// <summary>
|
||||
/// ddl師資來源B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl師資來源B;
|
||||
|
||||
/// <summary>
|
||||
/// rfv師資來源B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv師資來源B;
|
||||
|
||||
/// <summary>
|
||||
/// ddl師資來源C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl師資來源C;
|
||||
|
||||
/// <summary>
|
||||
/// Label17 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label17;
|
||||
|
||||
/// <summary>
|
||||
/// txt專業背景A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt專業背景A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator1;
|
||||
|
||||
/// <summary>
|
||||
/// rfv專業背景A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv專業背景A;
|
||||
|
||||
/// <summary>
|
||||
/// txt專業背景B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt專業背景B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator2;
|
||||
|
||||
/// <summary>
|
||||
/// rfv專業背景B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv專業背景B;
|
||||
|
||||
/// <summary>
|
||||
/// txt專業背景C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt專業背景C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator3 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator3;
|
||||
|
||||
/// <summary>
|
||||
/// Label18 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label18;
|
||||
|
||||
/// <summary>
|
||||
/// txt講授經驗A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講授經驗A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator4 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator4;
|
||||
|
||||
/// <summary>
|
||||
/// rfv講授經驗A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv講授經驗A;
|
||||
|
||||
/// <summary>
|
||||
/// txt講授經驗B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講授經驗B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator5 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator5;
|
||||
|
||||
/// <summary>
|
||||
/// rfv講授經驗B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv講授經驗B;
|
||||
|
||||
/// <summary>
|
||||
/// txt講授經驗C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講授經驗C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator6 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator6;
|
||||
|
||||
/// <summary>
|
||||
/// Label19 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label19;
|
||||
|
||||
/// <summary>
|
||||
/// txt口碑評價A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt口碑評價A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator7 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator7;
|
||||
|
||||
/// <summary>
|
||||
/// rfv口碑評價A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv口碑評價A;
|
||||
|
||||
/// <summary>
|
||||
/// txt口碑評價B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt口碑評價B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator8 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator8;
|
||||
|
||||
/// <summary>
|
||||
/// rfv口碑評價B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv口碑評價B;
|
||||
|
||||
/// <summary>
|
||||
/// txt口碑評價C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt口碑評價C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator9;
|
||||
|
||||
/// <summary>
|
||||
/// Label20 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label20;
|
||||
|
||||
/// <summary>
|
||||
/// txt費用A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt費用A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator10;
|
||||
|
||||
/// <summary>
|
||||
/// rfv費用A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv費用A;
|
||||
|
||||
/// <summary>
|
||||
/// txt費用B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt費用B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator11 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator11;
|
||||
|
||||
/// <summary>
|
||||
/// rfv費用B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv費用B;
|
||||
|
||||
/// <summary>
|
||||
/// txt費用C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt費用C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator12 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator12;
|
||||
|
||||
/// <summary>
|
||||
/// Label21 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label21;
|
||||
|
||||
/// <summary>
|
||||
/// txt配合度A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt配合度A;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator13 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator13;
|
||||
|
||||
/// <summary>
|
||||
/// rfv配合度A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv配合度A;
|
||||
|
||||
/// <summary>
|
||||
/// txt配合度B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt配合度B;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator14 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator14;
|
||||
|
||||
/// <summary>
|
||||
/// rfv配合度B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv配合度B;
|
||||
|
||||
/// <summary>
|
||||
/// txt配合度C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt配合度C;
|
||||
|
||||
/// <summary>
|
||||
/// RangeValidator15 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator RangeValidator15;
|
||||
|
||||
/// <summary>
|
||||
/// Label22 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label22;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計A 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計A;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計B 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計B;
|
||||
|
||||
/// <summary>
|
||||
/// lb合計C 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb合計C;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearA 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearA;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearB 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearB;
|
||||
|
||||
/// <summary>
|
||||
/// btnClearC 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClearC;
|
||||
|
||||
/// <summary>
|
||||
/// Label25 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label25;
|
||||
|
||||
/// <summary>
|
||||
/// txt總評 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt總評;
|
||||
|
||||
/// <summary>
|
||||
/// rfv總評 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator rfv總評;
|
||||
|
||||
/// <summary>
|
||||
/// Label26 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label26;
|
||||
|
||||
/// <summary>
|
||||
/// txt備註 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt備註;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid;
|
||||
|
||||
/// <summary>
|
||||
/// pnlTeacher 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnlTeacher;
|
||||
|
||||
/// <summary>
|
||||
/// lb姓名Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb姓名Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt姓名 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt姓名;
|
||||
|
||||
/// <summary>
|
||||
/// lb電話Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb電話Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt電話 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt電話;
|
||||
|
||||
/// <summary>
|
||||
/// lb手機Label1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb手機Label1;
|
||||
|
||||
/// <summary>
|
||||
/// txt手機 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt手機;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearch;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage;
|
||||
|
||||
/// <summary>
|
||||
/// FormView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView FormView1;
|
||||
|
||||
/// <summary>
|
||||
/// GridView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView1;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,566 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/Site2.Master" AutoEventWireup="true"
|
||||
CodeBehind="數位課程管理.aspx.cs" Inherits="Education.Forms.課程企劃.數位課程管理" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="weblib" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<asp:LinkButton ID="btn處理" runat="server" CssClass="tabButtonSelected">處理</asp:LinkButton>
|
||||
<asp:LinkButton ID="btn查詢" runat="server" CssClass="tabButton">查詢</asp:LinkButton>
|
||||
<div style="border-top: 1px solid gray">
|
||||
<asp:MultiView ID="MultiView1" runat="server" ActiveViewIndex="0">
|
||||
<asp:View runat="server" ID="view處理">
|
||||
<asp:ObjectDataSource ID="dsForm" runat="server" DataObjectTypeName="Education.數位課程"
|
||||
DeleteMethod="DeleteOne" InsertMethod="InsertOne" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="SelectOne" TypeName="Education.DAC_數位課程" UpdateMethod="UpdateOne"
|
||||
OnObjectCreating="dsForm_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="GridView1" Name="課程編號" PropertyName="SelectedValue"
|
||||
Type="Int32" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="dsGrid" runat="server" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Select" TypeName="Education.DAC_數位課程" OnObjectCreating="dsGrid_ObjectCreating">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="true" Name="noInputReturnAll" Type="Boolean" />
|
||||
<asp:ControlParameter ControlID="txt課程名稱_Search" DefaultValue="" Name="課程名稱" PropertyName="Text"
|
||||
Type="String" />
|
||||
<asp:ControlParameter ControlID="dd課程類別_Search" DefaultValue="" Name="課程類別" PropertyName="SelectedValue"
|
||||
Type="String" />
|
||||
<asp:ControlParameter ControlID="txt講師_Search" Name="講師" PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txt課程簡介_Search" Name="課程簡介" PropertyName="Text"
|
||||
Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:ObjectDataSource ID="ds課程類別" runat="server" OldValuesParameterFormatString="original_{0}"
|
||||
SelectMethod="Get類別資料By大類ForDropDown" TypeName="Education.DAC_BCLS">
|
||||
<SelectParameters>
|
||||
<asp:Parameter DefaultValue="課程類別" Name="大類" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:Panel runat="server" ID="pnl挑選課程" Visible="false">
|
||||
<asp:ObjectDataSource ID="ds課程" runat="server"
|
||||
OldValuesParameterFormatString="original_{0}"
|
||||
OnObjectCreating="ds課程_ObjectCreating" SelectMethod="Select"
|
||||
TypeName="Education.DAC_課程">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="ddl課程類別Search" PropertyName="SelectedValue" Name="課程類別"
|
||||
Type="String"></asp:ControlParameter>
|
||||
<asp:ControlParameter ControlID="txt課程名稱Search" PropertyName="Text" Name="課程名稱" Type="String">
|
||||
</asp:ControlParameter>
|
||||
<asp:Parameter DefaultValue="2" Name="課程類型" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<table style="border-collapse: collapse; table-layout: fixed;">
|
||||
<tr>
|
||||
<td class="caption" style="width: 80px; padding: 5px;">課程類別</td>
|
||||
<td style="width: 150px; padding: 5px;">
|
||||
<weblib:WDropDownList ID="ddl課程類別Search" runat="server" CssClass="inputFull"
|
||||
DataSourceID="ds課程類別" DataTextField="Name" DataValueField="Value">
|
||||
</weblib:WDropDownList>
|
||||
</td>
|
||||
<td class="caption" style="width: 80px; padding: 5px;">課程名稱</td>
|
||||
<td style="width: 150px; padding: 5px;">
|
||||
<asp:TextBox ID="txt課程名稱Search" runat="server" CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
<td style="padding: 5px;">
|
||||
<asp:LinkButton ID="btnSelect課程" runat="server" CssClass="button blue80"
|
||||
OnClick="btnSelect課程_Click" CausesValidation="False">查詢</asp:LinkButton>
|
||||
<asp:Label ID="lbMessage課程內容" runat="server" CssClass="ErrorMessage"
|
||||
EnableViewState="False"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:GridView ID="gv課程挑選" runat="server" AllowPaging="True"
|
||||
AutoGenerateColumns="False" DataKeyNames="課程編號" DataSourceID="ds課程"
|
||||
EnableModelValidation="True" OnRowCommand="gv課程挑選_RowCommand" PageSize="5">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="btn挑選" runat="server" CommandArgument='<%# Eval("課程編號") %>'
|
||||
CommandName="Select" CssClass="button blue60" CausesValidation="false">挑選</asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="60px" Wrap="false" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程編號<br/>課程類別" SortExpression="課程編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" ForeColor="Blue"
|
||||
Text='<%# Bind("課程編號") %>'></asp:Label>
|
||||
<br />
|
||||
<asp:Label ID="Label2" runat="server" Text='<%# Eval("課程類別", "[{0}]") %>'></asp:Label>
|
||||
<asp:Label ID="Label3" runat="server"
|
||||
Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="150px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="150px" Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程名稱<br/>課程內容" SortExpression="課程名稱">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label4" runat="server" ForeColor="Blue"
|
||||
Text='<%# Bind("課程名稱") %>'></asp:Label>
|
||||
<div style="padding-left: 10px;">
|
||||
<asp:Label ID="Label5" runat="server"
|
||||
Text='<%# Eval("課程內容", "{0}").Replace("\r\n", "<br/>") %>'></asp:Label>
|
||||
</div>
|
||||
<br />
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="500px" />
|
||||
<ItemStyle HorizontalAlign="Left" Width="650px" Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="課程時數" SortExpression="課程時數">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label7" runat="server" Text='<%# Bind("課程時數") %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<HeaderStyle Width="80px" />
|
||||
<ItemStyle HorizontalAlign="Center" Wrap="true" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<weblib:GridViewPager ID="GridViewPager2" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Panel>
|
||||
<asp:FormView ID="FormView1" runat="server" DataSourceID="dsForm"
|
||||
EnableModelValidation="True" DataKeyNames="課程編號,DB_APPNO"
|
||||
OnItemCommand="FormView1_ItemCommand">
|
||||
<ItemTemplate>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnInsert" runat="server" Text="新增" CommandName="New" CssClass="button blue80" />
|
||||
<asp:LinkButton ID="btnUpdate" runat="server" Text="更正" CommandName="Edit" CssClass="button green80" />
|
||||
<asp:LinkButton ID="btnDelete" runat="server" Text="刪除" CommandName="Delete" CssClass="button red80"
|
||||
OnClientClick="return confirm("是否確定刪除此筆資料?");" />
|
||||
<asp:LinkButton ID="btn計畫別" runat="server" CssClass="button gray100"
|
||||
OnClientClick='<%# GetOpenWindowJS("PickupProject.aspx", "_blank", "id", Eval("課程編號"), "type", "digital") %>'
|
||||
Visible='<%# Eval("開放觀看", "{0}").ToUpper() != "Y" %>'>計畫別</asp:LinkButton>
|
||||
<asp:LinkButton ID="btn訓練對象" runat="server" CssClass="button gray100"
|
||||
OnClientClick='<%# GetOpenWindowJS("PickupPeople.aspx", "_blank", "id", Eval("課程編號"), "type", "digital") %>'
|
||||
Visible='<%# Eval("開放觀看", "{0}").ToUpper() != "Y" %>'>訓練對象</asp:LinkButton>
|
||||
</div>
|
||||
<table border="0" cellpadding="3" cellspacing="2" style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 125px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程編號Label" runat="server" Text="課程編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb課程編號" runat="server" Text='<%# Bind("課程編號", "{0:000000}") %>' CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程類別Label" runat="server" Text="課程類別"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb課程類別" runat="server" Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb開放觀看Label" runat="server" Text="開放所有人觀看"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb開放觀看" runat="server" CssClass="inputFull" Text='<%# Eval("開放觀看", "{0}").ToUpper() == "Y" ? "是" : "否" %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程名稱Label" runat="server" Text="課程名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb課程名稱" runat="server" CssClass="inputFull" Text='<%# Bind("課程名稱") %>'></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb講師Label" runat="server" Text="講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb講師" runat="server" CssClass="inputFull" Text='<%# Bind("講師") %>'></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb長度Label" runat="server" Text="長度"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb長度" runat="server" CssClass="inputFull" Text='<%# Bind("長度") %>'></asp:Label>
|
||||
<asp:Label ID="lb長度0" runat="server" CssClass="inputFull" Text="分鐘"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程簡介Label" runat="server" Text="課程簡介"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:Label ID="lb課程簡介" runat="server" Text='<%# Eval("課程簡介", "{0}").Replace("\r", "<br/>") %>'
|
||||
CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程網址Label" runat="server" Text="課程網址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:HyperLink ID="hl課程網址" runat="server" Target="_blank"
|
||||
Text='<%# Eval("課程網址", "{0}").Length > 0 ? Eval("課程網址", "{0}") : "無" %>'
|
||||
NavigateUrl='<%# Eval("課程網址", "{0}").Length > 0 ? Eval("課程網址", "{0}") : "" %>'></asp:HyperLink>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程文件Label" runat="server" Text="課程文件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:HyperLink ID="hl課程文件" runat="server" Target="_blank"
|
||||
Text='<%# Eval("課程文件", "{0}").Length > 0 ? Eval("課程文件", "{0}") : "無" %>'
|
||||
NavigateUrl='<%# Eval("課程文件", "{0}").Length > 0 ? "~/DocUpload/" + Eval("課程文件", "{0}") : "" %>'></asp:HyperLink>
|
||||
<asp:FileUpload ID="fu課程文件" runat="server" />
|
||||
<asp:LinkButton ID="btnUpload1" runat="server"
|
||||
CommandArgument='<%# Eval("課程編號") %>' CommandName="上傳文件1"
|
||||
CssClass="button gray80">上傳文件</asp:LinkButton>
|
||||
<asp:LinkButton ID="LinkButton2" runat="server"
|
||||
CommandArgument='<%# Eval("課程編號") %>' CommandName="刪除文件1"
|
||||
CssClass="button red80" OnClientClick="return confirm("是否刪除課程文件?")">刪除文件</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb評量文件Label" runat="server" Text="評量文件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5">
|
||||
<asp:HyperLink ID="hl評量文件" runat="server" Target="_blank"
|
||||
Text='<%# Eval("評量文件", "{0}").Length > 0 ? Eval("評量文件", "{0}") : "無" %>'
|
||||
NavigateUrl='<%# Eval("評量文件", "{0}").Length > 0 ? "~/DocUpload/" + Eval("評量文件", "{0}") : "" %>'></asp:HyperLink>
|
||||
<asp:FileUpload ID="fu評量文件" runat="server" />
|
||||
<asp:LinkButton ID="btnUpload2" runat="server"
|
||||
CommandArgument='<%# Eval("課程編號") %>' CommandName="上傳文件2"
|
||||
CssClass="button gray80">上傳文件</asp:LinkButton>
|
||||
<asp:LinkButton ID="LinkButton3" runat="server"
|
||||
CommandArgument='<%# Eval("課程編號") %>' CommandName="刪除文件2"
|
||||
CssClass="button red80" OnClientClick="return confirm("是否刪除評量文件?")">刪除文件</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</ItemTemplate>
|
||||
<InsertItemTemplate>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnSave" runat="server" CommandName="Insert"
|
||||
CssClass="button blue80" Text="存檔" />
|
||||
<asp:LinkButton ID="btnCancel" runat="server" CausesValidation="false"
|
||||
CommandName="Cancel" CssClass="button red80"
|
||||
OnClientClick="return confirm("是否確定取消新增?");" Text="取消" />
|
||||
</div>
|
||||
<table border="0" cellpadding="3" cellspacing="2" style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程編號Label" runat="server" Text="課程編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb課程編號" runat="server" Text="(自動編號)" CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程類別Label" runat="server" Text="課程類別"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<weblib:WDropDownList ID="dd課程類別" runat="server" SelectedValue='<%# Bind("課程類別") %>'
|
||||
CssClass="inputFull" DataSourceID="ds課程類別" DataTextField="Name" DataValueField="Value">
|
||||
</weblib:WDropDownList>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="dd課程類別"
|
||||
Display="Dynamic" ErrorMessage="請選擇"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput" colspan="2">
|
||||
<weblib:ValueCheckBox ID="cb開放觀看" runat="server" CssClass="inputFull" Text="開放所有人觀看"
|
||||
Value='<%# Bind("開放觀看") %>' />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程名稱Label" runat="server" Text="課程名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程名稱" runat="server" CssClass="inputFull" MaxLength="100" Text='<%# Bind("課程名稱") %>'></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txt課程名稱"
|
||||
Display="Dynamic" ErrorMessage="請輸入"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb講師Label" runat="server" Text="講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<asp:TextBox ID="txt講師" runat="server" CssClass="inputFull" MaxLength="50" Text='<%# Bind("講師") %>'></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb長度Label" runat="server" Text="長度(分鐘)"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<asp:TextBox ID="txt長度" runat="server" CssClass="inputFull" MaxLength="4" Text='<%# Bind("長度") %>'></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="rfv長度" runat="server" ControlToValidate="txt長度" Display="Dynamic"
|
||||
ErrorMessage="請輸入"></asp:RequiredFieldValidator>
|
||||
<asp:RangeValidator ID="rv長度" runat="server" ControlToValidate="txt長度" Display="Dynamic"
|
||||
ErrorMessage="請輸入 1-1000 的數字" MaximumValue="1000" MinimumValue="0" Type="Integer"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程簡介Label" runat="server" Text="課程簡介"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程簡介" runat="server" Text='<%# Bind("課程簡介") %>' MaxLength="1000"
|
||||
TextMode="MultiLine" Rows="5" CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程網址Label" runat="server" Text="課程網址"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程網址" runat="server" Text='<%# Bind("課程網址") %>' MaxLength="100"
|
||||
CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</InsertItemTemplate>
|
||||
<EditItemTemplate>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnSave" runat="server" Text="存檔" CommandName="Update" CssClass="button blue80" />
|
||||
<asp:LinkButton ID="btnCancel" runat="server" Text="取消" CommandName="Cancel" CausesValidation="false"
|
||||
CssClass="button red80" OnClientClick="return confirm("是否確定取消更正?");" />
|
||||
<asp:HiddenField ID="hfDBAPPNO" runat="server" Value='<%# Bind("DB_APPNO") %>' />
|
||||
</div>
|
||||
<table border="0" cellpadding="3" cellspacing="2" style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程編號Label" runat="server" Text="課程編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1">
|
||||
<asp:Label ID="lb課程編號" runat="server" Text='<%# Bind("課程編號", "{0:00000}") %>' CssClass="inputFull"></asp:Label>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程類別Label" runat="server" Text="課程類別"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<weblib:WDropDownList ID="dd課程類別" runat="server" SelectedValue='<%# Bind("課程類別") %>'
|
||||
CssClass="inputFull" DataSourceID="ds課程類別" DataTextField="Name" DataValueField="Value">
|
||||
</weblib:WDropDownList>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="dd課程類別"
|
||||
Display="Dynamic" ErrorMessage="請選擇"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
<td class="datainput" colspan="2">
|
||||
<weblib:ValueCheckBox ID="cb開放觀看" runat="server" CssClass="inputFull" Text="開放所有人觀看"
|
||||
Value='<%# Bind("開放觀看") %>' />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程名稱Label" runat="server" Text="課程名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程名稱" runat="server" CssClass="inputFull" MaxLength="100" Text='<%# Bind("課程名稱") %>'></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txt課程名稱"
|
||||
Display="Dynamic" ErrorMessage="請輸入"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb講師Label" runat="server" Text="講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<asp:TextBox ID="txt講師" runat="server" CssClass="inputFull" MaxLength="50" Text='<%# Bind("講師") %>'></asp:TextBox>
|
||||
</td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb長度Label" runat="server" Text="長度(分鐘)"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<asp:TextBox ID="txt長度" runat="server" CssClass="inputFull" MaxLength="4" Text='<%# Bind("長度") %>'></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="rfv長度" runat="server" ControlToValidate="txt長度" Display="Dynamic"
|
||||
ErrorMessage="請輸入"></asp:RequiredFieldValidator>
|
||||
<asp:RangeValidator ID="rv長度" runat="server" ControlToValidate="txt長度" Display="Dynamic"
|
||||
ErrorMessage="請輸入 1-1000 的數字" MaximumValue="1000" MinimumValue="0" Type="Integer"></asp:RangeValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程簡介Label" runat="server" Text="課程簡介"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程簡介" runat="server" Text='<%# Bind("課程簡介") %>' MaxLength="1000"
|
||||
TextMode="MultiLine" Rows="5" CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程網址Label" runat="server" Text="課程網址"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="5">
|
||||
<asp:TextBox ID="txt課程網址" runat="server" Text='<%# Bind("課程網址") %>' MaxLength="100"
|
||||
CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</EditItemTemplate>
|
||||
<EmptyDataTemplate>
|
||||
<div>
|
||||
<asp:LinkButton ID="btnInsert" runat="server" Text="新增" CommandName="New" CssClass="button blue80" />
|
||||
</div>
|
||||
<table border="0" cellpadding="3" cellspacing="2" style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 125px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 150px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程編號Label" runat="server" Text="課程編號"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1"></td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程類別Label" runat="server" Text="課程類別"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1"></td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb開放觀看Label" runat="server" Text="開放所有人觀看"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程名稱Label" runat="server" Text="課程名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb講師Label" runat="server" Text="講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1"> </td>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb長度Label" runat="server" Text="長度"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="1"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程簡介Label" runat="server" Text="課程簡介"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程網址Label" runat="server" Text="課程網址"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程文件Label" runat="server" Text="課程文件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb評量文件Label" runat="server" Text="評量文件"></asp:Label>
|
||||
</td>
|
||||
<td class="datadisplay" colspan="5"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</EmptyDataTemplate>
|
||||
</asp:FormView>
|
||||
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataKeyNames="課程編號,DB_APPNO"
|
||||
DataSourceID="dsGrid" EnableModelValidation="True">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="課程編號" SortExpression="課程編號">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Bind("課程編號", "{0:000000}") %>'></asp:Label>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Select"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="課程名稱" HeaderText="課程名稱" SortExpression="課程名稱" />
|
||||
<asp:BoundField DataField="講師" HeaderText="講師" SortExpression="講師">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="長度" HeaderText="長度" SortExpression="長度">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="開放所有人觀看" SortExpression="開放觀看">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb開放觀看" runat="server" CssClass="inputFull" Text='<%# Eval("開放觀看", "{0}").ToUpper() == "Y" ? "是" : "否" %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</asp:View>
|
||||
<asp:View runat="server" ID="view查詢">
|
||||
<div>
|
||||
<asp:LinkButton ID="btnSearch" runat="server" Text="查詢" CssClass="button blue80"
|
||||
OnClick="btnSearch_Click" />
|
||||
<asp:LinkButton ID="btnClear" runat="server" Text="清除" CssClass="button red80" OnClick="btnClear_Click" />
|
||||
</div>
|
||||
<table border="0" style="table-layout: fixed;">
|
||||
<tr>
|
||||
<td colspan="1" class="widthcontrol" style="width: 90px;"></td>
|
||||
<td colspan="1" class="widthcontrol" style="width: 250px;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程類別Label" runat="server" Text="課程類別"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<weblib:WDropDownList ID="dd課程類別_Search" runat="server" CssClass="inputFull" DataSourceID="ds課程類別"
|
||||
DataTextField="Name" DataValueField="Value"></weblib:WDropDownList>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb講師Label" runat="server" Text="講師"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput" colspan="1">
|
||||
<asp:TextBox ID="txt講師_Search" runat="server" Text="" MaxLength="50" CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程名稱Label" runat="server" Text="課程名稱"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt課程名稱_Search" runat="server" Text="" MaxLength="100" CssClass="inputFull"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="lb課程簡介Label" runat="server" Text="課程簡介"></asp:Label>
|
||||
</td>
|
||||
<td class="datainput">
|
||||
<asp:TextBox ID="txt課程簡介_Search" runat="server" CssClass="inputFull" MaxLength="1000"
|
||||
Text=""></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:Label ID="lbMessage" runat="server" CssClass="ErrorMessage" EnableViewState="False"></asp:Label>
|
||||
</asp:View>
|
||||
</asp:MultiView>
|
||||
</div>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,333 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.IO;
|
||||
using WebLib;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class 數位課程管理 : FormBase
|
||||
{
|
||||
private DAC_數位課程 Dao數位課程;
|
||||
private string docPath;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "數位課程管理";
|
||||
Dao數位課程 = new DAC_數位課程(conn);
|
||||
//Dao數位課程.CurrentUserId = UserId;
|
||||
|
||||
docPath = Server.MapPath("~/DocUpload");
|
||||
if (!Directory.Exists(docPath))
|
||||
Directory.CreateDirectory(docPath);
|
||||
|
||||
Form_View = FormView1;
|
||||
Grid_View = GridView1;
|
||||
FormView_DataSource = dsForm;
|
||||
GridView_DataSource = dsGrid;
|
||||
|
||||
AddTabButton(MultiView1, view處理, btn處理);
|
||||
AddTabButton(MultiView1, view查詢, btn查詢);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
ActivateTab(MultiView1, view處理);
|
||||
}
|
||||
else
|
||||
{
|
||||
Grid_View.DataBind();
|
||||
Form_View.DataBind();
|
||||
|
||||
if (pnl挑選課程.Visible)
|
||||
{
|
||||
gv課程挑選.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void dsForm_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao數位課程;
|
||||
}
|
||||
|
||||
protected void dsGrid_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao數位課程;
|
||||
}
|
||||
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
Grid_View.PageIndex = 0;
|
||||
Grid_View.DataBind();
|
||||
}
|
||||
|
||||
protected override void FormView_ReadOnlyDataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_ReadOnlyDataBound(sender, e);
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnUpload1"));
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnUpload2"));
|
||||
}
|
||||
|
||||
protected override void FormView_InsertDataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_InsertDataBound(sender, e);
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnSave"));
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnCancel"));
|
||||
Form_View.FindControl("txt課程名稱").Focus();
|
||||
FindControl<TextBox>(Form_View, "txt長度").Text = "0";
|
||||
FindControl<ValueCheckBox>(Form_View, "cb開放觀看").Checked = true;
|
||||
}
|
||||
|
||||
protected override void FormView_EditDataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_EditDataBound(sender, e);
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnSave"));
|
||||
RegisterPostbackTrigger(Form_View.FindControl("btnCancel"));
|
||||
Form_View.FindControl("txt課程名稱").Focus();
|
||||
}
|
||||
|
||||
protected override void GridView_DataSource_Selected(object sender, ObjectDataSourceStatusEventArgs e)
|
||||
{
|
||||
base.GridView_DataSource_Selected(sender, e);
|
||||
|
||||
if (MultiView1.ActiveViewIndex == 1)
|
||||
{
|
||||
if (e.ReturnValue is 數位課程List list && list.Count > 0)
|
||||
ActivateTab(MultiView1, 1);
|
||||
else
|
||||
lbMessage.Text = "找不到合乎條件的資料";
|
||||
}
|
||||
}
|
||||
|
||||
private bool 儲存上傳檔案(FileUpload fu, int 課程編號, out string fileName)
|
||||
{
|
||||
if (fu == null || !fu.HasFile)
|
||||
{
|
||||
fileName = "";
|
||||
return false;
|
||||
}
|
||||
fileName = String.Format("{0:000000}_{1}", 課程編號, fu.FileName);
|
||||
|
||||
File.WriteAllBytes(docPath + "\\" + fileName, fu.FileBytes);
|
||||
return true;
|
||||
}
|
||||
|
||||
private void 刪除上傳檔案(int 課程編號, bool del課程文件 = true, bool del評量文件 = true)
|
||||
{
|
||||
數位課程List d = Dao數位課程.SelectOne(課程編號);
|
||||
if (d.Count > 0)
|
||||
{
|
||||
if (del課程文件 && d[0].課程文件.Length > 0 && File.Exists(docPath + "\\" + d[0].課程文件))
|
||||
File.Delete(docPath + "\\" + d[0].課程文件);
|
||||
if (del評量文件 && d[0].評量文件.Length > 0 && File.Exists(docPath + "\\" + d[0].評量文件))
|
||||
File.Delete(docPath + "\\" + d[0].評量文件);
|
||||
}
|
||||
}
|
||||
|
||||
protected override void FormView_ItemInserting(object sender, FormViewInsertEventArgs e)
|
||||
{
|
||||
base.FormView_ItemInserting(sender, e);
|
||||
//fu課程文件 = Form_View.FindControl("fu課程文件") as FileUpload;
|
||||
//fu評量文件 = Form_View.FindControl("fu評量文件") as FileUpload;
|
||||
}
|
||||
|
||||
protected override void FormView_ItemUpdating(object sender, FormViewUpdateEventArgs e)
|
||||
{
|
||||
base.FormView_ItemUpdating(sender, e);
|
||||
//fu課程文件 = Form_View.FindControl("fu課程文件") as FileUpload;
|
||||
//fu評量文件 = Form_View.FindControl("fu評量文件") as FileUpload;
|
||||
}
|
||||
|
||||
protected override void FormView_DataSource_Inserted(object sender, ObjectDataSourceStatusEventArgs e)
|
||||
{
|
||||
base.FormView_DataSource_Inserted(sender, e);
|
||||
int id = DAC.GetInt32(e.ReturnValue);
|
||||
|
||||
// 處理上傳檔案
|
||||
/*
|
||||
數位課程List d = Dao數位課程.SelectOne(id);
|
||||
if (d.Count > 0)
|
||||
{
|
||||
string fileName1;
|
||||
string fileName2;
|
||||
|
||||
if (儲存上傳檔案(fu課程文件, id, out fileName1))
|
||||
{
|
||||
d[0].課程文件 = fileName1;
|
||||
}
|
||||
if (儲存上傳檔案(fu評量文件, id, out fileName2))
|
||||
{
|
||||
d[0].評量文件 = fileName2;
|
||||
}
|
||||
Dao數位課程.UpdateOne(d[0]);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
protected override void FormView_DataSource_Updating(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
base.FormView_DataSource_Updating(sender, e);
|
||||
數位課程 value = e.InputParameters[0] as 數位課程;
|
||||
|
||||
/*
|
||||
string fileName1;
|
||||
string fileName2;
|
||||
|
||||
// 刪除舊上傳檔案
|
||||
刪除上傳檔案(value.課程編號, fu課程文件.HasFile, fu評量文件.HasFile);
|
||||
|
||||
// 儲存新上傳檔案
|
||||
if (儲存上傳檔案(fu課程文件, value.課程編號, out fileName1))
|
||||
{
|
||||
value.課程文件 = fileName1;
|
||||
}
|
||||
|
||||
if (儲存上傳檔案(fu評量文件, value.課程編號, out fileName2))
|
||||
{
|
||||
value.評量文件 = fileName2;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
protected override void FormView_DataSource_Deleting(object sender, ObjectDataSourceMethodEventArgs e)
|
||||
{
|
||||
base.FormView_DataSource_Deleting(sender, e);
|
||||
|
||||
// 刪除上傳檔案
|
||||
數位課程 value = e.InputParameters[0] as 數位課程;
|
||||
刪除上傳檔案(value.課程編號);
|
||||
}
|
||||
|
||||
protected void btnClear_Click(object sender, EventArgs e)
|
||||
{
|
||||
txt講師_Search.Text = "";
|
||||
txt課程名稱_Search.Text = "";
|
||||
txt課程簡介_Search.Text = "";
|
||||
}
|
||||
|
||||
protected void FormView1_ItemCommand(object sender, FormViewCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "刪除文件1" || e.CommandName == "刪除文件2")
|
||||
{
|
||||
數位課程List d = Dao數位課程.SelectOne(DAC.GetInt32(Form_View.SelectedValue));
|
||||
if (d.Count > 0)
|
||||
{
|
||||
string fileName;
|
||||
|
||||
if (e.CommandName == "刪除文件1" && d[0].課程文件.Length > 0)
|
||||
{
|
||||
fileName = String.Format("{0}\\{1}", docPath, d[0].課程文件);
|
||||
if (File.Exists(fileName))
|
||||
{
|
||||
File.Delete(fileName);
|
||||
d[0].課程文件 = "";
|
||||
}
|
||||
}
|
||||
else if (e.CommandName == "刪除文件2" && d[0].評量文件.Length > 0)
|
||||
{
|
||||
fileName = String.Format("{0}\\{1}", docPath, d[0].評量文件);
|
||||
if (File.Exists(fileName))
|
||||
{
|
||||
File.Delete(fileName);
|
||||
d[0].評量文件 = "";
|
||||
}
|
||||
}
|
||||
else
|
||||
return;
|
||||
|
||||
Dao數位課程.UpdateOne(d[0]);
|
||||
Form_View.DataBind();
|
||||
}
|
||||
}
|
||||
|
||||
if (e.CommandName == "上傳文件1")
|
||||
{
|
||||
FileUpload fu = FindControl<FileUpload>(Form_View, "fu課程文件");
|
||||
int id = DAC.GetInt32(Form_View.SelectedValue);
|
||||
|
||||
數位課程List d = Dao數位課程.SelectOne(id);
|
||||
if (d.Count > 0 && fu.HasFile)
|
||||
{
|
||||
刪除上傳檔案(id, true, false);
|
||||
|
||||
string fileName;
|
||||
if (儲存上傳檔案(fu, id, out fileName))
|
||||
{
|
||||
d[0].課程文件 = fileName;
|
||||
Dao數位課程.UpdateOne(d[0]);
|
||||
Form_View.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (e.CommandName == "上傳文件2")
|
||||
{
|
||||
FileUpload fu = FindControl<FileUpload>(Form_View, "fu評量文件");
|
||||
int id = DAC.GetInt32(Form_View.SelectedValue);
|
||||
|
||||
數位課程List d = Dao數位課程.SelectOne(id);
|
||||
if (d.Count > 0 && fu.HasFile)
|
||||
{
|
||||
刪除上傳檔案(id, false, true);
|
||||
|
||||
string fileName;
|
||||
if (儲存上傳檔案(fu, id, out fileName))
|
||||
{
|
||||
d[0].評量文件 = fileName;
|
||||
Dao數位課程.UpdateOne(d[0]);
|
||||
Form_View.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void ds課程_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao課程;
|
||||
}
|
||||
|
||||
protected void gv課程挑選_RowCommand(object sender, GridViewCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "Select")
|
||||
{
|
||||
// 挑選此課程,把課程相關資料抓出來填入底下
|
||||
課程List d = Dao課程.SelectOne(e.CommandArgument.ToString());
|
||||
if (d.Count > 0)
|
||||
{
|
||||
FindControl<DropDownList>(Form_View, "dd課程類別").SelectedValue = d[0].課程類別;
|
||||
FindControl<TextBox>(Form_View, "txt課程名稱").Text = d[0].課程名稱;
|
||||
FindControl<TextBox>(Form_View, "txt課程簡介").Text = d[0].課程內容;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnSelect課程_Click(object sender, EventArgs e)
|
||||
{
|
||||
//DropDownList ddl課程類別Search = Form_View.FindControl("ddl課程類別Search") as DropDownList;
|
||||
//Label lbMessage課程內容 = Form_View.FindControl("lbMessage課程內容") as Label;
|
||||
//GridView gv課程挑選 = Form_View.FindControl("gv課程挑選") as GridView;
|
||||
if (ddl課程類別Search.SelectedValue == null || ddl課程類別Search.SelectedValue.Length == 0)
|
||||
{
|
||||
lbMessage課程內容.Text = "請選擇一個課程類別再查詢";
|
||||
return;
|
||||
}
|
||||
|
||||
gv課程挑選.DataBind();
|
||||
|
||||
if (gv課程挑選.Rows.Count == 0)
|
||||
lbMessage課程內容.Text = "找不到合乎條件的課程";
|
||||
}
|
||||
|
||||
protected override void FormView_ModeChanged(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_ModeChanged(sender, e);
|
||||
|
||||
pnl挑選課程.Visible = Form_View.CurrentMode == FormViewMode.Insert;
|
||||
if (pnl挑選課程.Visible)
|
||||
gv課程挑選.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
+269
@@ -0,0 +1,269 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class 數位課程管理
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// btn處理 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btn處理;
|
||||
|
||||
/// <summary>
|
||||
/// btn查詢 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btn查詢;
|
||||
|
||||
/// <summary>
|
||||
/// MultiView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.MultiView MultiView1;
|
||||
|
||||
/// <summary>
|
||||
/// view處理 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.View view處理;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid;
|
||||
|
||||
/// <summary>
|
||||
/// ds課程類別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds課程類別;
|
||||
|
||||
/// <summary>
|
||||
/// pnl挑選課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel pnl挑選課程;
|
||||
|
||||
/// <summary>
|
||||
/// ds課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds課程;
|
||||
|
||||
/// <summary>
|
||||
/// ddl課程類別Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList ddl課程類別Search;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程名稱Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程名稱Search;
|
||||
|
||||
/// <summary>
|
||||
/// btnSelect課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSelect課程;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage課程內容 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage課程內容;
|
||||
|
||||
/// <summary>
|
||||
/// gv課程挑選 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView gv課程挑選;
|
||||
|
||||
/// <summary>
|
||||
/// FormView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView FormView1;
|
||||
|
||||
/// <summary>
|
||||
/// GridView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView1;
|
||||
|
||||
/// <summary>
|
||||
/// view查詢 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.View view查詢;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearch;
|
||||
|
||||
/// <summary>
|
||||
/// btnClear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClear;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程類別Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程類別Label;
|
||||
|
||||
/// <summary>
|
||||
/// dd課程類別_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList dd課程類別_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb講師Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb講師Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt講師_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt講師_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程名稱Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程名稱Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程名稱_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程名稱_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb課程簡介Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb課程簡介Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt課程簡介_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt課程簡介_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,114 @@
|
||||
<%@ Page Title="" Language="C#" MasterPageFile="~/Site2.Master" AutoEventWireup="true" CodeBehind="數位課程訓練對象.aspx.cs" Inherits="Education.Forms.課程企劃.數位課程訓練對象" %>
|
||||
|
||||
<%@ Register Assembly="WebLib" Namespace="WebLib" TagPrefix="cc1" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
|
||||
<h3>一、查詢員工</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label9" runat="server" Text="員工編號"></asp:Label>
|
||||
</td>
|
||||
<td>
|
||||
<asp:TextBox ID="txtBPENO" runat="server"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="caption">
|
||||
<asp:Label ID="Label10" runat="server" Text="員工姓名"></asp:Label>
|
||||
</td>
|
||||
<td>
|
||||
<asp:TextBox ID="txtBPNME" runat="server"></asp:TextBox>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<asp:LinkButton ID="btnSearch員工" runat="server" CssClass="button blue80" OnClick="btnSearch員工_Click">查詢</asp:LinkButton>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<asp:Panel ID="Panel1" runat="server" Visible="false">
|
||||
<h3>二、選擇一個員工</h3>
|
||||
<asp:ObjectDataSource ID="ds員工" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="Select" TypeName="Education.DAC_BPSN">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="txtBPENO" Name="BPENO" PropertyName="Text" Type="String" />
|
||||
<asp:ControlParameter ControlID="txtBPNME" Name="BPNME" PropertyName="Text" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataSourceID="ds員工" DataKeyNames="員工編號"
|
||||
EnableModelValidation="True" AllowPaging="True" OnDataBound="GridView1_DataBound"
|
||||
OnSelectedIndexChanged="GridView1_SelectedIndexChanged">
|
||||
<Columns>
|
||||
<asp:TemplateField ShowHeader="False">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Select" CssClass="button blue60" Text="選取"></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="員工編號" HeaderText="員工編號">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="員工姓名" HeaderText="員工姓名">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="計畫年度名稱" HeaderText="計畫名稱"></asp:BoundField>
|
||||
<asp:BoundField DataField="站別名稱" HeaderText="站別">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="職務名稱" HeaderText="職務">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<cc1:GridViewPager ID="GridViewPager1" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Panel>
|
||||
<asp:Panel ID="Panel2" runat="server" Visible="false">
|
||||
<h3>三、挑選這個員工應觀看的數位課程 (此處列出的是「不開放給所有人」的課程)</h3>
|
||||
<asp:Label ID="Label2" runat="server" Text="已觀看不可移除" ForeColor="Red"></asp:Label>
|
||||
<asp:ObjectDataSource ID="ds數位課程" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="Select非開放課程" TypeName="Education.DAC_數位課程"></asp:ObjectDataSource>
|
||||
<asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" DataKeyNames="課程編號" DataSourceID="ds數位課程" EnableModelValidation="True" AllowPaging="True" OnRowCommand="GridView2_RowCommand">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LinkButton2" runat="server" CommandArgument='<%# Eval("課程編號") %>' CommandName="Add" CssClass="button green60">加入</asp:LinkButton>
|
||||
<asp:LinkButton ID="LinkButton3" runat="server" CommandArgument='<%# Eval("課程編號") %>' CommandName="Remove" CssClass="button red60">移除</asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="應觀看">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb已報名" runat="server" Text="是" ForeColor="Red" Visible='<%# Dao數位課程觀看紀錄.是否報名(DAC.GetInt32(Eval("課程編號")), DAC.GetString(GridView1.SelectedValue)) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="已觀看">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lb已觀看" runat="server" Text="是" ForeColor="Red" Visible='<%# Dao數位課程觀看紀錄.是否觀看(DAC.GetInt32(Eval("課程編號")), DAC.GetString(GridView1.SelectedValue)) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="課程編號" DataFormatString="{0:000000}" HeaderText="課程編號" ReadOnly="True" SortExpression="課程編號">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="課程名稱" HeaderText="課程名稱" SortExpression="課程名稱" />
|
||||
<asp:TemplateField HeaderText="課程類別" SortExpression="課程類別">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Get類別名稱("課程類別", Eval("課程類別")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="講師" HeaderText="講師" SortExpression="講師">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField DataField="長度" HeaderText="長度" SortExpression="長度">
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
</asp:BoundField>
|
||||
</Columns>
|
||||
<PagerTemplate>
|
||||
<cc1:GridViewPager ID="GridViewPager2" runat="server" />
|
||||
</PagerTemplate>
|
||||
</asp:GridView>
|
||||
</asp:Panel>
|
||||
</asp:Content>
|
||||
@@ -0,0 +1,72 @@
|
||||
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 數位課程訓練對象 : FormBase
|
||||
{
|
||||
protected DAC_數位課程觀看紀錄 Dao數位課程觀看紀錄;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "數位課程訓練對象";
|
||||
|
||||
Dao數位課程觀看紀錄 = new DAC_數位課程觀看紀錄(conn);
|
||||
|
||||
if (IsPostBack)
|
||||
{
|
||||
GridView1.DataBind();
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnSearch員工_Click(object sender, EventArgs e)
|
||||
{
|
||||
GridView1.DataBind();
|
||||
}
|
||||
|
||||
protected void GridView2_RowCommand(object sender, GridViewCommandEventArgs e)
|
||||
{
|
||||
switch (e.CommandName)
|
||||
{
|
||||
case "Add":
|
||||
Dao數位課程觀看紀錄.報名(DAC.GetInt32(e.CommandArgument), DAC.GetString(GridView1.SelectedValue), UserId);
|
||||
GridView2.DataBind();
|
||||
break;
|
||||
case "Remove":
|
||||
Dao數位課程觀看紀錄.取消報名(DAC.GetInt32(e.CommandArgument), DAC.GetString(GridView1.SelectedValue));
|
||||
GridView2.DataBind();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
protected void GridView1_DataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (GridView1.Rows.Count > 0)
|
||||
{
|
||||
Panel1.Visible = true;
|
||||
if (GridView1.SelectedIndex == -1)
|
||||
GridView1.SelectedIndex = 0;
|
||||
GridView1_SelectedIndexChanged(sender, e);
|
||||
}
|
||||
else
|
||||
Panel1.Visible = false;
|
||||
}
|
||||
|
||||
protected void GridView1_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (GridView1.SelectedIndex != -1)
|
||||
{
|
||||
Panel2.Visible = true;
|
||||
GridView2.DataBind();
|
||||
}
|
||||
else
|
||||
Panel2.Visible = false;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+125
@@ -0,0 +1,125 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class 數位課程訓練對象
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Label9 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label9;
|
||||
|
||||
/// <summary>
|
||||
/// txtBPENO 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txtBPENO;
|
||||
|
||||
/// <summary>
|
||||
/// Label10 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label10;
|
||||
|
||||
/// <summary>
|
||||
/// txtBPNME 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txtBPNME;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch員工 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearch員工;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel Panel1;
|
||||
|
||||
/// <summary>
|
||||
/// ds員工 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds員工;
|
||||
|
||||
/// <summary>
|
||||
/// GridView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView1;
|
||||
|
||||
/// <summary>
|
||||
/// Panel2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Panel Panel2;
|
||||
|
||||
/// <summary>
|
||||
/// Label2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label2;
|
||||
|
||||
/// <summary>
|
||||
/// ds數位課程 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds數位課程;
|
||||
|
||||
/// <summary>
|
||||
/// GridView2 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView2;
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,252 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using WebLib;
|
||||
using System.IO;
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
public partial class 訓練課程企劃書 : FormBase
|
||||
{
|
||||
protected bool 可異動;
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
FunctionName = "訓練課程企劃書";
|
||||
HelpUrl = "~/Help/課程企劃/訓練課程企劃書.html";
|
||||
|
||||
Form_View = FormView1;
|
||||
Grid_View = GridView1;
|
||||
FormView_DataSource = dsForm;
|
||||
GridView_DataSource = dsGrid;
|
||||
|
||||
AddTabButton(MultiView1, View查詢, btnSearchTab);
|
||||
AddTabButton(MultiView1, View處理, btnProcessTab);
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
ActivateTab(MultiView1, 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
AfterChangeTab();
|
||||
}
|
||||
|
||||
if (Form_View.CurrentMode != FormViewMode.ReadOnly)
|
||||
{
|
||||
Grid_View.Visible = false;
|
||||
}
|
||||
|
||||
送簽1.DataBind();
|
||||
}
|
||||
|
||||
protected void btnSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
Grid_View.PageIndex = 0;
|
||||
Grid_View.DataBind();
|
||||
送簽1.DataBind();
|
||||
}
|
||||
|
||||
protected void btnClear_Click(object sender, EventArgs e)
|
||||
{
|
||||
dd計畫別_Search.SelectedValue = "";
|
||||
txt訓練年度_Search.Text = "";
|
||||
txt訓練名稱_Search.Text = "";
|
||||
txt承辦_Search.Text = "";
|
||||
}
|
||||
|
||||
protected override void AfterChangeTab()
|
||||
{
|
||||
switch (MultiView1.ActiveViewIndex)
|
||||
{
|
||||
case 1:
|
||||
Grid_View.DataBind();
|
||||
Form_View.DataBind();
|
||||
break;
|
||||
case 4:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
protected override void GridView_DataSource_Selected(object sender, ObjectDataSourceStatusEventArgs e)
|
||||
{
|
||||
base.GridView_DataSource_Selected(sender, e);
|
||||
|
||||
if (MultiView1.ActiveViewIndex == 0)
|
||||
{
|
||||
if (e.ReturnValue is 訓練課程企劃List list && list.Count > 0)
|
||||
ActivateTab(MultiView1, 1);
|
||||
else
|
||||
lbMessage.Text = "找不到合乎條件的資料";
|
||||
}
|
||||
}
|
||||
|
||||
protected override void GridView_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
base.GridView_SelectedIndexChanged(sender, e);
|
||||
送簽1.DataBind();
|
||||
送簽1.Refresh();
|
||||
}
|
||||
|
||||
protected override void GridView_PageIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
base.GridView_PageIndexChanged(sender, e);
|
||||
送簽1.DataBind();
|
||||
送簽1.Refresh();
|
||||
}
|
||||
|
||||
protected void dsGrid_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao訓練課程企劃;
|
||||
}
|
||||
|
||||
protected void dsForm_ObjectCreating(object sender, ObjectDataSourceEventArgs e)
|
||||
{
|
||||
e.ObjectInstance = Dao訓練課程企劃;
|
||||
}
|
||||
|
||||
protected override void FormView_ReadOnlyDataBound(object sender, EventArgs e)
|
||||
{
|
||||
if (Form_View.SelectedValue != null)
|
||||
{
|
||||
base.FormView_ReadOnlyDataBound(sender, e);
|
||||
可異動 = Dao表單簽核主檔.表單可異動("課程企劃", DAC.GetString(Form_View.SelectedValue));
|
||||
|
||||
SetWebControlEnabled((Form_View.FindControl("btnUpdate") as WebControl), 可異動);
|
||||
SetWebControlEnabled((Form_View.FindControl("btnDelete") as WebControl), 可異動);
|
||||
}
|
||||
}
|
||||
|
||||
protected override void FormView_DataBinding(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_DataBinding(sender, e);
|
||||
}
|
||||
|
||||
protected override void FormView_InsertDataBound(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_InsertDataBound(sender, e);
|
||||
FormViewSetControlValue("hf公司別", CompanyId);
|
||||
FormViewSetControlValue("txt人數", "30");
|
||||
FormViewSetControlValue("txt開放報名日期", DateTime.UtcNow.AddHours(8).Date.ToString("yyyyMMdd"));
|
||||
FormViewSetControlValue("txt報名截止期限", "5");
|
||||
FormViewSetControlValue("txt取消報名截止期限", "5");
|
||||
FormViewSetControlValue("txt承辦", UserId);
|
||||
FormViewSetControlValue("txt承辦X", UserName);
|
||||
}
|
||||
|
||||
protected override void FormView_ModeChanged(object sender, EventArgs e)
|
||||
{
|
||||
base.FormView_ModeChanged(sender, e);
|
||||
送簽1.Visible = Form_View.CurrentMode == FormViewMode.ReadOnly;
|
||||
if (送簽1.Visible)
|
||||
{
|
||||
送簽1.DataBind();
|
||||
送簽1.Refresh();
|
||||
}
|
||||
}
|
||||
|
||||
protected void FormView1_ItemCommand(object sender, FormViewCommandEventArgs e)
|
||||
{
|
||||
if (e.CommandName == "Close")
|
||||
{
|
||||
int 課程ID = DAC.GetInt32(e.CommandArgument);
|
||||
訓練課程企劃List d = Dao訓練課程企劃.SelectOne(課程ID);
|
||||
if (d.Count > 0)
|
||||
{
|
||||
if (d[0].已結案 == "Y")
|
||||
d[0].已結案 = "N";
|
||||
else
|
||||
d[0].已結案 = "Y";
|
||||
Dao訓練課程企劃.UpdateOne(d[0]);
|
||||
this.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void 送簽1_DataBinding(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid_View.SelectedValue != null)
|
||||
{
|
||||
int 課程id = DAC.GetInt32(Grid_View.SelectedValue);
|
||||
送簽1.表單ID = 課程id.ToString();
|
||||
送簽1.編號2 = 0;
|
||||
送簽1.訓練課程企劃編號 = 課程id;
|
||||
送簽1.Visible = true;
|
||||
訓練課程企劃List d = Dao訓練課程企劃.SelectOne(課程id);
|
||||
|
||||
if (d.Count == 0)
|
||||
送簽1.可送簽 = false;
|
||||
else
|
||||
{
|
||||
送簽1.表單ID格式 = String.Format("[{0}] {1}", d[0].顯示編號, d[0].訓練名稱);
|
||||
|
||||
/*
|
||||
DAC_場地遴選 Dao場地遴選 = new DAC_場地遴選(conn);
|
||||
場地遴選List 場地List = Dao場地遴選.SelectOne(課程id);
|
||||
|
||||
bool 場地已簽准 = 場地List.Count > 0;
|
||||
|
||||
if (場地List.Count > 0)
|
||||
{
|
||||
表單簽核主檔 場地簽核status = Dao表單簽核主檔.GetLastStatus("場地遴選", 場地List[0].課程企劃編號.ToString());
|
||||
場地已簽准 &= 場地簽核status != null &&
|
||||
場地簽核status.應簽關數.CompareTo("D") != 0 &&
|
||||
場地簽核status.應簽關數.CompareTo(場地簽核status.已簽關數) == 0 &&
|
||||
場地簽核status.最終結果 == "Y";
|
||||
}
|
||||
|
||||
DAC_訓練課程內容 Dao訓練課程內容 = new DAC_訓練課程內容(conn);
|
||||
訓練課程內容List 課程內容List = Dao訓練課程內容.SelectBy課程企劃(課程id);
|
||||
|
||||
bool 講師已簽准 = 課程內容List.Count > 0;
|
||||
|
||||
foreach (訓練課程內容 item in 課程內容List)
|
||||
{
|
||||
表單簽核主檔 講師簽核status = Dao表單簽核主檔.GetLastStatus("講師遴選", String.Format("{0}|{1}", 課程id, item.課程序號));
|
||||
講師已簽准 &= 講師簽核status != null &&
|
||||
講師簽核status.應簽關數.CompareTo("D") != 0 &&
|
||||
講師簽核status.應簽關數.CompareTo(講師簽核status.已簽關數) == 0 &&
|
||||
講師簽核status.最終結果 == "Y";
|
||||
}
|
||||
*/
|
||||
|
||||
送簽1.可送簽 = d[0].承辦.CompareTo(UserId) == 0 && Dao訓練課程企劃.Get場地講師已輸入(課程id);
|
||||
}
|
||||
}
|
||||
else
|
||||
送簽1.Visible = false;
|
||||
}
|
||||
|
||||
protected void 送簽1_Approved(object sender, EventArgs e)
|
||||
{
|
||||
this.DataBind();
|
||||
}
|
||||
|
||||
protected void 送簽1_Sending(object sender, SendingEventArgs e)
|
||||
{
|
||||
//int 課程id = DAC.GetInt32(Grid_View.SelectedValue);
|
||||
//e.允許送簽 = Dao訓練課程企劃.Get場地講師已簽准(課程id);
|
||||
//if (!e.允許送簽)
|
||||
//{
|
||||
// ScriptManager.RegisterStartupScript(Page, Page.GetType(), "client_mesage",
|
||||
// String.Format("alert(\"{0}\");", StringTable.GetString("場地遴選與講師遴選均簽核完畢,才可送簽")), true);
|
||||
//}
|
||||
}
|
||||
protected string Get選定場地名稱(object 課程企劃編號)
|
||||
{
|
||||
int id = DAC.GetInt32(課程企劃編號);
|
||||
場地 d = GetData.取得選定場地(id);
|
||||
if (d.編號 == 0)
|
||||
{
|
||||
場地異動List v = new DAC_場地異動(conn).Select最後異動(id);
|
||||
if (v.Count > 0 && v[0].場地編號 == 0 && !String.IsNullOrEmpty(v[0].場地名稱))
|
||||
return Server.HtmlEncode(v[0].場地名稱);
|
||||
return "";
|
||||
}
|
||||
else
|
||||
return d.場地名稱;
|
||||
}
|
||||
}
|
||||
}
|
||||
+224
@@ -0,0 +1,224 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自動產生>
|
||||
// 這段程式碼是由工具產生的。
|
||||
//
|
||||
// 變更這個檔案可能會導致不正確的行為,而且如果已重新產生
|
||||
// 程式碼,則會遺失變更。
|
||||
// </自動產生>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Education.Forms.課程企劃
|
||||
{
|
||||
|
||||
|
||||
public partial class 訓練課程企劃書
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// btnProcessTab 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnProcessTab;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearchTab 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearchTab;
|
||||
|
||||
/// <summary>
|
||||
/// MultiView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.MultiView MultiView1;
|
||||
|
||||
/// <summary>
|
||||
/// View查詢 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.View View查詢;
|
||||
|
||||
/// <summary>
|
||||
/// btnSearch 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnSearch;
|
||||
|
||||
/// <summary>
|
||||
/// btnClear 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton btnClear;
|
||||
|
||||
/// <summary>
|
||||
/// Label6 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label Label6;
|
||||
|
||||
/// <summary>
|
||||
/// txt訓練年度_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt訓練年度_Search;
|
||||
|
||||
/// <summary>
|
||||
/// rgv訓練年度_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RangeValidator rgv訓練年度_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb計畫別Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb計畫別Label;
|
||||
|
||||
/// <summary>
|
||||
/// dd計畫別_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::WebLib.WDropDownList dd計畫別_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb訓練名稱Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb訓練名稱Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt訓練名稱_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt訓練名稱_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lb承辦Label 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lb承辦Label;
|
||||
|
||||
/// <summary>
|
||||
/// txt承辦_Search 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txt承辦_Search;
|
||||
|
||||
/// <summary>
|
||||
/// lbMessage 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lbMessage;
|
||||
|
||||
/// <summary>
|
||||
/// View處理 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.View View處理;
|
||||
|
||||
/// <summary>
|
||||
/// dsGrid 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsGrid;
|
||||
|
||||
/// <summary>
|
||||
/// dsForm 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource dsForm;
|
||||
|
||||
/// <summary>
|
||||
/// ds計畫別 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource ds計畫別;
|
||||
|
||||
/// <summary>
|
||||
/// FormView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.FormView FormView1;
|
||||
|
||||
/// <summary>
|
||||
/// 送簽1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::Education.Forms.簽核.送簽 送簽1;
|
||||
|
||||
/// <summary>
|
||||
/// GridView1 控制項。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自動產生的欄位。
|
||||
/// 若要修改,請將欄位宣告從設計工具檔案移到程式碼後置檔案。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView GridView1;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user