人员管理补充公司级树
This commit is contained in:
parent
5a6796f656
commit
a37909b608
|
@ -33,11 +33,11 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
|
||||
this.txtStartDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||
|
@ -48,11 +48,15 @@ namespace FineUIPro.Web.Door
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
this.InitDropDownList();
|
||||
this.GetPersonStatistic();
|
||||
}
|
||||
/// <summary>
|
||||
|
|
|
@ -35,11 +35,10 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
this.txtStartDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||
this.txtEndDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||
if (this.CurrUser != null && this.CurrUser.PageSize.HasValue)
|
||||
|
@ -57,9 +56,14 @@ namespace FineUIPro.Web.Door
|
|||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
this.GetPersonStatistic();
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
}
|
||||
|
||||
#region 删除
|
||||
/// <summary>
|
||||
|
@ -240,7 +244,7 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
if (registrationId != null)
|
||||
{
|
||||
var registration = (from x in Funs.DB.T_d_facerecord where x.NewID == registrationId select x).FirstOrDefault();
|
||||
var registration = (from x in Funs.DB.T_d_facerecord where x.NewID == registrationId.ToString() select x).FirstOrDefault();
|
||||
// registration.Des1 = "FileUpload/Registration/20247/2024-07/638556302997373049_QQ截图20220817171229_-_副本.png";
|
||||
if (registration != null)
|
||||
{
|
||||
|
|
|
@ -33,11 +33,11 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
|
||||
this.txtStartDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||
|
@ -49,11 +49,14 @@ namespace FineUIPro.Web.Door
|
|||
}
|
||||
}
|
||||
}
|
||||
private void InitDropDownList()
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
this.InitDropDownList();
|
||||
this.GetPersonStatistic();
|
||||
}
|
||||
/// <summary>
|
||||
|
|
|
@ -33,11 +33,10 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
UnitService.InitUnitDownList(this.drpUnit, this.ProjectId, true);
|
||||
Funs.FineUIPleaseSelect(this.drpWorkTeam);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
|
||||
|
@ -55,12 +54,14 @@ namespace FineUIPro.Web.Door
|
|||
}
|
||||
}
|
||||
}
|
||||
private void InitDropDownList()
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
UnitService.InitUnitDownList(this.drpUnit, this.ProjectId, true);
|
||||
Funs.FineUIPleaseSelect(this.drpWorkTeam);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, true);
|
||||
this.InitDropDownList();
|
||||
this.GetPersonStatistic();
|
||||
}
|
||||
/// <summary>
|
||||
|
|
|
@ -35,9 +35,10 @@ namespace FineUIPro.Web.Door
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, false);
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
UnitService.InitUnitDownList(this.drpUnit, this.ProjectId, true);
|
||||
this.txtDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||
Search();
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
|
@ -47,11 +48,14 @@ namespace FineUIPro.Web.Door
|
|||
}
|
||||
}
|
||||
}
|
||||
private void InitDropDownList()
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
UnitService.InitUnitDownList(this.drpUnit, this.ProjectId, false);
|
||||
WorkPostService.InitWorkPostDropDownList(this.drpWorkPost, false);
|
||||
this.InitDropDownList();
|
||||
|
||||
}
|
||||
#region 查询
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TaskNotice.aspx.cs" Inherits="FineUIPro.Web.HSSE.EduTrain.TaskNotice" %>
|
||||
|
||||
<%@ Register Src="~/Controls/UnitProjectTControl.ascx" TagName="UnitProjectTControl" TagPrefix="uc1" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
|
@ -9,23 +11,38 @@
|
|||
</head>
|
||||
<body>
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel1" runat="server" />
|
||||
<f:Panel ID="Panel1" runat="server" Margin="5px" BodyPadding="5px" ShowBorder="false"
|
||||
ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Panel2" runat="server" />
|
||||
<f:Panel ID="Panel2" runat="server" ShowBorder="false" ShowHeader="false" Layout="Region">
|
||||
<Items>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="培训记录" EnableCollapse="true"
|
||||
runat="server" BoxFlex="1" DataKeyNames="TaskNoticeId" EnableColumnLines="true" DataIDField="TaskNoticeId" AllowSorting="true"
|
||||
SortField="TrainStartDate" SortDirection="DESC" OnSort="Grid1_Sort" AllowPaging="true" ForceFit="true"
|
||||
IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange"
|
||||
EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick"
|
||||
EnableTextSelection="True" EnableSummary="true" SummaryPosition="Flow">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar2" Position="Top" runat="server">
|
||||
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
||||
EnableCollapse="true" Width="380" Title="公司-项目" TitleToolTip="公司-项目" ShowBorder="true"
|
||||
ShowHeader="true" AutoScroll="true" BodyPadding="5px" IconFont="ArrowCircleLeft" Layout="Fit">
|
||||
<Items>
|
||||
<f:ContentPanel ID="ContentPanel1" runat="server" ShowHeader="false" EnableCollapse="true" AutoScroll="true"
|
||||
BodyPadding="0px">
|
||||
<uc1:UnitProjectTControl ID="ucTree" runat="server" Onchange="changeTree" />
|
||||
</f:ContentPanel>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true"
|
||||
Layout="VBox" ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" AutoScroll="true">
|
||||
<Items>
|
||||
<f:Panel ID="Panel1" runat="server" Margin="5px" BodyPadding="5px" ShowBorder="false" MinHeight="700px"
|
||||
ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
|
||||
<Items>
|
||||
<f:DropDownList ID="drpTrainType" runat="server" Label="培训类别" Width="210px" LabelWidth="80px" LabelAlign="Right"
|
||||
AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged">
|
||||
</f:DropDownList>
|
||||
<%-- <f:DropDownList ID="drpUnitId" runat="server" Label="单位" AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged"
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="培训记录" EnableCollapse="true"
|
||||
runat="server" BoxFlex="1" DataKeyNames="TaskNoticeId" EnableColumnLines="true" DataIDField="TaskNoticeId" AllowSorting="true"
|
||||
SortField="TrainStartDate" SortDirection="DESC" OnSort="Grid1_Sort" AllowPaging="true" ForceFit="true"
|
||||
IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange"
|
||||
EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick"
|
||||
EnableTextSelection="True" EnableSummary="true" SummaryPosition="Flow">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar2" Position="Top" runat="server">
|
||||
<Items>
|
||||
<f:DropDownList ID="drpTrainType" runat="server" Label="培训类别" Width="210px" LabelWidth="80px" LabelAlign="Right"
|
||||
AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged">
|
||||
</f:DropDownList>
|
||||
<%-- <f:DropDownList ID="drpUnitId" runat="server" Label="单位" AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged"
|
||||
LabelAlign="Right" LabelWidth="50px" Width="260px">
|
||||
</f:DropDownList>
|
||||
<f:DatePicker ID="txtStartDate" runat="server" Label="日期" Width="160px" LabelWidth="60px" LabelAlign="Right"
|
||||
|
@ -35,69 +52,73 @@
|
|||
</f:Label>
|
||||
<f:DatePicker ID="txtEndDate" runat="server" Width="100px" AutoPostBack="true" OnTextChanged="Text_TextChanged">
|
||||
</f:DatePicker>--%>
|
||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||
</f:ToolbarFill>
|
||||
<f:Button ID="btnNew" ToolTip="新增" Icon="Add" runat="server" Hidden="true" OnClick="btnNew_Click" Text="新增">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Columns>
|
||||
<f:TemplateField ColumnID="tfNumber" Width="55px" HeaderText="序号" HeaderTextAlign="Center"
|
||||
TextAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblNumber" runat="server" Text='<%# Grid1.PageIndex * Grid1.PageSize + Container.DataItemIndex + 1 %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
<%--<f:RenderField Width="120px" ColumnID="TrainingCode" DataField="TrainingCode" SortField="TrainingCode"
|
||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||
</f:ToolbarFill>
|
||||
<f:Button ID="btnNew" ToolTip="新增" Icon="Add" runat="server" Hidden="true" OnClick="btnNew_Click" Text="新增">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Columns>
|
||||
<f:TemplateField ColumnID="tfNumber" Width="55px" HeaderText="序号" HeaderTextAlign="Center"
|
||||
TextAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblNumber" runat="server" Text='<%# Grid1.PageIndex * Grid1.PageSize + Container.DataItemIndex + 1 %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
<%--<f:RenderField Width="120px" ColumnID="TrainingCode" DataField="TrainingCode" SortField="TrainingCode"
|
||||
FieldType="String" HeaderText="培训编号" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>--%>
|
||||
<f:RenderField Width="150px" ColumnID="TrainTitle" DataField="TrainTitle" SortField="TrainTitle"
|
||||
FieldType="String" HeaderText="标题" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="110px" ColumnID="TrainTypeName" DataField="TrainTypeName" SortField="TrainTypeName"
|
||||
FieldType="String" HeaderText="培训类型" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>
|
||||
|
||||
<f:RenderField Width="65px" ColumnID="TeachHour" DataField="TeachHour" SortField="TeachHour"
|
||||
FieldType="Float" HeaderText="学时" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="65px" ColumnID="DayOfWeek" DataField="DayOfWeek" SortField="DayOfWeek"
|
||||
FieldType="Float" HeaderText="周几" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="65px" ColumnID="WeekOfMonth" DataField="WeekOfMonth" SortField="WeekOfMonth"
|
||||
FieldType="Float" HeaderText="每月第几周" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:TemplateField ColumnID="tfTeachMan" Width="65px" HeaderText="授课人" HeaderTextAlign="Center"
|
||||
TextAlign="left">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblTeachMan" runat="server" Text='<%# ConvertUserName(Eval("TeachMan")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
<f:RenderField Width="100px" ColumnID="TrainStartDate" DataField="TrainStartDate"
|
||||
SortField="TrainStartDate" FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd"
|
||||
HeaderText="编制日期" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:TemplateField ColumnID="State" Width="65px" HeaderText="状态" HeaderTextAlign="Center"
|
||||
TextAlign="left">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# ConvertState(Eval("State")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
</Listeners>
|
||||
<PageItems>
|
||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||
</f:ToolbarSeparator>
|
||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||
</f:ToolbarText>
|
||||
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
||||
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
||||
</f:DropDownList>
|
||||
</PageItems>
|
||||
</f:Grid>
|
||||
<f:RenderField Width="150px" ColumnID="TrainTitle" DataField="TrainTitle" SortField="TrainTitle"
|
||||
FieldType="String" HeaderText="标题" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="110px" ColumnID="TrainTypeName" DataField="TrainTypeName" SortField="TrainTypeName"
|
||||
FieldType="String" HeaderText="培训类型" HeaderTextAlign="Center" TextAlign="Left">
|
||||
</f:RenderField>
|
||||
|
||||
<f:RenderField Width="65px" ColumnID="TeachHour" DataField="TeachHour" SortField="TeachHour"
|
||||
FieldType="Float" HeaderText="学时" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="65px" ColumnID="DayOfWeek" DataField="DayOfWeek" SortField="DayOfWeek"
|
||||
FieldType="Float" HeaderText="周几" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="65px" ColumnID="WeekOfMonth" DataField="WeekOfMonth" SortField="WeekOfMonth"
|
||||
FieldType="Float" HeaderText="每月第几周" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:TemplateField ColumnID="tfTeachMan" Width="65px" HeaderText="授课人" HeaderTextAlign="Center"
|
||||
TextAlign="left">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblTeachMan" runat="server" Text='<%# ConvertUserName(Eval("TeachMan")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
<f:RenderField Width="100px" ColumnID="TrainStartDate" DataField="TrainStartDate"
|
||||
SortField="TrainStartDate" FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd"
|
||||
HeaderText="编制日期" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:TemplateField ColumnID="State" Width="65px" HeaderText="状态" HeaderTextAlign="Center"
|
||||
TextAlign="left">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# ConvertState(Eval("State")) %>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
</Listeners>
|
||||
<PageItems>
|
||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||
</f:ToolbarSeparator>
|
||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||
</f:ToolbarText>
|
||||
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
||||
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
||||
</f:DropDownList>
|
||||
</PageItems>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Window ID="Window1" Title="编制培训记录" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
|
@ -112,7 +133,7 @@
|
|||
<f:MenuButton ID="btnMenuEdit" OnClick="btnMenuEdit_Click" EnablePostBack="true"
|
||||
runat="server" Icon="Pencil" Hidden="true" Text="编辑">
|
||||
</f:MenuButton>
|
||||
<f:MenuButton ID="btnMenuAddNew" OnClick="btnMenuAddNew_Click" EnablePostBack="true"
|
||||
<f:MenuButton ID="btnMenuAddNew" OnClick="btnMenuAddNew_Click" EnablePostBack="true"
|
||||
runat="server" Icon="Pencil" Hidden="true" Text="生成新计划">
|
||||
</f:MenuButton>
|
||||
<f:MenuButton ID="btnMenuDelete" OnClick="btnMenuDelete_Click" EnablePostBack="true"
|
||||
|
|
|
@ -12,7 +12,22 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
{
|
||||
public partial class TaskNotice : PageBase
|
||||
{
|
||||
|
||||
#region 项目主键
|
||||
/// <summary>
|
||||
/// 项目主键
|
||||
/// </summary>
|
||||
public string ProjectId
|
||||
{
|
||||
get
|
||||
{
|
||||
return (string)ViewState["ProjectId"];
|
||||
}
|
||||
set
|
||||
{
|
||||
ViewState["ProjectId"] = value;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 加载页面
|
||||
/// <summary>
|
||||
|
@ -25,19 +40,47 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
if (!IsPostBack)
|
||||
{
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
this.ProjectId = this.CurrUser.LoginProjectId;
|
||||
if (!string.IsNullOrEmpty(Request.Params["projectId"]) && Request.Params["projectId"] != this.CurrUser.LoginProjectId)
|
||||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
{
|
||||
this.panelLeftRegion.Hidden = true;
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
}
|
||||
|
||||
this.btnMenuDelete.OnClientClick = Grid1.GetNoSelectionAlertReference("请至少选择一项!");
|
||||
this.btnMenuDelete.ConfirmText = String.Format("你确定要删除选中的 <b><script>{0}</script></b> 行数据吗?", Grid1.GetSelectedCountReference());
|
||||
//单位
|
||||
// BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.CurrUser.LoginProjectId, true);
|
||||
// BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.CurrUser.LoginProjectId, true);
|
||||
//培训类型
|
||||
BLL.TrainTypeService.InitTrainTypeDropDownList(this.drpTrainType, true);
|
||||
|
||||
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
// 绑定表格
|
||||
BindGrid();
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 公司级树加载
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.BindGrid();
|
||||
|
||||
this.GetButtonPower();
|
||||
if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
{
|
||||
btnNew.Hidden = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -46,8 +89,12 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
string projectId = this.CurrUser.LoginProjectId;
|
||||
|
||||
if (string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
return;
|
||||
}
|
||||
//string projectId = this.CurrUser.LoginProjectId;
|
||||
|
||||
string strSql = @"SELECT task.TaskNoticeId,
|
||||
task.TrainTitle,
|
||||
task.TrainType,
|
||||
|
@ -69,14 +116,14 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
LEFT JOIN dbo.Sys_User AS users ON users.UserId = task.CreatMan where 1=1 ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
strSql += " AND task.ProjectId = @ProjectId";
|
||||
listStr.Add(new SqlParameter("@ProjectId", projectId));
|
||||
if (drpTrainType.SelectedValue!=Const._Null)
|
||||
listStr.Add(new SqlParameter("@ProjectId", this.ProjectId));
|
||||
if (drpTrainType.SelectedValue != Const._Null)
|
||||
{
|
||||
strSql += " AND task.TrainType = @TrainType";
|
||||
listStr.Add(new SqlParameter("@TrainType", drpTrainType.SelectedValue));
|
||||
|
||||
}
|
||||
|
||||
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||
Grid1.RecordCount = tb.Rows.Count;
|
||||
|
@ -97,7 +144,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
//};
|
||||
|
||||
// Grid1.SummaryData = summary;
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
@ -184,9 +231,9 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
var model = EduTrain_TaskNoticeService.GetEduTrain_TaskNoticeById(TaskNoticeId);
|
||||
if (model != null)
|
||||
{
|
||||
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("TaskNoticeEdit.aspx?TaskNoticeId={0}", TaskNoticeId, "编辑 - ")));
|
||||
|
||||
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("TaskNoticeEdit.aspx?TaskNoticeId={0}", TaskNoticeId, "编辑 - ")));
|
||||
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
@ -295,7 +342,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
{
|
||||
return;
|
||||
}
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProjectTrainRecordMenuId);
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.ProjectId, this.CurrUser.UserId, BLL.Const.ProjectTrainRecordMenuId);
|
||||
if (buttonList.Count() > 0)
|
||||
{
|
||||
if (buttonList.Contains(BLL.Const.BtnAdd))
|
||||
|
@ -361,7 +408,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
return "";
|
||||
}
|
||||
|
||||
protected string ConvertUserName(object users)
|
||||
protected string ConvertUserName(object users)
|
||||
{
|
||||
string userName = string.Empty;
|
||||
if (users != null)
|
||||
|
@ -399,6 +446,6 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
}
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
|
@ -32,6 +32,51 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// Panel2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel2;
|
||||
|
||||
/// <summary>
|
||||
/// panelLeftRegion 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelLeftRegion;
|
||||
|
||||
/// <summary>
|
||||
/// ContentPanel1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ContentPanel ContentPanel1;
|
||||
|
||||
/// <summary>
|
||||
/// ucTree 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Web.Controls.UnitProjectTControl ucTree;
|
||||
|
||||
/// <summary>
|
||||
/// panelCenterRegion 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelCenterRegion;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
|
|
|
@ -53,6 +53,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
|
@ -63,12 +64,6 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
this.GetButtonPower();
|
||||
var data = APIBaseInfoService.getWorkPost(CurrUser.ProjectId, null);
|
||||
this.drpWorkPost.DataValueField = "BaseInfoId";
|
||||
this.drpWorkPost.DataTextField = "BaseInfoName";
|
||||
this.drpWorkPost.DataSource = data;
|
||||
this.drpWorkPost.DataBind();
|
||||
Funs.FineUIPleaseSelect(drpWorkPost);
|
||||
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
// 绑定表格
|
||||
BindGrid();
|
||||
|
@ -82,9 +77,20 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
var data = APIBaseInfoService.getWorkPost(this.ProjectId, null);
|
||||
this.drpWorkPost.DataValueField = "BaseInfoId";
|
||||
this.drpWorkPost.DataTextField = "BaseInfoName";
|
||||
this.drpWorkPost.DataSource = data;
|
||||
this.drpWorkPost.DataBind();
|
||||
Funs.FineUIPleaseSelect(drpWorkPost);
|
||||
}
|
||||
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
//新增UnitId
|
||||
this.UnitId = this.ucTree.UnitId;
|
||||
//判断 当有projectId的时候单位id为空
|
||||
|
|
|
@ -59,6 +59,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
|
@ -66,14 +67,10 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
this.panelLeftRegion.Hidden = true;
|
||||
// this.Grid1.Columns[0].Hidden = true;
|
||||
}
|
||||
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
GetButtonPower();
|
||||
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.CurrUser.LoginProjectId, true);
|
||||
|
||||
|
||||
///更新没有结束时间且超时的考试记录
|
||||
GetDataService.UpdateTestPlanStates();
|
||||
|
@ -89,10 +86,15 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
//新增UnitId
|
||||
this.UnitId = this.ucTree.UnitId;
|
||||
//判断 当有projectId的时候单位id为空
|
||||
|
|
|
@ -60,12 +60,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
this.ucTree.ProjectId = this.ProjectId;
|
||||
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
this.InitDropDownList();
|
||||
//培训类型
|
||||
BLL.TrainTypeService.InitTrainTypeDropDownList(this.drpTrainType, true);
|
||||
//培训级别;
|
||||
|
@ -81,9 +76,21 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
}
|
||||
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
//新增UnitId
|
||||
this.UnitId = this.ucTree.UnitId;
|
||||
//判断 当有projectId的时候单位id为空
|
||||
|
|
|
@ -60,12 +60,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
this.ucTree.ProjectId = this.ProjectId;
|
||||
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
this.InitDropDownList();
|
||||
//培训类型
|
||||
BLL.TrainTypeService.InitTrainTypeDropDownList(this.drpTrainType, true);
|
||||
//培训级别;
|
||||
|
@ -82,9 +77,20 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
//新增UnitId
|
||||
this.UnitId = this.ucTree.UnitId;
|
||||
//判断 当有projectId的时候单位id为空
|
||||
|
|
|
@ -74,12 +74,12 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
//////权限按钮方法
|
||||
//this.GetButtonPower();
|
||||
this.btnMenuDelete.OnClientClick = Grid1.GetNoSelectionAlertReference("请至少选择一项!");
|
||||
this.btnMenuDelete.ConfirmText = String.Format("你确定要删除选中的 <b><script>{0}</script></b> 行数据吗?", Grid1.GetSelectedCountReference());
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.CurrUser.LoginProjectId, true);
|
||||
|
||||
this.InitDropDownList();
|
||||
//培训类型
|
||||
BLL.TrainTypeService.InitTrainTypeDropDownList(this.drpTrainType, true);
|
||||
trainType = Request.Params["trainType"];
|
||||
|
@ -109,6 +109,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
//新增UnitId
|
||||
this.UnitId = this.ucTree.UnitId;
|
||||
//判断 当有projectId的时候单位id为空
|
||||
|
@ -116,13 +117,20 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
{
|
||||
this.UnitId = "";
|
||||
}
|
||||
this.BindGrid();
|
||||
this.BindGrid();
|
||||
this.GetButtonPower();
|
||||
if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
{
|
||||
btnNew.Hidden = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
//单位
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, true);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 绑定数据
|
||||
/// </summary>
|
||||
|
@ -159,7 +167,7 @@ namespace FineUIPro.Web.HSSE.EduTrain
|
|||
strSql += " AND TrainRecord.TrainTitle LIKE @TrainTitle";
|
||||
listStr.Add(new SqlParameter("@TrainTitle", "%" + this.txtName.Text + "%"));
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (!string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
|
|
|
@ -43,7 +43,7 @@ namespace FineUIPro.Web.HSSE.SitePerson
|
|||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
////权限按钮方法
|
||||
|
@ -61,23 +61,28 @@ namespace FineUIPro.Web.HSSE.SitePerson
|
|||
BindGrid();
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId) )
|
||||
{
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.CurrUser.LoginProjectId, true);
|
||||
if (ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.CurrUser.LoginProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnit.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnit.Enabled = false;
|
||||
}
|
||||
this.panelLeftRegion.Hidden = true;
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
//单位
|
||||
UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true);
|
||||
if (ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnit.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnit.Enabled = false;
|
||||
}
|
||||
}
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
this.BindGrid();
|
||||
|
||||
this.GetButtonPower();
|
||||
}
|
||||
#endregion
|
||||
|
|
Loading…
Reference in New Issue