提交代码
This commit is contained in:
@@ -25,14 +25,21 @@
|
||||
<Items>
|
||||
<f:DatePicker ID="txtNDEDateMonth" runat="server" Label="月份"
|
||||
EmptyText="输入查询条件" AutoPostBack="true" OnTextChanged="Tree_TextChanged"
|
||||
Width="265px" LabelWidth="100px" DisplayType="Month" DateFormatString="yyyy-MM" LabelAlign="Right">
|
||||
Width="265px" LabelWidth="90px" DisplayType="Month" DateFormatString="yyyy-MM" LabelAlign="Right">
|
||||
</f:DatePicker>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
<f:Toolbar ID="Toolbar3" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<f:DropDownList ID="drpUnit" runat="server" Label="单位名称"
|
||||
LabelAlign="Right" Width="300px" LabelWidth="90px" AutoPostBack="true" OnSelectedIndexChanged="Tree_TextChanged">
|
||||
</f:DropDownList>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
<f:Toolbar ID="Toolbar5" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<f:TextBox ID="txtSearchCode" runat="server" EmptyText="输入查询条件"
|
||||
AutoPostBack="true" Label="委托单号" LabelWidth="100px"
|
||||
AutoPostBack="true" Label="委托单号" LabelWidth="90px"
|
||||
OnTextChanged="Tree_TextChanged" LabelAlign="Right">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
|
||||
@@ -53,6 +53,7 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
{
|
||||
GetButtonPower();
|
||||
this.Type = Request.Params["Type"];
|
||||
BLL.UnitService.InitUnitByProjectIdUnitTypeDropDownList(this.drpUnit, this.CurrUser.LoginProjectId, BLL.Const.ProjectUnitType_2, true);
|
||||
this.txtNDEDateMonth.Text = string.Format("{0:yyyy-MM}", DateTime.Now);
|
||||
this.ddlPageSize.SelectedValue = this.Grid1.PageSize.ToString();
|
||||
this.TrustBatchId = string.Empty;
|
||||
@@ -148,8 +149,8 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
unitWork1 = (from x in unitWorkList where x.ProjectType == "1" select x).ToList();
|
||||
unitWork2 = (from x in unitWorkList where x.ProjectType == "2" select x).ToList();
|
||||
unitWork1 = (from x in unitWorkList where x.ProjectType == "1" select x).ToList();
|
||||
unitWork2 = (from x in unitWorkList where x.ProjectType == "2" select x).ToList();
|
||||
//}
|
||||
|
||||
if (unitWork1.Count() > 0)
|
||||
@@ -195,7 +196,7 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
private void BindNodes(TreeNode node)
|
||||
{ ///&& x.TrustType == (this.Type == "R" ? "R" : null)
|
||||
var p = from x in Funs.DB.HJGL_Batch_BatchTrust
|
||||
where x.UnitWorkId == node.NodeID && Equals(x.TrustType, (this.Type == "R" ? "R" : null))
|
||||
where x.UnitWorkId == node.NodeID && Equals(x.TrustType, (this.Type == "R" ? "R" : null))
|
||||
&& x.TrustDate < Convert.ToDateTime(this.txtNDEDateMonth.Text.Trim() + "-01").AddMonths(1)
|
||||
&& x.TrustDate >= Convert.ToDateTime(this.txtNDEDateMonth.Text.Trim() + "-01")
|
||||
select x;
|
||||
@@ -264,6 +265,10 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
&& x.DetectionTypeId == ndtTypeId && x.DetectionRateId == item.DetectionRateId
|
||||
orderby x.TrustBatchCode descending
|
||||
select x;
|
||||
if (this.drpUnit.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
trusts = trusts.Where(x => x.UnitId == this.drpUnit.SelectedValue).OrderBy(x => x.TrustBatchCode);
|
||||
}
|
||||
if (item.DetectionRateValue > 0) //探伤比例为0的批不显示
|
||||
{
|
||||
TreeNode newNode = new TreeNode();
|
||||
@@ -300,6 +305,10 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
&& x.DetectionTypeId == ndtTypeId && x.DetectionRateId == ndtRateId
|
||||
orderby x.TrustBatchCode descending
|
||||
select x;
|
||||
if (this.drpUnit.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
trusts = trusts.Where(x => x.UnitId == this.drpUnit.SelectedValue).OrderBy(x => x.TrustBatchCode);
|
||||
}
|
||||
foreach (var trust in trusts)
|
||||
{
|
||||
TreeNode newNode = new TreeNode();
|
||||
@@ -318,11 +327,11 @@ namespace FineUIPro.Web.HJGL.NDT
|
||||
Model.HJGL_Batch_PointBatch batch = BLL.PointBatchService.GetPointBatchById(trust.PointBatchId);
|
||||
if (batch != null && batch.IsClosed == true)
|
||||
{
|
||||
newNode.Text = code;
|
||||
newNode.Text = code + "【" + BLL.UnitService.GetUnitNameByUnitId(trust.UnitId) + "】";
|
||||
}
|
||||
else
|
||||
{
|
||||
newNode.Text = "<font color='#EE0000'>" + code + "</font>";
|
||||
newNode.Text = "<font color='#EE0000'>" + code + "【" + BLL.UnitService.GetUnitNameByUnitId(trust.UnitId) + "】" + "</font>";
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -66,6 +66,24 @@ namespace FineUIPro.Web.HJGL.NDT {
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtNDEDateMonth;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar3;
|
||||
|
||||
/// <summary>
|
||||
/// drpUnit 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpUnit;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar5 控件。
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user